Sophie

Sophie

distrib > Mageia > 7 > armv7hl > by-pkgid > b3bdfe6d859a3d6920ff2c44b38e9a6f > files > 2208

saxon-manual-9.4.0.9-2.mga7.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_18) on Fri Dec 09 20:48:20 GMT 2011 -->
<TITLE>
RelativeURIResolver
</TITLE>

<META NAME="date" CONTENT="2011-12-09">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">

<SCRIPT type="text/javascript">
function windowTitle()
{
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="RelativeURIResolver";
    }
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>

</HEAD>

<BODY BGCOLOR="white" onload="windowTitle();">
<HR>


<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../net/sf/saxon/lib/ParseOptions.html" title="class in net.sf.saxon.lib"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../net/sf/saxon/lib/SaxonOutputKeys.html" title="class in net.sf.saxon.lib"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html?net/sf/saxon/lib/RelativeURIResolver.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="RelativeURIResolver.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
net.sf.saxon.lib</FONT>
<BR>
Interface RelativeURIResolver</H2>
<DL>
<DT><B>All Superinterfaces:</B> <DD><A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/URIResolver.html?is-external=true" title="class or interface in javax.xml.transform">URIResolver</A></DD>
</DL>
<HR>
<DL>
<DT><PRE>public interface <B>RelativeURIResolver</B><DT>extends <A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/URIResolver.html?is-external=true" title="class or interface in javax.xml.transform">URIResolver</A></DL>
</PRE>

<P>
The standard JAXP URIResolver is given a relative URI and a base URI and returns the resource
 identified by this combination. However, to support a stable implementation of the doc() function,
 Saxon needs to know what the absolute URI is before the resource is fetched, so it can determine whether
 a document with that absolute URI actually exists.
 <p>
 This extended interface defines a URIResolver that separates the two functions of resolving a relative URI
 against a base URI, and fetching a resource with that absolute URI. If the URI resolver supplied to Saxon
 implements this interface, the absolute URI associated with a loaded document will be the URI returned by
 this resolver.
 <p>
 The particular motivation for providing this interface is to allow a URIResolver to wrap a .NET XmlResolver,
 which has additional capability not present in the JAXP interface.
<P>

<P>
<HR>

<P>

<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/Source.html?is-external=true" title="class or interface in javax.xml.transform">Source</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/lib/RelativeURIResolver.html#dereference(java.lang.String)">dereference</A></B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;uri)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Called by the processor when it encounters
 an xsl:include, xsl:import, or document() function.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/lib/RelativeURIResolver.html#makeAbsolute(java.lang.String, java.lang.String)">makeAbsolute</A></B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;href,
             <A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;base)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create an absolute URI from a relative URI and a base URI.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/Source.html?is-external=true" title="class or interface in javax.xml.transform">Source</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/lib/RelativeURIResolver.html#resolve(java.lang.String, java.lang.String)">resolve</A></B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;href,
        <A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;base)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Called by the processor when it encounters
 an xsl:include, xsl:import, or document() function.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/lib/RelativeURIResolver.html#setExpectedMediaType(java.lang.String)">setExpectedMediaType</A></B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;mediaType)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Specify the media type of the resource that is expected to be delivered.</TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="makeAbsolute(java.lang.String, java.lang.String)"><!-- --></A><H3>
makeAbsolute</H3>
<PRE>
<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>makeAbsolute</B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;href,
                    <A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;base)
                    throws <A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/TransformerException.html?is-external=true" title="class or interface in javax.xml.transform">TransformerException</A></PRE>
<DL>
<DD>Create an absolute URI from a relative URI and a base URI. This method performs the
 process which is correctly called "URI resolution": this is purely a syntactic operation
 on the URI strings, and does not retrieve any resources.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>href</CODE> - A relative or absolute URI, to be resolved against the specified base URI<DD><CODE>base</CODE> - The base URI against which the first argument will be made
 absolute if the absolute URI is required.
