Class ManagedFunctionLoaderImpl
- java.lang.Object
-
- net.officefloor.compile.impl.managedfunction.ManagedFunctionLoaderImpl
-
- All Implemented Interfaces:
ManagedFunctionLoader
,IssueTarget
public class ManagedFunctionLoaderImpl extends java.lang.Object implements ManagedFunctionLoader, IssueTarget
ManagedFunctionLoader
implementation.- Author:
- Daniel Sagenschneider
-
-
Constructor Summary
Constructors Constructor Description ManagedFunctionLoaderImpl(Node node, OfficeNode officeNode, NodeContext nodeContext, boolean isLoadingType)
Initiate for building.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addIssue(java.lang.String issueDescription)
Adds the issue.void
addIssue(java.lang.String issueDescription, java.lang.Throwable cause)
Adds the issue.<S extends ManagedFunctionSource>
FunctionNamespaceTypeloadManagedFunctionType(java.lang.Class<S> managedFunctionSourceClass, PropertyList propertyList)
Loads and returns theFunctionNamespaceType
from theManagedFunctionSource
class.FunctionNamespaceType
loadManagedFunctionType(ManagedFunctionSource managedFunctionSource, PropertyList propertyList)
Loads and returns theFunctionNamespaceType
from theManagedFunctionSource
class.<S extends ManagedFunctionSource>
PropertyListloadSpecification(java.lang.Class<S> managedFunctionSourceClass)
Loads and returns thePropertyList
from theManagedFunctionSourceSpecification
for theManagedFunctionSource
.PropertyList
loadSpecification(ManagedFunctionSource managedFunctionSource)
Loads and returns thePropertyList
from theManagedFunctionSourceSpecification
for theManagedFunctionSource
.
-
-
-
Constructor Detail
-
ManagedFunctionLoaderImpl
public ManagedFunctionLoaderImpl(Node node, OfficeNode officeNode, NodeContext nodeContext, boolean isLoadingType)
Initiate for building.- Parameters:
node
-Node
requiring theManagedFunction
instances.officeNode
-OfficeNode
. May benull
if not loading withinOfficeNode
.nodeContext
-NodeContext
.isLoadingType
- Indicates using to load type.
-
-
Method Detail
-
loadSpecification
public <S extends ManagedFunctionSource> PropertyList loadSpecification(java.lang.Class<S> managedFunctionSourceClass)
Description copied from interface:ManagedFunctionLoader
Loads and returns thePropertyList
from theManagedFunctionSourceSpecification
for theManagedFunctionSource
.- Specified by:
loadSpecification
in interfaceManagedFunctionLoader
- Type Parameters:
S
-ManagedFunctionSource
type.- Parameters:
managedFunctionSourceClass
- Class of theManagedFunctionSource
.- Returns:
PropertyList
of theManagedFunctionSourceProperty
instances of theManagedFunctionSourceSpecification
ornull
if issue, which is reported to theCompilerIssues
.
-
loadSpecification
public PropertyList loadSpecification(ManagedFunctionSource managedFunctionSource)
Description copied from interface:ManagedFunctionLoader
Loads and returns thePropertyList
from theManagedFunctionSourceSpecification
for theManagedFunctionSource
.- Specified by:
loadSpecification
in interfaceManagedFunctionLoader
- Parameters:
managedFunctionSource
-ManagedFunctionSource
instance.- Returns:
PropertyList
of theManagedFunctionSourceProperty
instances of theManagedFunctionSourceSpecification
ornull
if issue, which is reported to theCompilerIssues
.
-
loadManagedFunctionType
public <S extends ManagedFunctionSource> FunctionNamespaceType loadManagedFunctionType(java.lang.Class<S> managedFunctionSourceClass, PropertyList propertyList)
Description copied from interface:ManagedFunctionLoader
Loads and returns theFunctionNamespaceType
from theManagedFunctionSource
class.- Specified by:
loadManagedFunctionType
in interfaceManagedFunctionLoader
- Type Parameters:
S
-ManagedFunctionSource
type.- Parameters:
managedFunctionSourceClass
- Class of theManagedFunctionSource
.propertyList
-PropertyList
containing the properties to source theFunctionNamespaceType
.- Returns:
FunctionNamespaceType
ornull
if issues, which is reported to theCompilerIssues
.
-
loadManagedFunctionType
public FunctionNamespaceType loadManagedFunctionType(ManagedFunctionSource managedFunctionSource, PropertyList propertyList)
Description copied from interface:ManagedFunctionLoader
Loads and returns theFunctionNamespaceType
from theManagedFunctionSource
class.- Specified by:
loadManagedFunctionType
in interfaceManagedFunctionLoader
- Parameters:
managedFunctionSource
-ManagedFunctionSource
instance.propertyList
-PropertyList
containing the properties to source theFunctionNamespaceType
.- Returns:
FunctionNamespaceType
ornull
if issues, which is reported to theCompilerIssues
.
-
addIssue
public void addIssue(java.lang.String issueDescription)
Description copied from interface:IssueTarget
Adds the issue.- Specified by:
addIssue
in interfaceIssueTarget
- Parameters:
issueDescription
- Description of the issue.
-
addIssue
public void addIssue(java.lang.String issueDescription, java.lang.Throwable cause)
Description copied from interface:IssueTarget
Adds the issue.- Specified by:
addIssue
in interfaceIssueTarget
- Parameters:
issueDescription
- Description of the issue.cause
- Cause of the issue.
-
-