Class AddMessageToEachPage

java.lang.Object
org.apache.pdfbox.examples.pdmodel.AddMessageToEachPage

public class AddMessageToEachPage extends Object
This is an example of how to add a message to every page in a pdf document.
  • Constructor Details

    • AddMessageToEachPage

      public AddMessageToEachPage()
      Constructor.
  • Method Details

    • doIt

      public void doIt(String file, String message, String outfile) throws IOException
      create the second sample document from the PDF file format specification.
      Parameters:
      file - The file to write the PDF to.
      message - The message to write in the file.
      outfile - The resulting PDF.
      Throws:
      IOException - If there is an error writing the data.
    • main

      public static void main(String[] args) throws IOException
      This will create a hello world PDF document.
      see usage() for commandline
      Parameters:
      args - Command line arguments.
      Throws:
      IOException
    • usage

      private void usage()
      This will print out a message telling how to use this example.