Generate the SilkCentral Test Manager class stubs

0 Likes

Problem:

How do I generate the SilkCentral Test Manager class stubs?

Resolution:

Requirements

  • JDK 1.5
  • Axis 1.4 distribution
    • http://ws.apache.org/axis/


What Web Services are available?

Web Service Name
WSDL URL Description
sccsystem /services/sccsystem?wsdl This is the root service that provides authentication andsimply utility methods
sccentities /services/sccentities?wsdl This service provides access to the Project and Productentities on the SilkCentral platform
tmrequirementsmanagement /services/tmrequirementsmanagement?msdl This service provides access to the Requirements unit ofSilkCentral Test Manager
Tmplanning /services/tmplanning?wsdl This service provides access to the Test Plan unit ofSilkCentral Test Manager. It also enables the starting ofexecutions and fetching execution results
Tmexecution /services/tmexecution?wsdl This services provides access to the Execution unit ofSilkCentral Test Manager
Scim /services/scim?wsdl This services provides access to SilkCentral IssueManager


Configuring theEnvironment

  1. Download the Axis 1.4 binarydistribution
  2. Extract the files in the distribution to adirectory of your choosing, this directory will now be referencedas %AXIS_DIR% for the remainder of this article
  3. Create an environment variable which referencesthe jar files extracted from the Axis binary distribution
    1. On your Windows Desktop, right click on"My Computer" and select"Properties"
    2. Select the "Advanced" tab andthen click the "Environmental Variables"button
    3. Create a new "System Variable" andgive it the name WS_CLASSPATH
    4. Give the WS_CLASSPATH environmental variable thefollowing value:
      “%AXIS_DIR%\axis.jar;%AXIS_DIR%\axis-ant.jar; %AXIS_DIR%\commons-discovery-0.2.jar;%AXIS_DIR%\commons-logging-1.0.4.jar; %AXIS_DIR%\jaxrpc.jar;%AXIS_DIR%\log4j-1.2.8.jar; %AXIS_DIR%\saaj.jar;%AXIS_DIR%\wsdl4j-1.5.1.jar;”


Now that our environment has been configured we canproceed with generating the Web Service stubs. To generate the WebService stubs ensure that you a Java SDJ 1.5 installed an in yourPATH. We can then perform the following actions:

  1. Open a Windows Command Prompt
  2. Run the following command:
    java -cp %WS_CLASSPATH% org.apacheaix.wsdl.WSDL2Java -o -d Session -p -t http
  3. After executing the above command for thespecified you will find that the Web Service stubshave been generated in the specified output directory,


Let us look at the command we would use to generate the Web Serviceclass stubs of the sccsystem web service, where the package name we want to use is "com.borland.sctm.tmplanning" and the directory to which we want to output the class stubs is "C:\com\microfocus\sctm\tmplanning". The command is as follows:



Old KB# 25100
Comment List
Anonymous
Related Discussions
Recommended