The following document contains the results of PMD's CPD 4.1.
File | Line |
---|---|
org\fosstrak\ale\util\SerializerUtil.java | 269 |
org\fosstrak\ale\util\SerializerUtil.java | 295 |
public static void serializeECSpec(ECSpec ecSpec, Writer writer) throws IOException { try { String JAXB_CONTEXT = "org.fosstrak.ale.xsd.ale.epcglobal"; JAXBContext context = JAXBContext.newInstance(JAXB_CONTEXT); Marshaller marshaller = context.createMarshaller(); marshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, new Boolean(true)); org.fosstrak.ale.xsd.ale.epcglobal.ObjectFactory objFactory = new org.fosstrak.ale.xsd.ale.epcglobal.ObjectFactory(); JAXBElement<ECSpec> theSpec = objFactory.createECSpec(ecSpec); // store the file to the file path marshaller.marshal(theSpec, writer); } catch (JAXBException e) { e.printStackTrace(); } } |