Class OfficeObjectNodeImpl
- java.lang.Object
-
- net.officefloor.compile.impl.structure.OfficeObjectNodeImpl
-
- All Implemented Interfaces:
LinkObjectNode,Node,OfficeObjectNode,AdministerableManagedObject,DependentManagedObject,GovernerableManagedObject,OfficeDependencyObjectNode,OfficeObject,OfficeFloorDependencyRequireNode
public class OfficeObjectNodeImpl extends java.lang.Object implements OfficeObjectNode
OfficeObjectNodeimplementation.- Author:
- Daniel Sagenschneider
-
-
Field Summary
-
Fields inherited from interface net.officefloor.compile.internal.structure.OfficeObjectNode
TYPE
-
-
Constructor Summary
Constructors Constructor Description OfficeObjectNodeImpl(java.lang.String objectName, OfficeNode office, NodeContext context)Allow adding aOfficeObjectvia theOfficeArchitect.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddAdministrator(AdministrationNode administrator)Adds anAdministrationNodefor thisOfficeManagedObjectType.voidaddGovernance(GovernanceNode governance)voidaddPreLoadAdministration(OfficeAdministration administration)Adds anOfficeAdministrationto be done before attempting load thisManagedObject.java.lang.StringgetAdministerableManagedObjectName()Obtains the name of thisAdministerableManagedObject.Node[]getChildNodes()Obtains the childNodeinstances.java.lang.StringgetDependentManagedObjectName()Obtains the name of thisDependentManagedObject.GovernanceNode[]getGovernances()Obtains theGovernanceNodeinstances to provideGovernanceoverBoundManagedObjectNodelinked to thisOfficeObjectNode.java.lang.StringgetGovernerableManagedObjectName()Obtains the name of thisGovernerableManagedObject.LinkObjectNodegetLinkedObjectNode()Obtains theLinkObjectNodelinked to thisLinkObjectNode.java.lang.StringgetLocation()Obtains the location of theNode.java.lang.StringgetNodeName()Obtains the name of theNode.java.lang.StringgetNodeType()Obtains theNodetype.java.lang.StringgetOfficeObjectName()Obtains the name that theOfficeSourcerefers to thisObject.java.lang.StringgetOfficeObjectType()Obtains the type of theOfficeObject.NodegetParentNode()AdministrationNode[]getPreLoadAdministrations()Obtains theAdministrationNodeinstances to provide pre-loadAdministrationoverBoundManagedObjectNodelinked to thisOfficeObjectNode.java.lang.StringgetTypeQualifier()Obtains the type qualifier for theOfficeObject.voidinitialise(java.lang.String objectType)Initialises thisOfficeManagedObjectType.booleanisInitialised()Indicates if theNodehas been initialised.booleanlinkObjectNode(LinkObjectNode node)Links the inputLinkObjectNodeto thisLinkObjectNode.OfficeManagedObjectTypeloadOfficeManagedObjectType(CompileContext compileContext)Loads theOfficeManagedObjectTypefor thisOfficeObjectNode.voidsetTypeQualifier(java.lang.String qualifier)Specifies the type qualifier.-
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
-
OfficeObjectNodeImpl
public OfficeObjectNodeImpl(java.lang.String objectName, OfficeNode office, NodeContext context)Allow adding aOfficeObjectvia theOfficeArchitect.- Parameters:
objectName- Name of theOfficeObject.office- ParentOfficeNode.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 objectType)
Description copied from interface:OfficeObjectNodeInitialises thisOfficeManagedObjectType.- Specified by:
initialisein interfaceOfficeObjectNode- Parameters:
objectType- Object type.
-
addAdministrator
public void addAdministrator(AdministrationNode administrator)
Description copied from interface:OfficeObjectNodeAdds an
AdministrationNodefor thisOfficeManagedObjectType.This allows the
OfficeManagedObjectTypeto report the extension types required to be supported by theOfficeFloorManagedObjectfor theOfficeObject.- Specified by:
addAdministratorin interfaceOfficeObjectNode- Parameters:
administrator-AdministrationNode.
-
addGovernance
public void addGovernance(GovernanceNode governance)
Description copied from interface:OfficeObjectNodeAdds a
GovernanceNodeprovidingGovernancefor thisOfficeObject.This also allows the
OfficeManagedObjectTypeto report the extension interfaces required to be supported by theOfficeFloorManagedObjectfor theOfficeObject.- Specified by:
addGovernancein interfaceOfficeObjectNode- Parameters:
governance-GovernanceNode.
-
getGovernances
public GovernanceNode[] getGovernances()
Description copied from interface:OfficeObjectNodeObtains theGovernanceNodeinstances to provideGovernanceoverBoundManagedObjectNodelinked to thisOfficeObjectNode.- Specified by:
getGovernancesin interfaceOfficeObjectNode- Returns:
GovernanceNodeinstances.
-
getPreLoadAdministrations
public AdministrationNode[] getPreLoadAdministrations()
Description copied from interface:OfficeObjectNodeObtains theAdministrationNodeinstances to provide pre-loadAdministrationoverBoundManagedObjectNodelinked to thisOfficeObjectNode.- Specified by:
getPreLoadAdministrationsin interfaceOfficeObjectNode- Returns:
AdministrationNodeinstances.
-
getTypeQualifier
public java.lang.String getTypeQualifier()
Description copied from interface:OfficeObjectNodeObtains the type qualifier for theOfficeObject.- Specified by:
getTypeQualifierin interfaceOfficeObjectNode- Returns:
- Type qualifier for the
OfficeObject.
-
getOfficeObjectType
public java.lang.String getOfficeObjectType()
Description copied from interface:OfficeObjectNodeObtains the type of theOfficeObject.- Specified by:
getOfficeObjectTypein interfaceOfficeObjectNode- Returns:
- Type of the
OfficeObject.
-
loadOfficeManagedObjectType
public OfficeManagedObjectType loadOfficeManagedObjectType(CompileContext compileContext)
Description copied from interface:OfficeObjectNodeLoads theOfficeManagedObjectTypefor thisOfficeObjectNode.- Specified by:
loadOfficeManagedObjectTypein interfaceOfficeObjectNode- Parameters:
compileContext-CompileContext.- Returns:
OfficeManagedObjectTypeornullwith issues reported to theCompilerIssues.
-
getOfficeObjectName
public java.lang.String getOfficeObjectName()
Description copied from interface:OfficeObjectObtains the name that theOfficeSourcerefers to thisObject.- Specified by:
getOfficeObjectNamein interfaceOfficeObject- Returns:
- Name that the
OfficeSourcerefers to thisObject.
-
setTypeQualifier
public void setTypeQualifier(java.lang.String qualifier)
Description copied from interface:OfficeObjectSpecifies the type qualifier.- Specified by:
setTypeQualifierin interfaceOfficeObject- Parameters:
qualifier- Type qualifier.
-
addPreLoadAdministration
public void addPreLoadAdministration(OfficeAdministration administration)
Description copied from interface:OfficeObjectAdds an
OfficeAdministrationto be done before attempting load thisManagedObject.The order that the
OfficeAdministrationinstances are added is the order they will be done.- Specified by:
addPreLoadAdministrationin interfaceOfficeObject- Parameters:
administration-OfficeAdministrationto be done before attempting load thisManagedObject.
-
getDependentManagedObjectName
public java.lang.String getDependentManagedObjectName()
Description copied from interface:DependentManagedObjectObtains the name of thisDependentManagedObject.- Specified by:
getDependentManagedObjectNamein interfaceDependentManagedObject- Returns:
- Name of this
DependentManagedObject.
-
getAdministerableManagedObjectName
public java.lang.String getAdministerableManagedObjectName()
Description copied from interface:AdministerableManagedObjectObtains the name of thisAdministerableManagedObject.- Specified by:
getAdministerableManagedObjectNamein interfaceAdministerableManagedObject- Returns:
- Name of this
AdministerableManagedObject.
-
getGovernerableManagedObjectName
public java.lang.String getGovernerableManagedObjectName()
Description copied from interface:GovernerableManagedObjectObtains the name of thisGovernerableManagedObject.- Specified by:
getGovernerableManagedObjectNamein interfaceGovernerableManagedObject- Returns:
- Name of this
GovernerableManagedObject.
-
linkObjectNode
public boolean linkObjectNode(LinkObjectNode node)
Description copied from interface:LinkObjectNodeLinks the inputLinkObjectNodeto thisLinkObjectNode.- Specified by:
linkObjectNodein interfaceLinkObjectNode- Parameters:
node-LinkObjectNodeto link to thisLinkObjectNode.- Returns:
trueif linked.
-
getLinkedObjectNode
public LinkObjectNode getLinkedObjectNode()
Description copied from interface:LinkObjectNodeObtains theLinkObjectNodelinked to thisLinkObjectNode.- Specified by:
getLinkedObjectNodein interfaceLinkObjectNode- Returns:
LinkObjectNodelinked to thisLinkObjectNode.
-
-