| |
|
| java.lang.Object javax.xml.crypto.dom.DOMCryptoContext
All known Subclasses: javax.xml.crypto.dsig.dom.DOMValidateContext, javax.xml.crypto.dsig.dom.DOMSignContext,
DOMCryptoContext | public class DOMCryptoContext implements XMLCryptoContext(Code) | | This class provides a DOM-specific implementation of the
XMLCryptoContext interface. It also includes additional
methods that are specific to a DOM-based implementation for registering
and retrieving elements that contain attributes of type ID.
author: Sean Mullan author: JSR 105 Expert Group since: 1.6 |
DOMCryptoContext | protected DOMCryptoContext()(Code) | | Default constructor. (For invocation by subclass constructors).
|
get | public Object get(Object key)(Code) | | This implementation uses an internal
HashMap to get the object
that the specified key maps to.
|
getDefaultNamespacePrefix | public String getDefaultNamespacePrefix()(Code) | | |
getElementById | public Element getElementById(String idValue)(Code) | | Returns the Element with the specified ID attribute value.
This implementation uses an internal
HashMap to get the
element that the specified attribute value maps to.
Parameters: idValue - the value of the ID the Element with the specified ID attribute value,or null if none. throws: NullPointerException - if idValue is null See Also: DOMCryptoContext.setIdAttributeNS |
getNamespacePrefix | public String getNamespacePrefix(String namespaceURI, String defaultPrefix)(Code) | | This implementation uses an internal
HashMap to get the prefix
that the specified URI maps to. It returns the defaultPrefix
if it maps to null .
throws: NullPointerException - |
iterator | public Iterator iterator()(Code) | | Returns a read-only iterator over the set of Id/Element mappings of
this DOMCryptoContext . Attempts to modify the set via the
Iterator.remove method throw an
UnsupportedOperationException . The mappings are returned
in no particular order. Each element in the iteration is represented as a
java.util.Map.Entry . If the DOMCryptoContext is
modified while an iteration is in progress, the results of the
iteration are undefined.
a read-only iterator over the set of mappings |
setDefaultNamespacePrefix | public void setDefaultNamespacePrefix(String defaultPrefix)(Code) | | |
setIdAttributeNS | public void setIdAttributeNS(Element element, String namespaceURI, String localName)(Code) | | Registers the element's attribute specified by the namespace URI and
local name to be of type ID. The attribute must have a non-empty value.
This implementation uses an internal
HashMap to map the
attribute's value to the specified element.
Parameters: element - the element Parameters: namespaceURI - the namespace URI of the attribute (specifynull if not applicable) Parameters: localName - the local name of the attribute throws: IllegalArgumentException - if localName is not anattribute of the specified element or it does not contain a specificvalue throws: NullPointerException - if element orlocalName is null See Also: DOMCryptoContext.getElementById |
|
|
|