public interface RelativeURIResolver extends URIResolver
Modifier and Type | Method and Description |
---|---|
Source |
dereference(String uri)
Called by the processor when it encounters
an xsl:include, xsl:import, or document() function.
|
String |
makeAbsolute(String href,
String base)
Create an absolute URI from a relative URI and a base URI.
|
Source |
resolve(String href,
String base)
Called by the processor when it encounters
an xsl:include, xsl:import, or document() function.
|
String makeAbsolute(String href, String base) throws TransformerException
href
- A relative or absolute URI, to be resolved against the specified base URIbase
- The base URI against which the first argument will be made
absolute if the absolute URI is required.resolve
method.TransformerException
- if any failure occursSource dereference(String uri) throws TransformerException
uri
- The absolute URI to be dereferencedTransformerException
- if an error occurs when trying to
resolve the URI.Source resolve(String href, String base) throws TransformerException
Despite the name, the main purpose of this method is to dereference the URI, not merely to resolve it.
This method is provided because it is required by the interface. When using a RelativeURIResolver,
the single-argument dereference() method is preferred. The result of calling this method should be the
same as the result of calling dereference(makeAbsolute(href, base))
resolve
in interface URIResolver
href
- An href attribute, which may be relative or absolute.base
- The base URI against which the first argument will be made
absolute if the absolute URI is required.TransformerException
- if an error occurs when trying to
resolve the URI.Copyright (c) 2004-2014 Saxonica Limited. All rights reserved.