XMLSignContext. This class contains additional methods
to specify the location in a DOM tree where an XMLSignature
object is to be marshalled when generating the signature.
Note that DOMSignContext instances can contain
information and state specific to the XML signature structure it is
used with. The results are unpredictable if a
DOMSignContext is used with different signature structures
(for example, you should not use the same DOMSignContext
instance to sign two different XMLSignature objects).
Implementation Note
The JDK implementation supports the following properties that can be set
using the setProperty method.
org.jcp.xml.dsig.internal.dom.SignatureProvider: value
must be a Provider. If specified, the underlying Signature
will be instantiated from this provider.
jdk.xmldsig.SecureRandom: value must be a
SecureRandom. If specified, this object will be
used to initialize the underlying Signature during signing
using the Signature#initSign(PrivateKey, SecureRandom)
method.
| Access | Constructor and Description |
|---|---|
| public | DOMSignContext(Key
the signing key signingKey, Node the parent node parent)Creates a |
| public | DOMSignContext(Key
the signing key signingKey, Node the parent node parent, Node the next sibling node nextSibling)Creates a |
| public | DOMSignContext(KeySelector
the key selector ks, Node the parent node parent)Creates a |
| public | DOMSignContext(KeySelector
the key selector ks, Node the parent node parent, Node the next sibling node nextSibling)Creates a |
| Modifier and Type | Method and Description |
|---|---|
| public Node | Returns: the nextSibling node, ornull if not specified.Returns the nextSibling node. |
| public Node | |
| public void | setNextSibling(Node
the next sibling node. The marshalled
nextSibling)XMLSignature will be inserted immediately before this
node. Specify null to remove the current setting.Sets the next sibling node. |
| public void |
| nextSibling | back to summary |
|---|---|
| private Node nextSibling | |
| parent | back to summary |
|---|---|
| private Node parent | |
| DOMSignContext | back to summary |
|---|---|
| public DOMSignContext(Key signingKey, Node parent) Creates a
| |
| DOMSignContext | back to summary |
|---|---|
| public DOMSignContext(Key signingKey, Node parent, Node nextSibling) Creates a
| |
| DOMSignContext | back to summary |
|---|---|
| public DOMSignContext(KeySelector ks, Node parent) Creates a
| |
| DOMSignContext | back to summary |
|---|---|
| public DOMSignContext(KeySelector ks, Node parent, Node nextSibling) Creates a
| |
| getNextSibling | back to summary |
|---|---|
| public Node getNextSibling() Returns the nextSibling node.
| |
| getParent | back to summary |
|---|---|
| public Node getParent() Returns the parent node.
| |
| setNextSibling | back to summary |
|---|---|
| public void setNextSibling(Node nextSibling) Sets the next sibling node.
| |
| setParent | back to summary |
|---|---|
| public void setParent(Node parent) Sets the parent node.
| |