We will use Axis2 service archiver tool for this.
- Go to your workspace folder which Eclipse creates , You will see a metadata folder there , go to metadata>plugins>servicearchiver>, and delete the file present in it.[if you are opening Eclipse for the first time then no need for this step]
- Open Eclipse from command line using syntax given below
EclipseHomeDirectoryPath\eclipse.exe -clean -console -consoleLog -debug -vmargs -Xmx384M
Example:
C:\Eclipse3311\eclipse\eclipse.exe -clean -console -consoleLog -debug -vmargs -Xmx384M
- Now Select the New->Other->Axis2 wizards->Axis2 Service Archiver
- Browse the location of the class file TestService.class we generated in second section , it must be present in project folder ->bin folder.
- Click on next
- Browse WSDL file we created and click on next
- In general if your class depends on some libraries then include those libraries now , in our case we dont need any other library so click on next
- If you have custom services.xml file then browse it here otherwise , for our example we will create services.xml file automatically so select Generate services.xml automatically click on next .
- Now give the service name and class name as follow
Class Name : webservice1.TestService
- Click on load , if filepath was given correctly then class should low and u should see serviceFunction() in the table
- Click on next
- Browse the output location, select Project folder(or any folder of your choice)
- Give file name as TestService
- Click on finish
No comments:
Post a Comment