Variables

Previous Next

This section lists Blend directives related to variables.

The standard directive for creating a variable is pc:assign-var. But if you require data type conversion, or if you want to prevent the variable value from being overwritten if it already exists, or both, then use an alternative:

 

 

+ prevent overwriting

 

pc:assign-var

pc:assign-var-default

+ data type conversion

pc:assign-nodeset

pc:assign-nodeset-default

pc:assign-string

pc:assign-string-default

pc:assign-number

pc:assign-number-default

pc:assign-boolean

pc:assign-boolean-default

 

assign:variable

Equivalent to pc:assign-var, but using an XML attribute instead of an XML element.

pc:define-boolean-flags

Adds items to the list of pairs of strings interpreted as boolean true() and boolean false() by "flag-based" string-to-boolean conversion.

pc:GetVariables

Returns the list of Blend variable declarations currently referenced.

pc:LoadVariablesDefault

Retrieves from a file a list of Blend variable declarations, NOT overwriting any existing variables with the same names.

pc:LoadVariablesOverwrite

Retrieves from a file a list of Blend variable declarations, overwriting any existing variables with the same names.

pc:SaveVariables

Save to a file the list of Blend variable declarations currently referenced.