Package org.springframework.oxm.castor

Examples of org.springframework.oxm.castor.CastorMarshaller.afterPropertiesSet()


  protected Unmarshaller getUnmarshaller() throws Exception {
    CastorMarshaller unmarshaller = new CastorMarshaller();
    unmarshaller.setMappingLocation(new ClassPathResource("mapping-castor.xml", getClass()));
    // alternatively target class can be set
    //unmarshaller.setTargetClass(Trade.class);
    unmarshaller.afterPropertiesSet();
    return unmarshaller;
  }

}
View Full Code Here


    CastorMarshaller marshaller = new CastorMarshaller();
    // marshaller.setTargetClass(Trade.class);
    marshaller.setMappingLocation(new ClassPathResource("mapping-castor.xml", getClass()));
    // there is no way to call
    // org.exolab.castor.xml.Marshaller.setSupressXMLDeclaration();
    marshaller.afterPropertiesSet();
    return marshaller;
  }

}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.