TextStudioTagParameterDefinition
public sealed class TextStudioTagParameterDefinitionParameter name, aliases, type, requirement, defaults, examples, and suggestion metadata for a tag.
Constructors
Section titled “Constructors”
TextStudioTagParameterDefinition(string, TextStudioTagParameterKind, bool, int, string, string, string, string[], string[], string, string, float?, float?, float, string, bool)
Section titled “TextStudioTagParameterDefinition(string, TextStudioTagParameterKind, bool, int, string, string, string, string[], string[], string, string, float?, float?, float, string, bool)”public TextStudioTagParameterDefinition(string name, TextStudioTagParameterKind kind = TextStudioTagParameterKind.String, bool required = false, int positionalIndex = -1, string displayName = null, string description = null, string suggestionKey = null, string[] allowedValues = null, string[] aliases = null, string defaultValue = null, string exampleValue = null, float? minimum = null, float? maximum = null, float snap = 0, string suffix = null, bool allowOverflow = false)Creates a parameter schema with normalized names, aliases, examples, and suggestions.
Parameters
| Name | Type |
|---|---|
name |
System.String |
kind |
TextStudio.TextStudioTagParameterKind |
required |
System.Boolean |
positionalIndex |
System.Int32 |
displayName |
System.String |
description |
System.String |
suggestionKey |
System.String |
allowedValues |
System.String[] |
aliases |
System.String[] |
defaultValue |
System.String |
exampleValue |
System.String |
minimum |
System.Nullable{System.Single} |
maximum |
System.Nullable{System.Single} |
snap |
System.Single |
suffix |
System.String |
allowOverflow |
System.Boolean |
Methods
Section titled “Methods”
MatchesName(string)
Section titled “MatchesName(string)”public bool MatchesName(string name)Matches the canonical parameter name or an alias using ordinal case-insensitive comparison.
Parameters
| Name | Type |
|---|---|
name |
System.String |
Returns
System.Boolean
Properties
Section titled “Properties”
public string Name { get; }Returns
System.String
DisplayName
Section titled “DisplayName”public string DisplayName { get; }Returns
System.String
Description
Section titled “Description”public string Description { get; }Returns
System.String
public TextStudioTagParameterKind Kind { get; }Returns
TextStudio.TextStudioTagParameterKind
Required
Section titled “Required”public bool Required { get; }Returns
System.Boolean
PositionalIndex
Section titled “PositionalIndex”public int PositionalIndex { get; }Returns
System.Int32
SuggestionKey
Section titled “SuggestionKey”public string SuggestionKey { get; }Returns
System.String
DefaultValue
Section titled “DefaultValue”public string DefaultValue { get; }Returns
System.String
ExampleValue
Section titled “ExampleValue”public string ExampleValue { get; }Returns
System.String
Minimum
Section titled “Minimum”public float? Minimum { get; }Returns
System.Nullable{System.Single}
Maximum
Section titled “Maximum”public float? Maximum { get; }Returns
System.Nullable{System.Single}
public float Snap { get; }Returns
System.Single
Suffix
Section titled “Suffix”public string Suffix { get; }Returns
System.String
AllowOverflow
Section titled “AllowOverflow”public bool AllowOverflow { get; }Returns
System.Boolean
AllowedValues
Section titled “AllowedValues”public IReadOnlyList<string> AllowedValues { get; }Returns
System.Collections.Generic.IReadOnlyList{System.String}
Aliases
Section titled “Aliases”public IReadOnlyList<string> Aliases { get; }Returns
System.Collections.Generic.IReadOnlyList{System.String}