send method

  1. @override
Future<Map<String, Object?>?> send(
  1. String method,
  2. Map<String, Object?>? params
)

Send a command to the server. An 'id' will be automatically assigned. The returned Future will be completed when the server acknowledges the command with a response. If the server acknowledges the command with a normal (non-error) response, the future will be completed with the 'result' field from the response. If the server acknowledges the command with an error response, the future will be completed with an error.

Implementation

@override
Future<Map<String, Object?>?> send(
        String method, Map<String, Object?>? params) =>
    sendCommandWith(method, params, _process!.stdin.add);