aspose file tools*
The moose likes Web Services and the fly likes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark ""Using the annotations in webservice"" Watch ""Using the annotations in webservice"" New topic
Author

"Using the annotations in webservice"

Guy Emerson
Greenhorn

Joined: Dec 14, 2010
Posts: 27
When we follow the java-to-wsdl way of creating the webservices we use annotations for creating the webService class and based on this class we create the wsdl using Java2WSDL tool in axis2.

But when we follow the wsdl-to-ava technique we have a wsdl first and we create the Server side and the client side classes using the WSDL2Java tool.

My question is : Why the Server side classes created by the WSDL2Java tool does not have the annotations which the Webservice class have when we design it manually following the Java-to-wsdl technique.
Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Hi!
The WSDL-to-Java tool cannot create endpoint implementation class(es), but only create one or more interfaces of the service.
It is then up to you to create a class that implements the interface in question and supplies the functionality of your web service.
Best wishes!


My free books and tutorials: http://www.slideshare.net/krizsan
Guy Emerson
Greenhorn

Joined: Dec 14, 2010
Posts: 27
Hi Ivan Krizsan


It is then up to you to create a class that implements the interface in question and supplies the functionality of your web service.


While implementing do we use the annotations(like @WebService, @WebMethod etc. )
Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Hi!
Guy Emerson wrote:
While implementing do we use the annotations(like @WebService, @WebMethod etc. )

Exactly!
Best wishes!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: "Using the annotations in webservice"