|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.xbean.kernel.AbstractServiceFactory
org.apache.xbean.kernel.StaticServiceFactory
A basic service factory that always creates the supplied object.
Constructor Summary | |
StaticServiceFactory(java.lang.Object service)
Creates a non-restartable service factory which will simply returns the specified service from the createService method. |
Method Summary | |
java.lang.Object |
createService(ServiceContext serviceContext)
Returns the static service instance. |
void |
destroyService(ServiceContext serviceContext)
This method is a noop. |
java.util.Set |
getOwnedServices()
Gets the names of services owned by this service. This information is used for the startRecursive method on the kernel. When a servcie is started with startRecursive all owned services will be started with startRecursive. |
java.lang.Class[] |
getTypes()
Gets the types of the service this service factory will create. |
boolean |
isRestartable()
A restartable service can be started and stopped repeatedly in the kernel. A service that is not restartable immediately enters the RUNNING state when registered with the kernel, and can not be started or stopped. |
Methods inherited from class org.apache.xbean.kernel.AbstractServiceFactory |
addStartCondition, addStopCondition, getStartConditions, getStopConditions, isEnabled, removeStartCondition, removeStopCondition, setEnabled |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StaticServiceFactory(java.lang.Object service) throws java.lang.NullPointerException
service
- the static to which this factory "creates"
java.lang.NullPointerException
- if service is nullMethod Detail |
public java.lang.Class[] getTypes()
ServiceFactory
public boolean isRestartable()
public java.util.Set getOwnedServices()
public java.lang.Object createService(ServiceContext serviceContext)
serviceContext
- ignored
public void destroyService(ServiceContext serviceContext)
serviceContext
- ignored
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |