org.apache.axis2.rpc.client.RPCServiceClient Class

This section describes the org.apache.axis2.rpc.client.RPCServiceClient class that represents an RPC based Web service client. The invokeBlocking() method can be used to invoke an RPC method based operation without using OMElement objects.

To make invoking an RPC method based Web service easier, Axis2 extends the org.apache.axis2.client.ServiceClient class to a sub class, org.apache.axis2.rpc.client.RPCServiceClient, to offer additional methods for client programming.

1. Creating an RPC method based service client object from an existing WSDL document with this constructor method:

   RPCServiceClient client =
      new RPCServiceClient(null, wsdlURL, serviceQName, portName)
// "null" indicates a default ConfigurationContext object to be used
// "wsdlURL" specifies a WSDL document using a new URL(wsdlUrlString)
// "serviceQName" specifies a service within the WSDL document
//    using a new QName(tns,serviceName)
//    "tns" specifies the target namespace of the Web service
// "portName" specifies a port within the service using the port name

2. Invoking an RPC method based operation and receiving return values as an OMElement with this invokeBlocking() method:

   response = invokeBlocking(operationQName, args)
// "operationQName" specifies an operation within the service
//    using a new QName(tns,operationName)
//    "tns" specifies the target namespace of the Web service
// "args" specifies input parameters as an Object[].
// "response" receives the SOAP Body element in the response message
//    as an org.apache.axiom.om.OMElement object

3. Invoking an RPC method based operation and receiving return values as an Object[] with this invokeBlocking() method:

   returnValues = invokeBlocking(operationQName, args)
// "operationQName" specifies an operation within the service
//    using a new QName(tns,operationName)
//    "tns" specifies the target namespace of the Web service
// "args" specifies input parameters as an Object[].
// "returnValues" receives return values as an Object[].

For other RPCServiceClient methods, see Axis documentation.

Table of Contents

 About This Book

 Introduction to WSDL 2.0

 WSDL 2.0 Document Structure and Syntax

 WSDL Version 2.0 Part 2: Adjuncts

 WSDL 2.0 Document Examples with SOAP Binding

 Using WSDL Document in Java Apache Axis2/Java for WSDL

 Apache Woden for WSDL Documents in Java

 SoapUI - Web Service Testing Tool

 PHP SOAP Extension for WSDL

 Perl SOAP::Lite for WSDL

 Introduction to WSDL 1.1

 WSDL 1.1 Document Structure and Syntax

 WSDL 1.1 Binding Extension for SOAP 1.1

 SoapUI as WSDL 1.1 Testing Tool

 WSDL 1.1 and SOAP 1.1 Examples - Document and RPC Styles

 PHP SOAP Extension for WSDL 1.1

 Perl SOAP::Lite for WSDL 1.1

Apache Axis2/Java for WSDL 1.1

 Creating Service Client with WSDL 1.1 Document

 org.apache.axis2.client.Options - Operation Client Options

 sendReceive() Method - Invoking a Named Operation

 Turning Off the Chunked HTTP Flag

 AXIOM (AXIs Object Model)

 Axis2RegistrationClient.java - document/literal Style

org.apache.axis2.rpc.client.RPCServiceClient Class

 Axis2GetExchangeRateClient.java - rpc/encoded Style

 SocketRequestResponseServer.java - Socket Server Testing Program

 Capturing the HTTP Request from an Axis2 Client Program

 Using WSDL2Java to Generate Web Service Stub Classes

 WSDL 1.1 Binding Extension for SOAP 1.2

 WSDL 1.1 and SOAP 1.2 Examples - Document and RPC Styles

 SOAP 1.2 Binding - PHP, Java and Perl Clients

 Python SOAP Client: Zeep

 WSDL Related Terminologies

 Archived Tutorials

 References

 Full Version in PDF/EPUB