1、@javax.jws.WebService(使用@WebService来标记一个类或接口,表示这是一个WebService服务),其中的属性:
Property Description Default
| The name of the | The unqualified name of the Java class or interface(默认是这个接口或类的名字) |
| The XML namespace of the the WSDL and some of the XML elements generated from this web service. Most of the XML elements will be in the namespace according to the JAXB mapping rules.(wsdl文件的命名空间) | The namespace mapped from the package name containing the web service according to section 3.2 of the JAX-WS 2.0 specification.(默认是包名反转) |
| The Service name of the web service: | The unqualified name of the Java class or interface + "Service"(默认是类名或接口名+”Service“) |
| The qualified name of the service endpoint interface. If the implementation bean references a service endpoint interface, that service endpoint interface is used to determine the abstract WSDL contract (portType and bindings). In this case, the service implementation bean MUST NOT include any JSR 181 annotations other than | None – If not specified, the endpoint implementation class is used to generate the web service contract. In this case, a service endpoint interface is not required.(默认为空,如果没指定实现接口,则直接把当前类当做服务类,这种情况下,服务端接口就不需要了) |
| The | The |
| Not currently used by JAX-WS RI 2.2.7 |
2、@javax.jws.WebMethod(使用@WebMethod来暴露出WebService中的方法),其中的属性:
Property Description Default
| The name of the | The name of the Java method(默认是方法名) |
| The XML namespace of the the WSDL and some of the XML elements generated from this web service. Most of the XML elements will be in the namespace according to the JAXB mapping rules.(wsdl文件中当前方法下子标签<soap:operation soapAction="..."/>的值) | "" |
| Used to exclude a method from the WebService.(是否从WebService服务中排除这个方法) | false(默认是不排除) |
3、@javax.jws.WebParam(使用@WebParam来设置请求参数和soap消息元素名的映射),其中的属性:
Property Description Default
| Name of the parameter.(参数的名字) If the operation is RPC style and Otherwise, the default is A name MUST be specified if the operation is document style, the parameter style is | |
| The XML namespace for the parameter. Only used if the operation is document style or the paramater maps to a header. If the target namespace is set to "", this represents the empty namespace. | The empty namespace, if the operation is document style, the parameter style is |
| Represents the direction the parameter flows for this method. Possible values are | (不是Holder参数则为IN,如果是Holder参数则为INOUT) |
| Specifies whether the parameter should be carried in a header.(是否单独声明一个元素<xsd:element name="...") | |
| Used to specify the | |
4、@javax.jws.WebResult(使用@WebResult来设置返回值和soap消息元素名的映射),其中的属性:
Property Description Default
| The name of the return value in the WSDL and on the wire. For | "return" for |
| The XML namespace for the return value. Only used if the operation is document style or the return value maps to a header. If the target namespace is set to "", this represents the empty namespace. | The empty namespace, if the operation is document style, the parameter style is |
| Specifies whether the result should be carried in a header. | |
| Used to specify the | |
5、@javax.jws.HandlerChain(使用@HandlerChain来定义程序处理链),其中的属性:
Property Description Default
| Location of the file containing the handler chain definition. The location can be relative or absolute with in a classpath system. If the location is relative, it is relative to the package of the web service. If it is absolute, it is absolute from some path on the classpath.(处理链的配置文件路径,配置文件放在类路径下) | None |
| DEPRECATED The handler chain name from within the handler chain file. | "" |
6、@javax.jws.soap.SOAPBinding(使用@SOAPBinding指定soap消息格式)
Property Description Default
| Defines the style for messages used in a web service. The value can be either | |
| Defines the encoding used for messages used in web service. Can only be | |
| Determines if the method's parameters represent the entire message body or whether the parameters are wrapped in a body element named after the operation. Choice of | |