Module: patch

patch.js The patch library describes how to add a patch connection between any 2 nodes by dragging from source node to destination and defines the patch manipulation.

Source:

Methods

(inner) addPatchComponent(cmode, cfrom, cto, clabel, ctext, isImport)

Patch creation. Patch style and configuration data loaded from configurationdata, styledata json.

Parameters:
Name Type Description
cmode number

Service mode 1 for add.

cfrom string

Source node ID.

cto string

Destination node ID.

clabel string

The Label of the service.

ctext string

The Text of the service.

isImport boolean

false -> manual add, true -> automattically added while import json.

Source:

(inner) clearSinglePatch()

Clear input/teporary data and other settings.

Source:

(inner) deletePatch(patchID)

Remove patch by patch ID.

Parameters:
Name Type Description
patchID string

patch ID.

Source:

(inner) singlePatchEdit(patchID, callback)

Populate patch details by patch ID.

Parameters:
Name Type Description
patchID string

Patch ID.

callback

The callback that handles the response.

Source:

(inner) singlePatchMode()

Enable settings for patch and reset other settings. Set patch 1 = enable, 0 = disable.

Source:

(inner) updateSinglePatch(patchID)

Update patch. Update patch label, text by patch ID.

Parameters:
Name Type Description
patchID string

patch ID.

Source: