|
- <?xml version="1.0"?>
- <doc>
- <assembly>
- <name>Discord.Net.Commands</name>
- </assembly>
- <members>
- <member name="T:Discord.Commands.AliasAttribute">
- <summary>
- Marks the aliases for a command.
- </summary>
- <remarks>
- This attribute allows a command to have one or multiple aliases. In other words, the base command can have
- multiple aliases when triggering the command itself, giving the end-user more freedom of choices when giving
- hot-words to trigger the desired command. See the example for a better illustration.
- </remarks>
- <example>
- In the following example, the command can be triggered with the base name, "stats", or either "stat" or
- "info".
- <code language="cs">
- [Command("stats")]
- [Alias("stat", "info")]
- public async Task GetStatsAsync(IUser user)
- {
- // ...pull stats
- }
- </code>
- </example>
- </member>
- <member name="P:Discord.Commands.AliasAttribute.Aliases">
- <summary>
- Gets the aliases which have been defined for the command.
- </summary>
- </member>
- <member name="M:Discord.Commands.AliasAttribute.#ctor(System.String[])">
- <summary>
- Creates a new <see cref="T:Discord.Commands.AliasAttribute" /> with the given aliases.
- </summary>
- </member>
- <member name="T:Discord.Commands.CommandAttribute">
- <summary>
- Marks the execution information for a command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandAttribute.Text">
- <summary>
- Gets the text that has been set to be recognized as a command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandAttribute.RunMode">
- <summary>
- Specifies the <see cref="P:Discord.Commands.CommandAttribute.RunMode" /> of the command. This affects how the command is executed.
- </summary>
- </member>
- <member name="M:Discord.Commands.CommandAttribute.#ctor">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.CommandAttribute.#ctor(System.String)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.CommandAttribute" /> attribute with the specified name.
- </summary>
- <param name="text">The name of the command.</param>
- </member>
- <member name="T:Discord.Commands.DontAutoLoadAttribute">
- <summary>
- Prevents the marked module from being loaded automatically.
- </summary>
- <remarks>
- This attribute tells <see cref="T:Discord.Commands.CommandService" /> to ignore the marked module from being loaded
- automatically (e.g. the <see cref="M:Discord.Commands.CommandService.AddModulesAsync(System.Reflection.Assembly,System.IServiceProvider)" /> method). If a non-public module marked
- with this attribute is attempted to be loaded manually, the loading process will also fail.
- </remarks>
- </member>
- <member name="T:Discord.Commands.DontInjectAttribute">
- <summary>
- Prevents the marked property from being injected into a module.
- </summary>
- <remarks>
- This attribute prevents the marked member from being injected into its parent module. Useful when you have a
- public property that you do not wish to invoke the library's dependency injection service.
- </remarks>
- <example>
- In the following example, <c>DatabaseService</c> will not be automatically injected into the module and will
- not throw an error message if the dependency fails to be resolved.
- <code language="cs">
- public class MyModule : ModuleBase
- {
- [DontInject]
- public DatabaseService DatabaseService;
- public MyModule()
- {
- DatabaseService = DatabaseFactory.Generate();
- }
- }
- </code>
- </example>
- </member>
- <member name="T:Discord.Commands.GroupAttribute">
- <summary>
- Marks the module as a command group.
- </summary>
- </member>
- <member name="P:Discord.Commands.GroupAttribute.Prefix">
- <summary>
- Gets the prefix set for the module.
- </summary>
- </member>
- <member name="M:Discord.Commands.GroupAttribute.#ctor">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.GroupAttribute.#ctor(System.String)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.GroupAttribute" /> with the provided prefix.
- </summary>
- <param name="prefix">The prefix of the module group.</param>
- </member>
- <member name="T:Discord.Commands.NameAttribute">
- <summary>
- Marks the public name of a command, module, or parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.NameAttribute.Text">
- <summary>
- Gets the name of the command.
- </summary>
- </member>
- <member name="M:Discord.Commands.NameAttribute.#ctor(System.String)">
- <summary>
- Marks the public name of a command, module, or parameter with the provided name.
- </summary>
- <param name="text">The public name of the object.</param>
- </member>
- <member name="T:Discord.Commands.NamedArgumentTypeAttribute">
- <summary>
- Instructs the command system to treat command parameters of this type
- as a collection of named arguments matching to its properties.
- </summary>
- </member>
- <member name="T:Discord.Commands.OverrideTypeReaderAttribute">
- <summary>
- Marks the <see cref="T:System.Type"/> to be read by the specified <see cref="T:Discord.Commands.TypeReader"/>.
- </summary>
- <remarks>
- This attribute will override the <see cref="T:Discord.Commands.TypeReader"/> to be used when parsing for the
- desired type in the command. This is useful when one wishes to use a particular
- <see cref="T:Discord.Commands.TypeReader"/> without affecting other commands that are using the same target
- type.
- <note type="warning">
- If the given type reader does not inherit from <see cref="T:Discord.Commands.TypeReader"/>, an
- <see cref="T:System.ArgumentException"/> will be thrown.
- </note>
- </remarks>
- <example>
- In this example, the <see cref="T:System.TimeSpan"/> will be read by a custom
- <see cref="T:Discord.Commands.TypeReader"/>, <c>FriendlyTimeSpanTypeReader</c>, instead of the
- <see cref="T:Discord.Commands.TimeSpanTypeReader"/> shipped by Discord.Net.
- <code language="cs">
- [Command("time")]
- public Task GetTimeAsync([OverrideTypeReader(typeof(FriendlyTimeSpanTypeReader))]TimeSpan time)
- => ReplyAsync(time);
- </code>
- </example>
- </member>
- <member name="P:Discord.Commands.OverrideTypeReaderAttribute.TypeReader">
- <summary>
- Gets the specified <see cref="P:Discord.Commands.OverrideTypeReaderAttribute.TypeReader"/> of the parameter.
- </summary>
- </member>
- <member name="M:Discord.Commands.OverrideTypeReaderAttribute.#ctor(System.Type)">
- <inheritdoc/>
- <param name="overridenTypeReader">The <see cref="P:Discord.Commands.OverrideTypeReaderAttribute.TypeReader"/> to be used with the parameter. </param>
- <exception cref="T:System.ArgumentException">The given <paramref name="overridenTypeReader"/> does not inherit from <see cref="P:Discord.Commands.OverrideTypeReaderAttribute.TypeReader"/>.</exception>
- </member>
- <member name="T:Discord.Commands.ParameterPreconditionAttribute">
- <summary>
- Requires the parameter to pass the specified precondition before execution can begin.
- </summary>
- <seealso cref="T:Discord.Commands.PreconditionAttribute"/>
- </member>
- <member name="M:Discord.Commands.ParameterPreconditionAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.ParameterInfo,System.Object,System.IServiceProvider)">
- <summary>
- Checks whether the condition is met before execution of the command.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="parameter">The parameter of the command being checked against.</param>
- <param name="value">The raw value of the parameter.</param>
- <param name="services">The service collection used for dependency injection.</param>
- </member>
- <member name="T:Discord.Commands.PreconditionAttribute">
- <summary>
- Requires the module or class to pass the specified precondition before execution can begin.
- </summary>
- <seealso cref="T:Discord.Commands.ParameterPreconditionAttribute"/>
- </member>
- <member name="P:Discord.Commands.PreconditionAttribute.Group">
- <summary>
- Specifies a group that this precondition belongs to.
- </summary>
- <remarks>
- <see cref="T:Discord.Preconditions" /> of the same group require only one of the preconditions to pass in order to
- be successful (A || B). Specifying <see cref="P:Discord.Commands.PreconditionAttribute.Group" /> = <c>null</c> or not at all will
- require *all* preconditions to pass, just like normal (A && B).
- </remarks>
- </member>
- <member name="P:Discord.Commands.PreconditionAttribute.ErrorMessage">
- <summary>
- When overridden in a derived class, uses the supplied string
- as the error message if the precondition doesn't pass.
- Setting this for a class that doesn't override
- this property is a no-op.
- </summary>
- </member>
- <member name="M:Discord.Commands.PreconditionAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.CommandInfo,System.IServiceProvider)">
- <summary>
- Checks if the <paramref name="command"/> has the sufficient permission to be executed.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="command">The command being executed.</param>
- <param name="services">The service collection used for dependency injection.</param>
- </member>
- <member name="T:Discord.Commands.RequireBotPermissionAttribute">
- <summary>
- Requires the bot to have a specific permission in the channel a command is invoked in.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireBotPermissionAttribute.GuildPermission">
- <summary>
- Gets the specified <see cref="T:Discord.GuildPermission" /> of the precondition.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireBotPermissionAttribute.ChannelPermission">
- <summary>
- Gets the specified <see cref="T:Discord.ChannelPermission" /> of the precondition.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireBotPermissionAttribute.ErrorMessage">
- <inheritdoc />
- </member>
- <member name="P:Discord.Commands.RequireBotPermissionAttribute.NotAGuildErrorMessage">
- <summary>
- Gets or sets the error message if the precondition
- fails due to being run outside of a Guild channel.
- </summary>
- </member>
- <member name="M:Discord.Commands.RequireBotPermissionAttribute.#ctor(Discord.GuildPermission)">
- <summary>
- Requires the bot account to have a specific <see cref="T:Discord.GuildPermission"/>.
- </summary>
- <remarks>
- This precondition will always fail if the command is being invoked in a <see cref="T:Discord.IPrivateChannel"/>.
- </remarks>
- <param name="permission">
- The <see cref="T:Discord.GuildPermission"/> that the bot must have. Multiple permissions can be specified
- by ORing the permissions together.
- </param>
- </member>
- <member name="M:Discord.Commands.RequireBotPermissionAttribute.#ctor(Discord.ChannelPermission)">
- <summary>
- Requires that the bot account to have a specific <see cref="T:Discord.ChannelPermission"/>.
- </summary>
- <param name="permission">
- The <see cref="T:Discord.ChannelPermission"/> that the bot must have. Multiple permissions can be
- specified by ORing the permissions together.
- </param>
- </member>
- <member name="M:Discord.Commands.RequireBotPermissionAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.CommandInfo,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.ContextType">
- <summary>
- Defines the type of command context (i.e. where the command is being executed).
- </summary>
- </member>
- <member name="F:Discord.Commands.ContextType.Guild">
- <summary>
- Specifies the command to be executed within a guild.
- </summary>
- </member>
- <member name="F:Discord.Commands.ContextType.DM">
- <summary>
- Specifies the command to be executed within a DM.
- </summary>
- </member>
- <member name="F:Discord.Commands.ContextType.Group">
- <summary>
- Specifies the command to be executed within a group.
- </summary>
- </member>
- <member name="T:Discord.Commands.RequireContextAttribute">
- <summary>
- Requires the command to be invoked in a specified context (e.g. in guild, DM).
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireContextAttribute.Contexts">
- <summary>
- Gets the context required to execute the command.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireContextAttribute.ErrorMessage">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.RequireContextAttribute.#ctor(Discord.Commands.ContextType)">
- <summary> Requires the command to be invoked in the specified context. </summary>
- <param name="contexts">The type of context the command can be invoked in. Multiple contexts can be specified by ORing the contexts together.</param>
- <example>
- <code language="cs">
- [Command("secret")]
- [RequireContext(ContextType.DM | ContextType.Group)]
- public Task PrivateOnlyAsync()
- {
- return ReplyAsync("shh, this command is a secret");
- }
- </code>
- </example>
- </member>
- <member name="M:Discord.Commands.RequireContextAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.CommandInfo,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.RequireNsfwAttribute">
- <summary>
- Requires the command to be invoked in a channel marked NSFW.
- </summary>
- <remarks>
- The precondition will restrict the access of the command or module to be accessed within a guild channel
- that has been marked as mature or NSFW. If the channel is not of type <see cref="T:Discord.ITextChannel"/> or the
- channel is not marked as NSFW, the precondition will fail with an erroneous <see cref="T:Discord.Commands.PreconditionResult"/>.
- </remarks>
- <example>
- The following example restricts the command <c>too-cool</c> to an NSFW-enabled channel only.
- <code language="cs">
- public class DankModule : ModuleBase
- {
- [Command("cool")]
- public Task CoolAsync()
- => ReplyAsync("I'm cool for everyone.");
-
- [RequireNsfw]
- [Command("too-cool")]
- public Task TooCoolAsync()
- => ReplyAsync("You can only see this if you're cool enough.");
- }
- </code>
- </example>
- </member>
- <member name="P:Discord.Commands.RequireNsfwAttribute.ErrorMessage">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.RequireNsfwAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.CommandInfo,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.RequireOwnerAttribute">
- <summary>
- Requires the command to be invoked by the owner of the bot.
- </summary>
- <remarks>
- This precondition will restrict the access of the command or module to the owner of the Discord application.
- If the precondition fails to be met, an erroneous <see cref="T:Discord.Commands.PreconditionResult"/> will be returned with the
- message "Command can only be run by the owner of the bot."
- <note>
- This precondition will only work if the account has a <see cref="T:Discord.TokenType"/> of <see cref="F:Discord.TokenType.Bot"/>
- ;otherwise, this precondition will always fail.
- </note>
- </remarks>
- <example>
- The following example restricts the command to a set of sensitive commands that only the owner of the bot
- application should be able to access.
- <code language="cs">
- [RequireOwner]
- [Group("admin")]
- public class AdminModule : ModuleBase
- {
- [Command("exit")]
- public async Task ExitAsync()
- {
- Environment.Exit(0);
- }
- }
- </code>
- </example>
- </member>
- <member name="P:Discord.Commands.RequireOwnerAttribute.ErrorMessage">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.RequireOwnerAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.CommandInfo,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.RequireUserPermissionAttribute">
- <summary>
- Requires the user invoking the command to have a specified permission.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireUserPermissionAttribute.GuildPermission">
- <summary>
- Gets the specified <see cref="T:Discord.GuildPermission" /> of the precondition.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireUserPermissionAttribute.ChannelPermission">
- <summary>
- Gets the specified <see cref="T:Discord.ChannelPermission" /> of the precondition.
- </summary>
- </member>
- <member name="P:Discord.Commands.RequireUserPermissionAttribute.ErrorMessage">
- <inheritdoc />
- </member>
- <member name="P:Discord.Commands.RequireUserPermissionAttribute.NotAGuildErrorMessage">
- <summary>
- Gets or sets the error message if the precondition
- fails due to being run outside of a Guild channel.
- </summary>
- </member>
- <member name="M:Discord.Commands.RequireUserPermissionAttribute.#ctor(Discord.GuildPermission)">
- <summary>
- Requires that the user invoking the command to have a specific <see cref="T:Discord.GuildPermission"/>.
- </summary>
- <remarks>
- This precondition will always fail if the command is being invoked in a <see cref="T:Discord.IPrivateChannel"/>.
- </remarks>
- <param name="permission">
- The <see cref="T:Discord.GuildPermission" /> that the user must have. Multiple permissions can be
- specified by ORing the permissions together.
- </param>
- </member>
- <member name="M:Discord.Commands.RequireUserPermissionAttribute.#ctor(Discord.ChannelPermission)">
- <summary>
- Requires that the user invoking the command to have a specific <see cref="T:Discord.ChannelPermission"/>.
- </summary>
- <param name="permission">
- The <see cref="T:Discord.ChannelPermission"/> that the user must have. Multiple permissions can be
- specified by ORing the permissions together.
- </param>
- </member>
- <member name="M:Discord.Commands.RequireUserPermissionAttribute.CheckPermissionsAsync(Discord.Commands.ICommandContext,Discord.Commands.CommandInfo,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.PriorityAttribute">
- <summary>
- Sets priority of commands.
- </summary>
- </member>
- <member name="P:Discord.Commands.PriorityAttribute.Priority">
- <summary>
- Gets the priority which has been set for the command.
- </summary>
- </member>
- <member name="M:Discord.Commands.PriorityAttribute.#ctor(System.Int32)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.PriorityAttribute" /> attribute with the given priority.
- </summary>
- </member>
- <member name="T:Discord.Commands.RemainderAttribute">
- <summary>
- Marks the input to not be parsed by the parser.
- </summary>
- </member>
- <member name="T:Discord.Commands.RemarksAttribute">
- <summary>
- Attaches remarks to your commands.
- </summary>
- </member>
- <member name="T:Discord.Commands.SummaryAttribute">
- <summary>
- Attaches a summary to your command.
- </summary>
- </member>
- <member name="M:Discord.Commands.Builders.CommandBuilder.Build(Discord.Commands.ModuleInfo,Discord.Commands.CommandService)">
- <exception cref="T:System.InvalidOperationException">Only the last parameter in a command may have the Remainder or Multiple flag.</exception>
- </member>
- <member name="T:Discord.Commands.CommandContext">
- <summary> The context of a command which may contain the client, user, guild, channel, and message. </summary>
- </member>
- <member name="P:Discord.Commands.CommandContext.Client">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.CommandContext.Guild">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.CommandContext.Channel">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.CommandContext.User">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.CommandContext.Message">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.CommandContext.IsPrivate">
- <summary> Indicates whether the channel that the command is executed in is a private channel. </summary>
- </member>
- <member name="M:Discord.Commands.CommandContext.#ctor(Discord.IDiscordClient,Discord.IUserMessage)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.CommandContext" /> class with the provided client and message.
- </summary>
- <param name="client">The underlying client.</param>
- <param name="msg">The underlying message.</param>
- </member>
- <member name="T:Discord.Commands.CommandError">
- <summary> Defines the type of error a command can throw. </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.UnknownCommand">
- <summary>
- Thrown when the command is unknown.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.ParseFailed">
- <summary>
- Thrown when the command fails to be parsed.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.BadArgCount">
- <summary>
- Thrown when the input text has too few or too many arguments.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.ObjectNotFound">
- <summary>
- Thrown when the object cannot be found by the <see cref="T:Discord.Commands.TypeReader"/>.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.MultipleMatches">
- <summary>
- Thrown when more than one object is matched by <see cref="T:Discord.Commands.TypeReader"/>.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.UnmetPrecondition">
- <summary>
- Thrown when the command fails to meet a <see cref="T:Discord.Commands.PreconditionAttribute"/>'s conditions.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.Exception">
- <summary>
- Thrown when an exception occurs mid-command execution.
- </summary>
- </member>
- <member name="F:Discord.Commands.CommandError.Unsuccessful">
- <summary>
- Thrown when the command is not successfully executed on runtime.
- </summary>
- </member>
- <member name="T:Discord.Commands.CommandException">
- <summary>
- The exception that is thrown if another exception occurs during a command execution.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandException.Command">
- <summary> Gets the command that caused the exception. </summary>
- </member>
- <member name="P:Discord.Commands.CommandException.Context">
- <summary> Gets the command context of the exception. </summary>
- </member>
- <member name="M:Discord.Commands.CommandException.#ctor(Discord.Commands.CommandInfo,Discord.Commands.ICommandContext,System.Exception)">
- <summary>
- Initializes a new instance of the <see cref="T:Discord.Commands.CommandException" /> class using a
- <paramref name="command"/> information, a <paramref name="command"/> context, and the exception that
- interrupted the execution.
- </summary>
- <param name="command">The command information.</param>
- <param name="context">The context of the command.</param>
- <param name="ex">The exception that interrupted the command execution.</param>
- </member>
- <member name="P:Discord.Commands.CommandMatch.Command">
- <summary> The command that matches the search result. </summary>
- </member>
- <member name="P:Discord.Commands.CommandMatch.Alias">
- <summary> The alias of the command. </summary>
- </member>
- <member name="T:Discord.Commands.CommandService">
- <summary>
- Provides a framework for building Discord commands.
- </summary>
- <remarks>
- <para>
- The service provides a framework for building Discord commands both dynamically via runtime builders or
- statically via compile-time modules. To create a command module at compile-time, see
- <see cref="T:Discord.Commands.ModuleBase" /> (most common); otherwise, see <see cref="T:Discord.Commands.Builders.ModuleBuilder" />.
- </para>
- <para>
- This service also provides several events for monitoring command usages; such as
- <see cref="E:Discord.Commands.CommandService.Log" /> for any command-related log events, and
- <see cref="E:Discord.Commands.CommandService.CommandExecuted" /> for information about commands that have
- been successfully executed.
- </para>
- </remarks>
- </member>
- <member name="E:Discord.Commands.CommandService.Log">
- <summary>
- Occurs when a command-related information is received.
- </summary>
- </member>
- <member name="E:Discord.Commands.CommandService.CommandExecuted">
- <summary>
- Occurs when a command is executed.
- </summary>
- <remarks>
- This event is fired when a command has been executed, successfully or not. When a command fails to
- execute during parsing or precondition stage, the CommandInfo may not be returned.
- </remarks>
- </member>
- <member name="P:Discord.Commands.CommandService.Modules">
- <summary>
- Represents all modules loaded within <see cref="T:Discord.Commands.CommandService"/>.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandService.Commands">
- <summary>
- Represents all commands loaded within <see cref="T:Discord.Commands.CommandService"/>.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandService.TypeReaders">
- <summary>
- Represents all <see cref="T:Discord.Commands.TypeReader" /> loaded within <see cref="T:Discord.Commands.CommandService"/>.
- </summary>
- </member>
- <member name="M:Discord.Commands.CommandService.#ctor">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.CommandService"/> class.
- </summary>
- </member>
- <member name="M:Discord.Commands.CommandService.#ctor(Discord.Commands.CommandServiceConfig)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.CommandService"/> class with the provided configuration.
- </summary>
- <param name="config">The configuration class.</param>
- <exception cref="T:System.InvalidOperationException">
- The <see cref="T:Discord.Commands.RunMode"/> cannot be set to <see cref="F:Discord.Commands.RunMode.Default"/>.
- </exception>
- </member>
- <member name="M:Discord.Commands.CommandService.AddModuleAsync``1(System.IServiceProvider)">
- <summary>
- Add a command module from a <see cref="T:System.Type" />.
- </summary>
- <example>
- <para>The following example registers the module <c>MyModule</c> to <c>commandService</c>.</para>
- <code language="cs">
- await commandService.AddModuleAsync<MyModule>(serviceProvider);
- </code>
- </example>
- <typeparam name="T">The type of module.</typeparam>
- <param name="services">The <see cref="T:System.IServiceProvider"/> for your dependency injection solution if using one; otherwise, pass <c>null</c>.</param>
- <exception cref="T:System.ArgumentException">This module has already been added.</exception>
- <exception cref="T:System.InvalidOperationException">
- The <see cref="T:Discord.Commands.ModuleInfo"/> fails to be built; an invalid type may have been provided.
- </exception>
- <returns>
- A task that represents the asynchronous operation for adding the module. The task result contains the
- built module.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.AddModuleAsync(System.Type,System.IServiceProvider)">
- <summary>
- Adds a command module from a <see cref="T:System.Type" />.
- </summary>
- <param name="type">The type of module.</param>
- <param name="services">The <see cref="T:System.IServiceProvider" /> for your dependency injection solution if using one; otherwise, pass <c>null</c> .</param>
- <exception cref="T:System.ArgumentException">This module has already been added.</exception>
- <exception cref="T:System.InvalidOperationException">
- The <see cref="T:Discord.Commands.ModuleInfo"/> fails to be built; an invalid type may have been provided.
- </exception>
- <returns>
- A task that represents the asynchronous operation for adding the module. The task result contains the
- built module.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.AddModulesAsync(System.Reflection.Assembly,System.IServiceProvider)">
- <summary>
- Add command modules from an <see cref="T:System.Reflection.Assembly"/>.
- </summary>
- <param name="assembly">The <see cref="T:System.Reflection.Assembly"/> containing command modules.</param>
- <param name="services">The <see cref="T:System.IServiceProvider"/> for your dependency injection solution if using one; otherwise, pass <c>null</c>.</param>
- <returns>
- A task that represents the asynchronous operation for adding the command modules. The task result
- contains an enumerable collection of modules added.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.RemoveModuleAsync(Discord.Commands.ModuleInfo)">
- <summary>
- Removes the command module.
- </summary>
- <param name="module">The <see cref="T:Discord.Commands.ModuleInfo" /> to be removed from the service.</param>
- <returns>
- A task that represents the asynchronous removal operation. The task result contains a value that
- indicates whether the <paramref name="module"/> is successfully removed.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.RemoveModuleAsync``1">
- <summary>
- Removes the command module.
- </summary>
- <typeparam name="T">The <see cref="T:System.Type"/> of the module.</typeparam>
- <returns>
- A task that represents the asynchronous removal operation. The task result contains a value that
- indicates whether the module is successfully removed.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.RemoveModuleAsync(System.Type)">
- <summary>
- Removes the command module.
- </summary>
- <param name="type">The <see cref="T:System.Type"/> of the module.</param>
- <returns>
- A task that represents the asynchronous removal operation. The task result contains a value that
- indicates whether the module is successfully removed.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.AddTypeReader``1(Discord.Commands.TypeReader)">
- <summary>
- Adds a custom <see cref="T:Discord.Commands.TypeReader" /> to this <see cref="T:Discord.Commands.CommandService" /> for the supplied object
- type.
- If <typeparamref name="T" /> is a <see cref="T:System.ValueType" />, a nullable <see cref="T:Discord.Commands.TypeReader" /> will
- also be added.
- If a default <see cref="T:Discord.Commands.TypeReader" /> exists for <typeparamref name="T" />, a warning will be logged
- and the default <see cref="T:Discord.Commands.TypeReader" /> will be replaced.
- </summary>
- <typeparam name="T">The object type to be read by the <see cref="T:Discord.Commands.TypeReader"/>.</typeparam>
- <param name="reader">An instance of the <see cref="T:Discord.Commands.TypeReader" /> to be added.</param>
- </member>
- <member name="M:Discord.Commands.CommandService.AddTypeReader(System.Type,Discord.Commands.TypeReader)">
- <summary>
- Adds a custom <see cref="T:Discord.Commands.TypeReader" /> to this <see cref="T:Discord.Commands.CommandService" /> for the supplied object
- type.
- If <paramref name="type" /> is a <see cref="T:System.ValueType" />, a nullable <see cref="T:Discord.Commands.TypeReader" /> for the
- value type will also be added.
- If a default <see cref="T:Discord.Commands.TypeReader" /> exists for <paramref name="type" />, a warning will be logged and
- the default <see cref="T:Discord.Commands.TypeReader" /> will be replaced.
- </summary>
- <param name="type">A <see cref="T:System.Type" /> instance for the type to be read.</param>
- <param name="reader">An instance of the <see cref="T:Discord.Commands.TypeReader" /> to be added.</param>
- </member>
- <member name="M:Discord.Commands.CommandService.AddTypeReader``1(Discord.Commands.TypeReader,System.Boolean)">
- <summary>
- Adds a custom <see cref="T:Discord.Commands.TypeReader" /> to this <see cref="T:Discord.Commands.CommandService" /> for the supplied object
- type.
- If <typeparamref name="T" /> is a <see cref="T:System.ValueType" />, a nullable <see cref="T:Discord.Commands.TypeReader" /> will
- also be added.
- </summary>
- <typeparam name="T">The object type to be read by the <see cref="T:Discord.Commands.TypeReader"/>.</typeparam>
- <param name="reader">An instance of the <see cref="T:Discord.Commands.TypeReader" /> to be added.</param>
- <param name="replaceDefault">
- Defines whether the <see cref="T:Discord.Commands.TypeReader"/> should replace the default one for
- <see cref="T:System.Type" /> if it exists.
- </param>
- </member>
- <member name="M:Discord.Commands.CommandService.AddTypeReader(System.Type,Discord.Commands.TypeReader,System.Boolean)">
- <summary>
- Adds a custom <see cref="T:Discord.Commands.TypeReader" /> to this <see cref="T:Discord.Commands.CommandService" /> for the supplied object
- type.
- If <paramref name="type" /> is a <see cref="T:System.ValueType" />, a nullable <see cref="T:Discord.Commands.TypeReader" /> for the
- value type will also be added.
- </summary>
- <param name="type">A <see cref="T:System.Type" /> instance for the type to be read.</param>
- <param name="reader">An instance of the <see cref="T:Discord.Commands.TypeReader" /> to be added.</param>
- <param name="replaceDefault">
- Defines whether the <see cref="T:Discord.Commands.TypeReader"/> should replace the default one for <see cref="T:System.Type" /> if
- it exists.
- </param>
- </member>
- <member name="M:Discord.Commands.CommandService.Search(Discord.Commands.ICommandContext,System.Int32)">
- <summary>
- Searches for the command.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="argPos">The position of which the command starts at.</param>
- <returns>The result containing the matching commands.</returns>
- </member>
- <member name="M:Discord.Commands.CommandService.Search(Discord.Commands.ICommandContext,System.String)">
- <summary>
- Searches for the command.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="input">The command string.</param>
- <returns>The result containing the matching commands.</returns>
- </member>
- <member name="M:Discord.Commands.CommandService.ExecuteAsync(Discord.Commands.ICommandContext,System.Int32,System.IServiceProvider,Discord.Commands.MultiMatchHandling)">
- <summary>
- Executes the command.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="argPos">The position of which the command starts at.</param>
- <param name="services">The service to be used in the command's dependency injection.</param>
- <param name="multiMatchHandling">The handling mode when multiple command matches are found.</param>
- <returns>
- A task that represents the asynchronous execution operation. The task result contains the result of the
- command execution.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandService.ExecuteAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider,Discord.Commands.MultiMatchHandling)">
- <summary>
- Executes the command.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="input">The command string.</param>
- <param name="services">The service to be used in the command's dependency injection.</param>
- <param name="multiMatchHandling">The handling mode when multiple command matches are found.</param>
- <returns>
- A task that represents the asynchronous execution operation. The task result contains the result of the
- command execution.
- </returns>
- </member>
- <member name="T:Discord.Commands.CommandServiceConfig">
- <summary>
- Represents a configuration class for <see cref="T:Discord.Commands.CommandService"/>.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.DefaultRunMode">
- <summary>
- Gets or sets the default <see cref="T:Discord.Commands.RunMode" /> commands should have, if one is not specified on the
- Command attribute or builder.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.SeparatorChar">
- <summary>
- Gets or sets the <see cref="T:System.Char"/> that separates an argument with another.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.CaseSensitiveCommands">
- <summary>
- Gets or sets whether commands should be case-sensitive.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.LogLevel">
- <summary>
- Gets or sets the minimum log level severity that will be sent to the <see cref="E:Discord.Commands.CommandService.Log"/> event.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.ThrowOnError">
- <summary>
- Gets or sets whether <see cref="F:Discord.Commands.RunMode.Sync"/> commands should push exceptions up to the caller.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.QuotationMarkAliasMap">
- <summary>
- Collection of aliases for matching pairs of string delimiters.
- The dictionary stores the opening delimiter as a key, and the matching closing delimiter as the value.
- If no value is supplied <see cref="P:Discord.Commands.QuotationAliasUtils.GetDefaultAliasMap"/> will be used, which contains
- many regional equivalents.
- Only values that are specified in this map will be used as string delimiters, so if " is removed then
- it won't be used.
- If this map is set to null or empty, the default delimiter of " will be used.
- </summary>
- <example>
- <code language="cs">
- QuotationMarkAliasMap = new Dictionary<char, char>()
- {
- {'\"', '\"' },
- {'“', '”' },
- {'「', '」' },
- }
- </code>
- </example>
- </member>
- <member name="P:Discord.Commands.CommandServiceConfig.IgnoreExtraArgs">
- <summary>
- Gets or sets a value that indicates whether extra parameters should be ignored.
- </summary>
- </member>
- <member name="T:Discord.Commands.CommandServiceExtensions">
- <summary>
- Provides extension methods for the <see cref="T:Discord.Commands.CommandService"/> class.
- </summary>
- </member>
- <member name="M:Discord.Commands.CommandServiceExtensions.GetExecutableCommandsAsync(System.Collections.Generic.ICollection{Discord.Commands.CommandInfo},Discord.Commands.ICommandContext,System.IServiceProvider)">
- <summary>
- Returns commands that can be executed under the current context.
- </summary>
- <param name="commands">The set of commands to be checked against.</param>
- <param name="context">The current command context.</param>
- <param name="provider">The service provider used for dependency injection upon precondition check.</param>
- <returns>
- A read-only collection of commands that can be executed under the current context.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandServiceExtensions.GetExecutableCommandsAsync(Discord.Commands.CommandService,Discord.Commands.ICommandContext,System.IServiceProvider)">
- <summary>
- Returns commands that can be executed under the current context.
- </summary>
- <param name="commandService">The desired command service class to check against.</param>
- <param name="context">The current command context.</param>
- <param name="provider">The service provider used for dependency injection upon precondition check.</param>
- <returns>
- A read-only collection of commands that can be executed under the current context.
- </returns>
- </member>
- <member name="M:Discord.Commands.CommandServiceExtensions.GetExecutableCommandsAsync(Discord.Commands.ModuleInfo,Discord.Commands.ICommandContext,System.IServiceProvider)">
- <summary>
- Returns commands that can be executed under the current context.
- </summary>
- <param name="module">The module to be checked against.</param>
- <param name="context">The current command context.</param>
- <param name="provider">The service provider used for dependency injection upon precondition check.</param>
- <returns>
- A read-only collection of commands that can be executed under the current context.
- </returns>
- </member>
- <member name="T:Discord.Commands.MessageExtensions">
- <summary>
- Provides extension methods for <see cref="T:Discord.IUserMessage" /> that relates to commands.
- </summary>
- </member>
- <member name="M:Discord.Commands.MessageExtensions.HasCharPrefix(Discord.IUserMessage,System.Char,System.Int32@)">
- <summary>
- Gets whether the message starts with the provided character.
- </summary>
- <param name="msg">The message to check against.</param>
- <param name="c">The char prefix.</param>
- <param name="argPos">References where the command starts.</param>
- <returns>
- <c>true</c> if the message begins with the char <paramref name="c"/>; otherwise <c>false</c>.
- </returns>
- </member>
- <member name="M:Discord.Commands.MessageExtensions.HasStringPrefix(Discord.IUserMessage,System.String,System.Int32@,System.StringComparison)">
- <summary>
- Gets whether the message starts with the provided string.
- </summary>
- </member>
- <member name="M:Discord.Commands.MessageExtensions.HasMentionPrefix(Discord.IUserMessage,Discord.IUser,System.Int32@)">
- <summary>
- Gets whether the message starts with the user's mention string.
- </summary>
- </member>
- <member name="T:Discord.Commands.CommandInfo">
- <summary>
- Provides the information of a command.
- </summary>
- <remarks>
- This object contains the information of a command. This can include the module of the command, various
- descriptions regarding the command, and its <see cref="P:Discord.Commands.CommandInfo.RunMode"/>.
- </remarks>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Module">
- <summary>
- Gets the module that the command belongs in.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Name">
- <summary>
- Gets the name of the command. If none is set, the first alias is used.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Summary">
- <summary>
- Gets the summary of the command.
- </summary>
- <remarks>
- This field returns the summary of the command. <see cref="P:Discord.Commands.CommandInfo.Summary"/> and <see cref="P:Discord.Commands.CommandInfo.Remarks"/> can be
- useful in help commands and various implementation that fetches details of the command for the user.
- </remarks>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Remarks">
- <summary>
- Gets the remarks of the command.
- </summary>
- <remarks>
- This field returns the summary of the command. <see cref="P:Discord.Commands.CommandInfo.Summary"/> and <see cref="P:Discord.Commands.CommandInfo.Remarks"/> can be
- useful in help commands and various implementation that fetches details of the command for the user.
- </remarks>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Priority">
- <summary>
- Gets the priority of the command. This is used when there are multiple overloads of the command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.HasVarArgs">
- <summary>
- Indicates whether the command accepts a <see langword="params"/> <see cref="T:System.Type"/>[] for its
- parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.IgnoreExtraArgs">
- <summary>
- Indicates whether extra arguments should be ignored for this command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.RunMode">
- <summary>
- Gets the <see cref="P:Discord.Commands.CommandInfo.RunMode" /> that is being used for the command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Aliases">
- <summary>
- Gets a list of aliases defined by the <see cref="T:Discord.Commands.AliasAttribute" /> of the command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Parameters">
- <summary>
- Gets a list of information about the parameters of the command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Preconditions">
- <summary>
- Gets a list of preconditions defined by the <see cref="T:Discord.Commands.PreconditionAttribute" /> of the command.
- </summary>
- </member>
- <member name="P:Discord.Commands.CommandInfo.Attributes">
- <summary>
- Gets a list of attributes of the command.
- </summary>
- </member>
- <member name="T:Discord.Commands.ModuleInfo">
- <summary>
- Provides the information of a module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Service">
- <summary>
- Gets the command service associated with this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Name">
- <summary>
- Gets the name of this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Summary">
- <summary>
- Gets the summary of this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Remarks">
- <summary>
- Gets the remarks of this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Group">
- <summary>
- Gets the group name (main prefix) of this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Aliases">
- <summary>
- Gets a read-only list of aliases associated with this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Commands">
- <summary>
- Gets a read-only list of commands associated with this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Preconditions">
- <summary>
- Gets a read-only list of preconditions that apply to this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Attributes">
- <summary>
- Gets a read-only list of attributes that apply to this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Submodules">
- <summary>
- Gets a read-only list of submodules associated with this module.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.Parent">
- <summary>
- Gets the parent module of this submodule if applicable.
- </summary>
- </member>
- <member name="P:Discord.Commands.ModuleInfo.IsSubmodule">
- <summary>
- Gets a value that indicates whether this module is a submodule or not.
- </summary>
- </member>
- <member name="T:Discord.Commands.ParameterInfo">
- <summary>
- Provides the information of a parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.Command">
- <summary>
- Gets the command that associates with this parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.Name">
- <summary>
- Gets the name of this parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.Summary">
- <summary>
- Gets the summary of this parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.IsOptional">
- <summary>
- Gets a value that indicates whether this parameter is optional or not.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.IsRemainder">
- <summary>
- Gets a value that indicates whether this parameter is a remainder parameter or not.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.Type">
- <summary>
- Gets the type of the parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.DefaultValue">
- <summary>
- Gets the default value for this optional parameter if applicable.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.Preconditions">
- <summary>
- Gets a read-only list of precondition that apply to this parameter.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParameterInfo.Attributes">
- <summary>
- Gets a read-only list of attributes that apply to this parameter.
- </summary>
- </member>
- <member name="M:Discord.Commands.CommandMapNode.AddCommand(Discord.Commands.CommandService,System.String,System.Int32,Discord.Commands.CommandInfo)">
- <exception cref="T:System.InvalidOperationException">Cannot add commands to the root node.</exception>
- </member>
- <member name="T:Discord.Commands.ModuleBase">
- <summary>
- Provides a base class for a command module to inherit from.
- </summary>
- </member>
- <member name="T:Discord.Commands.ModuleBase`1">
- <summary>
- Provides a base class for a command module to inherit from.
- </summary>
- <typeparam name="T">A class that implements <see cref="T:Discord.Commands.ICommandContext"/>.</typeparam>
- </member>
- <member name="P:Discord.Commands.ModuleBase`1.Context">
- <summary>
- The underlying context of the command.
- </summary>
- <seealso cref="T:Discord.Commands.ICommandContext" />
- <seealso cref="T:Discord.Commands.CommandContext" />
- </member>
- <member name="M:Discord.Commands.ModuleBase`1.ReplyAsync(System.String,System.Boolean,Discord.Embed,Discord.RequestOptions,Discord.AllowedMentions,Discord.MessageReference,Discord.MessageComponent,Discord.ISticker[],Discord.Embed[])">
- <summary>
- Sends a message to the source channel.
- </summary>
- <param name="message">
- Contents of the message; optional only if <paramref name="embed" /> is specified.
- </param>
- <param name="isTTS">Specifies if Discord should read this <paramref name="message"/> aloud using text-to-speech.</param>
- <param name="embed">An embed to be displayed alongside the <paramref name="message"/>.</param>
- <param name="allowedMentions">
- Specifies if notifications are sent for mentioned users and roles in the <paramref name="message"/>.
- If <c>null</c>, all mentioned roles and users will be notified.
- </param>
- <param name="options">The request options for this async request.</param>
- <param name="messageReference">The message references to be included. Used to reply to specific messages.</param>
- <param name="component">The message components to be included with this message. Used for interactions.</param>
- <param name="stickers">A collection of stickers to send with the file.</param>
- <param name="embeds">A array of <see cref="T:Discord.Embed"/>s to send with this response. Max 10.</param>
- </member>
- <member name="M:Discord.Commands.ModuleBase`1.BeforeExecute(Discord.Commands.CommandInfo)">
- <summary>
- The method to execute before executing the command.
- </summary>
- <param name="command">The <see cref="T:Discord.Commands.CommandInfo"/> of the command to be executed.</param>
- </member>
- <member name="M:Discord.Commands.ModuleBase`1.AfterExecute(Discord.Commands.CommandInfo)">
- <summary>
- The method to execute after executing the command.
- </summary>
- <param name="command">The <see cref="T:Discord.Commands.CommandInfo"/> of the command to be executed.</param>
- </member>
- <member name="M:Discord.Commands.ModuleBase`1.OnModuleBuilding(Discord.Commands.CommandService,Discord.Commands.Builders.ModuleBuilder)">
- <summary>
- The method to execute when building the module.
- </summary>
- <param name="commandService">The <see cref="T:Discord.Commands.CommandService"/> used to create the module.</param>
- <param name="builder">The builder used to build the module.</param>
- </member>
- <member name="T:Discord.Commands.MultiMatchHandling">
- <summary>
- Specifies the behavior when multiple matches are found during the command parsing stage.
- </summary>
- </member>
- <member name="F:Discord.Commands.MultiMatchHandling.Exception">
- <summary> Indicates that when multiple results are found, an exception should be thrown. </summary>
- </member>
- <member name="F:Discord.Commands.MultiMatchHandling.Best">
- <summary> Indicates that when multiple results are found, the best result should be chosen. </summary>
- </member>
- <member name="T:Discord.Commands.ChannelTypeReader`1">
- <summary>
- A <see cref="T:Discord.Commands.TypeReader"/> for parsing objects implementing <see cref="T:Discord.IChannel"/>.
- </summary>
- <remarks>
- This <see cref="T:Discord.Commands.TypeReader"/> is shipped with Discord.Net and is used by default to parse any
- <see cref="T:Discord.IChannel"/> implemented object within a command. The TypeReader will attempt to first parse the
- input by mention, then the snowflake identifier, then by name; the highest candidate will be chosen as the
- final output; otherwise, an erroneous <see cref="T:Discord.Commands.TypeReaderResult"/> is returned.
- </remarks>
- <typeparam name="T">The type to be checked; must implement <see cref="T:Discord.IChannel"/>.</typeparam>
- </member>
- <member name="M:Discord.Commands.ChannelTypeReader`1.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.EnumTypeReader`1.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.MessageTypeReader`1">
- <summary>
- A <see cref="T:Discord.Commands.TypeReader"/> for parsing objects implementing <see cref="T:Discord.IMessage"/>.
- </summary>
- <typeparam name="T">The type to be checked; must implement <see cref="T:Discord.IMessage"/>.</typeparam>
- </member>
- <member name="M:Discord.Commands.MessageTypeReader`1.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.NullableTypeReader`1.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.PrimitiveTypeReader`1.#ctor">
- <exception cref="T:System.ArgumentOutOfRangeException"><typeparamref name="T"/> must be within the range [0, 1].</exception>
- </member>
- <member name="M:Discord.Commands.PrimitiveTypeReader`1.#ctor(Discord.Commands.TryParseDelegate{`0},System.Single)">
- <exception cref="T:System.ArgumentOutOfRangeException"><paramref name="score"/> must be within the range [0, 1].</exception>
- </member>
- <member name="T:Discord.Commands.RoleTypeReader`1">
- <summary>
- A <see cref="T:Discord.Commands.TypeReader"/> for parsing objects implementing <see cref="T:Discord.IRole"/>.
- </summary>
- <typeparam name="T">The type to be checked; must implement <see cref="T:Discord.IRole"/>.</typeparam>
- </member>
- <member name="M:Discord.Commands.RoleTypeReader`1.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.TimeSpanTypeReader.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.TypeReader">
- <summary>
- Defines a reader class that parses user input into a specified type.
- </summary>
- </member>
- <member name="M:Discord.Commands.TypeReader.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <summary>
- Attempts to parse the <paramref name="input"/> into the desired type.
- </summary>
- <param name="context">The context of the command.</param>
- <param name="input">The raw input of the command.</param>
- <param name="services">The service collection used for dependency injection.</param>
- <returns>
- A task that represents the asynchronous parsing operation. The task result contains the parsing result.
- </returns>
- </member>
- <member name="T:Discord.Commands.UserTypeReader`1">
- <summary>
- A <see cref="T:Discord.Commands.TypeReader"/> for parsing objects implementing <see cref="T:Discord.IUser"/>.
- </summary>
- <typeparam name="T">The type to be checked; must implement <see cref="T:Discord.IUser"/>.</typeparam>
- </member>
- <member name="M:Discord.Commands.UserTypeReader`1.ReadAsync(Discord.Commands.ICommandContext,System.String,System.IServiceProvider)">
- <inheritdoc />
- </member>
- <member name="T:Discord.Commands.ExecuteResult">
- <summary>
- Contains information of the command's overall execution result.
- </summary>
- </member>
- <member name="P:Discord.Commands.ExecuteResult.Exception">
- <summary>
- Gets the exception that may have occurred during the command execution.
- </summary>
- </member>
- <member name="P:Discord.Commands.ExecuteResult.Error">
- <inheritdoc />
- </member>
- <member name="P:Discord.Commands.ExecuteResult.ErrorReason">
- <inheritdoc />
- </member>
- <member name="P:Discord.Commands.ExecuteResult.IsSuccess">
- <inheritdoc />
- </member>
- <member name="M:Discord.Commands.ExecuteResult.FromSuccess">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.ExecuteResult" /> with no error, indicating a successful execution.
- </summary>
- <returns>
- A <see cref="T:Discord.Commands.ExecuteResult" /> that does not contain any errors.
- </returns>
- </member>
- <member name="M:Discord.Commands.ExecuteResult.FromError(Discord.Commands.CommandError,System.String)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.ExecuteResult" /> with a specified <see cref="T:Discord.Commands.CommandError" /> and its
- reason, indicating an unsuccessful execution.
- </summary>
- <param name="error">The type of error.</param>
- <param name="reason">The reason behind the error.</param>
- <returns>
- A <see cref="T:Discord.Commands.ExecuteResult" /> that contains a <see cref="T:Discord.Commands.CommandError" /> and reason.
- </returns>
- </member>
- <member name="M:Discord.Commands.ExecuteResult.FromError(System.Exception)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.ExecuteResult" /> with a specified exception, indicating an unsuccessful
- execution.
- </summary>
- <param name="ex">The exception that caused the command execution to fail.</param>
- <returns>
- A <see cref="T:Discord.Commands.ExecuteResult" /> that contains the exception that caused the unsuccessful execution, along
- with a <see cref="T:Discord.Commands.CommandError" /> of type <c>Exception</c> as well as the exception message as the
- reason.
- </returns>
- </member>
- <member name="M:Discord.Commands.ExecuteResult.FromError(Discord.Commands.IResult)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.ExecuteResult" /> with a specified result; this may or may not be an
- successful execution depending on the <see cref="P:Discord.Commands.IResult.Error" /> and
- <see cref="P:Discord.Commands.IResult.ErrorReason" /> specified.
- </summary>
- <param name="result">The result to inherit from.</param>
- <returns>
- A <see cref="T:Discord.Commands.ExecuteResult"/> that inherits the <see cref="T:Discord.Commands.IResult"/> error type and reason.
- </returns>
- </member>
- <member name="M:Discord.Commands.ExecuteResult.ToString">
- <summary>
- Gets a string that indicates the execution result.
- </summary>
- <returns>
- <c>Success</c> if <see cref="P:Discord.Commands.ExecuteResult.IsSuccess"/> is <c>true</c>; otherwise "<see cref="P:Discord.Commands.ExecuteResult.Error"/>:
- <see cref="P:Discord.Commands.ExecuteResult.ErrorReason"/>".
- </returns>
- </member>
- <member name="T:Discord.Commands.IResult">
- <summary>
- Contains information of the result related to a command.
- </summary>
- </member>
- <member name="P:Discord.Commands.IResult.Error">
- <summary>
- Describes the error type that may have occurred during the operation.
- </summary>
- <returns>
- A <see cref="T:Discord.Commands.CommandError" /> indicating the type of error that may have occurred during the operation;
- <c>null</c> if the operation was successful.
- </returns>
- </member>
- <member name="P:Discord.Commands.IResult.ErrorReason">
- <summary>
- Describes the reason for the error.
- </summary>
- <returns>
- A string containing the error reason.
- </returns>
- </member>
- <member name="P:Discord.Commands.IResult.IsSuccess">
- <summary>
- Indicates whether the operation was successful or not.
- </summary>
- <returns>
- <c>true</c> if the result is positive; otherwise <c>false</c>.
- </returns>
- </member>
- <member name="T:Discord.Commands.ParseResult">
- <summary>
- Contains information for the parsing result from the command service's parser.
- </summary>
- </member>
- <member name="P:Discord.Commands.ParseResult.Error">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.ParseResult.ErrorReason">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.ParseResult.ErrorParameter">
- <summary>
- Provides information about the parameter that caused the parsing error.
- </summary>
- <returns>
- A <see cref="T:Discord.Commands.ParameterInfo" /> indicating the parameter info of the error that may have occurred during parsing;
- <c>null</c> if the parsing was successful or the parsing error is not specific to a single parameter.
- </returns>
- </member>
- <member name="P:Discord.Commands.ParseResult.IsSuccess">
- <inheritdoc/>
- </member>
- <member name="T:Discord.Commands.PreconditionResult">
- <summary>
- Represents a result type for command preconditions.
- </summary>
- </member>
- <member name="P:Discord.Commands.PreconditionResult.Error">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.PreconditionResult.ErrorReason">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.PreconditionResult.IsSuccess">
- <inheritdoc/>
- </member>
- <member name="M:Discord.Commands.PreconditionResult.#ctor(System.Nullable{Discord.Commands.CommandError},System.String)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.PreconditionResult" /> class with the command <paramref name="error"/> type
- and reason.
- </summary>
- <param name="error">The type of failure.</param>
- <param name="errorReason">The reason of failure.</param>
- </member>
- <member name="M:Discord.Commands.PreconditionResult.FromSuccess">
- <summary>
- Returns a <see cref="T:Discord.Commands.PreconditionResult" /> with no errors.
- </summary>
- </member>
- <member name="M:Discord.Commands.PreconditionResult.FromError(System.String)">
- <summary>
- Returns a <see cref="T:Discord.Commands.PreconditionResult" /> with <see cref="F:Discord.Commands.CommandError.UnmetPrecondition" /> and the
- specified reason.
- </summary>
- <param name="reason">The reason of failure.</param>
- </member>
- <member name="M:Discord.Commands.PreconditionResult.FromError(Discord.Commands.IResult)">
- <summary>
- Returns a <see cref="T:Discord.Commands.PreconditionResult" /> with the specified <paramref name="result"/> type.
- </summary>
- <param name="result">The result of failure.</param>
- </member>
- <member name="M:Discord.Commands.PreconditionResult.ToString">
- <summary>
- Returns a string indicating whether the <see cref="T:Discord.Commands.PreconditionResult"/> is successful.
- </summary>
- </member>
- <member name="M:Discord.Commands.RuntimeResult.#ctor(System.Nullable{Discord.Commands.CommandError},System.String)">
- <summary>
- Initializes a new <see cref="T:Discord.Commands.RuntimeResult" /> class with the type of error and reason.
- </summary>
- <param name="error">The type of failure, or <c>null</c> if none.</param>
- <param name="reason">The reason of failure.</param>
- </member>
- <member name="P:Discord.Commands.RuntimeResult.Error">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.RuntimeResult.Reason">
- <summary> Describes the execution reason or result. </summary>
- </member>
- <member name="P:Discord.Commands.RuntimeResult.IsSuccess">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.RuntimeResult.Discord#Commands#IResult#ErrorReason">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.SearchResult.Error">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.SearchResult.ErrorReason">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.SearchResult.IsSuccess">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.TypeReaderResult.Error">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.TypeReaderResult.ErrorReason">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.TypeReaderResult.IsSuccess">
- <inheritdoc/>
- </member>
- <member name="P:Discord.Commands.TypeReaderResult.BestMatch">
- <exception cref="T:System.InvalidOperationException">TypeReaderResult was not successful.</exception>
- </member>
- <member name="T:Discord.Commands.RunMode">
- <summary>
- Specifies the behavior of the command execution workflow.
- </summary>
- <seealso cref="T:Discord.Commands.CommandServiceConfig"/>
- <seealso cref="T:Discord.Commands.CommandAttribute"/>
- </member>
- <member name="F:Discord.Commands.RunMode.Default">
- <summary>
- The default behaviour set in <see cref="T:Discord.Commands.CommandServiceConfig"/>.
- </summary>
- </member>
- <member name="F:Discord.Commands.RunMode.Sync">
- <summary>
- Executes the command on the same thread as gateway one.
- </summary>
- </member>
- <member name="F:Discord.Commands.RunMode.Async">
- <summary>
- Executes the command on a different thread from the gateway one.
- </summary>
- </member>
- <member name="T:Discord.Commands.QuotationAliasUtils">
- <summary>
- Utility class which contains the default matching pairs of quotation marks for CommandServiceConfig
- </summary>
- </member>
- <member name="P:Discord.Commands.QuotationAliasUtils.GetDefaultAliasMap">
- <summary>
- A default map of open-close pairs of quotation marks.
- Contains many regional and Unicode equivalents.
- Used in the <see cref="T:Discord.Commands.CommandServiceConfig"/>.
- </summary>
- <seealso cref="P:Discord.Commands.CommandServiceConfig.QuotationMarkAliasMap"/>
- </member>
- </members>
- </doc>
|