Add output method to return a pdf as a string

Suggested by @sdsmith1981