Table of Contents

Class ExtensionMethods

Namespace
DisCatSharp.ApplicationCommands
Assembly
DisCatSharp.ApplicationCommands.dll

Defines various extension methods for application commands.

public static class ExtensionMethods
Inheritance
ExtensionMethods
Inherited Members

Methods

GetApplicationCommands(DiscordClient)

Gets the application commands module for this client.

GetApplicationCommandsAsync(DiscordShardedClient)

Gets the application commands from this DiscordShardedClient.

GetName<T>(T)

Gets the name from the ChoiceNameAttribute for this enum value.

RegisterGlobalCommands(IReadOnlyDictionary<int, ApplicationCommandsExtension>, Type, Action<ApplicationCommandsTranslationContext>?)

Registers a command class with optional translation setup globally.

RegisterGlobalCommands<T>(IReadOnlyDictionary<int, ApplicationCommandsExtension>, Action<ApplicationCommandsTranslationContext>?)

Registers a command class with optional translation setup globally.

RegisterGuildCommands(IReadOnlyDictionary<int, ApplicationCommandsExtension>, Type, ulong, Action<ApplicationCommandsTranslationContext>)

Registers a command class with optional translation setup for a guild.

RegisterGuildCommands<T>(IReadOnlyDictionary<int, ApplicationCommandsExtension>, ulong, Action<ApplicationCommandsTranslationContext>?)

Registers a command class with optional translation setup for a guild.

UseApplicationCommands(DiscordClient, ApplicationCommandsConfiguration?)

Enables application commands on this DiscordClient.

UseApplicationCommandsAsync(DiscordShardedClient, ApplicationCommandsConfiguration?)

Enables application commands on this DiscordShardedClient.