NativeReceiveStream class final
The reading half of a stream.
- Implemented types
- Available extensions
Constructors
-
NativeReceiveStream(Pointer<
wt_recv_stream_t> _handle, {int chunkSize = 64 * 1024})
Properties
-
bytes
→ Stream<
Uint8List> -
The bytes of this stream.
no setteroverride
- chunkSize → int
-
Maximum number of bytes requested per read by bytes.
final
-
handle
→ Pointer<
wt_recv_stream_t> -
The underlying native handle (native only).
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → int
-
QUIC stream id.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
cancel(
[int errorCode = 0]) → Future< void> -
Cancels the stream, telling the peer to stop sending.
override
-
dispose(
) → void - Releases the handle.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
read(
) → Future< Uint8List?> -
Reads the next chunk, or
nullonce the peer finished the stream.override -
readExact(
int length) → Future< Uint8List> -
Reads exactly
lengthbytes (native only). -
toBytes(
) → Future< Uint8List> -
Available on WebTransportReceiveStream, provided by the WebTransportReceiveStreamX extension
Drains the stream into a single buffer. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited