Table of Contents

Class CommandDescription

Namespace
BSGameLib.Chat
Assembly
BSGameLib.Chat.dll

A registered command as a game can show or complete it: what it is called and typed as, what it takes, and for a group, the commands under it. Read from the engine with DescribeCommands().

public sealed record CommandDescription : IEquatable<CommandDescription>
Inheritance
CommandDescription
Implements
Inherited Members

Constructors

CommandDescription(string, IReadOnlyList<string>, string, Type, IReadOnlyList<ICommandParameter>, IReadOnlyList<CommandDescription>, bool)

A registered command as a game can show or complete it: what it is called and typed as, what it takes, and for a group, the commands under it. Read from the engine with DescribeCommands().

public CommandDescription(string Name, IReadOnlyList<string> Keywords, string HelpText, Type CommandType, IReadOnlyList<ICommandParameter> Parameters, IReadOnlyList<CommandDescription> Commands, bool IsDefault)

Parameters

Name string

Its name, as registered.

Keywords IReadOnlyList<string>

What is typed for it: the first is its own, the rest shortenings.

HelpText string

What it does, when it says.

CommandType Type

The class behind it, for a game to ask what it needs before showing it; null for one built in code.

Parameters IReadOnlyList<ICommandParameter>

What it takes, in order.

Commands IReadOnlyList<CommandDescription>

For a group, the commands under it; empty otherwise.

IsDefault bool

Run when its group is typed with nothing after it.

Properties

CommandType

The class behind it, for a game to ask what it needs before showing it; null for one built in code.

public Type CommandType { get; init; }

Property Value

Type

Commands

For a group, the commands under it; empty otherwise.

public IReadOnlyList<CommandDescription> Commands { get; init; }

Property Value

IReadOnlyList<CommandDescription>

HelpText

What it does, when it says.

public string HelpText { get; init; }

Property Value

string

IsDefault

Run when its group is typed with nothing after it.

public bool IsDefault { get; init; }

Property Value

bool

IsGroup

Whether it is a group of commands, typed with one of them after it.

public bool IsGroup { get; }

Property Value

bool

Keywords

What is typed for it: the first is its own, the rest shortenings.

public IReadOnlyList<string> Keywords { get; init; }

Property Value

IReadOnlyList<string>

Name

Its name, as registered.

public string Name { get; init; }

Property Value

string

Parameters

What it takes, in order.

public IReadOnlyList<ICommandParameter> Parameters { get; init; }

Property Value

IReadOnlyList<ICommandParameter>