OpenMod Docs OpenMod Docs
OpenMod Docs OpenMod Docs
OpenMod .NET Plugin Framework.

Interface ICommandContextBuilder

The service for creating command contexts.

Namespace: OpenMod.API.Commands
Assembly: OpenMod.API.dll
Syntax
public interface ICommandContextBuilder

Methods

| Improve this Doc View Source

CreateContext(ICommandActor, String[], String, IReadOnlyCollection<ICommandRegistration>)

Creates a command context.

Declaration
ICommandContext CreateContext(ICommandActor actor, string[] args, string prefix, IReadOnlyCollection<ICommandRegistration> commandRegistrations)
Parameters
Type Name Description
ICommandActor actor

The command actor.

System.String[] args

The arguments for the command.

System.String prefix

The prefix for the command. Can be empty.

IReadOnlyCollection<ICommandRegistration> commandRegistrations

The command registrations used for looking up commands and their child commands. See GetCommandsAsync().

Returns
Type Description
ICommandContext

The created command context.

Extension Methods

DisposeHelper.DisposeSyncOrAsync(Object)