MCPcopy
hub / github.com/mongodb/node-mongodb-native / stream

Method stream

src/change_stream.ts:868–874  ·  view source on GitHub ↗

* Return a modified Readable stream including a possible transform method. * * NOTE: When using a Stream to process change stream events, the stream will * NOT automatically resume in the case a resumable error is encountered. * * @throws MongoChangeStreamError if the underlying curso

()

Source from the content-addressed store, hash-verified

866 * @throws MongoChangeStreamError if the underlying cursor or the change stream is closed
867 */
868 stream(): Readable & AsyncIterable<TChange> {
869 if (this.closed) {
870 throw new MongoChangeStreamError(CHANGESTREAM_CLOSED_ERROR);
871 }
872
873 return this.cursor.stream();
874 }
875
876 /** @internal */
877 private _setIsEmitter(): void {

Calls

no outgoing calls

Tested by 1

testFunction · 0.64