Package org.xmlpull.v1.builder

Examples of org.xmlpull.v1.builder.XmlElement.addChild()


        } else if (value instanceof Collection) {
            Collection list = (Collection) value;
            Iterator arrayValues = list.iterator();
            while (arrayValues.hasNext()) {
                XmlElement item = builder.newFragment("value");
                item.addChild(arrayValues.next());
                paramsElem.addChild(item);
            }
        } else if (value instanceof ArrayList) {
            Collection list = (Collection) value;
            Iterator arrayValues = list.iterator();
View Full Code Here


        } else if (value instanceof ArrayList) {
            Collection list = (Collection) value;
            Iterator arrayValues = list.iterator();
            while (arrayValues.hasNext()) {
                XmlElement item = builder.newFragment("value");
                item.addChild(arrayValues.next());
                paramsElem.addChild(item);
            }
        } else if (value instanceof String[]) {
            String[] list = (String[]) value;
            for (int i = 0; i < list.length; i++) {
View Full Code Here

            }
        } else if (value instanceof String[]) {
            String[] list = (String[]) value;
            for (int i = 0; i < list.length; i++) {
                XmlElement item = builder.newFragment("value");
                item.addChild(list[i]);
                paramsElem.addChild(item);
            }
        } else {
            throw new ComponentRegistryException("Simple WS Client can not handle the value of type " + value);
        }
View Full Code Here

    private void writeSplitorPerService(XmlElement scufl, WSNode node) throws GraphException {
        List<DataPort> inputPorts = node.getInputPorts();
        XmlElement processor = scufl.addElement(scuflNS, "processor");
        processor.addAttribute("name", getValidName(node) + "InputMessagePartXML");
        XmlElement local = processor.addElement(scuflNS, "local");
        local.addChild(0, "org.embl.ebi.escience.scuflworkers.java.XMLInputSplitter");
        XmlElement extensions = local.addElement(scuflNS, "extensions");

        QName inputName = getInputElementName(node);
        if (null == inputName) {
            throw new GraphException("No Valid input type found for WS Node" + node.getName());
View Full Code Here

        // /outspiltor
        XmlElement outProcessor = scufl.addElement(scuflNS, "processor");
        outProcessor.addAttribute("name", getValidName(node) + "OutputMessagePartXML");
        XmlElement outLocal = outProcessor.addElement(scuflNS, "local");
        outLocal.addChild(0, "org.embl.ebi.escience.scuflworkers.java.XMLOutputSplitter");
        XmlElement outExtensions = outLocal.addElement(scuflNS, "extensions");
        XmlElement outComplextype = outExtensions.addElement(scuflNS, "complextype");
        outComplextype.addAttribute("optional", "false");
        outComplextype.addAttribute("unbounded", "false");
        outComplextype.addAttribute("typename", component.getOutputTypeName());
View Full Code Here

        String name = getValidName(node);
        processor.addAttribute("name", name);
        XmlElement description = processor.addElement(scuflNS, "description");
        String txt = node.getComponent().getDescription();
        if (null == txt) {
            description.addChild(name);
        } else {
            description.addChild(txt);
        }

        XmlElement arbitrarywsdl = processor.addElement(scuflNS, "arbitrarywsdl");
View Full Code Here

        XmlElement description = processor.addElement(scuflNS, "description");
        String txt = node.getComponent().getDescription();
        if (null == txt) {
            description.addChild(name);
        } else {
            description.addChild(txt);
        }

        XmlElement arbitrarywsdl = processor.addElement(scuflNS, "arbitrarywsdl");
        XmlElement wsdl = arbitrarywsdl.addElement(scuflNS, "wsdl");
View Full Code Here

        String epr = getEPR(node);
        if (null == epr) {
            throw new GraphException("EPR not found for the WS-node:" + builder.serializeToString(node));
        }
        wsdl.addChild(epr + "?wsdl");

        XmlElement operation = arbitrarywsdl.addElement(scuflNS, "operation");
        operation.addChild(node.getOperationName());

        return processor;
View Full Code Here

            throw new GraphException("EPR not found for the WS-node:" + builder.serializeToString(node));
        }
        wsdl.addChild(epr + "?wsdl");

        XmlElement operation = arbitrarywsdl.addElement(scuflNS, "operation");
        operation.addChild(node.getOperationName());

        return processor;

    }
View Full Code Here

    private void createMessage(String paramName, Object value, XmlElement inputMsgElem)
            throws ComponentRegistryException {
        XmlElement paramsElem = builder.newFragment(this.requestNS, paramName);
        if (value instanceof String) {
            paramsElem.addChild(value);
        } else if (value instanceof Collection) {
            Collection list = (Collection) value;
            Iterator arrayValues = list.iterator();
            while (arrayValues.hasNext()) {
                XmlElement item = builder.newFragment("value");
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.