org.jcp.xml.dsig.internal.dom
Class DOMXMLSignature.DOMSignatureValue
java.lang.Object
org.jcp.xml.dsig.internal.dom.DOMStructure
org.jcp.xml.dsig.internal.dom.DOMXMLSignature.DOMSignatureValue
- All Implemented Interfaces:
- XMLSignature.SignatureValue, XMLStructure
- Enclosing class:
- DOMXMLSignature
public class DOMXMLSignature.DOMSignatureValue
- extends DOMStructure
- implements XMLSignature.SignatureValue
Method Summary |
boolean |
equals(java.lang.Object o)
|
java.lang.String |
getId()
Returns the optional Id attribute of this
SignatureValue , which permits this element to be
referenced from elsewhere. |
byte[] |
getValue()
Returns the signature value of this SignatureValue . |
int |
hashCode()
|
void |
marshal(org.w3c.dom.Node parent,
java.lang.String dsPrefix,
DOMCryptoContext context)
|
boolean |
validate(XMLValidateContext validateContext)
Validates the signature value. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
getId
public java.lang.String getId()
- Description copied from interface:
XMLSignature.SignatureValue
- Returns the optional
Id
attribute of this
SignatureValue
, which permits this element to be
referenced from elsewhere.
- Specified by:
getId
in interface XMLSignature.SignatureValue
- Returns:
- the
Id
attribute (may be null
if
not specified)
getValue
public byte[] getValue()
- Description copied from interface:
XMLSignature.SignatureValue
- Returns the signature value of this
SignatureValue
.
- Specified by:
getValue
in interface XMLSignature.SignatureValue
- Returns:
- the signature value (may be
null
if the
XMLSignature
has not been signed yet). Each
invocation of this method returns a new clone of the array to
prevent subsequent modification.
validate
public boolean validate(XMLValidateContext validateContext)
throws XMLSignatureException
- Description copied from interface:
XMLSignature.SignatureValue
- Validates the signature value. This method performs a
cryptographic validation of the signature calculated over the
SignedInfo
of the XMLSignature
.
This method only validates the signature the first
time it is invoked. On subsequent invocations, it returns a cached
result.
- Specified by:
validate
in interface XMLSignature.SignatureValue
- Parameters:
validateContext
- the validating context
- Returns:
true
if the signature was
validated successfully; false
otherwise
- Throws:
XMLSignatureException
- if an unexpected exception occurs while
validating the signature
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in class java.lang.Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
marshal
public void marshal(org.w3c.dom.Node parent,
java.lang.String dsPrefix,
DOMCryptoContext context)
throws MarshalException
- Specified by:
marshal
in class DOMStructure
- Throws:
MarshalException
Copyright © 2000-2014 The Apache Software Foundation. All Rights Reserved.