Constructor DiscordApplicationCommandOptionChoice
- Namespace
- DSharpPlus.Entities
- Assembly
- DSharpPlus.dll
DiscordApplicationCommandOptionChoice(string, string, IReadOnlyDictionary<string, string>?)
Creates a new instance of a DiscordApplicationCommandOptionChoice.
public DiscordApplicationCommandOptionChoice(string name, string value, IReadOnlyDictionary<string, string>? nameLocalizations = null)
Parameters
name
stringThe name of this choice.
value
stringThe value of this choice.
nameLocalizations
IReadOnlyDictionary<string, string>Localized names for this choice. The keys must be appropriate locales as documented by Discord: https://discord.com/developers/docs/reference#locales.
DiscordApplicationCommandOptionChoice(string, int, IReadOnlyDictionary<string, string>?)
Creates a new instance of a DiscordApplicationCommandOptionChoice.
public DiscordApplicationCommandOptionChoice(string name, int value, IReadOnlyDictionary<string, string>? nameLocalizations = null)
Parameters
name
stringThe name of this choice.
value
intThe value of this choice.
nameLocalizations
IReadOnlyDictionary<string, string>Localized names for this choice. The keys must be appropriate locales as documented by Discord: https://discord.com/developers/docs/reference#locales.
DiscordApplicationCommandOptionChoice(string, long, IReadOnlyDictionary<string, string>?)
Creates a new instance of a DiscordApplicationCommandOptionChoice.
public DiscordApplicationCommandOptionChoice(string name, long value, IReadOnlyDictionary<string, string>? nameLocalizations = null)
Parameters
name
stringThe name of this choice.
value
longThe value of this choice.
nameLocalizations
IReadOnlyDictionary<string, string>Localized names for this choice. The keys must be appropriate locales as documented by Discord: https://discord.com/developers/docs/reference#locales.
DiscordApplicationCommandOptionChoice(string, double, IReadOnlyDictionary<string, string>?)
Creates a new instance of a DiscordApplicationCommandOptionChoice.
public DiscordApplicationCommandOptionChoice(string name, double value, IReadOnlyDictionary<string, string>? nameLocalizations = null)
Parameters
name
stringThe name of this choice.
value
doubleThe value of this choice.
nameLocalizations
IReadOnlyDictionary<string, string>Localized names for this choice. The keys must be appropriate locales as documented by Discord: https://discord.com/developers/docs/reference#locales.
DiscordApplicationCommandOptionChoice(string, float, IReadOnlyDictionary<string, string>?)
Creates a new instance of a DiscordApplicationCommandOptionChoice.
public DiscordApplicationCommandOptionChoice(string name, float value, IReadOnlyDictionary<string, string>? nameLocalizations = null)
Parameters
name
stringThe name of this choice.
value
floatThe value of this choice.
nameLocalizations
IReadOnlyDictionary<string, string>Localized names for this choice. The keys must be appropriate locales as documented by Discord: https://discord.com/developers/docs/reference#locales.