Class JAXBMarshalListener

  • All Implemented Interfaces:
    org.eclipse.persistence.internal.oxm.Marshaller.Listener, XMLMarshalListener

    public class JAXBMarshalListener
    extends java.lang.Object
    implements XMLMarshalListener
    INTERNAL:

    Purpose:Provide a wrapper for a JAXB 2.0 Marshal Listener that implements XMLMarshalListener

    Responsibilities:

    • Implement the XMLMarshalListener API
    • Delegate event callbacks to the wrapped Listener instance
    • Perform JAXB 2.0 Class-Based marshal event callbacks
    See Also:
    Marshaller.Listener, XMLMarshalListener
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void afterMarshal​(java.lang.Object obj)
      This event will be called after an object is marshalled.
      void beforeMarshal​(java.lang.Object obj)
      This event will be called before an object is marshalled.
      javax.xml.bind.Marshaller.Listener getListener()  
      void setClassBasedMarshalEvents​(java.util.Map events)  
      void setListener​(javax.xml.bind.Marshaller.Listener jaxbListener)  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • JAXBMarshalListener

        public JAXBMarshalListener​(JAXBContext context,
                                   javax.xml.bind.Marshaller marshaller)
    • Method Detail

      • setListener

        public void setListener​(javax.xml.bind.Marshaller.Listener jaxbListener)
      • getListener

        public javax.xml.bind.Marshaller.Listener getListener()
      • beforeMarshal

        public void beforeMarshal​(java.lang.Object obj)
        Description copied from interface: org.eclipse.persistence.internal.oxm.Marshaller.Listener
        This event will be called before an object is marshalled.
        Specified by:
        beforeMarshal in interface org.eclipse.persistence.internal.oxm.Marshaller.Listener
        Parameters:
        obj - The object that will be marshalled.
      • afterMarshal

        public void afterMarshal​(java.lang.Object obj)
        Description copied from interface: org.eclipse.persistence.internal.oxm.Marshaller.Listener
        This event will be called after an object is marshalled.
        Specified by:
        afterMarshal in interface org.eclipse.persistence.internal.oxm.Marshaller.Listener
        Parameters:
        obj - The object that was marshalled.
      • setClassBasedMarshalEvents

        public void setClassBasedMarshalEvents​(java.util.Map events)