Class WrapperBridge<T>

  • All Implemented Interfaces:
    XMLBridge<T>

    public class WrapperBridge<T>
    extends Object
    implements XMLBridge<T>
    WrapperBridge handles RPC-Literal body and Document-Literal wrappers without static wrapper classes.
    Author:
    shih-chang.chen@oracle.com
    • Method Detail

      • marshal

        public final void marshal​(T object,
                                  ContentHandler contentHandler,
                                  javax.xml.bind.attachment.AttachmentMarshaller am)
                           throws javax.xml.bind.JAXBException
        Specified by:
        marshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • marshal

        public void marshal​(T object,
                            Node output)
                     throws javax.xml.bind.JAXBException
        Specified by:
        marshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • marshal

        public void marshal​(T object,
                            OutputStream output,
                            NamespaceContext nsContext,
                            javax.xml.bind.attachment.AttachmentMarshaller am)
                     throws javax.xml.bind.JAXBException
        Specified by:
        marshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • marshal

        public final void marshal​(T object,
                                  Result result)
                           throws javax.xml.bind.JAXBException
        Specified by:
        marshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • marshal

        public final void marshal​(T object,
                                  XMLStreamWriter output,
                                  javax.xml.bind.attachment.AttachmentMarshaller am)
                           throws javax.xml.bind.JAXBException
        Specified by:
        marshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException - if there was an error while marshalling.
      • unmarshal

        public final T unmarshal​(InputStream in)
                          throws javax.xml.bind.JAXBException
        Description copied from interface: XMLBridge
        Unmarshals the specified type object.
        Specified by:
        unmarshal in interface XMLBridge<T>
        Parameters:
        in - the parser must be pointing at a start tag that encloses the XML type that this XMLBridge is instanciated for.
        Returns:
        never null.
        Throws:
        javax.xml.bind.JAXBException - if there was an error while unmarshalling.
      • unmarshal

        public final T unmarshal​(Node n,
                                 javax.xml.bind.attachment.AttachmentUnmarshaller au)
                          throws javax.xml.bind.JAXBException
        Specified by:
        unmarshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • unmarshal

        public final T unmarshal​(Source in,
                                 javax.xml.bind.attachment.AttachmentUnmarshaller au)
                          throws javax.xml.bind.JAXBException
        Specified by:
        unmarshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • unmarshal

        public final T unmarshal​(XMLStreamReader in,
                                 javax.xml.bind.attachment.AttachmentUnmarshaller au)
                          throws javax.xml.bind.JAXBException
        Specified by:
        unmarshal in interface XMLBridge<T>
        Throws:
        javax.xml.bind.JAXBException
      • supportOutputStream

        public boolean supportOutputStream()
        Description copied from interface: XMLBridge
        This can be used to determine whether XMLStreamWriter or OutputStream is prefered by the implementation.
        Specified by:
        supportOutputStream in interface XMLBridge<T>
        Returns:
        true if marshall to OutputStream is supported in the implementation.