Interface ManagedObjectContainer
- 
- All Known Implementing Classes:
- ManagedObjectContainerImpl
 
 public interface ManagedObjectContainerContainer managing aManagedObject.- Author:
- Daniel Sagenschneider
 
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description FunctionStatecheckReady(ManagedObjectReadyCheck check)Creates aFunctionStateto check if theManagedObjectcontained within thisManagedObjectContaineris ready.<E> FunctionStateextractExtension(ManagedObjectExtensionExtractor<E> extractor, E[] managedObjectExtensions, int extensionIndex, TeamManagement responsibleTeam)Extracts theManagedObjectextension from theManagedObjectcontained in thisManagedObjectContainer.java.lang.ObjectgetObject()Obtains the object being managed by theManagedObject.java.lang.ObjectgetOptionalObject()Obtains the object only if available, otherwisenull.ThreadStategetResponsibleThreadState()Obtains theThreadStateresponsible for changes to thisManagedObjectContainer.FunctionStateloadManagedObject(ManagedFunctionContainer managedFunctionContainer)Creates aFunctionStateto load theManagedObject.FunctionStateunloadManagedObject()Creates aFunctionStateto unload theManagedObject.FunctionStateunregisterGovernance(int governanceIndex)Unregisters theManagedObjectfromGovernance.
 
- 
- 
- 
Method Detail- 
getResponsibleThreadStateThreadState getResponsibleThreadState() Obtains theThreadStateresponsible for changes to thisManagedObjectContainer.- Returns:
- ThreadStateresponsible for changes to this- ManagedObjectContainer.
 
 - 
loadManagedObjectFunctionState loadManagedObject(ManagedFunctionContainer managedFunctionContainer) Creates aFunctionStateto load theManagedObject.- Parameters:
- managedFunctionContainer-- ManagedFunctionContainerrequiring the- ManagedObject.
- Returns:
- Optional FunctionStateto load theManagedObject. Should this returnnull, theManagedFunctionContainershould not then be executed, as it is expecting to wait. This will return theManagedFunctionContainerwhen theManagedObjectis loaded.
 
 - 
checkReadyFunctionState checkReady(ManagedObjectReadyCheck check) Creates a FunctionStateto check if theManagedObjectcontained within thisManagedObjectContaineris ready.Should the ManagedObjectnot be ready, then will latch to wait for theManagedObjectto be ready.- Parameters:
- check-- ManagedObjectReadyCheck.
- Returns:
- FunctionStateto check if the- ManagedObjectcontained within this- ManagedObjectContaineris ready.
 
 - 
extractExtension<E> FunctionState extractExtension(ManagedObjectExtensionExtractor<E> extractor, E[] managedObjectExtensions, int extensionIndex, TeamManagement responsibleTeam) Extracts the ManagedObjectextension from theManagedObjectcontained in thisManagedObjectContainer.Should the ManagedObjectnot be loaded, then noManagedObjectextension will be loaded.- Type Parameters:
- E- Extension type.
- Parameters:
- extractor-- ManagedObjectExtensionExtractor.
- managedObjectExtensions-- Listto load the- ManagedObjectextension.
- extensionIndex- Index within the- ManagedObjectextensions array to load the extension.
- responsibleTeam-- TeamManagementresponsible for extracting the extension. May be- nullto use any- Team.
- Returns:
- FunctionStateto load the- ManagedObjectextension.
 
 - 
getObjectjava.lang.Object getObject() Obtains the object being managed by theManagedObject.- Returns:
- Object being managed by the ManagedObject.
 
 - 
getOptionalObjectjava.lang.Object getOptionalObject() Obtains the object only if available, otherwisenull.- Returns:
- Object being managed by the ManagedObjectornullif not yet available.
- See Also:
- OptionalThreadLocal
 
 - 
unregisterGovernanceFunctionState unregisterGovernance(int governanceIndex) Unregisters theManagedObjectfromGovernance.- Parameters:
- governanceIndex- Index of the- Governance.
- Returns:
- FunctionStateto unregister the- ManagedObjectfrom- Governance.
 
 - 
unloadManagedObjectFunctionState unloadManagedObject() Creates aFunctionStateto unload theManagedObject.- Returns:
- FunctionStateto unload the- ManagedObject.
 
 
- 
 
-