In particular circumstances it can happen that JAXBContext.newInstance("org.sbgn.bindings") fails.
This code might work all the time
ClassLoader classLoader = org.sbgn.bindings.ObjectFactory.class.getClassLoader(); JAXBContext.newInstance("org.sbgn.bindings", classLoader);
In particular circumstances it can happen that
JAXBContext.newInstance("org.sbgn.bindings")
fails.This code might work all the time
ClassLoader classLoader = org.sbgn.bindings.ObjectFactory.class.getClassLoader(); JAXBContext.newInstance("org.sbgn.bindings", classLoader);
Added a util class with a method
getJAXBContext
.