You have been redirected from an outdated version of the article. Below is the content available on this topic. To view the old article click here.

NotNull

Flow Elements - NotNull

Description

The NotNull element accepts multiple data sources and evaluates whether they are not null.

Parameters

Name Description
DataSources Accepts multiple DataTarget connections
Result Connects to a logic node DataSource or a Decision Condition

Search results for "NotNull"

NotNull

The NotNull element accepts multiple data sources and evaluates whether they are not null.

onCreate

  • Is called when an object is created (but the transaction is not yet committed)
  • Multiple onCreate methods can exist per type - every method prefixed with onCreate is called when an object is created (e.g. onCreate01, onCreate02)
  • Schema constraint checks (uniqueness constraint, notNull constraint) are performed after onCreate has run
  • can be rolled back
    • if an error occurs
    • if an error is raised via error() function
    • if a constraint is violated
  • All regular keywords can be used - no special keywords are introduced for this method

Example:

onSave

  • Is called when an object is modified. (Either modification of local attributes of relationships. When a relationship is created, the onSave is triggered for both nodes)
  • creation of an object is not a modification, thus the onSave is not run when an object is created (even if the object is ‘modified’ in onCreate)
  • Multiple onSave methods can exist per type - every method prefixed with onSave is called when an object is created (e.g. onSave01, onSave02)
  • Schema constraint checks (uniqueness constraint, notNull constraint) are performed after onSave has run
  • can be rolled back
    • if an error occurs
    • if an error is raised via error() function
    • if a constraint is violated
  • All regular keywords can be used - one special keyword is introduced for this method

The state of the object in the scripting environment represents the state of the object after the modification. To get information about the previous state the keyword modifications can be used.

Keyword Value
modifications Object containing the modifications made to the object in the current operation

Example: