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

    Class CommandsOptions

    Options used for command processing.

    Inheritance
    System.Object
    CommandsOptions
    Implements
    ICommandOptions
    Namespace: TehGM.Wolfringo.Commands
    Assembly: Wolfringo.Commands.dll
    Syntax
    public class CommandsOptions : ICommandOptions
    Remarks

    These are default options for CommandsService. They contain minimum amount of settings for core of Commands System to work.

    If you need to create custom options, inherit from this class. All properties are settable, so they can be changed from child classes.

    Properties

    | Improve this Doc View Source

    Assemblies

    Collection of Assemblies to load Command Handlers from.

    Declaration
    public ICollection<Assembly> Assemblies { get; set; }
    Property Value
    Type Description
    System.Collections.Generic.ICollection<System.Reflection.Assembly>
    Remarks

    Types need to have CommandsHandlerAttribute to be treated as a loadable type. Any type without that attribute will be ignored.

    | Improve this Doc View Source

    CancellationToken

    Cancellation token that can be used for cancelling all tasks within CommandsService.

    Declaration
    public CancellationToken CancellationToken { get; set; }
    Property Value
    Type Description
    System.Threading.CancellationToken
    | Improve this Doc View Source

    CaseSensitivity

    Whether commands should behave case-sensitive by default. Default value is false.

    Declaration
    public bool CaseSensitivity { get; set; }
    Property Value
    Type Description
    System.Boolean
    Remarks

    This setting can be overwritten per command using CaseSensitivityAttribute.

    See Also
    CaseSensitivityAttribute
    | Improve this Doc View Source

    Classes

    Collection of Types to load as Command Handlers.

    Declaration
    public ICollection<Type> Classes { get; set; }
    Property Value
    Type Description
    System.Collections.Generic.ICollection<System.Type>
    Remarks

    Any type included in this collection does not need to have CommandsHandlerAttribute.

    See Also
    Assemblies
    | Improve this Doc View Source

    EnableDefaultHelpCommand

    Whether the built-in default help command should be enabled.

    Declaration
    public bool EnableDefaultHelpCommand { get; set; }
    Property Value
    Type Description
    System.Boolean
    Remarks

    This command will be added independently on Classes and Assemblies.

    Defaults to false.

    | Improve this Doc View Source

    Prefix

    Prefix commands need to have. Default value is "!".

    Declaration
    public string Prefix { get; set; }
    Property Value
    Type Description
    System.String
    Remarks

    The actual requirement for command to have a prefix is specified by RequirePrefix.

    See Also
    RequirePrefix
    | Improve this Doc View Source

    RequirePrefix

    How prefix requirement is enforced by default. Default value is "Always".

    Declaration
    public PrefixRequirement RequirePrefix { get; set; }
    Property Value
    Type Description
    PrefixRequirement
    Remarks

    Prefix value can be set using Prefix

    See Also
    Prefix

    Implements

    ICommandOptions