<DT><B>Returns:</B><DD>A string containing the absolute URI that results from URI resolution. If the resource
 needs to be fetched, this absolute URI will be supplied as the href parameter in a subsequent
 call to the <code>resolve</code> method.
<DT><B>Throws:</B>
<DD><CODE><A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/TransformerException.html?is-external=true" title="class or interface in javax.xml.transform">TransformerException</A></CODE> - if any failure occurs</DL>
</DD>
</DL>
<HR>

<A NAME="dereference(java.lang.String)"><!-- --></A><H3>
dereference</H3>
<PRE>
<A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/Source.html?is-external=true" title="class or interface in javax.xml.transform">Source</A> <B>dereference</B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;uri)
                   throws <A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/TransformerException.html?is-external=true" title="class or interface in javax.xml.transform">TransformerException</A></PRE>
<DL>
<DD>Called by the processor when it encounters
 an xsl:include, xsl:import, or document() function.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>uri</CODE> - The absolute URI to be dereferenced
<DT><B>Returns:</B><DD>A Source object, or null if the href cannot be dereferenced,
 and the processor should try to resolve the URI itself.
<DT><B>Throws:</B>
<DD><CODE><A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/TransformerException.html?is-external=true" title="class or interface in javax.xml.transform">TransformerException</A></CODE> - if an error occurs when trying to
 resolve the URI.</DL>
</DD>
</DL>
<HR>

<A NAME="resolve(java.lang.String, java.lang.String)"><!-- --></A><H3>
resolve</H3>
<PRE>
<A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/Source.html?is-external=true" title="class or interface in javax.xml.transform">Source</A> <B>resolve</B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;href,
               <A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;base)
               throws <A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/TransformerException.html?is-external=true" title="class or interface in javax.xml.transform">TransformerException</A></PRE>
<DL>
<DD>Called by the processor when it encounters
 an xsl:include, xsl:import, or document() function.

 <p>Despite the name, the main purpose of this method is to dereference the URI, not merely
 to resolve it.</p>

 <p>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 <code>dereference(makeAbsolute(href, base))</code></p>
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/URIResolver.html?is-external=true#resolve(java.lang.String, java.lang.String)" title="class or interface in javax.xml.transform">resolve</A></CODE> in interface <CODE><A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/URIResolver.html?is-external=true" title="class or interface in javax.xml.transform">URIResolver</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>href</CODE> - An href attribute, which may be relative or absolute.<DD><CODE>base</CODE> - The base URI against which the first argument will be made
 absolute if the absolute URI is required.
<DT><B>Returns:</B><DD>A Source object, or null if the href cannot be resolved,
 and the processor should try to resolve the URI itself.
<DT><B>Throws:</B>
<DD><CODE><A HREF="http://download.oracle.com/javase/6/docs/api/javax/xml/transform/TransformerException.html?is-external=true" title="class or interface in javax.xml.transform">TransformerException</A></CODE> - if an error occurs when trying to
 resolve the URI.</DL>
</DD>
</DL>
<HR>

<A NAME="setExpectedMediaType(java.lang.String)"><!-- --></A><H3>
setExpectedMediaType</H3>
<PRE>
void <B>setExpectedMediaType</B>(<A HREF="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;mediaType)</PRE>
<DL>
<DD>Specify the media type of the resource that is expected to be delivered. This information is
 supplied by the processor primarily to indicate whether the URIResolver is allowed to return
 an XML tree already parsed. If the value is "text/plain" then the Source returned by the
 resolve() method should be a StreamSource.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>mediaType</CODE> - the expected media type</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>


<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../net/sf/saxon/lib/ParseOptions.html" title="class in net.sf.saxon.lib"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../net/sf/saxon/lib/SaxonOutputKeys.html" title="class in net.sf.saxon.lib"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html?net/sf/saxon/lib/RelativeURIResolver.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="RelativeURIResolver.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->

<HR>
Copyright (c) 2004-2011 Saxonica Limited. All rights reserved.
</BODY>
</HTML>