Examples of toStringWithConsume()


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

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

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

            * This is used in getting an InputSource which is later used as an argument
            * to the XMLSchemaCollection object.
            */
            String schemaElStr = null;
            try {
                schemaElStr = importedSchemaDoc.toStringWithConsume();
            }
            catch (XMLStreamException e) {
                e.printStackTrace();
            }
            byte[] schemaElbytes = schemaElStr.getBytes();
View Full Code Here

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

        ExecutionContext execContext = invocationContext.getExecutionContext();
        OMElement omSecurityContextHeader = execContext.getSecurityContextHeader();

        ContextHeaderDocument document = null;
        try {
            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()

        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()

     * @throws Exception
     */
    public static ADBBean serializeDeserialize(ADBBean bean) throws Exception {
        Class<? extends ADBBean> beanClass = bean.getClass();
        OMElement omElement = bean.getOMElement(ADBBeanUtil.getQName(beanClass), OMAbstractFactory.getOMFactory());
        String omElementString = omElement.toStringWithConsume();
//        System.out.println("om string ==> " + omElementString);
        XMLStreamReader xmlReader = StAXUtils.createXMLStreamReader(new ByteArrayInputStream(omElementString.getBytes()));
        return ADBBeanUtil.parse(beanClass, xmlReader);
    }
   
View Full Code Here

Examples of org.apache.axiom.om.impl.llom.OMSourcedElementImpl.toStringWithConsume()

    private Scriptable getJSONAsXML() throws CarbonException {
        OMSourcedElementImpl sourcedElement = (OMSourcedElementImpl) responseXML;
        if (sourcedElement.getDataSource() != null) {
            try {
                String jsonString = sourcedElement.toStringWithConsume();
                while (jsonString.indexOf("<?") == 0) {
                    jsonString = jsonString.substring(jsonString.indexOf("?>") + 2);
                }
                Object[] objects = {jsonString};
                return context.newObject(this, "XML", objects);
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.