Package org.apache.axis2.client

Examples of org.apache.axis2.client.ServiceClient.createClient()


        options.setAction("urn:uploadFileUsingSwA");
        options.setProperty(Constants.Configuration.ENABLE_SWA, Constants.VALUE_TRUE);

        ServiceClient sender = createServiceClient();
        sender.setOptions(options);
        OperationClient mepClient = sender.createClient(ServiceClient.ANON_OUT_IN_OP);

        MessageContext mc = new MessageContext();

        System.out.println("Sending file : " + fileName + " as SwA");
        FileDataSource fileDataSource = new FileDataSource(new File(fileName));
View Full Code Here


                String cookie = cookies[cookieNumber];
                if (httpSession) {
                    setSessionID(messageContext, cookie);
                }
                try {
                    OperationClient op = client.createClient(ServiceClient.ANON_OUT_IN_OP);
                    op.addMessageContext(messageContext);
                    op.execute(true);

                    MessageContext responseContext =
                            op.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
View Full Code Here

                                    configuration.getAxis2Xml());

            ServiceClient sender = new ServiceClient(configContext, null);

            sender.setOptions(options);
            OperationClient mepClient = sender.createClient(ServiceClient.ANON_OUT_IN_OP);

            MessageContext mc = new MessageContext();

            log.info("Sending file : " + fileName + " as SwA");
            FileDataSource fileDataSource = new FileDataSource(new File(fileName));
View Full Code Here

            AxisOperation opdesc = new OutInAxisOperation();
            opdesc.setName(opName);
            //   AxisOperation opdesc = new AxisOperation(new QName("viewVersion"));
            ServiceClient serviceClient = new ServiceClient();
            serviceClient.setOptions(options);
            OperationClient opClient = serviceClient.createClient(ServiceClient.ANON_OUT_IN_OP);
            opClient.addMessageContext(requestContext);
            opClient.setCallback(new ClientCallbackHandler(this.gui));
            opClient.execute(false);

        } catch (AxisFault e1) {
View Full Code Here

                serviceClient.setOptions(options);
                MessageContext requetMessageContext = new MessageContext();
                requetMessageContext.setEnvelope(getRequestEnvelope(opStr, param1, param2,
                        serviceGroupContextId));

                OperationClient opClient = serviceClient.createClient(ServiceClient.ANON_OUT_IN_OP);
                opClient.addMessageContext(requetMessageContext);
                opClient.setOptions(options);

                opClient.execute(true);
View Full Code Here

                serviceClient.setOptions(options);
                MessageContext requetMessageContext = new MessageContext();
                requetMessageContext.setEnvelope(getPreviousRequestEnvelope(opStr, param,
                        serviceGroupContextId));

                OperationClient opClient = serviceClient.createClient(ServiceClient.ANON_OUT_IN_OP);
                opClient.addMessageContext(requetMessageContext);
                opClient.setOptions(options);

                opClient.execute(true);
View Full Code Here

                __log.debug("Message: " + soapEnv);
            }


            ServiceClient client = getCachedServiceClient().client;
            final OperationClient operationClient = client.createClient(isTwoWay ? ServiceClient.ANON_OUT_IN_OP
                    : ServiceClient.ANON_OUT_ONLY_OP);
            operationClient.addMessageContext(mctx);
            // this Options can be alter without impacting the ServiceClient options (which is a requirement)
            Options operationOptions = operationClient.getOptions();
            operationOptions.setAction(mctx.getSoapAction());
View Full Code Here

        String backendServerUrl = (String) jobDataMap.get(TaskSchedulerConstants.BACK_END_URL);

        ServiceClient serviceClient;
        try {
            serviceClient = new ServiceClient();
            OperationClient opClient = serviceClient.createClient(ServiceClient.ANON_OUT_IN_OP);
            //creating message context
            MessageContext outMsgCtx = new MessageContext();
            Options opts = outMsgCtx.getOptions();
            //setting properties into option
            opts.setTo(new EndpointReference(backendServerUrl + serviceName + ".SOAP12Endpoint"));
View Full Code Here

            if (__log.isDebugEnabled()) {
                __log.debug("Axis2 sending message to " + axisEPR.getAddress() + " using MEX " + odeMex);
                __log.debug("Message: " + soapEnv);
            }

            final OperationClient operationClient = client.createClient(isTwoWay ? ServiceClient.ANON_OUT_IN_OP
                    : ServiceClient.ANON_OUT_ONLY_OP);
            operationClient.addMessageContext(mctx);
            // this Options can be alter without impacting the ServiceClient options (which is a requirement)
            Options operationOptions = operationClient.getOptions();
View Full Code Here

        options.setAction("urn:uploadFileUsingSwA");
        options.setProperty(Constants.Configuration.ENABLE_SWA, Constants.VALUE_TRUE);

        ServiceClient sender = createServiceClient();
        sender.setOptions(options);
        OperationClient mepClient = sender.createClient(ServiceClient.ANON_OUT_IN_OP);

        MessageContext mc = new MessageContext();

        System.out.println("Sending file : " + fileName + " as SwA");
        FileDataSource fileDataSource = new FileDataSource(new File(fileName));
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.