org.jcp.xml.dsig.internal.dom

Class DOMXMLObject

  • All Implemented Interfaces:
    javax.xml.crypto.dsig.XMLObject, javax.xml.crypto.XMLStructure


    public final class DOMXMLObject
    extends DOMStructure
    implements javax.xml.crypto.dsig.XMLObject
    DOM-based implementation of XMLObject.
    • Field Summary

      • Fields inherited from interface javax.xml.crypto.dsig.XMLObject

        TYPE
    • Constructor Summary

      Constructors 
      Constructor and Description
      DOMXMLObject(org.w3c.dom.Element objElem, javax.xml.crypto.XMLCryptoContext context, java.security.Provider provider)
      Creates an XMLObject from an element.
      DOMXMLObject(java.util.List<? extends javax.xml.crypto.XMLStructure> content, java.lang.String id, java.lang.String mimeType, java.lang.String encoding)
      Creates an XMLObject from the specified parameters.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      boolean equals(java.lang.Object o) 
      java.util.List getContent() 
      java.lang.String getEncoding() 
      java.lang.String getId() 
      java.lang.String getMimeType() 
      int hashCode() 
      void marshal(org.w3c.dom.Node parent, java.lang.String dsPrefix, javax.xml.crypto.dom.DOMCryptoContext context) 
      • 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

      • DOMXMLObject

        public DOMXMLObject(java.util.List<? extends javax.xml.crypto.XMLStructure> content,
                    java.lang.String id,
                    java.lang.String mimeType,
                    java.lang.String encoding)
        Creates an XMLObject from the specified parameters.
        Parameters:
        content - a list of XMLStructures. The list is defensively copied to protect against subsequent modification. May be null or empty.
        id - the Id (may be null)
        mimeType - the mime type (may be null)
        encoding - the encoding (may be null)
        Throws:
        java.lang.ClassCastException - if content contains any entries that are not of type XMLStructure
      • DOMXMLObject

        public DOMXMLObject(org.w3c.dom.Element objElem,
                    javax.xml.crypto.XMLCryptoContext context,
                    java.security.Provider provider)
                     throws javax.xml.crypto.MarshalException
        Creates an XMLObject from an element.
        Parameters:
        objElem - an Object element
        Throws:
        javax.xml.crypto.MarshalException - if there is an error when unmarshalling
    • Method Detail

      • getContent

        public java.util.List getContent()
        Specified by:
        getContent in interface javax.xml.crypto.dsig.XMLObject
      • getId

        public java.lang.String getId()
        Specified by:
        getId in interface javax.xml.crypto.dsig.XMLObject
      • getMimeType

        public java.lang.String getMimeType()
        Specified by:
        getMimeType in interface javax.xml.crypto.dsig.XMLObject
      • getEncoding

        public java.lang.String getEncoding()
        Specified by:
        getEncoding in interface javax.xml.crypto.dsig.XMLObject
      • marshal

        public void marshal(org.w3c.dom.Node parent,
                   java.lang.String dsPrefix,
                   javax.xml.crypto.dom.DOMCryptoContext context)
                     throws javax.xml.crypto.MarshalException
        Specified by:
        marshal in class DOMStructure
        Throws:
        javax.xml.crypto.MarshalException
      • 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

© Portions Copyright 2003, 2014 IBM Corporation. All rights reserved.
© Portions Copyright 2003, 2014 Oracle and/or its affiliates. All rights reserved.