Global

Members

activeTab

The currently open tab in the sidebar

Source:

(constant) addResourcePermission

adds a new permission depending on role permissions for a newly created resource

Source:

(constant) buildPermissions

builds permission for user that wants to authenticate

Source:

(constant) CONFIG_PROPERTIES

The property names of the machine values that are set/appended by the config.

Source:

(constant) createAdminUser

initially migrates data to iam related stores and creates admin user if not exists

Source:

(constant) defineRules

translates userinfo permissions object into casl rules

Source:

detectedCapabilities

A list of capabilities detected in the code

Source:

elementFilter

Model for the filter field.

Source:

(constant) ensureCleanRoleMappings

cleans up role mappings and roles members when a user is deleted

Source:

(constant) getUserinfo

fetches userinfo from idp /userinfo endpoint

Source:

(constant) handleOauthCallback

handles oauth callback, exchanges authorization code for tokens and caches tokens

Source:

(constant) initOpaCache

migrates data on server start to the opa cache for policy decision making

Source:

(constant) initResourcePermissions

initializes permissions for each individual resource that is loaded in stores on initial page load

Source:

(constant) isAllowed

can be used as express middleware in app.use(...) or directly in route e.g. app.get(path, isAllowed(...), ...)

Source:
Example
// checks if user has 16 = manage permissions for resource Role
isAllowed(16, 'Role')
// checks if user has 8 = delete OR 16 = manage permissions for resource Group
isAllowed([8, 16], 'Group')
// checks if user has 8 = delete AND 16 = manage permissions for resource Group (default decisionStrategy = "affirmative")
isAllowed([8, 16], 'Group', { decisionStrategy: "unanimous" })
// tells OPA to filter resources, which are only available for current authenticated user if user has sufficient permissions
isAllowed(1, 'Process', { filter: true })
// if resource is set to undefined, context MUST be set to true and req.context has to be set in a middleware, to provide resourceType and resourceId to OPA via context (useful for routes that can handle multiple types of resources)
isAllowed(16, undefined, { context: true })
// get error messages from OPA
isAllowed(1, 'Process', { explain: true })
// pass http body from request to OPA
isAllowed(1, 'Process', { includeBody: true })

(constant) isAuthenticated

check if user is authenticated

Source:

(constant) login

builds authorization url for authorization code flow with pkce

Source:

(constant) logout

builds logout url

Source:

machines

The local cache of the machine list available in the network.

Source:

messages

Storing messages to be displayed about the current code.

Source:

(constant) processSockets

Contains process specific connections

Source:

(constant) PROPERTIES

Property names and corresponding cache timeouts in s.

Source:

(constant) refreshUserToken

refreshes the user's access token

Source:

(constant) revokeUserToken

revokes the user's access token at the idp

Source:

(constant) runClientCredentialsFlow

runs client credentials flow to re-authenticate service account

Source:

suggestions

Storing available autocomplete suggestions for the code.

Source:

(constant) translateListToPermission

translates a permission list into a permissions number

Source:

(constant) translatePermissionToList

translates a permissions number into a list of permissions

Source:

(constant) verifyIdToken

verifies signature of id token and validates algorithm, audience, issuer and nonce

Source:

Methods

(async) abortInstanceOnNetwork(definitionId, instanceId)

Sends request to abort process instance to all machines in the local network

Parameters:
Name Type Description
definitionId string

name of the file the process is stored in

instanceId string

the id of the instance to abort

Source:

activateDistribution()

Sets up callbacks that trigger distribution when certain events are encountered in the registered modeler

Source:

(async) activateInspectionOrder(engine, userTask, _5iInformation)

Will signal to the 5thIndustry Application that the task linked to an inspection order has become active

Parameters:
Name Type Description
engine Object

the engine of the process the user task occured in

userTask Object

the user task that has become active

_5iInformation Object

5thIndustry data needed to match the user task to a specific inspection order in 5thIndustry App

Properties
Name Type Description
apiAddress String

the url of the 5thIndustry API that needs to be used when activating the inspection order

applicationAddress String

the url of the 5thIndustry APP that is used to link to the App from the ui of the engine

inspectionPlanId String

the inspection plan the inspection order is in (the plan that is linked to the process)

assemblyGroupId String

the assembly group the inspection order is in (an assembly group bundles multiple manufacturing steps)

manufacturingStepId String

the manufacturing step the inspection order is in (a manufacturing step contains multiple inspection orders)

inspectionOrderId String

id of the specific inspection order we want to target

Source:

add(storeName, newElement) → {Boolean}

Function to add an element to the stores which store elements with ids (machines, processes, etc.) (NOT! config)

Does check if element with the same id is already in store

Parameters:
Name Type Description
storeName String

the name of the store we want to add to

newElement Object

the object we want to add

