Previous Topic: WebServicePluginClassicOperationTemplate.javaNext Topic: WebServicePluginPortOperationsTemplate.wsdl


WebServicePluginSampleClientTemplate.java

This template file is used to create a sample Java client that may be used to test the web service or as the basis for writing your own client in Java. This file contains a class (<serviceName>Client) with an embedded class for the method called (<methodName>Request) and a main method. If there are multiple methods defined in the service, only the first one is used to create the sample.

The file generated from this template allows you to set all of your input parameters, display the SOAP message that is being sent, call the web service, and display the SOAP message that is returned. The main method contains a sample of the code needed to set the input parameters and display the sent and returned SOAP messages. The code that sets the input parameters must be modified before executing the client.

The template uses the following variables:

service

Specifies the name of the web service.

operation

Specifies the name of the operation selected to be included in the sample.

ClientRequest

Specifies a placeholder that indicates where the individual parameter set methods will be placed. A set method is created for every attribute view in the import view set.

SetClientRequest

Specifies a placeholder that indicates where sample calls to each of the set methods is placed. There is one call to each set method created. If one of the views is a repeating group view, only the first item in the repeating group view is set.