Package org.apache.cxf.jaxws
Class EndpointImpl
- java.lang.Object
-
- javax.xml.ws.Endpoint
-
- org.apache.cxf.jaxws.EndpointImpl
-
- All Implemented Interfaces:
AutoCloseable,Configurable,InterceptorProvider
- Direct Known Subclasses:
EndpointDefinitionParser.SpringEndpointImpl,EndpointImpl
public class EndpointImpl extends javax.xml.ws.Endpoint implements InterceptorProvider, Configurable, AutoCloseable
-
-
Field Summary
Fields Modifier and Type Field Description static StringCHECK_PUBLISH_ENDPOINT_PERMISSON_PROPERTYThis property controls whether the 'publishEndpoint' permission is checked using only the AccessController (i.e.static StringCHECK_PUBLISH_ENDPOINT_PERMISSON_PROPERTY_WITH_SECURITY_MANAGER
-
Constructor Summary
Constructors Constructor Description EndpointImpl(Object implementor)EndpointImpl(Bus bus, Object implementor)EndpointImpl(Bus b, Object i, String bindingUri)EndpointImpl(Bus b, Object i, String bindingUri, String wsdl)EndpointImpl(Bus b, Object i, String bindingUri, String wsdl, javax.xml.ws.WebServiceFeature[] f)EndpointImpl(Bus b, Object i, String bindingUri, javax.xml.ws.WebServiceFeature[] features)EndpointImpl(Bus b, Object implementor, JaxWsServerFactoryBean sf)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidcheckProperties()protected voidcheckPublishable()protected voidcheckPublishPermission()voidclose()protected voiddoPublish(String addr)Performs the publication action by setting up aServerinstance based on this endpoint's configuration.StringgetAddress()StringgetBeanName()Get the configurable object's Bean namejavax.xml.ws.BindinggetBinding()BindingConfigurationgetBindingConfig()StringgetBindingUri()BusgetBus()DataBindinggetDataBinding()javax.xml.ws.EndpointContextgetEndpointContext()QNamegetEndpointName()<T extends javax.xml.ws.EndpointReference>
TgetEndpointReference(Class<T> clazz, Element... referenceParameters)javax.xml.ws.EndpointReferencegetEndpointReference(Element... referenceParameters)ExecutorgetExecutor()List<Feature>getFeatures()List<javax.xml.ws.handler.Handler>getHandlers()ObjectgetImplementor()Class<?>getImplementorClass()Gets the class of the implementor.List<Interceptor<? extends Message>>getInFaultInterceptors()Returns the list of interceptors attached to the incoming fault interceptor chain of the object.List<Interceptor<? extends Message>>getInInterceptors()Returns the list of interceptors attached to the incoming interceptor chain of the object.InvokergetInvoker()List<Source>getMetadata()List<Interceptor<? extends Message>>getOutFaultInterceptors()Returns the list of interceptors attached to the outgoing fault interceptor chain of the object.List<Interceptor<? extends Message>>getOutInterceptors()Returns the list of interceptors attached to the outgoing interceptor chain of the object.Map<String,Object>getProperties()StringgetPublishedEndpointUrl()The published endpoint url is used for excplicitely specifying the url of the endpoint that would show up the generated wsdl definition, when the service is brought on line.List<String>getSchemaLocations()ServerImplgetServer()ServerImplgetServer(String addr)JaxWsServerFactoryBeangetServerFactory()ServicegetService()JaxWsServiceFactoryBeangetServiceFactory()QNamegetServiceName()StringgetTransportId()StringgetWsdlLocation()booleanisPublished()voidpublish()voidpublish(Object arg0)voidpublish(String addr)voidpublish(javax.xml.ws.spi.http.HttpContext context)voidsetAddress(String address)voidsetBindingConfig(BindingConfiguration config)voidsetBindingUri(String binding)voidsetBus(Bus b)voidsetDataBinding(DataBinding dataBinding)voidsetEndpointContext(javax.xml.ws.EndpointContext ctxt)voidsetEndpointName(QName endpointName)voidsetExecutor(Executor executor)voidsetFeatures(List<? extends Feature> features)voidsetHandlers(List<javax.xml.ws.handler.Handler> h)voidsetImplementorClass(Class<?> implementorClass)voidsetInFaultInterceptors(List<Interceptor<? extends Message>> interceptors)voidsetInInterceptors(List<Interceptor<? extends Message>> interceptors)voidsetInvoker(Invoker invoker)voidsetMetadata(List<Source> metadata)voidsetOutFaultInterceptors(List<Interceptor<? extends Message>> interceptors)voidsetOutInterceptors(List<Interceptor<? extends Message>> interceptors)voidsetProperties(Map<String,Object> properties)voidsetPublishedEndpointUrl(String publishedEndpointUrl)voidsetSchemaLocations(List<String> schemaLocations)protected voidsetServerFactory(JaxWsServerFactoryBean bean)voidsetServiceFactory(JaxWsServiceFactoryBean sf)voidsetServiceName(QName serviceName)voidsetTransportId(String transportId)voidsetWsdlLocation(String wsdlLocation)voidstop()
-
-
-
Field Detail
-
CHECK_PUBLISH_ENDPOINT_PERMISSON_PROPERTY
public static final String CHECK_PUBLISH_ENDPOINT_PERMISSON_PROPERTY
This property controls whether the 'publishEndpoint' permission is checked using only the AccessController (i.e. when SecurityManager is not installed). By default this check is not done as the system property is not set.- See Also:
- Constant Field Values
-
CHECK_PUBLISH_ENDPOINT_PERMISSON_PROPERTY_WITH_SECURITY_MANAGER
public static final String CHECK_PUBLISH_ENDPOINT_PERMISSON_PROPERTY_WITH_SECURITY_MANAGER
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
EndpointImpl
public EndpointImpl(Object implementor)
-
EndpointImpl
public EndpointImpl(Bus b, Object implementor, JaxWsServerFactoryBean sf)
-
EndpointImpl
public EndpointImpl(Bus b, Object i, String bindingUri, String wsdl)
- Parameters:
b-i- The implementor object.bindingUri- The URI of the Binding being used. Optional.wsdl- The URL of the WSDL for the service, if different than the URL specified on the WebService annotation. Optional.
-
EndpointImpl
public EndpointImpl(Bus b, Object i, String bindingUri, String wsdl, javax.xml.ws.WebServiceFeature[] f)
-
EndpointImpl
public EndpointImpl(Bus b, Object i, String bindingUri, javax.xml.ws.WebServiceFeature[] features)
-
-
Method Detail
-
setBus
public void setBus(Bus b)
-
getBus
public Bus getBus()
-
getBinding
public javax.xml.ws.Binding getBinding()
- Specified by:
getBindingin classjavax.xml.ws.Endpoint
-
setExecutor
public void setExecutor(Executor executor)
- Specified by:
setExecutorin classjavax.xml.ws.Endpoint
-
getExecutor
public Executor getExecutor()
- Specified by:
getExecutorin classjavax.xml.ws.Endpoint
-
getService
public Service getService()
-
getServiceFactory
public JaxWsServiceFactoryBean getServiceFactory()
-
getImplementor
public Object getImplementor()
- Specified by:
getImplementorin classjavax.xml.ws.Endpoint
-
getImplementorClass
public Class<?> getImplementorClass()
Gets the class of the implementor.- Returns:
- the class of the implementor object
-
getMetadata
public List<Source> getMetadata()
- Specified by:
getMetadatain classjavax.xml.ws.Endpoint
-
getProperties
public Map<String,Object> getProperties()
- Specified by:
getPropertiesin classjavax.xml.ws.Endpoint
-
isPublished
public boolean isPublished()
- Specified by:
isPublishedin classjavax.xml.ws.Endpoint
-
publish
public void publish(Object arg0)
This implementation performs no action except to check the publish permission.- Specified by:
publishin classjavax.xml.ws.Endpoint
-
publish
public void publish(String addr)
- Specified by:
publishin classjavax.xml.ws.Endpoint
-
setServiceFactory
public void setServiceFactory(JaxWsServiceFactoryBean sf)
-
setMetadata
public void setMetadata(List<Source> metadata)
- Specified by:
setMetadatain classjavax.xml.ws.Endpoint
-
setProperties
public void setProperties(Map<String,Object> properties)
- Specified by:
setPropertiesin classjavax.xml.ws.Endpoint
-
stop
public void stop()
- Specified by:
stopin classjavax.xml.ws.Endpoint
-
getBeanName
public String getBeanName()
Description copied from interface:ConfigurableGet the configurable object's Bean name- Specified by:
getBeanNamein interfaceConfigurable- Returns:
- the bean name
-
getServerFactory
public JaxWsServerFactoryBean getServerFactory()
-
setServerFactory
protected void setServerFactory(JaxWsServerFactoryBean bean)
-
checkProperties
protected void checkProperties()
-
doPublish
protected void doPublish(String addr)
Performs the publication action by setting up aServerinstance based on this endpoint's configuration.- Parameters:
addr- the optional endpoint address.- Throws:
IllegalStateException- if the endpoint cannot be published/republishedSecurityException- if permission checking is enabled and policy forbids publishingjavax.xml.ws.WebServiceException- if there is an error publishing the endpoint- See Also:
checkPublishPermission(),checkPublishable(),getServer(String)
-
getServer
public ServerImpl getServer()
-
getServer
public ServerImpl getServer(String addr)
-
checkPublishPermission
protected void checkPublishPermission()
-
checkPublishable
protected void checkPublishable()
- Throws:
IllegalStateException- ifpublishableis false
-
publish
public void publish()
-
getAddress
public String getAddress()
-
setAddress
public void setAddress(String address)
-
getPublishedEndpointUrl
public String getPublishedEndpointUrl()
The published endpoint url is used for excplicitely specifying the url of the endpoint that would show up the generated wsdl definition, when the service is brought on line.- Returns:
-
setPublishedEndpointUrl
public void setPublishedEndpointUrl(String publishedEndpointUrl)
-
getEndpointName
public QName getEndpointName()
-
setEndpointName
public void setEndpointName(QName endpointName)
-
getServiceName
public QName getServiceName()
-
setServiceName
public void setServiceName(QName serviceName)
-
getWsdlLocation
public String getWsdlLocation()
-
setWsdlLocation
public void setWsdlLocation(String wsdlLocation)
-
setBindingUri
public void setBindingUri(String binding)
-
getBindingUri
public String getBindingUri()
-
setDataBinding
public void setDataBinding(DataBinding dataBinding)
-
getDataBinding
public DataBinding getDataBinding()
-
getOutFaultInterceptors
public List<Interceptor<? extends Message>> getOutFaultInterceptors()
Description copied from interface:InterceptorProviderReturns the list of interceptors attached to the outgoing fault interceptor chain of the object.- Specified by:
getOutFaultInterceptorsin interfaceInterceptorProvider- Returns:
Listoutgoing fault interceptor chain
-
getInFaultInterceptors
public List<Interceptor<? extends Message>> getInFaultInterceptors()
Description copied from interface:InterceptorProviderReturns the list of interceptors attached to the incoming fault interceptor chain of the object.- Specified by:
getInFaultInterceptorsin interfaceInterceptorProvider- Returns:
Listincoming fault interceptor chain
-
getInInterceptors
public List<Interceptor<? extends Message>> getInInterceptors()
Description copied from interface:InterceptorProviderReturns the list of interceptors attached to the incoming interceptor chain of the object.- Specified by:
getInInterceptorsin interfaceInterceptorProvider- Returns:
Listincoming interceptor chain
-
getOutInterceptors
public List<Interceptor<? extends Message>> getOutInterceptors()
Description copied from interface:InterceptorProviderReturns the list of interceptors attached to the outgoing interceptor chain of the object.- Specified by:
getOutInterceptorsin interfaceInterceptorProvider- Returns:
Listoutgoing interceptor chain
-
setInInterceptors
public void setInInterceptors(List<Interceptor<? extends Message>> interceptors)
-
setInFaultInterceptors
public void setInFaultInterceptors(List<Interceptor<? extends Message>> interceptors)
-
setOutInterceptors
public void setOutInterceptors(List<Interceptor<? extends Message>> interceptors)
-
setOutFaultInterceptors
public void setOutFaultInterceptors(List<Interceptor<? extends Message>> interceptors)
-
setHandlers
public void setHandlers(List<javax.xml.ws.handler.Handler> h)
-
getHandlers
public List<javax.xml.ws.handler.Handler> getHandlers()
-
getInvoker
public Invoker getInvoker()
-
setInvoker
public void setInvoker(Invoker invoker)
-
setImplementorClass
public void setImplementorClass(Class<?> implementorClass)
-
setTransportId
public void setTransportId(String transportId)
-
getTransportId
public String getTransportId()
-
setBindingConfig
public void setBindingConfig(BindingConfiguration config)
-
getBindingConfig
public BindingConfiguration getBindingConfig()
-
getEndpointReference
public javax.xml.ws.EndpointReference getEndpointReference(Element... referenceParameters)
- Specified by:
getEndpointReferencein classjavax.xml.ws.Endpoint
-
getEndpointReference
public <T extends javax.xml.ws.EndpointReference> T getEndpointReference(Class<T> clazz, Element... referenceParameters)
- Specified by:
getEndpointReferencein classjavax.xml.ws.Endpoint
-
setEndpointContext
public void setEndpointContext(javax.xml.ws.EndpointContext ctxt)
- Overrides:
setEndpointContextin classjavax.xml.ws.Endpoint
-
getEndpointContext
public javax.xml.ws.EndpointContext getEndpointContext()
-
publish
public void publish(javax.xml.ws.spi.http.HttpContext context)
- Overrides:
publishin classjavax.xml.ws.Endpoint
-
close
public void close() throws Exception- Specified by:
closein interfaceAutoCloseable- Throws:
Exception
-
-