Class Placeholder<L>

Source
Expand description

This "node" will be replaced by the actual node when the workflow is built.

You can't call next() on it.

id can be the label or the id of the node.

Example:

definition: [
Chain.start(new NoOp("A")).next(new Placeholder("C")),
Chain.start(new NoOp("B")).next(new NoOp("C")),
]

This will result in:

 A -> C
B -> C

Constructors§

Source§

new Placeholder<L extends string>(id: L): Placeholder<L>

Properties§

Source§

public readonly id: L

Unique identifier for this state

Methods§

Source§

canTakeInput(
    _fromState: IChainable,
    _withConnectionOptions?: ConnectionOptions,
): boolean

Determines if this state can accept input from another state

Source§

listOutgoing(): IChainable<string, any>[]

Returns all states that are connected as next states from this state