< Dice‎ | FunctionContext
Revision as of 22:05, 25 April 2017 by Skizzerz (talk | contribs) (Created page with "{{APIdoc|FunctionContext.Arguments Property}} Gets the arguments to the function call. {{ns}} == Syntax == <syntaxhighlight lang="C#"> public IReadOnlyList<DiceAST> Argument...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

FunctionContext.Arguments Property

From DiceRoller Documentation

Gets the arguments to the function call.

  • Namespace: Dice
  • Assembly: DiceRoller (in DiceRoller.dll)

Syntax

public IReadOnlyList<DiceAST> Arguments { get; }

Property Value

Type: System.Collections.Generic.IReadOnlyList<Dice.AST.DiceAST>

The list of arguments that was passed to the function, may be an empty list (Arguments.Count == 0) but is never null.

Remarks

For the majority of functions, inspecting the Value, Values, and ValueType of each argument is generally sufficient to implement function logic, which does not require any casting.

All arguments are already evaluated at the time of the function call, so it is not necessary to evaluate them again. In other words, their Value, ValueType, and Values will be defined.