registerCommand method

String registerCommand(
  1. String name, {
  2. String description = '',
  3. List<JsonMap> options = const [],
  4. bool control = false,
  5. FakeAutocomplete? suggest,
})

Registers the command name of this agent on the instance (09 10.2) with option suggestions from suggest (09 10.5); returns its ID.

Implementation

String registerCommand(
  String name, {
  String description = '',
  List<JsonMap> options = const [],
  bool control = false,
  FakeAutocomplete? suggest,
}) => FakeAgentInterface.of(world).registerCommand(
  agentId,
  name,
  description: description,
  options: options,
  control: control,
  autocomplete: suggest,
);