Table of Contents

Class ApplicationCommandOptionChoiceProperties

Namespace
NetCord.Rest
Assembly
NetCord.dll
[JsonConverter(typeof(ApplicationCommandOptionChoiceProperties.ApplicationCommandOptionChoicePropertiesConverter))]
public class ApplicationCommandOptionChoiceProperties
Inheritance
ApplicationCommandOptionChoiceProperties
Inherited Members

Constructors

ApplicationCommandOptionChoiceProperties(string, double)

public ApplicationCommandOptionChoiceProperties(string name, double numericValue)

Parameters

name string
numericValue double

ApplicationCommandOptionChoiceProperties(string, string)

public ApplicationCommandOptionChoiceProperties(string name, string stringValue)

Parameters

name string
stringValue string

Properties

Name

Name of the choice (1-100 characters).

[JsonPropertyName("name")]
public string Name { get; set; }

Property Value

string

NameLocalizations

Localizations of Name (1-100 characters each).

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("name_localizations")]
public IReadOnlyDictionary<string, string>? NameLocalizations { get; set; }

Property Value

IReadOnlyDictionary<string, string>

NumericValue

Numeric value for the choice (max 100 characters).

public double? NumericValue { get; set; }

Property Value

double?

StringValue

String value for the choice (max 100 characters).

public string? StringValue { get; set; }

Property Value

string

ValueType

Type of value.

public ApplicationCommandOptionChoiceValueType ValueType { get; set; }

Property Value

ApplicationCommandOptionChoiceValueType

Methods

WithName(string)

Name of the choice (1-100 characters).

public ApplicationCommandOptionChoiceProperties WithName(string name)

Parameters

name string

Returns

ApplicationCommandOptionChoiceProperties

WithNameLocalizations(IReadOnlyDictionary<string, string>?)

Localizations of Name (1-100 characters each).

public ApplicationCommandOptionChoiceProperties WithNameLocalizations(IReadOnlyDictionary<string, string>? nameLocalizations)

Parameters

nameLocalizations IReadOnlyDictionary<string, string>

Returns

ApplicationCommandOptionChoiceProperties

WithNumericValue(double?)

Numeric value for the choice (max 100 characters).

public ApplicationCommandOptionChoiceProperties WithNumericValue(double? numericValue)

Parameters

numericValue double?

Returns

ApplicationCommandOptionChoiceProperties

WithStringValue(string?)

String value for the choice (max 100 characters).

public ApplicationCommandOptionChoiceProperties WithStringValue(string? stringValue)

Parameters

stringValue string

Returns

ApplicationCommandOptionChoiceProperties

WithValueType(ApplicationCommandOptionChoiceValueType)

Type of value.

public ApplicationCommandOptionChoiceProperties WithValueType(ApplicationCommandOptionChoiceValueType valueType)

Parameters

valueType ApplicationCommandOptionChoiceValueType

Returns

ApplicationCommandOptionChoiceProperties