CommandsClientExtension extension
- on
Methods
-
addCommand(
String command, FutureOr< String?> callback(CommandArgs)) → void -
Available on Client, provided by the CommandsClientExtension extension
Add a command to the command handler.command
is its name, andcallback
is the callback to invoke -
parseAndRunCommand(
Room room, String msg, {Event? inReplyTo, String? editEventId, String? txid, String? threadRootEventId, String? threadLastEventId}) → Future< String?> -
Available on Client, provided by the CommandsClientExtension extension
Parse and execute a string,msg
is the input. OptionallyinReplyTo
is the event being replied to andeditEventId
is the eventId of the event being replied to -
registerDefaultCommands(
) → void -
Available on Client, provided by the CommandsClientExtension extension
Register all default commands -
unregisterAllCommands(
) → void -
Available on Client, provided by the CommandsClientExtension extension
Unregister all commands