Skip to content

workflow / Exports / EdgeUtils

Class: EdgeUtils

Edge utility functions

Table of contents

Constructors

Methods

Constructors

constructor

new EdgeUtils(): EdgeUtils

Returns

EdgeUtils

Methods

generateId

generateId(sourceId, targetId, type): string

Generate edge ID from source and target

Parameters

NameType
sourceIdstring
targetIdstring
typeWorkflowConnectionType

Returns

string

Defined in

interfaces/workflow-edge.ts:116


wouldCreateCycle

wouldCreateCycle(edges, sourceId, targetId): boolean

Check if edge creates a cycle

Parameters

NameType
edgesWorkflowEdge[]
sourceIdstring
targetIdstring

Returns

boolean

Defined in

interfaces/workflow-edge.ts:123

Released under the MIT License.