Class JAXBSupport

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.ClassLoader classloader  
      private java.lang.String contextPath  
      private javax.xml.bind.JAXBContext jaxbContext  
      private javax.xml.bind.Marshaller marshaller  
      private javax.xml.bind.Unmarshaller unmarshaller  
    • Constructor Summary

      Constructors 
      Constructor Description
      JAXBSupport​(java.lang.String contextPath)  
      JAXBSupport​(java.lang.String contextPath, java.lang.ClassLoader classloader)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private javax.xml.bind.JAXBContext getContext()  
      private javax.xml.bind.Marshaller getMarshaller()  
      private javax.xml.bind.Unmarshaller getUnmarshaller()  
      protected Element marshal​(javax.xml.bind.Element element)
      Marshals the given Elementin to its DOM4J counterpart.
      protected javax.xml.bind.Element unmarshal​(Element element)
      Unmarshalls the specified DOM4J Elementinto a Element
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • contextPath

        private java.lang.String contextPath
      • classloader

        private java.lang.ClassLoader classloader
      • jaxbContext

        private javax.xml.bind.JAXBContext jaxbContext
      • marshaller

        private javax.xml.bind.Marshaller marshaller
      • unmarshaller

        private javax.xml.bind.Unmarshaller unmarshaller
    • Constructor Detail

      • JAXBSupport

        public JAXBSupport​(java.lang.String contextPath)
      • JAXBSupport

        public JAXBSupport​(java.lang.String contextPath,
                           java.lang.ClassLoader classloader)
    • Method Detail

      • marshal

        protected Element marshal​(javax.xml.bind.Element element)
                           throws javax.xml.bind.JAXBException
        Marshals the given Elementin to its DOM4J counterpart.
        Parameters:
        element - JAXB Element to be marshalled
        Returns:
        the marshalled DOM4J Element
        Throws:
        javax.xml.bind.JAXBException - when an error occurs
      • unmarshal

        protected javax.xml.bind.Element unmarshal​(Element element)
                                            throws javax.xml.bind.JAXBException
        Unmarshalls the specified DOM4J Elementinto a Element
        Parameters:
        element - the DOM4J element to unmarshall
        Returns:
        the unmarshalled JAXB object
        Throws:
        javax.xml.bind.JAXBException - when an error occurs
      • getMarshaller

        private javax.xml.bind.Marshaller getMarshaller()
                                                 throws javax.xml.bind.JAXBException
        Throws:
        javax.xml.bind.JAXBException
      • getUnmarshaller

        private javax.xml.bind.Unmarshaller getUnmarshaller()
                                                     throws javax.xml.bind.JAXBException
        Throws:
        javax.xml.bind.JAXBException
      • getContext

        private javax.xml.bind.JAXBContext getContext()
                                               throws javax.xml.bind.JAXBException
        Throws:
        javax.xml.bind.JAXBException