< Dice | MacroContext
Difference between revisions of "Dice/MacroContext/Name"
From DiceRoller Documentation
(Created page with "{{APIdoc|MacroContext.Name Property}} Gets the name of the macro, if using the recommended method of separating arguments with colons. {{ns}} == Syntax == <syntaxhighlight l...") |
(No difference)
|
Latest revision as of 23:22, 14 August 2017
Gets the name of the macro, if using the recommended method of separating arguments with colons.
- Namespace: Dice
- Assembly: DiceRoller (in DiceRoller.dll)
Syntax
public string Name { get; private set; }
Property Value
Type: System.String
The name of the macro, in the casing that the user specified.
Remarks
All leading and trailing whitespace is trimmed from the name, so the macro [ a : b : c ] and the macro [a:b:c] have equivalent Names ("a"). If internal whitespace is important, you will need to parse the Param property yourself in order to preserve the spaces. The casing of Name is equivalent to what the user specified, so if you are doing a switch on Name, you may wish to force it all to lowercase.