UNPKG

@reactivex/rxjs

Version:

Reactive Extensions for modern JavaScript

1,463 lines 220 kB
{ "type": "Program", "body": [ { "type": "ImportDeclaration", "specifiers": [ { "type": "ImportSpecifier", "local": { "type": "Identifier", "name": "Subscriber", "range": [ 9, 19 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 19 } } }, "imported": { "type": "Identifier", "name": "Subscriber", "range": [ 9, 19 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 19 } } }, "range": [ 9, 19 ], "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 19 } } } ], "source": { "type": "Literal", "value": "../Subscriber", "raw": "'../Subscriber'", "range": [ 27, 42 ], "loc": { "start": { "line": 1, "column": 27 }, "end": { "line": 1, "column": 42 } } }, "range": [ 0, 43 ], "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 43 } }, "trailingComments": [ { "type": "Block", "value": " tslint:disable:max-line-length ", "range": [ 44, 80 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 36 } } } ] }, { "type": "ExportNamedDeclaration", "declaration": { "type": "FunctionDeclaration", "id": { "type": "Identifier", "name": "find", "range": [ 97, 101 ], "loc": { "start": { "line": 3, "column": 16 }, "end": { "line": 3, "column": 20 } } }, "params": [ { "type": "Identifier", "name": "predicate", "range": [ 102, 111 ], "loc": { "start": { "line": 3, "column": 21 }, "end": { "line": 3, "column": 30 } } }, { "type": "Identifier", "name": "thisArg", "range": [ 113, 120 ], "loc": { "start": { "line": 3, "column": 32 }, "end": { "line": 3, "column": 39 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "IfStatement", "test": { "type": "BinaryExpression", "operator": "!==", "left": { "type": "UnaryExpression", "operator": "typeof", "argument": { "type": "Identifier", "name": "predicate", "range": [ 139, 148 ], "loc": { "start": { "line": 4, "column": 15 }, "end": { "line": 4, "column": 24 } } }, "prefix": true, "range": [ 132, 148 ], "loc": { "start": { "line": 4, "column": 8 }, "end": { "line": 4, "column": 24 } } }, "right": { "type": "Literal", "value": "function", "raw": "'function'", "range": [ 153, 163 ], "loc": { "start": { "line": 4, "column": 29 }, "end": { "line": 4, "column": 39 } } }, "range": [ 132, 163 ], "loc": { "start": { "line": 4, "column": 8 }, "end": { "line": 4, "column": 39 } } }, "consequent": { "type": "BlockStatement", "body": [ { "type": "ThrowStatement", "argument": { "type": "NewExpression", "callee": { "type": "Identifier", "name": "TypeError", "range": [ 185, 194 ], "loc": { "start": { "line": 5, "column": 18 }, "end": { "line": 5, "column": 27 } } }, "arguments": [ { "type": "Literal", "value": "predicate is not a function", "raw": "'predicate is not a function'", "range": [ 195, 224 ], "loc": { "start": { "line": 5, "column": 28 }, "end": { "line": 5, "column": 57 } } } ], "range": [ 181, 225 ], "loc": { "start": { "line": 5, "column": 14 }, "end": { "line": 5, "column": 58 } } }, "range": [ 175, 226 ], "loc": { "start": { "line": 5, "column": 8 }, "end": { "line": 5, "column": 59 } } } ], "range": [ 165, 232 ], "loc": { "start": { "line": 4, "column": 41 }, "end": { "line": 6, "column": 5 } } }, "alternate": null, "range": [ 128, 232 ], "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 6, "column": 5 } } }, { "type": "ReturnStatement", "argument": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 244, 248 ], "loc": { "start": { "line": 7, "column": 11 }, "end": { "line": 7, "column": 15 } } }, "property": { "type": "Identifier", "name": "lift", "range": [ 249, 253 ], "loc": { "start": { "line": 7, "column": 16 }, "end": { "line": 7, "column": 20 } } }, "range": [ 244, 253 ], "loc": { "start": { "line": 7, "column": 11 }, "end": { "line": 7, "column": 20 } } }, "arguments": [ { "type": "NewExpression", "callee": { "type": "Identifier", "name": "FindValueOperator", "range": [ 258, 275 ], "loc": { "start": { "line": 7, "column": 25 }, "end": { "line": 7, "column": 42 } } }, "arguments": [ { "type": "Identifier", "name": "predicate", "range": [ 276, 285 ], "loc": { "start": { "line": 7, "column": 43 }, "end": { "line": 7, "column": 52 } } }, { "type": "ThisExpression", "range": [ 287, 291 ], "loc": { "start": { "line": 7, "column": 54 }, "end": { "line": 7, "column": 58 } } }, { "type": "Literal", "value": false, "raw": "false", "range": [ 293, 298 ], "loc": { "start": { "line": 7, "column": 60 }, "end": { "line": 7, "column": 65 } } }, { "type": "Identifier", "name": "thisArg", "range": [ 300, 307 ], "loc": { "start": { "line": 7, "column": 67 }, "end": { "line": 7, "column": 74 } } } ], "range": [ 254, 308 ], "loc": { "start": { "line": 7, "column": 21 }, "end": { "line": 7, "column": 75 } } } ], "range": [ 244, 309 ], "loc": { "start": { "line": 7, "column": 11 }, "end": { "line": 7, "column": 76 } } }, "range": [ 237, 310 ], "loc": { "start": { "line": 7, "column": 4 }, "end": { "line": 7, "column": 77 } } } ], "range": [ 122, 312 ], "loc": { "start": { "line": 3, "column": 41 }, "end": { "line": 8, "column": 1 } } }, "generator": false, "expression": false, "range": [ 88, 312 ], "loc": { "start": { "line": 3, "column": 7 }, "end": { "line": 8, "column": 1 } }, "leadingComments": [ { "type": "Block", "value": " tslint:disable:max-line-length ", "range": [ 44, 80 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 36 } } } ], "trailingComments": [] }, "specifiers": [], "source": null, "range": [ 81, 312 ], "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 8, "column": 1 } }, "leadingComments": [ { "type": "Block", "value": " tslint:disable:max-line-length ", "range": [ 44, 80 ], "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 36 } } } ] }, { "type": "ExportNamedDeclaration", "declaration": { "type": "VariableDeclaration", "declarations": [ { "type": "VariableDeclarator", "id": { "type": "Identifier", "name": "FindValueOperator", "range": [ 324, 341 ], "loc": { "start": { "line": 9, "column": 11 }, "end": { "line": 9, "column": 28 } } }, "init": { "type": "CallExpression", "callee": { "type": "FunctionExpression", "id": null, "params": [], "body": { "type": "BlockStatement", "body": [ { "type": "FunctionDeclaration", "id": { "type": "Identifier", "name": "FindValueOperator", "range": [ 372, 389 ], "loc": { "start": { "line": 10, "column": 13 }, "end": { "line": 10, "column": 30 } } }, "params": [ { "type": "Identifier", "name": "predicate", "range": [ 390, 399 ], "loc": { "start": { "line": 10, "column": 31 }, "end": { "line": 10, "column": 40 } } }, { "type": "Identifier", "name": "source", "range": [ 401, 407 ], "loc": { "start": { "line": 10, "column": 42 }, "end": { "line": 10, "column": 48 } } }, { "type": "Identifier", "name": "yieldIndex", "range": [ 409, 419 ], "loc": { "start": { "line": 10, "column": 50 }, "end": { "line": 10, "column": 60 } } }, { "type": "Identifier", "name": "thisArg", "range": [ 421, 428 ], "loc": { "start": { "line": 10, "column": 62 }, "end": { "line": 10, "column": 69 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 440, 444 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 12 } } }, "property": { "type": "Identifier", "name": "predicate", "range": [ 445, 454 ], "loc": { "start": { "line": 11, "column": 13 }, "end": { "line": 11, "column": 22 } } }, "range": [ 440, 454 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 22 } } }, "right": { "type": "Identifier", "name": "predicate", "range": [ 457, 466 ], "loc": { "start": { "line": 11, "column": 25 }, "end": { "line": 11, "column": 34 } } }, "range": [ 440, 466 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 34 } } }, "range": [ 440, 467 ], "loc": { "start": { "line": 11, "column": 8 }, "end": { "line": 11, "column": 35 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 476, 480 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 12 } } }, "property": { "type": "Identifier", "name": "source", "range": [ 481, 487 ], "loc": { "start": { "line": 12, "column": 13 }, "end": { "line": 12, "column": 19 } } }, "range": [ 476, 487 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 19 } } }, "right": { "type": "Identifier", "name": "source", "range": [ 490, 496 ], "loc": { "start": { "line": 12, "column": 22 }, "end": { "line": 12, "column": 28 } } }, "range": [ 476, 496 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 28 } } }, "range": [ 476, 497 ], "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 29 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 506, 510 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 12 } } }, "property": { "type": "Identifier", "name": "yieldIndex", "range": [ 511, 521 ], "loc": { "start": { "line": 13, "column": 13 }, "end": { "line": 13, "column": 23 } } }, "range": [ 506, 521 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 23 } } }, "right": { "type": "Identifier", "name": "yieldIndex", "range": [ 524, 534 ], "loc": { "start": { "line": 13, "column": 26 }, "end": { "line": 13, "column": 36 } } }, "range": [ 506, 534 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 36 } } }, "range": [ 506, 535 ], "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 37 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "ThisExpression", "range": [ 544, 548 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 12 } } }, "property": { "type": "Identifier", "name": "thisArg", "range": [ 549, 556 ], "loc": { "start": { "line": 14, "column": 13 }, "end": { "line": 14, "column": 20 } } }, "range": [ 544, 556 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 20 } } }, "right": { "type": "Identifier", "name": "thisArg", "range": [ 559, 566 ], "loc": { "start": { "line": 14, "column": 23 }, "end": { "line": 14, "column": 30 } } }, "range": [ 544, 566 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 30 } } }, "range": [ 544, 567 ], "loc": { "start": { "line": 14, "column": 8 }, "end": { "line": 14, "column": 31 } } } ], "range": [ 430, 573 ], "loc": { "start": { "line": 10, "column": 71 }, "end": { "line": 15, "column": 5 } } }, "generator": false, "expression": false, "range": [ 363, 573 ], "loc": { "start": { "line": 10, "column": 4 }, "end": { "line": 15, "column": 5 } } }, { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=", "left": { "type": "MemberExpression", "computed": false, "object": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "FindValueOperator", "range": [ 578, 595 ], "loc": { "start": { "line": 16, "column": 4 }, "end": { "line": 16, "column": 21 } } }, "property": { "type": "Identifier", "name": "prototype", "range": [ 596, 605 ], "loc": { "start": { "line": 16, "column": 22 }, "end": { "line": 16, "column": 31 } } }, "range": [ 578, 605 ], "loc": { "start": { "line": 16, "column": 4 }, "end": { "line": 16, "column": 31 } } }, "property": { "type": "Identifier", "name": "call", "range": [ 606, 610 ], "loc": { "start": { "line": 16, "column": 32 }, "end": { "line": 16, "column": 36 } } }, "range": [ 578, 610 ], "loc": { "start": { "line": 16, "column": 4 }, "end": { "line": 16, "column": 36 } } }, "right": { "type": "FunctionExpression", "id": null, "params": [ { "type": "Identifier", "name": "observer", "range": [ 623, 631 ], "loc": { "start": { "line": 16, "column": 49 }, "end": { "line": 16, "column": 57 } } }, { "type": "Identifier", "name": "source", "range": [ 633, 639 ], "loc": { "start": { "line": 16, "column": 59 }, "end": { "line": 16, "column": 65 } } } ], "body": { "type": "BlockStatement", "body": [ { "type": "ReturnStatement", "argument": { "type": "CallExpression", "callee": { "type": "MemberExpression", "computed": false, "object": { "type": "Identifier", "name": "source", "range": [ 658, 664 ], "loc": { "start": { "line": 17, "column": 15 }, "end": { "line": 17, "column": 21 } } }, "property": { "type": "Identifier", "name": "_subscribe", "range": [ 665, 675 ], "loc": { "start": { "line": 17, "column": 22 }, "end": { "line": 17, "column": 32 } } }, "range": [ 658, 675 ], "loc": { "start": { "line": 17, "column": 15 }, "end": { "line": 17, "column": 32 } } }, "arguments": [ { "type": "NewExpression", "callee": { "type": "Identifier", "name": "FindValueSubscriber", "range": [ 680, 699 ], "loc": { "start": { "line": 17, "column": 37 }, "end": { "line": 17, "column": 56 } } }, "arguments": [ { "type": "Identifier", "name": "observer", "range": [ 700, 7