Methods Summary |
---|
public static javax.xml.bind.Marshaller | createMarshaller()Marshal xml fragment, not an XML document.
try {
final Marshaller marshaller = getJAXBContext().createMarshaller();
marshaller.setProperty(Marshaller.JAXB_FRAGMENT, Boolean.TRUE);
return marshaller;
} catch (JAXBException e) {
logger.severe("createMarshaller", LocalizationMessages.FAILED_TO_CREATE_MARSHALLER_2003(e));
return null;
}
|
public static javax.xml.bind.Unmarshaller | createUnmarshaller()
try {
return getJAXBContext().createUnmarshaller();
} catch (JAXBException e) {
logger.severe("createUnmarshaller", LocalizationMessages.FAILED_TO_CREATE_UNMARSHALLER_2004(e));
return null;
}
|
private static java.util.List | getClassesToBeBound()
final Class[] classes;
final ArrayList<Class> classList;
classes = new Class[]{
Class.forName("com.sun.xml.ws.tx.webservice.member.coord.CoordinationContext")
};
classList = new ArrayList<Class>(Arrays.asList(classes));
return classList;
|
public static javax.xml.bind.JAXBContext | getJAXBContext()
try {
final List<Class> classes = getClassesToBeBound();
jc = JAXBContext.newInstance(classes.toArray(new Class[classes.size()]));
} catch (JAXBException e) {
logger.severe("getJAXBContext", LocalizationMessages.FAILED_TO_CREATE_JAXBCONTEXT_2002(e));
} catch (ClassNotFoundException e) {
logger.severe("getJAXBContext", LocalizationMessages.FAILED_TO_CREATE_JAXBCONTEXT_2002(e));
}
return jc;
|