Return to site

GITHUB: JAVA PDF printer 🖨

· java,github

I am on a SpringBoot project which prints PDF, and I wanted to do a mini-POC on my own to realize how simple can it be.

―It prints a PDF with sample data (with Apache PDFBox).
―It then converts to a base64 string (typically to then send into a JSON).
The whole is done without file system dependencies (thanks to input/output streams).
So it can run on Windows or Unix-like OS.

You launch the app by running the main of the class PDFPrinter.
it outputs the base64 in the console of your IDE.

You can then check the pdf from this website(by pasting into it the base64 from the console):

Have a good one!

All Posts

Almost done…

We just sent you an email. Please click the link in the email to confirm your subscription!