Class ManagedObjectPoolNodeImpl
- java.lang.Object
-
- net.officefloor.compile.impl.structure.ManagedObjectPoolNodeImpl
-
- All Implemented Interfaces:
LinkPoolNode,ManagedObjectPoolNode,Node,PropertyConfigurable,OfficeManagedObjectPool,OfficeFloorManagedObjectPool,SectionManagedObjectPool
public class ManagedObjectPoolNodeImpl extends java.lang.Object implements ManagedObjectPoolNode
ManagedObjectPoolNodeimplementation.- Author:
- Daniel Sagenschneider
-
-
Field Summary
-
Fields inherited from interface net.officefloor.compile.internal.structure.ManagedObjectPoolNode
TYPE
-
-
Constructor Summary
Constructors Constructor Description ManagedObjectPoolNodeImpl(java.lang.String managedObjectPoolName, SectionNode containingSectionNode, OfficeNode containingOfficeNode, OfficeFloorNode containingOfficeFloorNode, NodeContext context)Instantiate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddProperty(java.lang.String name, java.lang.String value)================== PropertyConfigurable ====================voidbuildManagedObjectPool(ManagedObjectBuilder<?> builder, ManagedObjectType<?> managedObjectType, CompileContext compileContext)BuildsManagedObjectPoolfor thisManagedObjectPoolNode.Node[]getChildNodes()Obtains the childNodeinstances.LinkPoolNodegetLinkedPoolNode()Obtains theLinkPoolNodelinked to thisLinkPoolNode.java.lang.StringgetLocation()Obtains the location of theNode.java.lang.StringgetNodeName()Obtains the name of theNode.java.lang.StringgetNodeType()Obtains theNodetype.java.lang.StringgetOfficeFloorManagedObjectPoolName()Obtains the name of thisOfficeFloorManagedObjectPool.java.lang.StringgetOfficeManagedObjectPoolName()Obtains the name of thisOfficeManagedObjectPool.NodegetParentNode()java.lang.StringgetSectionManagedObjectPoolName()Obtains the name of thisSectionManagedObjectPool.voidinitialise(java.lang.String managedObjectPoolSourceClassName, ManagedObjectPoolSource managedObjectPoolSource)Initialises theManagedObjectPoolNode.booleanisInitialised()Indicates if theNodehas been initialised.booleanlinkPoolNode(LinkPoolNode node)Links the inputLinkPoolNodeto thisLinkPoolNode.ManagedObjectPoolTypeloadManagedObjectPoolType(boolean isLoadingType)Loads theManagedObjectPoolType.booleansourceManagedObjectPool(CompileContext compileContext)Sources theManagedObjectPool.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.officefloor.compile.internal.structure.Node
getQualifiedName, getQualifiedName
-
-
-
-
Constructor Detail
-
ManagedObjectPoolNodeImpl
public ManagedObjectPoolNodeImpl(java.lang.String managedObjectPoolName, SectionNode containingSectionNode, OfficeNode containingOfficeNode, OfficeFloorNode containingOfficeFloorNode, NodeContext context)Instantiate.- Parameters:
managedObjectPoolName- Name of thisManagedObjectPoolNode.containingSectionNode- ContainingSectionNode.nullif contained in theOfficeorOfficeFloor.containingOfficeNode- ContainingOfficeNode.nullif contained in theOfficeFloor.containingOfficeFloorNode- ContainingOfficeFloorNode.context-NodeContext.
-
-
Method Detail
-
getNodeName
public java.lang.String getNodeName()
Description copied from interface:NodeObtains the name of theNode.- Specified by:
getNodeNamein interfaceNode- Returns:
- Name of the
Node.
-
getNodeType
public java.lang.String getNodeType()
Description copied from interface:NodeObtains theNodetype.- Specified by:
getNodeTypein interfaceNode- Returns:
Nodetype.
-
getLocation
public java.lang.String getLocation()
Description copied from interface:NodeObtains the location of theNode.- Specified by:
getLocationin interfaceNode- Returns:
- Location of the
Node. May benullifNodedoes not support a location.
-
getParentNode
public Node getParentNode()
Description copied from interface:Node- Specified by:
getParentNodein interfaceNode- Returns:
Nodecontaining thisNode.
-
getChildNodes
public Node[] getChildNodes()
Description copied from interface:NodeObtains the childNodeinstances.- Specified by:
getChildNodesin interfaceNode- Returns:
- Child
Nodeinstances.
-
isInitialised
public boolean isInitialised()
Description copied from interface:NodeIndicates if theNodehas been initialised.Nodeinstances should only be initialised once. Initialising theNodetwice is an issue.- Specified by:
isInitialisedin interfaceNode- Returns:
trueif initialised.
-
initialise
public void initialise(java.lang.String managedObjectPoolSourceClassName, ManagedObjectPoolSource managedObjectPoolSource)Description copied from interface:ManagedObjectPoolNodeInitialises theManagedObjectPoolNode.- Specified by:
initialisein interfaceManagedObjectPoolNode- Parameters:
managedObjectPoolSourceClassName- Class name of theManagedObjectPoolSource.managedObjectPoolSource- Optional instantiatedManagedObjectPoolSource. May benull.
-
getOfficeFloorManagedObjectPoolName
public java.lang.String getOfficeFloorManagedObjectPoolName()
Description copied from interface:OfficeFloorManagedObjectPoolObtains the name of thisOfficeFloorManagedObjectPool.- Specified by:
getOfficeFloorManagedObjectPoolNamein interfaceOfficeFloorManagedObjectPool- Returns:
- Name of this
OfficeFloorManagedObjectPool.
-
getOfficeManagedObjectPoolName
public java.lang.String getOfficeManagedObjectPoolName()
Description copied from interface:OfficeManagedObjectPoolObtains the name of thisOfficeManagedObjectPool.- Specified by:
getOfficeManagedObjectPoolNamein interfaceOfficeManagedObjectPool- Returns:
- Name of this
OfficeManagedObjectPool.
-
getSectionManagedObjectPoolName
public java.lang.String getSectionManagedObjectPoolName()
Description copied from interface:SectionManagedObjectPoolObtains the name of thisSectionManagedObjectPool.- Specified by:
getSectionManagedObjectPoolNamein interfaceSectionManagedObjectPool- Returns:
- Name of this
SectionManagedObjectPool.
-
addProperty
public void addProperty(java.lang.String name, java.lang.String value)================== PropertyConfigurable ====================- Specified by:
addPropertyin interfacePropertyConfigurable- Parameters:
name- Name ofProperty.value- Value ofProperty.
-
loadManagedObjectPoolType
public ManagedObjectPoolType loadManagedObjectPoolType(boolean isLoadingType)
Description copied from interface:ManagedObjectPoolNodeLoads theManagedObjectPoolType.- Specified by:
loadManagedObjectPoolTypein interfaceManagedObjectPoolNode- Parameters:
isLoadingType- Indicates if using to load type.- Returns:
ManagedObjectPoolTypeornullif issue loading with issue reported to theCompilerIssues.
-
sourceManagedObjectPool
public boolean sourceManagedObjectPool(CompileContext compileContext)
Description copied from interface:ManagedObjectPoolNodeSources theManagedObjectPool.- Specified by:
sourceManagedObjectPoolin interfaceManagedObjectPoolNode- Parameters:
compileContext-CompileContext.- Returns:
trueif successfully sourced. Otherwise,falsewith issues reported to theCompilerIssues.
-
buildManagedObjectPool
public void buildManagedObjectPool(ManagedObjectBuilder<?> builder, ManagedObjectType<?> managedObjectType, CompileContext compileContext)
Description copied from interface:ManagedObjectPoolNodeBuildsManagedObjectPoolfor thisManagedObjectPoolNode.- Specified by:
buildManagedObjectPoolin interfaceManagedObjectPoolNode- Parameters:
builder-ManagedObjectBuilder.managedObjectType-ManagedObjectTypeof theManagedObjectSourcebeing pooled.compileContext-CompileContext.
-
linkPoolNode
public boolean linkPoolNode(LinkPoolNode node)
Description copied from interface:LinkPoolNodeLinks the inputLinkPoolNodeto thisLinkPoolNode.- Specified by:
linkPoolNodein interfaceLinkPoolNode- Parameters:
node-LinkPoolNodeto link to thisLinkPoolNode.- Returns:
trueif linked.
-
getLinkedPoolNode
public LinkPoolNode getLinkedPoolNode()
Description copied from interface:LinkPoolNodeObtains theLinkPoolNodelinked to thisLinkPoolNode.- Specified by:
getLinkedPoolNodein interfaceLinkPoolNode- Returns:
LinkPoolNodelinked to thisLinkPoolNode.
-
-