Package com.adobe.internal.xmp.options
Class ParseOptions
- java.lang.Object
-
- com.adobe.internal.xmp.options.Options
-
- com.adobe.internal.xmp.options.ParseOptions
-
public final class ParseOptions extends Options
Options forXMPMetaFactory.parse(InputStream, ParseOptions)
.- Since:
- 24.01.2006
-
-
Field Summary
Fields Modifier and Type Field Description static int
ACCEPT_LATIN_1
If the input is not unicode, try to parse it as ISO-8859-1.static int
DISALLOW_DOCTYPE
Disallow DOCTYPE declarations to prevent entity expansion attacks.static int
FIX_CONTROL_CHARS
Convert ASCII control characters 0x01 - 0x1F (except tab, cr, and lf) to spaces.static int
OMIT_NORMALIZATION
Do not carry run the XMPNormalizer on a packet, leave it as it is.static int
REQUIRE_XMP_META
Require a surrounding "x:xmpmeta" element in the xml-document.static int
STRICT_ALIASING
Do not reconcile alias differences, throw an exception instead.
-
Constructor Summary
Constructors Constructor Description ParseOptions()
Sets the options to the default values.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
areXMPNodesLimited()
boolean
getAcceptLatin1()
boolean
getDisallowDoctype()
boolean
getFixControlChars()
boolean
getOmitNormalization()
boolean
getRequireXMPMeta()
boolean
getStrictAliasing()
java.util.Map<java.lang.String,java.lang.Integer>
getXMPNodesToLimit()
ParseOptions
setAcceptLatin1(boolean value)
ParseOptions
setDisallowDoctype(boolean value)
ParseOptions
setFixControlChars(boolean value)
ParseOptions
setOmitNormalization(boolean value)
ParseOptions
setRequireXMPMeta(boolean value)
ParseOptions
setStrictAliasing(boolean value)
ParseOptions
setXMPNodesToLimit(java.util.Map<java.lang.String,java.lang.Integer> nodeMap)
-
Methods inherited from class com.adobe.internal.xmp.options.Options
clear, containsAllOptions, containsOneOf, equals, getOptions, getOptionsString, hashCode, isExactly, setOption, setOptions, toString
-
-
-
-
Field Detail
-
REQUIRE_XMP_META
public static final int REQUIRE_XMP_META
Require a surrounding "x:xmpmeta" element in the xml-document.- See Also:
- Constant Field Values
-
STRICT_ALIASING
public static final int STRICT_ALIASING
Do not reconcile alias differences, throw an exception instead.- See Also:
- Constant Field Values
-
FIX_CONTROL_CHARS
public static final int FIX_CONTROL_CHARS
Convert ASCII control characters 0x01 - 0x1F (except tab, cr, and lf) to spaces.- See Also:
- Constant Field Values
-
ACCEPT_LATIN_1
public static final int ACCEPT_LATIN_1
If the input is not unicode, try to parse it as ISO-8859-1.- See Also:
- Constant Field Values
-
OMIT_NORMALIZATION
public static final int OMIT_NORMALIZATION
Do not carry run the XMPNormalizer on a packet, leave it as it is.- See Also:
- Constant Field Values
-
DISALLOW_DOCTYPE
public static final int DISALLOW_DOCTYPE
Disallow DOCTYPE declarations to prevent entity expansion attacks. Note: Slight performance loss when set- See Also:
- Constant Field Values
-
-
Method Detail
-
getRequireXMPMeta
public boolean getRequireXMPMeta()
- Returns:
- Returns the requireXMPMeta.
-
setRequireXMPMeta
public ParseOptions setRequireXMPMeta(boolean value)
- Parameters:
value
- the value to set- Returns:
- Returns the instance to call more set-methods.
-
getStrictAliasing
public boolean getStrictAliasing()
- Returns:
- Returns the strictAliasing.
-
setStrictAliasing
public ParseOptions setStrictAliasing(boolean value)
- Parameters:
value
- the value to set- Returns:
- Returns the instance to call more set-methods.
-
getFixControlChars
public boolean getFixControlChars()
- Returns:
- Returns the strictAliasing.
-
setFixControlChars
public ParseOptions setFixControlChars(boolean value)
- Parameters:
value
- the value to set- Returns:
- Returns the instance to call more set-methods.
-
getAcceptLatin1
public boolean getAcceptLatin1()
- Returns:
- Returns the strictAliasing.
-
setOmitNormalization
public ParseOptions setOmitNormalization(boolean value)
- Parameters:
value
- the value to set- Returns:
- Returns the instance to call more set-methods.
-
getOmitNormalization
public boolean getOmitNormalization()
- Returns:
- Returns the option "omit normalization".
-
setDisallowDoctype
public ParseOptions setDisallowDoctype(boolean value)
- Parameters:
value
- the value to set- Returns:
- Returns the instance to call more set-methods.
-
getDisallowDoctype
public boolean getDisallowDoctype()
- Returns:
- Returns the option "disallow DOCTYPE".
-
setAcceptLatin1
public ParseOptions setAcceptLatin1(boolean value)
- Parameters:
value
- the value to set- Returns:
- Returns the instance to call more set-methods.
-
areXMPNodesLimited
public boolean areXMPNodesLimited()
- Returns:
- Returns true if some XMP nodes have been limited.
-
setXMPNodesToLimit
public ParseOptions setXMPNodesToLimit(java.util.Map<java.lang.String,java.lang.Integer> nodeMap)
- Parameters:
nodeMap
- the Map with name of nodes and number-of-items to limit them to- Returns:
- Returns the instance to call more set-methods.
-
getXMPNodesToLimit
public java.util.Map<java.lang.String,java.lang.Integer> getXMPNodesToLimit()
- Returns:
- Returns Unmodifiable Map containing names oF XMP nodes to limit and number-of-items limit corresponding to the XMP nodes.
-
-