UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

652 lines 17 kB
{ "type": "Program", "body": [ { "type": "ImportDeclaration", "specifiers": [ { "type": "ImportSpecifier", "local": { "type": "Identifier", "name": "SubscribeOnObservable", "range": [ 9, 30 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 30 } } }, "imported": { "type": "Identifier", "name": "SubscribeOnObservable", "range": [ 9, 30 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 30 } } }, "range": [ 9, 30 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 30 } } } ], "source": { "type": "Literal", "value": "../observable/SubscribeOnObservable", "raw": "'../observable/SubscribeOnObservable'", "range": [ 38, 75 ], "loc": { "start": { "line": 1, "column": 38 }, "end": { "line": 1, "column": 75 } } }, "range": [ 0, 76 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 76 } }, "trailingComments": [ { "type": "Block", "value": "*\n * Asynchronously subscribes Observers to this Observable on the specified Scheduler.\n *\n * <img src=\"./img/subscribeOn.png\" width=\"100%\">\n *\n * @param {Scheduler} the Scheduler to perform subscription actions on.\n * @return {Observable<T>} the source Observable modified so that its subscriptions happen on the specified Scheduler\n .\n * @method subscribeOn\n * @owner Observable\n ", "range": [ 77, 463 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 12, "column": 3 } } } ] }, { "type": "ExportNamedDeclaration", "declaration": { "type": "FunctionDeclaration", "id": { "type": "Identifier", "name": "subscribeOn", "range": [ 480, 491 ], "loc": { "start": { "line": 13, "column": 16 }, "end": { "line": 13, "column": 27 } } }, "params": [ { "type": "Identifier", "name": "scheduler", "range": [ 492, 501 ], "loc": { "start": { "line": 13, "column": 28 }, "end": { "line": 13, "column": 37 } } }, { "type": "Identifier", "name": "delay", "range": [ 503, 508 ], "loc": { "start": { "line": 13, "column": 39 }, "end": { "line": 13, "column": 44 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "IfStatement", "test": { "type": "BinaryExpression", "operator": "===", "left": { "type": "Identifier", "name": "delay", "range": [ 520, 525 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 13 } } }, "right": { "type": "UnaryExpression", "operator": "void", "argument": { "type": "Literal", "value": 0, "raw": "0", "range": [ 535, 536 ], "loc": { "start": { "line": 14, "column": 23 }, "end": { "line": 14, "column": 24 } } }, "prefix": true, "range": [ 530, 536 ], "loc": { "start": { "line": 14, "column": 18 }, "end": { "line": 14, "column": 24 } } }, "range": [ 520, 536 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 24 } } }, "consequent": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "Identifier", "name": "delay", "range": [ 540, 545 ], "loc": { "start": { "line": 14, "column": 28 }, "end": { "line": 14, "column": 33 } } }, "right": { "type": "Literal", "value": 0, "raw": "0", "range": [ 548, 549 ], "loc": { "start": { "line": 14, "column": 36 }, "end": { "line": 14, "column": 37 } } }, "range": [ 540, 549 ], "loc": { "start": { "line": 14, "column": 28 }, "end": { "line": 14, "column": 37 } } }, "range": [ 540, 550 ], "loc": { "start": { "line": 14, "column": 28 }, "end": { "line": 14, "column": 38 } } } ], "range": [ 538, 552 ], "loc": { "start": { "line": 14, "column": 26 }, "end": { "line": 14, "column": 40 } } }, "alternate": null, "range": [ 516, 552 ], "loc": { "start": { "line": 14, "column": 4 }, "end": { "line": 14, "column": 40 } } }, { "type": "ReturnStatement", "argument": { "type": "NewExpression", "callee": { "type": "Identifier", "name": "SubscribeOnObservable", "range": [ 568, 589 ], "loc": { "start": { "line": 15, "column": 15 }, "end": { "line": 15, "column": 36 } } }, "arguments": [ { "type": "ThisExpression", "range": [ 590, 594 ], "loc": { "start": { "line": 15, "column": 37 }, "end": { "line": 15, "column": 41 } } }, { "type": "Identifier", "name": "delay", "range": [ 596, 601 ], "loc": { "start": { "line": 15, "column": 43 }, "end": { "line": 15, "column": 48 } } }, { "type": "Identifier", "name": "scheduler", "range": [ 603, 612 ], "loc": { "start": { "line": 15, "column": 50 }, "end": { "line": 15, "column": 59 } } } ], "range": [ 564, 613 ], "loc": { "start": { "line": 15, "column": 11 }, "end": { "line": 15, "column": 60 } } }, "range": [ 557, 614 ], "loc": { "start": { "line": 15, "column": 4 }, "end": { "line": 15, "column": 61 } } } ], "range": [ 510, 616 ], "loc": { "start": { "line": 13, "column": 46 }, "end": { "line": 16, "column": 1 } } }, "generator": false, "expression": false, "range": [ 471, 616 ], "loc": { "start": { "line": 13, "column": 7 }, "end": { "line": 16, "column": 1 } }, "leadingComments": [ { "type": "Block", "value": "*\n * Asynchronously subscribes Observers to this Observable on the specified Scheduler.\n *\n * <img src=\"./img/subscribeOn.png\" width=\"100%\">\n *\n * @param {Scheduler} the Scheduler to perform subscription actions on.\n * @return {Observable<T>} the source Observable modified so that its subscriptions happen on the specified Scheduler\n .\n * @method subscribeOn\n * @owner Observable\n ", "range": [ 77, 463 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 12, "column": 3 } } } ], "trailingComments": [ { "type": "Line", "value": "# sourceMappingURL=subscribeOn.js.map", "range": [ 617, 656 ], "loc": { "start": { "line": 17, "column": 0 }, "end": { "line": 17, "column": 39 } } } ] }, "specifiers": [], "source": null, "range": [ 464, 616 ], "loc": { "start": { "line": 13, "column": 0 }, "end": { "line": 16, "column": 1 } }, "leadingComments": [ { "type": "Block", "value": "*\n * Asynchronously subscribes Observers to this Observable on the specified Scheduler.\n *\n * <img src=\"./img/subscribeOn.png\" width=\"100%\">\n *\n * @param {Scheduler} the Scheduler to perform subscription actions on.\n * @return {Observable<T>} the source Observable modified so that its subscriptions happen on the specified Scheduler\n .\n * @method subscribeOn\n * @owner Observable\n ", "range": [ 77, 463 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 12, "column": 3 } } } ], "trailingComments": [ { "type": "Line", "value": "# sourceMappingURL=subscribeOn.js.map", "range": [ 617, 656 ], "loc": { "start": { "line": 17, "column": 0 }, "end": { "line": 17, "column": 39 } } } ] } ], "sourceType": "module", "range": [ 0, 616 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 16, "column": 1 } }, "comments": [ { "type": "Block", "value": "*\n * Asynchronously subscribes Observers to this Observable on the specified Scheduler.\n *\n * <img src=\"./img/subscribeOn.png\" width=\"100%\">\n *\n * @param {Scheduler} the Scheduler to perform subscription actions on.\n * @return {Observable<T>} the source Observable modified so that its subscriptions happen on the specified Scheduler\n .\n * @method subscribeOn\n * @owner Observable\n ", "range": [ 77, 463 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 12, "column": 3 } } }, { "type": "Line", "value": "# sourceMappingURL=subscribeOn.js.map", "range": [ 617, 656 ], "loc": { "start": { "line": 17, "column": 0 }, "end": { "line": 17, "column": 39 } } } ] }