com.ctc.wstx.cfg
Interface InputConfigFlags

All Known Implementing Classes:
DTDElement, ElementValidator, InputElementStack, MinimalInputFactory, ReaderConfig, StreamScanner, WstxInputFactory

public interface InputConfigFlags

Constant interface that contains configuration flag used by parser and parser factory, as well as some other input constants.


Field Summary
static int CFG_CACHE_DTDS
          If true, input factory is allowed cache parsed external DTD subsets, potentially speeding up things for which DTDs are needed for: entity substitution, attribute defaulting, and of course DTD-based validation.
static int CFG_COALESCE_TEXT
           
static int CFG_INTERN_NS_URIS
          It true, will call intern() on all namespace URIs parsed; otherwise will just use 'regular' Strings created from parsed contents.
static int CFG_LAZY_PARSING
          If true, input factory can defer parsing of nodes until data is actually needed; if false, it has to read all the data in right away when next type is requested.
static int CFG_NAMESPACE_AWARE
          If true, parser will handle namespaces according to XML specs; if false, will only pass them as part of element/attribute name value information.
static int CFG_NORMALIZE_ATTR_VALUES
          If true, will do attribute value normalization as explained in XML specs; if false, will leave values as they are in input (including not converting linefeeds).
static int CFG_NORMALIZE_LFS
          If true, will convert all 'alien' linefeeds (\r\n, \r) to standard linefeed char (\n), in content like text, CDATA, processing instructions and comments.
static int CFG_PRESERVE_LOCATION
          Property that determines whether Event objects created will contain (accurate) Location information or not.
static int CFG_REPLACE_ENTITY_REFS
          Flag that enables automatic replacement of internal entities
static int CFG_REPORT_ALL_TEXT_AS_CHARACTERS
          If true, parser will report CDATA and SPACE events as CHARACTERS, independent of coalescing settings.
static int CFG_REPORT_PROLOG_WS
          If true, parser will report (ignorable) white space events in prolog and epilog; if false, it will silently ignore them.
static int CFG_SUPPORT_DTD
          Whether DTD handling is enabled or disabled; disabling means both internal and external subsets will just be skipped unprocessed.
static int CFG_SUPPORT_DTDPP
          If true, DTD-parser will recognize DTD++ features, and the validator will also use any such information found from DTD when DTD validation is enabled.
static int CFG_SUPPORT_EXTERNAL_ENTITIES
          ???.
static int CFG_VALIDATE_AGAINST_DTD
          Not yet (fully) supported; added as the placeholder
static int CFG_VALIDATE_TEXT_CHARS
          If true, will check that all characters in textual content of the document (content that is not part of markup; including content in CDATA, comments and processing instructions) are valid XML (1.1) characters.
static int CONTENT_ALLOW_DTD_ANY
          Content allowed to 'any' content specification type from DTD.
static int CONTENT_ALLOW_MIXED
           
static int CONTENT_ALLOW_NON_MIXED
           
static int CONTENT_ALLOW_NONE
           
static int CONTENT_ALLOW_UNDEFINED
          Dummy marker type; used to mark 'undefined' element entries; entries created as placeholders.
 

Field Detail

CFG_NAMESPACE_AWARE

public static final int CFG_NAMESPACE_AWARE
If true, parser will handle namespaces according to XML specs; if false, will only pass them as part of element/attribute name value information.

See Also:
Constant Field Values

CFG_COALESCE_TEXT

public static final int CFG_COALESCE_TEXT
See Also:
Constant Field Values

CFG_REPLACE_ENTITY_REFS

public static final int CFG_REPLACE_ENTITY_REFS
Flag that enables automatic replacement of internal entities

See Also:
Constant Field Values

CFG_SUPPORT_EXTERNAL_ENTITIES

public static final int CFG_SUPPORT_EXTERNAL_ENTITIES
???.

What does this option really mean?

See Also:
Constant Field Values

CFG_SUPPORT_DTD

public static final int CFG_SUPPORT_DTD
Whether DTD handling is enabled or disabled; disabling means both internal and external subsets will just be skipped unprocessed.

See Also:
Constant Field Values

CFG_VALIDATE_AGAINST_DTD

public static final int CFG_VALIDATE_AGAINST_DTD
Not yet (fully) supported; added as the placeholder

See Also:
Constant Field Values

CFG_NORMALIZE_LFS

public static final int CFG_NORMALIZE_LFS
If true, will convert all 'alien' linefeeds (\r\n, \r) to standard linefeed char (\n), in content like text, CDATA, processing instructions and comments. If false, will leave linefeeds as they were.

Note: not normalizing linefeeds is against XML 1.0 specs

See Also:
Constant Field Values

CFG_NORMALIZE_ATTR_VALUES

public static final int CFG_NORMALIZE_ATTR_VALUES
If true, will do attribute value normalization as explained in XML specs; if false, will leave values as they are in input (including not converting linefeeds).

Note: not normalizing attribute values is against XML 1.0 specs

See Also:
Constant Field Values

CFG_INTERN_NS_URIS

public static final int CFG_INTERN_NS_URIS
It true, will call intern() on all namespace URIs parsed; otherwise will just use 'regular' Strings created from parsed contents. Interning makes namespace-based access faster, but has initial overhead of intern() call.

See Also:
Constant Field Values

CFG_REPORT_ALL_TEXT_AS_CHARACTERS

public static final int CFG_REPORT_ALL_TEXT_AS_CHARACTERS
If true, parser will report CDATA and SPACE events as CHARACTERS, independent of coalescing settings.

See Also:
Constant Field Values

CFG_REPORT_PROLOG_WS

public static final int CFG_REPORT_PROLOG_WS
If true, parser will report (ignorable) white space events in prolog and epilog; if false, it will silently ignore them.

See Also:
Constant Field Values

CFG_VALIDATE_TEXT_CHARS

public static final int CFG_VALIDATE_TEXT_CHARS
If true, will check that all characters in textual content of the document (content that is not part of markup; including content in CDATA, comments and processing instructions) are valid XML (1.1) characters. If false, will accept all Unicode characters outside of ones signalling markup in the context.

!!! TBI.

See Also:
Constant Field Values

CFG_CACHE_DTDS

public static final int CFG_CACHE_DTDS
If true, input factory is allowed cache parsed external DTD subsets, potentially speeding up things for which DTDs are needed for: entity substitution, attribute defaulting, and of course DTD-based validation.

See Also:
Constant Field Values

CFG_LAZY_PARSING

public static final int CFG_LAZY_PARSING
If true, input factory can defer parsing of nodes until data is actually needed; if false, it has to read all the data in right away when next type is requested. Setting it to true is good for performance, in the cases where some of the nodes (like comments, processing instructions, or whole subtrees) are ignored. Otherwise setting will not make much of a difference. Downside is that error reporting is also done 'lazily'; not right away when getting the next even type but when either accessing data, or skipping it.

See Also:
Constant Field Values

CFG_PRESERVE_LOCATION

public static final int CFG_PRESERVE_LOCATION
Property that determines whether Event objects created will contain (accurate) Location information or not. If not, Location may be null or a fixed location (beginning of main XML file).

Note, however, that the underlying parser will still keep track of location information for error reporting purposes; it's only Event objects that are affected.

See Also:
Constant Field Values

CFG_SUPPORT_DTDPP

public static final int CFG_SUPPORT_DTDPP
If true, DTD-parser will recognize DTD++ features, and the validator will also use any such information found from DTD when DTD validation is enabled.

See Also:
Constant Field Values

CONTENT_ALLOW_NONE

public static final int CONTENT_ALLOW_NONE
See Also:
Constant Field Values

CONTENT_ALLOW_NON_MIXED

public static final int CONTENT_ALLOW_NON_MIXED
See Also:
Constant Field Values

CONTENT_ALLOW_DTD_ANY

public static final int CONTENT_ALLOW_DTD_ANY
Content allowed to 'any' content specification type from DTD. This is NOT the same as more generic 'whatever' implied by non-validating parser, now even 'mixed' content spec. According to XML specs it's actually bit more limiting...

See Also:
Constant Field Values

CONTENT_ALLOW_MIXED

public static final int CONTENT_ALLOW_MIXED
See Also:
Constant Field Values

CONTENT_ALLOW_UNDEFINED

public static final int CONTENT_ALLOW_UNDEFINED
Dummy marker type; used to mark 'undefined' element entries; entries created as placeholders.

See Also:
Constant Field Values