Module java.xml
Package javax.xml

Class XMLConstants

java.lang.Object
javax.xml.XMLConstants

public final class XMLConstants extends Object
Defines constants for XML Processing APIs.

External Access Properties

The value of the external access properties, including ACCESS_EXTERNAL_DTD, ACCESS_EXTERNAL_SCHEMA, and ACCESS_EXTERNAL_STYLESHEET, is defined as follows.

Value:

A list of protocols separated by comma. A protocol is the scheme portion of a URI, or in the case of the JAR protocol, "jar" plus the scheme portion separated by colon. A scheme is defined as:
scheme = alpha *( alpha | digit | "+" | "-" | "." )
where alpha = a-z and A-Z.

And the JAR protocol:
jar[:scheme]

Protocols including the keyword "jar" are case-insensitive. Any whitespaces as defined by Character.isSpaceChar(char) in the value will be ignored. Examples of protocols are file, http, jar:file.

Default value:

The default value is implementation specific and therefore not specified. The following options are provided for consideration:
  • an empty string to deny all access to external references;
  • a specific protocol, such as file, to give permission to only the protocol;
  • the keyword "all" to grant permission to all protocols.

When FEATURE_SECURE_PROCESSING is enabled, it is recommended that implementations restrict external connections by default, though this may cause problems for applications that process XML/XSD/XSL with external references.

Granting all access:

The keyword "all" grants permission to all protocols.

Property Precedence

Properties, including the External Access Properties and USE_CATALOG, can be specified through multiple configuration sources. They follow the configuration process as defined in the Configuration section of the module summary.
Since:
1.5
See Also: