BodyDecoder class abstract

Decodes bytes according to contentType.

See RequestBody for a concrete implementation.

Implementers

Constructors

BodyDecoder(Stream<List<int>> bodyByteStream)

Properties

bytes Stream<List<int>>
The stream of bytes to decode.
no setter
contentType ContentType?
Determines how bytes get decoded.
no setter
decodedType Type
The type of data bytes was decoded into.
no setter
hasBeenDecoded bool
Whether or not bytes have been decoded yet.
no setter
hashCode int
The hash code for this object.
no setterinherited
isEmpty bool
Whether or not bytes is empty.
no setter
originalBytes List<int>?
The raw bytes of this request body.
no setter
retainOriginalBytes bool
Whether or not bytes are available as a list after decoding has occurred.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

as<T>() → T
Returns previously decoded object as T.
decode<T>() Future<T>
Decodes this object's bytes as T.
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