A live message channel to an MCP server: JSON-RPC messages go out through send, decoded server messages arrive on messages.
- Implementers
Properties
-
closed
→ Future<
void> -
Completes when the connection dies, expectedly or not.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
-
messages
→ Stream<
Map< String, dynamic> > -
Decoded JSON-RPC messages from the server. The stream closing (normally
or by error) means the connection is dead.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
close(
) → Future< void> - Closes the connection. Idempotent.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
send(
Map< String, dynamic> message) → Future<void> - Sends one JSON-RPC message. For HTTP transports the returned future settles once the message was POSTed (transport-level failures are delivered as synthetic error responses on messages when the message was a request).
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited