Search in sources :

Example 6 with XmlAdapter

use of javax.xml.bind.annotation.adapters.XmlAdapter in project ddf by codice.

the class XmlParserConfiguratorTest method setup.

@Before
public void setup() {
    pc = new XmlParserConfigurator();
    testHandler = new ValidationEventHandler() {

        @Override
        public boolean handleEvent(ValidationEvent event) {
            return false;
        }
    };
    testAdapter = new XmlAdapter() {

        @Override
        public Object unmarshal(Object v) throws Exception {
            return null;
        }

        @Override
        public Object marshal(Object v) throws Exception {
            return null;
        }
    };
}
Also used : ValidationEventHandler(javax.xml.bind.ValidationEventHandler) ValidationEvent(javax.xml.bind.ValidationEvent) XmlAdapter(javax.xml.bind.annotation.adapters.XmlAdapter) Before(org.junit.Before)

Aggregations

XmlAdapter (javax.xml.bind.annotation.adapters.XmlAdapter)6 XmlJavaTypeAdapter (javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter)4 ValidationEvent (javax.xml.bind.ValidationEvent)2 ValidationEventHandler (javax.xml.bind.ValidationEventHandler)2 Before (org.junit.Before)2