简体   繁体   中英

Generate Web Service Skeleton (Server Side artifacts) using wsimport

I have written a wsdl file and trying to generate server side artifacts to provide the actual business logic.

but I am failed to generate server side artifacts

I am using the below command

wsimport -keep -d Employee.wsdl

Its not generating the service class with business method(Operation). It looks its generating the client artifacts instead server .

Can anybody help me to solve this?

I came across this issue. It looks like wsimport tool generates both client and service stub. The service interface class gets the name of "portType" in wsdl file:

<wsdl:portType name="XPortType">

Then in generated XPortType.java you can see web service annotation:

@WebService(name = "XPortType" ...
public interface XPortType {

You can create your service implementation class as follows:

public class XServiceImpl implements XPortType

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM