populateVariables
Populates a list of variables for use in dropdown controls.
Signature
populateVariables(
source: Node | NodeBlock | Condition | ConditionBlock,
filter?: (slot: Slot, pipe: boolean, block: NodeBlock) => boolean,
value?: string,
includeSelf?: boolean,
...excludes: (string | undefined)[]
): IDropdownOption[]
Parameters
Name | Type | Optional | Description |
---|---|---|---|
source | Node | NodeBlock | Condition | ConditionBlock | No | Specifies the source for the list. |
filter | (slot: Slot , pipe: boolean, block: NodeBlock ) => boolean | Yes | Optional filter function that is invoked for each slot found. |
value | string | Yes | Specifies an optional value of the control that will use the variables list. This will assure that the referenced variable in that value will be included in the list. |
includeSelf | boolean | Yes | Specifies if slots of the source should be included or not (default is false ). |
...excludes | (string | undefined)[] | Yes | Specifies the slot identifiers of slots that should be ignored. |
Return value
Returns an IDropdownOption
array with dropdown options.