Package net.officefloor.web.state
Class HttpApplicationObjectManagedObjectSource.HttpApplicationObjectManagedObject
java.lang.Object
net.officefloor.web.state.HttpApplicationObjectManagedObjectSource.HttpApplicationObjectManagedObject
- All Implemented Interfaces:
ContextAwareManagedObject,CoordinatingManagedObject<HttpApplicationObjectManagedObjectSource.Dependencies>,ManagedObject
- Enclosing class:
- HttpApplicationObjectManagedObjectSource
public static class HttpApplicationObjectManagedObjectSource.HttpApplicationObjectManagedObject
extends Object
implements ContextAwareManagedObject, CoordinatingManagedObject<HttpApplicationObjectManagedObjectSource.Dependencies>
ManagedObject to retrieve the object from the
HttpApplicationState.-
Constructor Summary
ConstructorsConstructorDescriptionHttpApplicationObjectManagedObject(Class<?> objectClass, String bindName) Initiate. -
Method Summary
Modifier and TypeMethodDescriptionObtains the object being managed.voidLoads the Objects of theManagedObjectinstances to be referenced by thisCoordinatingManagedObject.voidProvides theManagedObjectContextto theManagedObject.
-
Constructor Details
-
HttpApplicationObjectManagedObject
Initiate.- Parameters:
objectClass- Class of the object.bindName- Specific name to bind the object into theHttpApplicationState.
-
-
Method Details
-
setManagedObjectContext
Description copied from interface:ContextAwareManagedObjectProvides theManagedObjectContextto theManagedObject.- Specified by:
setManagedObjectContextin interfaceContextAwareManagedObject- Parameters:
context-ManagedObjectContext.
-
loadObjects
public void loadObjects(ObjectRegistry<HttpApplicationObjectManagedObjectSource.Dependencies> registry) throws Throwable Description copied from interface:CoordinatingManagedObjectLoads the Objects of the
ManagedObjectinstances to be referenced by thisCoordinatingManagedObject.References to the loaded Objects must be released on recycling the
ManagedObject.- Specified by:
loadObjectsin interfaceCoordinatingManagedObject<HttpApplicationObjectManagedObjectSource.Dependencies>- Parameters:
registry- Registry of the Objects for theManagedObjectinstances.- Throws:
Throwable- Should thisCoordinatingManagedObjectfail to load theManagedObject.
-
getObject
Description copied from interface:ManagedObjectObtains the object being managed.- Specified by:
getObjectin interfaceManagedObject- Returns:
- Object being managed.
- Throws:
Throwable- Indicating failed to obtain the object for use.
-