Package org.apache.cxf.frontend
Class ClientProxyFactoryBean
java.lang.Object
org.apache.cxf.interceptor.AbstractBasicInterceptorProvider
org.apache.cxf.frontend.ClientProxyFactoryBean
- All Implemented Interfaces:
org.apache.cxf.interceptor.InterceptorProvider
- Direct Known Subclasses:
ClientProxyFactoryBeanDefinitionParser.SpringClientProxyFactoryBean
public class ClientProxyFactoryBean
extends org.apache.cxf.interceptor.AbstractBasicInterceptorProvider
This class will create a client for you which implements the specified
service class. Example:
ClientProxyFactoryBean factory = new ClientProxyFactoryBean(); factory.setServiceClass(YourServiceInterface.class); YourServiceInterface client = (YourServiceInterface) factory.create();To access the underlying Client object:
Client cxfClient = ClientProxy.getClient(client);
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected ClientProxy
clientClientProxy
(org.apache.cxf.endpoint.Client c) create()
Creates a proxy object that can be used to make remote invocations.<ProxyServiceType>
ProxyServiceTypeCreate a proxy object that implements a specified Service Endpoint Interface.org.apache.cxf.binding.BindingConfiguration
org.apache.cxf.Bus
getBus()
org.apache.cxf.endpoint.ConduitSelector
protected String
org.apache.cxf.databinding.DataBinding
List<org.apache.cxf.feature.Feature>
protected Class<?>[]
Returns the property map for the proxy factory.Class<?>
org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean
Returns the QName of the WSDL service the proxy implementsvoid
void
setAddress
(String add) void
setBindingConfig
(org.apache.cxf.binding.BindingConfiguration config) void
setBindingId
(String bind) void
setBus
(org.apache.cxf.Bus bus) void
setClientFactoryBean
(ClientFactoryBean clientFactoryBean) void
setConduitSelector
(org.apache.cxf.endpoint.ConduitSelector selector) void
setDataBinding
(org.apache.cxf.databinding.DataBinding dataBinding) void
setEndpointName
(QName endpointName) void
setFeatures
(List<? extends org.apache.cxf.feature.Feature> f) void
setPassword
(String password) void
setProperties
(Map<String, Object> properties) Specifies a set of properties used to configure the proxies provided by the factory.void
setServiceClass
(Class<?> serviceClass) Specifies the class representing the SEI the proxy implements.void
setServiceFactory
(org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean sf) void
setServiceName
(QName serviceName) Specifies the QName of the WSDL service the proxy implements.void
setTransportId
(String transportId) void
setUsername
(String username) void
setWsdlLocation
(String wsdlURL) Specifies the URL where the proxy can find the WSDL defining the service the proxy implements.void
setWsdlURL
(String wsdlURL) Specifies the URL where the proxy can find the WSDL defining the service the proxy implements.Methods inherited from class org.apache.cxf.interceptor.AbstractBasicInterceptorProvider
getInFaultInterceptors, getInInterceptors, getOutFaultInterceptors, getOutInterceptors, setInFaultInterceptors, setInInterceptors, setOutFaultInterceptors, setOutInterceptors
-
Field Details
-
configured
protected boolean configured
-
-
Constructor Details
-
ClientProxyFactoryBean
public ClientProxyFactoryBean() -
ClientProxyFactoryBean
-
-
Method Details
-
initFeatures
public void initFeatures() -
create
Create a proxy object that implements a specified Service Endpoint Interface. This method is a combination ofsetServiceClass(Class)
andcreate()
.- Type Parameters:
ProxyServiceType
- The type for the SEI.- Parameters:
serviceClass
- The Java class object representing the interface you want.- Returns:
- the proxy.
-
getConfiguredName
-
create
Creates a proxy object that can be used to make remote invocations.- Returns:
- the proxy. You must cast the returned object to the appropriate class before using it.
-
getImplementingClasses
-
clientClientProxy
-
getClientFactoryBean
-
setClientFactoryBean
-
getPassword
-
setPassword
-
getServiceClass
-
setServiceClass
Specifies the class representing the SEI the proxy implements.- Parameters:
serviceClass
- the SEI's class
-
getUsername
-
setUsername
-
getWsdlLocation
-
setWsdlLocation
Specifies the URL where the proxy can find the WSDL defining the service the proxy implements.- Parameters:
wsdlURL
- a string containing the WSDL's URL
-
getWsdlURL
-
setWsdlURL
Specifies the URL where the proxy can find the WSDL defining the service the proxy implements.- Parameters:
wsdlURL
- a string containing the WSDL's URL
-
getEndpointName
-
setEndpointName
-
getServiceName
Returns the QName of the WSDL service the proxy implements- Returns:
- the WSDL service's QName
-
setServiceName
Specifies the QName of the WSDL service the proxy implements. The service must exist or an error will result.- Parameters:
serviceName
- the QName of the service for the proxy
-
getAddress
-
setAddress
-
getConduitSelector
public org.apache.cxf.endpoint.ConduitSelector getConduitSelector() -
setConduitSelector
public void setConduitSelector(org.apache.cxf.endpoint.ConduitSelector selector) -
setBindingId
-
getBindingId
-
setTransportId
-
getTransportId
-
getServiceFactory
public org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean getServiceFactory() -
setServiceFactory
public void setServiceFactory(org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean sf) -
getBus
public org.apache.cxf.Bus getBus() -
setBus
public void setBus(org.apache.cxf.Bus bus) -
getProperties
Returns the property map for the proxy factory.- Returns:
- the property map
-
setProperties
Specifies a set of properties used to configure the proxies provided by the factory. These properties include things like adding a namespace map to the JAXB databinding.- Parameters:
properties
- the property map
-
getFeatures
-
setFeatures
-
getDataBinding
public org.apache.cxf.databinding.DataBinding getDataBinding() -
setDataBinding
public void setDataBinding(org.apache.cxf.databinding.DataBinding dataBinding) -
setBindingConfig
public void setBindingConfig(org.apache.cxf.binding.BindingConfiguration config) -
getBindingConfig
public org.apache.cxf.binding.BindingConfiguration getBindingConfig()
-