Skip to content
This repository has been archived by the owner on Sep 4, 2024. It is now read-only.

Latest commit

 

History

History
36 lines (22 loc) · 1.1 KB

DisposableStream.md

File metadata and controls

36 lines (22 loc) · 1.1 KB

com.industry.rx_epl.DisposableStream <>

Wrapper for a stream to allow the stream and the observable to be terminated together. Returned by calls to .toStream(...).

Methods

# .getStream() returns stream<any> <>

Access the stream<any>.

Note: .dispose() should be used rather than stream.quit().

DisposableStream ds := Observable.interval(1.0)
	.toStream();

stream<any> strm := ds.getStream();

stream<integer> intStream := from v in strm select <integer> v;

# .dispose() <>

Dispose of a stream and the observable source.

Note: Calls stream.quit() which will terminate any stream listeners.

DisposableStream ds:= Observable.interval(1.0)
	.toStream();

ds.dispose(); // Terminate the observable and the stream.