Class Promise
- java.lang.Object
-
- net.officefloor.frame.impl.execute.function.Promise
-
public class Promise extends java.lang.ObjectProvides promise like functionality forFunctionStateinstances.- Author:
- Daniel Sagenschneider
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static FunctionStatethen(FunctionState function, FunctionState thenFunction)Execute theFunctionStatethen theFunctionState.
-
-
-
Method Detail
-
then
public static FunctionState then(FunctionState function, FunctionState thenFunction)
Execute the
FunctionStatethen theFunctionState.State is passed between
FunctionStateinstances viaManagedObjectinstances, so no parameter is provided.- Parameters:
function-FunctionStateto execute it and its sequence ofFunctionStateinstances. May benull.thenFunction-FunctionStateto then continue after the first inputFunctionStatesequence completes. May benull.- Returns:
- Next
FunctionStateto undertake theFunctionStatesequence and then continueFunctionStatesequence. Will returnnullif both inputs arenull.
-
-