public enum PreservationProcessingMode extends java.lang.Enum<PreservationProcessingMode>
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.
Enum Constant and Description |
---|
A
Keep the A version.
|
AB
Keep the A version if it exists, otherwise keep the B version.
|
AdB
Same as
PreservationProcessingMode.A , except when handling internal subset declarations which are treated as PreservationProcessingMode.AB . |
AUTOMATIC
Use the default ProcessingMode.
|
B
Keep the B version.
|
BA
Keep the B version if it exists, otherwise keep the A version.
|
BdA
Same as
PreservationProcessingMode.B , except when handling internal subset declarations which are treated as PreservationProcessingMode.BA . |
CHANGE
Do not process at this point.
|
Modifier and Type | Method and Description |
---|---|
static PreservationProcessingMode |
getProcessingMode(java.lang.String val)
Returns a ProcessingMode object from the supplied String value if appropriate.
|
java.lang.String |
toString()
The string representation of the enumerated type constants.
|
static PreservationProcessingMode |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static PreservationProcessingMode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PreservationProcessingMode A
public static final PreservationProcessingMode B
public static final PreservationProcessingMode AB
public static final PreservationProcessingMode BA
public static final PreservationProcessingMode AdB
PreservationProcessingMode.A
, except when handling internal subset declarations which are treated as PreservationProcessingMode.AB
.public static final PreservationProcessingMode BdA
PreservationProcessingMode.B
, except when handling internal subset declarations which are treated as PreservationProcessingMode.BA
.public static final PreservationProcessingMode AUTOMATIC
public static final PreservationProcessingMode CHANGE
public static PreservationProcessingMode[] values()
for (PreservationProcessingMode c : PreservationProcessingMode.values()) System.out.println(c);
public static PreservationProcessingMode valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic java.lang.String toString()
toString
in class java.lang.Enum<PreservationProcessingMode>
public static PreservationProcessingMode getProcessingMode(java.lang.String val)
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.
val
- a String representation of a ProcessingMode value or null for the default value