getLatestLedger method

Future<GetLatestLedgerResponse> getLatestLedger()
inherited

Implementation

Future<GetLatestLedgerResponse> getLatestLedger() async {
  JsonRpcMethod getLatestLedger = JsonRpcMethod("getLatestLedger");
  dio.Response response = await _dio.post(_serverUrl,
      data: json.encode(getLatestLedger),
      options: dio.Options(headers: _headers));
  if (enableLogging) {
    print("getLatestLedger response: $response");
  }
  return GetLatestLedgerResponse.fromJson(response.data);
}