KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > xml > crypto > URIDereferencer


1 /*
2  * Portions copyright 2006 Sun Microsystems, Inc. All rights reserved.
3  */

4 /*
5  * ===========================================================================
6  *
7  * (C) Copyright IBM Corp. 2003 All Rights Reserved.
8  *
9  * ===========================================================================
10  */

11 /*
12  * $Id: URIDereferencer.java,v 1.5 2005/05/10 15:47:42 mullan Exp $
13  */

14 package javax.xml.crypto;
15
16 /**
17  * A dereferencer of {@link URIReference}s.
18  * <p>
19  * The result of dereferencing a <code>URIReference</code> is either an
20  * instance of {@link OctetStreamData} or {@link NodeSetData}. Unless the
21  * <code>URIReference</code> is a <i>same-document reference</i> as defined
22  * in section 4.2 of the W3C Recommendation for XML-Signature Syntax and
23  * Processing, the result of dereferencing the <code>URIReference</code>
24  * MUST be an <code>OctetStreamData</code>.
25  *
26  * @author Sean Mullan
27  * @author Joyce Leung
28  * @author JSR 105 Expert Group
29  * @since 1.6
30  * @see XMLCryptoContext#setURIDereferencer(URIDereferencer)
31  * @see XMLCryptoContext#getURIDereferencer
32  */

33 public interface URIDereferencer {
34
35     /**
36      * Dereferences the specified <code>URIReference</code> and returns the
37      * dereferenced data.
38      *
39      * @param uriReference the <code>URIReference</code>
40      * @param context an <code>XMLCryptoContext</code> that may
41      * contain additional useful information for dereferencing the URI. This
42      * implementation should dereference the specified
43      * <code>URIReference</code> against the context's <code>baseURI</code>
44      * parameter, if specified.
45      * @return the dereferenced data
46      * @throws NullPointerException if <code>uriReference</code> or
47      * <code>context</code> are <code>null</code>
48      * @throws URIReferenceException if an exception occurs while
49      * dereferencing the specified <code>uriReference</code>
50      */

51     Data dereference(URIReference uriReference, XMLCryptoContext context)
52     throws URIReferenceException;
53 }
54
Popular Tags