WritableStreamDefaultWriter extension type

The WritableStreamDefaultWriter interface of the Streams API is the object returned by WritableStream.getWriter and once created locks the writer to the WritableStream ensuring that no other streams can write to the underlying sink.

on
Implemented types

Constructors

WritableStreamDefaultWriter(WritableStream stream)
factory

Properties

closed JSPromise<JSAny?>
no setter
desiredSize num?
no setter
hashCode int
The hash code for this object.
no setterinherited
ready JSPromise<JSAny?>
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

abort([JSAny? reason]) JSPromise<JSAny?>
The abort() method of the WritableStreamDefaultWriter interface aborts the stream, signaling that the producer can no longer successfully write to the stream and it is to be immediately moved to an error state, with any queued writes discarded.
close() JSPromise<JSAny?>
The close() method of the WritableStreamDefaultWriter interface closes the associated writable stream.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
releaseLock() → void
The releaseLock() method of the WritableStreamDefaultWriter interface releases the writer's lock on the corresponding stream. After the lock is released, the writer is no longer active. If the associated stream is errored when the lock is released, the writer will appear errored in the same way from now on; otherwise, the writer will appear closed.
toString() String
A string representation of this object.
inherited
write([JSAny? chunk]) JSPromise<JSAny?>
The write() method of the WritableStreamDefaultWriter interface writes a passed chunk of data to a WritableStream and its underlying sink, then returns a Promise that resolves to indicate the success or failure of the write operation.

Operators

operator ==(Object other) bool
The equality operator.
inherited