Examples of xmlFormat()


Examples of org.wso2.carbon.utils.xml.XMLPrettyPrinter.xmlFormat()

                    OMElement paramEle = new StAXOMBuilder(xmlSR).getDocumentElement();
                    String paramName = paramEle.getAttribute(new QName("name")).getAttributeValue();
                    InputStream xmlIn = new ByteArrayInputStream(serviceParameter.getBytes());
                    XMLPrettyPrinter xmlPrettyPrinter = new XMLPrettyPrinter(xmlIn, null);
                    Parameter parameter = new Parameter(paramName,
                                                        xmlPrettyPrinter.xmlFormat());
                    boolean isLocked = false;
                    OMAttribute lockedAttrib = paramEle.getAttribute(new QName("locked"));
                    if(lockedAttrib != null) {
                        isLocked = "true".equals(lockedAttrib.getAttributeValue());
                    }
View Full Code Here

Examples of org.wso2.carbon.utils.xml.XMLPrettyPrinter.xmlFormat()

                            String paramName = paramEle.getAttribute(new QName("name"))
                                    .getAttributeValue();
                            InputStream xmlIn = new ByteArrayInputStream(groupParameter.getBytes());
                            XMLPrettyPrinter xmlPrettyPrinter = new XMLPrettyPrinter(xmlIn, null);
                            Parameter parameter = new Parameter(paramName,
                                                                xmlPrettyPrinter.xmlFormat());
                            boolean isLocked = false;
                            OMAttribute lockedAttrib = paramEle.getAttribute(new QName("locked"));
                            if (lockedAttrib != null) {
                                isLocked = "true".equals(lockedAttrib.getAttributeValue());
                            }
View Full Code Here

Examples of org.wso2.carbon.utils.xml.XMLPrettyPrinter.xmlFormat()

                    XMLOutputFactory.newInstance().createXMLStreamWriter(outBuffer);
            policy.serialize(writer);
            writer.flush();
            ByteArrayInputStream bais = new ByteArrayInputStream(outBuffer.toByteArray());
            XMLPrettyPrinter xmlPrettyPrinter = new XMLPrettyPrinter(bais);
            return xmlPrettyPrinter.xmlFormat();

        } catch (XMLStreamException e) {
            throw new RuntimeException("Serialization of Policy object failed " + 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.