Class SubtreeProcessingMode
java.lang.Object
com.deltaxml.core.config.subtreeProcessing.SubtreeProcessingMode
This class configures content processing based on whether file has data or text or both.
-
Constructor Summary
ConstructorsConstructorDescriptionSubtreeProcessingMode(SubtreeMode defaultMode) Initialises aSubtreeProcessingModewith the given parameters.SubtreeProcessingMode(SubtreeMode defaultMode, List<Subtree> subtrees) Initialises aSubtreeProcessingModewith the given parameters.SubtreeProcessingMode(List<Subtree> subtrees) Initialises aSubtreeProcessingModewith the given parameters. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddSubtree(Subtree subtree) Gets the default mode for subtree processing.voidsetDefaultMode(SubtreeMode defaultType) Sets the default mode for subtree processing.voidsetSubtrees(List<Subtree> subtrees)
-
Constructor Details
-
SubtreeProcessingMode
public SubtreeProcessingMode()Initialises a newSubtreeProcessingModewith an emptyListofSubtree's. Default mode is set according to the comparator used for that product. For example, TEXT forDocumentComparatorand DATA forDataComparator. -
SubtreeProcessingMode
Initialises aSubtreeProcessingModewith the given parameters.- Parameters:
defaultMode- default mode TEXT or DATA for the input files.subtrees- aListofSubtreeobjects.- Throws:
IllegalArgumentException- ifListofSubtree's orSubtreeModeis invalid.
-
SubtreeProcessingMode
Initialises aSubtreeProcessingModewith the given parameters.- Parameters:
defaultMode- default mode TEXT or DATA for the input files.- Throws:
IllegalArgumentException- ifSubtreeModeis null.
-
SubtreeProcessingMode
Initialises aSubtreeProcessingModewith the given parameters.- Parameters:
subtrees- aListofSubtreeobjects.- Throws:
IllegalArgumentException- ifListofSubtree's is invalid.
-
-
Method Details
-
getDefaultMode
Gets the default mode for subtree processing.- Returns:
- default mode currently set.
-
setDefaultMode
Sets the default mode for subtree processing.- Parameters:
defaultType- default mode TEXT or DATA for the input files.- Throws:
IllegalArgumentException- ifSubtreeModeis null.
-
getSubtrees
-
setSubtrees
- Parameters:
subtrees- aListofSubtreeobjects.- Throws:
IllegalArgumentException- ifListofSubtree's is invalid.
-
addSubtree
- Parameters:
subtree- aSubtreeto be added to the existingListofSubtreeobjects.- Throws:
IllegalArgumentException- ifSubtreeis null.
-