Testing a Password Protected Web Service

Edit service test client-generated Java source to provide a username and password.

When using tooling to test a service, the code created by the Create Web Service Client wizard does not include the username and password that are required to test a password-protected service. Edit the service test client-generated Java source to provide the required information.
  1. Edit the .java source file for the class that ends with BindingStub, for example, SimpleJavaServiceImplHTTP_BindingStub.java.
  2. Locate the source for the createCall() method.
  3. Add the following lines, substituting appropriate values for the user name and password:
    _call.setUsername("
    
    user
    ");
    _call.setPassword("
    
    password
    ");
    
Related concepts
Web Service Client Wizard
Related tasks
Testing a Service Using the Web Service Client Wizard

Send your feedback on this help topic to Sybase Technical Publications: pubs@sybase.com

Your comments will be sent to the technical publications staff at Sybase, Inc. For product-related issues or technical support, contact Sybase Technical Support at 1-800-8SYBASE.