Examples of toStringWithConsume()


Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

public class WorkFlowUtils {
    public static String getSoapBodyContent(String wholeMessage) throws XMLStreamException {
        SOAPEnvelope messageEl = reader2SOAPEnvilope(new StringReader(wholeMessage));
        OMElement messageBodyContent = messageEl.getBody().getFirstElement();
        return messageBodyContent.toStringWithConsume();
    }

    public static String formatURLString(String url) {

        if (url == null) {
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

        String topic = getTopic(messageContext);
        OMElement outputElement = null;
        OMElement header = getHeader(messageContext);
        ContextHeaderDocument document = null;
        try {
            document = ContextHeaderDocument.Factory.parse(header.toStringWithConsume());
        } catch (XMLStreamException e) {
            e.printStackTrace();
        } catch (XmlException e) {
            e.printStackTrace();
        }
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

        SOAPHeader header = context.getEnvelope().getHeader();
        OMElement contextHeader = header.getFirstChildWithName(new QName(
                "http://schemas.airavata.apache.org/workflow-execution-context", "context-header"));
        String address = null;
        try {
            ContextHeaderDocument document = ContextHeaderDocument.Factory.parse(contextHeader.toStringWithConsume());
            address = document.getContextHeader().getWorkflowMonitoringContext().getEventPublishEpr();
        } catch (XmlException e) {
            e.printStackTrace(); // To change body of catch statement use File | Settings | File Templates.
        } catch (XMLStreamException e) {
            e.printStackTrace(); // To change body of catch statement use File | Settings | File Templates.
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

    private String getTopic(MessageContext context) {
        OMElement contextHeader = getHeader(context);
        String topic = null;
        try {
            ContextHeaderDocument document = ContextHeaderDocument.Factory.parse(contextHeader.toStringWithConsume());
            topic = document.getContextHeader().getWorkflowMonitoringContext().getExperimentId();
        } catch (XmlException e) {
            e.printStackTrace();
        } catch (XMLStreamException e) {
            e.printStackTrace();
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

            for (Iterator<OMElement> ite = referenceParametersMap.values().iterator(); ite.hasNext();) {
                OMElement currentReferenceParameter = ite.next();

                try {
                    buffer.append(currentReferenceParameter.toStringWithConsume());
                } catch (XMLStreamException se) {
                    logger.error("unable to convert reference parameter", se);
                }

            }
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

        OMElement omSecurityContextHeader = context.getExecutionContext().getSecurityContextHeader();

        ContextHeaderDocument document = null;
        try {
            if (omSecurityContextHeader != null) {
                document = ContextHeaderDocument.Factory.parse(omSecurityContextHeader.toStringWithConsume());
            }
        } catch (XMLStreamException e) {
            e.printStackTrace();
        } catch (XmlException e) {
            e.printStackTrace();
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

            try {
                Iterator<OMElement> omElementIterator = msgBoxClient.takeMessagesFromMsgBox(msgBoxAddr, 5000L);
                List<XmlElement> xmlArrayList = new ArrayList<XmlElement>();
                while (omElementIterator.hasNext()){
                    OMElement next = omElementIterator.next();
                    String message = next.toStringWithConsume();
                    xmlArrayList.add(XMLUtil.stringToXmlElement3(message));
                }
                // now hard work: find callbacks
                for (int i = 0; i < xmlArrayList.size(); i++) {
                    XmlElement m = xmlArrayList.get(i);
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

                                StAXOMBuilder builder = new StAXOMBuilder(reader);
                                outputElement.addChild(builder.getDocumentElement());
                            }
                            // Send notification
                            logger.info("outputMessage: " + outputElement.toString());
                            outPut = new WSIFMessageElement(XMLUtil.stringToXmlElement3(outputElement.toStringWithConsume()));
                            EmbeddedGFacInvoker.this.notifier.serviceFinished(new WSIFMessageElement((XmlElement)outPut));
                        } else {
                            // An implementation of WSIFMessage,
                            // WSIFMessageElement, implements toString(), which
                            // serialize the message XML.
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

                    airavataAPI.getApplicationManager().getApplicationDescription(serviceName, registeredHost.getType().getHostName());

            // When we run getInParameters we set the actualParameter object, this has to be fixed
            URL resource = EmbeddedGFacInvoker.class.getClassLoader().getResource("gfac-config.xml");
            OMElement inputMessage = getInParameters();
            Object wsifMessageElement = new WSIFMessageElement(XMLUtil.stringToXmlElement3(inputMessage.toStringWithConsume()));
            this.notifier.invokingService(new WSIFMessageElement((XmlElement) wsifMessageElement));
            Properties configurationProperties = ServerSettings.getProperties();
            GFacConfiguration gFacConfiguration = GFacConfiguration.create(new File(resource.getPath()), airavataAPI, configurationProperties);

            JobExecutionContext jobExecutionContext = new JobExecutionContext(gFacConfiguration, serviceName);
View Full Code Here

Examples of org.apache.axiom.om.OMElement.toStringWithConsume()

                StAXOMBuilder builder = new StAXOMBuilder(reader);
                outputElement.addChild(builder.getDocumentElement());
            }
            // Send notification
            logger.debug("outputMessage: " + outputElement.toString());
            outPut = new WSIFMessageElement(XMLUtil.stringToXmlElement3(outputElement.toStringWithConsume()));
            this.result = true;
            EmbeddedGFacInvoker.this.notifier.serviceFinished(new WSIFMessageElement((XmlElement) outPut));
            //todo check whether ActualParameter values are set or not, if they are null have to through an error or handle this in gfac level.
//             {
//                // An implementation of WSIFMessage,
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.