org.apache.jcp.xml.dsig.internal.dom
Class DOMSignatureProperties

java.lang.Object
  extended by org.apache.jcp.xml.dsig.internal.dom.DOMStructure
      extended by org.apache.jcp.xml.dsig.internal.dom.DOMSignatureProperties
All Implemented Interfaces:
SignatureProperties, XMLStructure

public final class DOMSignatureProperties
extends DOMStructure
implements SignatureProperties

DOM-based implementation of SignatureProperties.

Author:
Sean Mullan

Field Summary
 
Fields inherited from interface javax.xml.crypto.dsig.SignatureProperties
TYPE
 
Constructor Summary
DOMSignatureProperties(Element propsElem, XMLCryptoContext context)
          Creates a DOMSignatureProperties from an element.
DOMSignatureProperties(List<? extends SignatureProperty> properties, String id)
          Creates a DOMSignatureProperties from the specified parameters.
 
Method Summary
 boolean equals(Object o)
           
 String getId()
          Returns the Id of this SignatureProperties.
 List getProperties()
          Returns an unmodifiable list of one or more SignaturePropertys that are contained in this SignatureProperties.
 int hashCode()
           
 void marshal(Node parent, String dsPrefix, DOMCryptoContext context)
           
 
Methods inherited from class org.apache.jcp.xml.dsig.internal.dom.DOMStructure
isFeatureSupported
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.xml.crypto.XMLStructure
isFeatureSupported
 

Constructor Detail

DOMSignatureProperties

public DOMSignatureProperties(List<? extends SignatureProperty> properties,
                              String id)
Creates a DOMSignatureProperties from the specified parameters.

Parameters:
properties - a list of one or more SignaturePropertys. The list is defensively copied to protect against subsequent modification.
id - the Id (may be null)
Throws:
ClassCastException - if properties contains any entries that are not of type SignatureProperty
IllegalArgumentException - if properties is empty
NullPointerException - if properties

DOMSignatureProperties

public DOMSignatureProperties(Element propsElem,
                              XMLCryptoContext context)
                       throws MarshalException
Creates a DOMSignatureProperties from an element.

Parameters:
propsElem - a SignatureProperties element
Throws:
MarshalException - if a marshalling error occurs
Method Detail

getProperties

public List getProperties()
Description copied from interface: SignatureProperties
Returns an unmodifiable list of one or more SignaturePropertys that are contained in this SignatureProperties.

Specified by:
getProperties in interface SignatureProperties
Returns:
an unmodifiable list of one or more SignaturePropertys

getId

public String getId()
Description copied from interface: SignatureProperties
Returns the Id of this SignatureProperties.

Specified by:
getId in interface SignatureProperties
Returns:
the Id of this SignatureProperties (or null if not specified)

marshal

public void marshal(Node parent,
                    String dsPrefix,
                    DOMCryptoContext context)
             throws MarshalException
Specified by:
marshal in class DOMStructure
Throws:
MarshalException

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2000–2014 The Apache Software Foundation. All rights reserved.