groovyx.net.ws
Class AbstractCXFWSClient

java.lang.Object
  extended by groovy.lang.GroovyObjectSupport
      extended by groovyx.net.ws.AbstractCXFWSClient
All Implemented Interfaces:
groovy.lang.GroovyObject, IWSClient<org.apache.cxf.endpoint.Client>
Direct Known Subclasses:
WSClient

public abstract class AbstractCXFWSClient
extends groovy.lang.GroovyObjectSupport
implements IWSClient<org.apache.cxf.endpoint.Client>

Since:
0.5
Author:
Tog, Dennis Bayer, Basile Clout

Field Summary
protected  BasicAuthenticationHelper basicAuthHelper
          A helper to set the basic auth configuration.
protected  org.apache.cxf.endpoint.Client client
          The webservice-client
protected  ConnectionTimeoutHelper connectionTimeoutHelper
          A helper to set the connection timeout.
protected  MtomHelper mtomHelper
          A helper to set the MTOM configuration.
protected  ProxyHelper proxyHelper
          A helper to set the proxy configuration.
protected  SoapHelper soapHelper
          A helper to set the SOAP configuration.
protected  SSLHelper sslHelper
          A helper to set the ssl configuration.
 
Constructor Summary
AbstractCXFWSClient()
           
 
Method Summary
 java.lang.Object create(java.lang.String classname)
          Creates an object for the given classname using the classloader of the current thread.
 org.apache.cxf.endpoint.Client createClient(java.lang.Object... args)
          The cxf-implementation of IWSClient.
protected  org.apache.cxf.service.model.BindingOperationInfo getBindingOperationInfo(javax.xml.namespace.QName qname)
          Returns the BindingOperationInfo for the given QName.
protected  java.util.logging.Logger getLogger()
           
protected  java.lang.String getServiceNamespaceURI()
          Returns the ServiceNamespaceURI of the currently set service.
 java.lang.Object invokeMethod(java.lang.String name, java.lang.Object args)
          Invokes the webservice-method.
protected  java.lang.Object parseResponse(java.lang.Object[] response)
          Parses the response.
 
Methods inherited from class groovy.lang.GroovyObjectSupport
getMetaClass, getProperty, setMetaClass, setProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface groovyx.net.ws.IWSClient
initialize
 

Field Detail

client

protected org.apache.cxf.endpoint.Client client
The webservice-client


sslHelper

protected SSLHelper sslHelper
A helper to set the ssl configuration.


proxyHelper

protected ProxyHelper proxyHelper
A helper to set the proxy configuration.


basicAuthHelper

protected BasicAuthenticationHelper basicAuthHelper
A helper to set the basic auth configuration.


connectionTimeoutHelper

protected ConnectionTimeoutHelper connectionTimeoutHelper
A helper to set the connection timeout.


mtomHelper

protected MtomHelper mtomHelper
A helper to set the MTOM configuration.


soapHelper

protected SoapHelper soapHelper
A helper to set the SOAP configuration.

Constructor Detail

AbstractCXFWSClient

public AbstractCXFWSClient()
Method Detail

getLogger

protected java.util.logging.Logger getLogger()
Returns:
The logger for the class

invokeMethod

public java.lang.Object invokeMethod(java.lang.String name,
                                     java.lang.Object args)
Description copied from interface: IWSClient
Invokes the webservice-method.

Specified by:
invokeMethod in interface groovy.lang.GroovyObject
Specified by:
invokeMethod in interface IWSClient<org.apache.cxf.endpoint.Client>
Overrides:
invokeMethod in class groovy.lang.GroovyObjectSupport
Parameters:
name - The name of the method.
args - The arguments of the method.
Returns:
The result of the call.

parseResponse

protected java.lang.Object parseResponse(java.lang.Object[] response)
Parses the response.

Parameters:
response - The object-array which contains the result
Returns:
The modified response.

getBindingOperationInfo

protected final org.apache.cxf.service.model.BindingOperationInfo getBindingOperationInfo(javax.xml.namespace.QName qname)
Returns the BindingOperationInfo for the given QName.

Parameters:
qname - The QName of the operation.
Returns:
A BindingOperationInfo.
See Also:
invokeMethod(String, Object)

getServiceNamespaceURI

protected final java.lang.String getServiceNamespaceURI()
Returns the ServiceNamespaceURI of the currently set service.

Returns:
A string containing the ServiceNamespaceURI.
See Also:
invokeMethod(String, Object)

create

public java.lang.Object create(java.lang.String classname)
Creates an object for the given classname using the classloader of the current thread.

Parameters:
classname - The classname of the object which should be created.
Returns:
An instance of the class.

createClient

public org.apache.cxf.endpoint.Client createClient(java.lang.Object... args)
The cxf-implementation of IWSClient.

Specified by:
createClient in interface IWSClient<org.apache.cxf.endpoint.Client>
Parameters:
args - : url (The url of the wsdl-file), cl (The classloader)
Returns:
An instance of C.
See Also:
IWSClient.createClient(java.lang.Object[])