Source:
Returns:
  • if adding was possible (don't add if element with same id exists)
Type
Boolean

(async) addAdditionalContent(container, process, viewer, options)

Adds optional content to the pdf/directory (e.g. User Tasks for bpmn export or called processes for image exports)

Parameters:
Name Type Description
container Object

a pdf or zip directory

process *
viewer *
options *
Source:

addCallActivityReference(callActivityId, calledBpmn, calledProcessLocation)

Add meta information of the called bpmn process to the modeler bpmn where it's getting called from. This includes a custom namespace in the definitions part, an import element as first child of definitions and the calledElement attribute of the call activity bpmn element

Parameters:
Name Type Description
callActivityId String

The ID of the call activity bpmn element inside the rootBpmn

calledBpmn String

The bpmn file of the called process

calledProcessLocation String

The definitionId of the calledBpmn.

Source:

addConstraints(processConstraints, taskConstraintMapping)

Adds process and task constraints as extension elements to the process after checking for inconsistencies

Parameters:
Name Type Description
processConstraints
taskConstraintMapping
Source:

addConstraintsToElement(element, cons)

Adds the given constraints to the extensionElements of the given modeler element

Parameters:
Name Type Description
element Object

the modeler element we want to add the constraints to

cons Object

the constraints we want to add

Source:

(async) addFile(container, process, viewer, options)

Adds a file to the given pdf/zip directory

Parameters:
Name Type Description
container Object

either a pdf file or a zip directory

process Object

the process we want to create a file of

viewer Object

the viewer to get image data from

options Object

the selected export options

Source:

addLocationsToElement(element, locations)

Adds the given locations to the extensionElements of the given modeler element

Parameters:
Name Type Description
element Object

the modeler element we want to add the locations to

locations Object

the locations we want to add

Source:

(async) addMachine(service)

Requests information for given service and adds the publishing machine to the list of known machines

Parameters:
Name Type Description
service Object
Source:

addMachine(machine)

Handles machines that are added by the user

Parameters:
Name Type Description
machine Object

contains user defined information about the machine to add

Source:

addMachineLogsSubscription(machineId)

Set flag that logs for a machine are requested

Parameters:
Name Type Description
machineId String

the machine for which logs are requested

Source:

addMachineSubscription(machineId)

Set flag that we want extended information for a specific machine

Parameters:
Name Type Description
machineId String

machine that more information is requested for

Source:

addMilestonesToElement(element, milestones)

Adds the given milestones to the extensionElements of the given modeler element

Parameters:
Name Type Description
element Object

the modeler element we want to add the milestones to

milestones Object

the milestones we want to add

Source:

addProcess(bpmn) → {Object}

Handles adding a process, makes sure all necessary information gets parsed from bpmn

Parameters:
Name Type Description
bpmn String

the xml description of the process to create

Source:
Returns:
  • returns an object containing the intitial process information
Type
Object

addProcess(processData)

Adds a new process to the browsers localStorage

Parameters:
Name Type Description
processData String

the process definition and additional process info

Source:

(async) addProcess(processData)

Will send the process to the backend for authenticated users and shared processes or store it in the browser-storage for unauthenticated users

Parameters:
Name Type Description
processData Object
Source:

addResourcesToElement(element, resources)

Adds the given resources to the extensionElements of the given modeler element

Parameters:
Name Type Description
element Object

the modeler element we want to add the resources to

resources Object

the resources we want to add

Source:

addRole(roleRepresentation) → {Object}

Adds a new role for the PROCEED MS

Parameters:
Name Type Description
roleRepresentation Object

role representation

Source:
Returns:
  • newly created role
Type
Object

addRoleMapping(roleMapping) → {Object}

Adds a user role mapping

Parameters:
Name Type Description
roleMapping Object

role mapping object containing userId & roleId

Source:
Returns:
  • new user role mapping
Type
Object

addShare(share) → {Object}

Creates a new share

Parameters:
Name Type Description
share Object

the new share object

Properties
Name Type Description
permissions Number

allowed permissions (mandatory)

resourceType String

type of resource (mandatory)

resourceId String

id of resource (mandatory)

type 0 | 1 | 2

type of sharing (mandatory) - 0 = sharing from user to user, 1 = sharing from user to group, 2 = link sharing

sharedWith String

id of a user (mandatory if not link sharing)

password String

password for a link sharing (only for type link, optional)

expiredAt Date

date when a sharing should expire (optional)

note String

a note for users that receive the sharing (optional)

Source:
Returns:
  • new share object
Type
Object

addToPDF(pdf, viewer, process, options) → {Promise.<Object>}

Adds an image of a (sub)process to the given pdf

Parameters:
Name Type Description
pdf Object

the pdf file to write to

viewer Object

the bpmn-js viewer to get the image data from

process Object

the (sub)process we want to create the pdf data from

options Object

the selected export options

Source:
Returns:

the updated pdf file

Type
Promise.<Object>

addZipFile(processFolder, fileName, file, options)

Adds a file to the given directory inside the zip

Parameters:
Name Type Description
processFolder Object

the directory the file will be added to

fileName Object

the name to be used for the zip file

file Object

the content of the new zip file

options Object

the selected export options

Source:

applyExternalEvent(command, context)

Use some modules from the modeler to trigger similar events to the ones coming from other machines inside the local modeler

Parameters:
Name Type Description
command String

the event that is supposed to be applied

context Object

information about the current state and the expected changes

Source:

(async) applyModelingEvent(processDefinitionsId, type, context)

Queues up events to be applied and applies them in sequence if no other instance of the function is already running

Parameters:
Name Type Description
processDefinitionsId String
type String

the type of event to be applied

context Object

information of the current state and the expected result of the event

Source:

(async) asyncForEach(array, cb)

Executes an async callback for every entry in an array and will resolve when all callbacks resolved

Parameters:
Name Type Description
array Array

the array for which the async forEach is supposed to be executed

cb asyncArrayCallback

the function to execute for every entry

Source:

(async) asyncMap(array, cb)

Executes an async callback to map every entry in an array and will resolve with the results when all callbacks resolved

Parameters:
Name Type Description
array Array

the entries which are supposed to be mapped

cb asyncArrayCallback

the async mapping function

Source:

authRouter() → {Express.Router}

creates authentication related routes for express application

Source:
Returns:
  • Express router
Type
Express.Router

blockProcess(socketId, processDefinitionsId)

Stores the id of the socket wanting to block the process from being deleted inside the process object

Parameters:
Name Type Description
socketId String
processDefinitionsId String
Source:

changeBackendConfig(newValues)

Merges proposed config changes into the backend config object, updates the store and emits an event if at least one entry was changed

Parameters:
Name Type Description
newValues Object

key value pairs of proposed config changes

Source:

checkAvailability(machine) → {Promise.<boolean>}

Sends request checking if there is an engine running on the given machine

Parameters:
Name Type Description
machine object
Properties
Name Type Description
ip string

the ip of the given machine

port number

the port the engine is accessible through

Source:
Returns:

indicates if the machine is available or not

Type
Promise.<boolean>

checkForUncoveredDomains(domains, coveredDomains) → {Boolean}

Checks if a list of domains contains at least one that is not in a list of covered domains

Parameters:
Name Type Description
domains Array.<String>

the domain list to check

coveredDomains Array.<String>

the list of covered domains

Source:
Returns:

if there are uncovered domains

Type
Boolean

(async) checkIfAvailable(machine)

Sends request to see if a machine is reachable and running an engine

Parameters:
Name Type Description
machine Object
Source:

checkIfProcessExists(processDefinitionsId)

Throws if process with given id doesn't exist

Parameters:
Name Type Description
processDefinitionsId String
Source:

completeUserTask(machine, instanceId, userTaskId, processChain, callChain)

Complete userTask on machine

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
host string

the ip address of the machine

port number

the port of the machine

instanceId string

id of the instance the userTask is running in

userTaskId string

id of the active userTask

processChain string
callChain string
Source:

convertSemanticDescription(the)

Parameters:
Name Type Description
the object

capability description gotten from an engine in form of an object

Source:
Returns:
  • the capability information as needed by the ms

(async) createConfig() → {Object}

creates iam configuration based on parameters and schema

Parameters:
Type Description
Object

iam configuration object

Source:
Returns:
  • validated iam configuration object
Type
Object

(async) createProcessContainer(process, viewer, options, zipopt) → {Promise.<Object>}

Creates a pdf in case of pdf export or a zip directory in case we export multiple non pdf files

will add the pdf to the given optionally given zip

Parameters:
Name Type Attributes Description
process Object

the process to export

viewer Object

the bpmn-js process viewer

options Object

the selected export options

zip Object <optional>

the zip we want to create the container in in case of multi process export

Source:
Returns:

either a zip directory or a pdf file

Type
Promise.<Object>

createUserTasks(processFolder)

Creates user task directory and files in zip

Parameters:
Name Type Description
processFolder Object

the directory in the zip to write to

Source:

deepEquals(a, b) → {Boolean}

Compares two values

normal comparison for fundamental data types (number, string etc) element wise comparison for objects and arrays recursive handling for nested objects and arrays

Parameters:
Name Type Description
a Any

some value

b Any

some value

Source:
Returns:
  • if the two values are equal
Type
Boolean

deleteEnvProfile(id, type)

Removes the json file of the environment profile with the given id

Parameters:
Name Type Description
id String

the id of the environment profile

type String

the type of the environment profile

Source:

deleteProcess(id)

Deletes the directory for the process we want to remove

Parameters:
Name Type Description
id String
Source:

deleteProcessUserTask(processDefinitionsId, userTaskFileName)

Removes a stored user task from disk

Parameters:
Name Type Description
processDefinitionsId String
userTaskFileName String
Source:

deleteRole(roleId)

Deletes a role from the PROCEED MS

Parameters:
Name Type Description
roleId String

the id of a role

Source:

deleteRoleMapping(userId, roleId) → {Object}

Removes a role mapping from a user

Parameters:
Name Type Description
userId String

id of user

roleId String

role mapping that has to be removed based on roleId

Source:
Returns:
  • new mapping object without removed element
Type
Object

deleteShare(shareId) → {String}

Deletes a share based on share id

Parameters:
Name Type Description
shareId Object

id share object

Source:
Returns:
  • id share object
Type
String

deleteUserTaskHTML(processDefinitionsId, taskFileName)

Removes data for a specific user task

Parameters:
Name Type Description
processDefinitionsId String
taskFileName String
Source:

deployProcess(machine, definitionId, bpmn)

Sends process definitionid and process bpmn to deploy process on engine

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

bpmn string

the description of the process in xml

Source:

dontGetDeployments()

Deactivate request for deployment information in request loop

Source:

(async) dynamicDeployment(process, bpmn)

Tries to find an optimal machine to deploy process to and sends all necessary process information on success

Parameters:
Name Type Description
process Object

an object containing inforamtion about the process to deploy

bpmn String

the process description in xml

Source:

emit(event, data)

Function to emit one event to the server without response alignment (ids).

Parameters:
Name Type Description
event string

The name of the event

data any

The (raw) data to send

Source:

(async) evaluateDynamicDeployment(engine, processInstanceId, processInfo, tokenId, from, to) → {dynamicDeploymentResult}

Uses the decider module to find the optimal next machine to continue execution of the current token

Parameters:
Name Type Description
engine object

instance of the engine class containing all information about the current process and its instances

processInstanceId string

id of the specific instance the token is running in

processInfo object

information about the running process

tokenId string

the id of the token for which we have to decide where to execute it next

from string

the previous executed element

to string

the next element to be executed

Source:
Returns:

holding information about continuation of execution

Type
dynamicDeploymentResult

(async) evaluateStaticDeployment(engine, nextActivity) → {staticDeploymentResult}

Evaluates if the next acitvity is supposed be executed on the current engine for static deployment

Parameters:
Name Type Description
engine object

instance of the engine class containing all information about the current process and its instances

nextActivity object

information object about the activity that the token is supposed to be moved to

Source:
Returns:

Result object that contains information about execution of next element

Type
staticDeploymentResult

exportSelectedProcesses(allProcesses, selectedProcesses, selectedOption)

Export selected processes to the selected format or a zip if we export multiple files.

Parameters:
Name Type Description
allProcesses Array.<Object>

all known processes to search for referenced call activities

selectedProcesses Array.<Object>

all processes that were selected for export

selectedOption Object

selected export options

Source:

filterHTML(processInfo, imported) → {Array}

Function that filters the User Tasks HTML fileNames from the general process information object

Parameters:
Name Type Description
processInfo Object

contains all known information for a process

imported Boolean

indicates if we want the HTML for the process or for the processes imported by the process

Source:
Returns:
  • array containing the fileNames for all User-Task data we have
Type
Array

filterImportedProcesses(processInfo) → {Object}

Function that filters the imported process descripions from the general process information object

Parameters:
Name Type Description
processInfo Object

contains all known information for a process

Source:
Returns:
  • mapping from definitionId of imported process definition to actual definition
Type
Object

findMatchingMachineId(machine) → {String|undefined}

Goes through the known machines searching for a machine that matches the given machine in some way

Parameters:
Name Type Description
machine Object

the machine we want to find a matching machine for

Source:
Returns:

the id of the matching machine in known (or undefined for no matching)

Type
String | undefined

(async) forwardDynamicInstance(engine, processInstanceId, tokenId, from, to, machine) → {boolean}

Parameters:
Name Type Description
engine object

instance of the engine class containing all information about the current process and its instances

processInstanceId string

id of the specific instance the token is running in

tokenId string

the id of the token for which we have to decide where to execute it next

from string

the previous executed element

to string

the next element to be executed

machine object

machine to forward the instance to

Source:
Returns:
  • true if instance was successully forwarded, false if not
Type
boolean

(async) forwardHTML(ip, port, definitionId, imported)

Sends the html information for all user tasks to the next machine

Parameters:
Name Type Description
ip String

the ip of the next machine

port Number

the port the engine is published on on the next machine

definitionId String

the name of the file the process information is supposed to be stored under on the next machine

imported Boolean

indicates if we want to send the HTML information for imported processes or just the ones for the main process

Source:

(async) forwardImports(ip, port, definitionId)

Sends the process descriptions and user task data for all imported processes to the next machine

Parameters:
Name Type Description
ip String

the ip of the next machine

port Number

the port the engine is published on on the next machine

definitionId String

the name of the file the process information is supposed to be stored under on the next machine

Source:

(async) forwardInstance(ip, port, definitionId, instanceId, instanceInfo)

Sends the necessary instance information and the signal to continue the process on the next machine

Parameters:
Name Type Description
ip String

the ip of the next machine

port Number

the port the engine is published on on the next machine

definitionId String

the name of the file the process information is supposed to be stored under on the next machine

instanceId String

id of the instance we want to continue

instanceInfo Object

the complete instance information that exists at this point

Source:

(async) forwardProcess(ip, port, definitionId, bpmn)

Sends the process definition to the next machine

Parameters:
Name Type Description
ip String

the ip of the other machine

port Number

the port the engine is published on on the other machine

definitionId String

the name of the file the process is supposed to be stored under

bpmn String

the process definition

Source:

get(store)

Gets the value of the store with the given name

Parameters:
Name Type Description
store String

the name of the store we want to get

Source:

getActiveUserTaskHTML(machine, instanceId, userTaskId, processChain, callChain) → {string}

Requests HTML from active userTask on machine

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
host string

the ip address of the machine

port number

the port of the machine

instanceId string

id of the instance the userTask is running in

userTaskId string

id of the active userTask

processChain string
callChain string
Source:
Returns:

HTML of the userTask

Type
string

getActiveUserTasks(machine) → {array}

Requests active userTasks on machine

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
host string

the ip address of the machine

port number

the port of the machine

Source:
Returns:

array with information-objects for every active usertask

Type
array

getAllCollapsedSubprocesses(process)

Returns content of all collapsed subprocesses for given process

Parameters:
Name Type Description
process Object

current selected process of the hierarchy

Source:

getAllSubprocesses(allProcesses, currentProcess, includedProcesses, addUserTasksopt, includeCollapsed)

Creates a set of all called processes inside a process and their called processeses recursively

additionally adds the collapsed subprocesses of a process as an attribute to the respective process

Parameters:
Name Type Attributes Description
allProcesses Array.<Object>

all known processes to search for referenced call activities

currentProcess Object

current selected process of the hierarchy

includedProcesses Array.<Object>

container containing all (nested) call activities

addUserTasks Boolean <optional>

if we want to get the user tasks of the called processes

includeCollapsed Boolean

signal if also collapsed subprocesses should be retrieved

Source:

getAppDataPath() → {String}

Returns the path where all the data for the MS is stored

should be:

Server: Production: same directory as server files Development: /path/to/appdata-directory/proceed-management-system-development Electron: Production: /path/to/appdata-directory/proceed-management-system Development: /path/to/appdata-directory/proceed-management-system-development

Source:
Returns:
Type
String

getBackendConfig() → {Object}

Returns the current config values

Source:
Returns:

the current config values

Type
Object

(async) getBPMN(processDefinitionsId)

Requests the bpmn xml for a specific process

Parameters:
Name Type Description
processDefinitionsId String
Source:

getBPMN(processDefinitionsId) → {String}

Get the bpmn of a specific process as a string

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:

the process description

Type
String

getCertificate(letsencryptPath) → {Object}

Returns a certificate which is supposed to be used for the servers that provide the frontend and the websockets

Parameters:
Name Type Description
letsencryptPath String

the file path where the Let's Encrypt Challenge Files are served from

Source:
Returns:

The private key and public certificate to use

Type
Object

getCertificateDomains(pem) → {Array.<String>}

Returns the domains specified inside a certificate

Parameters:
Name Type Description
pem String

the certificate string

Source:
Returns:

list of domains

Type
Array.<String>

(async) getClient(config) → {Object}

creates openid client with library: https://github.com/panva/node-openid-client/blob/main/docs/README.md#client

Parameters:
Name Type Description
config Object

the iam configuration

Source:
Returns:
  • OpenID Client
Type
Object

getCompleteMachineInformation(machine) → {Object|undefined}

Returns the updated information for a machine if the machine information changed (returns undefined if not)

Parameters:
Name Type Description
machine Object

the machine we want to request information for

Source:
Returns:

the updated object or undefined if there was no new information

Type
Object | undefined

getConfiguration(machineId) → {Object}

Requests and returns the configuration of the engine on another machine

Parameters:
Name Type Description
machineId String
Source:
Returns:
  • contains config values
Type
Object

getDefinitionsIdForCallActivity(callActivityId) → {String|undefined}

Gets the id of the process definition of the process called in a callActivity

Parameters:
Name Type Description
callActivityId String
Source:
Returns:
  • the id of the process definition of the called process
Type
String | undefined

getDeployedProcesses(machine) → {array}

Requests information about all deployed processes of a machine

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

Source:
Returns:

definitionIds of all processes deployed to the given machine

Type
array

getDeployedToMachines(processDefinitionsId)

Returns an array with all machines the process with the given id is deployed to

Parameters:
Name Type Description
processDefinitionsId String

the id of the deployed process

Source:

getDeploymentBPMN(machine, definitionId) → {string}

Requests process bpmn of process with given id from given machine

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

Source:
Returns:

the process bpmn xml

Type
string

getDeployments()

Activates request for deployment information for all machines in request loop

Source:

getElementConstraints(element) → {Object}

Returns a constraint object containing all the constraints of the given object

Parameters:
Name Type Description
element Object

the modeler element we want to know the constraints of

Source:
Returns:
  • contains all constraints of the given element
Type
Object

getEnvFolder() → {String}

Find the path to the folder where the info about all Environment Profiles is stored

Source:
Returns:
Type
String

getEnvProfileJSON() → {String}

Get the json of an environment profile

Source:
Returns:

the environmentProfile json

Type
String

getEnvProfileName() → {String}

Find the path to the file where the info about an environment profile is stored

Source:
Returns:
Type
String

(async) getExportFile(processesToExport, options) → {Promise.<Object>}

Creates the file we want to export

Parameters:
Name Type Description
processesToExport Array.<Object>

the processes we want to export and their information

options Object

the selected export options

Source:
Returns:

the file to export

Type
Promise.<Object>

(async) getExportZip(processesToExport, viewer, options) → {Promise.<Object>}

Creates the zip file containing all the files we want from the export

Parameters:
Name Type Description
processesToExport Array.<Object>

the processes we want to export

viewer Object

a bpmn-io viewer

options Object

the selected export options

Source:
Returns:

the zip file to export

Type
Promise.<Object>

getFolder(id) → {String}

Find the path to the folder where the data of a specific process is stored

Parameters:
Name Type Description
id
Source:
Returns:
Type
String

getInstanceInformation(machine, definitionId, instanceId) → {object}

Request information about a certain process instance

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

instanceId string

id of the specific instance

Source:
Returns:

instance information object

Type
object

getLogHandler(engine)

Creates a callback function that can be used to handle calls from the log stream of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

Source:

getLogs(machineId) → {Object}

Requests and returns the logs of the engine on another machine

Parameters:
Name Type Description
machineId String
Source:
Returns:
  • Object containing logs for the engine and process execution
Type
Object

(async) getMachineInfo(ip, port)

Requests additional information about a machine

Parameters:
Name Type Description
ip String

the ip of the machine

port Number

the port the engine is running on

Source:

(async) getMachineInformation(machine) → {Object}

Gets some necessary information about the machine

Parameters:
Name Type Description
machine Object

contains machines network information to make request

Source:
Returns:
  • Object containing id, hostname and currentlyConnectedEnvironments
Type
Object

(async) getMachineInformationAndUpdate(machine)

Request information from a machine and update the local information on response

Parameters:
Name Type Description
machine Object

current information about the machine

Source:

getMachineProperties(machineId, properties) → {Object}

Requests and returns the properties for the given machine, desired properties can be specified

Parameters:
Name Type Description
machineId String
properties Array

names of the desired properties

Source:
Returns:
  • object containing the requested properties and their values
Type
Object

getOnAbortedHandler(engine, instance)

Creates a callback function that can be used to handle calls from the onAborted hook of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

instance Object

the process instance that ended

Source:

getOnCallActivityInterruptedHandler(engine, instance)

Creates a callback function that can be used to handle calls from the onCallActivityInterrupted hook of the neo engine -> stop execution of call activity processs

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

instance Object

the process instance the token is in

Source:

getOnEndedHandler(engine, onEnded, instance)

Creates a callback function that can be used to handle calls from the onEnded hook of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

onEnded function

function that is supposed to be called when instance ends

instance Object

the process instance that ended

Source:

getOnScriptTaskErrorHandler(engine, instance)

Creates a callback function that can be used to handle calls from the onScriptTaskError hook of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

instance Object

the process instance the token is in

Source:

getOnTokenEndedHandler(engine, onTokenEnded, instance)

Creates a callback function that can be used to handle calls from the onTokenEnded hook of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

onTokenEnded function

function that is supposed to be called when the execution of a token ends

instance Object

the process instance the token is in

Source:

getOnUserTaskInterruptedHandler(engine, instance)

Creates a callback function that can be used to handle calls from the onUserTaskInterrupted hook of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

instance Object

the process instance the token is in

Source:

getParameterInfo(id, expandedList)

a function that parses information about the parameter from the list

Parameters:
Name Type Description
id string

id of the related parameter node

expandedList object

list to search in

Source:

(async) getPlanInspectionOrder(engine, _5iInformation) → {Object}

Requests some information about a specific inspection order that we need to check if the order was finished

Parameters:
Name Type Description
engine Object

the engine of the process the user task occured in

_5iInformation Object

5thIndustry data needed to match the user task to a specific inspection order in 5thIndustry App

Properties
Name Type Description
apiAddress String

the url of the 5thIndustry GraphQL API

inspectionPlanId String

the inspection plan the inspection order is in (the plan that is linked to the process)

assemblyGroupId String

the assembly group the inspection order is in (an assembly group bundles multiple manufacturing steps)

manufacturingStepId String

the manufacturing step the inspection order is in (a manufacturing step contains multiple inspection orders)

inspectionOrderId String

id of the specific inspection order we want to target

Source:
Returns:

the order information

Type
Object

getPNG(viewer, isMultiDownload, resolution) → {Promise.<String>}

Creates a png from the process in the viewer

Parameters:
Name Type Description
viewer Object

the bpmn-js viewer to get the image from

isMultiDownload Boolean

if the png will be added to some kind of containing file

resolution Number
Source:
Returns:

the png data

Type
Promise.<String>

getProcess(processDefinitionsId, processesopt) → {Object}

Returns the locally stored process with the given id

Parameters:
Name Type Attributes Description
processDefinitionsId String
processes Object <optional>

the list of objects to search (to avoid redundant parsing)

Source:
Returns:

an Object containing the processes information

Type
Object

getProcessBpmn(processDefinitionsId) → {String}

Returns the process definition for the process with the given id

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:
  • the process definition
Type
String

getProcesses() → {Array}

Returns all known processes in form of an array

Source:
Returns:
  • array containing all known processes
Type
Array

getProcesses() → {Object}

Returns all processes that are stored in the browser

Source:
Returns:

an object containing all locally stored processes

Type
Object

getProcessesFolder() → {String}

Find the path to the folder where the info about all Processes is stored

Source:
Returns:
Type
String

(async) getProcessFile(process, viewer, options, containeropt) → {Promise.<(Object|String)>}

Creates a single file for a process

Parameters:
Name Type Attributes Description
process Object

the process from which we want to create the file

viewer Object

a bpmn-js viewer

options Object

the selected export options

container Boolean <optional>

pdf or zip directory the file will be added to

Source:
Returns:

the file or string with the process information

Type
Promise.<(Object|String)>

getProcessInstances(machine, definitionId) → {array}

Requests information about all instances of process with given id

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

Source:
Returns:

array with information objects for each instance of the process

Type
array

getProcessUserTaskHtml(processDefinitionsId, taskFileName) → {String}

Returns the html for a specific user task in a process

Parameters:
Name Type Description
processDefinitionsId String
taskFileName String
Source:
Returns:
  • the html under the given fileName
Type
String

getProcessUserTasks(processDefinitionsId) → {Array}

Returns the filenames of html data for all user tasks in the given process

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:
  • array containing the filenames of the htmls of all user tasks in the process
Type
Array

getProcessUserTasksHtml(processDefinitionsId) → {Object}

Return object mapping from user tasks fileNames to their html

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:
  • contains the html for all user tasks in the process
Type
Object

getResource(resourceId) → {Array}

Returns a resource based on resource id

Parameters:
Name Type Description
resourceId String

the id of a resource

Source:
Returns:
  • array containing all resources
Type
Array

getResources() → {Array}

Returns all resources in form of an array

Source:
Returns:
  • array containing all resources
Type
Array

getRoleById(roleId) → {Object}

Returns a role based on role id

Parameters:
Name Type Description
roleId String

the id of a role

Source:
Returns:
  • role object
Type
Object

getRoleMappingByUserId(userId) → {Array}

Returns a role mapping by user id

Parameters:
Name Type Description
userId String

the id of a user

Source:
Returns:
  • role mappings of a user
Type
Array

getRoleMappings() → {Array}

Returns all role mappings in form of an array

Source:
Returns:
  • array containing all role mappings
Type
Array

getRoles() → {Array}

Returns all roles in form of an array

Source:
Returns:
  • array containing all roles
Type
Array

getShare(shareId) → {Array}

Returns a share based on share id

Parameters:
Name Type Description
shareId String

the id of a share

Source:
Returns:
  • array containing all shares
Type
Array

getShares() → {Array}

Returns shares in form of an array

Source:
Returns:
  • array containing shares
Type
Array

getSingular(storeName) → {Strings}

Returns singular form of a stores name (machines => machine)

Parameters:
Name Type Description
storeName String

plural

Source:
Returns:
  • singular
Type
Strings

getStatus(machineId) → {Boolean}

Requests and returns information if the engine with the given id is running a proceed engine

Parameters:
Name Type Description
machineId String

the id of the machine we want to know the status of

Source:
Returns:
  • if the machine is running a proceed engine
Type
Boolean

getStore(storeName, defaultVal, noStorage)

Creates a new conf store that is used to store the current state of something

Parameters:
Name Type Description
storeName String

the name of the store referencing the thing we want to store

defaultVal undefined | Object | Array

the default layout of the store that is used when creating it

noStorage Boolean

used to signal if the store is supposed to be stored in the Storage subdirectory

Source:

getSVG(viewer, isMultiDownload)

Creates a SVG from the modeler content

Parameters:
Name Type Description
viewer Object

the bpmn-js viewer to get the data from

isMultiDownload Boolean

if the SVG will be added to some kind of container file

Source:

getUniqueMappedMachineAddresses(machineMapping)

Function that given a machineMapping will return an array of unique machine addresses of machines in the mapping

Parameters:
Name Type Description
machineMapping object

the mapping that contains the machines we want to know the addresses of

Source:

getUpdatedDeploymentInfo(machine) → {object|undefined}

Gets updated information about the processes deployed on the given machine

Parameters:
Name Type Description
machine object
Properties
Name Type Description
ip string

the ip of the given machine

port number

the port the engine is accessible through

Source:
Returns:

information about the processes deployed on the machine or undefined if nothing changed

Type
object | undefined

(async) getUpdatedDeployments()

Checks if there are deployments on the machine that are not known locally or vice versa and updates accordingly

Source:

getUpdateInterval() → {Number}

Returns the time between two requests for machine information

Source:
Returns:

the interval time

Type
Number

(async) getUserInfo() → {Object}

calls userinfo endpoint at idp via backend to retreive user information

Source:
Returns:
  • userinfo object
Type
Object

getUserTaskDir(id)

Find the user task directory for the given process

Parameters:
Name Type Description
id String
Source:

getUserTaskHTML(processDefinitionsId, taskId)

Returns the html for a user task with the given id in a process

Parameters:
Name Type Description
processDefinitionsId String
taskId String
Source:

getUserTaskHTML(machine, definitionId, userTaskId) → {string}

Gets HTML for user task with given id in process with given id

Parameters:
Name Type Description
machine Object

contains machine information

Properties
Name Type Description
ip String

the ip address of the machine

port Number

the port of the machine

definitionId String

name of the file the process is saved in

userTaskId String

id of the user task

Source:
Returns:

the user task html

Type
string

getUserTaskIds(processDefinitionsId)

Returns the ids of all user tasks of the process with the given id

Parameters:
Name Type Description
processDefinitionsId String
Source:

getUserTasksByProcess(process)

Parameters:
Name Type Description
process Object
Source:
Returns:
  • Returns usertasks for a process from the store

getUserTasksHTML(processDefinitionsId) → {Promise}

Returns the html for all user tasks in a process

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:
Type
Promise

getUserTasksHTML(processDefinitionsId) → {Object}

Returns the user task data for all user tasks in a process

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:

contains mapping from user task filename to user task data

Type
Object

getXmlByProcess(process)

Parameters:
Name Type Description
process Object
Source:
Returns:
  • Returns xml for a process from the store

(async) handle5thIndustryUserTask(userTask, engine)

Will setup everything that is needed to handle a User Task that is using 5thIndustry as its implementation

Parameters:
Name Type Description
userTask Object

the user task object from the neo engine

engine Object

the proceed engine instance associated with the process the user task occured in

Source:

handleLetsEncrypt(letsencryptPath, frontendServers)

Handles Let's Encrypt functionality, e.g. keeping certificates up to date and requesting a new certificate when the list of domains for the server changes

Parameters:
Name Type Description
letsencryptPath String

the file path where the Let's Encrypt Challenge Files are served from

frontendServers Array.<Object>

the node https servers used for the frontend and the websockets

Source:

(async) handleOauthCallback() → {Object}

executed on every page load performs oauth callback when oauth authorization request is detected based at backend

Source:
Returns:
  • authenticated or unauthenticated user information
Type
Object

hasProcess(processDefinitionsId) → {Boolean}

Returns if a process with the given id is stored in the browser

Parameters:
Name Type Description
processDefinitionsId String
Source:
Returns:
Type
Boolean

(async) init()

For explanation for the general server architecture, see: https://gitlab.com/dBPMS-PROCEED/proceed/-/wikis/MS/Architecture-Server-and-Desktop-App#ms-server-architecture

Source:

init() → {Object}

Creates the initial config which is a merge of the user config and the default config

Source:
Returns:

the initial config

Type
Object

init()

initializes the resources meta information objects

Source:

init()

initializes the role mappings meta information objects

Source:

init()

initializes the roles meta information objects

Source:

init()

initializes the shares meta information objects

Source:

init()

initializes the process meta information objects

Source:

(async) initAdditionalLetsEnrypt(letsencryptPath, frontendServers, coveredDomains)

Will initialize an AcmeService to augment the already existing Certificate.

This will request a Let's Encrypt Certificate for URLs that are entered into the config and that point at the server but are not covered by the main certificate. Requests to the URLs will be served using the Let's Encrypt Certificate while all others are served using the main certificate

Parameters:
Name Type Description
letsencryptPath String

the file path where the Let's Encrypt Challenge Files are served from

frontendServers Array.<Object>

the node https servers used for the frontend and the websockets

coveredDomains Array.<String>

the domains that are already covered by the main certificate and should not be considered for the LE certificate

Source:

initRenderJSON(config)

Initializes the dom tree that represents the config ui

Parameters:
Name Type Description
config Object

the config values as gotten from the engine

Source:

inputElement(parentElement, key, valueBefore, callback) → {Object}

Sets up dom elements (input etc.) and callbacks for a specific config entry

Parameters:
Name Type Description
parentElement Object

the DOM element the new elements should be placed in

key String

the key of the entry we want to set up the input for

valueBefore String | Boolean | Number

the current value of the entry

callback function

the callback that is supposed to be called on change

Source:
Returns:

the newly created line containing the input elements

Type
Object

isSubset(set, candidate) → {Boolean}

A function that checks if an object or array contains only the entries contained in some other array or object

the other object(|array) might contain additional entries

(set doesn't mean that the arrays can contain a value only once in this case)

Parameters:
Name Type Description
set Object | Array

the object or array we want to compare against

candidate Object | Array

the object we want to check

Source:
Throws:

Will throw an error if the two given values are not of the same type or if they are not of the specified type (null is also not allowed)

Returns:

if the candidate contains only elements of the original object

Type
Boolean

listen(event, listener, once)

Function to receive events from the server without response alignment (ids).

Parameters:
Name Type Description
event string

The name of the event

listener function

The listener function

once boolean

Indicating if only one time listener

Source:

(async) mapUserTasks(newPlan)

Tries to adjust the ids of the assembly groups, manufacturing steps and inspection orders that were assigned to user tasks

This is necessary since the ids change when a plan is created from a template

Parameters:
Name Type Description
newPlan Object

the newly created plan

Source:

mergeIntoObject(target, toMerge, deepMerge, noNewValues, typesafe) → {Object}

Function that allows overwriting entries in an object with values given in another object

Parameters:
Name Type Description
target Object

the object to merge into

toMerge Object

the object containing the new values

deepMerge Boolean

if nested objects are supposed to be merged recursively (else they are just overwritten)

noNewValues Boolean | String

flag to disallow new entries being added to the target object ('strict' for error, true for silent ignore)

typesafe Boolean | String

if entries are not allowed to change their type ('strict' for error, true for silent ignore)

Source:
Returns:

object containing the values that were actually changed (some changes might be silently ignored due to flags)

Type
Object

(async) migrateProcesses()

migrates all available processes

Source:

(async) migrateRoles()

migrates all available roles

Source:

(async) migrateShares()

migrates all available shares

Source:

moveToken(machine, processDefinitionsId, instanceId, tokenId, flowElementId)

Moves token inside an instance to a new flow element

Parameters:
Name Type Description
machine Object
Properties
Name Type Description
ip String

the ip address of the machine

port Number

the port of the machine

processDefinitionsId String
instanceId String
tokenId String
flowElementId String
Source:

moveToken(machine, definitionId, instanceId, tokenId, flowElementId)

Sends a request to move a token from one element to another

Parameters:
Name Type Description
machine Object

the machine that is currently executing the token

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

instanceId string

id of the specific instance

tokenId string

id of the token to move

flowElementId string

id of the target element

Source:

needZipExport(processesToExport, options) → {Boolean}

Checks if we have to export more than one file which means we have to use a zip file

Parameters:
Name Type Description
processesToExport Array.<Object>

the process(es) we want to export

options Object

the export options (e.g. which file format to export to)

Source:
Returns:

if the export has to be in form of a zip

Type
Boolean

normalizeUrl(url)

Will remove trailing slash from a url if there is one

Parameters:
Name Type Description
url String

the url to normalize

Source:

observeProcess(processDefinitionsId)

Connects to process namespace and sets up handlers for server side events

Parameters:
Name Type Description
processDefinitionsId String
Source:

onCallActivity(engine, Engine, instance)

Creates a callback that handles the execution of callActivities when one becomes active

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

Engine Class

the process Execution class that we want to create a new Instance of to execute the callActivity process

instance Object

the process instance the call activity was encountered in

Source:

onRefreshData()

Gets current config values from engine and builds dom from it

Source:

onUserTask(engine, instance)

Creates a callback function that can be used to register to the userTask stream of the neo engine

Parameters:
Name Type Description
engine Object

proceed engine instance that contains the process information

instance Object

the process instance the user task was encountered in

Source:

onWriteUserConfig()

Sends updated config to the engine

Source:

parse(elementRegistry, elementFactory, bpmnFactory, command, context) → {object}

Transforms the serialized context back into a form that we can use to trigger an event similar to the original one

Parameters:
Name Type Description
elementRegistry object

gives us functions to get elements in the modeler (shapes, processes, sequence flows)

elementFactory object

gives us functions to create modeler elements

bpmnFactory object

gives us functions to create the businessObjects of modeler elements

command object

the command we will execute

context object

the serialized context

Source:
Returns:
  • the restored context
Type
object

pauseInstance()

Sends request to pause an instance of a process on a machine

Source:

pauseProcessInstance(machine, definitionId, instanceId)

Sends request to pause a certain process instance

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

instanceId string

id of the specific instance

Source:

(async) pingDiscoveredMachines()

Periodically pings discovered machines to ensure that they didn't going offline without signal

Source:

(async) pollInspectionOrderProgress(engine, userTask, _5iInformation)

Will poll the 5thIndustry App to see if the Inspection Order linked to the user task has been finished

Parameters:
Name Type Description
engine Object

an instance of the proceed engine in which the process is executed in

userTask Object

the user task that has become active insde the process

_5iInformation Object

5thIndustry data needed to match the user task to a specific inspection order in 5thIndustry App

Properties
Name Type Description
apiAddress String

the url of the 5thIndustry API that needs to be used when activating the inspection order

inspectionPlanId String

the inspection plan the inspection order is in (the plan that is linked to the process)

assemblyGroupId String

the assembly group the inspection order is in (an assembly group bundles multiple manufacturing steps)

manufacturingStepId String

the manufacturing step the inspection order is in (a manufacturing step contains multiple inspection orders)

inspectionOrderId String

id of the specific inspection order we want to target

Source:

(async) pollMachinesInformation()

Occasionally polls all machines for up to date informations

Source:

prepareProcesses(allProcesses, processesToExport, options)

Retrieve every subprocess and subprocesses of call activities for the processes to export and their meta information, bpmn and user tasks

Parameters:
Name Type Description
allProcesses Array.<Object>

all known processes to search for referenced call activities

processesToExport Array.<Object>

all processes that need to be exported

options Object

export format

Source:

preSerialize(command, context) → {object}

Transforms the given context into a JSON serializable form this form contains everything to restore the information on another client to apply the event in the same way

Parameters:
Name Type Description
command string

the command that is supposed to be executed on another machine

context object

the information needed to execute the command

Source:
Returns:
  • the transformed context
Type
object

(async) pullProcess(id, isUpdateopt) → {Object}

Pulls process from the backend writes it to the browser storage and returns it

Parameters:
Name Type Attributes Description
id String

the definitions id of the process

isUpdate Boolean <optional>

if the process is known but supposed to be synchronized with the server

Source:
Returns:

The process with the given id

Type
Object

(async) reEvaluateDynamicDeployment(engine, processInstanceId, processInfo, tokenId, from, to) → {dynamicDeploymentResult}

Reevaluate after timer expired to find the optimal next machine to continue execution of the current token

Parameters:
Name Type Description
engine object

instance of the engine class containing all information about the current process and its instances

processInstanceId string

id of the specific instance the token is running in

processInfo object

object with information about the executed process

tokenId string

the id of the token for which we have to decide where to execute it next

from string

the previous executed element

to string

the next element to be executed

Source:
Returns:

holding information about continuation of execution

Type
dynamicDeploymentResult

registerModeler(modeler)

Registers the modeler the events are supposed to be applied in with this module

Parameters:
Name Type Description
modeler Object

an instance of a bpmn-js modeler

Source:

registerModeler(modeler)

Registers the modeler for which we want to distribute and apply the events

Parameters:
Name Type Description
modeler Object

the modeler

Source:

remove(storeName, elementId)

Function to remove an element from a store (store has to have property like with add)

Parameters:
Name Type Description
storeName String

name of the store we want to remove from

elementId String

id of the element we want to remove

Source:

removeCallActivityReference(callActivityId, noDistribution)

Remove the reference to the called process added in addCallActivityReference but remains the actual bpmn element

Parameters:
Name Type Description
callActivityId String

The ID of the bpmn element for which the meta information should be removed

noDistribution Boolean

if this event should not be distributed to other machines

Source:

removeDeployment(processDefinitionsId)

Removes the deployment of the process with the given id from all currently connected machines

Parameters:
Name Type Description
processDefinitionsId String

the id of the deployed process

Source:

removeDeployment(machine, definitionId)

Sends request to delete the deployment of process with given id

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

Source:

(async) removeDeploymentFromMachines(definitionId, machines)

Removes deployed process with corresponding definitionid from all given machines

Parameters:
Name Type Description
definitionId String

name of the file the process is stored under

machines Array

contains information about all machines the process is supposed to be removed from

Source:

removeDictElement(storeName, elementId, itemId)

Function to remove an element from a store in dictionary format

Parameters:
Name Type Default Description
storeName String

name of the store we want to remove from

elementId String

id of the element we want to remove

itemId String null

only if nested item in element should be removed

Source:

removeExcessiveInformation(machineInfo) → {Object}

Returns an object that contains only the most vital information about an object that we would like to store

which is: id, ip, port, hostname, name, optionalName

Parameters:
Name Type Description
machineInfo Object

a machine information object

Source:
Returns:
  • an object that contains a subset of the original object information
Type
Object

removeExcessiveInformation(processInfo)

Removes information from the meta data that would not be correct after a restart

Parameters:
Name Type Description
processInfo Object

the complete process meta information

Source:

(async) removeMachine(service)

Removes machine which unpublished its service from the list of known machines

Parameters:
Name Type Description
service Object
Source:

removeMachine(machineId)

Handles machines that are removed by the user

Parameters:
Name Type Description
machineId String

id of the machine to remove

Source:

removeMachineLogsSubscription(machineId)

Remove flag so that logs for the machine are not requested anymore

Parameters:
Name Type Description
machineId String

the machine for which logs are not needed anymore

Source:

removeMachineSubscription(machineId)

Remove flag for extended information about a specific machine

Parameters:
Name Type Description
machineId String

machine for which extended information is not needed anymore

Source:

removeProcess(processDefinitionsId)

Removes an existing process

Parameters:
Name Type Description
processDefinitionsId String
Source:

removeProcess(processDefinitionsId)

Removes a process from the localStorage

Parameters:
Name Type Description
processDefinitionsId String
Source:

removeUserTaskForm(taskId)

Removes the displayed form of a user task (does nothing if it isn't currently displayed)

Parameters:
Name Type Description
taskId String

id of the user task of which we want to remove the form

Source:

renderFirstLayerJSON(parentNode, configObject)

Actually the same functionality as in renderJSON(), but that it puts the input elements first and then the configuration objects. Needed to put 'name' and 'description' before all other configs.

Parameters:
Name Type Description
parentNode Object

the node inside which the current tree should be build (might be the root or some encapsulating config tree)

configObject Object

the config for which the ui should be build

Source:

renderJSON(parentNode, configObject)

(Recursively) builds the ui which allows editing the given config

Parameters:
Name Type Description
parentNode Object

the node inside which the current tree should be build (might be the root or some encapsulating config tree)

configObject Object

the config for which the ui should be build

Source:

request(event, …data) → {Promise.<any>}

Function to send and receive exactly one event. It takes care of the response alignemnt using ids to match the async reponse from the server with the initial request.

Parameters:
Name Type Attributes Description
event string

The name of the event

data any <repeatable>

The (raw) data to send

Source:
Returns:

The response from the server

Type
Promise.<any>

requestDeploymentInformation() → {Promise.<Array.<void>>}

Request deployment information from every connected machine

Source:
Returns:

Resolves if all deployment information was requested

Type
Promise.<Array.<void>>

(async) restRequest(path, options) → {Object|Array|String}

function prepares http requests

Parameters:
Name Type Description
path String

request path

options Object

default undefined, otherwise necessary http request options

Source:
Returns:
  • response of http request
Type
Object | Array | String

resumeInstance()

Sends request to resume an instance of a process on a machine

Source:

resumeProcessInstance(machine, definitionId, instanceId)

Sends request to resume a certain process instance

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

instanceId string

id of the specific instance

Source:

runningInstances()

Returns array with all instances that didn't finish yet for the displayed machine

Source:

saveEnvProfile(Id, type, environmentProfile)

Saves the json for a given environment profile

Parameters:
Name Type Description
Id String

the id of the environment profile

type String

the type of the environment profile

environmentProfile String

the environment profile json

Source:

saveProcess(id, bpmn)

Saves the process bpmn of a process

Parameters:
Name Type Description
id String

the id of the process

bpmn String

the process description

Source:

saveScriptTaskJS(processDefinitionsId, taskId, js)

Saves the script for a scriptTask

Parameters:
Name Type Description
processDefinitionsId String
taskId String
js String
Source:

saveScriptTaskJS(processDefinitionsId, taskId, js)

Saves script task data for a specific task inside a process

Parameters:
Name Type Description
processDefinitionsId String
taskId String
js String
Source:

saveUserTaskHTML(processDefinitionsId, taskId, html)

Saves the html of the a user task

Parameters:
Name Type Description
processDefinitionsId String

the id of the process that contains the user task

taskId String

the id of the specific user task

html String

the html data of the user task

Source:

saveUserTaskHTML(definitionsId, taskFileName, html)

Saves user task data for a specific process

Parameters:
Name Type Description
definitionsId String
taskFileName String

the tasks filename that would be used if it was stored on the server

html String

the user task data

Source:

saveUserTasksHtml(definitionsId, userTasks)

Overwrites user tasks of a process with the given ones

Parameters:
Name Type Description
definitionsId String
userTasks Object

mapping from filenames to the contained html

Source:

sendConfiguration(machineId, configuration)

Sends a configuration to an engine which it is supposed to use

Parameters:
Name Type Description
machineId String
configuration Object

object containing config values

Source:

(async) sendGraphQLRequest(data) → {Object}

Will send a request to 5thIndustries GraphQL API

Parameters:
Name Type Description
data Object

the request data to send

Source:
Throws:

Throws an exception if the GraphQL API returns an error code

Returns:

the response body

Type
Object

sendImportedProcess(machine, definitionId, importedDefinitionId, bpmn)

Sends process used in call activity of another process

Parameters:
Name Type Description
machine Object

contains machine information

Properties
Name Type Description
ip String

the ip address of the machine

port Number

the port of the machine

definitionId String

the id in the definitions field of the importing process

importedDefinitionId String

the id in the definitions field of the imported process

bpmn String

the description of the process in xml

Source:

(async) sendImportedProcesses(process, bpmn, machineInfo, dynamic)

Checks the process for imported processes and sends them to the correct endpoint if there are any

Parameters:
Name Type Description
process *
bpmn *
machineInfo *
dynamic Boolean

if the process is deployed dynamically

Source:

(async) sendUserTaskHTML(process, machineInfo, dynamic)

Sends user task html to all machines that need them

Parameters:
Name Type Description
process object

used to determine the endpoint we want to send the data to (actual process/importing process)

machineInfo object

either a map mapping taskId to machine or a machine

dynamic bool

indicates if the html is to be send to a singular machine or multiple ones

Source:

sendUserTaskHTML(machine, definitionId, userTaskId, html)

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

userTaskId string

id of the user task

html string

the html of the user task

Source:

setDictElement(storeName, newItem)

Function to set an element in dictionary format

Parameters:
Name Type Description
storeName String

the name of the store we want to add to

newItem Object

the object we want to add

Source:

(async) setInspectionOrderTokenState(engine, _5iInformation, tokenState)

Will set an attribute on a specific inspection order that signals that the linked User Task is either currently active or not active

Parameters:
Name Type Description
engine Object

the engine of the process the user task occured in

_5iInformation Object

5thIndustry data needed to match the user task to a specific inspection order in 5thIndustry App

Properties
Name Type Description
apiAddress String

the url of the 5thIndustry GraphQL API

inspectionPlanId String

the inspection plan the inspection order is in (the plan that is linked to the process)

assemblyGroupId String

the assembly group the inspection order is in (an assembly group bundles multiple manufacturing steps)

manufacturingStepId String

the manufacturing step the inspection order is in (a manufacturing step contains multiple inspection orders)

inspectionOrderId String

id of the specific inspection order we want to target

tokenState Boolean

if the token is currently on the linked user task or not

Source:

setPdfPropsAndValues(pdf, imageURI, process, isHeadingRequested, svgWidth, svgHeight)

create PDF with Properties and Values

Parameters:
Name Type Description
pdf Object

the pdf we want to add to

imageURI String
process Object

the process we add the image for

isHeadingRequested Boolean

if the images in the pdf should be anotated

svgWidth String
svgHeight String
Source:

setProcessDefinitionsId(pId, sId)

Sets processDefinitionsId and optional subprocessId which is needed when distributing the event

Parameters:
Name Type Description
pId String

supposed id of the process insidethe modeler

sId String

supposed id of the subprocess

Source:

setTaskExternal(element, external)

Sets external value on a task

Parameters:
Name Type Description
element Object

the element to change

external Boolean

if the task is supposed to be external

Source:

(async) settleRequest(request) → {object}

Waits for request to resolve or reject and returns the result and information if it succeded

Parameters:
Name Type Description
request promise

the request we await to resolve

Source:
Returns:

object containing a result and a status member

Type
object

setUpdateInterval(newInterval)

Allows changing the time between two consecutive machine information requests

Parameters:
Name Type Description
newInterval Number

the new time between two requests (in seconds)

Source:

setupMachineInfoRequestHandlers(addListener)

Setup handlers for specific subscription requests from clients

Parameters:
Name Type Description
addListener function

allows setting callbacks for socket requests from clients

Source:

start5thIndustryPlan(inspectionPlanId)

Will set a plan into a in progress state to signal that it is being executed

Parameters:
Name Type Description
inspectionPlanId String
Source:

startInstance(processDefinitionsId)

Starts an instance of the deployed process with the given id

Parameters:
Name Type Description
processDefinitionsId String

id of the deployed process

Source:
Throws:

Will throw an error if starting the instance fails

startMachinePolling(socket)

Handles the request of a client for recurring updates about all machines

Parameters:
Name Type Description
socket Object

the requesting socker

Source:

startPolling()

Activates a polling loop that requests information from all machines

Source:

startProcessInstance(machine, definitionId, variables) → {string}

Sends request to start an instance of a process with process variables

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

variables object

start values for process variables

Source:
Returns:

the id of the created isntance

Type
string

(async) staticDeployment(process, bpmn)

Sends process bpmn and user task html to all machines that were mapped to flowNodes in the process

Parameters:
Name Type Description
process Object

object containing all information about the process to deploy

bpmn String

the process description in xml

Source:

stop5thIndustryPlan(inspectionPlanId)

Will set the plan back to an open state to signal that is currently not being executed (might be necessary when something in the linked process fails)

Parameters:
Name Type Description
inspectionPlanId String
Source:

stopInstance()

Sends request to stop an instance of a process on a machine

Source:

(async) stopInstanceOnNetwork(definitionId, instanceId)

Sends request to stop process instance to all machines in the local network

Parameters:
Name Type Description
definitionId string

name of the file the process is stored in

instanceId string

the id of the instance to stop

Source:

stopMachinePolling(socket)

Removes a socket from the list of subscribed sockets and stops request for updates if no socket remains

Parameters:
Name Type Description
socket Object
Source:

(async) stopObserving(processDefinitionsId)

Unregisters from process namespaces

Parameters:
Name Type Description
processDefinitionsId String
Source:

stopPolling()

Deactivates the machine polling loop

Source:

stopProcessInstance(machine, definitionId, instanceId)

Sends request to stop a certain process instance

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
ip string

the ip address of the machine

port number

the port of the machine

definitionId string

name of the file the process is saved in

instanceId string

id of the specific instance

Source:

strikeMachine(machine)

Adds a strike for an unreachable discovered machine and removes it at the third strike

Parameters:
Name Type Description
machine Object

machine information object

Source:

subObjectElement(parentNode, objName, subObject)

Sets up recursive rendering of a config sub object inside the parent element

Parameters:
Name Type Description
parentNode Object

the element the subobject nodes should be placed in

objName String

key of the config subobject

subObject Object

an object inside a config object

Source:

subscribeToMachine(machineId, socket)

Function that subscribes a client to updates of information about one machine

Parameters:
Name Type Description
machineId string
socket object

the connection to the client that wants the information

Source:

subscribeToMachineLogs(machineId, socket)

Subscribes a client to the log stream of a machine

Parameters:
Name Type Description
machineId String

the machine that the client wants information for

socket Object

the endpoint for the client that wants the information

Source:

tablesChanged(data) → {Boolean}

Checks if there are new tables or tables were removed

Parameters:
Name Type Description
data Object

new logging data

Source:
Returns:

if the list of tables changed

Type
Boolean

toListString(array, cutoffopt) → {String}

Takes an array of strings and returns a string that lists all entries separated by commas and an "and"

e.g.

[entry] => "[entry]"; [entry 1, entry 2] => "[entry 1] and [entry 2]" [entry 1, entry 2, ..., entry n] => "[entry 1], [entry 2], ..., [entry n-1] and [entry n]"

Parameters:
Name Type Attributes Description
array Array.<String>

the array of strings to convert

cutoff Number <optional>

the maximum number of elements that will be enumerated (if there are more a "and x more" will be appended to the string)

Source:
Returns:

the string listing the entries of the array

Type
String

triggerExport(fileName, objectContent)

Handles the export of the created file

Parameters:
Name Type Description
fileName String

name used to download file

objectContent String | Object

content, either as Blob or objectURL DOMString

Source:

unblockProcess(socketId, processDefinitionsId)

Removes the id of the socket wanting to unblock the process from the process object

Parameters:
Name Type Description
socketId String
processDefinitionsId String
Source:

unsubscribeFromAllLogs(socket)

Clears all log subscriptions of a client

Parameters:
Name Type Description
socket Object

the client that unsubscribes

Source:

unsubscribeFromAllMachines(socket)

Clears all subscriptions of a client

Parameters:
Name Type Description
socket Object

the client that unsubscribes

Source:

unsubscribeFromMachineLogs(machineId, socket)

Unsubscribes a client from the log stream of a machine

Parameters:
Name Type Description
machineId String

the machine the client doesn't want logs for anymore

socket Object

the endpoint for the client that wants no logs anymore

Source:

update(storeName, elementId, updatedInfo)

Function to update a single value inside one of the stores

Parameters:
Name Type Description
storeName String

the name of the store we want to update something in

elementId String

the id of the element we want to update

updatedInfo Object

the info we want to overwrite the current one with

Source:

(async) update5thIndustryAuthorization()

Will try to create a valid 5thIndustry Authorization token using the service account data provided through the REST API

Source:
Throws:

Will throw an error if there is no service account data

updateBPMN(processDefinitionsId, bpmn)

Updates the process definition of a process in the local storage

Parameters:
Name Type Description
processDefinitionsId String
bpmn String

the new process definition

Source:

updateByIds(storeName, idUpdateMap, key:, value:)

Allows the manipulation of specific objects in the given store BEWARE: Don't use this on the config store

Parameters:
Name Type Description
storeName string
idUpdateMap object

object with key value pairs

key: string

the id of the object we want to change

value: object

the new value for the object we want to change

Source:

(async) updateInspectionPlan(inspectionPlanId, values, type)

Sends a request to the 5thIndustry backend to change attributes of an existing plan

Parameters:
Name Type Description
inspectionPlanId String
values Object

the entries to change as key value pairs

type String

what kind of plan is supposed to be changed (either "template" or "entity")

Source:

updateProcess(id, bpmn, newName)

Saves new process bpmn for an existing process and changes the file and directory name if the process name changed

Parameters:
Name Type Description
id String
bpmn String
newName String

optional

Source:

updateProcess(processDefinitionsId, newBpmn) → {Object}

Updates an existing process with the given bpmn

Parameters:
Name Type Description
processDefinitionsId String
newBpmn String
Source:
Returns:
  • contains the new process meta information
Type
Object

updateProcessDescription(processDefinitionsId, description)

Updates a processes description in its definition and meta data

Parameters:
Name Type Description
processDefinitionsId String
description String
Source:

updateProcessMetaData(processDefinitionsId, metaChanges)

Direct updates to process meta data, should mostly be used for internal changes (puppeteer client, electron) to avoid parsing the bpmn unnecessarily

Parameters:
Name Type Description
processDefinitionsId Object
metaChanges Object

contains the elements to change and their new values

Source:

updateProcessMetaData(processDefinitionsId, metaChanges)

Updates the meta data about a process in the local storage

Parameters:
Name Type Description
processDefinitionsId String
metaChanges String

contains the entries to change

Source:

updateProcessName(processDefinitionsId, newName)

Changes the name of a process in its definition and meta data

Parameters:
Name Type Description
processDefinitionsId String
newName String
Source:

(async) updateProcessViaWebsocket(id, bpmn, processChanges)

Sends the new bpmn of a process for the backend to save

Parameters:
Name Type Description
id String

id of the process

bpmn String
processChanges String

changes to the process meta information that should be merged on the server

Source:

updateRole(roleId, roleRepresentation) → {Object}

Updates a role by id for the PROCEED MS

Parameters:
Name Type Description
roleId String

if of role

roleRepresentation Object

role representation

Source:
Returns:
  • updated role
Type
Object

updateShare(shareId, updates) → {Object}

Updates a share based on share id

Parameters:
Name Type Description
shareId String

the id of a share object

updates Object

the updated share object properties

Properties
Name Type Description
permissions Number

allowed permissions (optional)

password String

password for a link sharing (only for type link, optional)

expiredAt Date

date when a sharing should expire (optional)

note String

a note for users that receive the sharing (optional)

Source:
Returns:
  • updated share object
Type
Object

updateStoreIfInfoChanged(oldInfo, newInfo)

Checks if a change of machine information should trigger a mutation of the backend machine store

Parameters:
Name Type Description
oldInfo Object

contains the previously known information about a machine

newInfo Object

contains the newly available information about a machine

Source:

updateUserTaskMilestone(machine, instanceId, userTaskId, processChain, callChain, milestone)

Update milestone on UserTask

Parameters:
Name Type Description
machine object

contains machine information

Properties
Name Type Description
host string

the ip address of the machine

port number

the port of the machine

instanceId string

id of the instance the userTask is running in

userTaskId string

id of the active userTask

processChain string
callChain string
milestone object

object with id and value of milestone

Source:

(async) waitForNetworkConnection()

Periodically checks if there is a network connection and restarts discovery functionality if there is

Source:

Type Definitions

asyncArrayCallback(entry, index)

A function called for all functions of an array

Parameters:
Name Type Description
entry *

The current entry of the array

index Number

The index of the current entry inside the array

Source:

downCallback(machine)

callbacks that are to be called when a discovered service goes down

Parameters:
Name Type Description
machine Object

the machine that unpublished its service

Source:

upCallback(newMachine)

callbacks that are to be called if a new machine is discovered

Parameters:
Name Type Description
newMachine Object

the machine that was newly discovered

Source:

Events

input(value): the changed editor value

Monaco Editor component.

Emits:

Source: