Skip to content

Latest commit

 

History

History
58 lines (45 loc) · 2.2 KB

manyselect.md

File metadata and controls

58 lines (45 loc) · 2.2 KB

Rx.Observable.prototype.manySelect(selector, [scheduler])

Rx.Observable.prototype.extend(selector, [scheduler])

Comonadic bind operator.

Arguments

  1. selector (Function): A transform function to apply to each element.
  2. [scheduler=Rx.Scheduler.immediate] (Scheduler): Scheduler used to execute the operation. If not specified, defaults to the Rx.Scheduler.immediate scheduler.

Returns

(Observable): An observable sequence which results from the comonadic bind operation.

Example

var source = Rx.Observable.range(0, 3)
    .manySelect(function (ys) { return ys.first(); })
    .mergeAll();

var subscription = source.subscribe(
    function (x) {
        console.log('Next: ' + x);
    },
    function (err) {
        console.log('Error: ' + err);
    },
    function () {
        console.log('Completed');
    });

// => Next: 0
// => Next: 1
// => Next: 2
// => Completed

Location

File:

Dist:

Prerequisites:

NPM Packages:

NuGet Packages:

Unit Tests: