|
||||||||||
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
public class StaticServiceFactory
A basic service factory that always creates the supplied object.
Constructor Summary | |
---|---|
StaticServiceFactory(Object service)
Creates a non-restartable service factory which will simply returns the specified service from the createService method. |
|
StaticServiceFactory(Object service,
ClassLoader classLoader)
Creates a non-restartable service factory which will simply returns the specified service from the createService method. |
Method Summary | |
---|---|
Object |
createService(ServiceContext serviceContext)
Returns the static service instance. |
void |
destroyService(ServiceContext serviceContext)
This method is a noop. |
ClassLoader |
getClassLoader()
Gets the class loader associated with this service. |
Set |
getOwnedServices()
Gets the names of services owned by this service. |
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. |
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(Object service) throws NullPointerException
service
- the static to which this factory "creates"
NullPointerException
- if service is nullpublic StaticServiceFactory(Object service, ClassLoader classLoader) throws NullPointerException
service
- the static to which this factory "creates"classLoader
- the classLoader used to load the service class
NullPointerException
- if service or classLoader is nullMethod Detail |
---|
public Class[] getTypes()
ServiceFactory
public boolean isRestartable()
public Set getOwnedServices()
public Object createService(ServiceContext serviceContext)
serviceContext
- ignored
public void destroyService(ServiceContext serviceContext)
serviceContext
- ignoredpublic ClassLoader getClassLoader()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |