KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > xml > crypto > dsig > SignatureProperty


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

4 /*
5  * $Id: SignatureProperty.java,v 1.4 2005/05/10 16:03:46 mullan Exp $
6  */

7 package javax.xml.crypto.dsig;
8
9 import javax.xml.crypto.XMLStructure;
10 import java.util.List JavaDoc;
11
12 /**
13  * A representation of the XML <code>SignatureProperty</code> element as
14  * defined in the <a HREF="http://www.w3.org/TR/xmldsig-core/">
15  * W3C Recommendation for XML-Signature Syntax and Processing</a>.
16  * The XML Schema Definition is defined as:
17  * <pre><code>
18  *&lt;element name="SignatureProperty" type="ds:SignaturePropertyType"/&gt;
19  * &lt;complexType name="SignaturePropertyType" mixed="true"&gt;
20  * &lt;choice maxOccurs="unbounded"&gt;
21  * &lt;any namespace="##other" processContents="lax"/&gt;
22  * &lt;!-- (1,1) elements from (1, unbounded) namespaces --&gt;
23  * &lt;/choice&gt;
24  * &lt;attribute name="Target" type="anyURI" use="required"/&gt;
25  * &lt;attribute name="Id" type="ID" use="optional"/&gt;
26  * &lt;/complexType&gt;
27  * </code></pre>
28  *
29  * A <code>SignatureProperty</code> instance may be created by invoking the
30  * {@link XMLSignatureFactory#newSignatureProperty newSignatureProperty}
31  * method of the {@link XMLSignatureFactory} class; for example:
32  *
33  * <pre>
34  * XMLSignatureFactory factory = XMLSignatureFactory.getInstance("DOM");
35  * SignatureProperty property = factory.newSignatureProperty
36  * (Collections.singletonList(content), "#Signature-1", "TimeStamp");
37  * </pre>
38  *
39  * @author Sean Mullan
40  * @author JSR 105 Expert Group
41  * @since 1.6
42  * @see XMLSignatureFactory#newSignatureProperty(List, String, String)
43  * @see SignatureProperties
44  */

45 public interface SignatureProperty extends XMLStructure {
46
47     /**
48      * Returns the target URI of this <code>SignatureProperty</code>.
49      *
50      * @return the target URI of this <code>SignatureProperty</code> (never
51      * <code>null</code>)
52      */

53     String JavaDoc getTarget();
54
55     /**
56      * Returns the Id of this <code>SignatureProperty</code>.
57      *
58      * @return the Id of this <code>SignatureProperty</code> (or
59      * <code>null</code> if not specified)
60      */

61     String JavaDoc getId();
62     
63     /**
64      * Returns an {@link java.util.Collections#unmodifiableList unmodifiable
65      * list} of one or more {@link XMLStructure}s that are contained in
66      * this <code>SignatureProperty</code>. These represent additional
67      * information items concerning the generation of the {@link XMLSignature}
68      * (i.e. date/time stamp or serial numbers of cryptographic hardware used
69      * in signature generation).
70      *
71      * @return an unmodifiable list of one or more <code>XMLStructure</code>s
72      */

73     List JavaDoc getContent();
74 }
75
Popular Tags