Class SimpleContainer
- All Implemented Interfaces:
Serializable
,SourceLocator
,Container
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
Return the character position where the current document event ends.int
Get the granularity of the container.Get the Executable (representing a complete stylesheet or query) of which this Container forms partint
Get the host language (XSLT, XQuery, XPath) used to implement the code in this containerint
Return the line number where the current document event ends.Get the LocationProvider allowing location identifiers to be resolved.Return the public identifier for the current document event.Return the system identifier for the current document event.void
setLocation
(String systemId, int lineNumber) Set location information if available
-
Constructor Details
-
SimpleContainer
-
-
Method Details
-
setLocation
Set location information if available- Parameters:
systemId
- the system IdlineNumber
- the line number
-
getExecutable
Get the Executable (representing a complete stylesheet or query) of which this Container forms part- Specified by:
getExecutable
in interfaceContainer
- Returns:
- the executable
-
getLocationProvider
Get the LocationProvider allowing location identifiers to be resolved.- Specified by:
getLocationProvider
in interfaceContainer
- Returns:
- the location provider
-
getHostLanguage
public int getHostLanguage()Get the host language (XSLT, XQuery, XPath) used to implement the code in this container- Specified by:
getHostLanguage
in interfaceContainer
- Returns:
- typically
Configuration.XSLT
orConfiguration.XQUERY
-
getContainerGranularity
public int getContainerGranularity()Get the granularity of the container. During successive phases of compilation, growing expression trees are rooted in containers of increasing granularity. The granularity of the container is used to avoid "repotting" a tree more frequently than is required, as this requires a complete traversal of the tree which can take a measurable time.- Specified by:
getContainerGranularity
in interfaceContainer
- Returns:
- 0 for a temporary container created during parsing; 1 for a container that operates at the level of an XPath expression; 2 for a container at the level of a global function or template
-
getPublicId
Return the public identifier for the current document event.The return value is the public identifier of the document entity or of the external parsed entity in which the markup that triggered the event appears.
- Specified by:
getPublicId
in interfaceSourceLocator
- Returns:
- A string containing the public identifier, or null if none is available.
- See Also:
-
getSystemId
Return the system identifier for the current document event.The return value is the system identifier of the document entity or of the external parsed entity in which the markup that triggered the event appears.
If the system identifier is a URL, the parser must resolve it fully before passing it to the application.
- Specified by:
getSystemId
in interfaceSourceLocator
- Returns:
- A string containing the system identifier, or null if none is available.
- See Also:
-
getLineNumber
public int getLineNumber()Return the line number where the current document event ends.Warning: The return value from the method is intended only as an approximation for the sake of error reporting; it is not intended to provide sufficient information to edit the character content of the original XML document.
The return value is an approximation of the line number in the document entity or external parsed entity where the markup that triggered the event appears.
- Specified by:
getLineNumber
in interfaceSourceLocator
- Returns:
- The line number, or -1 if none is available.
- See Also:
-
getColumnNumber
public int getColumnNumber()Return the character position where the current document event ends.Warning: The return value from the method is intended only as an approximation for the sake of error reporting; it is not intended to provide sufficient information to edit the character content of the original XML document.
The return value is an approximation of the column number in the document entity or external parsed entity where the markup that triggered the event appears.
- Specified by:
getColumnNumber
in interfaceSourceLocator
- Returns:
- The column number, or -1 if none is available.
- See Also:
-