Class SlashCommandInfo<TContext>
- Namespace
- NetCord.Services.ApplicationCommands
- Assembly
- NetCord.Services.dll
public class SlashCommandInfo<TContext> : ApplicationCommandInfo<TContext>, IApplicationCommandInfo, IAutocompleteInfo where TContext : IApplicationCommandContext
Type Parameters
TContext
- Inheritance
-
SlashCommandInfo<TContext>
- Implements
-
- Inherited Members
-
Properties
Description
public string Description { get; }
Property Value
- string
LocalizationPathSegment
public override LocalizationPathSegment LocalizationPathSegment { get; }
Property Value
- LocalizationPathSegment
Parameters
public IReadOnlyList<SlashCommandParameter<TContext>> Parameters { get; }
Property Value
- IReadOnlyList<SlashCommandParameter<TContext>>
ParametersDictionary
public IReadOnlyDictionary<string, SlashCommandParameter<TContext>> ParametersDictionary { get; }
Property Value
- IReadOnlyDictionary<string, SlashCommandParameter<TContext>>
Preconditions
public IReadOnlyList<PreconditionAttribute<TContext>> Preconditions { get; }
Property Value
- IReadOnlyList<PreconditionAttribute<TContext>>
Methods
GetRawValueAsync(CancellationToken)
public override ValueTask<ApplicationCommandProperties> GetRawValueAsync(CancellationToken cancellationToken = default)
Parameters
cancellationToken
CancellationToken
Returns
- ValueTask<ApplicationCommandProperties>
InvokeAsync(TContext, ApplicationCommandServiceConfiguration<TContext>, IServiceProvider?)
public override ValueTask<IExecutionResult> InvokeAsync(TContext context, ApplicationCommandServiceConfiguration<TContext> configuration, IServiceProvider? serviceProvider)
Parameters
context
TContext
configuration
ApplicationCommandServiceConfiguration<TContext>
serviceProvider
IServiceProvider
Returns
- ValueTask<IExecutionResult>
InvokeAutocompleteAsync<TAutocompleteContext>(TAutocompleteContext, IReadOnlyList<ApplicationCommandInteractionDataOption>, IServiceProvider?)
public ValueTask<IExecutionResult> InvokeAutocompleteAsync<TAutocompleteContext>(TAutocompleteContext context, IReadOnlyList<ApplicationCommandInteractionDataOption> options, IServiceProvider? serviceProvider) where TAutocompleteContext : IAutocompleteInteractionContext
Parameters
context
TAutocompleteContext
options
IReadOnlyList<ApplicationCommandInteractionDataOption>
serviceProvider
IServiceProvider
Returns
- ValueTask<IExecutionResult>
Type Parameters
TAutocompleteContext