Enum Class PreservationProcessingMode
- All Implemented Interfaces:
Serializable,Comparable<PreservationProcessingMode>,Constable
Represents the behaviour required when outputting preserved lexical items which have changed.
If Lexical Preservation is used to keep hold of items such as Doctype declarations, comments, processing instructions etc, you must choose whether or not to convert these items back from the XML encoded form into their original form in the result. If you wish to convert them back to their original form (i.e. not encoded in XML elements), you must decide which version of any changed items you are going to use. This enumeration stored the possible values to use when making these decisions.
- Since:
- 7.0
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionKeep the A version.Keep the A version if it exists, otherwise keep the B version.Use the default ProcessingMode.Keep the B version.Keep the B version if it exists, otherwise keep the A version.Do not process at this point. -
Method Summary
Modifier and TypeMethodDescriptionstatic PreservationProcessingModegetProcessingMode(String val) Returns a ProcessingMode object from the supplied String value if appropriate.toString()The string representation of the enumerated type constants.static PreservationProcessingModeReturns the enum constant of this class with the specified name.static PreservationProcessingMode[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, valueOf
-
Enum Constant Details
-
A
Keep the A version. -
B
Keep the B version. -
AB
Keep the A version if it exists, otherwise keep the B version. -
BA
Keep the B version if it exists, otherwise keep the A version. -
AdB
-
BdA
-
AUTOMATIC
Use the default ProcessingMode. -
CHANGE
Do not process at this point. If items have not been processed earlier in the pipeline then this effectively chooses to leave any changes present in the result in the encoded form.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
toString
The string representation of the enumerated type constants. Here, the strings are the same as the enumerated types except for 'AUTOMATIC' and 'CHANGE' whose string representations are 'auto' and 'skip' respectively.- Overrides:
toStringin classEnum<PreservationProcessingMode>- Returns:
- The string representation of the enumerated type constants.
-
getProcessingMode
Returns a ProcessingMode object from the supplied String value if appropriate.
This method should not be used under normal circumstances, enum instance values should be used instead.
- Parameters:
val- a String representation of a ProcessingMode value or null for the default value- Returns:
- the ProcessingMode instance corresponding to the parameter, or null if the value is invalid
-