ArchValueGroup(coreExpressionViewModel)

new ArchValueGroup(coreExpressionViewModel)

This class holds a value in Architect Scripting. Data Type: Group Note: Do not attempt to create instances of this class directly. They will be created automatically as needed by Architect Scripting.

Parameters:
Name Type Description
coreExpressionViewModel object

( Internal ) an Architect core expression view model.

Extends

Members

static, readonly displayTypeName :string

Implements override support for the display type name string for this Architect Scripting object.

readonly consumesSecureData :boolean

Returns whether or not this value uses secure data. For this to be the case, the value must use a secure variable either in an expression or as the configured variable.

Inherited From:

readonly dataType :ArchDataType

The Architect data type associated with this value.

Inherited From:

readonly flowLevelDefault :ArchBaseValue

If this value has a flow-level default setting value available, this method will return the value for that setting. Otherwise, null will be returned. To see if a value has a flow level default, you can check the ArchValueSettings#hasFlowLevelDefault property.

Inherited From:

readonly hasError :boolean

Returns whether or not this value currently has an error. While this is certainly useful, please note the following:

  • Any asynchronous methods that have been called on this value that are still pending will not update the error state until the asynchronous method completes.
  • This property will reflect the value's view of itself and lots of times you'll want to look at validation results themselves in that the errors or warnings there will have informational strings that specify more information on what's wrong within the context of a containing object. This object can also identify issues between the relationship of multiple values within the object which an individual value cannot. An example of an "object" would be an action within a flow.
Inherited From:

readonly hasErrorOrWarning :boolean

Returns whether or not this value currently has an error or warning. While this is certainly useful, please note the following:

  • Any asynchronous methods that have been called on this value that are still pending will not update the error or warning state until the asynchronous method completes.
  • This property will reflect the value's view of itself and lots of times you'll want to look at validation results themselves in that the errors or warnings there will have informational strings that specify more information on what's wrong within the context of a containing object. This object can also identify issues between the relationship of multiple values within the object which an individual value cannot. An example of an "object" would be an action within a flow.
Inherited From:

readonly hasWarning :boolean

Returns whether or not this value currently has a warning. While this is certainly useful, please note the following:

  • Any asynchronous methods that have been called on this value that are still pending will not update the warning state until the asynchronous method completes.
  • This property will reflect the value's view of itself and lots of times you'll want to look at validation results themselves in that the warnings there will have informational strings that specify more information on what's wrong within the context of a containing object. This object can also identify issues between the relationship of multiple values within the object which an individual value cannot. An example of an "object" would be an action within a flow.
Inherited From:

readonly isArchValueGroup :boolean

Returns true indicating that this is an ArchValueGroup instance.

readonly isBuilder :boolean

Returns whether or not this value is set to a builder value. While builders end up generating expression text that specifies how the value should be calculated, they cannot be changed in Architect Scripting. You can call different methods on an ArchBaseValue instance such as ArchBaseValue#setExpression to set this to an expression or value type specific literal setter such as ArchValueString#setLiteralString on a ArchValueString instance to set this to a literal.

Inherited From:

readonly isCollection :boolean

Returns false indicating that this value is not a collection value.

Inherited From:

readonly isExpression :boolean

Returns whether or not this value is set to a expression value.

Inherited From:

readonly isLiteral :boolean

Returns whether or not this value is set to a literal value.

Inherited From:

readonly isNoValue :boolean

Returns whether or not this value is set to no value. Note that this does not mean the value is NOT_SET. It means there is no value specified for this value.

Inherited From:

readonly isNoValueNoFallback :boolean

Returns whether or not this value is set to no value with no fallback. Note that this does not mean the value is NOT_SET. It means that there is no value specified for this value and the flow's runtime handling, such as picking up a default value for a setting somewhere else, should not be used.

Inherited From:

readonly isVariable :boolean

Returns whether or not this value is set to a variable value. Note that this is true when the value is set by calling ArchBaseValue#setVariable. If you set the value with an expression, the return value will be false even if the expression is only a variable reference.

Inherited From:

readonly isVariableInitialValue :boolean

Returns whether or not this value is the initial value for a variable.

Inherited From:

readonly logStr :string

Returns a logging string that describes this Architect value.

Inherited From:

readonly objectName :string

Returns the name of the object referenced on this value if this value is a literal. Remember that you should not expect to get an object's name back if you access this property while there is a pending set literal by identifier or name operation pending such as ArchValueQueue#setLiteralByQueueNameAsync. If this value is not a literal, nothing is returned.

Inherited From:

readonly overridesDefaultValue :boolean

Returns whether or not this value is overriding another default value. For example, this is true when this a value overrides a flow level setting value.

Inherited From:

readonly parent :ArchBaseObject

The parent Architect Scripting object associated with this value.

Inherited From:

readonly parentFlow :ArchBaseFlow

Returns the parent flow for this value.

Inherited From:

readonly settings :ArchValueSettings

Returns the settings associated with this value which provides meta data about this value like whether it is an output, can be set to a literal, can be set to an expression, etc. etc.

