org.exolab.adaptx.xml

Class SAXURILocation

public final class SAXURILocation extends ObjectURILocation

An implementation of ObjectURILocation for a SAX XMLReader

Author: Keith Visco

Constructor Summary
SAXURILocation(XMLReader reader, InputSource source)
Creates a new SAXURILocation
Method Summary
StringgetAbsoluteURI()
Returns the absolute URI for this URILocation
StringgetBaseURI()
Returns the base location of this URILocation.
InputSourcegetInputSource()
Returns the InputSource for this SAXURILocation
ObjectgetObject()
Returns the Object from this ObjectURILocation.
ReadergetReader()
Returns the reader for this URILocation.
StringgetRelativeURI()
Returns the relative URI for this URILocation
XMLReadergetXMLReader()
Returns the SAX XMLReader for this URILocation, or null if not set.
StringtoString()
Returns the String representation of this URILocation.

Constructor Detail

SAXURILocation

public SAXURILocation(XMLReader reader, InputSource source)
Creates a new SAXURILocation

Method Detail

getAbsoluteURI

public String getAbsoluteURI()
Returns the absolute URI for this URILocation

Returns: the absolute URI for this URILocation

See Also: getRelativeURI getBaseURI

getBaseURI

public String getBaseURI()
Returns the base location of this URILocation. If this URILocation is an URL, the base location will be equivalent to the document base for the URL.

Returns: the base location of this URILocation

See Also: getAbsoluteURI getRelativeURI

getInputSource

public InputSource getInputSource()
Returns the InputSource for this SAXURILocation

Returns: the InputSource

getObject

public Object getObject()
Returns the Object from this ObjectURILocation.

This method will return the XMLReader

Returns: the Object from this ObjectURILocation

See Also: SAXURILocation

getReader

public Reader getReader()
Returns the reader for this URILocation.

This method may return null, if an XMLReader exists. Try getXMLReader first.

Returns: a Reader for the resource represented by this URILocation

Throws: java.io.FileNotFoundException java.io.IOException

getRelativeURI

public String getRelativeURI()
Returns the relative URI for this URILocation

Returns: the relative URI for this URILocation

See Also: getAbsoluteURI getBaseURI

getXMLReader

public XMLReader getXMLReader()
Returns the SAX XMLReader for this URILocation, or null if not set.

Returns: the SAX XMLReader for this URILocation

toString

public String toString()
Returns the String representation of this URILocation.

Returns: the String representation of this URILocation