branch

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 21, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const ErrorCodeCompilerError = "CompilerError"
View Source
const ErrorCodeFailedFetchOutputs = "FailedFetchOutputs"
View Source
const ErrorCodeMalformedBranch = "MalformedBranchUserError"
View Source
const ErrorCodeUserProvidedError = "UserProvidedError"

Variables

This section is empty.

Functions

func DecideBranch

func DecideBranch(ctx context.Context, nl executors.NodeLookup, nodeID v1alpha1.NodeID, node v1alpha1.ExecutableBranchNode, nodeInputs *core.LiteralMap) (*v1alpha1.NodeID, error)

Decides the branch to be taken, returns the nodeId of the selected node or an error The branchNode is marked as success. This is used by downstream node to determine if it can be executed All downstream nodes are marked as skipped

func Evaluate

func Evaluate(lValue *core.Primitive, rValue *core.Primitive, op core.ComparisonExpression_Operator) (bool, error)

func Evaluate1

func Evaluate1(lValue *core.Primitive, rValue *core.Literal, op core.ComparisonExpression_Operator) (bool, error)

func Evaluate2

func Evaluate2(lValue *core.Literal, rValue *core.Primitive, op core.ComparisonExpression_Operator) (bool, error)

func EvaluateBooleanExpression

func EvaluateBooleanExpression(expr *core.BooleanExpression, nodeInputs *core.LiteralMap) (bool, error)

func EvaluateComparison

func EvaluateComparison(expr *core.ComparisonExpression, nodeInputs *core.LiteralMap) (bool, error)

func EvaluateIfBlock

func EvaluateIfBlock(block v1alpha1.ExecutableIfBlock, nodeInputs *core.LiteralMap, skippedNodeIds []*v1alpha1.NodeID) (*v1alpha1.NodeID, []*v1alpha1.NodeID, error)

func EvaluateLiterals

func EvaluateLiterals(lValue *core.Literal, rValue *core.Literal, op core.ComparisonExpression_Operator) (bool, error)

func New

func New(executor interfaces.Node, eventConfig *config.EventConfig, scope promutils.Scope) interfaces.NodeHandler

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL