querySupportedCommands method

List? querySupportedCommands()

Query supported commands.

Returns a list of supported commands.

Implementation

List? querySupportedCommands() {
  if (!_ready) throw AlohaException(AlohaException.notReady);

  final js.JsArray proxy = _alohaContext.callMethod('querySupportedCommands');

  List? commands = <String>[];

  try {
    final length = proxy.length;
    for (var i = 0; i < length; i++) {
      commands.add(proxy[i]);
    }
  } on Exception {
    commands = null;
  }

  return commands;
}