Writable streams are an abstraction for a destination to which data is written.

See also:

Variables

@:value(cast "close")@:enum@:implinlineread onlyClose:WritableEvent<() ‑> Void> = "close"

The 'close' event is emitted when the stream and any of its underlying resources (a file descriptor, for example) have been closed. The event indicates that no more events will be emitted, and no further computation will occur.

See also:

@:value(cast "drain")@:enum@:implinlineread onlyDrain:WritableEvent<() ‑> Void> = "drain"

If a call to stream.write(chunk) returns false, the 'drain' event will be emitted when it is appropriate to resume writing data to the stream.

See also:

@:value(cast "error")@:enum@:implinlineread onlyError:WritableEvent<Error ‑> Void> = "error"

The 'error' event is emitted if an error occurred while writing or piping data. The listener callback is passed a single Error argument when called.

See also:

@:value(cast "finish")@:enum@:implinlineread onlyFinish:WritableEvent<() ‑> Void> = "finish"

The 'finish' event is emitted after the stream.end() method has been called, and all data has been flushed to the underlying system.

See also:

@:value(cast "pipe")@:enum@:implinlineread onlyPipe:WritableEvent<IReadable ‑> Void> = "pipe"

The 'pipe' event is emitted when the stream.pipe() method is called on a readable stream, adding this writable to its set of destinations.

See also:

@:value(cast "unpipe")@:enum@:implinlineread onlyUnpipe:WritableEvent<IReadable ‑> Void> = "unpipe"

The 'unpipe' event is emitted when the stream.unpipe() method is called on a Readable stream, removing this Writable from its set of destinations.

See also: