|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.icl.saxon.StandardURIResolver
This class provides the service of converting a URI into an InputSource. It is used to get stylesheet modules referenced by xsl:import and xsl:include, and source documents referenced by the document() function. The standard version handles anything that the java URL class will handle. You can write a subclass to handle other kinds of URI, e.g. references to things in a database.
Constructor Summary | |
StandardURIResolver()
|
Method Summary | |
org.w3c.dom.Node |
getDOMNode()
This will be called by the processor when it encounters an xsl:include, xsl:import, or document() function, if it needs a DOM tree. |
org.xml.sax.InputSource |
getInputSource()
Return an InputSource corresponding to the URL |
java.lang.String |
getURI()
Get the absolute URI |
org.xml.sax.XMLReader |
getXMLReader()
Return a SAX2 Parser to be used with this InputSource. |
void |
setParserClass(java.lang.String name)
Set the name of the class to be used for parsing |
void |
setURI(java.lang.String baseURI,
java.lang.String uri)
Set a relative URI, given a base URI to resolve it |
protected static java.net.URL |
toURL(java.lang.String systemID)
Parse an absolute URI |
protected static java.net.URL |
toURL(java.net.URL baseURL,
java.lang.String systemID)
Parse a relative URI |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StandardURIResolver()
Method Detail |
public void setParserClass(java.lang.String name)
public void setURI(java.lang.String baseURI, java.lang.String uri) throws TransformException
setURI
in interface URIResolver
baseURI
- The base URI that should be used. May be null if uri is absolute.public java.lang.String getURI()
getURI
in interface URIResolver
public org.w3c.dom.Node getDOMNode()
getDOMNode
in interface URIResolver
base
- The base URI that should be used.uri
- Value from an xsl:import or xsl:include's href attribute,
or a URI specified in the document() function.public org.xml.sax.InputSource getInputSource()
getInputSource
in interface URIResolver
public org.xml.sax.XMLReader getXMLReader() throws TransformException
getXMLReader
in interface URIResolver
protected static java.net.URL toURL(java.lang.String systemID) throws TransformException
protected static java.net.URL toURL(java.net.URL baseURL, java.lang.String systemID) throws TransformException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |