Package su.onno.process
Class ProcessGraph<P,S extends Enum<S> & ProcessStepKey>
java.lang.Object
su.onno.process.ProcessGraph<P,S>
Typed business-process route graph.
Application code connects node handles rather than string names. The graph becomes immutable after definition validation.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionautomatic(S step, AutomaticStep<P> action) Add an immediate application-code step with one continuation.<O extends Enum<O>>
DecisionNode<P, S, O> decision(S step, TypedDecision<P, O> decision) Add an immediate, exhaustive typed decision.Immutable, serialization-friendly structural description of this validated graph.Add a terminal node.<O extends Enum<O>>
HumanTaskNode<P, S, O> Add a typed human-task node.Resolve a node by its typed step key.Resolve a node by its stable persisted step key.List<ProcessNode<P, S>> nodes()Declared route nodes in definition order, excluding the synthetic start.<B extends Enum<B>>
ParallelForkNode<P, S, B> Add a typed parallel fork and its paired join.start()stepType()Enum class that owns this graph's typed step keys.<C,CS extends Enum<CS> & ProcessStepKey>
SubprocessNode<P, S, C, CS> subprocess(S step, SubprocessCall<P, C, CS> call) Add a durable typed child-process call.timer(S step, ProcessTimer<P> timer) Add a durable timer wait with one continuation.
-
Constructor Details
-
ProcessGraph
public ProcessGraph()
-
-
Method Details
-
start
-
human
Add a typed human-task node. -
automatic
Add an immediate application-code step with one continuation. -
decision
Add an immediate, exhaustive typed decision. -
timer
Add a durable timer wait with one continuation. -
parallel
public <B extends Enum<B>> ParallelForkNode<P,S, parallelB> (S forkStep, Class<B> branchType, S joinStep) Add a typed parallel fork and its paired join.Declare every branch with
ParallelForkNode.on(Enum)and connect the continuation throughfork.join().to(next). -
subprocess
public <C,CS extends Enum<CS> & ProcessStepKey> SubprocessNode<P,S, subprocessC, CS> (S step, SubprocessCall<P, C, CS> call) Add a durable typed child-process call. -
end
Add a terminal node. A graph may have multiple meaningful endings. -
node
Resolve a node by its typed step key. -
nodeByKey
Resolve a node by its stable persisted step key. -
nodes
Declared route nodes in definition order, excluding the synthetic start. -
stepType
Enum class that owns this graph's typed step keys. -
descriptor
Immutable, serialization-friendly structural description of this validated graph.
-