Class FunctionNamespaceNodeImpl
- java.lang.Object
-
- net.officefloor.compile.impl.structure.FunctionNamespaceNodeImpl
-
- All Implemented Interfaces:
FunctionNamespaceNode
,Node
,PropertyConfigurable
,SectionFunctionNamespace
public class FunctionNamespaceNodeImpl extends java.lang.Object implements FunctionNamespaceNode
FunctionNamespaceNode
implementation.- Author:
- Daniel Sagenschneider
-
-
Field Summary
-
Fields inherited from interface net.officefloor.compile.internal.structure.FunctionNamespaceNode
TYPE
-
-
Constructor Summary
Constructors Constructor Description FunctionNamespaceNodeImpl(java.lang.String namespaceName, SectionNode section, NodeContext context)
Instantiate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addProperty(java.lang.String name, java.lang.String value)
Adds aProperty
to configure the item.SectionFunction
addSectionFunction(java.lang.String functionName, java.lang.String functionTypeName)
Adds aSectionFunction
.Node[]
getChildNodes()
Obtains the childNode
instances.java.lang.String
getLocation()
Obtains the location of theNode
.java.lang.String
getNodeName()
Obtains the name of theNode
.java.lang.String
getNodeType()
Obtains theNode
type.Node
getParentNode()
java.lang.String
getSectionFunctionNamespaceName()
Obtains the name of thisSectionFunctionNamespace
.SectionNode
getSectionNode()
Obtains theSectionNode
containing thisFunctionNamespaceNode
.void
initialise(java.lang.String managedFunctionSourceClassName, ManagedFunctionSource managedFunctionSource)
Initialises theFunctionNamespaceNode
.boolean
isInitialised()
Indicates if theNode
has been initialised.FunctionNamespaceType
loadFunctionNamespaceType(boolean isLoadingType)
Obtains theFunctionNamespaceType
for thisFunctionNamespaceNode
.void
registerAsPossibleMbean(CompileContext compileContext)
Registers theManagedFunctionSource
as a possible MBean.-
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
-
FunctionNamespaceNodeImpl
public FunctionNamespaceNodeImpl(java.lang.String namespaceName, SectionNode section, NodeContext context)
Instantiate.- Parameters:
namespaceName
- Name of thisSectionFunctionNamespace
.section
-OfficeSection
containing thisFunctionNamespaceNode
.context
-NodeContext
.
-
-
Method Detail
-
getNodeName
public java.lang.String getNodeName()
Description copied from interface:Node
Obtains the name of theNode
.- Specified by:
getNodeName
in interfaceNode
- Returns:
- Name of the
Node
.
-
getNodeType
public java.lang.String getNodeType()
Description copied from interface:Node
Obtains theNode
type.- Specified by:
getNodeType
in interfaceNode
- Returns:
Node
type.
-
getLocation
public java.lang.String getLocation()
Description copied from interface:Node
Obtains the location of theNode
.- Specified by:
getLocation
in interfaceNode
- Returns:
- Location of the
Node
. May benull
ifNode
does not support a location.
-
getParentNode
public Node getParentNode()
Description copied from interface:Node
- Specified by:
getParentNode
in interfaceNode
- Returns:
Node
containing thisNode
.
-
getChildNodes
public Node[] getChildNodes()
Description copied from interface:Node
Obtains the childNode
instances.- Specified by:
getChildNodes
in interfaceNode
- Returns:
- Child
Node
instances.
-
isInitialised
public boolean isInitialised()
Description copied from interface:Node
Indicates if theNode
has been initialised.Node
instances should only be initialised once. Initialising theNode
twice is an issue.- Specified by:
isInitialised
in interfaceNode
- Returns:
true
if initialised.
-
initialise
public void initialise(java.lang.String managedFunctionSourceClassName, ManagedFunctionSource managedFunctionSource)
Description copied from interface:FunctionNamespaceNode
Initialises theFunctionNamespaceNode
.- Specified by:
initialise
in interfaceFunctionNamespaceNode
- Parameters:
managedFunctionSourceClassName
-Class
name of theManagedFunctionSource
.managedFunctionSource
- Optional instantiatedManagedFunctionSource
. May benull
.
-
getSectionFunctionNamespaceName
public java.lang.String getSectionFunctionNamespaceName()
Description copied from interface:SectionFunctionNamespace
Obtains the name of thisSectionFunctionNamespace
.- Specified by:
getSectionFunctionNamespaceName
in interfaceSectionFunctionNamespace
- Returns:
- Name of this
SectionFunctionNamespace
.
-
addProperty
public void addProperty(java.lang.String name, java.lang.String value)
Description copied from interface:PropertyConfigurable
Adds aProperty
to configure the item.- Specified by:
addProperty
in interfacePropertyConfigurable
- Parameters:
name
- Name ofProperty
.value
- Value ofProperty
.
-
addSectionFunction
public SectionFunction addSectionFunction(java.lang.String functionName, java.lang.String functionTypeName)
Description copied from interface:SectionFunctionNamespace
Adds aSectionFunction
.- Specified by:
addSectionFunction
in interfaceSectionFunctionNamespace
- Parameters:
functionName
- Name of theSectionFunction
.functionTypeName
- Name of theManagedFunctionType
on theFunctionNamespaceType
.- Returns:
SectionFunction
.
-
getSectionNode
public SectionNode getSectionNode()
Description copied from interface:FunctionNamespaceNode
Obtains theSectionNode
containing thisFunctionNamespaceNode
.- Specified by:
getSectionNode
in interfaceFunctionNamespaceNode
- Returns:
SectionNode
containing thisFunctionNamespaceNode
.
-
loadFunctionNamespaceType
public FunctionNamespaceType loadFunctionNamespaceType(boolean isLoadingType)
Description copied from interface:FunctionNamespaceNode
Obtains theFunctionNamespaceType
for thisFunctionNamespaceNode
.- Specified by:
loadFunctionNamespaceType
in interfaceFunctionNamespaceNode
- Parameters:
isLoadingType
- Indicates using to load type.- Returns:
FunctionNamespaceType
for thisFunctionNamespaceNode
. May benull
if can not load theFunctionNamespaceType
.
-
registerAsPossibleMbean
public void registerAsPossibleMbean(CompileContext compileContext)
Description copied from interface:FunctionNamespaceNode
Registers theManagedFunctionSource
as a possible MBean.- Specified by:
registerAsPossibleMbean
in interfaceFunctionNamespaceNode
- Parameters:
compileContext
-CompileContext
.
-
-