Wolfringo Wolfringo
Wolfringo Wolfringo
Wolfringo (c) 2020 TehGM
DocFX, DiscordFX theme.
Search Results for

    Interface ICommandsService

    A service that deals with commands loading, initialization and execution.

    Namespace: TehGM.Wolfringo.Commands
    Assembly: Wolfringo.Commands.dll
    Syntax
    public interface ICommandsService

    Properties

    | Improve this Doc View Source

    Commands

    Descriptors of all commands loaded to this commands service.

    Declaration
    IEnumerable<ICommandInstanceDescriptor> Commands { get; }
    Property Value
    Type Description
    System.Collections.Generic.IEnumerable<ICommandInstanceDescriptor>

    Methods

    | Improve this Doc View Source

    ExecuteAsync(ICommandContext, CancellationToken)

    Executes commands against a command context.

    Declaration
    Task<ICommandResult> ExecuteAsync(ICommandContext context, CancellationToken cancellationToken = default(CancellationToken))
    Parameters
    Type Name Description
    ICommandContext context

    Context to execute commands with.

    System.Threading.CancellationToken cancellationToken

    Cancellation token to cancel execution with.

    Returns
    Type Description
    System.Threading.Tasks.Task<ICommandResult>

    Result of the execution.

    | Improve this Doc View Source

    StartAsync(CancellationToken)

    Starts the Command Service.

    Declaration
    Task StartAsync(CancellationToken cancellationToken = default(CancellationToken))
    Parameters
    Type Name Description
    System.Threading.CancellationToken cancellationToken

    Cancellation token to cancel loading with.

    Returns
    Type Description
    System.Threading.Tasks.Task