Class VariablesAccessor
Inherited Members
Namespace: EyeAuras.Scripting.Scaffolding
Assembly: EyeAuras.Scripting.dll
Syntax
public class VariablesAccessor : IVariablesAccessor, IEnumerable<AuraVariable>, IEnumerable, ICanSetVariables
Constructors
Name | Description |
---|---|
VariablesAccessor(Func<IHasVariables>) |
Properties
Name | Description |
---|---|
Count | Gets the total number of variables managed by the accessor. |
this[string] | Gets or sets the variable associated with the specified key. |
Methods
Name | Description |
---|---|
AddOrUpdate<T>(string, T) | Adds a new variable or updates an existing variable with the specified value. |
AddOrUpdate<T>(string, T, Func<T, T>) | Adds a new variable or updates an existing variable with a value determined by the updater function. |
Contains(string) | Determines whether a variable with the specified name exists. |
GetEnumerator() | |
GetValue<T>(string) | Gets the value of a variable of a specified type. Throws an exception if the variable is not found. |
GetValue<T>(string, T) | Gets the value of a variable of a specified type, returning a default value if the variable is not found. |
Get<T>(string) | Gets a ScriptVariable<T> wrapper for a variable, facilitating advanced interactions. |
TryGetValue<T>(string, out T) | Tries to get the value of a variable of a specified type. |