Java Code
Lets walk through the java code now, here we basically define the interfaces for our web services and add the implementation for the same as well
-
The HelloWorld.java interface has a one method that takes in a string parameter. Notice the annotations (@WebService to define a web service and @WebParam to define a parameter)
package com.yosanai.tutorial.ws.hellowebservice; import javax.jws.WebParam; import javax.jws.WebService; /** * @author Saravana P Shanmugam * */ @WebService public interface HelloWorld { String sayHi(@WebParam(name = "message") String text); }
-
The FileManagement.java interface has a one method that takes in a File.java object as parameter. Notice the annotations (@WebService to define a web service and @WebParam to define a parameter)
package com.yosanai.tutorial.ws.hellowebservice; import javax.jws.WebParam; import javax.jws.WebService; /** * @author Saravana P Shanmugam * */ @WebService public interface FileManagement { public String upload(@WebParam(name = "file") File file) throws Exception; }
- Tags:
Who's online
There are currently 0 users and 2 guests online.
Who's new
- Saravana Peruma...
Recent comments
29 weeks 4 days ago
33 weeks 8 min ago
47 weeks 3 days ago
49 weeks 5 days ago
1 year 6 weeks ago
1 year 37 weeks ago
2 years 13 weeks ago
2 years 14 weeks ago