Inherited From:

readonly valueText :string

Returns a JavaScript string representing the value specified on this ArchBaseValueBasic instance. If this value is an expression, it returns the expression text. If this value is a variable, it returns the variable text. If this value is a literal, it will return the value of the [name property]ArchBaseNetworkValueSingleton#name. Overall this property is meant to be a quick and easy way to look at a "value" string but it is not meant to be some kind of fully inclusive description of this ArchBaseNetworkValueSingleton.

Inherited From:

Methods

getExpressionText() → {string}

If this value is an expression, this method will return the expression text.

Returns:
string
Inherited From:

getVariable() → {ArchBaseVariable}

If this value is a variable reference, this method will return the variable that is being referenced.

Returns:
ArchBaseVariable
Inherited From:

setExpression(expressionText)

This sets the expression text on this value. If the expression cannot be set because the expression text is invalid, you're trying to set an expression on an output, etc. etc. the call will fail. If you wish to have the ability to set syntactically invalid expression text on an ArchBaseValue object and not have this method throw, you can set the ArchValueSettings.allowInvalidExpressionText property to true prior to calling the setExpression function and Scripting will not throw an error if the expression text is invalid. Remember, output values are required to be variables so you should use setVariable on those calls instead of passing in expression text that references a variable.

Parameters:
Name Type Description
expressionText string

the expression to set on this value.

Throws:
  • This method will throw if it is unable to set the supplied expression text with an error describing why.
Inherited From:

setExpressionFromVariable(variableToAssign)

This method sets the value to an expression and assigns the variable's name as the expression text.

Parameters:
Name Type Description
variableToAssign string | ArchBaseVariable

the variable to assign passed in either by a string like 'Flow.myInteger' or an Architect variable. If the value is a string, this function will attempt to look up the variable and if it doesn't exist then create it. Next it will assign the variable name as the expression text. If you pass in an ArchBaseVariable reference, it needs to be in scope for this value.

Inherited From:

setExpressionNotSet()

This is a helper method that will set the expression NOT_SET on this value.

Inherited From:

setFromValue(sourceValue)

Sets this value to match the given source value, copying its mode and configuration exactly. This is useful when you want to duplicate the full state of one value onto another, including expression mode, literal values, variable references, builder configuration, and no-value states. The source and destination values must have the same data type.

Parameters:
Name Type Description
sourceValue ArchBaseValue

the source value to copy from.

Inherited From:

setLiteralByGroupIdAsync(groupId, callbackFunctionopt) → {Promise.<ArchValueGroup>}

Sets the value of this group to the group with the specified identifier.

Parameters:
Name Type Attributes Description
groupId string

the identifier of the group.

callbackFunction callbackArchValueGroup <optional>

a callback function to call if the group is successfully looked up and configured on this value. The first parameter passed to the callback function will be this group value instance.

Returns:
Promise.<ArchValueGroup>

setLiteralByGroupNameAsync(groupName, callbackFunctionopt) → {Promise.<ArchValueGroup>}

Sets the value of this group to the group with the specified name.

Parameters:
Name Type Attributes Description
groupName string

the name of the group.

callbackFunction callbackArchValueGroup <optional>

a callback function to call if the group is successfully looked up and configured on this value. The first parameter passed to the callback function will be this group value instance.

Returns:
Promise.<ArchValueGroup>

setNoValue()

This method sets the value to no value. Note that this is different from setting NOT_SET or something like a blank string. Setting a value to contain no value is something which is rather internal to Architect but we're exposing it in scripting. In a nutshell, setting no value means to take advantage of default runtime handling. The default runtime handling can change based on where this is used. For example, setting no value for a variable initial value means that the runtime will set a non-collection variable to NOT_SET or a collection variable to an empty collection. On a value that has a flow level default, setting it to no value means that the runtime should pick up the value to use from the flow level default. And if a flow level default allows no value, that means that the runtime will pick up the value from somewhere else normally defined in Admin. An example of this is that the connect timeout specified for a Transfer to Number action that it would use the Edge trunk connect timeout.

Inherited From:

setNoValueNoFallback()

This method sets the value to no value but with no fallback. This is different that setNoValue in that you are explicitly setting the expression to no value and you do not want to use the flows default value for this setting.

Inherited From:

setVariable(variableToAssign)

This method sets the value to a variable and assigns the supplied variable to it. One thing to be aware of is when a value reports that it is an input, the value may not allow you to call this method to configure a variable if the value's can be variable setting reports false. Assuming that the value reports it can be an expression, please look at using the ArchBaseValue#setExpressionFromVariable method instead.

Parameters:
Name Type Description
variableToAssign string | ArchBaseVariable

the variable to assign passed in either by a string like 'Flow.myInteger' or an Architect variable. If the value is a string, this function will attempt to look up the variable and if it doesn't exist then create it. Next it will assign the variable name as the expression text. If you pass in an ArchBaseVariable reference, it needs to be in scope for this value.

Inherited From: