package at.gv.egiz.moazs.config; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.oxm.jaxb.Jaxb2Marshaller; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; import java.util.HashMap; @Configuration public class MarshallerConfig { @Bean public Jaxb2Marshaller jaxb2Marshaller() { Jaxb2Marshaller marshaller = new Jaxb2Marshaller(); marshaller.setClassesToBeBound( at.gv.e_government.reference.namespace.zustellung.mzs.persondata_.ObjectFactory.class, at.gv.e_government.reference.namespace.zustellung.mzs.app2mzs_.ObjectFactory.class, at.gv.e_government.reference.namespace.zustellung.msg.phase2._20181206_.ObjectFactory.class, at.gv.e_government.reference.namespace.persondata.phase2._20181206_.ObjectFactory.class); marshaller.setMarshallerProperties(new HashMap() {{ put(javax.xml.bind.Marshaller.JAXB_FORMATTED_OUTPUT, true); }}); return marshaller; } }