Execution

data class Execution<T : CommandEvent<*>>(val arguments: List<Argument<*, *>>, val action: suspend T.() -> Unit)

The bundle of information to be executed when a command is invoked.

Parameters

arguments

The Arguments accepted by this execution.

action

The code to be run when this execution is fired.

Constructors

Link copied to clipboard
fun <T : CommandEvent<*>> Execution(arguments: List<Argument<*, *>>, action: suspend T.() -> Unit)

Functions

Link copied to clipboard
suspend fun execute(event: T)

Run the command logic.

Properties

Link copied to clipboard
val action: suspend T.() -> Unit
Link copied to clipboard
val arguments: List<Argument<*, *>>
Link copied to clipboard
val signature: String

Mocks a method signature using Argument names, ex: (a, b, c)

Link copied to clipboard
val structure: String

Each Argument separated by a space ex: a b c