Receives chunks from callback-style conversation streaming.
Constructors
- MessageCallback.from({required void onMessage(Message message), required void onDone(), required void onError(Object error, StackTrace stackTrace)})
-
Creates a callback from individual lifecycle handlers.
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onDone(
) → void - Called when the stream finishes successfully.
-
onError(
Object error, StackTrace stackTrace) → void - Called when the stream fails.
-
onMessage(
Message message) → void - Called for each streamed message chunk.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited