Examples of XmlContent


Examples of edu.harvard.hul.ois.ots.schemas.XmlContent.XmlContent

    }

    //if we have technical metadata convert it to the standard form
    if(techmd != null && techmd.getChildren().size() > 0) {
      ByteArrayOutputStream baos = new ByteArrayOutputStream();
      XmlContent xml = getStandardXmlContent();
      if(xml != null) {
        XMLStreamWriter sw = xmlOutputFactory.createXMLStreamWriter(baos);
        xml.output(sw);
        String stdxml = baos.toString("UTF-8");
       
        //convert the std xml back to a JDOM element so we can insert it back into the fitsXml Document
        try {
          StringReader sReader = new StringReader(stdxml);
View Full Code Here

Examples of edu.harvard.hul.ois.ots.schemas.XmlContent.XmlContent

      FitsOutput fitsOut = fits.examine(input);
     
    XMLOutputter serializer = new XMLOutputter(Format.getPrettyFormat());
    serializer.output(fitsOut.getFitsXml(), System.out);
   
    XmlContent xml = fitsOut.getStandardXmlContent();
   
    if(xml != null) {
      xml.setRoot(true);
      XMLOutputFactory xmlof = XMLOutputFactory.newInstance();
      XMLStreamWriter writer = xmlof.createXMLStreamWriter(System.out);
     
      xml.output(writer);
    }
     
  }
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.