Class ClassFlowBuilder<A extends Annotation>
java.lang.Object
net.officefloor.plugin.clazz.flow.ClassFlowBuilder<A>
Factory to create the
Flow instances.- Author:
- Daniel Sagenschneider
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ClassFlowMethodMetaDatabuildFlow(String flowName, Class<?> flowInterfaceType, Method flowMethod, ClassFlowRegistry flowRegistry, String errorSuffix) Builds theClassFlowMethodMetaData.buildFlowFactory(String flowName, Class<?> flowInterfaceType, ClassFlowRegistry flowRegistry, SourceContext sourceContext) Builds theClassFlowInterfaceFactoryfor theFlowinjected interface.buildFlowInterfaceFactory(Class<?> flowInterfaceType, ClassFlowRegistry flowRegistry, SourceContext sourceContext) Builds theClassFlowInterfaceFactoryfor theFlowInterface.
-
Constructor Details
-
ClassFlowBuilder
Instantiate.- Parameters:
annotationClass-Classof theAnnotation.
-
-
Method Details
-
buildFlowFactory
public ClassFlowInterfaceFactory buildFlowFactory(String flowName, Class<?> flowInterfaceType, ClassFlowRegistry flowRegistry, SourceContext sourceContext) throws Exception Builds theClassFlowInterfaceFactoryfor theFlowinjected interface.- Parameters:
flowName- Name of theFlow.flowInterfaceType- Type of interface. Should only have a singleMethod.flowRegistry-ClassFlowRegistry.sourceContext-SourceContext.- Returns:
ClassFlowInterfaceFactory.- Throws:
Exception- If fails to build theClassFlowInterfaceFactory.
-
buildFlowInterfaceFactory
public ClassFlowInterfaceFactory buildFlowInterfaceFactory(Class<?> flowInterfaceType, ClassFlowRegistry flowRegistry, SourceContext sourceContext) throws Exception Builds theClassFlowInterfaceFactoryfor theFlowInterface.- Parameters:
flowInterfaceType- InterfaceClassfor theFlowInterface.flowRegistry-ClassFlowRegistry.sourceContext-SourceContext.- Returns:
ClassFlowInterfaceFactoryornullif parameter is not aFlowInterface.- Throws:
Exception- If fails to build theClassFlowInterfaceFactory.
-
buildFlow
protected ClassFlowMethodMetaData buildFlow(String flowName, Class<?> flowInterfaceType, Method flowMethod, ClassFlowRegistry flowRegistry, String errorSuffix) throws Exception Builds theClassFlowMethodMetaData.- Parameters:
flowName- Name of theFlow.flowInterfaceType- Interface type of dependency to invoke for theFlow.flowMethod-Methodto invoke for theFlow.flowRegistry-ClassFlowRegistry.errorSuffix- Error suffix.- Returns:
ClassFlowMethodMetaData.- Throws:
Exception- If fails to build theClassFlowMethodMetaData.
-