Class Postprocessors
java.lang.Object
pro.verron.officestamper.preset.Postprocessors
The Postprocessors class provides static utility methods for obtaining implementations of the PostProcessor
interface that perform specific post-processing operations on WordprocessingMLPackage documents.
This class is a utility class and cannot be instantiated.
-
Method Summary
Modifier and TypeMethodDescriptionstatic PostProcessorCreates a PostProcessor that removes orphaned endnotes from a WordprocessingMLPackage document.static PostProcessorCreates a PostProcessor that removes orphaned footnotes from a WordprocessingMLPackage document.static PostProcessorremoveTags(String element) Creates a PostProcessor that removes specified XML elements from a WordprocessingMLPackage document.
-
Method Details
-
removeOrphanedFootnotes
Creates a PostProcessor that removes orphaned footnotes from a WordprocessingMLPackage document. An orphaned footnote is a footnote that is defined in the document but does not have a corresponding reference in the main content. This PostProcessor ensures that such unused footnotes are cleaned up, maintaining the structural integrity of the document.- Returns:
- a PostProcessor instance that performs the removal of orphaned footnotes
-
removeOrphanedEndnotes
Creates a PostProcessor that removes orphaned endnotes from a WordprocessingMLPackage document. An orphaned endnote is an endnote that is defined in the document but does not have a corresponding reference in the main content. This PostProcessor ensures that such unused endnotes are cleaned up, maintaining the integrity and consistency of the document.- Returns:
- a PostProcessor instance that performs the removal of orphaned endnotes
-
removeTags
Creates a PostProcessor that removes specified XML elements from a WordprocessingMLPackage document. This PostProcessor searches for and removes all occurrences of the specified element tag within the document, helping to clean up temporary or unwanted markup that may have been used during the stamping process.- Parameters:
element- the name of the XML element to be removed from the document- Returns:
- a
PostProcessorinstance that performs the removal of specified tags
-