HttpTransport class

HTTP transport for JSON-RPC communication.

Constructors

HttpTransport(String url, {Map<String, String> headers = const {}, Duration timeout = const Duration(seconds: 30), Client? client})

Properties

hashCode int
The hash code for this object.
no setterinherited
headers Map<String, String>
Custom HTTP headers.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
timeout Duration
Request timeout.
final
url String
The RPC endpoint URL.
final

Methods

batchRequest(List<RpcRequest> requests) Future<List<Map<String, dynamic>>>
Sends multiple RPC requests in a batch.
dispose() → void
Disposes of the transport resources.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
request(String method, List params) Future<Map<String, dynamic>>
Sends a single RPC request.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited