org.codehaus.xfire.spring
Class ServiceBean

java.lang.Object
  extended by org.codehaus.xfire.spring.ServiceBean
All Implemented Interfaces:
org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware
Direct Known Subclasses:
XFireExporter

public class ServiceBean
extends java.lang.Object
implements org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware

A convenience bean which creates a Service from a ServiceFactory instance. If there is no ServiceFactory set, ServiceBean will create one from the ObjectServiceFactory.

Alternatively, the Jsr181BeanPostProcessor or the XFireExportermay be used.

Author:
Dan Diephouse , Arjen Poutsma, Tomasz Sztelak
See Also:
Service, Jsr181BeanPostProcessor, ObjectServiceFactory, XFireExporter

Field Summary
protected  boolean createDefaultBindings
          Some properties to make it easier to work with ObjectServiceFactory
protected  java.lang.Class implementationClass
           
protected  java.lang.String style
           
protected  java.lang.String use
           
protected  org.codehaus.xfire.XFire xFire
           
 
Constructor Summary
ServiceBean()
           
 
Method Summary
 void afterPropertiesSet()
           
 java.util.List getBindings()
           
 java.lang.Object getExecutor()
           
 java.util.List getFaultHandlers()
           
 java.lang.Class getImplementationClass()
           
 java.util.List getInHandlers()
           
 org.codehaus.xfire.service.invoker.Invoker getInvoker()
           
 java.util.List getMethods()
           
 java.util.List getOutHandlers()
           
 java.util.Map getProperties()
           
protected  java.lang.Object getProxyForService()
           
 java.util.List getSchemas()
           
 java.lang.String getScope()
           
 java.lang.Object getServiceBean()
          Gets the object which backs this service.
 java.lang.Class getServiceClass()
          Set the service class.
 org.codehaus.xfire.service.ServiceFactory getServiceFactory()
           
 java.lang.String getStyle()
           
 java.lang.String getUse()
           
 java.lang.String getWsdlURL()
           
 org.codehaus.xfire.XFire getXfire()
           
 org.codehaus.xfire.service.Service getXFireService()
          Gets the XFire Service created by this bean.
protected  void initializeBindings()
           
 boolean isCreateDefaultBindings()
           
 void setApplicationContext(org.springframework.context.ApplicationContext ctx)
           
 void setBindings(java.util.List bindings)
           
 void setCreateDefaultBindings(boolean createDefaultBindings)
           
 void setExecutor(java.lang.Object executor)
           
 void setFaultHandlers(java.util.List faultHandlers)
           
 void setImplementationClass(java.lang.Class implementationClass)
           
 void setInHandlers(java.util.List inHandlers)
           
 void setInvoker(org.codehaus.xfire.service.invoker.Invoker invoker)
           
 void setMethods(java.util.List operations)
           
 void setName(java.lang.String name)
          Sets the service name.
 void setNamespace(java.lang.String namespace)
          Sets the service default namespace.
 void setOutHandlers(java.util.List outHandlers)
           
 void setProperties(java.util.Map properties)
           
 void setSchemas(java.util.List schemas)
           
 void setScope(java.lang.String scope)
           
 void setServiceBean(java.lang.Object service)
          Sets the object which backs this service.
 void setServiceClass(java.lang.Class serviceInterface)
           
 void setServiceFactory(org.codehaus.xfire.service.ServiceFactory serviceFactory)
           
 void setStyle(java.lang.String style)
           
 void setUse(java.lang.String use)
           
 void setWsdlURL(java.lang.String wsdlURL)
           
 void setXfire(org.codehaus.xfire.XFire xFire)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

xFire

protected org.codehaus.xfire.XFire xFire

implementationClass

protected java.lang.Class implementationClass

createDefaultBindings

protected boolean createDefaultBindings
Some properties to make it easier to work with ObjectServiceFactory


use

protected java.lang.String use

style

protected java.lang.String style
Constructor Detail

ServiceBean

public ServiceBean()
Method Detail

afterPropertiesSet

public void afterPropertiesSet()
                        throws java.lang.Exception
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Throws:
java.lang.Exception

initializeBindings

protected void initializeBindings()
                           throws java.lang.Exception
Throws:
java.lang.Exception

getProxyForService

protected java.lang.Object getProxyForService()
Returns:

getXFireService

public org.codehaus.xfire.service.Service getXFireService()
Gets the XFire Service created by this bean.

Returns:
See Also:
Service

getServiceBean

public java.lang.Object getServiceBean()
Gets the object which backs this service.

Returns:

setServiceBean

public void setServiceBean(java.lang.Object service)
Sets the object which backs this service.


getServiceClass

public java.lang.Class getServiceClass()
Set the service class. The service class is passed to the ServiceFactory's create method and is used to determine the operations on the service.

Returns:

setServiceClass

public void setServiceClass(java.lang.Class serviceInterface)

setServiceFactory

public void setServiceFactory(org.codehaus.xfire.service.ServiceFactory serviceFactory)

getServiceFactory

public org.codehaus.xfire.service.ServiceFactory getServiceFactory()

setName

public void setName(java.lang.String name)
Sets the service name. Default is the bean name of this exporter.


setNamespace

public void setNamespace(java.lang.String namespace)
Sets the service default namespace. Default is a namespace based on the package of the service interface.


getFaultHandlers

public java.util.List getFaultHandlers()

setFaultHandlers

public void setFaultHandlers(java.util.List faultHandlers)

getInHandlers

public java.util.List getInHandlers()

setInHandlers

public void setInHandlers(java.util.List inHandlers)

getOutHandlers

public java.util.List getOutHandlers()

setOutHandlers

public void setOutHandlers(java.util.List outHandlers)

setXfire

public void setXfire(org.codehaus.xfire.XFire xFire)

getXfire

public org.codehaus.xfire.XFire getXfire()

getImplementationClass

public java.lang.Class getImplementationClass()

setImplementationClass

public void setImplementationClass(java.lang.Class implementationClass)

getProperties

public java.util.Map getProperties()
Returns:

setProperties

public void setProperties(java.util.Map properties)

getScope

public java.lang.String getScope()

setScope

public void setScope(java.lang.String scope)

getStyle

public java.lang.String getStyle()

setStyle

public void setStyle(java.lang.String style)

getUse

public java.lang.String getUse()

setUse

public void setUse(java.lang.String use)

getSchemas

public java.util.List getSchemas()

setSchemas

public void setSchemas(java.util.List schemas)

setApplicationContext

public void setApplicationContext(org.springframework.context.ApplicationContext ctx)
                           throws org.springframework.beans.BeansException
Specified by:
setApplicationContext in interface org.springframework.context.ApplicationContextAware
Throws:
org.springframework.beans.BeansException

getBindings

public java.util.List getBindings()

setBindings

public void setBindings(java.util.List bindings)

getInvoker

public org.codehaus.xfire.service.invoker.Invoker getInvoker()

setInvoker

public void setInvoker(org.codehaus.xfire.service.invoker.Invoker invoker)

isCreateDefaultBindings

public boolean isCreateDefaultBindings()

getExecutor

public java.lang.Object getExecutor()

setExecutor

public void setExecutor(java.lang.Object executor)

setCreateDefaultBindings

public void setCreateDefaultBindings(boolean createDefaultBindings)

getWsdlURL

public java.lang.String getWsdlURL()

setWsdlURL

public void setWsdlURL(java.lang.String wsdlURL)

getMethods

public java.util.List getMethods()
Returns:

setMethods

public void setMethods(java.util.List operations)


Copyright © 2004-2008. All Rights Reserved.