类 AbstractJaxWsServiceExporter
- java.lang.Object
- org.springframework.remoting.jaxws.AbstractJaxWsServiceExporter
- 所有已实现的接口:
Aware
,BeanFactoryAware
,DisposableBean
,InitializingBean
public abstract class AbstractJaxWsServiceExporter extends Object implements BeanFactoryAware, InitializingBean, DisposableBean
Abstract exporter for JAX-WS services, autodetecting annotated service beans (through the JAX-WSjavax.jws.WebService
annotation). Compatible with JAX-WS 2.1 and 2.2, as included in JDK 6 update 4+ and Java 7/8.Subclasses need to implement the
publishEndpoint(Endpoint, WebService)
template methods for actual endpoint exposure.- 从以下版本开始:
- 2.5.5
- 作者:
- Juergen Hoeller
- 另请参阅:
javax.jws.WebService
,javax.xml.ws.Endpoint
,SimpleJaxWsServiceExporter
,SimpleHttpServerJaxWsServiceExporter
构造器概要
构造器 构造器 说明 AbstractJaxWsServiceExporter()
方法概要
所有方法 实例方法 抽象方法 具体方法 已过时的方法 修饰符和类型 方法 说明 void
afterPropertiesSet()
Immediately publish all endpoints when fully configured.protected Endpoint
createEndpoint(Object bean)
Create the actual Endpoint instance.void
destroy()
Stops all published endpoints, taking the web services offline.protected abstract void
publishEndpoint(Endpoint endpoint, WebService annotation)
Actually publish the given endpoint.protected abstract void
publishEndpoint(Endpoint endpoint, WebServiceProvider annotation)
Actually publish the given provider endpoint.void
publishEndpoints()
Publish alljavax.jws.WebService
annotated beans in the containing BeanFactory.void
setBeanFactory(BeanFactory beanFactory)
Obtains all web service beans and publishes them as JAX-WS endpoints.void
setBindingType(String bindingType)
Specify the binding type to use, overriding the value of the JAX-WSjavax.xml.ws.BindingType
annotation.void
setEndpointFeatures(WebServiceFeature... endpointFeatures)
Specify WebServiceFeature objects (e.g. as inner bean definitions) to apply to JAX-WS endpoint creation.void
setEndpointProperties(Map<String,Object> endpointProperties)
Set the property bag for the endpoint, including properties such as "javax.xml.ws.wsdl.service" or "javax.xml.ws.wsdl.port".void
setExecutor(Executor executor)
Set the JDK concurrent executor to use for dispatching incoming requests to exported service instances.void
setWebServiceFeatures(Object[] webServiceFeatures)
已过时。as of Spring 4.0, in favor ofsetEndpointFeatures(WebServiceFeature...)
构造器详细资料
AbstractJaxWsServiceExporter
public AbstractJaxWsServiceExporter()
方法详细资料
setEndpointProperties
public void setEndpointProperties(Map<String,Object> endpointProperties)
Set the property bag for the endpoint, including properties such as "javax.xml.ws.wsdl.service" or "javax.xml.ws.wsdl.port".- 另请参阅:
javax.xml.ws.Endpoint#setProperties
,javax.xml.ws.Endpoint#WSDL_SERVICE
,javax.xml.ws.Endpoint#WSDL_PORT
setExecutor
public void setExecutor(Executor executor)
Set the JDK concurrent executor to use for dispatching incoming requests to exported service instances.- 另请参阅:
javax.xml.ws.Endpoint#setExecutor
setBindingType
public void setBindingType(String bindingType)
Specify the binding type to use, overriding the value of the JAX-WSjavax.xml.ws.BindingType
annotation.
setEndpointFeatures
public void setEndpointFeatures(WebServiceFeature... endpointFeatures)
Specify WebServiceFeature objects (e.g. as inner bean definitions) to apply to JAX-WS endpoint creation.- 从以下版本开始:
- 4.0
setWebServiceFeatures
@Deprecated public void setWebServiceFeatures(Object[] webServiceFeatures)
已过时。as of Spring 4.0, in favor ofsetEndpointFeatures(WebServiceFeature...)
Allows for providing JAX-WS 2.2 WebServiceFeature specifications: in the form of actualjavax.xml.ws.WebServiceFeature
objects, WebServiceFeature Class references, or WebServiceFeature class names.As of Spring 4.0, this is effectively just an alternative way of specifying
"endpointFeatures"
. Do not specify both properties at the same time; prefer "endpointFeatures" moving forward.
setBeanFactory
public void setBeanFactory(BeanFactory beanFactory)
Obtains all web service beans and publishes them as JAX-WS endpoints.- 指定者:
setBeanFactory
在接口中BeanFactoryAware
- 参数:
beanFactory
- owning BeanFactory (nevernull
). The bean can immediately call methods on the factory.- 另请参阅:
BeanInitializationException
afterPropertiesSet
public void afterPropertiesSet() throws Exception
Immediately publish all endpoints when fully configured.- 指定者:
afterPropertiesSet
在接口中InitializingBean
- 抛出:
Exception
- in the event of misconfiguration (such as failure to set an essential property) or if initialization fails for any other reason- 另请参阅:
publishEndpoints()
publishEndpoints
public void publishEndpoints()
Publish alljavax.jws.WebService
annotated beans in the containing BeanFactory.
createEndpoint
@UsesJava7 protected Endpoint createEndpoint(Object bean)
Create the actual Endpoint instance.- 参数:
bean
- the service object to wrap- 返回:
- the Endpoint instance
- 另请参阅:
Endpoint#create(Object)
,Endpoint#create(String, Object)
publishEndpoint
protected abstract void publishEndpoint(Endpoint endpoint, WebService annotation)
Actually publish the given endpoint. To be implemented by subclasses.- 参数:
endpoint
- the JAX-WS Endpoint objectannotation
- the service bean's WebService annotation
publishEndpoint
protected abstract void publishEndpoint(Endpoint endpoint, WebServiceProvider annotation)
Actually publish the given provider endpoint. To be implemented by subclasses.- 参数:
endpoint
- the JAX-WS Provider Endpoint objectannotation
- the service bean's WebServiceProvider annotation
destroy
public void destroy()
Stops all published endpoints, taking the web services offline.- 指定者:
destroy
在接口中DisposableBean