org.objectweb.speedo.pm.lib
Class SpeedoProxyManagerInstanciator
java.lang.Object
org.objectweb.speedo.pm.lib.SpeedoProxyManagerInstanciator
- All Implemented Interfaces:
- org.objectweb.fractal.api.control.BindingController, org.objectweb.fractal.api.control.LifeCycleController, org.objectweb.perseus.pool.api.PoolMatchFactory
- public class SpeedoProxyManagerInstanciator
- extends java.lang.Object
- implements org.objectweb.perseus.pool.api.PoolMatchFactory, org.objectweb.fractal.api.control.BindingController, org.objectweb.fractal.api.control.LifeCycleController
is a primitive components in charge of the ProxyManager and the Transaction
allocation. It exports the PoolMatchFactory interface in order to be used by
a Pool as Factory of pool resource. The pool resource is the ProxyManager
instance.
It uses a ConnectionHolderFactory for allocating ConnectionHolder to the
created Transaction components.
- Author:
- S.Chassande-Barrioz
- See Also:
ProxyManager
,
SpeedoProxyManager
,
Transaction
,
SpeedoTransaction
,
ConnectionHolder
,
ConnectionHolderFactory
Fields inherited from interface org.objectweb.fractal.api.control.LifeCycleController |
STARTED, STOPPED |
Method Summary |
void |
bindFc(java.lang.String c,
java.lang.Object s)
|
java.lang.Object |
createResource(java.lang.Object o)
Creates a new PoolResource . |
void |
destroyResource(java.lang.Object resource)
It removes the ProxyManager and the Transaction components from the
Speedo composite. |
java.lang.String |
getFcState()
|
java.lang.String[] |
listFc()
|
java.lang.Object |
lookupFc(java.lang.String c)
|
boolean |
matchResource(java.lang.Object resource,
java.lang.Object o)
|
void |
startFc()
Startes the component by computing the components array. |
void |
stopFc()
Clears the components array. |
void |
unbindFc(java.lang.String c)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CONNECTION_HOLDER_FACTORY_BINDING
public static final java.lang.String CONNECTION_HOLDER_FACTORY_BINDING
- See Also:
- Constant Field Values
COMPONENT_BINDING
public static final java.lang.String COMPONENT_BINDING
- See Also:
- Constant Field Values
PM_TEMPLATE
public static final java.lang.String PM_TEMPLATE
- See Also:
- Constant Field Values
T_TEMPLATE
public static final java.lang.String T_TEMPLATE
- See Also:
- Constant Field Values
SpeedoProxyManagerInstanciator
public SpeedoProxyManagerInstanciator()
getFcState
public java.lang.String getFcState()
- Specified by:
getFcState
in interface org.objectweb.fractal.api.control.LifeCycleController
startFc
public void startFc()
throws org.objectweb.fractal.api.control.IllegalLifeCycleException
- Startes the component by computing the components array.
- Specified by:
startFc
in interface org.objectweb.fractal.api.control.LifeCycleController
- Throws:
org.objectweb.fractal.api.control.IllegalLifeCycleException
stopFc
public void stopFc()
throws org.objectweb.fractal.api.control.IllegalLifeCycleException
- Clears the components array.
- Specified by:
stopFc
in interface org.objectweb.fractal.api.control.LifeCycleController
- Throws:
org.objectweb.fractal.api.control.IllegalLifeCycleException
listFc
public java.lang.String[] listFc()
- Specified by:
listFc
in interface org.objectweb.fractal.api.control.BindingController
lookupFc
public java.lang.Object lookupFc(java.lang.String c)
- Specified by:
lookupFc
in interface org.objectweb.fractal.api.control.BindingController
bindFc
public void bindFc(java.lang.String c,
java.lang.Object s)
- Specified by:
bindFc
in interface org.objectweb.fractal.api.control.BindingController
unbindFc
public void unbindFc(java.lang.String c)
- Specified by:
unbindFc
in interface org.objectweb.fractal.api.control.BindingController
createResource
public java.lang.Object createResource(java.lang.Object o)
throws org.objectweb.perseus.pool.api.PoolException
- Creates a new
PoolResource
.
This methos is invoked by the owned Pool
.
A new SpeedoProxyManager and a new SpeedoTransaction component are
created, and added into the Speedo composite.
- Specified by:
createResource
in interface org.objectweb.perseus.pool.api.PoolMatchFactory
- Parameters:
o
- params used to build a new PoolResource
- Returns:
- the build
SpeedoProxyManager
- Throws:
org.objectweb.perseus.pool.api.PoolException
matchResource
public boolean matchResource(java.lang.Object resource,
java.lang.Object o)
- Specified by:
matchResource
in interface org.objectweb.perseus.pool.api.PoolMatchFactory
destroyResource
public void destroyResource(java.lang.Object resource)
- It removes the ProxyManager and the Transaction components from the
Speedo composite.
- Specified by:
destroyResource
in interface org.objectweb.perseus.pool.api.PoolMatchFactory
- Parameters:
resource
- is the ProxyManager to destroy.