'How to modify an existing PDF file contents in Java

I am using a Spring Boot application and I need to dynamically populate the blanks in an existing PDF using the values from the database. I have attached the image of the PDF for your reference.

I want to know the best practice to do so. Please guide me.

Image of the PDF which I want to dynamically populate



Solution 1:[1]

I have used now Itext version 7. Where i have created the exact replica of the existing PDF using Itext table cells.

When you are writing the generation code itself in JAVA then there is no problem in mapping the data into the same.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1