JsonUtf8Encoder class
Encoder that encodes a single object as a UTF-8 encoded JSON string.
This encoder works equivalently to first converting the object to a JSON string, and then UTF-8 encoding the string, but without creating an intermediate string.
Constants
- DEFAULT_BUFFER_SIZE → int
-
Default buffer size used by the JSON-to-UTF-8 encoder.
256
Constructors
- JsonUtf8Encoder([String indent, dynamic toEncodable(object), int bufferSize = DEFAULT_BUFFER_SIZE ])
-
Create converter.
Properties
- hashCode → int read-only, inherited
-
The hash code for this object.
- runtimeType → Type read-only, inherited
-
A representation of the runtime type of the object.
Operators
- operator ==(
other) → bool inherited -
The equality operator.
Methods
- bind(
Stream<Object> stream) → Stream<List<int>> -
Transforms the provided
stream
. - convert(
Object object) → List<int> -
Convert
object
into UTF-8 encoded JSON. - startChunkedConversion(
Sink<List<int>> sink) → ChunkedConversionSink<Object> -
Start a chunked conversion.
- fuse<TT>(
Converter<List<int>, TT> other) → Converter<Object, TT> inherited -
Fuses
this
withother
. - noSuchMethod(
Invocation invocation) → dynamic inherited -
Invoked when a non-existent method or property is accessed.
- toString(
) → String inherited -
Returns a string representation of this object.
© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/1.24.3/dart-convert/JsonUtf8Encoder-class.html