PDF generation methods are added.

need to clean up code and add exceptions.