Runtime tools : Core components : Web services access : Accessing Web services : Defining a Web services connector
  
Defining a Web services connector
To enable applications to interact with Web services, you must first define the Web services connector.
In the services.xml file or a self-defined connector file, declare a Web services connector for every Web services that you want to invoke.
If you use the <service> tag to define a Web services connector, you must specify an implementation class by providing a value for the implClass attribute. In the following block of sample code, the com.ibm.btt.services.ws.jaxws.BTTJaxWsConnector class is specified for the PeopleService service in the <service> tag.
<service id=”PeopleService”
namespaceUri=http://mock.dallas.com/
serviceName="PeopleServicesService"
portName="PeopleServicesPort"
serviceEndpointInterface="com.dallas.mock.PeopleServicesDelegate"
wsdlUrl="/WEB-INF/wsdl/PeopleServicesService.wsdl"
implClass="com.ibm.btt.services.ws.jaxws.BTTJaxWsConnector" />
If you are using your own tag, not the <service> tag, to define a Web services connector, you must first define the BTTJaxWsConnector class in the service section of the btt.xml file as shown in the following example:
<field id =”JaxWsConnector” value=”com.ibm.btt.ws.BTTJaxWsConnector” />
After you declare the BTTJaxWsConnector class in the btt.xml file, use your own tag in the services.xml file or a self-defined connector file to define the Web services connector.
Note If you are using your own tag to define a Web services connector, remove the implClass attribute. The implClass attribute does not need to be specified because you specify the relationship between the tag and the implementation class in the btt.xml file.
In the following example code, the <JaxWsConnector> tag is used to define a Web services connector:
<JaxWsConnector id=”PeopleService”
namespaceUri=http://mock.dallas.com/
serviceName="PeopleServicesService"
portName="PeopleServicesPort"
serviceEndpointInterface="com.dallas.mock.PeopleServicesDelegate"
wsdlUrl="/WEB-INF/wsdl/PeopleServicesService.wsdl"/>
Go up to
Accessing Web services