KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > xml > transform > URIResolver


1 /*
2  * @(#)URIResolver.java 1.13 04/07/26
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7 package javax.xml.transform;
8
9 /**
10  * <p>An object that implements this interface that can be called by the processor
11  * to turn a URI used in document(), xsl:import, or xsl:include into a Source object.
12  */

13 public interface URIResolver {
14
15     /**
16      * Called by the processor when it encounters
17      * an xsl:include, xsl:import, or document() function.
18      *
19      * @param href An href attribute, which may be relative or absolute.
20      * @param base The base URI against which the first argument will be made
21      * absolute if the absolute URI is required.
22      *
23      * @return A Source object, or null if the href cannot be resolved,
24      * and the processor should try to resolve the URI itself.
25      *
26      * @throws TransformerException if an error occurs when trying to
27      * resolve the URI.
28      */

29     public Source JavaDoc resolve(String JavaDoc href, String JavaDoc base)
30         throws TransformerException JavaDoc;
31 }
32
Popular Tags