StringPropertyStream class
A property stream for JSON string values.
Provides both a stream that emits string chunks as they are parsed, and a future that completes with the complete string value.
Example:
final titleStream = parser.getStringProperty('title');
// React to chunks as they arrive
titleStream.stream.listen((chunk) {
displayText += chunk; // Update UI incrementally
});
// Or wait for the complete value
final fullTitle = await titleStream.future;
- Inheritance
-
- Object
- PropertyStream<
String> - StringPropertyStream
Constructors
-
StringPropertyStream({required Future<
String> future, required Stream<String> stream, required JsonStreamParserController parserController})
Properties
-
future
→ Future<
String> -
A future that completes with the final parsed value of this property.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
stream
→ Stream<
String> -
A stream that emits string chunks as they are parsed.
no setter
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited