Class PdfMergerProperties


  • public class PdfMergerProperties
    extends java.lang.Object
    Class with additional properties for PdfMerger processing. Needs to be passed at merger initialization.
    • Field Detail

      • closeSrcDocuments

        private boolean closeSrcDocuments
      • mergeTags

        private boolean mergeTags
      • mergeOutlines

        private boolean mergeOutlines
      • mergeScripts

        private boolean mergeScripts
    • Constructor Detail

      • PdfMergerProperties

        public PdfMergerProperties()
        Default constructor, use provided setters for configuration options.
    • Method Detail

      • isCloseSrcDocuments

        public boolean isCloseSrcDocuments()
        check if source documents should be close after merging
        Returns:
        true if they should, false otherwise
      • isMergeTags

        public boolean isMergeTags()
        check if tags should be merged
        Returns:
        true if they should, false otherwise
      • isMergeOutlines

        public boolean isMergeOutlines()
        check if outlines should be merged
        Returns:
        true if they should, false otherwise
      • isMergeScripts

        public boolean isMergeScripts()
        check if ECMA scripts (which are executed at document opening) should be merged
        Returns:
        true if they should, false otherwise
      • setCloseSrcDocuments

        public PdfMergerProperties setCloseSrcDocuments​(boolean closeSrcDocuments)
        close source documents after merging
        Parameters:
        closeSrcDocuments - true to close, false otherwise
        Returns:
        PdfMergerProperties instance
      • setMergeTags

        public PdfMergerProperties setMergeTags​(boolean mergeTags)
        merge documents tags
        Parameters:
        mergeTags - true to merge, false otherwise
        Returns:
        PdfMergerProperties instance
      • setMergeOutlines

        public PdfMergerProperties setMergeOutlines​(boolean mergeOutlines)
        merge documents outlines
        Parameters:
        mergeOutlines - true to merge, false otherwise
        Returns:
        PdfMergerProperties instance
      • setMergeScripts

        public PdfMergerProperties setMergeScripts​(boolean mergeNames)
        merge documents ECMA scripts, if AA or OpenAction or Names dictionaries contained in both documents than nothing will be merged
        Parameters:
        mergeNames - true to merge, false otherwise
        Returns:
        PdfMergerProperties instance