Package org.apache.xmlbeans

Examples of org.apache.xmlbeans.XmlObject.save()


        XmlObject xmlObject = parse(source);
        xmlObject = upgrade(xmlObject);

        XmlOptions xmlOptions = new XmlOptions();
        xmlOptions.setSavePrettyPrint();
        xmlObject.save(target, xmlOptions);

    }

    public XmlObject upgrade(XmlObject xmlObject) throws XmlException {
        XmlCursor cursor = xmlObject.newCursor();
View Full Code Here


                targetDir.mkdirs();
            }

            XmlOptions xmlOptions = new XmlOptions();
            xmlOptions.setSavePrettyPrint();
            doc.save(targetFile, xmlOptions);

            log.info("Generated: " + targetFile);
        }
        finally {
            xmlCursor.dispose();
View Full Code Here

            // before saving, make sure the directory is present
            ensureMonitorDir();

            //TODO GERONIMO-3719.  Hack to use xmlbeans to write out xml instead of sun specific classes.
            XmlObject xmlObject = XmlObject.Factory.parse(document.getDocumentElement());
            xmlObject.save(new File(path));

            // formatting the doc
            // generate a file output
        } catch(Exception e) {
            log.error(e.getMessage(), e);
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.