diff --git a/.dart_tool/package_config.json b/.dart_tool/package_config.json index 4ab9d573d6a..953751e6417 100644 --- a/.dart_tool/package_config.json +++ b/.dart_tool/package_config.json @@ -556,6 +556,12 @@ "packageUri": "lib/", "languageVersion": "2.1" }, + { + "name": "sse", + "rootUri": "../third_party/pkg/sse", + "packageUri": "lib/", + "languageVersion": "2.6" + }, { "name": "stack_trace", "rootUri": "../third_party/pkg/stack_trace", @@ -586,6 +592,12 @@ "packageUri": "lib/", "languageVersion": "2.0" }, + { + "name": "sync_http", + "rootUri": "../third_party/pkg/sync_http", + "packageUri": "lib/", + "languageVersion": "2.6" + }, { "name": "telemetry", "rootUri": "../pkg/telemetry", @@ -694,6 +706,12 @@ "packageUri": "lib/", "languageVersion": "2.2" }, + { + "name": "webdriver", + "rootUri": "../third_party/pkg/webdriver", + "packageUri": "lib/", + "languageVersion": "2.6" + }, { "name": "web_components", "rootUri": "../third_party/pkg/web_components", @@ -713,4 +731,4 @@ "languageVersion": "2.4" } ] -} \ No newline at end of file +} diff --git a/.packages b/.packages index f1a7e2306d5..ee073a7fc86 100644 --- a/.packages +++ b/.packages @@ -92,11 +92,13 @@ source_map_stack_trace:third_party/pkg/source_map_stack_trace/lib sourcemap_testing:pkg/sourcemap_testing/lib source_maps:third_party/pkg/source_maps/lib source_span:third_party/pkg/source_span/lib +sse:third_party/pkg/sse/lib stack_trace:third_party/pkg/stack_trace/lib stagehand:third_party/pkg/stagehand/lib status_file:pkg/status_file/lib stream_channel:third_party/pkg/stream_channel/lib string_scanner:third_party/pkg/string_scanner/lib +sync_http:third_party/pkg/sync_http/lib telemetry:pkg/telemetry/lib term_glyph:third_party/pkg/term_glyph/lib test:third_party/pkg/test/pkgs/test/lib @@ -115,6 +117,7 @@ vm:pkg/vm/lib vm_service:pkg/vm_service/lib vm_snapshot_analysis:pkg/vm_snapshot_analysis/lib watcher:third_party/pkg/watcher/lib +webdriver:third_party/pkg/webdriver/lib web_components:third_party/pkg/web_components/lib web_socket_channel:third_party/pkg/web_socket_channel/lib yaml:third_party/pkg/yaml/lib diff --git a/DEPS b/DEPS index 8ef3a8157ba..1e5bee094f6 100644 --- a/DEPS +++ b/DEPS @@ -96,6 +96,7 @@ vars = { # For more details, see https://github.com/dart-lang/sdk/issues/30164 "dart_style_tag": "1.3.6", # Please see the note above before updating. + "chromedriver_tag": "83.0.4103.39", "dartdoc_tag" : "v0.32.2", "ffi_rev": "454ab0f9ea6bd06942a983238d8a6818b1357edb", "fixnum_rev": "9b38f49f6679654d66a363e69e48173cca07e882", @@ -142,10 +143,12 @@ vars = { "source_maps-0.9.4_rev": "38524", "source_maps_rev": "87b4fd9027378bbd51b02e9d7df794eee8a82b7a", "source_span_tag": "1.7.0", + "sse_tag": "e5cf68975e8e87171a3dc297577aa073454a91dc", "stack_trace_tag": "56811dbb2530d823b764fe167ec335879a4adb32", "stagehand_tag": "v3.3.9", "stream_channel_tag": "70433d577be02c48cb16d72d65654f3b4d82c6ed", "string_scanner_rev": "a918e7371af6b6e73bfd534ff9da6084741c1f99", + "sync_http_rev": "a85d7ec764ea485cbbc49f3f3e7f1b43f87a1c74", "test_descriptor_tag": "1.1.1", "test_process_tag": "1.0.3", "term_glyph_rev": "b3da31e9684a99cfe5f192b89914492018b44da7", @@ -156,6 +159,7 @@ vars = { "usage_tag": "3.4.0", "vector_math_rev": "90631fbb609f61d42f28621253c0ec9fc6a326d2", "watcher_rev": "fc3c9aae5d31d707b3013b42634dde8d8a1161b4", + "webdriver_rev": "5a8d6805d9cf8a3cbb4fcd64849b538b7491e50e", "web_components_rev": "8f57dac273412a7172c8ade6f361b407e2e4ed02", "web_socket_channel_rev": "490061ef0e22d3c8460ad2802f9948219365ad6b", "WebCore_rev": "fb11e887f77919450e497344da570d780e078bc8", @@ -408,6 +412,8 @@ deps = { Var("dart_root") + "/third_party/pkg/source_map_stack_trace": Var("dart_git") + "source_map_stack_trace.git" + "@" + Var("source_map_stack_trace_tag"), + Var("dart_root") + "/third_party/pkg/sse": + Var("dart_git") + "sse.git" + "@" + Var("sse_tag"), Var("dart_root") + "/third_party/pkg/stack_trace": Var("dart_git") + "stack_trace.git" + "@" + Var("stack_trace_tag"), Var("dart_root") + "/third_party/pkg/stagehand": @@ -418,6 +424,8 @@ deps = { Var("dart_root") + "/third_party/pkg/string_scanner": Var("dart_git") + "string_scanner.git" + "@" + Var("string_scanner_rev"), + Var("dart_root") + "/third_party/pkg/sync_http": + Var("dart_git") + "sync_http.git" + "@" + Var("sync_http_rev"), Var("dart_root") + "/third_party/pkg/term_glyph": Var("dart_git") + "term_glyph.git" + "@" + Var("term_glyph_rev"), Var("dart_root") + "/third_party/pkg/test": @@ -443,6 +451,10 @@ deps = { Var("dart_root") + "/third_party/pkg/web_components": Var("dart_git") + "web-components.git" + "@" + Var("web_components_rev"), + Var("dart_root") + "/third_party/pkg/webdriver": + Var("dart_git") + "external/github.com/google/webdriver.dart.git" + + "@" + Var("webdriver_rev"), + Var("dart_root") + "/third_party/pkg/web_socket_channel": Var("dart_git") + "web_socket_channel.git" + "@" + Var("web_socket_channel_rev"), @@ -460,6 +472,17 @@ deps = { "dep_type": "cipd", }, + Var("dart_root") + "/third_party/webdriver/chrome": { + "packages": [ + { + "package": "dart/third_party/chromedriver/${{platform}}", + "version": "version:" + Var("chromedriver_tag"), + } + ], + "condition": "host_cpu == 'x64'", + "dep_type": "cipd", + }, + Var("dart_root") + "/pkg/analysis_server/language_model": { "packages": [ { diff --git a/pkg/dds/CHANGELOG.md b/pkg/dds/CHANGELOG.md index c4725eacda6..7970319b623 100644 --- a/pkg/dds/CHANGELOG.md +++ b/pkg/dds/CHANGELOG.md @@ -1,3 +1,7 @@ +# 1.3.0 + +- Added support for SSE connections from web-based clients. + # 1.2.4 - Fixed another issue where a `StateError` could be raised within `DartDevelopmentService` diff --git a/pkg/dds/README.md b/pkg/dds/README.md index 64b0c72c99a..ec3567b0c96 100644 --- a/pkg/dds/README.md +++ b/pkg/dds/README.md @@ -2,7 +2,35 @@ A package used to spawn the Dart Developer Service (DDS), which is used to commu # Functionality -Existing VM Service clients can issue both HTTP and websocket requests to a running DDS instance as if it were an instance of the VM Service itself. If a request corresponds to an RPC defined in the [VM Service Protocol][service-protocol], DDS will forward the request and return the response from the VM Service. Requests corresponding to an RPC defined in the [DDS Protocol][dds-protocol] will be handled directly by the DDS instance. +Existing VM Service clients can issue both HTTP, websocket, and SSE requests to a running DDS instance as if it were an instance of the VM Service itself. If a request corresponds to an RPC defined in the [VM Service Protocol][service-protocol], DDS will forward the request and return the response from the VM Service. Requests corresponding to an RPC defined in the [DDS Protocol][dds-protocol] will be handled directly by the DDS instance. + +# SSE Support + +For certain web clients it may be preferrable or required to communicate with DDS using server-sent events (SSE). DDS has a SSE handler listening for requests on `/$debugHandler`. + +## SSE and package:vm_service example + +```dart +import 'package:sse/sse.dart'; +import 'package:vm_service/vm_service.dart'; + +void main() { + // Establish connection with DDS using SSE. + final ddsChannel = SseClient('${ddsUri}\$debugHandler'); + + // Wait for ddsChannel to be established + await ddsChannel.onOpen.first; + + // Initialize VmService using the sink and stream from ddsChannel. + final vmService = VmService( + ddsChannel.stream, + (e) => ddsChannel.sink.add(e), + ); + + // You're ready to query DDS and the VM service! + print(await vmService.getVersion()); +} +``` [dds-protocol]: dds_protocol.md [service-protocol]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md diff --git a/pkg/dds/lib/dds.dart b/pkg/dds/lib/dds.dart index 90461e60dfc..f9c057cf96d 100644 --- a/pkg/dds/lib/dds.dart +++ b/pkg/dds/lib/dds.dart @@ -21,6 +21,7 @@ import 'package:shelf/shelf.dart'; import 'package:shelf/shelf_io.dart' as io; import 'package:shelf_proxy/shelf_proxy.dart'; import 'package:shelf_web_socket/shelf_web_socket.dart'; +import 'package:sse/server/sse_handler.dart'; import 'package:stream_channel/stream_channel.dart'; import 'package:web_socket_channel/web_socket_channel.dart'; @@ -110,6 +111,12 @@ abstract class DartDevelopmentService { /// Returns `null` if the service is not running. Uri get uri; + /// The [Uri] VM service clients can use to communicate with this + /// [DartDevelopmentService] via server-sent events (SSE). + /// + /// Returns `null` if the service is not running. + Uri get sseUri; + /// The [Uri] VM service clients can use to communicate with this /// [DartDevelopmentService] via a [WebSocket]. /// diff --git a/pkg/dds/lib/src/client.dart b/pkg/dds/lib/src/client.dart index 40991286cad..3d796fc52ab 100644 --- a/pkg/dds/lib/src/client.dart +++ b/pkg/dds/lib/src/client.dart @@ -7,24 +7,46 @@ part of dds; /// Representation of a single DDS client which manages the connection and /// DDS request intercepting / forwarding. class _DartDevelopmentServiceClient { - _DartDevelopmentServiceClient( + factory _DartDevelopmentServiceClient.fromWebSocket( + DartDevelopmentService dds, + WebSocketChannel ws, + json_rpc.Peer vmServicePeer, + ) => + _DartDevelopmentServiceClient._( + dds, + ws, + vmServicePeer, + ); + + factory _DartDevelopmentServiceClient.fromSSEConnection( + DartDevelopmentService dds, + SseConnection sse, + json_rpc.Peer vmServicePeer, + ) => + _DartDevelopmentServiceClient._( + dds, + sse, + vmServicePeer, + ); + + _DartDevelopmentServiceClient._( this.dds, - this.ws, + this.connection, json_rpc.Peer vmServicePeer, ) : _vmServicePeer = vmServicePeer { _clientPeer = json_rpc.Peer( // Manually create a StreamChannel instead of calling - // ws.cast() as cast() results in addStream() being called, + // .cast() as cast() results in addStream() being called, // binding the underlying sink. This results in a StateError being thrown // if we try and add directly to the sink, which we do for binary events // in _StreamManager's streamNotify(). StreamChannel( - ws.stream.cast(), + connection.stream.cast(), StreamController(sync: true) ..stream .cast() - .listen((event) => ws.sink.add(event)) - .onDone(() => ws.sink.close()), + .listen((event) => connection.sink.add(event)) + .onDone(() => connection.sink.close()), ), strictProtocolChecks: false, ); @@ -231,8 +253,8 @@ class _DartDevelopmentServiceClient { String _name; final _DartDevelopmentService dds; + final StreamChannel connection; final Map services = {}; final json_rpc.Peer _vmServicePeer; - final WebSocketChannel ws; json_rpc.Peer _clientPeer; } diff --git a/pkg/dds/lib/src/dds_impl.dart b/pkg/dds/lib/src/dds_impl.dart index 221b2c9bbda..55e9e64c17f 100644 --- a/pkg/dds/lib/src/dds_impl.dart +++ b/pkg/dds/lib/src/dds_impl.dart @@ -139,10 +139,15 @@ class _DartDevelopmentService implements DartDevelopmentService { // Attempt to upgrade HTTP requests to a websocket before processing them as // standard HTTP requests. The websocket handler will fail quickly if the // request doesn't appear to be a websocket upgrade request. - Cascade _handlers() => Cascade().add(_webSocketHandler()).add(_httpHandler()); + Cascade _handlers() { + return Cascade() + .add(_webSocketHandler()) + .add(_sseHandler()) + .add(_httpHandler()); + } Handler _webSocketHandler() => webSocketHandler((WebSocketChannel ws) { - final client = _DartDevelopmentServiceClient( + final client = _DartDevelopmentServiceClient.fromWebSocket( this, ws, _vmServiceClient, @@ -150,6 +155,23 @@ class _DartDevelopmentService implements DartDevelopmentService { clientManager.addClient(client); }); + Handler _sseHandler() { + final handler = authCodesEnabled + ? SseHandler(Uri.parse('/$_authCode/$_kSseHandlerPath')) + : SseHandler(Uri.parse('/$_kSseHandlerPath')); + + handler.connections.rest.listen((sseConnection) { + final client = _DartDevelopmentServiceClient.fromSSEConnection( + this, + sseConnection, + _vmServiceClient, + ); + clientManager.addClient(client); + }); + + return handler.handler; + } + Handler _httpHandler() { // DDS doesn't support any HTTP requests itself, so we just forward all of // them to the VM service. @@ -157,10 +179,7 @@ class _DartDevelopmentService implements DartDevelopmentService { return cascade.handler; } - Uri _toWebSocket(Uri uri) { - if (uri == null) { - return null; - } + List _cleanupPathSegments(Uri uri) { final pathSegments = []; if (uri.pathSegments.isNotEmpty) { pathSegments.addAll(uri.pathSegments.where( @@ -170,10 +189,27 @@ class _DartDevelopmentService implements DartDevelopmentService { (s) => s.isNotEmpty, )); } + return pathSegments; + } + + Uri _toWebSocket(Uri uri) { + if (uri == null) { + return null; + } + final pathSegments = _cleanupPathSegments(uri); pathSegments.add('ws'); return uri.replace(scheme: 'ws', pathSegments: pathSegments); } + Uri _toSse(Uri uri) { + if (uri == null) { + return null; + } + final pathSegments = _cleanupPathSegments(uri); + pathSegments.add(_kSseHandlerPath); + return uri.replace(pathSegments: pathSegments); + } + String _getNamespace(_DartDevelopmentServiceClient client) => clientManager.clients.keyOf(client); @@ -186,6 +222,7 @@ class _DartDevelopmentService implements DartDevelopmentService { Uri _remoteVmServiceUri; Uri get uri => _uri; + Uri get sseUri => _toSse(_uri); Uri get wsUri => _toWebSocket(_uri); Uri _uri; @@ -210,6 +247,8 @@ class _DartDevelopmentService implements DartDevelopmentService { _StreamManager get streamManager => _streamManager; _StreamManager _streamManager; + static const _kSseHandlerPath = '\$debugHandler'; + json_rpc.Peer _vmServiceClient; WebSocketChannel _vmServiceSocket; HttpServer _server; diff --git a/pkg/dds/lib/src/stream_manager.dart b/pkg/dds/lib/src/stream_manager.dart index 45f9389ce1c..ea8aeaa9ad2 100644 --- a/pkg/dds/lib/src/stream_manager.dart +++ b/pkg/dds/lib/src/stream_manager.dart @@ -28,7 +28,7 @@ class _StreamManager { continue; } if (isBinaryData) { - listener.ws.sink.add(data); + listener.connection.sink.add(data); } else { listener.sendNotification('streamNotify', data); } diff --git a/pkg/dds/pubspec.yaml b/pkg/dds/pubspec.yaml index 73531268485..c96cca31105 100644 --- a/pkg/dds/pubspec.yaml +++ b/pkg/dds/pubspec.yaml @@ -3,7 +3,7 @@ description: >- A library used to spawn the Dart Developer Service, used to communicate with a Dart VM Service instance. -version: 1.2.4 +version: 1.3.0 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/dds @@ -18,9 +18,11 @@ dependencies: shelf: ^0.7.5 shelf_proxy: ^0.1.0+7 shelf_web_socket: ^0.2.3 + sse: ^3.5.0 stream_channel: ^2.0.0 web_socket_channel: ^1.1.0 dev_dependencies: test: ^1.0.0 vm_service: ^4.0.0 + webdriver: ^2.1.2 diff --git a/pkg/dds/test/smoke_test.dart b/pkg/dds/test/smoke_test.dart index 3b8cd7bd253..e7e5216ab78 100644 --- a/pkg/dds/test/smoke_test.dart +++ b/pkg/dds/test/smoke_test.dart @@ -27,49 +27,51 @@ void main() { process = null; }); - bool useAuthCodes = false; - for (int i = 0; i < 2; ++i) { - test('Smoke Test with ${useAuthCodes ? "" : "no "} authentication codes', - () async { - dds = await DartDevelopmentService.startDartDevelopmentService( - remoteVmServiceUri, - enableAuthCodes: useAuthCodes, - ); - expect(dds.isRunning, true); + void createSmokeTest(bool useAuthCodes) { + test( + 'Smoke Test with ${useAuthCodes ? "" : "no "} authentication codes', + () async { + dds = await DartDevelopmentService.startDartDevelopmentService( + remoteVmServiceUri, + enableAuthCodes: useAuthCodes, + ); + expect(dds.isRunning, true); - // Ensure basic websocket requests are forwarded correctly to the VM service. - final service = await vmServiceConnectUri(dds.wsUri.toString()); - final version = await service.getVersion(); - expect(version.major > 0, true); - expect(version.minor > 0, true); + // Ensure basic websocket requests are forwarded correctly to the VM service. + final service = await vmServiceConnectUri(dds.wsUri.toString()); + final version = await service.getVersion(); + expect(version.major > 0, true); + expect(version.minor > 0, true); - expect( - remoteVmServiceUri.pathSegments, - useAuthCodes ? isNotEmpty : isEmpty, - ); + expect( + dds.uri.pathSegments, + useAuthCodes ? isNotEmpty : isEmpty, + ); - // Ensure we can still make requests of the VM service via HTTP. - HttpClient client = HttpClient(); - final request = await client.getUrl(remoteVmServiceUri.replace( - pathSegments: [ - if (remoteVmServiceUri.pathSegments.isNotEmpty) - remoteVmServiceUri.pathSegments.first, - 'getVersion', - ], - )); - final response = await request.close(); - final Map jsonResponse = (await response - .transform(utf8.decoder) - .transform(json.decoder) - .single); - expect(jsonResponse['result']['type'], 'Version'); - expect(jsonResponse['result']['major'] > 0, true); - expect(jsonResponse['result']['minor'] > 0, true); - }); - - useAuthCodes = true; + // Ensure we can still make requests of the VM service via HTTP. + HttpClient client = HttpClient(); + final request = await client.getUrl(remoteVmServiceUri.replace( + pathSegments: [ + if (remoteVmServiceUri.pathSegments.isNotEmpty) + remoteVmServiceUri.pathSegments.first, + 'getVersion', + ], + )); + final response = await request.close(); + final Map jsonResponse = (await response + .transform(utf8.decoder) + .transform(json.decoder) + .single); + expect(jsonResponse['result']['type'], 'Version'); + expect(jsonResponse['result']['major'] > 0, true); + expect(jsonResponse['result']['minor'] > 0, true); + }, + ); } + createSmokeTest(true); + createSmokeTest(false); + test('startup fails when VM service has existing clients', () async { Uri httpToWebSocketUri(Uri httpUri) { final segments = (httpUri.pathSegments.isNotEmpty) diff --git a/pkg/dds/test/sse_smoke_test.dart b/pkg/dds/test/sse_smoke_test.dart new file mode 100644 index 00000000000..682fa18a5f8 --- /dev/null +++ b/pkg/dds/test/sse_smoke_test.dart @@ -0,0 +1,116 @@ +// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file +// for details. All rights reserved. Use of this source code is governed by a +// BSD-style license that can be found in the LICENSE file. + +import 'dart:async'; +import 'dart:convert'; +import 'dart:io'; + +import 'package:dds/dds.dart'; +import 'package:shelf/shelf.dart' as shelf; +import 'package:shelf/shelf_io.dart' as io; +import 'package:shelf_static/shelf_static.dart'; +import 'package:sse/server/sse_handler.dart'; +import 'package:test/test.dart'; +import 'package:vm_service/vm_service.dart' as service; +import 'package:webdriver/io.dart'; + +import 'common/test_helper.dart'; + +// NOTE: this test requires that Chrome is available via PATH or CHROME_PATH +// environment variables. + +void main() { + Process chromeDriver; + DartDevelopmentService dds; + SseHandler handler; + Process process; + HttpServer server; + WebDriver webdriver; + + setUpAll(() async { + final chromedriverUri = Platform.script.resolveUri( + Uri.parse('../../../third_party/webdriver/chrome/chromedriver')); + try { + chromeDriver = await Process.start(chromedriverUri.path, [ + '--port=4444', + '--url-base=wd/hub', + ]); + } catch (e) { + throw StateError( + 'Could not start ChromeDriver. Is it installed?\nError: $e'); + } + }); + + tearDownAll(() { + chromeDriver.kill(); + }); + + group('DDS', () { + setUp(() async { + process = await spawnDartProcess('smoke.dart'); + + handler = SseHandler(Uri.parse('/test')); + final cascade = shelf.Cascade() + .add(handler.handler) + .add(_faviconHandler) + .add(createStaticHandler(Platform.script.resolve('web').path, + listDirectories: true, defaultDocument: 'index.html')); + + server = await io.serve(cascade.handler, 'localhost', 0); + + final capabilities = Capabilities.chrome + ..addAll({ + Capabilities.chromeOptions: { + 'args': ['--headless'], + 'binary': Platform.environment['CHROME_PATH'] ?? '', + }, + }); + print('Capabilities: $capabilities'); + webdriver = await createDriver( + desired: capabilities, + ); + }); + + tearDown(() async { + await dds?.shutdown(); + process?.kill(); + await webdriver.quit(); + await server.close(); + dds = null; + process = null; + }); + + void createTest(bool useAuthCodes) { + test( + 'SSE Smoke Test with ${useAuthCodes ? "" : "no "}authentication codes', + () async { + dds = await DartDevelopmentService.startDartDevelopmentService( + remoteVmServiceUri, + serviceUri: Uri.parse('http://localhost:0'), + enableAuthCodes: useAuthCodes, + ); + expect(dds.isRunning, true); + await webdriver.get('http://localhost:${server.port}'); + final testeeConnection = await handler.connections.next; + testeeConnection.sink.add(dds.sseUri.toString()); + + final response = json.decode(await testeeConnection.stream.first); + final version = service.Version.parse(response); + expect(version.major > 0, isTrue); + expect(version.minor >= 0, isTrue); + }, + ); + } + + createTest(true); + createTest(false); + }); +} + +FutureOr _faviconHandler(shelf.Request request) { + if (request.url.path.endsWith('favicon.ico')) { + return shelf.Response.ok(''); + } + return shelf.Response.notFound(''); +} diff --git a/pkg/dds/test/uri_test.dart b/pkg/dds/test/uri_test.dart new file mode 100644 index 00000000000..8afd52371ab --- /dev/null +++ b/pkg/dds/test/uri_test.dart @@ -0,0 +1,88 @@ +// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file +// for details. All rights reserved. Use of this source code is governed by a +// BSD-style license that can be found in the LICENSE file. + +import 'dart:io'; + +import 'package:dds/dds.dart'; +import 'package:test/test.dart'; + +import 'common/test_helper.dart'; + +void main() { + Process process; + DartDevelopmentService dds; + setUp(() async { + process = await spawnDartProcess('smoke.dart'); + }); + + tearDown(() async { + await dds?.shutdown(); + process?.kill(); + dds = null; + process = null; + }); + + Future getAvailablePort() async { + final tmpServer = await HttpServer.bind(InternetAddress.loopbackIPv4, 0); + final port = tmpServer.port; + await tmpServer.close(); + return port; + } + + group('Ensure DDS URIs are consistent', () { + test('without authentication codes', () async { + final port = await getAvailablePort(); + final serviceUri = Uri.parse('http://127.0.0.1:$port/'); + dds = await DartDevelopmentService.startDartDevelopmentService( + remoteVmServiceUri, + serviceUri: serviceUri, + enableAuthCodes: false, + ); + + expect(dds.uri, serviceUri); + expect( + dds.sseUri, + serviceUri.replace( + pathSegments: ['\$debugHandler'], + ), + ); + expect( + dds.wsUri, + serviceUri.replace( + scheme: 'ws', + pathSegments: ['ws'], + ), + ); + }); + + test('with authentication codes', () async { + final port = await getAvailablePort(); + final serviceUri = Uri.parse('http://127.0.0.1:$port/'); + dds = await DartDevelopmentService.startDartDevelopmentService( + remoteVmServiceUri, + serviceUri: serviceUri, + ); + + // We need to pull the authentication code out of the main DDS URI, so + // just make sure that it's at the right address and port. + expect(dds.uri.toString().contains(serviceUri.toString()), isTrue); + + expect(dds.uri.pathSegments, isNotEmpty); + final authCode = dds.uri.pathSegments.first; + expect( + dds.sseUri, + serviceUri.replace( + pathSegments: [authCode, '\$debugHandler'], + ), + ); + expect( + dds.wsUri, + serviceUri.replace( + scheme: 'ws', + pathSegments: [authCode, 'ws'], + ), + ); + }); + }); +} diff --git a/pkg/dds/test/web/index.html b/pkg/dds/test/web/index.html new file mode 100644 index 00000000000..27d3952e97c --- /dev/null +++ b/pkg/dds/test/web/index.html @@ -0,0 +1,12 @@ + + + + + DDS SSE Smoke Test + + + + + + + \ No newline at end of file diff --git a/pkg/dds/test/web/sse_smoke_driver.dart b/pkg/dds/test/web/sse_smoke_driver.dart new file mode 100644 index 00000000000..66ef20c4f93 --- /dev/null +++ b/pkg/dds/test/web/sse_smoke_driver.dart @@ -0,0 +1,37 @@ +// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file +// for details. All rights reserved. Use of this source code is governed by a +// BSD-style license that can be found in the LICENSE file. + +// This file must be compiled for changes to be picked up. +// +// Run the following command from the root of this package if this file is +// updated: +// +// dart2js -o test/web/sse_smoke_driver.dart.js test/web/sse_smoke_driver.dart + +import 'dart:convert'; + +import 'package:async/async.dart'; +import 'package:sse/client/sse_client.dart'; +import 'package:vm_service/vm_service.dart'; + +Future main() async { + // Connect to test server + final channel = SseClient('/test'); + final testerStream = StreamQueue(channel.stream); + + // Connect to DDS + final ddsUri = await testerStream.next; + final ddsChannel = SseClient(ddsUri); + + // Wait for ddsChannel to be established. + await ddsChannel.onOpen.first; + + final vmService = VmService( + ddsChannel.stream, + (e) => ddsChannel.sink.add(e), + ); + final version = await vmService.getVersion(); + channel.sink.add(json.encode(version.json)); + ddsChannel.close(); +} diff --git a/pkg/dds/test/web/sse_smoke_driver.dart.js b/pkg/dds/test/web/sse_smoke_driver.dart.js new file mode 100644 index 00000000000..1fc97584079 --- /dev/null +++ b/pkg/dds/test/web/sse_smoke_driver.dart.js @@ -0,0 +1,14723 @@ +// Generated by dart2js (fast startup emitter, strong), the Dart to JavaScript compiler version: 2.9.0-edge.9d8087a399ebe62f6a93f21ec20f56d39dbcf1a2. +// The code supports the following hooks: +// dartPrint(message): +// if this function is defined it is called instead of the Dart [print] +// method. +// +// dartMainRunner(main, args): +// if this function is defined, the Dart [main] method will not be invoked +// directly. Instead, a closure that will invoke [main], and its arguments +// [args] is passed to [dartMainRunner]. +// +// dartDeferredLibraryLoader(uri, successCallback, errorCallback): +// if this function is defined, it will be called when a deferred library +// is loaded. It should load and eval the javascript of `uri`, and call +// successCallback. If it fails to do so, it should call errorCallback with +// an error. +// +// dartCallInstrumentation(id, qualifiedName): +// if this function is defined, it will be called at each entry of a +// method or constructor. Used only when compiling programs with +// --experiment-call-instrumentation. +(function dartProgram() { + function copyProperties(from, to) { + var keys = Object.keys(from); + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + to[key] = from[key]; + } + } + var supportsDirectProtoAccess = function() { + var cls = function() { + }; + cls.prototype = {p: {}}; + var object = new cls(); + if (!(object.__proto__ && object.__proto__.p === cls.prototype.p)) + return false; + try { + if (typeof navigator != "undefined" && typeof navigator.userAgent == "string" && navigator.userAgent.indexOf("Chrome/") >= 0) + return true; + if (typeof version == "function" && version.length == 0) { + var v = version(); + if (/^\d+\.\d+\.\d+\.\d+$/.test(v)) + return true; + } + } catch (_) { + } + return false; + }(); + function setFunctionNamesIfNecessary(holders) { + function t() { + } + ; + if (typeof t.name == "string") + return; + for (var i = 0; i < holders.length; i++) { + var holder = holders[i]; + var keys = Object.keys(holder); + for (var j = 0; j < keys.length; j++) { + var key = keys[j]; + var f = holder[key]; + if (typeof f == 'function') + f.name = key; + } + } + } + function inherit(cls, sup) { + cls.prototype.constructor = cls; + cls.prototype["$is" + cls.name] = cls; + if (sup != null) { + if (supportsDirectProtoAccess) { + cls.prototype.__proto__ = sup.prototype; + return; + } + var clsPrototype = Object.create(sup.prototype); + copyProperties(cls.prototype, clsPrototype); + cls.prototype = clsPrototype; + } + } + function inheritMany(sup, classes) { + for (var i = 0; i < classes.length; i++) + inherit(classes[i], sup); + } + function mixin(cls, mixin) { + copyProperties(mixin.prototype, cls.prototype); + cls.prototype.constructor = cls; + } + function lazy(holder, name, getterName, initializer) { + var uninitializedSentinel = holder; + holder[name] = uninitializedSentinel; + holder[getterName] = function() { + holder[getterName] = function() { + H.throwCyclicInit(name); + }; + var result; + var sentinelInProgress = initializer; + try { + if (holder[name] === uninitializedSentinel) { + result = holder[name] = sentinelInProgress; + result = holder[name] = initializer(); + } else + result = holder[name]; + } finally { + if (result === sentinelInProgress) + holder[name] = null; + holder[getterName] = function() { + return this[name]; + }; + } + return result; + }; + } + function makeConstList(list) { + list.immutable$list = Array; + list.fixed$length = Array; + return list; + } + function convertToFastObject(properties) { + function t() { + } + t.prototype = properties; + new t(); + return properties; + } + function convertAllToFastObject(arrayOfObjects) { + for (var i = 0; i < arrayOfObjects.length; ++i) + convertToFastObject(arrayOfObjects[i]); + } + var functionCounter = 0; + function tearOffGetter(funcs, applyTrampolineIndex, reflectionInfo, name, isIntercepted) { + return isIntercepted ? new Function("funcs", "applyTrampolineIndex", "reflectionInfo", "name", "H", "c", "return function tearOff_" + name + functionCounter++ + "(receiver) {" + "if (c === null) c = " + "H.closureFromTearOff" + "(" + "this, funcs, applyTrampolineIndex, reflectionInfo, false, true, name);" + "return new c(this, funcs[0], receiver, name);" + "}")(funcs, applyTrampolineIndex, reflectionInfo, name, H, null) : new Function("funcs", "applyTrampolineIndex", "reflectionInfo", "name", "H", "c", "return function tearOff_" + name + functionCounter++ + "() {" + "if (c === null) c = " + "H.closureFromTearOff" + "(" + "this, funcs, applyTrampolineIndex, reflectionInfo, false, false, name);" + "return new c(this, funcs[0], null, name);" + "}")(funcs, applyTrampolineIndex, reflectionInfo, name, H, null); + } + function tearOff(funcs, applyTrampolineIndex, reflectionInfo, isStatic, name, isIntercepted) { + var cache = null; + return isStatic ? function() { + if (cache === null) + cache = H.closureFromTearOff(this, funcs, applyTrampolineIndex, reflectionInfo, true, false, name).prototype; + return cache; + } : tearOffGetter(funcs, applyTrampolineIndex, reflectionInfo, name, isIntercepted); + } + var typesOffset = 0; + function installTearOff(container, getterName, isStatic, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) { + var funs = []; + for (var i = 0; i < funsOrNames.length; i++) { + var fun = funsOrNames[i]; + if (typeof fun == 'string') + fun = container[fun]; + fun.$callName = callNames[i]; + funs.push(fun); + } + var fun = funs[0]; + fun.$requiredArgCount = requiredParameterCount; + fun.$defaultValues = optionalParameterDefaultValues; + var reflectionInfo = funType; + if (typeof reflectionInfo == "number") + reflectionInfo += typesOffset; + var name = funsOrNames[0]; + fun.$stubName = name; + var getterFunction = tearOff(funs, applyIndex || 0, reflectionInfo, isStatic, name, isIntercepted); + container[getterName] = getterFunction; + if (isStatic) + fun.$tearOff = getterFunction; + } + function installStaticTearOff(container, getterName, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) { + return installTearOff(container, getterName, true, false, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex); + } + function installInstanceTearOff(container, getterName, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) { + return installTearOff(container, getterName, false, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex); + } + function setOrUpdateInterceptorsByTag(newTags) { + var tags = init.interceptorsByTag; + if (!tags) { + init.interceptorsByTag = newTags; + return; + } + copyProperties(newTags, tags); + } + function setOrUpdateLeafTags(newTags) { + var tags = init.leafTags; + if (!tags) { + init.leafTags = newTags; + return; + } + copyProperties(newTags, tags); + } + function updateTypes(newTypes) { + var types = init.types; + var length = types.length; + types.push.apply(types, newTypes); + return length; + } + function updateHolder(holder, newHolder) { + copyProperties(newHolder, holder); + return holder; + } + var hunkHelpers = function() { + var mkInstance = function(isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, applyIndex) { + return function(container, getterName, name, funType) { + return installInstanceTearOff(container, getterName, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, [name], funType, applyIndex); + }; + }, + mkStatic = function(requiredParameterCount, optionalParameterDefaultValues, callNames, applyIndex) { + return function(container, getterName, name, funType) { + return installStaticTearOff(container, getterName, requiredParameterCount, optionalParameterDefaultValues, callNames, [name], funType, applyIndex); + }; + }; + return {inherit: inherit, inheritMany: inheritMany, mixin: mixin, installStaticTearOff: installStaticTearOff, installInstanceTearOff: installInstanceTearOff, _instance_0u: mkInstance(0, 0, null, ["call$0"], 0), _instance_1u: mkInstance(0, 1, null, ["call$1"], 0), _instance_2u: mkInstance(0, 2, null, ["call$2"], 0), _instance_0i: mkInstance(1, 0, null, ["call$0"], 0), _instance_1i: mkInstance(1, 1, null, ["call$1"], 0), _instance_2i: mkInstance(1, 2, null, ["call$2"], 0), _static_0: mkStatic(0, null, ["call$0"], 0), _static_1: mkStatic(1, null, ["call$1"], 0), _static_2: mkStatic(2, null, ["call$2"], 0), makeConstList: makeConstList, lazy: lazy, updateHolder: updateHolder, convertToFastObject: convertToFastObject, setFunctionNamesIfNecessary: setFunctionNamesIfNecessary, updateTypes: updateTypes, setOrUpdateInterceptorsByTag: setOrUpdateInterceptorsByTag, setOrUpdateLeafTags: setOrUpdateLeafTags}; + }(); + function initializeDeferredHunk(hunk) { + typesOffset = init.types.length; + hunk(hunkHelpers, init, holders, $); + } + function getGlobalFromName(name) { + for (var i = 0; i < holders.length; i++) { + if (holders[i] == C) + continue; + if (holders[i][name]) + return holders[i][name]; + } + } + var C = {}, + H = {JS_CONST: function JS_CONST() { + }, + MappedIterable_MappedIterable: function(iterable, $function, $S, $T) { + if (type$.EfficientLengthIterable_dynamic._is(iterable)) + return new H.EfficientLengthMappedIterable(iterable, $function, $S._eval$1("@<0>")._bind$1($T)._eval$1("EfficientLengthMappedIterable<1,2>")); + return new H.MappedIterable(iterable, $function, $S._eval$1("@<0>")._bind$1($T)._eval$1("MappedIterable<1,2>")); + }, + IterableElementError_noElement: function() { + return new P.StateError("No element"); + }, + IterableElementError_tooFew: function() { + return new P.StateError("Too few elements"); + }, + EfficientLengthIterable: function EfficientLengthIterable() { + }, + ListIterable: function ListIterable() { + }, + ListIterator: function ListIterator(t0, t1, t2) { + var _ = this; + _._iterable = t0; + _.__internal$_length = t1; + _._index = 0; + _._current = null; + _.$ti = t2; + }, + MappedIterable: function MappedIterable(t0, t1, t2) { + this._iterable = t0; + this._f = t1; + this.$ti = t2; + }, + EfficientLengthMappedIterable: function EfficientLengthMappedIterable(t0, t1, t2) { + this._iterable = t0; + this._f = t1; + this.$ti = t2; + }, + MappedIterator: function MappedIterator(t0, t1, t2) { + var _ = this; + _._current = null; + _._iterator = t0; + _._f = t1; + _.$ti = t2; + }, + MappedListIterable: function MappedListIterable(t0, t1, t2) { + this.__internal$_source = t0; + this._f = t1; + this.$ti = t2; + }, + FixedLengthListMixin: function FixedLengthListMixin() { + }, + Symbol: function Symbol(t0) { + this.__internal$_name = t0; + }, + ConstantMap__throwUnmodifiable: function() { + throw H.wrapException(P.UnsupportedError$("Cannot modify unmodifiable Map")); + }, + unminifyOrTag: function(rawClassName) { + var preserved = H.unmangleGlobalNameIfPreservedAnyways(rawClassName); + if (preserved != null) + return preserved; + return rawClassName; + }, + isJsIndexable: function(object, record) { + var result; + if (record != null) { + result = record.x; + if (result != null) + return result; + } + return type$.JavaScriptIndexingBehavior_dynamic._is(object); + }, + S: function(value) { + var res; + if (typeof value == "string") + return value; + if (typeof value == "number") { + if (value !== 0) + return "" + value; + } else if (true === value) + return "true"; + else if (false === value) + return "false"; + else if (value == null) + return "null"; + res = J.toString$0$(value); + if (typeof res != "string") + throw H.wrapException(H.argumentErrorValue(value)); + return res; + }, + Primitives_objectHashCode: function(object) { + var hash = object.$identityHash; + if (hash == null) { + hash = Math.random() * 0x3fffffff | 0; + object.$identityHash = hash; + } + return hash; + }, + Primitives_parseInt: function(source, radix) { + var match, decimalMatch; + if (typeof source != "string") + H.throwExpression(H.argumentErrorValue(source)); + match = /^\s*[+-]?((0x[a-f0-9]+)|(\d+)|([a-z0-9]+))\s*$/i.exec(source); + if (match == null) + return null; + if (3 >= match.length) + return H.ioore(match, 3); + decimalMatch = match[3]; + if (decimalMatch != null) + return parseInt(source, 10); + if (match[2] != null) + return parseInt(source, 16); + return null; + }, + Primitives_objectTypeName: function(object) { + var t1 = H.Primitives__objectTypeNameNewRti(object); + return t1; + }, + Primitives__objectTypeNameNewRti: function(object) { + var dispatchName, $constructor, constructorName; + if (object instanceof P.Object) + return H._rtiToString(H.instanceType(object), null); + if (J.getInterceptor$(object) === C.Interceptor_methods || type$.UnknownJavaScriptObject._is(object)) { + dispatchName = C.C_JS_CONST(object); + if (H.Primitives__saneNativeClassName(dispatchName)) + return dispatchName; + $constructor = object.constructor; + if (typeof $constructor == "function") { + constructorName = $constructor.name; + if (typeof constructorName == "string" && H.Primitives__saneNativeClassName(constructorName)) + return constructorName; + } + } + return H._rtiToString(H.instanceType(object), null); + }, + Primitives__saneNativeClassName: function($name) { + var t1 = $name !== "Object" && $name !== ""; + return t1; + }, + Primitives__fromCharCodeApply: function(array) { + var result, i, i0, chunkEnd, + end = array.length; + if (end <= 500) + return String.fromCharCode.apply(null, array); + for (result = "", i = 0; i < end; i = i0) { + i0 = i + 500; + chunkEnd = i0 < end ? i0 : end; + result += String.fromCharCode.apply(null, array.slice(i, chunkEnd)); + } + return result; + }, + Primitives_stringFromCodePoints: function(codePoints) { + var t1, _i, i, + a = H.setRuntimeTypeInfo([], type$.JSArray_int); + for (t1 = codePoints.length, _i = 0; _i < codePoints.length; codePoints.length === t1 || (0, H.throwConcurrentModificationError)(codePoints), ++_i) { + i = codePoints[_i]; + if (!H._isInt(i)) + throw H.wrapException(H.argumentErrorValue(i)); + if (i <= 65535) + C.JSArray_methods.add$1(a, i); + else if (i <= 1114111) { + C.JSArray_methods.add$1(a, 55296 + (C.JSInt_methods._shrOtherPositive$1(i - 65536, 10) & 1023)); + C.JSArray_methods.add$1(a, 56320 + (i & 1023)); + } else + throw H.wrapException(H.argumentErrorValue(i)); + } + return H.Primitives__fromCharCodeApply(a); + }, + Primitives_stringFromCharCodes: function(charCodes) { + var t1, _i, i; + for (t1 = charCodes.length, _i = 0; _i < t1; ++_i) { + i = charCodes[_i]; + if (!H._isInt(i)) + throw H.wrapException(H.argumentErrorValue(i)); + if (i < 0) + throw H.wrapException(H.argumentErrorValue(i)); + if (i > 65535) + return H.Primitives_stringFromCodePoints(charCodes); + } + return H.Primitives__fromCharCodeApply(charCodes); + }, + Primitives_stringFromNativeUint8List: function(charCodes, start, end) { + var i, result, i0, chunkEnd; + if (end <= 500 && start === 0 && end === charCodes.length) + return String.fromCharCode.apply(null, charCodes); + for (i = start, result = ""; i < end; i = i0) { + i0 = i + 500; + chunkEnd = i0 < end ? i0 : end; + result += String.fromCharCode.apply(null, charCodes.subarray(i, chunkEnd)); + } + return result; + }, + Primitives_stringFromCharCode: function(charCode) { + var bits; + if (charCode <= 65535) + return String.fromCharCode(charCode); + if (charCode <= 1114111) { + bits = charCode - 65536; + return String.fromCharCode((55296 | C.JSInt_methods._shrOtherPositive$1(bits, 10)) >>> 0, 56320 | bits & 1023); + } + throw H.wrapException(P.RangeError$range(charCode, 0, 1114111, null, null)); + }, + Primitives_lazyAsJsDate: function(receiver) { + if (receiver.date === void 0) + receiver.date = new Date(receiver._value); + return receiver.date; + }, + Primitives_getYear: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCFullYear() + 0 : H.Primitives_lazyAsJsDate(receiver).getFullYear() + 0; + }, + Primitives_getMonth: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCMonth() + 1 : H.Primitives_lazyAsJsDate(receiver).getMonth() + 1; + }, + Primitives_getDay: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCDate() + 0 : H.Primitives_lazyAsJsDate(receiver).getDate() + 0; + }, + Primitives_getHours: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCHours() + 0 : H.Primitives_lazyAsJsDate(receiver).getHours() + 0; + }, + Primitives_getMinutes: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCMinutes() + 0 : H.Primitives_lazyAsJsDate(receiver).getMinutes() + 0; + }, + Primitives_getSeconds: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCSeconds() + 0 : H.Primitives_lazyAsJsDate(receiver).getSeconds() + 0; + }, + Primitives_getMilliseconds: function(receiver) { + return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCMilliseconds() + 0 : H.Primitives_lazyAsJsDate(receiver).getMilliseconds() + 0; + }, + Primitives_functionNoSuchMethod: function($function, positionalArguments, namedArguments) { + var $arguments, namedArgumentList, t1 = {}; + t1.argumentCount = 0; + $arguments = []; + namedArgumentList = []; + t1.argumentCount = positionalArguments.length; + C.JSArray_methods.addAll$1($arguments, positionalArguments); + t1.names = ""; + if (namedArguments != null && !namedArguments.get$isEmpty(namedArguments)) + namedArguments.forEach$1(0, new H.Primitives_functionNoSuchMethod_closure(t1, namedArgumentList, $arguments)); + "" + t1.argumentCount; + return J.noSuchMethod$1$($function, new H.JSInvocationMirror(C.Symbol_call, 0, $arguments, namedArgumentList, 0)); + }, + Primitives_applyFunction: function($function, positionalArguments, namedArguments) { + var t1, $arguments, argumentCount, jsStub; + if (positionalArguments instanceof Array) + t1 = namedArguments == null || namedArguments.get$isEmpty(namedArguments); + else + t1 = false; + if (t1) { + $arguments = positionalArguments; + argumentCount = $arguments.length; + if (argumentCount === 0) { + if (!!$function.call$0) + return $function.call$0(); + } else if (argumentCount === 1) { + if (!!$function.call$1) + return $function.call$1($arguments[0]); + } else if (argumentCount === 2) { + if (!!$function.call$2) + return $function.call$2($arguments[0], $arguments[1]); + } else if (argumentCount === 3) { + if (!!$function.call$3) + return $function.call$3($arguments[0], $arguments[1], $arguments[2]); + } else if (argumentCount === 4) { + if (!!$function.call$4) + return $function.call$4($arguments[0], $arguments[1], $arguments[2], $arguments[3]); + } else if (argumentCount === 5) + if (!!$function.call$5) + return $function.call$5($arguments[0], $arguments[1], $arguments[2], $arguments[3], $arguments[4]); + jsStub = $function["call" + "$" + argumentCount]; + if (jsStub != null) + return jsStub.apply($function, $arguments); + } + return H.Primitives__genericApplyFunction2($function, positionalArguments, namedArguments); + }, + Primitives__genericApplyFunction2: function($function, positionalArguments, namedArguments) { + var $arguments, argumentCount, requiredParameterCount, defaultValuesClosure, t1, defaultValues, interceptor, jsFunction, keys, _i, defaultValue, used, key; + if (positionalArguments != null) + $arguments = positionalArguments instanceof Array ? positionalArguments : P.List_List$from(positionalArguments, true, type$.dynamic); + else + $arguments = []; + argumentCount = $arguments.length; + requiredParameterCount = $function.$requiredArgCount; + if (argumentCount < requiredParameterCount) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + defaultValuesClosure = $function.$defaultValues; + t1 = defaultValuesClosure == null; + defaultValues = !t1 ? defaultValuesClosure() : null; + interceptor = J.getInterceptor$($function); + jsFunction = interceptor["call*"]; + if (typeof jsFunction == "string") + jsFunction = interceptor[jsFunction]; + if (t1) { + if (namedArguments != null && namedArguments.get$isNotEmpty(namedArguments)) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + if (argumentCount === requiredParameterCount) + return jsFunction.apply($function, $arguments); + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + } + if (defaultValues instanceof Array) { + if (namedArguments != null && namedArguments.get$isNotEmpty(namedArguments)) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + if (argumentCount > requiredParameterCount + defaultValues.length) + return H.Primitives_functionNoSuchMethod($function, $arguments, null); + C.JSArray_methods.addAll$1($arguments, defaultValues.slice(argumentCount - requiredParameterCount)); + return jsFunction.apply($function, $arguments); + } else { + if (argumentCount > requiredParameterCount) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + keys = Object.keys(defaultValues); + if (namedArguments == null) + for (t1 = keys.length, _i = 0; _i < keys.length; keys.length === t1 || (0, H.throwConcurrentModificationError)(keys), ++_i) { + defaultValue = defaultValues[H._asStringS(keys[_i])]; + if (C.C__Required === defaultValue) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + C.JSArray_methods.add$1($arguments, defaultValue); + } + else { + for (t1 = keys.length, used = 0, _i = 0; _i < keys.length; keys.length === t1 || (0, H.throwConcurrentModificationError)(keys), ++_i) { + key = H._asStringS(keys[_i]); + if (namedArguments.containsKey$1(key)) { + ++used; + C.JSArray_methods.add$1($arguments, namedArguments.$index(0, key)); + } else { + defaultValue = defaultValues[key]; + if (C.C__Required === defaultValue) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + C.JSArray_methods.add$1($arguments, defaultValue); + } + } + if (used !== namedArguments.get$length(namedArguments)) + return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments); + } + return jsFunction.apply($function, $arguments); + } + }, + iae: function(argument) { + throw H.wrapException(H.argumentErrorValue(argument)); + }, + ioore: function(receiver, index) { + if (receiver == null) + J.get$length$asx(receiver); + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + }, + diagnoseIndexError: function(indexable, index) { + var $length, t1, _s5_ = "index"; + if (!H._isInt(index)) + return new P.ArgumentError(true, index, _s5_, null); + $length = H._asIntS(J.get$length$asx(indexable)); + if (!(index < 0)) { + if (typeof $length !== "number") + return H.iae($length); + t1 = index >= $length; + } else + t1 = true; + if (t1) + return P.IndexError$(index, indexable, _s5_, null, $length); + return P.RangeError$value(index, _s5_); + }, + argumentErrorValue: function(object) { + return new P.ArgumentError(true, object, null, null); + }, + checkBool: function(value) { + return value; + }, + wrapException: function(ex) { + var wrapper, t1; + if (ex == null) + ex = new P.NullThrownError(); + wrapper = new Error(); + wrapper.dartException = ex; + t1 = H.toStringWrapper; + if ("defineProperty" in Object) { + Object.defineProperty(wrapper, "message", {get: t1}); + wrapper.name = ""; + } else + wrapper.toString = t1; + return wrapper; + }, + toStringWrapper: function() { + return J.toString$0$(this.dartException); + }, + throwExpression: function(ex) { + throw H.wrapException(ex); + }, + throwConcurrentModificationError: function(collection) { + throw H.wrapException(P.ConcurrentModificationError$(collection)); + }, + TypeErrorDecoder_extractPattern: function(message) { + var match, $arguments, argumentsExpr, expr, method, receiver; + message = H.quoteStringForRegExp(message.replace(String({}), '$receiver$')); + match = message.match(/\\\$[a-zA-Z]+\\\$/g); + if (match == null) + match = H.setRuntimeTypeInfo([], type$.JSArray_String); + $arguments = match.indexOf("\\$arguments\\$"); + argumentsExpr = match.indexOf("\\$argumentsExpr\\$"); + expr = match.indexOf("\\$expr\\$"); + method = match.indexOf("\\$method\\$"); + receiver = match.indexOf("\\$receiver\\$"); + return new H.TypeErrorDecoder(message.replace(new RegExp('\\\\\\$arguments\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$argumentsExpr\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$expr\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$method\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$receiver\\\\\\$', 'g'), '((?:x|[^x])*)'), $arguments, argumentsExpr, expr, method, receiver); + }, + TypeErrorDecoder_provokeCallErrorOn: function(expression) { + return function($expr$) { + var $argumentsExpr$ = '$arguments$'; + try { + $expr$.$method$($argumentsExpr$); + } catch (e) { + return e.message; + } + }(expression); + }, + TypeErrorDecoder_provokePropertyErrorOn: function(expression) { + return function($expr$) { + try { + $expr$.$method$; + } catch (e) { + return e.message; + } + }(expression); + }, + NullError$: function(_message, match) { + return new H.NullError(_message, match == null ? null : match.method); + }, + JsNoSuchMethodError$: function(_message, match) { + var t1 = match == null, + t2 = t1 ? null : match.method; + return new H.JsNoSuchMethodError(_message, t2, t1 ? null : match.receiver); + }, + unwrapException: function(ex) { + if (ex == null) + return new H.NullThrownFromJavaScriptException(ex); + if (ex instanceof H.ExceptionAndStackTrace) + return H.saveStackTrace(ex, ex.dartException); + if (typeof ex !== "object") + return ex; + if ("dartException" in ex) + return H.saveStackTrace(ex, ex.dartException); + return H._unwrapNonDartException(ex); + }, + saveStackTrace: function(ex, error) { + if (type$.Error._is(error)) + if (error.$thrownJsError == null) + error.$thrownJsError = ex; + return error; + }, + _unwrapNonDartException: function(ex) { + var message, number, ieErrorCode, nsme, notClosure, nullCall, nullLiteralCall, undefCall, undefLiteralCall, nullProperty, undefProperty, undefLiteralProperty, match, t1, _null = null; + if (!("message" in ex)) + return ex; + message = ex.message; + if ("number" in ex && typeof ex.number == "number") { + number = ex.number; + ieErrorCode = number & 65535; + if ((C.JSInt_methods._shrOtherPositive$1(number, 16) & 8191) === 10) + switch (ieErrorCode) { + case 438: + return H.saveStackTrace(ex, H.JsNoSuchMethodError$(H.S(message) + " (Error " + ieErrorCode + ")", _null)); + case 445: + case 5007: + return H.saveStackTrace(ex, H.NullError$(H.S(message) + " (Error " + ieErrorCode + ")", _null)); + } + } + if (ex instanceof TypeError) { + nsme = $.$get$TypeErrorDecoder_noSuchMethodPattern(); + notClosure = $.$get$TypeErrorDecoder_notClosurePattern(); + nullCall = $.$get$TypeErrorDecoder_nullCallPattern(); + nullLiteralCall = $.$get$TypeErrorDecoder_nullLiteralCallPattern(); + undefCall = $.$get$TypeErrorDecoder_undefinedCallPattern(); + undefLiteralCall = $.$get$TypeErrorDecoder_undefinedLiteralCallPattern(); + nullProperty = $.$get$TypeErrorDecoder_nullPropertyPattern(); + $.$get$TypeErrorDecoder_nullLiteralPropertyPattern(); + undefProperty = $.$get$TypeErrorDecoder_undefinedPropertyPattern(); + undefLiteralProperty = $.$get$TypeErrorDecoder_undefinedLiteralPropertyPattern(); + match = nsme.matchTypeError$1(message); + if (match != null) + return H.saveStackTrace(ex, H.JsNoSuchMethodError$(H._asStringS(message), match)); + else { + match = notClosure.matchTypeError$1(message); + if (match != null) { + match.method = "call"; + return H.saveStackTrace(ex, H.JsNoSuchMethodError$(H._asStringS(message), match)); + } else { + match = nullCall.matchTypeError$1(message); + if (match == null) { + match = nullLiteralCall.matchTypeError$1(message); + if (match == null) { + match = undefCall.matchTypeError$1(message); + if (match == null) { + match = undefLiteralCall.matchTypeError$1(message); + if (match == null) { + match = nullProperty.matchTypeError$1(message); + if (match == null) { + match = nullLiteralCall.matchTypeError$1(message); + if (match == null) { + match = undefProperty.matchTypeError$1(message); + if (match == null) { + match = undefLiteralProperty.matchTypeError$1(message); + t1 = match != null; + } else + t1 = true; + } else + t1 = true; + } else + t1 = true; + } else + t1 = true; + } else + t1 = true; + } else + t1 = true; + } else + t1 = true; + if (t1) + return H.saveStackTrace(ex, H.NullError$(H._asStringS(message), match)); + } + } + return H.saveStackTrace(ex, new H.UnknownJsTypeError(typeof message == "string" ? message : "")); + } + if (ex instanceof RangeError) { + if (typeof message == "string" && message.indexOf("call stack") !== -1) + return new P.StackOverflowError(); + message = function(ex) { + try { + return String(ex); + } catch (e) { + } + return null; + }(ex); + return H.saveStackTrace(ex, new P.ArgumentError(false, _null, _null, typeof message == "string" ? message.replace(/^RangeError:\s*/, "") : message)); + } + if (typeof InternalError == "function" && ex instanceof InternalError) + if (typeof message == "string" && message === "too much recursion") + return new P.StackOverflowError(); + return ex; + }, + getTraceFromException: function(exception) { + var trace; + if (exception instanceof H.ExceptionAndStackTrace) + return exception.stackTrace; + if (exception == null) + return new H._StackTrace(exception); + trace = exception.$cachedTrace; + if (trace != null) + return trace; + return exception.$cachedTrace = new H._StackTrace(exception); + }, + fillLiteralMap: function(keyValuePairs, result) { + var index, index0, index1, + $length = keyValuePairs.length; + for (index = 0; index < $length; index = index1) { + index0 = index + 1; + index1 = index0 + 1; + result.$indexSet(0, keyValuePairs[index], keyValuePairs[index0]); + } + return result; + }, + invokeClosure: function(closure, numberOfArguments, arg1, arg2, arg3, arg4) { + type$.Function._as(closure); + switch (H._asIntS(numberOfArguments)) { + case 0: + return closure.call$0(); + case 1: + return closure.call$1(arg1); + case 2: + return closure.call$2(arg1, arg2); + case 3: + return closure.call$3(arg1, arg2, arg3); + case 4: + return closure.call$4(arg1, arg2, arg3, arg4); + } + throw H.wrapException(P.Exception_Exception("Unsupported number of arguments for wrapped closure")); + }, + convertDartClosureToJS: function(closure, arity) { + var $function; + if (closure == null) + return null; + $function = closure.$identity; + if (!!$function) + return $function; + $function = function(closure, arity, invoke) { + return function(a1, a2, a3, a4) { + return invoke(closure, arity, a1, a2, a3, a4); + }; + }(closure, arity, H.invokeClosure); + closure.$identity = $function; + return $function; + }, + Closure_fromTearOff: function(receiver, functions, applyTrampolineIndex, reflectionInfo, isStatic, isIntercepted, propertyName) { + var $constructor, t1, trampoline, signatureFunction, applyTrampoline, i, stub, stubCallName, + $function = functions[0], + callName = $function.$callName, + $prototype = isStatic ? Object.create(new H.StaticClosure().constructor.prototype) : Object.create(new H.BoundClosure(null, null, null, "").constructor.prototype); + $prototype.$initialize = $prototype.constructor; + if (isStatic) + $constructor = function static_tear_off() { + this.$initialize(); + }; + else { + t1 = $.Closure_functionCounter; + if (typeof t1 !== "number") + return t1.$add(); + $.Closure_functionCounter = t1 + 1; + t1 = new Function("a,b,c,d" + t1, "this.$initialize(a,b,c,d" + t1 + ")"); + $constructor = t1; + } + $prototype.constructor = $constructor; + $constructor.prototype = $prototype; + if (!isStatic) { + trampoline = H.Closure_forwardCallTo(receiver, $function, isIntercepted); + trampoline.$reflectionInfo = reflectionInfo; + } else { + $prototype.$static_name = propertyName; + trampoline = $function; + } + signatureFunction = H.Closure__computeSignatureFunctionNewRti(reflectionInfo, isStatic, isIntercepted); + $prototype.$signature = signatureFunction; + $prototype[callName] = trampoline; + for (applyTrampoline = trampoline, i = 1; i < functions.length; ++i) { + stub = functions[i]; + stubCallName = stub.$callName; + if (stubCallName != null) { + stub = isStatic ? stub : H.Closure_forwardCallTo(receiver, stub, isIntercepted); + $prototype[stubCallName] = stub; + } + if (i === applyTrampolineIndex) { + stub.$reflectionInfo = reflectionInfo; + applyTrampoline = stub; + } + } + $prototype["call*"] = applyTrampoline; + $prototype.$requiredArgCount = $function.$requiredArgCount; + $prototype.$defaultValues = $function.$defaultValues; + return $constructor; + }, + Closure__computeSignatureFunctionNewRti: function(functionType, isStatic, isIntercepted) { + var typeEvalMethod; + if (typeof functionType == "number") + return function(getType, t) { + return function() { + return getType(t); + }; + }(H.getTypeFromTypesTable, functionType); + if (typeof functionType == "string") { + if (isStatic) + throw H.wrapException("Cannot compute signature for static tearoff."); + typeEvalMethod = isIntercepted ? H.BoundClosure_evalRecipeIntercepted : H.BoundClosure_evalRecipe; + return function(recipe, evalOnReceiver) { + return function() { + return evalOnReceiver(this, recipe); + }; + }(functionType, typeEvalMethod); + } + throw H.wrapException("Error in functionType of tearoff"); + }, + Closure_cspForwardCall: function(arity, isSuperCall, stubName, $function) { + var getSelf = H.BoundClosure_selfOf; + switch (isSuperCall ? -1 : arity) { + case 0: + return function(n, S) { + return function() { + return S(this)[n](); + }; + }(stubName, getSelf); + case 1: + return function(n, S) { + return function(a) { + return S(this)[n](a); + }; + }(stubName, getSelf); + case 2: + return function(n, S) { + return function(a, b) { + return S(this)[n](a, b); + }; + }(stubName, getSelf); + case 3: + return function(n, S) { + return function(a, b, c) { + return S(this)[n](a, b, c); + }; + }(stubName, getSelf); + case 4: + return function(n, S) { + return function(a, b, c, d) { + return S(this)[n](a, b, c, d); + }; + }(stubName, getSelf); + case 5: + return function(n, S) { + return function(a, b, c, d, e) { + return S(this)[n](a, b, c, d, e); + }; + }(stubName, getSelf); + default: + return function(f, s) { + return function() { + return f.apply(s(this), arguments); + }; + }($function, getSelf); + } + }, + Closure_forwardCallTo: function(receiver, $function, isIntercepted) { + var stubName, arity, lookedUpFunction, t1, t2, selfName, $arguments; + if (isIntercepted) + return H.Closure_forwardInterceptedCallTo(receiver, $function); + stubName = $function.$stubName; + arity = $function.length; + lookedUpFunction = receiver[stubName]; + t1 = $function == null ? lookedUpFunction == null : $function === lookedUpFunction; + t2 = !t1 || arity >= 27; + if (t2) + return H.Closure_cspForwardCall(arity, !t1, stubName, $function); + if (arity === 0) { + t1 = $.Closure_functionCounter; + if (typeof t1 !== "number") + return t1.$add(); + $.Closure_functionCounter = t1 + 1; + selfName = "self" + t1; + return new Function("return function(){var " + selfName + " = this." + H.S(H.BoundClosure_selfFieldName()) + ";return " + selfName + "." + H.S(stubName) + "();}")(); + } + $arguments = "abcdefghijklmnopqrstuvwxyz".split("").splice(0, arity).join(","); + t1 = $.Closure_functionCounter; + if (typeof t1 !== "number") + return t1.$add(); + $.Closure_functionCounter = t1 + 1; + $arguments += t1; + return new Function("return function(" + $arguments + "){return this." + H.S(H.BoundClosure_selfFieldName()) + "." + H.S(stubName) + "(" + $arguments + ");}")(); + }, + Closure_cspForwardInterceptedCall: function(arity, isSuperCall, $name, $function) { + var getSelf = H.BoundClosure_selfOf, + getReceiver = H.BoundClosure_receiverOf; + switch (isSuperCall ? -1 : arity) { + case 0: + throw H.wrapException(H.RuntimeError$("Intercepted function with no arguments.")); + case 1: + return function(n, s, r) { + return function() { + return s(this)[n](r(this)); + }; + }($name, getSelf, getReceiver); + case 2: + return function(n, s, r) { + return function(a) { + return s(this)[n](r(this), a); + }; + }($name, getSelf, getReceiver); + case 3: + return function(n, s, r) { + return function(a, b) { + return s(this)[n](r(this), a, b); + }; + }($name, getSelf, getReceiver); + case 4: + return function(n, s, r) { + return function(a, b, c) { + return s(this)[n](r(this), a, b, c); + }; + }($name, getSelf, getReceiver); + case 5: + return function(n, s, r) { + return function(a, b, c, d) { + return s(this)[n](r(this), a, b, c, d); + }; + }($name, getSelf, getReceiver); + case 6: + return function(n, s, r) { + return function(a, b, c, d, e) { + return s(this)[n](r(this), a, b, c, d, e); + }; + }($name, getSelf, getReceiver); + default: + return function(f, s, r, a) { + return function() { + a = [r(this)]; + Array.prototype.push.apply(a, arguments); + return f.apply(s(this), a); + }; + }($function, getSelf, getReceiver); + } + }, + Closure_forwardInterceptedCallTo: function(receiver, $function) { + var stubName, arity, lookedUpFunction, t1, t2, $arguments, + selfField = H.BoundClosure_selfFieldName(), + receiverField = $.BoundClosure_receiverFieldNameCache; + if (receiverField == null) + receiverField = $.BoundClosure_receiverFieldNameCache = H.BoundClosure_computeFieldNamed("receiver"); + stubName = $function.$stubName; + arity = $function.length; + lookedUpFunction = receiver[stubName]; + t1 = $function == null ? lookedUpFunction == null : $function === lookedUpFunction; + t2 = !t1 || arity >= 28; + if (t2) + return H.Closure_cspForwardInterceptedCall(arity, !t1, stubName, $function); + if (arity === 1) { + t1 = "return function(){return this." + H.S(selfField) + "." + H.S(stubName) + "(this." + receiverField + ");"; + t2 = $.Closure_functionCounter; + if (typeof t2 !== "number") + return t2.$add(); + $.Closure_functionCounter = t2 + 1; + return new Function(t1 + t2 + "}")(); + } + $arguments = "abcdefghijklmnopqrstuvwxyz".split("").splice(0, arity - 1).join(","); + t1 = "return function(" + $arguments + "){return this." + H.S(selfField) + "." + H.S(stubName) + "(this." + receiverField + ", " + $arguments + ");"; + t2 = $.Closure_functionCounter; + if (typeof t2 !== "number") + return t2.$add(); + $.Closure_functionCounter = t2 + 1; + return new Function(t1 + t2 + "}")(); + }, + closureFromTearOff: function(receiver, functions, applyTrampolineIndex, reflectionInfo, isStatic, isIntercepted, $name) { + return H.Closure_fromTearOff(receiver, functions, applyTrampolineIndex, reflectionInfo, !!isStatic, !!isIntercepted, $name); + }, + BoundClosure_evalRecipe: function(closure, recipe) { + return H._Universe_evalInEnvironment(init.typeUniverse, H.instanceType(closure._self), recipe); + }, + BoundClosure_evalRecipeIntercepted: function(closure, recipe) { + return H._Universe_evalInEnvironment(init.typeUniverse, H.instanceType(closure._receiver), recipe); + }, + BoundClosure_selfOf: function(closure) { + return closure._self; + }, + BoundClosure_receiverOf: function(closure) { + return closure._receiver; + }, + BoundClosure_selfFieldName: function() { + var t1 = $.BoundClosure_selfFieldNameCache; + return t1 == null ? $.BoundClosure_selfFieldNameCache = H.BoundClosure_computeFieldNamed("self") : t1; + }, + BoundClosure_computeFieldNamed: function(fieldName) { + var t1, i, $name, + template = new H.BoundClosure("self", "target", "receiver", "name"), + names = J.JSArray_markFixedList(Object.getOwnPropertyNames(template), type$.dynamic); + for (t1 = names.length, i = 0; i < t1; ++i) { + $name = names[i]; + if (template[$name] === fieldName) + return $name; + } + throw H.wrapException(P.ArgumentError$("Field name " + fieldName + " not found.")); + }, + boolConversionCheck: function(value) { + if (value == null) + H.assertThrow("boolean expression must not be null"); + return value; + }, + assertThrow: function(message) { + throw H.wrapException(new H._AssertionError(message)); + }, + throwCyclicInit: function(staticName) { + throw H.wrapException(new P.CyclicInitializationError(staticName)); + }, + RuntimeError$: function(message) { + return new H.RuntimeError(message); + }, + getIsolateAffinityTag: function($name) { + return init.getIsolateTag($name); + }, + setRuntimeTypeInfo: function(target, rti) { + target[init.arrayRti] = rti; + return target; + }, + getRuntimeTypeInfo: function(target) { + if (target == null) + return null; + return target.$ti; + }, + getRuntimeTypeArguments: function(interceptor, object, substitutionName) { + return H.substitute(interceptor["$as" + H.S(substitutionName)], H.getRuntimeTypeInfo(object)); + }, + getRuntimeType: function(object) { + var rti = object instanceof H.Closure ? H.closureFunctionType(object) : null; + return H.createRuntimeType(rti == null ? H.instanceType(object) : rti); + }, + substitute: function(substitution, $arguments) { + if (substitution == null) + return $arguments; + substitution = substitution.apply(null, $arguments); + if (substitution == null) + return null; + if (Array.isArray(substitution)) + return substitution; + if (typeof substitution == "function") + return substitution.apply(null, $arguments); + return $arguments; + }, + computeSignature: function(signature, context, contextName) { + return signature.apply(context, H.getRuntimeTypeArguments(J.getInterceptor$(context), context, contextName)); + }, + defineProperty: function(obj, property, value) { + Object.defineProperty(obj, property, {value: value, enumerable: false, writable: true, configurable: true}); + }, + lookupAndCacheInterceptor: function(obj) { + var interceptor, interceptorClass, altTag, mark, t1, + tag = H._asStringS($.getTagFunction.call$1(obj)), + record = $.dispatchRecordsForInstanceTags[tag]; + if (record != null) { + Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true}); + return record.i; + } + interceptor = $.interceptorsForUncacheableTags[tag]; + if (interceptor != null) + return interceptor; + interceptorClass = init.interceptorsByTag[tag]; + if (interceptorClass == null) { + altTag = H._asStringQ($.alternateTagFunction.call$2(obj, tag)); + if (altTag != null) { + record = $.dispatchRecordsForInstanceTags[altTag]; + if (record != null) { + Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true}); + return record.i; + } + interceptor = $.interceptorsForUncacheableTags[altTag]; + if (interceptor != null) + return interceptor; + interceptorClass = init.interceptorsByTag[altTag]; + tag = altTag; + } + } + if (interceptorClass == null) + return null; + interceptor = interceptorClass.prototype; + mark = tag[0]; + if (mark === "!") { + record = H.makeLeafDispatchRecord(interceptor); + $.dispatchRecordsForInstanceTags[tag] = record; + Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true}); + return record.i; + } + if (mark === "~") { + $.interceptorsForUncacheableTags[tag] = interceptor; + return interceptor; + } + if (mark === "-") { + t1 = H.makeLeafDispatchRecord(interceptor); + Object.defineProperty(Object.getPrototypeOf(obj), init.dispatchPropertyName, {value: t1, enumerable: false, writable: true, configurable: true}); + return t1.i; + } + if (mark === "+") + return H.patchInteriorProto(obj, interceptor); + if (mark === "*") + throw H.wrapException(P.UnimplementedError$(tag)); + if (init.leafTags[tag] === true) { + t1 = H.makeLeafDispatchRecord(interceptor); + Object.defineProperty(Object.getPrototypeOf(obj), init.dispatchPropertyName, {value: t1, enumerable: false, writable: true, configurable: true}); + return t1.i; + } else + return H.patchInteriorProto(obj, interceptor); + }, + patchInteriorProto: function(obj, interceptor) { + var proto = Object.getPrototypeOf(obj); + Object.defineProperty(proto, init.dispatchPropertyName, {value: J.makeDispatchRecord(interceptor, proto, null, null), enumerable: false, writable: true, configurable: true}); + return interceptor; + }, + makeLeafDispatchRecord: function(interceptor) { + return J.makeDispatchRecord(interceptor, false, null, !!interceptor.$isJavaScriptIndexingBehavior); + }, + makeDefaultDispatchRecord: function(tag, interceptorClass, proto) { + var interceptor = interceptorClass.prototype; + if (init.leafTags[tag] === true) + return H.makeLeafDispatchRecord(interceptor); + else + return J.makeDispatchRecord(interceptor, proto, null, null); + }, + initNativeDispatch: function() { + if (true === $.initNativeDispatchFlag) + return; + $.initNativeDispatchFlag = true; + H.initNativeDispatchContinue(); + }, + initNativeDispatchContinue: function() { + var map, tags, fun, i, tag, proto, record, interceptorClass; + $.dispatchRecordsForInstanceTags = Object.create(null); + $.interceptorsForUncacheableTags = Object.create(null); + H.initHooks(); + map = init.interceptorsByTag; + tags = Object.getOwnPropertyNames(map); + if (typeof window != "undefined") { + window; + fun = function() { + }; + for (i = 0; i < tags.length; ++i) { + tag = tags[i]; + proto = $.prototypeForTagFunction.call$1(tag); + if (proto != null) { + record = H.makeDefaultDispatchRecord(tag, map[tag], proto); + if (record != null) { + Object.defineProperty(proto, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true}); + fun.prototype = proto; + } + } + } + } + for (i = 0; i < tags.length; ++i) { + tag = tags[i]; + if (/^[A-Za-z_]/.test(tag)) { + interceptorClass = map[tag]; + map["!" + tag] = interceptorClass; + map["~" + tag] = interceptorClass; + map["-" + tag] = interceptorClass; + map["+" + tag] = interceptorClass; + map["*" + tag] = interceptorClass; + } + } + }, + initHooks: function() { + var transformers, i, transformer, getTag, getUnknownTag, prototypeForTag, + hooks = C.C_JS_CONST0(); + hooks = H.applyHooksTransformer(C.C_JS_CONST1, H.applyHooksTransformer(C.C_JS_CONST2, H.applyHooksTransformer(C.C_JS_CONST3, H.applyHooksTransformer(C.C_JS_CONST3, H.applyHooksTransformer(C.C_JS_CONST4, H.applyHooksTransformer(C.C_JS_CONST5, H.applyHooksTransformer(C.C_JS_CONST6(C.C_JS_CONST), hooks))))))); + if (typeof dartNativeDispatchHooksTransformer != "undefined") { + transformers = dartNativeDispatchHooksTransformer; + if (typeof transformers == "function") + transformers = [transformers]; + if (transformers.constructor == Array) + for (i = 0; i < transformers.length; ++i) { + transformer = transformers[i]; + if (typeof transformer == "function") + hooks = transformer(hooks) || hooks; + } + } + getTag = hooks.getTag; + getUnknownTag = hooks.getUnknownTag; + prototypeForTag = hooks.prototypeForTag; + $.getTagFunction = new H.initHooks_closure(getTag); + $.alternateTagFunction = new H.initHooks_closure0(getUnknownTag); + $.prototypeForTagFunction = new H.initHooks_closure1(prototypeForTag); + }, + applyHooksTransformer: function(transformer, hooks) { + return transformer(hooks) || hooks; + }, + quoteStringForRegExp: function(string) { + if (/[[\]{}()*+?.\\^$|]/.test(string)) + return string.replace(/[[\]{}()*+?.\\^$|]/g, "\\$&"); + return string; + }, + ConstantMapView: function ConstantMapView(t0, t1) { + this._collection$_map = t0; + this.$ti = t1; + }, + ConstantMap: function ConstantMap() { + }, + ConstantMap_map_closure: function ConstantMap_map_closure(t0, t1, t2) { + this.$this = t0; + this.transform = t1; + this.result = t2; + }, + ConstantStringMap: function ConstantStringMap(t0, t1, t2, t3) { + var _ = this; + _._length = t0; + _._jsObject = t1; + _._keys = t2; + _.$ti = t3; + }, + _ConstantMapKeyIterable: function _ConstantMapKeyIterable(t0, t1) { + this._map = t0; + this.$ti = t1; + }, + JSInvocationMirror: function JSInvocationMirror(t0, t1, t2, t3, t4) { + var _ = this; + _._memberName = t0; + _.__js_helper$_kind = t1; + _._arguments = t2; + _._namedArgumentNames = t3; + _._typeArgumentCount = t4; + }, + Primitives_functionNoSuchMethod_closure: function Primitives_functionNoSuchMethod_closure(t0, t1, t2) { + this._box_0 = t0; + this.namedArgumentList = t1; + this.$arguments = t2; + }, + TypeErrorDecoder: function TypeErrorDecoder(t0, t1, t2, t3, t4, t5) { + var _ = this; + _._pattern = t0; + _._arguments = t1; + _._argumentsExpr = t2; + _._expr = t3; + _._method = t4; + _._receiver = t5; + }, + NullError: function NullError(t0, t1) { + this._message = t0; + this._method = t1; + }, + JsNoSuchMethodError: function JsNoSuchMethodError(t0, t1, t2) { + this._message = t0; + this._method = t1; + this._receiver = t2; + }, + UnknownJsTypeError: function UnknownJsTypeError(t0) { + this._message = t0; + }, + NullThrownFromJavaScriptException: function NullThrownFromJavaScriptException(t0) { + this._irritant = t0; + }, + ExceptionAndStackTrace: function ExceptionAndStackTrace(t0, t1) { + this.dartException = t0; + this.stackTrace = t1; + }, + _StackTrace: function _StackTrace(t0) { + this._exception = t0; + this._trace = null; + }, + Closure: function Closure() { + }, + TearOffClosure: function TearOffClosure() { + }, + StaticClosure: function StaticClosure() { + }, + BoundClosure: function BoundClosure(t0, t1, t2, t3) { + var _ = this; + _._self = t0; + _.__js_helper$_target = t1; + _._receiver = t2; + _._name = t3; + }, + RuntimeError: function RuntimeError(t0) { + this.message = t0; + }, + _AssertionError: function _AssertionError(t0) { + this.message = t0; + }, + _Required: function _Required() { + }, + JsLinkedHashMap: function JsLinkedHashMap(t0) { + var _ = this; + _._length = 0; + _._last = _._first = _.__js_helper$_rest = _._nums = _._strings = null; + _._modifications = 0; + _.$ti = t0; + }, + JsLinkedHashMap_addAll_closure: function JsLinkedHashMap_addAll_closure(t0) { + this.$this = t0; + }, + LinkedHashMapCell: function LinkedHashMapCell(t0, t1) { + var _ = this; + _.hashMapCellKey = t0; + _.hashMapCellValue = t1; + _._previous = _._next = null; + }, + LinkedHashMapKeyIterable: function LinkedHashMapKeyIterable(t0, t1) { + this._map = t0; + this.$ti = t1; + }, + LinkedHashMapKeyIterator: function LinkedHashMapKeyIterator(t0, t1, t2) { + var _ = this; + _._map = t0; + _._modifications = t1; + _.__js_helper$_current = _._cell = null; + _.$ti = t2; + }, + initHooks_closure: function initHooks_closure(t0) { + this.getTag = t0; + }, + initHooks_closure0: function initHooks_closure0(t0) { + this.getUnknownTag = t0; + }, + initHooks_closure1: function initHooks_closure1(t0) { + this.prototypeForTag = t0; + }, + _checkViewArguments: function(buffer, offsetInBytes, $length) { + }, + _ensureNativeList: function(list) { + var t1, result, i; + if (type$.JSIndexable_dynamic._is(list)) + return list; + t1 = J.getInterceptor$asx(list); + result = P.List_List$filled(t1.get$length(list), null, false, type$.dynamic); + for (i = 0; i < t1.get$length(list); ++i) + C.JSArray_methods.$indexSet(result, i, t1.$index(list, i)); + return result; + }, + NativeByteData_NativeByteData$view: function(buffer, offsetInBytes, $length) { + H._checkViewArguments(buffer, offsetInBytes, $length); + return $length == null ? new DataView(buffer, offsetInBytes) : new DataView(buffer, offsetInBytes, $length); + }, + _checkValidIndex: function(index, list, $length) { + if (index >>> 0 !== index || index >= $length) + throw H.wrapException(H.diagnoseIndexError(list, index)); + }, + NativeByteBuffer: function NativeByteBuffer() { + }, + NativeTypedData: function NativeTypedData() { + }, + NativeByteData: function NativeByteData() { + }, + NativeTypedArray: function NativeTypedArray() { + }, + NativeTypedArrayOfDouble: function NativeTypedArrayOfDouble() { + }, + NativeTypedArrayOfInt: function NativeTypedArrayOfInt() { + }, + NativeFloat32List: function NativeFloat32List() { + }, + NativeFloat64List: function NativeFloat64List() { + }, + NativeInt16List: function NativeInt16List() { + }, + NativeInt32List: function NativeInt32List() { + }, + NativeInt8List: function NativeInt8List() { + }, + NativeUint16List: function NativeUint16List() { + }, + NativeUint32List: function NativeUint32List() { + }, + NativeUint8ClampedList: function NativeUint8ClampedList() { + }, + NativeUint8List: function NativeUint8List() { + }, + _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin: function _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin() { + }, + _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin: function _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin() { + }, + _NativeTypedArrayOfInt_NativeTypedArray_ListMixin: function _NativeTypedArrayOfInt_NativeTypedArray_ListMixin() { + }, + _NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin: function _NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin() { + }, + Rti__getQuestionFromStar: function(universe, rti) { + var question = rti._precomputed1; + return question == null ? rti._precomputed1 = H._Universe__lookupQuestionRti(universe, rti._primary, true) : question; + }, + Rti__getFutureFromFutureOr: function(universe, rti) { + var future = rti._precomputed1; + return future == null ? rti._precomputed1 = H._Universe__lookupInterfaceRti(universe, "Future", [rti._primary]) : future; + }, + Rti__isUnionOfFunctionType: function(rti) { + var kind = rti._kind; + if (kind === 6 || kind === 7 || kind === 8) + return H.Rti__isUnionOfFunctionType(rti._primary); + return kind === 11 || kind === 12; + }, + Rti__getCanonicalRecipe: function(rti) { + return rti._canonicalRecipe; + }, + findType: function(recipe) { + return H._Universe_eval(init.typeUniverse, recipe, false); + }, + _substitute: function(universe, rti, typeArguments, depth) { + var baseType, substitutedBaseType, interfaceTypeArguments, substitutedInterfaceTypeArguments, base, substitutedBase, $arguments, substitutedArguments, returnType, substitutedReturnType, functionParameters, substitutedFunctionParameters, bounds, substitutedBounds, index, argument, + kind = rti._kind; + switch (kind) { + case 5: + case 1: + case 2: + case 3: + case 4: + return rti; + case 6: + baseType = rti._primary; + substitutedBaseType = H._substitute(universe, baseType, typeArguments, depth); + if (substitutedBaseType === baseType) + return rti; + return H._Universe__lookupStarRti(universe, substitutedBaseType, true); + case 7: + baseType = rti._primary; + substitutedBaseType = H._substitute(universe, baseType, typeArguments, depth); + if (substitutedBaseType === baseType) + return rti; + return H._Universe__lookupQuestionRti(universe, substitutedBaseType, true); + case 8: + baseType = rti._primary; + substitutedBaseType = H._substitute(universe, baseType, typeArguments, depth); + if (substitutedBaseType === baseType) + return rti; + return H._Universe__lookupFutureOrRti(universe, substitutedBaseType, true); + case 9: + interfaceTypeArguments = rti._rest; + substitutedInterfaceTypeArguments = H._substituteArray(universe, interfaceTypeArguments, typeArguments, depth); + if (substitutedInterfaceTypeArguments === interfaceTypeArguments) + return rti; + return H._Universe__lookupInterfaceRti(universe, rti._primary, substitutedInterfaceTypeArguments); + case 10: + base = rti._primary; + substitutedBase = H._substitute(universe, base, typeArguments, depth); + $arguments = rti._rest; + substitutedArguments = H._substituteArray(universe, $arguments, typeArguments, depth); + if (substitutedBase === base && substitutedArguments === $arguments) + return rti; + return H._Universe__lookupBindingRti(universe, substitutedBase, substitutedArguments); + case 11: + returnType = rti._primary; + substitutedReturnType = H._substitute(universe, returnType, typeArguments, depth); + functionParameters = rti._rest; + substitutedFunctionParameters = H._substituteFunctionParameters(universe, functionParameters, typeArguments, depth); + if (substitutedReturnType === returnType && substitutedFunctionParameters === functionParameters) + return rti; + return H._Universe__lookupFunctionRti(universe, substitutedReturnType, substitutedFunctionParameters); + case 12: + bounds = rti._rest; + depth += bounds.length; + substitutedBounds = H._substituteArray(universe, bounds, typeArguments, depth); + base = rti._primary; + substitutedBase = H._substitute(universe, base, typeArguments, depth); + if (substitutedBounds === bounds && substitutedBase === base) + return rti; + return H._Universe__lookupGenericFunctionRti(universe, substitutedBase, substitutedBounds, true); + case 13: + index = rti._primary; + if (index < depth) + return rti; + argument = typeArguments[index - depth]; + if (argument == null) + return rti; + return argument; + default: + throw H.wrapException(P.AssertionError$("Attempted to substitute unexpected RTI kind " + kind)); + } + }, + _substituteArray: function(universe, rtiArray, typeArguments, depth) { + var changed, i, rti, substitutedRti, + $length = rtiArray.length, + result = []; + for (changed = false, i = 0; i < $length; ++i) { + rti = rtiArray[i]; + substitutedRti = H._substitute(universe, rti, typeArguments, depth); + if (substitutedRti !== rti) + changed = true; + result.push(substitutedRti); + } + return changed ? result : rtiArray; + }, + _substituteNamed: function(universe, namedArray, typeArguments, depth) { + var changed, i, t1, t2, rti, substitutedRti, + $length = namedArray.length, + result = []; + for (changed = false, i = 0; i < $length; i += 3) { + t1 = namedArray[i]; + t2 = namedArray[i + 1]; + rti = namedArray[i + 2]; + substitutedRti = H._substitute(universe, rti, typeArguments, depth); + if (substitutedRti !== rti) + changed = true; + result.push(t1); + result.push(t2); + result.push(substitutedRti); + } + return changed ? result : namedArray; + }, + _substituteFunctionParameters: function(universe, functionParameters, typeArguments, depth) { + var result, + requiredPositional = functionParameters._requiredPositional, + substitutedRequiredPositional = H._substituteArray(universe, requiredPositional, typeArguments, depth), + optionalPositional = functionParameters._optionalPositional, + substitutedOptionalPositional = H._substituteArray(universe, optionalPositional, typeArguments, depth), + named = functionParameters._named, + substitutedNamed = H._substituteNamed(universe, named, typeArguments, depth); + if (substitutedRequiredPositional === requiredPositional && substitutedOptionalPositional === optionalPositional && substitutedNamed === named) + return functionParameters; + result = new H._FunctionParameters(); + result._requiredPositional = substitutedRequiredPositional; + result._optionalPositional = substitutedOptionalPositional; + result._named = substitutedNamed; + return result; + }, + closureFunctionType: function(closure) { + var signature = closure.$signature; + if (signature != null) { + if (typeof signature == "number") + return H.getTypeFromTypesTable(signature); + return closure.$signature(); + } + return null; + }, + instanceOrFunctionType: function(object, testRti) { + var rti; + if (H.Rti__isUnionOfFunctionType(testRti)) + if (object instanceof H.Closure) { + rti = H.closureFunctionType(object); + if (rti != null) + return rti; + } + return H.instanceType(object); + }, + instanceType: function(object) { + var rti; + if (object instanceof P.Object) { + rti = object.$ti; + return rti != null ? rti : H._instanceTypeFromConstructor(object); + } + if (Array.isArray(object)) + return H._arrayInstanceType(object); + return H._instanceTypeFromConstructor(J.getInterceptor$(object)); + }, + _arrayInstanceType: function(object) { + var rti = object[init.arrayRti], + defaultRti = type$.JSArray_dynamic; + if (rti == null) + return defaultRti; + if (rti.constructor !== defaultRti.constructor) + return defaultRti; + return rti; + }, + _instanceType: function(object) { + var rti = object.$ti; + return rti != null ? rti : H._instanceTypeFromConstructor(object); + }, + _instanceTypeFromConstructor: function(instance) { + var $constructor = instance.constructor, + probe = $constructor.$ccache; + if (probe != null) + return probe; + return H._instanceTypeFromConstructorMiss(instance, $constructor); + }, + _instanceTypeFromConstructorMiss: function(instance, $constructor) { + var effectiveConstructor = instance instanceof H.Closure ? instance.__proto__.__proto__.constructor : $constructor, + rti = H._Universe_findErasedType(init.typeUniverse, effectiveConstructor.name); + $constructor.$ccache = rti; + return rti; + }, + getTypeFromTypesTable: function(index) { + var table, type, rti; + H._asIntS(index); + table = init.types; + type = table[index]; + if (typeof type == "string") { + rti = H._Universe_eval(init.typeUniverse, type, false); + table[index] = rti; + return rti; + } + return type; + }, + createRuntimeType: function(rti) { + var recipe, starErasedRecipe, starErasedRti, + type = rti._cachedRuntimeType; + if (type != null) + return type; + recipe = rti._canonicalRecipe; + starErasedRecipe = recipe.replace(/\*/g, ""); + if (starErasedRecipe === recipe) + return rti._cachedRuntimeType = new H._Type(rti); + starErasedRti = H._Universe_eval(init.typeUniverse, starErasedRecipe, true); + type = starErasedRti._cachedRuntimeType; + return rti._cachedRuntimeType = type == null ? starErasedRti._cachedRuntimeType = new H._Type(starErasedRti) : type; + }, + typeLiteral: function(recipe) { + return H.createRuntimeType(H._Universe_eval(init.typeUniverse, recipe, false)); + }, + _installSpecializedIsTest: function(object) { + var unstarred, isFn, testRti = this, + t1 = type$.Object; + if (testRti === t1) + return H._finishIsFn(testRti, object, H._isObject); + if (!H.isStrongTopType(testRti)) + if (!(testRti === type$.legacy_Object)) + t1 = testRti === t1; + else + t1 = true; + else + t1 = true; + if (t1) + return H._finishIsFn(testRti, object, H._isTop); + t1 = testRti._kind; + unstarred = t1 === 6 ? testRti._primary : testRti; + if (unstarred === type$.int) + isFn = H._isInt; + else if (unstarred === type$.double || unstarred === type$.num) + isFn = H._isNum; + else if (unstarred === type$.String) + isFn = H._isString; + else + isFn = unstarred === type$.bool ? H._isBool : null; + if (isFn != null) + return H._finishIsFn(testRti, object, isFn); + if (unstarred._kind === 9) { + t1 = unstarred._primary; + if (unstarred._rest.every(H.isTopType)) { + testRti._specializedTestResource = "$is" + t1; + return H._finishIsFn(testRti, object, H._isTestViaProperty); + } + } else if (t1 === 7) + return H._finishIsFn(testRti, object, H._generalNullableIsTestImplementation); + return H._finishIsFn(testRti, object, H._generalIsTestImplementation); + }, + _finishIsFn: function(testRti, object, isFn) { + testRti._is = isFn; + return testRti._is(object); + }, + _installSpecializedAsCheck: function(object) { + var t1, asFn, testRti = this; + if (!H.isStrongTopType(testRti)) + if (!(testRti === type$.legacy_Object)) + t1 = testRti === type$.Object; + else + t1 = true; + else + t1 = true; + if (t1) + asFn = H._asTop; + else if (testRti === type$.Object) + asFn = H._asObject; + else + asFn = H._generalNullableAsCheckImplementation; + testRti._as = asFn; + return testRti._as(object); + }, + _nullIs: function(testRti) { + var t2, + t1 = testRti._kind; + if (!H.isStrongTopType(testRti)) + if (!(testRti === type$.legacy_Object)) + t2 = testRti === type$.Object; + else + t2 = true; + else + t2 = true; + return t2 || testRti === type$.legacy_Never || t1 === 7 || testRti === type$.Null || testRti === type$.JSNull; + }, + _generalIsTestImplementation: function(object) { + var testRti = this; + if (object == null) + return H._nullIs(testRti); + return H._isSubtype(init.typeUniverse, H.instanceOrFunctionType(object, testRti), null, testRti, null); + }, + _generalNullableIsTestImplementation: function(object) { + if (object == null) + return true; + return this._primary._is(object); + }, + _isTestViaProperty: function(object) { + var t1 = this, + tag = t1._specializedTestResource; + if (object instanceof P.Object) + return !!object[tag]; + return !!J.getInterceptor$(object)[tag]; + }, + _generalAsCheckImplementation: function(object) { + var testRti = this; + if (object == null) + return object; + else if (testRti._is(object)) + return object; + H._failedAsCheck(object, testRti); + }, + _generalNullableAsCheckImplementation: function(object) { + var testRti = this; + if (object == null) + return object; + else if (testRti._is(object)) + return object; + H._failedAsCheck(object, testRti); + }, + _failedAsCheck: function(object, testRti) { + throw H.wrapException(H._TypeError$fromMessage(H._Error_compose(object, H.instanceOrFunctionType(object, testRti), H._rtiToString(testRti, null)))); + }, + _Error_compose: function(object, objectRti, checkedTypeDescription) { + var objectDescription = P.Error_safeToString(object), + objectTypeDescription = H._rtiToString(objectRti == null ? H.instanceType(object) : objectRti, null); + return objectDescription + ": type '" + H.S(objectTypeDescription) + "' is not a subtype of type '" + H.S(checkedTypeDescription) + "'"; + }, + _TypeError$fromMessage: function(message) { + return new H._TypeError("TypeError: " + message); + }, + _TypeError__TypeError$forType: function(object, type) { + return new H._TypeError("TypeError: " + H._Error_compose(object, null, type)); + }, + _isObject: function(object) { + return object != null; + }, + _asObject: function(object) { + return object; + }, + _isTop: function(object) { + return true; + }, + _asTop: function(object) { + return object; + }, + _isBool: function(object) { + return true === object || false === object; + }, + _asBool: function(object) { + if (true === object || false === object) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "bool")); + }, + _asBoolS: function(object) { + if (true === object || false === object) + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "bool")); + }, + _asBoolQ: function(object) { + if (true === object || false === object) + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "bool?")); + }, + _asDouble: function(object) { + if (typeof object == "number") + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "double")); + }, + _asDoubleS: function(object) { + if (typeof object == "number") + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "double")); + }, + _asDoubleQ: function(object) { + if (typeof object == "number") + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "double?")); + }, + _isInt: function(object) { + return typeof object == "number" && Math.floor(object) === object; + }, + _asInt: function(object) { + if (typeof object == "number" && Math.floor(object) === object) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "int")); + }, + _asIntS: function(object) { + if (typeof object == "number" && Math.floor(object) === object) + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "int")); + }, + _asIntQ: function(object) { + if (typeof object == "number" && Math.floor(object) === object) + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "int?")); + }, + _isNum: function(object) { + return typeof object == "number"; + }, + _asNum: function(object) { + if (typeof object == "number") + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "num")); + }, + _asNumS: function(object) { + if (typeof object == "number") + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "num")); + }, + _asNumQ: function(object) { + if (typeof object == "number") + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "num?")); + }, + _isString: function(object) { + return typeof object == "string"; + }, + _asString: function(object) { + if (typeof object == "string") + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "String")); + }, + _asStringS: function(object) { + if (typeof object == "string") + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "String")); + }, + _asStringQ: function(object) { + if (typeof object == "string") + return object; + if (object == null) + return object; + throw H.wrapException(H._TypeError__TypeError$forType(object, "String?")); + }, + _rtiArrayToString: function(array, genericContext) { + var s, sep, i; + for (s = "", sep = "", i = 0; i < array.length; ++i, sep = ", ") + s += C.JSString_methods.$add(sep, H._rtiToString(array[i], genericContext)); + return s; + }, + _functionRtiToString: function(functionType, genericContext, bounds) { + var boundsLength, outerContextLength, offset, i, t1, t2, t3, typeParametersText, typeSep, t4, t5, boundRti, kind, parameters, requiredPositional, requiredPositionalLength, optionalPositional, optionalPositionalLength, named, namedLength, returnTypeText, argumentsText, sep, _s2_ = ", "; + if (bounds != null) { + boundsLength = bounds.length; + if (genericContext == null) { + genericContext = H.setRuntimeTypeInfo([], type$.JSArray_String); + outerContextLength = null; + } else + outerContextLength = genericContext.length; + offset = genericContext.length; + for (i = boundsLength; i > 0; --i) + C.JSArray_methods.add$1(genericContext, "T" + (offset + i)); + for (t1 = type$.nullable_Object, t2 = type$.legacy_Object, t3 = type$.Object, typeParametersText = "<", typeSep = "", i = 0; i < boundsLength; ++i, typeSep = _s2_) { + typeParametersText += typeSep; + t4 = genericContext.length; + t5 = t4 - 1 - i; + if (t5 < 0) + return H.ioore(genericContext, t5); + typeParametersText = C.JSString_methods.$add(typeParametersText, genericContext[t5]); + boundRti = bounds[i]; + kind = boundRti._kind; + if (!(kind === 2 || kind === 3 || kind === 4 || kind === 5 || boundRti === t1)) + if (!(boundRti === t2)) + t4 = boundRti === t3; + else + t4 = true; + else + t4 = true; + if (!t4) + typeParametersText += C.JSString_methods.$add(" extends ", H._rtiToString(boundRti, genericContext)); + } + typeParametersText += ">"; + } else { + typeParametersText = ""; + outerContextLength = null; + } + t1 = functionType._primary; + parameters = functionType._rest; + requiredPositional = parameters._requiredPositional; + requiredPositionalLength = requiredPositional.length; + optionalPositional = parameters._optionalPositional; + optionalPositionalLength = optionalPositional.length; + named = parameters._named; + namedLength = named.length; + returnTypeText = H._rtiToString(t1, genericContext); + for (argumentsText = "", sep = "", i = 0; i < requiredPositionalLength; ++i, sep = _s2_) + argumentsText += C.JSString_methods.$add(sep, H._rtiToString(requiredPositional[i], genericContext)); + if (optionalPositionalLength > 0) { + argumentsText += sep + "["; + for (sep = "", i = 0; i < optionalPositionalLength; ++i, sep = _s2_) + argumentsText += C.JSString_methods.$add(sep, H._rtiToString(optionalPositional[i], genericContext)); + argumentsText += "]"; + } + if (namedLength > 0) { + argumentsText += sep + "{"; + for (sep = "", i = 0; i < namedLength; i += 3, sep = _s2_) { + argumentsText += sep; + if (named[i + 1]) + argumentsText += "required "; + argumentsText += J.$add$ansx(H._rtiToString(named[i + 2], genericContext), " ") + named[i]; + } + argumentsText += "}"; + } + if (outerContextLength != null) { + genericContext.toString; + genericContext.length = outerContextLength; + } + return typeParametersText + "(" + argumentsText + ") => " + H.S(returnTypeText); + }, + _rtiToString: function(rti, genericContext) { + var s, questionArgument, argumentKind, $name, $arguments, t1, t2, + kind = rti._kind; + if (kind === 5) + return "erased"; + if (kind === 2) + return "dynamic"; + if (kind === 3) + return "void"; + if (kind === 1) + return "Never"; + if (kind === 4) + return "any"; + if (kind === 6) { + s = H._rtiToString(rti._primary, genericContext); + return s; + } + if (kind === 7) { + questionArgument = rti._primary; + s = H._rtiToString(questionArgument, genericContext); + argumentKind = questionArgument._kind; + return J.$add$ansx(argumentKind === 11 || argumentKind === 12 ? C.JSString_methods.$add("(", s) + ")" : s, "?"); + } + if (kind === 8) + return "FutureOr<" + H.S(H._rtiToString(rti._primary, genericContext)) + ">"; + if (kind === 9) { + $name = H._unminifyOrTag(rti._primary); + $arguments = rti._rest; + return $arguments.length !== 0 ? $name + ("<" + H._rtiArrayToString($arguments, genericContext) + ">") : $name; + } + if (kind === 11) + return H._functionRtiToString(rti, genericContext, null); + if (kind === 12) + return H._functionRtiToString(rti._primary, genericContext, rti._rest); + if (kind === 13) { + genericContext.toString; + t1 = rti._primary; + t2 = genericContext.length; + t1 = t2 - 1 - t1; + if (t1 < 0 || t1 >= t2) + return H.ioore(genericContext, t1); + return genericContext[t1]; + } + return "?"; + }, + _unminifyOrTag: function(rawClassName) { + var preserved = H.unmangleGlobalNameIfPreservedAnyways(rawClassName); + if (preserved != null) + return preserved; + return rawClassName; + }, + _Universe_findRule: function(universe, targetType) { + var rule = universe.tR[targetType]; + for (; typeof rule == "string";) + rule = universe.tR[rule]; + return rule; + }, + _Universe_findErasedType: function(universe, cls) { + var $length, erased, $arguments, i, $interface, + metadata = universe.eT, + probe = metadata[cls]; + if (probe == null) + return H._Universe_eval(universe, cls, false); + else if (typeof probe == "number") { + $length = probe; + erased = H._Universe__lookupTerminalRti(universe, 5, "#"); + $arguments = []; + for (i = 0; i < $length; ++i) + $arguments.push(erased); + $interface = H._Universe__lookupInterfaceRti(universe, cls, $arguments); + metadata[cls] = $interface; + return $interface; + } else + return probe; + }, + _Universe_addRules: function(universe, rules) { + return H._Utils_objectAssign(universe.tR, rules); + }, + _Universe_addErasedTypes: function(universe, types) { + return H._Utils_objectAssign(universe.eT, types); + }, + _Universe_eval: function(universe, recipe, normalize) { + var rti, + cache = universe.eC, + probe = cache.get(recipe); + if (probe != null) + return probe; + rti = H._Parser_parse(H._Parser_create(universe, null, recipe, normalize)); + cache.set(recipe, rti); + return rti; + }, + _Universe_evalInEnvironment: function(universe, environment, recipe) { + var probe, rti, + cache = environment._evalCache; + if (cache == null) + cache = environment._evalCache = new Map(); + probe = cache.get(recipe); + if (probe != null) + return probe; + rti = H._Parser_parse(H._Parser_create(universe, environment, recipe, true)); + cache.set(recipe, rti); + return rti; + }, + _Universe_bind: function(universe, environment, argumentsRti) { + var argumentsRecipe, probe, rti, + cache = environment._bindCache; + if (cache == null) + cache = environment._bindCache = new Map(); + argumentsRecipe = argumentsRti._canonicalRecipe; + probe = cache.get(argumentsRecipe); + if (probe != null) + return probe; + rti = H._Universe__lookupBindingRti(universe, environment, argumentsRti._kind === 10 ? argumentsRti._rest : [argumentsRti]); + cache.set(argumentsRecipe, rti); + return rti; + }, + _Universe__installTypeTests: function(universe, rti) { + rti._as = H._installSpecializedAsCheck; + rti._is = H._installSpecializedIsTest; + return rti; + }, + _Universe__lookupTerminalRti: function(universe, kind, key) { + var rti, t1, + probe = universe.eC.get(key); + if (probe != null) + return probe; + rti = new H.Rti(null, null); + rti._kind = kind; + rti._canonicalRecipe = key; + t1 = H._Universe__installTypeTests(universe, rti); + universe.eC.set(key, t1); + return t1; + }, + _Universe__lookupStarRti: function(universe, baseType, normalize) { + var t1, + key = baseType._canonicalRecipe + "*", + probe = universe.eC.get(key); + if (probe != null) + return probe; + t1 = H._Universe__createStarRti(universe, baseType, key, normalize); + universe.eC.set(key, t1); + return t1; + }, + _Universe__createStarRti: function(universe, baseType, key, normalize) { + var baseKind, t1, rti; + if (normalize) { + baseKind = baseType._kind; + if (!H.isStrongTopType(baseType)) + t1 = baseType === type$.Null || baseType === type$.JSNull || baseKind === 7 || baseKind === 6; + else + t1 = true; + if (t1) + return baseType; + } + rti = new H.Rti(null, null); + rti._kind = 6; + rti._primary = baseType; + rti._canonicalRecipe = key; + return H._Universe__installTypeTests(universe, rti); + }, + _Universe__lookupQuestionRti: function(universe, baseType, normalize) { + var t1, + key = baseType._canonicalRecipe + "?", + probe = universe.eC.get(key); + if (probe != null) + return probe; + t1 = H._Universe__createQuestionRti(universe, baseType, key, normalize); + universe.eC.set(key, t1); + return t1; + }, + _Universe__createQuestionRti: function(universe, baseType, key, normalize) { + var baseKind, t1, starArgument, rti; + if (normalize) { + baseKind = baseType._kind; + if (!H.isStrongTopType(baseType)) + if (!(baseType === type$.Null || baseType === type$.JSNull)) + if (baseKind !== 7) + t1 = baseKind === 8 && H.isNullable(baseType._primary); + else + t1 = true; + else + t1 = true; + else + t1 = true; + if (t1) + return baseType; + else if (baseKind === 1 || baseType === type$.legacy_Never) + return type$.Null; + else if (baseKind === 6) { + starArgument = baseType._primary; + if (starArgument._kind === 8 && H.isNullable(starArgument._primary)) + return starArgument; + else + return H.Rti__getQuestionFromStar(universe, baseType); + } + } + rti = new H.Rti(null, null); + rti._kind = 7; + rti._primary = baseType; + rti._canonicalRecipe = key; + return H._Universe__installTypeTests(universe, rti); + }, + _Universe__lookupFutureOrRti: function(universe, baseType, normalize) { + var t1, + key = baseType._canonicalRecipe + "/", + probe = universe.eC.get(key); + if (probe != null) + return probe; + t1 = H._Universe__createFutureOrRti(universe, baseType, key, normalize); + universe.eC.set(key, t1); + return t1; + }, + _Universe__createFutureOrRti: function(universe, baseType, key, normalize) { + var t1, t2, rti; + if (normalize) { + t1 = baseType._kind; + if (!H.isStrongTopType(baseType)) + if (!(baseType === type$.legacy_Object)) + t2 = baseType === type$.Object; + else + t2 = true; + else + t2 = true; + if (t2 || baseType === type$.Object) + return baseType; + else if (t1 === 1) + return H._Universe__lookupInterfaceRti(universe, "Future", [baseType]); + else if (baseType === type$.Null || baseType === type$.JSNull) + return type$.nullable_Future_Null; + } + rti = new H.Rti(null, null); + rti._kind = 8; + rti._primary = baseType; + rti._canonicalRecipe = key; + return H._Universe__installTypeTests(universe, rti); + }, + _Universe__lookupGenericFunctionParameterRti: function(universe, index) { + var rti, t1, + key = "" + index + "^", + probe = universe.eC.get(key); + if (probe != null) + return probe; + rti = new H.Rti(null, null); + rti._kind = 13; + rti._primary = index; + rti._canonicalRecipe = key; + t1 = H._Universe__installTypeTests(universe, rti); + universe.eC.set(key, t1); + return t1; + }, + _Universe__canonicalRecipeJoin: function($arguments) { + var s, sep, i, + $length = $arguments.length; + for (s = "", sep = "", i = 0; i < $length; ++i, sep = ",") + s += sep + $arguments[i]._canonicalRecipe; + return s; + }, + _Universe__canonicalRecipeJoinNamed: function($arguments) { + var s, sep, i, t1, nameSep, s0, + $length = $arguments.length; + for (s = "", sep = "", i = 0; i < $length; i += 3, sep = ",") { + t1 = $arguments[i]; + nameSep = $arguments[i + 1] ? "!" : ":"; + s0 = $arguments[i + 2]._canonicalRecipe; + s += sep + t1 + nameSep + s0; + } + return s; + }, + _Universe__lookupInterfaceRti: function(universe, $name, $arguments) { + var probe, rti, t1, + s = $name; + if ($arguments.length !== 0) + s += "<" + H._Universe__canonicalRecipeJoin($arguments) + ">"; + probe = universe.eC.get(s); + if (probe != null) + return probe; + rti = new H.Rti(null, null); + rti._kind = 9; + rti._primary = $name; + rti._rest = $arguments; + if ($arguments.length > 0) + rti._precomputed1 = $arguments[0]; + rti._canonicalRecipe = s; + t1 = H._Universe__installTypeTests(universe, rti); + universe.eC.set(s, t1); + return t1; + }, + _Universe__lookupBindingRti: function(universe, base, $arguments) { + var newBase, newArguments, key, probe, rti, t1; + if (base._kind === 10) { + newBase = base._primary; + newArguments = base._rest.concat($arguments); + } else { + newArguments = $arguments; + newBase = base; + } + key = newBase._canonicalRecipe + (";<" + H._Universe__canonicalRecipeJoin(newArguments) + ">"); + probe = universe.eC.get(key); + if (probe != null) + return probe; + rti = new H.Rti(null, null); + rti._kind = 10; + rti._primary = newBase; + rti._rest = newArguments; + rti._canonicalRecipe = key; + t1 = H._Universe__installTypeTests(universe, rti); + universe.eC.set(key, t1); + return t1; + }, + _Universe__lookupFunctionRti: function(universe, returnType, parameters) { + var sep, t1, key, probe, rti, + s = returnType._canonicalRecipe, + requiredPositional = parameters._requiredPositional, + requiredPositionalLength = requiredPositional.length, + optionalPositional = parameters._optionalPositional, + optionalPositionalLength = optionalPositional.length, + named = parameters._named, + namedLength = named.length, + recipe = "(" + H._Universe__canonicalRecipeJoin(requiredPositional); + if (optionalPositionalLength > 0) { + sep = requiredPositionalLength > 0 ? "," : ""; + t1 = H._Universe__canonicalRecipeJoin(optionalPositional); + recipe += sep + "[" + t1 + "]"; + } + if (namedLength > 0) { + sep = requiredPositionalLength > 0 ? "," : ""; + t1 = H._Universe__canonicalRecipeJoinNamed(named); + recipe += sep + "{" + t1 + "}"; + } + key = s + (recipe + ")"); + probe = universe.eC.get(key); + if (probe != null) + return probe; + rti = new H.Rti(null, null); + rti._kind = 11; + rti._primary = returnType; + rti._rest = parameters; + rti._canonicalRecipe = key; + t1 = H._Universe__installTypeTests(universe, rti); + universe.eC.set(key, t1); + return t1; + }, + _Universe__lookupGenericFunctionRti: function(universe, baseFunctionType, bounds, normalize) { + var t1, + key = baseFunctionType._canonicalRecipe + ("<" + H._Universe__canonicalRecipeJoin(bounds) + ">"), + probe = universe.eC.get(key); + if (probe != null) + return probe; + t1 = H._Universe__createGenericFunctionRti(universe, baseFunctionType, bounds, key, normalize); + universe.eC.set(key, t1); + return t1; + }, + _Universe__createGenericFunctionRti: function(universe, baseFunctionType, bounds, key, normalize) { + var $length, typeArguments, count, i, bound, substitutedBase, substitutedBounds, rti; + if (normalize) { + $length = bounds.length; + typeArguments = new Array($length); + for (count = 0, i = 0; i < $length; ++i) { + bound = bounds[i]; + if (bound._kind === 1) { + typeArguments[i] = bound; + ++count; + } + } + if (count > 0) { + substitutedBase = H._substitute(universe, baseFunctionType, typeArguments, 0); + substitutedBounds = H._substituteArray(universe, bounds, typeArguments, 0); + return H._Universe__lookupGenericFunctionRti(universe, substitutedBase, substitutedBounds, bounds !== substitutedBounds); + } + } + rti = new H.Rti(null, null); + rti._kind = 12; + rti._primary = baseFunctionType; + rti._rest = bounds; + rti._canonicalRecipe = key; + return H._Universe__installTypeTests(universe, rti); + }, + _Parser_create: function(universe, environment, recipe, normalize) { + return {u: universe, e: environment, r: recipe, s: [], p: 0, n: normalize}; + }, + _Parser_parse: function(parser) { + var t1, i, ch, universe, array, head, base, u, parameters, optionalPositional, named, item, + source = parser.r, + stack = parser.s; + for (t1 = source.length, i = 0; i < t1;) { + ch = source.charCodeAt(i); + if (ch >= 48 && ch <= 57) + i = H._Parser_handleDigit(i + 1, ch, source, stack); + else if ((((ch | 32) >>> 0) - 97 & 65535) < 26 || ch === 95 || ch === 36) + i = H._Parser_handleIdentifier(parser, i, source, stack, false); + else if (ch === 46) + i = H._Parser_handleIdentifier(parser, i, source, stack, true); + else { + ++i; + switch (ch) { + case 44: + break; + case 58: + stack.push(false); + break; + case 33: + stack.push(true); + break; + case 59: + stack.push(H._Parser_toType(parser.u, parser.e, stack.pop())); + break; + case 94: + stack.push(H._Universe__lookupGenericFunctionParameterRti(parser.u, stack.pop())); + break; + case 35: + stack.push(H._Universe__lookupTerminalRti(parser.u, 5, "#")); + break; + case 64: + stack.push(H._Universe__lookupTerminalRti(parser.u, 2, "@")); + break; + case 126: + stack.push(H._Universe__lookupTerminalRti(parser.u, 3, "~")); + break; + case 60: + stack.push(parser.p); + parser.p = stack.length; + break; + case 62: + universe = parser.u; + array = stack.splice(parser.p); + H._Parser_toTypes(parser.u, parser.e, array); + parser.p = stack.pop(); + head = stack.pop(); + if (typeof head == "string") + stack.push(H._Universe__lookupInterfaceRti(universe, head, array)); + else { + base = H._Parser_toType(universe, parser.e, head); + switch (base._kind) { + case 11: + stack.push(H._Universe__lookupGenericFunctionRti(universe, base, array, parser.n)); + break; + default: + stack.push(H._Universe__lookupBindingRti(universe, base, array)); + break; + } + } + break; + case 38: + H._Parser_handleExtendedOperations(parser, stack); + break; + case 42: + u = parser.u; + stack.push(H._Universe__lookupStarRti(u, H._Parser_toType(u, parser.e, stack.pop()), parser.n)); + break; + case 63: + u = parser.u; + stack.push(H._Universe__lookupQuestionRti(u, H._Parser_toType(u, parser.e, stack.pop()), parser.n)); + break; + case 47: + u = parser.u; + stack.push(H._Universe__lookupFutureOrRti(u, H._Parser_toType(u, parser.e, stack.pop()), parser.n)); + break; + case 40: + stack.push(parser.p); + parser.p = stack.length; + break; + case 41: + universe = parser.u; + parameters = new H._FunctionParameters(); + optionalPositional = universe.sEA; + named = universe.sEA; + head = stack.pop(); + if (typeof head == "number") + switch (head) { + case -1: + optionalPositional = stack.pop(); + break; + case -2: + named = stack.pop(); + break; + default: + stack.push(head); + break; + } + else + stack.push(head); + array = stack.splice(parser.p); + H._Parser_toTypes(parser.u, parser.e, array); + parser.p = stack.pop(); + parameters._requiredPositional = array; + parameters._optionalPositional = optionalPositional; + parameters._named = named; + stack.push(H._Universe__lookupFunctionRti(universe, H._Parser_toType(universe, parser.e, stack.pop()), parameters)); + break; + case 91: + stack.push(parser.p); + parser.p = stack.length; + break; + case 93: + array = stack.splice(parser.p); + H._Parser_toTypes(parser.u, parser.e, array); + parser.p = stack.pop(); + stack.push(array); + stack.push(-1); + break; + case 123: + stack.push(parser.p); + parser.p = stack.length; + break; + case 125: + array = stack.splice(parser.p); + H._Parser_toTypesNamed(parser.u, parser.e, array); + parser.p = stack.pop(); + stack.push(array); + stack.push(-2); + break; + default: + throw "Bad character " + ch; + } + } + } + item = stack.pop(); + return H._Parser_toType(parser.u, parser.e, item); + }, + _Parser_handleDigit: function(i, digit, source, stack) { + var t1, ch, + value = digit - 48; + for (t1 = source.length; i < t1; ++i) { + ch = source.charCodeAt(i); + if (!(ch >= 48 && ch <= 57)) + break; + value = value * 10 + (ch - 48); + } + stack.push(value); + return i; + }, + _Parser_handleIdentifier: function(parser, start, source, stack, hasPeriod) { + var t1, ch, t2, string, environment, recipe, + i = start + 1; + for (t1 = source.length; i < t1; ++i) { + ch = source.charCodeAt(i); + if (ch === 46) { + if (hasPeriod) + break; + hasPeriod = true; + } else { + if (!((((ch | 32) >>> 0) - 97 & 65535) < 26 || ch === 95 || ch === 36)) + t2 = ch >= 48 && ch <= 57; + else + t2 = true; + if (!t2) + break; + } + } + string = source.substring(start, i); + if (hasPeriod) { + t1 = parser.u; + environment = parser.e; + if (environment._kind === 10) + environment = environment._primary; + recipe = H._Universe_findRule(t1, environment._primary)[string]; + if (recipe == null) + H.throwExpression('No "' + string + '" in "' + H.Rti__getCanonicalRecipe(environment) + '"'); + stack.push(H._Universe_evalInEnvironment(t1, environment, recipe)); + } else + stack.push(string); + return i; + }, + _Parser_handleExtendedOperations: function(parser, stack) { + var $top = stack.pop(); + if (0 === $top) { + stack.push(H._Universe__lookupTerminalRti(parser.u, 1, "0&")); + return; + } + if (1 === $top) { + stack.push(H._Universe__lookupTerminalRti(parser.u, 4, "1&")); + return; + } + throw H.wrapException(P.AssertionError$("Unexpected extended operation " + H.S($top))); + }, + _Parser_toType: function(universe, environment, item) { + if (typeof item == "string") + return H._Universe__lookupInterfaceRti(universe, item, universe.sEA); + else if (typeof item == "number") + return H._Parser_indexToType(universe, environment, item); + else + return item; + }, + _Parser_toTypes: function(universe, environment, items) { + var i, + $length = items.length; + for (i = 0; i < $length; ++i) + items[i] = H._Parser_toType(universe, environment, items[i]); + }, + _Parser_toTypesNamed: function(universe, environment, items) { + var i, + $length = items.length; + for (i = 2; i < $length; i += 3) + items[i] = H._Parser_toType(universe, environment, items[i]); + }, + _Parser_indexToType: function(universe, environment, index) { + var typeArguments, len, + kind = environment._kind; + if (kind === 10) { + if (index === 0) + return environment._primary; + typeArguments = environment._rest; + len = typeArguments.length; + if (index <= len) + return typeArguments[index - 1]; + index -= len; + environment = environment._primary; + kind = environment._kind; + } else if (index === 0) + return environment; + if (kind !== 9) + throw H.wrapException(P.AssertionError$("Indexed base must be an interface type")); + typeArguments = environment._rest; + if (index <= typeArguments.length) + return typeArguments[index - 1]; + throw H.wrapException(P.AssertionError$("Bad index " + index + " for " + environment.toString$0(0))); + }, + _isSubtype: function(universe, s, sEnv, t, tEnv) { + var t1, sKind, leftTypeVariable, tKind, sBounds, tBounds, sLength, i, sBound, tBound; + if (s === t) + return true; + if (!H.isStrongTopType(t)) + if (!(t === type$.legacy_Object)) + t1 = t === type$.Object; + else + t1 = true; + else + t1 = true; + if (t1) + return true; + sKind = s._kind; + if (sKind === 4) + return true; + if (H.isStrongTopType(s)) + return false; + if (s._kind !== 1) + t1 = s === type$.Null || s === type$.JSNull; + else + t1 = true; + if (t1) + return true; + leftTypeVariable = sKind === 13; + if (leftTypeVariable) + if (H._isSubtype(universe, sEnv[s._primary], sEnv, t, tEnv)) + return true; + tKind = t._kind; + if (sKind === 6) + return H._isSubtype(universe, s._primary, sEnv, t, tEnv); + if (tKind === 6) { + t1 = t._primary; + return H._isSubtype(universe, s, sEnv, t1, tEnv); + } + if (sKind === 8) { + if (!H._isSubtype(universe, s._primary, sEnv, t, tEnv)) + return false; + return H._isSubtype(universe, H.Rti__getFutureFromFutureOr(universe, s), sEnv, t, tEnv); + } + if (sKind === 7) { + t1 = H._isSubtype(universe, s._primary, sEnv, t, tEnv); + return t1; + } + if (tKind === 8) { + if (H._isSubtype(universe, s, sEnv, t._primary, tEnv)) + return true; + return H._isSubtype(universe, s, sEnv, H.Rti__getFutureFromFutureOr(universe, t), tEnv); + } + if (tKind === 7) { + t1 = H._isSubtype(universe, s, sEnv, t._primary, tEnv); + return t1; + } + if (leftTypeVariable) + return false; + t1 = sKind !== 11; + if ((!t1 || sKind === 12) && t === type$.Function) + return true; + if (tKind === 12) { + if (s === type$.JavaScriptFunction) + return true; + if (sKind !== 12) + return false; + sBounds = s._rest; + tBounds = t._rest; + sLength = sBounds.length; + if (sLength !== tBounds.length) + return false; + sEnv = sEnv == null ? sBounds : sBounds.concat(sEnv); + tEnv = tEnv == null ? tBounds : tBounds.concat(tEnv); + for (i = 0; i < sLength; ++i) { + sBound = sBounds[i]; + tBound = tBounds[i]; + if (!H._isSubtype(universe, sBound, sEnv, tBound, tEnv) || !H._isSubtype(universe, tBound, tEnv, sBound, sEnv)) + return false; + } + return H._isFunctionSubtype(universe, s._primary, sEnv, t._primary, tEnv); + } + if (tKind === 11) { + if (s === type$.JavaScriptFunction) + return true; + if (t1) + return false; + return H._isFunctionSubtype(universe, s, sEnv, t, tEnv); + } + if (sKind === 9) { + if (tKind !== 9) + return false; + return H._isInterfaceSubtype(universe, s, sEnv, t, tEnv); + } + return false; + }, + _isFunctionSubtype: function(universe, s, sEnv, t, tEnv) { + var sParameters, tParameters, sRequiredPositional, tRequiredPositional, sRequiredPositionalLength, tRequiredPositionalLength, requiredPositionalDelta, sOptionalPositional, tOptionalPositional, sOptionalPositionalLength, tOptionalPositionalLength, i, t1, sNamed, tNamed, sNamedLength, tNamedLength, sIndex, tIndex, tName, sName, sIsRequired; + if (!H._isSubtype(universe, s._primary, sEnv, t._primary, tEnv)) + return false; + sParameters = s._rest; + tParameters = t._rest; + sRequiredPositional = sParameters._requiredPositional; + tRequiredPositional = tParameters._requiredPositional; + sRequiredPositionalLength = sRequiredPositional.length; + tRequiredPositionalLength = tRequiredPositional.length; + if (sRequiredPositionalLength > tRequiredPositionalLength) + return false; + requiredPositionalDelta = tRequiredPositionalLength - sRequiredPositionalLength; + sOptionalPositional = sParameters._optionalPositional; + tOptionalPositional = tParameters._optionalPositional; + sOptionalPositionalLength = sOptionalPositional.length; + tOptionalPositionalLength = tOptionalPositional.length; + if (sRequiredPositionalLength + sOptionalPositionalLength < tRequiredPositionalLength + tOptionalPositionalLength) + return false; + for (i = 0; i < sRequiredPositionalLength; ++i) { + t1 = sRequiredPositional[i]; + if (!H._isSubtype(universe, tRequiredPositional[i], tEnv, t1, sEnv)) + return false; + } + for (i = 0; i < requiredPositionalDelta; ++i) { + t1 = sOptionalPositional[i]; + if (!H._isSubtype(universe, tRequiredPositional[sRequiredPositionalLength + i], tEnv, t1, sEnv)) + return false; + } + for (i = 0; i < tOptionalPositionalLength; ++i) { + t1 = sOptionalPositional[requiredPositionalDelta + i]; + if (!H._isSubtype(universe, tOptionalPositional[i], tEnv, t1, sEnv)) + return false; + } + sNamed = sParameters._named; + tNamed = tParameters._named; + sNamedLength = sNamed.length; + tNamedLength = tNamed.length; + for (sIndex = 0, tIndex = 0; tIndex < tNamedLength; tIndex += 3) { + tName = tNamed[tIndex]; + for (; true;) { + if (sIndex >= sNamedLength) + return false; + sName = sNamed[sIndex]; + sIndex += 3; + if (tName < sName) + return false; + sIsRequired = sNamed[sIndex - 2]; + if (sName < tName) { + if (sIsRequired) + return false; + continue; + } + t1 = tNamed[tIndex + 1]; + if (sIsRequired && !t1) + return false; + t1 = sNamed[sIndex - 1]; + if (!H._isSubtype(universe, tNamed[tIndex + 2], tEnv, t1, sEnv)) + return false; + break; + } + } + for (; sIndex < sNamedLength;) { + if (sNamed[sIndex + 1]) + return false; + sIndex += 3; + } + return true; + }, + _isInterfaceSubtype: function(universe, s, sEnv, t, tEnv) { + var sArgs, tArgs, $length, i, t1, t2, rule, supertypeArgs, + sName = s._primary, + tName = t._primary; + if (sName === tName) { + sArgs = s._rest; + tArgs = t._rest; + $length = sArgs.length; + for (i = 0; i < $length; ++i) { + t1 = sArgs[i]; + t2 = tArgs[i]; + if (!H._isSubtype(universe, t1, sEnv, t2, tEnv)) + return false; + } + return true; + } + if (t === type$.Object) + return true; + rule = H._Universe_findRule(universe, sName); + if (rule == null) + return false; + supertypeArgs = rule[tName]; + if (supertypeArgs == null) + return false; + $length = supertypeArgs.length; + tArgs = t._rest; + for (i = 0; i < $length; ++i) + if (!H._isSubtype(universe, H._Universe_evalInEnvironment(universe, s, supertypeArgs[i]), sEnv, tArgs[i], tEnv)) + return false; + return true; + }, + isNullable: function(t) { + var t1, + kind = t._kind; + if (!(t === type$.Null || t === type$.JSNull)) + if (!H.isStrongTopType(t)) + if (kind !== 7) + if (!(kind === 6 && H.isNullable(t._primary))) + t1 = kind === 8 && H.isNullable(t._primary); + else + t1 = true; + else + t1 = true; + else + t1 = true; + else + t1 = true; + return t1; + }, + isTopType: function(t) { + var t1; + if (!H.isStrongTopType(t)) + if (!(t === type$.legacy_Object)) + t1 = t === type$.Object; + else + t1 = true; + else + t1 = true; + return t1; + }, + isStrongTopType: function(t) { + var kind = t._kind; + return kind === 2 || kind === 3 || kind === 4 || kind === 5 || t === type$.nullable_Object; + }, + _Utils_objectAssign: function(o, other) { + var i, key, + keys = Object.keys(other), + $length = keys.length; + for (i = 0; i < $length; ++i) { + key = keys[i]; + o[key] = other[key]; + } + }, + Rti: function Rti(t0, t1) { + var _ = this; + _._as = t0; + _._is = t1; + _._cachedRuntimeType = _._specializedTestResource = _._precomputed1 = null; + _._kind = 0; + _._canonicalRecipe = _._bindCache = _._evalCache = _._rest = _._primary = null; + }, + _FunctionParameters: function _FunctionParameters() { + this._named = this._optionalPositional = this._requiredPositional = null; + }, + _Type: function _Type(t0) { + this._rti = t0; + }, + _Error: function _Error() { + }, + _TypeError: function _TypeError(t0) { + this.__rti$_message = t0; + }, + unmangleGlobalNameIfPreservedAnyways: function($name) { + return init.mangledGlobalNames[$name]; + } + }, + J = { + makeDispatchRecord: function(interceptor, proto, extension, indexability) { + return {i: interceptor, p: proto, e: extension, x: indexability}; + }, + getNativeInterceptor: function(object) { + var proto, objectProto, $constructor, interceptor, + record = object[init.dispatchPropertyName]; + if (record == null) + if ($.initNativeDispatchFlag == null) { + H.initNativeDispatch(); + record = object[init.dispatchPropertyName]; + } + if (record != null) { + proto = record.p; + if (false === proto) + return record.i; + if (true === proto) + return object; + objectProto = Object.getPrototypeOf(object); + if (proto === objectProto) + return record.i; + if (record.e === objectProto) + throw H.wrapException(P.UnimplementedError$("Return interceptor for " + H.S(proto(object, record)))); + } + $constructor = object.constructor; + interceptor = $constructor == null ? null : $constructor[J.JS_INTEROP_INTERCEPTOR_TAG()]; + if (interceptor != null) + return interceptor; + interceptor = H.lookupAndCacheInterceptor(object); + if (interceptor != null) + return interceptor; + if (typeof object == "function") + return C.JavaScriptFunction_methods; + proto = Object.getPrototypeOf(object); + if (proto == null) + return C.PlainJavaScriptObject_methods; + if (proto === Object.prototype) + return C.PlainJavaScriptObject_methods; + if (typeof $constructor == "function") { + Object.defineProperty($constructor, J.JS_INTEROP_INTERCEPTOR_TAG(), {value: C.UnknownJavaScriptObject_methods, enumerable: false, writable: true, configurable: true}); + return C.UnknownJavaScriptObject_methods; + } + return C.UnknownJavaScriptObject_methods; + }, + JS_INTEROP_INTERCEPTOR_TAG: function() { + var t1 = $._JS_INTEROP_INTERCEPTOR_TAG; + return t1 == null ? $._JS_INTEROP_INTERCEPTOR_TAG = init.getIsolateTag("_$dart_js") : t1; + }, + JSArray_JSArray$fixed: function($length, $E) { + if (!H._isInt($length)) + throw H.wrapException(P.ArgumentError$value($length, "length", "is not an integer")); + if ($length < 0 || $length > 4294967295) + throw H.wrapException(P.RangeError$range($length, 0, 4294967295, "length", null)); + return J.JSArray_JSArray$markFixed(new Array($length), $E); + }, + JSArray_JSArray$growable: function($length, $E) { + if (!H._isInt($length) || $length < 0) + throw H.wrapException(P.ArgumentError$("Length must be a non-negative integer: " + H.S($length))); + return H.setRuntimeTypeInfo(new Array($length), $E._eval$1("JSArray<0>")); + }, + JSArray_JSArray$markFixed: function(allocation, $E) { + return J.JSArray_markFixedList(H.setRuntimeTypeInfo(allocation, $E._eval$1("JSArray<0>")), $E); + }, + JSArray_markFixedList: function(list, $T) { + list.fixed$length = Array; + return list; + }, + getInterceptor$: function(receiver) { + if (typeof receiver == "number") { + if (Math.floor(receiver) == receiver) + return J.JSInt.prototype; + return J.JSDouble.prototype; + } + if (typeof receiver == "string") + return J.JSString.prototype; + if (receiver == null) + return J.JSNull.prototype; + if (typeof receiver == "boolean") + return J.JSBool.prototype; + if (receiver.constructor == Array) + return J.JSArray.prototype; + if (typeof receiver != "object") { + if (typeof receiver == "function") + return J.JavaScriptFunction.prototype; + return receiver; + } + if (receiver instanceof P.Object) + return receiver; + return J.getNativeInterceptor(receiver); + }, + getInterceptor$ansx: function(receiver) { + if (typeof receiver == "number") + return J.JSNumber.prototype; + if (typeof receiver == "string") + return J.JSString.prototype; + if (receiver == null) + return receiver; + if (receiver.constructor == Array) + return J.JSArray.prototype; + if (typeof receiver != "object") { + if (typeof receiver == "function") + return J.JavaScriptFunction.prototype; + return receiver; + } + if (receiver instanceof P.Object) + return receiver; + return J.getNativeInterceptor(receiver); + }, + getInterceptor$asx: function(receiver) { + if (typeof receiver == "string") + return J.JSString.prototype; + if (receiver == null) + return receiver; + if (receiver.constructor == Array) + return J.JSArray.prototype; + if (typeof receiver != "object") { + if (typeof receiver == "function") + return J.JavaScriptFunction.prototype; + return receiver; + } + if (receiver instanceof P.Object) + return receiver; + return J.getNativeInterceptor(receiver); + }, + getInterceptor$ax: function(receiver) { + if (receiver == null) + return receiver; + if (receiver.constructor == Array) + return J.JSArray.prototype; + if (typeof receiver != "object") { + if (typeof receiver == "function") + return J.JavaScriptFunction.prototype; + return receiver; + } + if (receiver instanceof P.Object) + return receiver; + return J.getNativeInterceptor(receiver); + }, + getInterceptor$bn: function(receiver) { + if (typeof receiver == "number") + return J.JSNumber.prototype; + if (receiver == null) + return receiver; + if (typeof receiver == "boolean") + return J.JSBool.prototype; + if (!(receiver instanceof P.Object)) + return J.UnknownJavaScriptObject.prototype; + return receiver; + }, + getInterceptor$n: function(receiver) { + if (typeof receiver == "number") + return J.JSNumber.prototype; + if (receiver == null) + return receiver; + if (!(receiver instanceof P.Object)) + return J.UnknownJavaScriptObject.prototype; + return receiver; + }, + getInterceptor$s: function(receiver) { + if (typeof receiver == "string") + return J.JSString.prototype; + if (receiver == null) + return receiver; + if (!(receiver instanceof P.Object)) + return J.UnknownJavaScriptObject.prototype; + return receiver; + }, + getInterceptor$x: function(receiver) { + if (receiver == null) + return receiver; + if (typeof receiver != "object") { + if (typeof receiver == "function") + return J.JavaScriptFunction.prototype; + return receiver; + } + if (receiver instanceof P.Object) + return receiver; + return J.getNativeInterceptor(receiver); + }, + get$hashCode$: function(receiver) { + return J.getInterceptor$(receiver).get$hashCode(receiver); + }, + get$iterator$ax: function(receiver) { + return J.getInterceptor$ax(receiver).get$iterator(receiver); + }, + get$length$asx: function(receiver) { + return J.getInterceptor$asx(receiver).get$length(receiver); + }, + get$runtimeType$: function(receiver) { + return J.getInterceptor$(receiver).get$runtimeType(receiver); + }, + $add$ansx: function(receiver, a0) { + if (typeof receiver == "number" && typeof a0 == "number") + return receiver + a0; + return J.getInterceptor$ansx(receiver).$add(receiver, a0); + }, + $and$bn: function(receiver, a0) { + if (typeof receiver == "number" && typeof a0 == "number") + return (receiver & a0) >>> 0; + return J.getInterceptor$bn(receiver).$and(receiver, a0); + }, + $div$n: function(receiver, a0) { + if (typeof receiver == "number" && typeof a0 == "number") + return receiver / a0; + return J.getInterceptor$n(receiver).$div(receiver, a0); + }, + $eq$: function(receiver, a0) { + if (receiver == null) + return a0 == null; + if (typeof receiver != "object") + return a0 != null && receiver === a0; + return J.getInterceptor$(receiver).$eq(receiver, a0); + }, + $ge$n: function(receiver, a0) { + if (typeof receiver == "number" && typeof a0 == "number") + return receiver >= a0; + return J.getInterceptor$n(receiver).$ge(receiver, a0); + }, + $index$asx: function(receiver, a0) { + if (typeof a0 === "number") + if (receiver.constructor == Array || typeof receiver == "string" || H.isJsIndexable(receiver, receiver[init.dispatchPropertyName])) + if (a0 >>> 0 === a0 && a0 < receiver.length) + return receiver[a0]; + return J.getInterceptor$asx(receiver).$index(receiver, a0); + }, + $indexSet$ax: function(receiver, a0, a1) { + return J.getInterceptor$ax(receiver).$indexSet(receiver, a0, a1); + }, + $or$bn: function(receiver, a0) { + if (typeof receiver == "number" && typeof a0 == "number") + return (receiver | a0) >>> 0; + return J.getInterceptor$bn(receiver).$or(receiver, a0); + }, + $shl$n: function(receiver, a0) { + return J.getInterceptor$n(receiver).$shl(receiver, a0); + }, + $sub$n: function(receiver, a0) { + if (typeof receiver == "number" && typeof a0 == "number") + return receiver - a0; + return J.getInterceptor$n(receiver).$sub(receiver, a0); + }, + _removeEventListener$3$x: function(receiver, a0, a1, a2) { + return J.getInterceptor$x(receiver)._removeEventListener$3(receiver, a0, a1, a2); + }, + addEventListener$3$x: function(receiver, a0, a1, a2) { + return J.getInterceptor$x(receiver).addEventListener$3(receiver, a0, a1, a2); + }, + elementAt$1$ax: function(receiver, a0) { + return J.getInterceptor$ax(receiver).elementAt$1(receiver, a0); + }, + map$1$ax: function(receiver, a0) { + return J.getInterceptor$ax(receiver).map$1(receiver, a0); + }, + map$1$1$ax: function(receiver, a0, $T1) { + return J.getInterceptor$ax(receiver).map$1$1(receiver, a0, $T1); + }, + noSuchMethod$1$: function(receiver, a0) { + return J.getInterceptor$(receiver).noSuchMethod$1(receiver, a0); + }, + toList$0$ax: function(receiver) { + return J.getInterceptor$ax(receiver).toList$0(receiver); + }, + toString$0$: function(receiver) { + return J.getInterceptor$(receiver).toString$0(receiver); + }, + Interceptor: function Interceptor() { + }, + JSBool: function JSBool() { + }, + JSNull: function JSNull() { + }, + JSObject: function JSObject() { + }, + JavaScriptObject: function JavaScriptObject() { + }, + PlainJavaScriptObject: function PlainJavaScriptObject() { + }, + UnknownJavaScriptObject: function UnknownJavaScriptObject() { + }, + JavaScriptFunction: function JavaScriptFunction() { + }, + JSArray: function JSArray(t0) { + this.$ti = t0; + }, + JSUnmodifiableArray: function JSUnmodifiableArray(t0) { + this.$ti = t0; + }, + ArrayIterator: function ArrayIterator(t0, t1, t2) { + var _ = this; + _.__interceptors$_iterable = t0; + _.__interceptors$_length = t1; + _.__interceptors$_index = 0; + _.__interceptors$_current = null; + _.$ti = t2; + }, + JSNumber: function JSNumber() { + }, + JSInt: function JSInt() { + }, + JSDouble: function JSDouble() { + }, + JSString: function JSString() { + } + }, + P = { + _AsyncRun__initializeScheduleImmediate: function() { + var div, span, t1 = {}; + if (self.scheduleImmediate != null) + return P.async__AsyncRun__scheduleImmediateJsOverride$closure(); + if (self.MutationObserver != null && self.document != null) { + div = self.document.createElement("div"); + span = self.document.createElement("span"); + t1.storedCallback = null; + new self.MutationObserver(H.convertDartClosureToJS(new P._AsyncRun__initializeScheduleImmediate_internalCallback(t1), 1)).observe(div, {childList: true}); + return new P._AsyncRun__initializeScheduleImmediate_closure(t1, div, span); + } else if (self.setImmediate != null) + return P.async__AsyncRun__scheduleImmediateWithSetImmediate$closure(); + return P.async__AsyncRun__scheduleImmediateWithTimer$closure(); + }, + _AsyncRun__scheduleImmediateJsOverride: function(callback) { + self.scheduleImmediate(H.convertDartClosureToJS(new P._AsyncRun__scheduleImmediateJsOverride_internalCallback(type$.void_Function._as(callback)), 0)); + }, + _AsyncRun__scheduleImmediateWithSetImmediate: function(callback) { + self.setImmediate(H.convertDartClosureToJS(new P._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback(type$.void_Function._as(callback)), 0)); + }, + _AsyncRun__scheduleImmediateWithTimer: function(callback) { + P.Timer__createTimer(C.Duration_0, type$.void_Function._as(callback)); + }, + Timer__createTimer: function(duration, callback) { + var milliseconds = C.JSInt_methods._tdivFast$1(duration._duration, 1000); + return P._TimerImpl$(milliseconds < 0 ? 0 : milliseconds, callback); + }, + _TimerImpl$: function(milliseconds, callback) { + var t1 = new P._TimerImpl(); + t1._TimerImpl$2(milliseconds, callback); + return t1; + }, + _makeAsyncAwaitCompleter: function($T) { + return new P._AsyncAwaitCompleter(new P._Future($.Zone__current, $T._eval$1("_Future<0>")), $T._eval$1("_AsyncAwaitCompleter<0>")); + }, + _asyncStartSync: function(bodyFunction, completer) { + bodyFunction.call$2(0, null); + completer.isSync = true; + return completer._future; + }, + _asyncAwait: function(object, bodyFunction) { + P._awaitOnObject(object, bodyFunction); + }, + _asyncReturn: function(object, completer) { + completer.complete$1(object); + }, + _asyncRethrow: function(object, completer) { + completer.completeError$2(H.unwrapException(object), H.getTraceFromException(object)); + }, + _awaitOnObject: function(object, bodyFunction) { + var t1, future, + thenCallback = new P._awaitOnObject_closure(bodyFunction), + errorCallback = new P._awaitOnObject_closure0(bodyFunction); + if (object instanceof P._Future) + object._thenAwait$1$2(thenCallback, errorCallback, type$.dynamic); + else { + t1 = type$.dynamic; + if (type$.Future_dynamic._is(object)) + object.then$1$2$onError(thenCallback, errorCallback, t1); + else { + future = new P._Future($.Zone__current, type$._Future_dynamic); + future._state = 4; + future._resultOrListeners = object; + future._thenAwait$1$2(thenCallback, errorCallback, t1); + } + } + }, + _wrapJsFunctionForAsync: function($function) { + var $protected = function(fn, ERROR) { + return function(errorCode, result) { + while (true) + try { + fn(errorCode, result); + break; + } catch (error) { + result = error; + errorCode = ERROR; + } + }; + }($function, 1); + return $.Zone__current.registerBinaryCallback$3$1(new P._wrapJsFunctionForAsync_closure($protected), type$.Null, type$.int, type$.dynamic); + }, + _Future$zoneValue: function(value, _zone, $T) { + var t1 = new P._Future(_zone, $T._eval$1("_Future<0>")); + $T._as(value); + t1._state = 4; + t1._resultOrListeners = value; + return t1; + }, + _Future__chainForeignFuture: function(source, target) { + var e, s, exception; + target._state = 1; + try { + source.then$1$2$onError(new P._Future__chainForeignFuture_closure(target), new P._Future__chainForeignFuture_closure0(target), type$.Null); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + P.scheduleMicrotask(new P._Future__chainForeignFuture_closure1(target, e, s)); + } + }, + _Future__chainCoreFuture: function(source, target) { + var t1, t2, listeners; + for (t1 = type$._Future_dynamic; t2 = source._state, t2 === 2;) + source = t1._as(source._resultOrListeners); + if (t2 >= 4) { + listeners = target._removeListeners$0(); + target._state = source._state; + target._resultOrListeners = source._resultOrListeners; + P._Future__propagateToListeners(target, listeners); + } else { + listeners = type$.nullable__FutureListener_dynamic_dynamic._as(target._resultOrListeners); + target._state = 2; + target._resultOrListeners = source; + source._prependListeners$1(listeners); + } + }, + _Future__propagateToListeners: function(source, listeners) { + var t2, t3, t4, _box_0, hasError, asyncError, nextListener, nextListener0, t5, sourceResult, t6, t7, zone, oldZone, result, current, _null = null, _box_1 = {}, + t1 = _box_1.source = source; + for (t2 = type$.AsyncError, t3 = type$.nullable__FutureListener_dynamic_dynamic, t4 = type$.Future_dynamic; true;) { + _box_0 = {}; + hasError = t1._state === 8; + if (listeners == null) { + if (hasError) { + asyncError = t2._as(t1._resultOrListeners); + P._rootHandleUncaughtError(_null, _null, t1._zone, asyncError.error, asyncError.stackTrace); + } + return; + } + _box_0.listener = listeners; + nextListener = listeners._nextListener; + for (t1 = listeners; nextListener != null; t1 = nextListener, nextListener = nextListener0) { + t1._nextListener = null; + P._Future__propagateToListeners(_box_1.source, t1); + _box_0.listener = nextListener; + nextListener0 = nextListener._nextListener; + } + t5 = _box_1.source; + sourceResult = t5._resultOrListeners; + _box_0.listenerHasError = hasError; + _box_0.listenerValueOrError = sourceResult; + t6 = !hasError; + if (t6) { + t7 = t1.state; + t7 = (t7 & 1) !== 0 || (t7 & 15) === 8; + } else + t7 = true; + if (t7) { + zone = t1.result._zone; + if (hasError) { + t7 = t5._zone === zone; + t7 = !(t7 || t7); + } else + t7 = false; + if (t7) { + t2._as(sourceResult); + P._rootHandleUncaughtError(_null, _null, t5._zone, sourceResult.error, sourceResult.stackTrace); + return; + } + oldZone = $.Zone__current; + if (oldZone !== zone) + $.Zone__current = zone; + else + oldZone = _null; + t1 = t1.state; + if ((t1 & 15) === 8) + new P._Future__propagateToListeners_handleWhenCompleteCallback(_box_0, _box_1, hasError).call$0(); + else if (t6) { + if ((t1 & 1) !== 0) + new P._Future__propagateToListeners_handleValueCallback(_box_0, sourceResult).call$0(); + } else if ((t1 & 2) !== 0) + new P._Future__propagateToListeners_handleError(_box_1, _box_0).call$0(); + if (oldZone != null) + $.Zone__current = oldZone; + t1 = _box_0.listenerValueOrError; + if (t4._is(t1)) { + result = _box_0.listener.result; + if (t1._state >= 4) { + current = t3._as(result._resultOrListeners); + result._resultOrListeners = null; + listeners = result._reverseListeners$1(current); + result._state = t1._state; + result._resultOrListeners = t1._resultOrListeners; + _box_1.source = t1; + continue; + } else + P._Future__chainCoreFuture(t1, result); + return; + } + } + result = _box_0.listener.result; + current = t3._as(result._resultOrListeners); + result._resultOrListeners = null; + listeners = result._reverseListeners$1(current); + t1 = _box_0.listenerHasError; + t5 = _box_0.listenerValueOrError; + if (!t1) { + result.$ti._precomputed1._as(t5); + result._state = 4; + result._resultOrListeners = t5; + } else { + t2._as(t5); + result._state = 8; + result._resultOrListeners = t5; + } + _box_1.source = result; + t1 = result; + } + }, + _registerErrorHandler: function(errorHandler, zone) { + var t1; + if (type$.dynamic_Function_Object_StackTrace._is(errorHandler)) + return zone.registerBinaryCallback$3$1(errorHandler, type$.dynamic, type$.Object, type$.StackTrace); + t1 = type$.dynamic_Function_Object; + if (t1._is(errorHandler)) + return t1._as(errorHandler); + throw H.wrapException(P.ArgumentError$value(errorHandler, "onError", "Error handler must accept one Object or one Object and a StackTrace as arguments, and return a a valid result")); + }, + _microtaskLoop: function() { + var entry, next; + for (entry = $._nextCallback; entry != null; entry = $._nextCallback) { + $._lastPriorityCallback = null; + next = entry.next; + $._nextCallback = next; + if (next == null) + $._lastCallback = null; + entry.callback.call$0(); + } + }, + _startMicrotaskLoop: function() { + $._isInCallbackLoop = true; + try { + P._microtaskLoop(); + } finally { + $._lastPriorityCallback = null; + $._isInCallbackLoop = false; + if ($._nextCallback != null) + $.$get$_AsyncRun__scheduleImmediateClosure().call$1(P.async___startMicrotaskLoop$closure()); + } + }, + _scheduleAsyncCallback: function(callback) { + var newEntry = new P._AsyncCallbackEntry(callback), + lastCallback = $._lastCallback; + if (lastCallback == null) { + $._nextCallback = $._lastCallback = newEntry; + if (!$._isInCallbackLoop) + $.$get$_AsyncRun__scheduleImmediateClosure().call$1(P.async___startMicrotaskLoop$closure()); + } else + $._lastCallback = lastCallback.next = newEntry; + }, + _schedulePriorityAsyncCallback: function(callback) { + var entry, lastPriorityCallback, next, + t1 = $._nextCallback; + if (t1 == null) { + P._scheduleAsyncCallback(callback); + $._lastPriorityCallback = $._lastCallback; + return; + } + entry = new P._AsyncCallbackEntry(callback); + lastPriorityCallback = $._lastPriorityCallback; + if (lastPriorityCallback == null) { + entry.next = t1; + $._nextCallback = $._lastPriorityCallback = entry; + } else { + next = lastPriorityCallback.next; + entry.next = next; + $._lastPriorityCallback = lastPriorityCallback.next = entry; + if (next == null) + $._lastCallback = entry; + } + }, + scheduleMicrotask: function(callback) { + var _null = null, + currentZone = $.Zone__current; + if (C.C__RootZone === currentZone) { + P._rootScheduleMicrotask(_null, _null, C.C__RootZone, callback); + return; + } + P._rootScheduleMicrotask(_null, _null, currentZone, type$.void_Function._as(currentZone.bindCallbackGuarded$1(callback))); + }, + StreamIterator_StreamIterator: function(stream, $T) { + P.ArgumentError_checkNotNull(stream, "stream", $T._eval$1("Stream<0>")); + return new P._StreamIterator(stream, $T._eval$1("_StreamIterator<0>")); + }, + StreamController_StreamController: function($T) { + var _null = null; + return new P._AsyncStreamController(_null, _null, _null, _null, $T._eval$1("_AsyncStreamController<0>")); + }, + StreamController_StreamController$broadcast: function(sync, $T) { + var _null = null; + return sync ? new P._SyncBroadcastStreamController(_null, _null, $T._eval$1("_SyncBroadcastStreamController<0>")) : new P._AsyncBroadcastStreamController(_null, _null, $T._eval$1("_AsyncBroadcastStreamController<0>")); + }, + _runGuarded: function(notificationHandler) { + return; + }, + _BufferingStreamSubscription__registerDataHandler: function(zone, handleData, $T) { + var t1 = handleData == null ? P.async___nullDataHandler$closure() : handleData; + return type$.$env_1_1_void._bind$1($T)._eval$1("1(2)")._as(t1); + }, + _BufferingStreamSubscription__registerErrorHandler: function(zone, handleError) { + if (handleError == null) + handleError = P.async___nullErrorHandler$closure(); + if (type$.void_Function_Object_StackTrace._is(handleError)) + return zone.registerBinaryCallback$3$1(handleError, type$.dynamic, type$.Object, type$.StackTrace); + if (type$.void_Function_Object._is(handleError)) + return type$.dynamic_Function_Object._as(handleError); + throw H.wrapException(P.ArgumentError$("handleError callback must take either an Object (the error), or both an Object (the error) and a StackTrace.")); + }, + _BufferingStreamSubscription__registerDoneHandler: function(zone, handleDone) { + return type$.void_Function._as(handleDone); + }, + _nullDataHandler: function(value) { + }, + _nullErrorHandler: function(error, stackTrace) { + P._rootHandleUncaughtError(null, null, $.Zone__current, error, stackTrace); + }, + _cancelAndValue: function(subscription, future, value) { + var cancelFuture = subscription.cancel$0(); + if (cancelFuture != null && cancelFuture !== $.$get$Future__nullFuture()) + cancelFuture.whenComplete$1(new P._cancelAndValue_closure(future, value)); + else + future._complete$1(value); + }, + Timer_Timer: function(duration, callback) { + var t1 = $.Zone__current; + if (t1 === C.C__RootZone) + return P.Timer__createTimer(duration, type$.void_Function._as(callback)); + return P.Timer__createTimer(duration, type$.void_Function._as(t1.bindCallbackGuarded$1(callback))); + }, + AsyncError$: function(error, stackTrace) { + var t1 = stackTrace == null ? P.AsyncError_defaultStackTrace(error) : stackTrace; + P.ArgumentError_checkNotNull(error, "error", type$.Object); + return new P.AsyncError(error, t1); + }, + AsyncError_defaultStackTrace: function(error) { + var stackTrace; + if (type$.Error._is(error)) { + stackTrace = error.get$stackTrace(); + if (stackTrace != null) + return stackTrace; + } + return C.C__StringStackTrace; + }, + _rootHandleUncaughtError: function($self, $parent, zone, error, stackTrace) { + P._schedulePriorityAsyncCallback(new P._rootHandleUncaughtError_closure(error, stackTrace)); + }, + _rootRun: function($self, $parent, zone, f, $R) { + var old, + t1 = $.Zone__current; + if (t1 === zone) + return f.call$0(); + $.Zone__current = zone; + old = t1; + try { + t1 = f.call$0(); + return t1; + } finally { + $.Zone__current = old; + } + }, + _rootRunUnary: function($self, $parent, zone, f, arg, $R, $T) { + var old, + t1 = $.Zone__current; + if (t1 === zone) + return f.call$1(arg); + $.Zone__current = zone; + old = t1; + try { + t1 = f.call$1(arg); + return t1; + } finally { + $.Zone__current = old; + } + }, + _rootRunBinary: function($self, $parent, zone, f, arg1, arg2, $R, T1, T2) { + var old, + t1 = $.Zone__current; + if (t1 === zone) + return f.call$2(arg1, arg2); + $.Zone__current = zone; + old = t1; + try { + t1 = f.call$2(arg1, arg2); + return t1; + } finally { + $.Zone__current = old; + } + }, + _rootScheduleMicrotask: function($self, $parent, zone, f) { + var t1; + type$.void_Function._as(f); + t1 = C.C__RootZone !== zone; + if (t1) + f = !(!t1 || false) ? zone.bindCallbackGuarded$1(f) : zone.bindCallback$1$1(f, type$.void); + P._scheduleAsyncCallback(f); + }, + _AsyncRun__initializeScheduleImmediate_internalCallback: function _AsyncRun__initializeScheduleImmediate_internalCallback(t0) { + this._box_0 = t0; + }, + _AsyncRun__initializeScheduleImmediate_closure: function _AsyncRun__initializeScheduleImmediate_closure(t0, t1, t2) { + this._box_0 = t0; + this.div = t1; + this.span = t2; + }, + _AsyncRun__scheduleImmediateJsOverride_internalCallback: function _AsyncRun__scheduleImmediateJsOverride_internalCallback(t0) { + this.callback = t0; + }, + _AsyncRun__scheduleImmediateWithSetImmediate_internalCallback: function _AsyncRun__scheduleImmediateWithSetImmediate_internalCallback(t0) { + this.callback = t0; + }, + _TimerImpl: function _TimerImpl() { + this._handle = null; + }, + _TimerImpl_internalCallback: function _TimerImpl_internalCallback(t0, t1) { + this.$this = t0; + this.callback = t1; + }, + _AsyncAwaitCompleter: function _AsyncAwaitCompleter(t0, t1) { + this._future = t0; + this.isSync = false; + this.$ti = t1; + }, + _awaitOnObject_closure: function _awaitOnObject_closure(t0) { + this.bodyFunction = t0; + }, + _awaitOnObject_closure0: function _awaitOnObject_closure0(t0) { + this.bodyFunction = t0; + }, + _wrapJsFunctionForAsync_closure: function _wrapJsFunctionForAsync_closure(t0) { + this.$protected = t0; + }, + _BroadcastSubscription: function _BroadcastSubscription(t0, t1, t2, t3, t4, t5, t6) { + var _ = this; + _._eventState = 0; + _._async$_previous = _._async$_next = null; + _._controller = t0; + _._async$_onData = t1; + _._onError = t2; + _._onDone = t3; + _._zone = t4; + _._state = t5; + _._pending = _._cancelFuture = null; + _.$ti = t6; + }, + _BroadcastStreamController: function _BroadcastStreamController() { + }, + _SyncBroadcastStreamController: function _SyncBroadcastStreamController(t0, t1, t2) { + var _ = this; + _.onListen = t0; + _.onCancel = t1; + _._state = 0; + _._doneFuture = _._addStreamState = _._lastSubscription = _._firstSubscription = null; + _.$ti = t2; + }, + _SyncBroadcastStreamController__sendData_closure: function _SyncBroadcastStreamController__sendData_closure(t0, t1) { + this.$this = t0; + this.data = t1; + }, + _AsyncBroadcastStreamController: function _AsyncBroadcastStreamController(t0, t1, t2) { + var _ = this; + _.onListen = t0; + _.onCancel = t1; + _._state = 0; + _._doneFuture = _._addStreamState = _._lastSubscription = _._firstSubscription = null; + _.$ti = t2; + }, + Future: function Future() { + }, + Completer: function Completer() { + }, + _Completer: function _Completer() { + }, + _AsyncCompleter: function _AsyncCompleter(t0, t1) { + this.future = t0; + this.$ti = t1; + }, + _FutureListener: function _FutureListener(t0, t1, t2, t3, t4) { + var _ = this; + _._nextListener = null; + _.result = t0; + _.state = t1; + _.callback = t2; + _.errorCallback = t3; + _.$ti = t4; + }, + _Future: function _Future(t0, t1) { + var _ = this; + _._state = 0; + _._zone = t0; + _._resultOrListeners = null; + _.$ti = t1; + }, + _Future__addListener_closure: function _Future__addListener_closure(t0, t1) { + this.$this = t0; + this.listener = t1; + }, + _Future__prependListeners_closure: function _Future__prependListeners_closure(t0, t1) { + this._box_0 = t0; + this.$this = t1; + }, + _Future__chainForeignFuture_closure: function _Future__chainForeignFuture_closure(t0) { + this.target = t0; + }, + _Future__chainForeignFuture_closure0: function _Future__chainForeignFuture_closure0(t0) { + this.target = t0; + }, + _Future__chainForeignFuture_closure1: function _Future__chainForeignFuture_closure1(t0, t1, t2) { + this.target = t0; + this.e = t1; + this.s = t2; + }, + _Future__asyncCompleteWithValue_closure: function _Future__asyncCompleteWithValue_closure(t0, t1) { + this.$this = t0; + this.value = t1; + }, + _Future__chainFuture_closure: function _Future__chainFuture_closure(t0, t1) { + this.$this = t0; + this.value = t1; + }, + _Future__asyncCompleteError_closure: function _Future__asyncCompleteError_closure(t0, t1, t2) { + this.$this = t0; + this.error = t1; + this.stackTrace = t2; + }, + _Future__propagateToListeners_handleWhenCompleteCallback: function _Future__propagateToListeners_handleWhenCompleteCallback(t0, t1, t2) { + this._box_0 = t0; + this._box_1 = t1; + this.hasError = t2; + }, + _Future__propagateToListeners_handleWhenCompleteCallback_closure: function _Future__propagateToListeners_handleWhenCompleteCallback_closure(t0) { + this.originalSource = t0; + }, + _Future__propagateToListeners_handleValueCallback: function _Future__propagateToListeners_handleValueCallback(t0, t1) { + this._box_0 = t0; + this.sourceResult = t1; + }, + _Future__propagateToListeners_handleError: function _Future__propagateToListeners_handleError(t0, t1) { + this._box_1 = t0; + this._box_0 = t1; + }, + _AsyncCallbackEntry: function _AsyncCallbackEntry(t0) { + this.callback = t0; + this.next = null; + }, + Stream: function Stream() { + }, + Stream_length_closure: function Stream_length_closure(t0, t1) { + this._box_0 = t0; + this.$this = t1; + }, + Stream_length_closure0: function Stream_length_closure0(t0, t1) { + this._box_0 = t0; + this.future = t1; + }, + Stream_first_closure: function Stream_first_closure(t0) { + this.future = t0; + }, + Stream_first_closure0: function Stream_first_closure0(t0, t1, t2) { + this.$this = t0; + this.subscription = t1; + this.future = t2; + }, + StreamSubscription: function StreamSubscription() { + }, + StreamTransformerBase: function StreamTransformerBase() { + }, + StreamController: function StreamController() { + }, + _StreamController: function _StreamController() { + }, + _StreamController__subscribe_closure: function _StreamController__subscribe_closure(t0) { + this.$this = t0; + }, + _StreamController__recordCancel_complete: function _StreamController__recordCancel_complete(t0) { + this.$this = t0; + }, + _AsyncStreamControllerDispatch: function _AsyncStreamControllerDispatch() { + }, + _AsyncStreamController: function _AsyncStreamController(t0, t1, t2, t3, t4) { + var _ = this; + _._varData = null; + _._state = 0; + _._doneFuture = null; + _.onListen = t0; + _.onPause = t1; + _.onResume = t2; + _.onCancel = t3; + _.$ti = t4; + }, + _ControllerStream: function _ControllerStream(t0, t1) { + this._controller = t0; + this.$ti = t1; + }, + _ControllerSubscription: function _ControllerSubscription(t0, t1, t2, t3, t4, t5, t6) { + var _ = this; + _._controller = t0; + _._async$_onData = t1; + _._onError = t2; + _._onDone = t3; + _._zone = t4; + _._state = t5; + _._pending = _._cancelFuture = null; + _.$ti = t6; + }, + _StreamSinkWrapper: function _StreamSinkWrapper(t0, t1) { + this._async$_target = t0; + this.$ti = t1; + }, + _BufferingStreamSubscription: function _BufferingStreamSubscription() { + }, + _BufferingStreamSubscription__sendError_sendError: function _BufferingStreamSubscription__sendError_sendError(t0, t1, t2) { + this.$this = t0; + this.error = t1; + this.stackTrace = t2; + }, + _BufferingStreamSubscription__sendDone_sendDone: function _BufferingStreamSubscription__sendDone_sendDone(t0) { + this.$this = t0; + }, + _StreamImpl: function _StreamImpl() { + }, + _DelayedEvent: function _DelayedEvent() { + }, + _DelayedData: function _DelayedData(t0, t1) { + this.value = t0; + this.next = null; + this.$ti = t1; + }, + _DelayedError: function _DelayedError(t0, t1) { + this.error = t0; + this.stackTrace = t1; + this.next = null; + }, + _DelayedDone: function _DelayedDone() { + }, + _PendingEvents: function _PendingEvents() { + }, + _PendingEvents_schedule_closure: function _PendingEvents_schedule_closure(t0, t1) { + this.$this = t0; + this.dispatch = t1; + }, + _StreamImplEvents: function _StreamImplEvents(t0) { + var _ = this; + _.lastPendingEvent = _.firstPendingEvent = null; + _._state = 0; + _.$ti = t0; + }, + _DoneStreamSubscription: function _DoneStreamSubscription(t0, t1, t2) { + var _ = this; + _._zone = t0; + _._state = 0; + _._onDone = t1; + _.$ti = t2; + }, + _StreamIterator: function _StreamIterator(t0, t1) { + var _ = this; + _._async$_subscription = null; + _._stateData = t0; + _._isPaused = false; + _.$ti = t1; + }, + _cancelAndValue_closure: function _cancelAndValue_closure(t0, t1) { + this.future = t0; + this.value = t1; + }, + _ForwardingStream: function _ForwardingStream() { + }, + _ForwardingStreamSubscription: function _ForwardingStreamSubscription(t0, t1, t2, t3, t4, t5, t6) { + var _ = this; + _._stream = t0; + _._async$_subscription = null; + _._async$_onData = t1; + _._onError = t2; + _._onDone = t3; + _._zone = t4; + _._state = t5; + _._pending = _._cancelFuture = null; + _.$ti = t6; + }, + _MapStream: function _MapStream(t0, t1, t2) { + this._transform = t0; + this._async$_source = t1; + this.$ti = t2; + }, + AsyncError: function AsyncError(t0, t1) { + this.error = t0; + this.stackTrace = t1; + }, + _Zone: function _Zone() { + }, + _rootHandleUncaughtError_closure: function _rootHandleUncaughtError_closure(t0, t1) { + this.error = t0; + this.stackTrace = t1; + }, + _RootZone: function _RootZone() { + }, + _RootZone_bindCallback_closure: function _RootZone_bindCallback_closure(t0, t1, t2) { + this.$this = t0; + this.f = t1; + this.R = t2; + }, + _RootZone_bindCallbackGuarded_closure: function _RootZone_bindCallbackGuarded_closure(t0, t1) { + this.$this = t0; + this.f = t1; + }, + _RootZone_bindUnaryCallbackGuarded_closure: function _RootZone_bindUnaryCallbackGuarded_closure(t0, t1, t2) { + this.$this = t0; + this.f = t1; + this.T = t2; + }, + LinkedHashMap_LinkedHashMap: function($K, $V) { + return new H.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>")); + }, + LinkedHashMap_LinkedHashMap$_literal: function(keyValuePairs, $K, $V) { + return $K._eval$1("@<0>")._bind$1($V)._eval$1("LinkedHashMap<1,2>")._as(H.fillLiteralMap(keyValuePairs, new H.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>")))); + }, + LinkedHashMap_LinkedHashMap$_empty: function($K, $V) { + return new H.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>")); + }, + LinkedHashSet_LinkedHashSet: function($E) { + return new P._LinkedHashSet($E._eval$1("_LinkedHashSet<0>")); + }, + _LinkedHashSet__newHashTable: function() { + var table = Object.create(null); + table[""] = table; + delete table[""]; + return table; + }, + IterableBase_iterableToShortString: function(iterable, leftDelimiter, rightDelimiter) { + var parts, t1; + if (P._isToStringVisiting(iterable)) { + if (leftDelimiter === "(" && rightDelimiter === ")") + return "(...)"; + return leftDelimiter + "..." + rightDelimiter; + } + parts = H.setRuntimeTypeInfo([], type$.JSArray_String); + C.JSArray_methods.add$1($._toStringVisiting, iterable); + try { + P._iterablePartsToStrings(iterable, parts); + } finally { + if (0 >= $._toStringVisiting.length) + return H.ioore($._toStringVisiting, -1); + $._toStringVisiting.pop(); + } + t1 = P.StringBuffer__writeAll(leftDelimiter, type$.Iterable_dynamic._as(parts), ", ") + rightDelimiter; + return t1.charCodeAt(0) == 0 ? t1 : t1; + }, + IterableBase_iterableToFullString: function(iterable, leftDelimiter, rightDelimiter) { + var buffer, t1; + if (P._isToStringVisiting(iterable)) + return leftDelimiter + "..." + rightDelimiter; + buffer = new P.StringBuffer(leftDelimiter); + C.JSArray_methods.add$1($._toStringVisiting, iterable); + try { + t1 = buffer; + t1._contents = P.StringBuffer__writeAll(t1._contents, iterable, ", "); + } finally { + if (0 >= $._toStringVisiting.length) + return H.ioore($._toStringVisiting, -1); + $._toStringVisiting.pop(); + } + buffer._contents += rightDelimiter; + t1 = buffer._contents; + return t1.charCodeAt(0) == 0 ? t1 : t1; + }, + _isToStringVisiting: function(o) { + var t1, i; + for (t1 = $._toStringVisiting.length, i = 0; i < t1; ++i) + if (o === $._toStringVisiting[i]) + return true; + return false; + }, + _iterablePartsToStrings: function(iterable, parts) { + var next, ultimateString, penultimateString, penultimate, ultimate, ultimate0, elision, + it = iterable.get$iterator(iterable), + $length = 0, count = 0; + while (true) { + if (!($length < 80 || count < 3)) + break; + if (!it.moveNext$0()) + return; + next = H.S(it.get$current()); + C.JSArray_methods.add$1(parts, next); + $length += next.length + 2; + ++count; + } + if (!it.moveNext$0()) { + if (count <= 5) + return; + if (0 >= parts.length) + return H.ioore(parts, -1); + ultimateString = parts.pop(); + if (0 >= parts.length) + return H.ioore(parts, -1); + penultimateString = parts.pop(); + } else { + penultimate = it.get$current(); + ++count; + if (!it.moveNext$0()) { + if (count <= 4) { + C.JSArray_methods.add$1(parts, H.S(penultimate)); + return; + } + ultimateString = H.S(penultimate); + if (0 >= parts.length) + return H.ioore(parts, -1); + penultimateString = parts.pop(); + $length += ultimateString.length + 2; + } else { + ultimate = it.get$current(); + ++count; + for (; it.moveNext$0(); penultimate = ultimate, ultimate = ultimate0) { + ultimate0 = it.get$current(); + ++count; + if (count > 100) { + while (true) { + if (!($length > 75 && count > 3)) + break; + if (0 >= parts.length) + return H.ioore(parts, -1); + $length -= parts.pop().length + 2; + --count; + } + C.JSArray_methods.add$1(parts, "..."); + return; + } + } + penultimateString = H.S(penultimate); + ultimateString = H.S(ultimate); + $length += ultimateString.length + penultimateString.length + 4; + } + } + if (count > parts.length + 2) { + $length += 5; + elision = "..."; + } else + elision = null; + while (true) { + if (!($length > 80 && parts.length > 3)) + break; + if (0 >= parts.length) + return H.ioore(parts, -1); + $length -= parts.pop().length + 2; + if (elision == null) { + $length += 5; + elision = "..."; + } + } + if (elision != null) + C.JSArray_methods.add$1(parts, elision); + C.JSArray_methods.add$1(parts, penultimateString); + C.JSArray_methods.add$1(parts, ultimateString); + }, + LinkedHashMap_LinkedHashMap$of: function(other, $K, $V) { + var t1 = P.LinkedHashMap_LinkedHashMap($K, $V); + t1.addAll$1(0, other); + return t1; + }, + MapBase_mapToString: function(m) { + var result, t1 = {}; + if (P._isToStringVisiting(m)) + return "{...}"; + result = new P.StringBuffer(""); + try { + C.JSArray_methods.add$1($._toStringVisiting, m); + result._contents += "{"; + t1.first = true; + m.forEach$1(0, new P.MapBase_mapToString_closure(t1, result)); + result._contents += "}"; + } finally { + if (0 >= $._toStringVisiting.length) + return H.ioore($._toStringVisiting, -1); + $._toStringVisiting.pop(); + } + t1 = result._contents; + return t1.charCodeAt(0) == 0 ? t1 : t1; + }, + ListQueue__calculateCapacity: function(initialCapacity) { + return 8; + }, + _LinkedHashSet: function _LinkedHashSet(t0) { + var _ = this; + _._collection$_length = 0; + _._collection$_last = _._collection$_first = _._collection$_rest = _._collection$_nums = _._collection$_strings = null; + _._collection$_modifications = 0; + _.$ti = t0; + }, + _LinkedHashSetCell: function _LinkedHashSetCell(t0) { + this._element = t0; + this._collection$_next = null; + }, + _LinkedHashSetIterator: function _LinkedHashSetIterator(t0, t1, t2) { + var _ = this; + _._set = t0; + _._collection$_modifications = t1; + _._collection$_current = _._collection$_cell = null; + _.$ti = t2; + }, + ListMixin: function ListMixin() { + }, + MapBase: function MapBase() { + }, + MapBase_mapToString_closure: function MapBase_mapToString_closure(t0, t1) { + this._box_0 = t0; + this.result = t1; + }, + MapMixin: function MapMixin() { + }, + _UnmodifiableMapMixin: function _UnmodifiableMapMixin() { + }, + MapView: function MapView() { + }, + UnmodifiableMapView: function UnmodifiableMapView() { + }, + ListQueue: function ListQueue(t0, t1) { + var _ = this; + _._collection$_table = t0; + _._modificationCount = _._tail = _._head = 0; + _.$ti = t1; + }, + _ListQueueIterator: function _ListQueueIterator(t0, t1, t2, t3, t4) { + var _ = this; + _._queue = t0; + _._end = t1; + _._modificationCount = t2; + _._position = t3; + _._collection$_current = null; + _.$ti = t4; + }, + _SetBase: function _SetBase() { + }, + _UnmodifiableMapView_MapView__UnmodifiableMapMixin: function _UnmodifiableMapView_MapView__UnmodifiableMapMixin() { + }, + _parseJson: function(source, reviver) { + var parsed, e, exception, t1; + if (typeof source != "string") + throw H.wrapException(H.argumentErrorValue(source)); + parsed = null; + try { + parsed = JSON.parse(source); + } catch (exception) { + e = H.unwrapException(exception); + t1 = P.FormatException$(String(e), null, null); + throw H.wrapException(t1); + } + t1 = P._convertJsonToDartLazy(parsed); + return t1; + }, + _convertJsonToDartLazy: function(object) { + var i; + if (object == null) + return null; + if (typeof object != "object") + return object; + if (Object.getPrototypeOf(object) !== Array.prototype) + return new P._JsonMap(object, Object.create(null)); + for (i = 0; i < object.length; ++i) + object[i] = P._convertJsonToDartLazy(object[i]); + return object; + }, + Utf8Decoder__convertIntercepted: function(allowMalformed, codeUnits, start, end) { + var casted, result; + if (codeUnits instanceof Uint8Array) { + casted = codeUnits; + end = casted.length; + if (end - start < 15) + return null; + result = P.Utf8Decoder__convertInterceptedUint8List(allowMalformed, casted, start, end); + if (result != null && allowMalformed) + if (result.indexOf("\ufffd") >= 0) + return null; + return result; + } + return null; + }, + Utf8Decoder__convertInterceptedUint8List: function(allowMalformed, codeUnits, start, end) { + var decoder = allowMalformed ? $.$get$Utf8Decoder__decoderNonfatal() : $.$get$Utf8Decoder__decoder(); + if (decoder == null) + return null; + if (0 === start && end === codeUnits.length) + return P.Utf8Decoder__useTextDecoder(decoder, codeUnits); + return P.Utf8Decoder__useTextDecoder(decoder, codeUnits.subarray(start, P.RangeError_checkValidRange(start, end, codeUnits.length))); + }, + Utf8Decoder__useTextDecoder: function(decoder, codeUnits) { + var t1, exception; + try { + t1 = decoder.decode(codeUnits); + return t1; + } catch (exception) { + H.unwrapException(exception); + } + return null; + }, + JsonUnsupportedObjectError$: function(unsupportedObject, cause, partialResult) { + return new P.JsonUnsupportedObjectError(unsupportedObject, cause); + }, + _defaultToEncodable: function(object) { + return object.toJson$0(); + }, + _JsonStringStringifier_stringify: function(object, toEncodable, indent) { + var t1, + output = new P.StringBuffer(""), + stringifier = new P._JsonStringStringifier(output, [], P.convert___defaultToEncodable$closure()); + stringifier.writeObject$1(object); + t1 = output._contents; + return t1.charCodeAt(0) == 0 ? t1 : t1; + }, + _Utf8Decoder_errorDescription: function(state) { + switch (state) { + case 65: + return "Missing extension byte"; + case 67: + return "Unexpected extension byte"; + case 69: + return "Invalid UTF-8 byte"; + case 71: + return "Overlong encoding"; + case 73: + return "Out of unicode range"; + case 75: + return "Encoded surrogate"; + case 77: + return "Unfinished UTF-8 octet sequence"; + default: + return ""; + } + }, + _JsonMap: function _JsonMap(t0, t1) { + this._original = t0; + this._processed = t1; + this._data = null; + }, + _JsonMapKeyIterable: function _JsonMapKeyIterable(t0) { + this._parent = t0; + }, + Utf8Decoder_closure: function Utf8Decoder_closure() { + }, + Utf8Decoder_closure0: function Utf8Decoder_closure0() { + }, + Codec: function Codec() { + }, + Converter: function Converter() { + }, + JsonUnsupportedObjectError: function JsonUnsupportedObjectError(t0, t1) { + this.unsupportedObject = t0; + this.cause = t1; + }, + JsonCyclicError: function JsonCyclicError(t0, t1) { + this.unsupportedObject = t0; + this.cause = t1; + }, + JsonCodec: function JsonCodec() { + }, + JsonEncoder: function JsonEncoder(t0) { + this._toEncodable = t0; + }, + JsonDecoder: function JsonDecoder(t0) { + this._reviver = t0; + }, + _JsonStringifier: function _JsonStringifier() { + }, + _JsonStringifier_writeMap_closure: function _JsonStringifier_writeMap_closure(t0, t1) { + this._box_0 = t0; + this.keyValueList = t1; + }, + _JsonStringStringifier: function _JsonStringStringifier(t0, t1, t2) { + this._sink = t0; + this._seen = t1; + this._toEncodable = t2; + }, + Utf8Decoder: function Utf8Decoder(t0) { + this._allowMalformed = t0; + }, + _Utf8Decoder: function _Utf8Decoder(t0) { + this.allowMalformed = t0; + this._convert$_state = 16; + this._charOrIndex = 0; + }, + _symbolMapToStringMap: function(map) { + var result = new H.JsLinkedHashMap(type$.JsLinkedHashMap_String_dynamic); + map.forEach$1(0, new P._symbolMapToStringMap_closure(result)); + return result; + }, + Function_apply: function($function, positionalArguments, namedArguments) { + return H.Primitives_applyFunction($function, positionalArguments, namedArguments == null ? null : P._symbolMapToStringMap(namedArguments)); + }, + int_parse: function(source) { + var value = H.Primitives_parseInt(source, null); + if (value != null) + return value; + throw H.wrapException(P.FormatException$(source, null, null)); + }, + Error__objectToString: function(object) { + if (object instanceof H.Closure) + return object.toString$0(0); + return "Instance of '" + H.S(H.Primitives_objectTypeName(object)) + "'"; + }, + List_List$filled: function($length, fill, growable, $E) { + var i, + result = growable ? J.JSArray_JSArray$growable($length, $E) : J.JSArray_JSArray$fixed($length, $E); + if ($length !== 0 && fill != null) + for (i = 0; i < result.length; ++i) + result[i] = fill; + return result; + }, + List_List$from: function(elements, growable, $E) { + var t1, + list = H.setRuntimeTypeInfo([], $E._eval$1("JSArray<0>")); + for (t1 = J.get$iterator$ax(elements); t1.moveNext$0();) + C.JSArray_methods.add$1(list, $E._as(t1.get$current())); + return list; + }, + String_String$fromCharCodes: function(charCodes, start, end) { + var array, len, t1; + if (Array.isArray(charCodes)) { + array = charCodes; + len = array.length; + end = P.RangeError_checkValidRange(start, end, len); + return H.Primitives_stringFromCharCodes(start > 0 || end < len ? array.slice(start, end) : array); + } + t1 = H.Primitives_stringFromNativeUint8List(charCodes, start, P.RangeError_checkValidRange(start, end, charCodes.length)); + return t1; + }, + StringBuffer__writeAll: function(string, objects, separator) { + var iterator = J.get$iterator$ax(objects); + if (!iterator.moveNext$0()) + return string; + if (separator.length === 0) { + do + string += H.S(iterator.get$current()); + while (iterator.moveNext$0()); + } else { + string += H.S(iterator.get$current()); + for (; iterator.moveNext$0();) + string = string + separator + H.S(iterator.get$current()); + } + return string; + }, + NoSuchMethodError$: function(receiver, memberName, positionalArguments, namedArguments) { + return new P.NoSuchMethodError(receiver, memberName, positionalArguments, namedArguments); + }, + StackTrace_current: function() { + var stackTrace, exception; + if (H.boolConversionCheck($.$get$_hasErrorStackProperty())) + return H.getTraceFromException(new Error()); + try { + throw H.wrapException(""); + } catch (exception) { + H.unwrapException(exception); + stackTrace = H.getTraceFromException(exception); + return stackTrace; + } + }, + DateTime__fourDigits: function(n) { + var absN = Math.abs(n), + sign = n < 0 ? "-" : ""; + if (absN >= 1000) + return "" + n; + if (absN >= 100) + return sign + "0" + absN; + if (absN >= 10) + return sign + "00" + absN; + return sign + "000" + absN; + }, + DateTime__threeDigits: function(n) { + if (n >= 100) + return "" + n; + if (n >= 10) + return "0" + n; + return "00" + n; + }, + DateTime__twoDigits: function(n) { + if (n >= 10) + return "" + n; + return "0" + n; + }, + Error_safeToString: function(object) { + if (typeof object == "number" || H._isBool(object) || null == object) + return J.toString$0$(object); + if (typeof object == "string") + return JSON.stringify(object); + return P.Error__objectToString(object); + }, + AssertionError$: function(message) { + return new P.AssertionError(message); + }, + ArgumentError$: function(message) { + return new P.ArgumentError(false, null, null, message); + }, + ArgumentError$value: function(value, $name, message) { + return new P.ArgumentError(true, value, $name, message); + }, + ArgumentError_checkNotNull: function(argument, $name, $T) { + if (argument == null) + throw H.wrapException(new P.ArgumentError(false, null, $name, "Must not be null")); + return argument; + }, + RangeError$: function(message) { + var _null = null; + return new P.RangeError(_null, _null, false, _null, _null, message); + }, + RangeError$value: function(value, $name) { + return new P.RangeError(null, null, true, value, $name, "Value not in range"); + }, + RangeError$range: function(invalidValue, minValue, maxValue, $name, message) { + return new P.RangeError(minValue, maxValue, true, invalidValue, $name, "Invalid value"); + }, + RangeError_checkValidRange: function(start, end, $length) { + if (0 > start || start > $length) + throw H.wrapException(P.RangeError$range(start, 0, $length, "start", null)); + if (end != null) { + if (start > end || end > $length) + throw H.wrapException(P.RangeError$range(end, start, $length, "end", null)); + return end; + } + return $length; + }, + RangeError_checkNotNegative: function(value, $name) { + if (value < 0) + throw H.wrapException(P.RangeError$range(value, 0, null, $name, null)); + return value; + }, + IndexError$: function(invalidValue, indexable, $name, message, $length) { + var t1 = H._asIntS($length == null ? J.get$length$asx(indexable) : $length); + return new P.IndexError(t1, true, invalidValue, $name, "Index out of range"); + }, + UnsupportedError$: function(message) { + return new P.UnsupportedError(message); + }, + UnimplementedError$: function(message) { + return new P.UnimplementedError(message); + }, + StateError$: function(message) { + return new P.StateError(message); + }, + ConcurrentModificationError$: function(modifiedObject) { + return new P.ConcurrentModificationError(modifiedObject); + }, + Exception_Exception: function(message) { + return new P._Exception(message); + }, + FormatException$: function(message, source, offset) { + return new P.FormatException(message, source, offset); + }, + _symbolMapToStringMap_closure: function _symbolMapToStringMap_closure(t0) { + this.result = t0; + }, + NoSuchMethodError_toString_closure: function NoSuchMethodError_toString_closure(t0, t1) { + this._box_0 = t0; + this.sb = t1; + }, + bool: function bool() { + }, + DateTime: function DateTime(t0, t1) { + this._value = t0; + this.isUtc = t1; + }, + double: function double() { + }, + Duration: function Duration(t0) { + this._duration = t0; + }, + Duration_toString_sixDigits: function Duration_toString_sixDigits() { + }, + Duration_toString_twoDigits: function Duration_toString_twoDigits() { + }, + Error0: function Error0() { + }, + AssertionError: function AssertionError(t0) { + this.message = t0; + }, + NullThrownError: function NullThrownError() { + }, + ArgumentError: function ArgumentError(t0, t1, t2, t3) { + var _ = this; + _._hasValue = t0; + _.invalidValue = t1; + _.name = t2; + _.message = t3; + }, + RangeError: function RangeError(t0, t1, t2, t3, t4, t5) { + var _ = this; + _.start = t0; + _.end = t1; + _._hasValue = t2; + _.invalidValue = t3; + _.name = t4; + _.message = t5; + }, + IndexError: function IndexError(t0, t1, t2, t3, t4) { + var _ = this; + _.length = t0; + _._hasValue = t1; + _.invalidValue = t2; + _.name = t3; + _.message = t4; + }, + NoSuchMethodError: function NoSuchMethodError(t0, t1, t2, t3) { + var _ = this; + _._core$_receiver = t0; + _._core$_memberName = t1; + _._core$_arguments = t2; + _._namedArguments = t3; + }, + UnsupportedError: function UnsupportedError(t0) { + this.message = t0; + }, + UnimplementedError: function UnimplementedError(t0) { + this.message = t0; + }, + StateError: function StateError(t0) { + this.message = t0; + }, + ConcurrentModificationError: function ConcurrentModificationError(t0) { + this.modifiedObject = t0; + }, + OutOfMemoryError: function OutOfMemoryError() { + }, + StackOverflowError: function StackOverflowError() { + }, + CyclicInitializationError: function CyclicInitializationError(t0) { + this.variableName = t0; + }, + _Exception: function _Exception(t0) { + this.message = t0; + }, + FormatException: function FormatException(t0, t1, t2) { + this.message = t0; + this.source = t1; + this.offset = t2; + }, + Function: function Function() { + }, + int: function int() { + }, + Iterable: function Iterable() { + }, + Iterator: function Iterator() { + }, + List: function List() { + }, + Map: function Map() { + }, + MapEntry: function MapEntry() { + }, + Null: function Null() { + }, + num: function num() { + }, + Object: function Object() { + }, + StackTrace: function StackTrace() { + }, + _StringStackTrace: function _StringStackTrace() { + }, + String: function String() { + }, + StringBuffer: function StringBuffer(t0) { + this._contents = t0; + }, + Symbol0: function Symbol0() { + }, + convertDartToNative_Dictionary: function(dict) { + var object = {}; + dict.forEach$1(0, new P.convertDartToNative_Dictionary_closure(object)); + return object; + }, + _AcceptStructuredClone: function _AcceptStructuredClone() { + }, + _AcceptStructuredClone_walk_closure: function _AcceptStructuredClone_walk_closure(t0, t1) { + this._box_0 = t0; + this.$this = t1; + }, + convertDartToNative_Dictionary_closure: function convertDartToNative_Dictionary_closure(t0) { + this.object = t0; + }, + _AcceptStructuredCloneDart2Js: function _AcceptStructuredCloneDart2Js(t0, t1) { + this.values = t0; + this.copies = t1; + this.mustCopy = false; + }, + promiseToFuture: function(jsPromise, $T) { + var t1 = new P._Future($.Zone__current, $T._eval$1("_Future<0>")), + completer = new P._AsyncCompleter(t1, $T._eval$1("_AsyncCompleter<0>")); + jsPromise.then(H.convertDartClosureToJS(new P.promiseToFuture_closure(completer, $T), 1), H.convertDartClosureToJS(new P.promiseToFuture_closure0(completer), 1)); + return t1; + }, + promiseToFuture_closure: function promiseToFuture_closure(t0, t1) { + this.completer = t0; + this.T = t1; + }, + promiseToFuture_closure0: function promiseToFuture_closure0(t0) { + this.completer = t0; + }, + _JSRandom: function _JSRandom() { + }, + ByteBuffer: function ByteBuffer() { + }, + ByteData: function ByteData() { + }, + Int8List: function Int8List() { + }, + Uint8List: function Uint8List() { + }, + Uint8ClampedList: function Uint8ClampedList() { + }, + Int16List: function Int16List() { + }, + Uint16List: function Uint16List() { + }, + Int32List: function Int32List() { + }, + Uint32List: function Uint32List() { + }, + Float32List: function Float32List() { + }, + Float64List: function Float64List() { + } + }, + W = { + EventSource__factoryEventSource: function(url, eventSourceInitDict) { + var t1 = new EventSource(url, P.convertDartToNative_Dictionary(eventSourceInitDict)); + return t1; + }, + HttpRequest_request: function(url, method, sendData, withCredentials) { + var t2, t3, t4, + t1 = new P._Future($.Zone__current, type$._Future_HttpRequest), + completer = new P._AsyncCompleter(t1, type$._AsyncCompleter_HttpRequest), + xhr = new XMLHttpRequest(); + C.HttpRequest_methods.open$3$async(xhr, method, url, true); + xhr.withCredentials = true; + t2 = type$.nullable_void_Function_legacy_ProgressEvent; + t3 = t2._as(new W.HttpRequest_request_closure(xhr, completer)); + type$.nullable_void_Function._as(null); + t4 = type$.legacy_ProgressEvent; + W._EventStreamSubscription$(xhr, "load", t3, false, t4); + W._EventStreamSubscription$(xhr, "error", t2._as(completer.get$completeError()), false, t4); + xhr.send(sendData); + return t1; + }, + _EventStreamSubscription$: function(_target, _eventType, onData, _useCapture, $T) { + var t1 = onData == null ? null : W._wrapZone(new W._EventStreamSubscription_closure(onData), type$.Event); + t1 = new W._EventStreamSubscription(_target, _eventType, t1, false, $T._eval$1("_EventStreamSubscription<0>")); + t1._tryResume$0(); + return t1; + }, + _wrapZone: function(callback, $T) { + var t1 = $.Zone__current; + if (t1 === C.C__RootZone) + return callback; + return t1.bindUnaryCallbackGuarded$1$1(callback, $T); + }, + DomException: function DomException() { + }, + Event0: function Event0() { + }, + EventSource: function EventSource() { + }, + EventTarget: function EventTarget() { + }, + HttpRequest: function HttpRequest() { + }, + HttpRequest_request_closure: function HttpRequest_request_closure(t0, t1) { + this.xhr = t0; + this.completer = t1; + }, + HttpRequestEventTarget: function HttpRequestEventTarget() { + }, + MessageEvent: function MessageEvent() { + }, + ProgressEvent: function ProgressEvent() { + }, + EventStreamProvider: function EventStreamProvider(t0, t1) { + this._eventType = t0; + this.$ti = t1; + }, + _EventStream: function _EventStream(t0, t1, t2, t3) { + var _ = this; + _._target = t0; + _._eventType = t1; + _._useCapture = t2; + _.$ti = t3; + }, + _EventStreamSubscription: function _EventStreamSubscription(t0, t1, t2, t3, t4) { + var _ = this; + _._pauseCount = 0; + _._target = t0; + _._eventType = t1; + _._onData = t2; + _._useCapture = t3; + _.$ti = t4; + }, + _EventStreamSubscription_closure: function _EventStreamSubscription_closure(t0) { + this.onData = t0; + }, + _EventStreamSubscription_onData_closure: function _EventStreamSubscription_onData_closure(t0) { + this.handleData = t0; + } + }, + V = {ErrorResult: function ErrorResult(t0, t1) { + this.error = t0; + this.stackTrace = t1; + }}, + E = {Result: function Result() { + }, + main: function() { + var $async$goto = 0, + $async$completer = P._makeAsyncAwaitCompleter(type$.void), + ddsChannel, vmService, id, message, channel, t1, t2, t3, $async$temp1, $async$temp2, $async$temp3; + var $async$main = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { + if ($async$errorCode === 1) + return P._asyncRethrow($async$result, $async$completer); + while (true) + switch ($async$goto) { + case 0: + // Function start + channel = M.SseClient$("/test"); + t1 = channel._incomingController; + t2 = new Q.QueueList(type$.QueueList_legacy_Result_legacy_String); + t3 = new Array(8); + t3.fixed$length = Array; + t2.set$_table(H.setRuntimeTypeInfo(t3, type$.JSArray_legacy_Result_legacy_String)); + $async$temp1 = M; + $async$goto = 2; + return P._asyncAwait(new G.StreamQueue(new P._ControllerStream(t1, H._instanceType(t1)._eval$1("_ControllerStream<1>")), t2, new P.ListQueue(P.List_List$filled(P.ListQueue__calculateCapacity(null), null, false, type$.nullable__EventRequest_dynamic), type$.ListQueue_legacy__EventRequest_dynamic), type$.StreamQueue_legacy_String).get$next(), $async$main); + case 2: + // returning from await. + ddsChannel = $async$temp1.SseClient$($async$result); + t2 = new W._EventStream(ddsChannel._eventSource, "open", false, type$._EventStream_legacy_Event); + $async$goto = 3; + return P._asyncAwait(t2.get$first(t2), $async$main); + case 3: + // returning from await. + t2 = ddsChannel._incomingController; + vmService = Q.VmService$(new P._ControllerStream(t2, H._instanceType(t2)._eval$1("_ControllerStream<1>")), new E.main_closure(ddsChannel)); + id = "" + ++vmService._id; + t2 = new P._Future($.Zone__current, type$._Future_legacy_Version); + vmService._completers.$indexSet(0, id, new P._AsyncCompleter(t2, type$._AsyncCompleter_legacy_Version)); + vmService._methodCalls.$indexSet(0, id, "getVersion"); + t1 = type$.dynamic; + message = C.C_JsonCodec.encode$2$toEncodable(P.LinkedHashMap_LinkedHashMap$_literal(["jsonrpc", "2.0", "id", id, "method", "getVersion", "params", C.Map_empty], t1, t1), null); + vmService._onSend.add$1(0, message); + vmService._writeMessage.call$1(message); + t1 = channel._outgoingController; + $async$temp1 = t1; + $async$temp2 = H._instanceType(t1)._precomputed1; + $async$temp3 = C.C_JsonCodec; + $async$goto = 4; + return P._asyncAwait(t2, $async$main); + case 4: + // returning from await. + $async$temp1.add$1(0, $async$temp2._as($async$temp3.encode$1($async$result.json))); + ddsChannel.close$0(0); + // implicit return + return P._asyncReturn(null, $async$completer); + } + }); + return P._asyncStartSync($async$main, $async$completer); + }, + main_closure: function main_closure(t0) { + this.ddsChannel = t0; + } + }, + F = {ValueResult: function ValueResult(t0, t1) { + this.value = t0; + this.$ti = t1; + }, + Logger_Logger: function($name) { + return $.Logger__loggers.putIfAbsent$2($name, new F.Logger_Logger_closure($name)); + }, + Logger: function Logger(t0, t1, t2) { + var _ = this; + _.name = t0; + _.parent = t1; + _._level = null; + _._children = t2; + }, + Logger_Logger_closure: function Logger_Logger_closure(t0) { + this.name = t0; + } + }, + G = {StreamQueue: function StreamQueue(t0, t1, t2, t3) { + var _ = this; + _._source = t0; + _._subscription = null; + _._isDone = false; + _._eventsReceived = 0; + _._eventQueue = t1; + _._requestQueue = t2; + _.$ti = t3; + }, StreamQueue__ensureListening_closure: function StreamQueue__ensureListening_closure(t0) { + this.$this = t0; + }, StreamQueue__ensureListening_closure1: function StreamQueue__ensureListening_closure1(t0) { + this.$this = t0; + }, StreamQueue__ensureListening_closure0: function StreamQueue__ensureListening_closure0(t0) { + this.$this = t0; + }, _EventRequest: function _EventRequest() { + }, _NextRequest: function _NextRequest(t0, t1) { + this._completer = t0; + this.$ti = t1; + }}, + Q = {QueueList: function QueueList(t0) { + var _ = this; + _._table = null; + _._queue_list$_tail = _._queue_list$_head = 0; + _.$ti = t0; + }, _QueueList_Object_ListMixin: function _QueueList_Object_ListMixin() { + }, + createServiceObject: function(json, expectedTypes) { + var t1, type, _null = null; + if (json == null) + return _null; + if (type$.legacy_List_dynamic._is(json)) { + t1 = J.map$1$1$ax(json, new Q.createServiceObject_closure(expectedTypes), type$.legacy_Object); + return P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")); + } else if (type$.legacy_Map_dynamic_dynamic._is(json)) { + type = H._asStringS(json.$index(0, "type")); + if (type == null) + if (expectedTypes.length === 1) + type = (expectedTypes && C.JSArray_methods).get$first(expectedTypes); + else + return _null; + else if (J.$eq$(json.$index(0, "type"), "@Instance") && J.$eq$(json.$index(0, "kind"), "Null") && !(expectedTypes && C.JSArray_methods).contains$1(expectedTypes, type)) + return _null; + if ($._typeFactories.$index(0, type) == null) + return _null; + else + return $._typeFactories.$index(0, type).call$1(json); + } else + return json; + }, + _createSpecificObject: function(json, creator) { + var t1, t2, key; + if (json == null) + return null; + if (type$.legacy_List_dynamic._is(json)) { + t1 = J.map$1$1$ax(json, new Q._createSpecificObject_closure(creator), type$.dynamic); + return P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")); + } else if (type$.legacy_Map_dynamic_dynamic._is(json)) { + t1 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic); + for (t2 = json.get$keys(), t2 = t2.get$iterator(t2); t2.moveNext$0();) { + key = H._asStringS(t2.get$current()); + t1.$indexSet(0, key, json.$index(0, key)); + } + return creator.call$1(t1); + } else + return json; + }, + _setIfNotNull: function(json, key, value) { + if (value == null) + return; + json.$indexSet(0, key, value); + }, + VmService$: function(inStream, writeMessage) { + var t1 = type$.legacy_String; + t1 = new Q.VmService(P.LinkedHashMap_LinkedHashMap$_empty(t1, type$.legacy_Completer_dynamic), P.LinkedHashMap_LinkedHashMap$_empty(t1, t1), P.LinkedHashMap_LinkedHashMap$_empty(t1, type$.legacy_legacy_Future_legacy_Map_of_legacy_String_and_dynamic_Function_legacy_Map_of_legacy_String_and_dynamic), P.StreamController_StreamController$broadcast(true, t1), P.StreamController_StreamController$broadcast(true, t1), new P._AsyncCompleter(new P._Future($.Zone__current, type$._Future_dynamic), type$._AsyncCompleter_dynamic), P.LinkedHashMap_LinkedHashMap$_empty(t1, type$.legacy_StreamController_legacy_Event)); + t1.VmService$5$disposeHandler$log$streamClosed(inStream, writeMessage, null, null, null); + return t1; + }, + ExtensionData_parse: function(json) { + return json == null ? null : new Q.ExtensionData(json); + }, + AllocationProfile_parse: function(json) { + var t1, t2, + _s24_ = "dateLastAccumulatorReset", + _s17_ = "dateLastServiceGC"; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.AllocationProfile(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "members"), C.List_ClassHeapStats); + if (t2 == null) + t2 = []; + t1.set$members(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ClassHeapStats)); + t1.memoryUsage = type$.legacy_MemoryUsage._as(Q.createServiceObject(json.$index(0, "memoryUsage"), C.List_MemoryUsage)); + t1.dateLastAccumulatorReset = H._asIntS(typeof json.$index(0, _s24_) == "string" ? P.int_parse(H._asStringS(json.$index(0, _s24_))) : json.$index(0, _s24_)); + t1.dateLastServiceGC = H._asIntS(typeof json.$index(0, _s17_) == "string" ? P.int_parse(H._asStringS(json.$index(0, _s17_))) : json.$index(0, _s17_)); + return t1; + }, + BoundField_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.BoundField(); + t1.decl = type$.legacy_FieldRef._as(Q.createServiceObject(json.$index(0, "decl"), C.List_FieldRef)); + t1.value = Q.createServiceObject(json.$index(0, "value"), C.List_InstanceRef_Sentinel); + return t1; + }, + BoundVariable_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.BoundVariable(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.name = H._asStringS(json.$index(0, "name")); + t1.value = Q.createServiceObject(json.$index(0, "value"), C.List_PAk); + t1.declarationTokenPos = H._asIntS(json.$index(0, "declarationTokenPos")); + t1.scopeStartTokenPos = H._asIntS(json.$index(0, "scopeStartTokenPos")); + t1.scopeEndTokenPos = H._asIntS(json.$index(0, "scopeEndTokenPos")); + return t1; + }, + Breakpoint_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Breakpoint(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.breakpointNumber = H._asIntS(json.$index(0, "breakpointNumber")); + t1.resolved = H._asBoolS(json.$index(0, "resolved")); + t1.isSyntheticAsyncContinuation = H._asBoolS(json.$index(0, "isSyntheticAsyncContinuation")); + t1.location = Q.createServiceObject(json.$index(0, "location"), C.List_oqh); + return t1; + }, + ClassRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ClassRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + return t1; + }, + Class_parse: function(json) { + var t1, t2, t3, t4, t5; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Class(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.error = type$.legacy_ErrorRef._as(Q.createServiceObject(json.$index(0, "error"), C.List_ErrorRef)); + t1.isAbstract = H._asBoolS(json.$index(0, "abstract")); + t1.isConst = H._asBoolS(json.$index(0, "const")); + t1.library = type$.legacy_LibraryRef._as(Q.createServiceObject(json.$index(0, "library"), C.List_LibraryRef)); + t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation)); + t2 = type$.legacy_ClassRef; + t1.superClass = t2._as(Q.createServiceObject(json.$index(0, "super"), C.List_ClassRef)); + t3 = type$.legacy_InstanceRef; + t1.superType = t3._as(Q.createServiceObject(json.$index(0, "superType"), C.List_InstanceRef)); + t4 = Q.createServiceObject(json.$index(0, "interfaces"), C.List_InstanceRef); + if (t4 == null) + t4 = []; + t5 = type$.Iterable_dynamic; + t1.set$interfaces(P.List_List$from(t5._as(t4), true, t3)); + t1.mixin = t3._as(Q.createServiceObject(json.$index(0, "mixin"), C.List_InstanceRef)); + t3 = Q.createServiceObject(json.$index(0, "fields"), C.List_FieldRef); + t1.set$fields(P.List_List$from(t5._as(t3 == null ? [] : t3), true, type$.legacy_FieldRef)); + t3 = Q.createServiceObject(json.$index(0, "functions"), C.List_FuncRef); + t1.set$functions(P.List_List$from(t5._as(t3 == null ? [] : t3), true, type$.legacy_FuncRef)); + t3 = Q.createServiceObject(json.$index(0, "subclasses"), C.List_ClassRef); + t1.set$subclasses(P.List_List$from(t5._as(t3 == null ? [] : t3), true, t2)); + return t1; + }, + ClassHeapStats_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ClassHeapStats(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.classRef = type$.legacy_ClassRef._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef)); + t1.accumulatedSize = H._asIntS(json.$index(0, "accumulatedSize")); + t1.bytesCurrent = H._asIntS(json.$index(0, "bytesCurrent")); + t1.instancesAccumulated = H._asIntS(json.$index(0, "instancesAccumulated")); + t1.instancesCurrent = H._asIntS(json.$index(0, "instancesCurrent")); + return t1; + }, + ClassList_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ClassList(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "classes"), C.List_ClassRef); + if (t2 == null) + t2 = []; + t1.set$classes(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ClassRef)); + return t1; + }, + ClientName_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ClientName(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.name = H._asStringS(json.$index(0, "name")); + return t1; + }, + CodeRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.CodeRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.kind = H._asStringS(json.$index(0, "kind")); + return t1; + }, + Code_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Code(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.kind = H._asStringS(json.$index(0, "kind")); + return t1; + }, + ContextRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ContextRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.length = H._asIntS(json.$index(0, "length")); + return t1; + }, + Context_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Context(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.length = H._asIntS(json.$index(0, "length")); + t1.parent = type$.legacy_Context._as(Q.createServiceObject(json.$index(0, "parent"), C.List_Context)); + t2 = Q.createServiceObject(json.$index(0, "variables"), C.List_ContextElement); + if (t2 == null) + t2 = []; + t1.set$variables(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ContextElement)); + return t1; + }, + ContextElement_parse: function(json) { + var t1 = new Q.ContextElement(); + t1.value = Q.createServiceObject(type$.legacy_Map_of_legacy_String_and_dynamic._as(json).$index(0, "value"), C.List_InstanceRef_Sentinel); + return t1; + }, + CpuSamples_parse: function(json) { + var t1, t2, t3; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.CpuSamples(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.samplePeriod = H._asIntS(json.$index(0, "samplePeriod")); + t1.maxStackDepth = H._asIntS(json.$index(0, "maxStackDepth")); + t1.sampleCount = H._asIntS(json.$index(0, "sampleCount")); + t1.timeSpan = H._asIntS(json.$index(0, "timeSpan")); + t1.timeOriginMicros = H._asIntS(json.$index(0, "timeOriginMicros")); + t1.timeExtentMicros = H._asIntS(json.$index(0, "timeExtentMicros")); + t1.pid = H._asIntS(json.$index(0, "pid")); + t2 = Q.createServiceObject(json.$index(0, "functions"), C.List_ProfileFunction); + if (t2 == null) + t2 = []; + t3 = type$.Iterable_dynamic; + t1.set$functions(P.List_List$from(t3._as(t2), true, type$.legacy_ProfileFunction)); + t2 = Q.createServiceObject(json.$index(0, "samples"), C.List_CpuSample); + t1.set$samples(P.List_List$from(t3._as(t2 == null ? [] : t2), true, type$.legacy_CpuSample)); + return t1; + }, + CpuSample_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.CpuSample(); + t1.tid = H._asIntS(json.$index(0, "tid")); + t1.timestamp = H._asIntS(json.$index(0, "timestamp")); + t1.vmTag = H._asStringS(json.$index(0, "vmTag")); + t1.userTag = H._asStringS(json.$index(0, "userTag")); + t1.truncated = H._asBoolS(json.$index(0, "truncated")); + t1.set$stack(P.List_List$from(type$.Iterable_dynamic._as(json.$index(0, "stack")), true, type$.legacy_int)); + return t1; + }, + ErrorRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ErrorRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.kind = H._asStringS(json.$index(0, "kind")); + t1.message = H._asStringS(json.$index(0, "message")); + return t1; + }, + Error_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Error(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.kind = H._asStringS(json.$index(0, "kind")); + t1.message = H._asStringS(json.$index(0, "message")); + t2 = type$.legacy_InstanceRef; + t1.exception = t2._as(Q.createServiceObject(json.$index(0, "exception"), C.List_InstanceRef)); + t1.stacktrace = t2._as(Q.createServiceObject(json.$index(0, "stacktrace"), C.List_InstanceRef)); + return t1; + }, + Event_parse: function(json) { + var t1, t2, _null = null, + _s16_ = "pauseBreakpoints", + _s14_ = "timelineEvents", + _s14_0 = "updatedStreams"; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Event(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.kind = H._asStringS(json.$index(0, "kind")); + t1.isolate = type$.legacy_IsolateRef._as(Q.createServiceObject(json.$index(0, "isolate"), C.List_IsolateRef)); + t1.vm = type$.legacy_VMRef._as(Q.createServiceObject(json.$index(0, "vm"), C.List_VMRef)); + t1.timestamp = H._asIntS(json.$index(0, "timestamp")); + t2 = type$.legacy_Breakpoint; + t1.breakpoint = t2._as(Q.createServiceObject(json.$index(0, "breakpoint"), C.List_Breakpoint)); + t1.set$pauseBreakpoints(json.$index(0, _s16_) == null ? _null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, _s16_), C.List_Breakpoint)), true, t2)); + t1.topFrame = type$.legacy_Frame._as(Q.createServiceObject(json.$index(0, "topFrame"), C.List_Frame)); + t2 = type$.legacy_InstanceRef; + t1.exception = t2._as(Q.createServiceObject(json.$index(0, "exception"), C.List_InstanceRef)); + t1.bytes = H._asStringS(json.$index(0, "bytes")); + t1.inspectee = t2._as(Q.createServiceObject(json.$index(0, "inspectee"), C.List_InstanceRef)); + t1.extensionRPC = H._asStringS(json.$index(0, "extensionRPC")); + t1.extensionKind = H._asStringS(json.$index(0, "extensionKind")); + t2 = type$.legacy_Map_dynamic_dynamic._as(json.$index(0, "extensionData")); + t1.extensionData = t2 == null ? _null : new Q.ExtensionData(t2); + t1.set$timelineEvents(json.$index(0, _s14_) == null ? _null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, _s14_), C.List_TimelineEvent)), true, type$.legacy_TimelineEvent)); + t1.set$updatedStreams(json.$index(0, _s14_0) == null ? _null : P.List_List$from(type$.Iterable_dynamic._as(json.$index(0, _s14_0)), true, type$.legacy_String)); + t1.atAsyncSuspension = H._asBoolS(json.$index(0, "atAsyncSuspension")); + t1.status = H._asStringS(json.$index(0, "status")); + t1.logRecord = type$.legacy_LogRecord._as(Q.createServiceObject(json.$index(0, "logRecord"), C.List_LogRecord)); + t1.service = H._asStringS(json.$index(0, "service")); + t1.method = H._asStringS(json.$index(0, "method")); + t1.alias = H._asStringS(json.$index(0, "alias")); + t1.flag = H._asStringS(json.$index(0, "flag")); + t1.newValue = H._asStringS(json.$index(0, "newValue")); + t1.last = H._asBoolS(json.$index(0, "last")); + t1.data = type$.legacy_ByteData._as(json.$index(0, "data")); + return t1; + }, + FieldRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.FieldRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.owner = type$.legacy_ObjRef._as(Q.createServiceObject(json.$index(0, "owner"), C.List_ObjRef)); + t1.declaredType = type$.legacy_InstanceRef._as(Q.createServiceObject(json.$index(0, "declaredType"), C.List_InstanceRef)); + t1.isConst = H._asBoolS(json.$index(0, "const")); + t1.isFinal = H._asBoolS(json.$index(0, "final")); + t1.isStatic = H._asBoolS(json.$index(0, "static")); + return t1; + }, + Field_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Field(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.owner = type$.legacy_ObjRef._as(Q.createServiceObject(json.$index(0, "owner"), C.List_ObjRef)); + t2 = type$.legacy_InstanceRef; + t1.declaredType = t2._as(Q.createServiceObject(json.$index(0, "declaredType"), C.List_InstanceRef)); + t1.isConst = H._asBoolS(json.$index(0, "const")); + t1.isFinal = H._asBoolS(json.$index(0, "final")); + t1.isStatic = H._asBoolS(json.$index(0, "static")); + t1.staticValue = t2._as(Q.createServiceObject(json.$index(0, "staticValue"), C.List_InstanceRef)); + t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation)); + return t1; + }, + Flag_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Flag(); + t1.name = H._asStringS(json.$index(0, "name")); + t1.comment = H._asStringS(json.$index(0, "comment")); + t1.modified = H._asBoolS(json.$index(0, "modified")); + t1.valueAsString = H._asStringS(json.$index(0, "valueAsString")); + return t1; + }, + FlagList_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.FlagList(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "flags"), C.List_Flag); + if (t2 == null) + t2 = []; + t1.set$flags(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_Flag)); + return t1; + }, + Frame_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Frame(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.index = H._asIntS(json.$index(0, "index")); + t1.$function = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "function"), C.List_FuncRef)); + t1.code = type$.legacy_CodeRef._as(Q.createServiceObject(json.$index(0, "code"), C.List_CodeRef)); + t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation)); + t1.set$vars(json.$index(0, "vars") == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, "vars"), C.List_BoundVariable)), true, type$.legacy_BoundVariable)); + t1.kind = H._asStringS(json.$index(0, "kind")); + return t1; + }, + FuncRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.FuncRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.owner = Q.createServiceObject(json.$index(0, "owner"), C.List_LibraryRef_ClassRef_FuncRef); + t1.isStatic = H._asBoolS(json.$index(0, "static")); + t1.isConst = H._asBoolS(json.$index(0, "const")); + return t1; + }, + Func_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Func(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.owner = Q.createServiceObject(json.$index(0, "owner"), C.List_LibraryRef_ClassRef_FuncRef); + t1.isStatic = H._asBoolS(json.$index(0, "static")); + t1.isConst = H._asBoolS(json.$index(0, "const")); + t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation)); + t1.code = type$.legacy_CodeRef._as(Q.createServiceObject(json.$index(0, "code"), C.List_CodeRef)); + return t1; + }, + InstanceRef_parse: function(json) { + var t1 = Q.InstanceRef$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + return t1; + }, + InstanceRef$_fromJson: function(json) { + var t1 = new Q.InstanceRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.InstanceRef$_fromJson$1(json); + return t1; + }, + Instance_parse: function(json) { + var t1 = Q.Instance$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + return t1; + }, + Instance$_fromJson: function(json) { + var t1 = new Q.Instance(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.Instance$_fromJson$1(json); + return t1; + }, + IsolateRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.IsolateRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.id = H._asStringS(json.$index(0, "id")); + t1.number = H._asStringS(json.$index(0, "number")); + t1.name = H._asStringS(json.$index(0, "name")); + return t1; + }, + Isolate_parse: function(json) { + var t1, t2, t3, t4, + _s13_ = "extensionRPCs"; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Isolate(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.id = H._asStringS(json.$index(0, "id")); + t1.number = H._asStringS(json.$index(0, "number")); + t1.name = H._asStringS(json.$index(0, "name")); + t1.startTime = H._asIntS(json.$index(0, "startTime")); + t1.runnable = H._asBoolS(json.$index(0, "runnable")); + t1.livePorts = H._asIntS(json.$index(0, "livePorts")); + t1.pauseOnExit = H._asBoolS(json.$index(0, "pauseOnExit")); + t1.pauseEvent = type$.legacy_Event._as(Q.createServiceObject(json.$index(0, "pauseEvent"), C.List_Event)); + t2 = type$.legacy_LibraryRef; + t1.rootLib = t2._as(Q.createServiceObject(json.$index(0, "rootLib"), C.List_LibraryRef)); + t3 = Q.createServiceObject(json.$index(0, "libraries"), C.List_LibraryRef); + if (t3 == null) + t3 = []; + t4 = type$.Iterable_dynamic; + t1.set$libraries(P.List_List$from(t4._as(t3), true, t2)); + t2 = Q.createServiceObject(json.$index(0, "breakpoints"), C.List_Breakpoint); + t1.set$breakpoints(P.List_List$from(t4._as(t2 == null ? [] : t2), true, type$.legacy_Breakpoint)); + t1.error = type$.legacy_Error._as(Q.createServiceObject(json.$index(0, "error"), C.List_Error)); + t1.exceptionPauseMode = H._asStringS(json.$index(0, "exceptionPauseMode")); + t1.set$extensionRPCs(json.$index(0, _s13_) == null ? null : P.List_List$from(t4._as(json.$index(0, _s13_)), true, type$.legacy_String)); + return t1; + }, + IsolateGroupRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.IsolateGroupRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.id = H._asStringS(json.$index(0, "id")); + t1.number = H._asStringS(json.$index(0, "number")); + t1.name = H._asStringS(json.$index(0, "name")); + return t1; + }, + IsolateGroup_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.IsolateGroup(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.id = H._asStringS(json.$index(0, "id")); + t1.number = H._asStringS(json.$index(0, "number")); + t1.name = H._asStringS(json.$index(0, "name")); + t2 = Q.createServiceObject(json.$index(0, "isolates"), C.List_IsolateRef); + if (t2 == null) + t2 = []; + t1.set$isolates(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_IsolateRef)); + return t1; + }, + InboundReferences_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.InboundReferences(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "references"), C.List_InboundReference); + if (t2 == null) + t2 = []; + t1.set$references(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_InboundReference)); + return t1; + }, + InboundReference_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.InboundReference(); + t1.source = type$.legacy_ObjRef._as(Q.createServiceObject(json.$index(0, "source"), C.List_ObjRef)); + t1.parentListIndex = H._asIntS(json.$index(0, "parentListIndex")); + t1.parentField = type$.legacy_FieldRef._as(Q.createServiceObject(json.$index(0, "parentField"), C.List_FieldRef)); + return t1; + }, + InstanceSet_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.InstanceSet(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.totalCount = H._asIntS(json.$index(0, "totalCount")); + t2 = json.$index(0, "instances"); + t1.set$instances(P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(t2 == null ? json.$index(0, "samples") : t2, C.List_ObjRef)), true, type$.legacy_ObjRef)); + return t1; + }, + LibraryRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.LibraryRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.uri = H._asStringS(json.$index(0, "uri")); + return t1; + }, + Library_parse: function(json) { + var t1, t2, t3; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Library(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t1.uri = H._asStringS(json.$index(0, "uri")); + t1.debuggable = H._asBoolS(json.$index(0, "debuggable")); + t2 = type$.Iterable_dynamic; + t1.set$dependencies(P.List_List$from(t2._as(Q._createSpecificObject(json.$index(0, "dependencies"), Q.vm_service_LibraryDependency_parse$closure())), true, type$.legacy_LibraryDependency)); + t3 = Q.createServiceObject(json.$index(0, "scripts"), C.List_ScriptRef); + t1.set$scripts(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_ScriptRef)); + t3 = Q.createServiceObject(json.$index(0, "variables"), C.List_FieldRef); + t1.set$variables(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_FieldRef)); + t3 = Q.createServiceObject(json.$index(0, "functions"), C.List_FuncRef); + t1.set$functions(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_FuncRef)); + t3 = Q.createServiceObject(json.$index(0, "classes"), C.List_ClassRef); + t1.set$classes(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_ClassRef)); + return t1; + }, + LibraryDependency_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + if (json == null) + t1 = null; + else { + t1 = new Q.LibraryDependency(); + t1.isImport = H._asBoolS(json.$index(0, "isImport")); + t1.isDeferred = H._asBoolS(json.$index(0, "isDeferred")); + t1.prefix = H._asStringS(json.$index(0, "prefix")); + t1.target = type$.legacy_LibraryRef._as(Q.createServiceObject(json.$index(0, "target"), C.List_LibraryRef)); + } + return t1; + }, + LogRecord_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.LogRecord(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = type$.legacy_InstanceRef; + t1.message = t2._as(Q.createServiceObject(json.$index(0, "message"), C.List_InstanceRef)); + t1.time = H._asIntS(json.$index(0, "time")); + t1.level = H._asIntS(json.$index(0, "level")); + t1.sequenceNumber = H._asIntS(json.$index(0, "sequenceNumber")); + t1.loggerName = t2._as(Q.createServiceObject(json.$index(0, "loggerName"), C.List_InstanceRef)); + t1.zone = t2._as(Q.createServiceObject(json.$index(0, "zone"), C.List_InstanceRef)); + t1.error = t2._as(Q.createServiceObject(json.$index(0, "error"), C.List_InstanceRef)); + t1.stackTrace = t2._as(Q.createServiceObject(json.$index(0, "stackTrace"), C.List_InstanceRef)); + return t1; + }, + MapAssociation_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + if (json == null) + t1 = null; + else { + t1 = new Q.MapAssociation(); + t1.key = Q.createServiceObject(json.$index(0, "key"), C.List_InstanceRef_Sentinel); + t1.value = Q.createServiceObject(json.$index(0, "value"), C.List_InstanceRef_Sentinel); + } + return t1; + }, + MemoryUsage_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.MemoryUsage(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.externalUsage = H._asIntS(json.$index(0, "externalUsage")); + t1.heapCapacity = H._asIntS(json.$index(0, "heapCapacity")); + t1.heapUsage = H._asIntS(json.$index(0, "heapUsage")); + return t1; + }, + Message_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Message(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.index = H._asIntS(json.$index(0, "index")); + t1.name = H._asStringS(json.$index(0, "name")); + t1.messageObjectId = H._asStringS(json.$index(0, "messageObjectId")); + t1.size = H._asIntS(json.$index(0, "size")); + t1.handler = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "handler"), C.List_FuncRef)); + t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation)); + return t1; + }, + NativeFunction_parse: function(json) { + var t1 = new Q.NativeFunction(); + t1.name = H._asStringS(type$.legacy_Map_of_legacy_String_and_dynamic._as(json).$index(0, "name")); + return t1; + }, + NullValRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.NullValRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.InstanceRef$_fromJson$1(json); + t1.NullValRef_valueAsString = H._asStringS(json.$index(0, "valueAsString")); + return t1; + }, + NullVal_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.NullVal(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.Instance$_fromJson$1(json); + t1.NullVal_valueAsString = H._asStringS(json.$index(0, "valueAsString")); + return t1; + }, + ObjRef_parse: function(json) { + var t1 = Q.ObjRef$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + return t1; + }, + ObjRef$_fromJson: function(json) { + var t1 = new Q.ObjRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + return t1; + }, + Obj_parse: function(json) { + var t1 = Q.Obj$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + return t1; + }, + Obj$_fromJson: function(json) { + var t1 = new Q.Obj(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + return t1; + }, + ProfileFunction_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ProfileFunction(); + t1.kind = H._asStringS(json.$index(0, "kind")); + t1.inclusiveTicks = H._asIntS(json.$index(0, "inclusiveTicks")); + t1.exclusiveTicks = H._asIntS(json.$index(0, "exclusiveTicks")); + t1.resolvedUrl = H._asStringS(json.$index(0, "resolvedUrl")); + t1.$function = Q.createServiceObject(json.$index(0, "function"), C.List_dynamic); + return t1; + }, + ReloadReport_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ReloadReport(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.success = H._asBoolS(json.$index(0, "success")); + return t1; + }, + RetainingObject_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.RetainingObject(); + t2 = type$.legacy_ObjRef; + t1.value = t2._as(Q.createServiceObject(json.$index(0, "value"), C.List_ObjRef)); + t1.parentListIndex = H._asIntS(json.$index(0, "parentListIndex")); + t1.parentMapKey = t2._as(Q.createServiceObject(json.$index(0, "parentMapKey"), C.List_ObjRef)); + t1.parentField = H._asStringS(json.$index(0, "parentField")); + return t1; + }, + RetainingPath_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.RetainingPath(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.length = H._asIntS(json.$index(0, "length")); + t1.gcRootType = H._asStringS(json.$index(0, "gcRootType")); + t2 = Q.createServiceObject(json.$index(0, "elements"), C.List_RetainingObject); + if (t2 == null) + t2 = []; + t1.set$elements(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_RetainingObject)); + return t1; + }, + Response_parse: function(json) { + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + return json == null ? null : Q.Response$_fromJson(json); + }, + Response$_fromJson: function(json) { + var t1 = new Q.Response(json); + t1.type = H._asStringS(json.$index(0, "type")); + return t1; + }, + Sentinel_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Sentinel(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.kind = H._asStringS(json.$index(0, "kind")); + t1.valueAsString = H._asStringS(json.$index(0, "valueAsString")); + return t1; + }, + Sentinel$_fromJson: function(json) { + var t1 = new Q.Sentinel(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.kind = H._asStringS(json.$index(0, "kind")); + t1.valueAsString = H._asStringS(json.$index(0, "valueAsString")); + return t1; + }, + ScriptRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ScriptRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.uri = H._asStringS(json.$index(0, "uri")); + return t1; + }, + Script_parse: function(json) { + var t1 = Q.Script$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + return t1; + }, + Script$_fromJson: function(json) { + var t1 = type$.legacy_int; + t1 = new Q.Script(P.LinkedHashMap_LinkedHashMap$_empty(t1, t1), P.LinkedHashMap_LinkedHashMap$_empty(t1, t1), json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.Script$_fromJson$1(json); + return t1; + }, + ScriptList_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.ScriptList(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "scripts"), C.List_ScriptRef); + if (t2 == null) + t2 = []; + t1.set$scripts(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ScriptRef)); + return t1; + }, + SourceLocation_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.SourceLocation(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.script = type$.legacy_ScriptRef._as(Q.createServiceObject(json.$index(0, "script"), C.List_ScriptRef)); + t1.tokenPos = H._asIntS(json.$index(0, "tokenPos")); + t1.endTokenPos = H._asIntS(json.$index(0, "endTokenPos")); + return t1; + }, + SourceReport_parse: function(json) { + var t1, t2, t3; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.SourceReport(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = type$.Iterable_dynamic; + t1.set$ranges(P.List_List$from(t2._as(Q._createSpecificObject(json.$index(0, "ranges"), Q.vm_service_SourceReportRange_parse$closure())), true, type$.legacy_SourceReportRange)); + t3 = Q.createServiceObject(json.$index(0, "scripts"), C.List_ScriptRef); + t1.set$scripts(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_ScriptRef)); + return t1; + }, + SourceReportCoverage_parse: function(json) { + var t1, t2, t3; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + if (json == null) + t1 = null; + else { + t1 = new Q.SourceReportCoverage(); + t2 = type$.Iterable_dynamic; + t3 = type$.legacy_int; + t1.set$hits(P.List_List$from(t2._as(json.$index(0, "hits")), true, t3)); + t1.set$misses(P.List_List$from(t2._as(json.$index(0, "misses")), true, t3)); + } + return t1; + }, + SourceReportRange_parse: function(json) { + var t1, + _s19_ = "possibleBreakpoints"; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + if (json == null) + t1 = null; + else { + t1 = new Q.SourceReportRange(); + t1.scriptIndex = H._asIntS(json.$index(0, "scriptIndex")); + t1.startPos = H._asIntS(json.$index(0, "startPos")); + t1.endPos = H._asIntS(json.$index(0, "endPos")); + t1.compiled = H._asBoolS(json.$index(0, "compiled")); + t1.error = type$.legacy_ErrorRef._as(Q.createServiceObject(json.$index(0, "error"), C.List_ErrorRef)); + t1.coverage = type$.legacy_SourceReportCoverage._as(Q._createSpecificObject(json.$index(0, "coverage"), Q.vm_service_SourceReportCoverage_parse$closure())); + t1.set$possibleBreakpoints(json.$index(0, _s19_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(json.$index(0, _s19_)), true, type$.legacy_int)); + } + return t1; + }, + Stack_parse: function(json) { + var t1, t2, t3, t4, + _s17_ = "asyncCausalFrames", + _s13_ = "awaiterFrames"; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Stack(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "frames"), C.List_Frame); + if (t2 == null) + t2 = []; + t3 = type$.Iterable_dynamic; + t4 = type$.legacy_Frame; + t1.set$frames(P.List_List$from(t3._as(t2), true, t4)); + t1.set$asyncCausalFrames(json.$index(0, _s17_) == null ? null : P.List_List$from(t3._as(Q.createServiceObject(json.$index(0, _s17_), C.List_Frame)), true, t4)); + t1.set$awaiterFrames(json.$index(0, _s13_) == null ? null : P.List_List$from(t3._as(Q.createServiceObject(json.$index(0, _s13_), C.List_Frame)), true, t4)); + t2 = Q.createServiceObject(json.$index(0, "messages"), C.List_Message); + t1.set$messages(P.List_List$from(t3._as(t2 == null ? [] : t2), true, type$.legacy_Message)); + return t1; + }, + Success_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Success(json); + t1.type = H._asStringS(json.$index(0, "type")); + return t1; + }, + Timeline_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Timeline(json); + t1.type = H._asStringS(json.$index(0, "type")); + t2 = Q.createServiceObject(json.$index(0, "traceEvents"), C.List_TimelineEvent); + if (t2 == null) + t2 = []; + t1.set$traceEvents(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_TimelineEvent)); + t1.timeOriginMicros = H._asIntS(json.$index(0, "timeOriginMicros")); + t1.timeExtentMicros = H._asIntS(json.$index(0, "timeExtentMicros")); + return t1; + }, + TimelineEvent_parse: function(json) { + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + return new Q.TimelineEvent(json); + }, + TimelineFlags_parse: function(json) { + var t1, t2, t3; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.TimelineFlags(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.recorderName = H._asStringS(json.$index(0, "recorderName")); + t2 = type$.Iterable_dynamic; + t3 = type$.legacy_String; + t1.set$availableStreams(P.List_List$from(t2._as(json.$index(0, "availableStreams")), true, t3)); + t1.set$recordedStreams(P.List_List$from(t2._as(json.$index(0, "recordedStreams")), true, t3)); + return t1; + }, + Timestamp_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Timestamp(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.timestamp = H._asIntS(json.$index(0, "timestamp")); + return t1; + }, + TypeArgumentsRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.TypeArgumentsRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.ObjRef$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + return t1; + }, + TypeArguments_parse: function(json) { + var t1, t2; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.TypeArguments(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.Obj$_fromJson$1(json); + t1.name = H._asStringS(json.$index(0, "name")); + t2 = Q.createServiceObject(json.$index(0, "types"), C.List_InstanceRef); + if (t2 == null) + t2 = []; + t1.set$types(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_InstanceRef)); + return t1; + }, + UnresolvedSourceLocation_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.UnresolvedSourceLocation(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.script = type$.legacy_ScriptRef._as(Q.createServiceObject(json.$index(0, "script"), C.List_ScriptRef)); + t1.scriptUri = H._asStringS(json.$index(0, "scriptUri")); + t1.tokenPos = H._asIntS(json.$index(0, "tokenPos")); + t1.line = H._asIntS(json.$index(0, "line")); + t1.column = H._asIntS(json.$index(0, "column")); + return t1; + }, + Version_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.Version(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.major = H._asIntS(json.$index(0, "major")); + t1.minor = H._asIntS(json.$index(0, "minor")); + return t1; + }, + VMRef_parse: function(json) { + var t1; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.VMRef(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.name = H._asStringS(json.$index(0, "name")); + return t1; + }, + VM_parse: function(json) { + var t1, t2, t3; + type$.legacy_Map_of_legacy_String_and_dynamic._as(json); + t1 = new Q.VM(json); + t1.type = H._asStringS(json.$index(0, "type")); + t1.name = H._asStringS(json.$index(0, "name")); + t1.architectureBits = H._asIntS(json.$index(0, "architectureBits")); + t1.hostCPU = H._asStringS(json.$index(0, "hostCPU")); + t1.operatingSystem = H._asStringS(json.$index(0, "operatingSystem")); + t1.targetCPU = H._asStringS(json.$index(0, "targetCPU")); + t1.version = H._asStringS(json.$index(0, "version")); + t1.pid = H._asIntS(json.$index(0, "pid")); + t1.startTime = H._asIntS(json.$index(0, "startTime")); + t2 = Q.createServiceObject(json.$index(0, "isolates"), C.List_IsolateRef); + if (t2 == null) + t2 = []; + t3 = type$.Iterable_dynamic; + t1.set$isolates(P.List_List$from(t3._as(t2), true, type$.legacy_IsolateRef)); + t2 = Q.createServiceObject(json.$index(0, "isolateGroups"), C.List_IsolateGroupRef); + t1.set$isolateGroups(P.List_List$from(t3._as(t2 == null ? [] : t2), true, type$.legacy_IsolateGroupRef)); + return t1; + }, + createServiceObject_closure: function createServiceObject_closure(t0) { + this.expectedTypes = t0; + }, + _createSpecificObject_closure: function _createSpecificObject_closure(t0) { + this.creator = t0; + }, + VmService: function VmService(t0, t1, t2, t3, t4, t5, t6) { + var _ = this; + _._writeMessage = null; + _._id = 0; + _._completers = t0; + _._methodCalls = t1; + _._services = t2; + _._log = null; + _._onSend = t3; + _._onReceive = t4; + _._onDoneCompleter = t5; + _._eventControllers = t6; + }, + VmService_closure: function VmService_closure(t0) { + this.$this = t0; + }, + RPCError: function RPCError(t0, t1, t2, t3) { + var _ = this; + _.callingMethod = t0; + _.code = t1; + _.message = t2; + _.data = t3; + }, + SentinelException: function SentinelException(t0, t1) { + this.callingMethod = t0; + this.sentinel = t1; + }, + ExtensionData: function ExtensionData(t0) { + this.data = t0; + }, + _NullLog: function _NullLog() { + }, + AllocationProfile: function AllocationProfile(t0) { + var _ = this; + _.dateLastServiceGC = _.dateLastAccumulatorReset = _.memoryUsage = _.members = null; + _.json = t0; + _.type = null; + }, + AllocationProfile_toJson_closure: function AllocationProfile_toJson_closure() { + }, + BoundField: function BoundField() { + this.value = this.decl = null; + }, + BoundVariable: function BoundVariable(t0) { + var _ = this; + _.scopeEndTokenPos = _.scopeStartTokenPos = _.declarationTokenPos = _.value = _.name = null; + _.json = t0; + _.type = null; + }, + Breakpoint: function Breakpoint(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.location = _.isSyntheticAsyncContinuation = _.resolved = _.breakpointNumber = null; + _.json = t0; + _.type = null; + }, + ClassRef: function ClassRef(t0) { + var _ = this; + _.fixedId = _.id = _.name = null; + _.json = t0; + _.type = null; + }, + Class: function Class(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.subclasses = _.functions = _.fields = _.mixin = _.interfaces = _.superType = _.superClass = _.location = _.library = _.isConst = _.isAbstract = _.error = _.name = null; + _.json = t0; + _.type = null; + }, + Class_toJson_closure: function Class_toJson_closure() { + }, + Class_toJson_closure0: function Class_toJson_closure0() { + }, + Class_toJson_closure1: function Class_toJson_closure1() { + }, + Class_toJson_closure2: function Class_toJson_closure2() { + }, + ClassHeapStats: function ClassHeapStats(t0) { + var _ = this; + _.instancesCurrent = _.instancesAccumulated = _.bytesCurrent = _.accumulatedSize = _.classRef = null; + _.json = t0; + _.type = null; + }, + ClassList: function ClassList(t0) { + this.classes = null; + this.json = t0; + this.type = null; + }, + ClassList_toJson_closure: function ClassList_toJson_closure() { + }, + ClientName: function ClientName(t0) { + this.name = null; + this.json = t0; + this.type = null; + }, + CodeRef: function CodeRef(t0) { + var _ = this; + _.fixedId = _.id = _.kind = _.name = null; + _.json = t0; + _.type = null; + }, + Code: function Code(t0) { + var _ = this; + _.fixedId = _.id = _.kind = _.name = null; + _.json = t0; + _.type = null; + }, + ContextRef: function ContextRef(t0) { + var _ = this; + _.fixedId = _.id = _.length = null; + _.json = t0; + _.type = null; + }, + Context: function Context(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.variables = _.parent = _.length = null; + _.json = t0; + _.type = null; + }, + Context_toJson_closure: function Context_toJson_closure() { + }, + ContextElement: function ContextElement() { + this.value = null; + }, + CpuSamples: function CpuSamples(t0) { + var _ = this; + _.samples = _.functions = _.pid = _.timeExtentMicros = _.timeOriginMicros = _.timeSpan = _.sampleCount = _.maxStackDepth = _.samplePeriod = null; + _.json = t0; + _.type = null; + }, + CpuSamples_toJson_closure: function CpuSamples_toJson_closure() { + }, + CpuSamples_toJson_closure0: function CpuSamples_toJson_closure0() { + }, + CpuSample: function CpuSample() { + var _ = this; + _.stack = _.truncated = _.userTag = _.vmTag = _.timestamp = _.tid = null; + }, + CpuSample_toJson_closure: function CpuSample_toJson_closure() { + }, + ErrorRef: function ErrorRef(t0) { + var _ = this; + _.fixedId = _.id = _.message = _.kind = null; + _.json = t0; + _.type = null; + }, + Error: function Error(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.stacktrace = _.exception = _.message = _.kind = null; + _.json = t0; + _.type = null; + }, + Event: function Event(t0) { + var _ = this; + _.data = _.last = _.newValue = _.flag = _.alias = _.method = _.service = _.logRecord = _.status = _.atAsyncSuspension = _.updatedStreams = _.timelineEvents = _.extensionData = _.extensionKind = _.extensionRPC = _.inspectee = _.bytes = _.exception = _.topFrame = _.pauseBreakpoints = _.breakpoint = _.timestamp = _.vm = _.isolate = _.kind = null; + _.json = t0; + _.type = null; + }, + Event_toJson_closure: function Event_toJson_closure() { + }, + Event_toJson_closure0: function Event_toJson_closure0() { + }, + Event_toJson_closure1: function Event_toJson_closure1() { + }, + FieldRef: function FieldRef(t0) { + var _ = this; + _.fixedId = _.id = _.isStatic = _.isFinal = _.isConst = _.declaredType = _.owner = _.name = null; + _.json = t0; + _.type = null; + }, + Field: function Field(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.location = _.staticValue = _.isStatic = _.isFinal = _.isConst = _.declaredType = _.owner = _.name = null; + _.json = t0; + _.type = null; + }, + Flag: function Flag() { + var _ = this; + _.valueAsString = _.modified = _.comment = _.name = null; + }, + FlagList: function FlagList(t0) { + this.flags = null; + this.json = t0; + this.type = null; + }, + FlagList_toJson_closure: function FlagList_toJson_closure() { + }, + Frame: function Frame(t0) { + var _ = this; + _.kind = _.vars = _.location = _.code = _.$function = _.index = null; + _.json = t0; + _.type = null; + }, + Frame_toJson_closure: function Frame_toJson_closure() { + }, + FuncRef: function FuncRef(t0) { + var _ = this; + _.fixedId = _.id = _.isConst = _.isStatic = _.owner = _.name = null; + _.json = t0; + _.type = null; + }, + Func: function Func(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.code = _.location = _.isConst = _.isStatic = _.owner = _.name = null; + _.json = t0; + _.type = null; + }, + InstanceRef: function InstanceRef(t0) { + var _ = this; + _.fixedId = _.id = _.closureContext = _.closureFunction = _.pattern = _.parameterizedClass = _.typeClass = _.name = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.classRef = _.kind = null; + _.json = t0; + _.type = null; + }, + Instance: function Instance(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.bound = _.targetType = _.parameterIndex = _.typeArguments = _.propertyValue = _.propertyKey = _.isMultiLine = _.isCaseSensitive = _.closureContext = _.closureFunction = _.pattern = _.mirrorReferent = _.bytes = _.associations = _.elements = _.fields = _.parameterizedClass = _.typeClass = _.name = _.count = _.offset = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.Instance_classRef = _.kind = null; + _.json = t0; + _.type = null; + }, + Instance_toJson_closure: function Instance_toJson_closure() { + }, + Instance_toJson_closure0: function Instance_toJson_closure0() { + }, + Instance_toJson_closure1: function Instance_toJson_closure1() { + }, + IsolateRef: function IsolateRef(t0) { + var _ = this; + _.name = _.number = _.id = null; + _.json = t0; + _.type = null; + }, + Isolate: function Isolate(t0) { + var _ = this; + _.extensionRPCs = _.exceptionPauseMode = _.error = _.breakpoints = _.libraries = _.rootLib = _.pauseEvent = _.pauseOnExit = _.livePorts = _.runnable = _.startTime = _.name = _.number = _.id = null; + _.json = t0; + _.type = null; + }, + Isolate_toJson_closure: function Isolate_toJson_closure() { + }, + Isolate_toJson_closure0: function Isolate_toJson_closure0() { + }, + Isolate_toJson_closure1: function Isolate_toJson_closure1() { + }, + IsolateGroupRef: function IsolateGroupRef(t0) { + var _ = this; + _.name = _.number = _.id = null; + _.json = t0; + _.type = null; + }, + IsolateGroup: function IsolateGroup(t0) { + var _ = this; + _.isolates = _.name = _.number = _.id = null; + _.json = t0; + _.type = null; + }, + IsolateGroup_toJson_closure: function IsolateGroup_toJson_closure() { + }, + InboundReferences: function InboundReferences(t0) { + this.references = null; + this.json = t0; + this.type = null; + }, + InboundReferences_toJson_closure: function InboundReferences_toJson_closure() { + }, + InboundReference: function InboundReference() { + this.parentField = this.parentListIndex = this.source = null; + }, + InstanceSet: function InstanceSet(t0) { + var _ = this; + _.instances = _.totalCount = null; + _.json = t0; + _.type = null; + }, + InstanceSet_toJson_closure: function InstanceSet_toJson_closure() { + }, + LibraryRef: function LibraryRef(t0) { + var _ = this; + _.fixedId = _.id = _.uri = _.name = null; + _.json = t0; + _.type = null; + }, + Library: function Library(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.classes = _.functions = _.variables = _.scripts = _.dependencies = _.debuggable = _.uri = _.name = null; + _.json = t0; + _.type = null; + }, + Library_toJson_closure: function Library_toJson_closure() { + }, + Library_toJson_closure0: function Library_toJson_closure0() { + }, + Library_toJson_closure1: function Library_toJson_closure1() { + }, + Library_toJson_closure2: function Library_toJson_closure2() { + }, + Library_toJson_closure3: function Library_toJson_closure3() { + }, + LibraryDependency: function LibraryDependency() { + var _ = this; + _.target = _.prefix = _.isDeferred = _.isImport = null; + }, + LogRecord: function LogRecord(t0) { + var _ = this; + _.stackTrace = _.error = _.zone = _.loggerName = _.sequenceNumber = _.level = _.time = _.message = null; + _.json = t0; + _.type = null; + }, + MapAssociation: function MapAssociation() { + this.value = this.key = null; + }, + MemoryUsage: function MemoryUsage(t0) { + var _ = this; + _.heapUsage = _.heapCapacity = _.externalUsage = null; + _.json = t0; + _.type = null; + }, + Message: function Message(t0) { + var _ = this; + _.location = _.handler = _.size = _.messageObjectId = _.name = _.index = null; + _.json = t0; + _.type = null; + }, + NativeFunction: function NativeFunction() { + this.name = null; + }, + NullValRef: function NullValRef(t0) { + var _ = this; + _.fixedId = _.id = _.closureContext = _.closureFunction = _.pattern = _.parameterizedClass = _.typeClass = _.name = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.classRef = _.kind = _.NullValRef_valueAsString = null; + _.json = t0; + _.type = null; + }, + NullVal: function NullVal(t0) { + var _ = this; + _.classRef = _.fixedId = _.id = _.bound = _.targetType = _.parameterIndex = _.typeArguments = _.propertyValue = _.propertyKey = _.isMultiLine = _.isCaseSensitive = _.closureContext = _.closureFunction = _.pattern = _.mirrorReferent = _.bytes = _.associations = _.elements = _.fields = _.parameterizedClass = _.typeClass = _.name = _.count = _.offset = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.Instance_classRef = _.kind = _.NullVal_valueAsString = null; + _.size = null; + _.json = t0; + _.type = null; + }, + ObjRef: function ObjRef(t0) { + var _ = this; + _.fixedId = _.id = null; + _.json = t0; + _.type = null; + }, + Obj: function Obj(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = null; + _.json = t0; + _.type = null; + }, + ProfileFunction: function ProfileFunction() { + var _ = this; + _.$function = _.resolvedUrl = _.exclusiveTicks = _.inclusiveTicks = _.kind = null; + }, + ReloadReport: function ReloadReport(t0) { + this.success = null; + this.json = t0; + this.type = null; + }, + RetainingObject: function RetainingObject() { + var _ = this; + _.parentField = _.parentMapKey = _.parentListIndex = _.value = null; + }, + RetainingPath: function RetainingPath(t0) { + var _ = this; + _.elements = _.gcRootType = _.length = null; + _.json = t0; + _.type = null; + }, + RetainingPath_toJson_closure: function RetainingPath_toJson_closure() { + }, + Response: function Response(t0) { + this.json = t0; + this.type = null; + }, + Sentinel: function Sentinel(t0) { + var _ = this; + _.valueAsString = _.kind = null; + _.json = t0; + _.type = null; + }, + ScriptRef: function ScriptRef(t0) { + var _ = this; + _.fixedId = _.id = _.uri = null; + _.json = t0; + _.type = null; + }, + Script: function Script(t0, t1, t2) { + var _ = this; + _._tokenToLine = t0; + _._tokenToColumn = t1; + _.size = _.classRef = _.fixedId = _.id = _.tokenPosTable = _.source = _.columnOffset = _.lineOffset = _.library = _.uri = null; + _.json = t2; + _.type = null; + }, + Script$_fromJson_closure: function Script$_fromJson_closure() { + }, + Script_toJson_closure: function Script_toJson_closure() { + }, + ScriptList: function ScriptList(t0) { + this.scripts = null; + this.json = t0; + this.type = null; + }, + ScriptList_toJson_closure: function ScriptList_toJson_closure() { + }, + SourceLocation: function SourceLocation(t0) { + var _ = this; + _.endTokenPos = _.tokenPos = _.script = null; + _.json = t0; + _.type = null; + }, + SourceReport: function SourceReport(t0) { + var _ = this; + _.scripts = _.ranges = null; + _.json = t0; + _.type = null; + }, + SourceReport_toJson_closure: function SourceReport_toJson_closure() { + }, + SourceReport_toJson_closure0: function SourceReport_toJson_closure0() { + }, + SourceReportCoverage: function SourceReportCoverage() { + this.misses = this.hits = null; + }, + SourceReportCoverage_toJson_closure: function SourceReportCoverage_toJson_closure() { + }, + SourceReportCoverage_toJson_closure0: function SourceReportCoverage_toJson_closure0() { + }, + SourceReportRange: function SourceReportRange() { + var _ = this; + _.possibleBreakpoints = _.coverage = _.error = _.compiled = _.endPos = _.startPos = _.scriptIndex = null; + }, + SourceReportRange_toJson_closure: function SourceReportRange_toJson_closure() { + }, + Stack: function Stack(t0) { + var _ = this; + _.messages = _.awaiterFrames = _.asyncCausalFrames = _.frames = null; + _.json = t0; + _.type = null; + }, + Stack_toJson_closure: function Stack_toJson_closure() { + }, + Stack_toJson_closure0: function Stack_toJson_closure0() { + }, + Stack_toJson_closure1: function Stack_toJson_closure1() { + }, + Stack_toJson_closure2: function Stack_toJson_closure2() { + }, + Success: function Success(t0) { + this.json = t0; + this.type = null; + }, + Timeline: function Timeline(t0) { + var _ = this; + _.timeExtentMicros = _.timeOriginMicros = _.traceEvents = null; + _.json = t0; + _.type = null; + }, + Timeline_toJson_closure: function Timeline_toJson_closure() { + }, + TimelineEvent: function TimelineEvent(t0) { + this.json = t0; + }, + TimelineFlags: function TimelineFlags(t0) { + var _ = this; + _.recordedStreams = _.availableStreams = _.recorderName = null; + _.json = t0; + _.type = null; + }, + TimelineFlags_toJson_closure: function TimelineFlags_toJson_closure() { + }, + TimelineFlags_toJson_closure0: function TimelineFlags_toJson_closure0() { + }, + Timestamp: function Timestamp(t0) { + this.timestamp = null; + this.json = t0; + this.type = null; + }, + TypeArgumentsRef: function TypeArgumentsRef(t0) { + var _ = this; + _.fixedId = _.id = _.name = null; + _.json = t0; + _.type = null; + }, + TypeArguments: function TypeArguments(t0) { + var _ = this; + _.size = _.classRef = _.fixedId = _.id = _.types = _.name = null; + _.json = t0; + _.type = null; + }, + TypeArguments_toJson_closure: function TypeArguments_toJson_closure() { + }, + UnresolvedSourceLocation: function UnresolvedSourceLocation(t0) { + var _ = this; + _.column = _.line = _.tokenPos = _.scriptUri = _.script = null; + _.json = t0; + _.type = null; + }, + Version: function Version(t0) { + var _ = this; + _.minor = _.major = null; + _.json = t0; + _.type = null; + }, + VMRef: function VMRef(t0) { + this.name = null; + this.json = t0; + this.type = null; + }, + VM: function VM(t0) { + var _ = this; + _.isolateGroups = _.isolates = _.startTime = _.pid = _.version = _.targetCPU = _.operatingSystem = _.hostCPU = _.architectureBits = _.name = null; + _.json = t0; + _.type = null; + }, + VM_toJson_closure: function VM_toJson_closure() { + }, + VM_toJson_closure0: function VM_toJson_closure0() { + } + }, + N = {HexCodec: function HexCodec() { + }}, + R = { + _convert: function(bytes, start, end) { + var t1, t2, i, bufferIndex, byteOr, byte, bufferIndex0, t3, + buffer = new Uint8Array((end - start) * 2); + for (t1 = buffer.length, t2 = bytes.length, i = start, bufferIndex = 0, byteOr = 0; i < end; ++i) { + if (i >= t2) + return H.ioore(bytes, i); + byte = bytes[i]; + if (typeof byte !== "number") + return H.iae(byte); + byteOr = (byteOr | byte) >>> 0; + bufferIndex0 = bufferIndex + 1; + t3 = (byte & 240) >>> 4; + t3 = t3 < 10 ? t3 + 48 : t3 + 97 - 10; + if (bufferIndex >= t1) + return H.ioore(buffer, bufferIndex); + buffer[bufferIndex] = t3; + bufferIndex = bufferIndex0 + 1; + t3 = byte & 15; + t3 = t3 < 10 ? t3 + 48 : t3 + 97 - 10; + if (bufferIndex0 >= t1) + return H.ioore(buffer, bufferIndex0); + buffer[bufferIndex0] = t3; + } + if (byteOr >= 0 && byteOr <= 255) + return P.String_String$fromCharCodes(buffer, 0, null); + for (i = start; i < end; ++i) { + if (i >= t2) + return H.ioore(bytes, i); + byte = bytes[i]; + if (typeof byte !== "number") + return byte.$ge(); + if (byte >= 0 && byte <= 255) + continue; + throw H.wrapException(P.FormatException$("Invalid byte " + (byte < 0 ? "-" : "") + "0x" + C.JSInt_methods.toRadixString$1(Math.abs(byte), 16) + ".", bytes, i)); + } + throw H.wrapException("unreachable"); + }, + HexEncoder: function HexEncoder() { + }, + StreamChannelMixin: function StreamChannelMixin() { + } + }, + Y = {Level: function Level(t0, t1) { + this.name = t0; + this.value = t1; + }}, + L = {LogRecord0: function LogRecord0(t0, t1, t2) { + this.level = t0; + this.message = t1; + this.loggerName = t2; + }}, + M = { + SseClient$: function(serverUrl) { + var t1 = type$.legacy_String; + t1 = new M.SseClient(P.StreamController_StreamController(t1), P.StreamController_StreamController(t1), F.Logger_Logger("SseClient"), P.StreamController_StreamController(type$.dynamic)); + t1.SseClient$1(serverUrl); + return t1; + }, + SseClient: function SseClient(t0, t1, t2, t3) { + var _ = this; + _._incomingController = t0; + _._outgoingController = t1; + _._logger = t2; + _._errorTimer = _._serverUrl = _._eventSource = null; + _._messages = t3; + }, + SseClient_closure: function SseClient_closure(t0) { + this.$this = t0; + }, + SseClient_closure0: function SseClient_closure0(t0) { + this.$this = t0; + }, + SseClient__closure: function SseClient__closure(t0, t1) { + this.$this = t0; + this.error = t1; + } + }, + K = { + Uuid$: function() { + var options, t2, t1 = {}; + t1.options = options; + t1.options = null; + t2 = new K.Uuid(); + t2.Uuid$1$options(t1); + return t2; + }, + Uuid: function Uuid() { + var _ = this; + _._clockSeq = _._nodeId = _._seedBytes = null; + _._lastNSecs = _._lastMSecs = 0; + _._hexToByte = _._byteToHex = null; + } + }, + T = { + UuidUtil_mathRNG: function() { + var b, rand, i, + t1 = new Array(16); + t1.fixed$length = Array; + b = H.setRuntimeTypeInfo(t1, type$.JSArray_legacy_int); + for (rand = null, i = 0; i < 16; ++i) { + t1 = i & 3; + if (t1 === 0) + rand = C.JSInt_methods.toInt$0(C.JSNumber_methods.floor$0(C.C__JSRandom.nextDouble$0() * 4294967296)); + if (typeof rand !== "number") + return rand.$shr(); + C.JSArray_methods.$indexSet(b, i, C.JSInt_methods._shrOtherPositive$1(rand, t1 << 3) & 255); + } + return b; + } + }; + var holders = [C, H, J, P, W, V, E, F, G, Q, N, R, Y, L, M, K, T]; + hunkHelpers.setFunctionNamesIfNecessary(holders); + var $ = {}; + H.JS_CONST.prototype = {}; + J.Interceptor.prototype = { + $eq: function(receiver, other) { + return receiver === other; + }, + get$hashCode: function(receiver) { + return H.Primitives_objectHashCode(receiver); + }, + toString$0: function(receiver) { + return "Instance of '" + H.S(H.Primitives_objectTypeName(receiver)) + "'"; + }, + noSuchMethod$1: function(receiver, invocation) { + type$.Invocation._as(invocation); + throw H.wrapException(P.NoSuchMethodError$(receiver, invocation.get$memberName(), invocation.get$positionalArguments(), invocation.get$namedArguments())); + }, + get$runtimeType: function(receiver) { + return H.getRuntimeType(receiver); + } + }; + J.JSBool.prototype = { + toString$0: function(receiver) { + return String(receiver); + }, + $and: function(receiver, other) { + return H.checkBool(H._asBoolS(other)) && receiver; + }, + $or: function(receiver, other) { + return H.checkBool(H._asBoolS(other)) || receiver; + }, + get$hashCode: function(receiver) { + return receiver ? 519018 : 218159; + }, + get$runtimeType: function(receiver) { + return C.Type_bool_lhE; + }, + $isbool: 1 + }; + J.JSNull.prototype = { + $eq: function(receiver, other) { + return null == other; + }, + toString$0: function(receiver) { + return "null"; + }, + get$hashCode: function(receiver) { + return 0; + }, + get$runtimeType: function(receiver) { + return C.Type_Null_Yyn; + }, + noSuchMethod$1: function(receiver, invocation) { + return this.super$Interceptor$noSuchMethod(receiver, type$.Invocation._as(invocation)); + }, + $isNull: 1 + }; + J.JSObject.prototype = {}; + J.JavaScriptObject.prototype = { + get$hashCode: function(receiver) { + return 0; + }, + get$runtimeType: function(receiver) { + return C.Type_JSObject_8k0; + }, + toString$0: function(receiver) { + return String(receiver); + } + }; + J.PlainJavaScriptObject.prototype = {}; + J.UnknownJavaScriptObject.prototype = {}; + J.JavaScriptFunction.prototype = { + toString$0: function(receiver) { + var dartClosure = receiver[$.$get$DART_CLOSURE_PROPERTY_NAME()]; + if (dartClosure == null) + return this.super$JavaScriptObject$toString(receiver); + return "JavaScript function for " + H.S(J.toString$0$(dartClosure)); + }, + $signature: function() { + return {func: 1, opt: [,,,,,,,,,,,,,,,,]}; + }, + $isFunction: 1 + }; + J.JSArray.prototype = { + add$1: function(receiver, value) { + H._arrayInstanceType(receiver)._precomputed1._as(value); + if (!!receiver.fixed$length) + H.throwExpression(P.UnsupportedError$("add")); + receiver.push(value); + }, + addAll$1: function(receiver, collection) { + var t1, _i; + H._arrayInstanceType(receiver)._eval$1("Iterable<1>")._as(collection); + if (!!receiver.fixed$length) + H.throwExpression(P.UnsupportedError$("addAll")); + for (t1 = collection.length, _i = 0; _i < collection.length; collection.length === t1 || (0, H.throwConcurrentModificationError)(collection), ++_i) + receiver.push(collection[_i]); + }, + map$1$1: function(receiver, f, $T) { + var t1 = H._arrayInstanceType(receiver); + return new H.MappedListIterable(receiver, t1._bind$1($T)._eval$1("1(2)")._as(f), t1._eval$1("@<1>")._bind$1($T)._eval$1("MappedListIterable<1,2>")); + }, + map$1: function($receiver, f) { + return this.map$1$1($receiver, f, type$.dynamic); + }, + elementAt$1: function(receiver, index) { + if (index < 0 || index >= receiver.length) + return H.ioore(receiver, index); + return receiver[index]; + }, + get$first: function(receiver) { + if (receiver.length > 0) + return receiver[0]; + throw H.wrapException(H.IterableElementError_noElement()); + }, + setRange$4: function(receiver, start, end, iterable, skipCount) { + var $length, otherList, t1, i; + H._arrayInstanceType(receiver)._eval$1("Iterable<1>")._as(iterable); + if (!!receiver.immutable$list) + H.throwExpression(P.UnsupportedError$("setRange")); + P.RangeError_checkValidRange(start, end, receiver.length); + $length = end - start; + if ($length === 0) + return; + P.RangeError_checkNotNegative(skipCount, "skipCount"); + otherList = iterable; + t1 = J.getInterceptor$asx(otherList); + if (skipCount + $length > t1.get$length(otherList)) + throw H.wrapException(H.IterableElementError_tooFew()); + if (skipCount < start) + for (i = $length - 1; i >= 0; --i) + receiver[start + i] = t1.$index(otherList, skipCount + i); + else + for (i = 0; i < $length; ++i) + receiver[start + i] = t1.$index(otherList, skipCount + i); + }, + contains$1: function(receiver, other) { + var i; + for (i = 0; i < receiver.length; ++i) + if (J.$eq$(receiver[i], other)) + return true; + return false; + }, + get$isNotEmpty: function(receiver) { + return receiver.length !== 0; + }, + toString$0: function(receiver) { + return P.IterableBase_iterableToFullString(receiver, "[", "]"); + }, + toList$1$growable: function(receiver, growable) { + var t1 = H.setRuntimeTypeInfo(receiver.slice(0), H._arrayInstanceType(receiver)); + return t1; + }, + toList$0: function($receiver) { + return this.toList$1$growable($receiver, true); + }, + get$iterator: function(receiver) { + return new J.ArrayIterator(receiver, receiver.length, H._arrayInstanceType(receiver)._eval$1("ArrayIterator<1>")); + }, + get$hashCode: function(receiver) { + return H.Primitives_objectHashCode(receiver); + }, + get$length: function(receiver) { + return receiver.length; + }, + set$length: function(receiver, newLength) { + if (!!receiver.fixed$length) + H.throwExpression(P.UnsupportedError$("set length")); + receiver.length = newLength; + }, + $index: function(receiver, index) { + H._asIntS(index); + if (!H._isInt(index)) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + if (index >= receiver.length || index < 0) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + return receiver[index]; + }, + $indexSet: function(receiver, index, value) { + H._asIntS(index); + H._arrayInstanceType(receiver)._precomputed1._as(value); + if (!!receiver.immutable$list) + H.throwExpression(P.UnsupportedError$("indexed set")); + if (!H._isInt(index)) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + if (index >= receiver.length || index < 0) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + receiver[index] = value; + }, + $add: function(receiver, other) { + var t2, _i, + t1 = H._arrayInstanceType(receiver); + t1._eval$1("List<1>")._as(other); + t1 = H.setRuntimeTypeInfo([], t1); + for (t2 = receiver.length, _i = 0; _i < receiver.length; receiver.length === t2 || (0, H.throwConcurrentModificationError)(receiver), ++_i) + this.add$1(t1, receiver[_i]); + for (t2 = other.get$iterator(other); t2.moveNext$0();) + this.add$1(t1, t2.get$current()); + return t1; + }, + $isJSIndexable: 1, + $isEfficientLengthIterable: 1, + $isIterable: 1, + $isList: 1 + }; + J.JSUnmodifiableArray.prototype = {}; + J.ArrayIterator.prototype = { + get$current: function() { + return this.__interceptors$_current; + }, + moveNext$0: function() { + var t2, _this = this, + t1 = _this.__interceptors$_iterable, + $length = t1.length; + if (_this.__interceptors$_length !== $length) + throw H.wrapException(H.throwConcurrentModificationError(t1)); + t2 = _this.__interceptors$_index; + if (t2 >= $length) { + _this.set$__interceptors$_current(null); + return false; + } + _this.set$__interceptors$_current(t1[t2]); + ++_this.__interceptors$_index; + return true; + }, + set$__interceptors$_current: function(_current) { + this.__interceptors$_current = this.$ti._eval$1("1?")._as(_current); + }, + $isIterator: 1 + }; + J.JSNumber.prototype = { + toInt$0: function(receiver) { + var t1; + if (receiver >= -2147483648 && receiver <= 2147483647) + return receiver | 0; + if (isFinite(receiver)) { + t1 = receiver < 0 ? Math.ceil(receiver) : Math.floor(receiver); + return t1 + 0; + } + throw H.wrapException(P.UnsupportedError$("" + receiver + ".toInt()")); + }, + floor$0: function(receiver) { + var truncated, d; + if (receiver >= 0) { + if (receiver <= 2147483647) + return receiver | 0; + } else if (receiver >= -2147483648) { + truncated = receiver | 0; + return receiver === truncated ? truncated : truncated - 1; + } + d = Math.floor(receiver); + if (isFinite(d)) + return d; + throw H.wrapException(P.UnsupportedError$("" + receiver + ".floor()")); + }, + toRadixString$1: function(receiver, radix) { + var result, match, t1, exponent; + if (radix < 2 || radix > 36) + throw H.wrapException(P.RangeError$range(radix, 2, 36, "radix", null)); + result = receiver.toString(radix); + if (C.JSString_methods.codeUnitAt$1(result, result.length - 1) !== 41) + return result; + match = /^([\da-z]+)(?:\.([\da-z]+))?\(e\+(\d+)\)$/.exec(result); + if (match == null) + H.throwExpression(P.UnsupportedError$("Unexpected toString result: " + result)); + t1 = match.length; + if (1 >= t1) + return H.ioore(match, 1); + result = match[1]; + if (3 >= t1) + return H.ioore(match, 3); + exponent = +match[3]; + t1 = match[2]; + if (t1 != null) { + result += t1; + exponent -= t1.length; + } + return result + C.JSString_methods.$mul("0", exponent); + }, + toString$0: function(receiver) { + if (receiver === 0 && 1 / receiver < 0) + return "-0.0"; + else + return "" + receiver; + }, + get$hashCode: function(receiver) { + var absolute, floorLog2, factor, scaled, + intValue = receiver | 0; + if (receiver === intValue) + return 536870911 & intValue; + absolute = Math.abs(receiver); + floorLog2 = Math.log(absolute) / 0.6931471805599453 | 0; + factor = Math.pow(2, floorLog2); + scaled = absolute < 1 ? absolute / factor : factor / absolute; + return 536870911 & ((scaled * 9007199254740992 | 0) + (scaled * 3542243181176521 | 0)) * 599197 + floorLog2 * 1259; + }, + $add: function(receiver, other) { + H._asNumS(other); + return receiver + other; + }, + $sub: function(receiver, other) { + return receiver - other; + }, + $div: function(receiver, other) { + return receiver / other; + }, + $mod: function(receiver, other) { + var result = receiver % other; + if (result === 0) + return 0; + if (result > 0) + return result; + if (other < 0) + return result - other; + else + return result + other; + }, + _tdivFast$1: function(receiver, other) { + return (receiver | 0) === receiver ? receiver / other | 0 : this._tdivSlow$1(receiver, other); + }, + _tdivSlow$1: function(receiver, other) { + var quotient = receiver / other; + if (quotient >= -2147483648 && quotient <= 2147483647) + return quotient | 0; + if (quotient > 0) { + if (quotient !== 1 / 0) + return Math.floor(quotient); + } else if (quotient > -1 / 0) + return Math.ceil(quotient); + throw H.wrapException(P.UnsupportedError$("Result of truncating division is " + H.S(quotient) + ": " + H.S(receiver) + " ~/ " + other)); + }, + $shl: function(receiver, other) { + if (other < 0) + throw H.wrapException(H.argumentErrorValue(other)); + return other > 31 ? 0 : receiver << other >>> 0; + }, + $shr: function(receiver, other) { + var t1; + if (other < 0) + throw H.wrapException(H.argumentErrorValue(other)); + if (receiver > 0) + t1 = this._shrBothPositive$1(receiver, other); + else { + t1 = other > 31 ? 31 : other; + t1 = receiver >> t1 >>> 0; + } + return t1; + }, + _shrOtherPositive$1: function(receiver, other) { + var t1; + if (receiver > 0) + t1 = this._shrBothPositive$1(receiver, other); + else { + t1 = other > 31 ? 31 : other; + t1 = receiver >> t1 >>> 0; + } + return t1; + }, + _shrBothPositive$1: function(receiver, other) { + return other > 31 ? 0 : receiver >>> other; + }, + $and: function(receiver, other) { + return (receiver & other) >>> 0; + }, + $or: function(receiver, other) { + H._asNumS(other); + if (typeof other != "number") + throw H.wrapException(H.argumentErrorValue(other)); + return (receiver | other) >>> 0; + }, + $lt: function(receiver, other) { + return receiver < other; + }, + $gt: function(receiver, other) { + return receiver > other; + }, + $ge: function(receiver, other) { + if (typeof other != "number") + throw H.wrapException(H.argumentErrorValue(other)); + return receiver >= other; + }, + get$runtimeType: function(receiver) { + return C.Type_num_cv7; + }, + $isdouble: 1, + $isnum: 1 + }; + J.JSInt.prototype = { + get$runtimeType: function(receiver) { + return C.Type_int_tHn; + }, + $isint: 1 + }; + J.JSDouble.prototype = { + get$runtimeType: function(receiver) { + return C.Type_double_K1J; + } + }; + J.JSString.prototype = { + codeUnitAt$1: function(receiver, index) { + if (index < 0) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + if (index >= receiver.length) + H.throwExpression(H.diagnoseIndexError(receiver, index)); + return receiver.charCodeAt(index); + }, + _codeUnitAt$1: function(receiver, index) { + if (index >= receiver.length) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + return receiver.charCodeAt(index); + }, + $add: function(receiver, other) { + H._asStringS(other); + if (typeof other != "string") + throw H.wrapException(P.ArgumentError$value(other, null, null)); + return receiver + other; + }, + startsWith$1: function(receiver, pattern) { + var otherLength = pattern.length; + if (otherLength > receiver.length) + return false; + return pattern === receiver.substring(0, otherLength); + }, + substring$2: function(receiver, startIndex, endIndex) { + if (endIndex == null) + endIndex = receiver.length; + if (startIndex < 0) + throw H.wrapException(P.RangeError$value(startIndex, null)); + if (startIndex > endIndex) + throw H.wrapException(P.RangeError$value(startIndex, null)); + if (endIndex > receiver.length) + throw H.wrapException(P.RangeError$value(endIndex, null)); + return receiver.substring(startIndex, endIndex); + }, + substring$1: function($receiver, startIndex) { + return this.substring$2($receiver, startIndex, null); + }, + $mul: function(receiver, times) { + var s, result; + if (0 >= times) + return ""; + if (times === 1 || receiver.length === 0) + return receiver; + if (times !== times >>> 0) + throw H.wrapException(C.C_OutOfMemoryError); + for (s = receiver, result = ""; true;) { + if ((times & 1) === 1) + result = s + result; + times = times >>> 1; + if (times === 0) + break; + s += s; + } + return result; + }, + lastIndexOf$1: function(receiver, pattern) { + var start = receiver.length, + t1 = pattern.length; + if (start + t1 > start) + start -= t1; + return receiver.lastIndexOf(pattern, start); + }, + toString$0: function(receiver) { + return receiver; + }, + get$hashCode: function(receiver) { + var t1, hash, i; + for (t1 = receiver.length, hash = 0, i = 0; i < t1; ++i) { + hash = 536870911 & hash + receiver.charCodeAt(i); + hash = 536870911 & hash + ((524287 & hash) << 10); + hash ^= hash >> 6; + } + hash = 536870911 & hash + ((67108863 & hash) << 3); + hash ^= hash >> 11; + return 536870911 & hash + ((16383 & hash) << 15); + }, + get$runtimeType: function(receiver) { + return C.Type_String_k8F; + }, + get$length: function(receiver) { + return receiver.length; + }, + $index: function(receiver, index) { + H._asIntS(index); + if (index >= receiver.length || false) + throw H.wrapException(H.diagnoseIndexError(receiver, index)); + return receiver[index]; + }, + $isJSIndexable: 1, + $isPattern: 1, + $isString: 1 + }; + H.EfficientLengthIterable.prototype = {}; + H.ListIterable.prototype = { + get$iterator: function(_) { + var _this = this; + return new H.ListIterator(_this, _this.get$length(_this), H._instanceType(_this)._eval$1("ListIterator")); + }, + get$isEmpty: function(_) { + return this.get$length(this) === 0; + }, + map$1: function(_, f) { + var t1 = H._instanceType(this); + return new H.MappedListIterable(this, t1._eval$1("@(ListIterable.E)")._as(f), t1._eval$1("MappedListIterable")); + } + }; + H.ListIterator.prototype = { + get$current: function() { + var cur = this._current; + return cur; + }, + moveNext$0: function() { + var t3, _this = this, + t1 = _this._iterable, + t2 = J.getInterceptor$asx(t1), + $length = t2.get$length(t1); + if (_this.__internal$_length !== $length) + throw H.wrapException(P.ConcurrentModificationError$(t1)); + t3 = _this._index; + if (t3 >= $length) { + _this.set$_current(null); + return false; + } + _this.set$_current(t2.elementAt$1(t1, t3)); + ++_this._index; + return true; + }, + set$_current: function(_current) { + this._current = this.$ti._eval$1("1?")._as(_current); + }, + $isIterator: 1 + }; + H.MappedIterable.prototype = { + get$iterator: function(_) { + var t1 = H._instanceType(this); + return new H.MappedIterator(J.get$iterator$ax(this._iterable), this._f, t1._eval$1("@<1>")._bind$1(t1._rest[1])._eval$1("MappedIterator<1,2>")); + }, + get$length: function(_) { + return J.get$length$asx(this._iterable); + } + }; + H.EfficientLengthMappedIterable.prototype = {$isEfficientLengthIterable: 1}; + H.MappedIterator.prototype = { + moveNext$0: function() { + var _this = this, + t1 = _this._iterator; + if (t1.moveNext$0()) { + _this.set$_current(_this._f.call$1(t1.get$current())); + return true; + } + _this.set$_current(null); + return false; + }, + get$current: function() { + var cur = this._current; + return cur; + }, + set$_current: function(_current) { + this._current = this.$ti._eval$1("2?")._as(_current); + } + }; + H.MappedListIterable.prototype = { + get$length: function(_) { + return J.get$length$asx(this.__internal$_source); + }, + elementAt$1: function(_, index) { + return this._f.call$1(J.elementAt$1$ax(this.__internal$_source, index)); + } + }; + H.FixedLengthListMixin.prototype = {}; + H.Symbol.prototype = { + get$hashCode: function(_) { + var hash = this._hashCode; + if (hash != null) + return hash; + hash = 536870911 & 664597 * J.get$hashCode$(this.__internal$_name); + this._hashCode = hash; + return hash; + }, + toString$0: function(_) { + return 'Symbol("' + H.S(this.__internal$_name) + '")'; + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof H.Symbol && this.__internal$_name == other.__internal$_name; + }, + $isSymbol0: 1 + }; + H.ConstantMapView.prototype = {}; + H.ConstantMap.prototype = { + get$isEmpty: function(_) { + return this.get$length(this) === 0; + }, + toString$0: function(_) { + return P.MapBase_mapToString(this); + }, + $indexSet: function(_, key, val) { + var t1 = H._instanceType(this); + t1._precomputed1._as(key); + t1._rest[1]._as(val); + H.ConstantMap__throwUnmodifiable(); + }, + map$2$1: function(_, transform, K2, V2) { + var result = P.LinkedHashMap_LinkedHashMap$_empty(K2, V2); + this.forEach$1(0, new H.ConstantMap_map_closure(this, H._instanceType(this)._bind$1(K2)._bind$1(V2)._eval$1("MapEntry<1,2>(3,4)")._as(transform), result)); + return result; + }, + map$1: function($receiver, transform) { + return this.map$2$1($receiver, transform, type$.dynamic, type$.dynamic); + }, + $isMap: 1 + }; + H.ConstantMap_map_closure.prototype = { + call$2: function(key, value) { + var t1 = H._instanceType(this.$this), + entry = this.transform.call$2(t1._precomputed1._as(key), t1._rest[1]._as(value)); + this.result.$indexSet(0, C.JSNull_methods.get$key(entry), entry.get$value()); + }, + $signature: function() { + return H._instanceType(this.$this)._eval$1("Null(1,2)"); + } + }; + H.ConstantStringMap.prototype = { + get$length: function(_) { + return this._length; + }, + containsKey$1: function(key) { + if (typeof key != "string") + return false; + if ("__proto__" === key) + return false; + return this._jsObject.hasOwnProperty(key); + }, + $index: function(_, key) { + if (!this.containsKey$1(key)) + return null; + return this._fetch$1(key); + }, + _fetch$1: function(key) { + return this._jsObject[H._asStringS(key)]; + }, + forEach$1: function(_, f) { + var keys, t2, i, key, + t1 = H._instanceType(this); + t1._eval$1("~(1,2)")._as(f); + keys = this._keys; + for (t2 = keys.length, t1 = t1._rest[1], i = 0; i < t2; ++i) { + key = keys[i]; + f.call$2(key, t1._as(this._fetch$1(key))); + } + }, + get$keys: function() { + return new H._ConstantMapKeyIterable(this, H._instanceType(this)._eval$1("_ConstantMapKeyIterable<1>")); + } + }; + H._ConstantMapKeyIterable.prototype = { + get$iterator: function(_) { + var t1 = this._map._keys; + return new J.ArrayIterator(t1, t1.length, H._arrayInstanceType(t1)._eval$1("ArrayIterator<1>")); + }, + get$length: function(_) { + return this._map._keys.length; + } + }; + H.JSInvocationMirror.prototype = { + get$memberName: function() { + var t1 = this._memberName; + return t1; + }, + get$positionalArguments: function() { + var t1, argumentCount, list, index, _this = this; + if (_this.__js_helper$_kind === 1) + return C.List_empty; + t1 = _this._arguments; + argumentCount = t1.length - _this._namedArgumentNames.length - _this._typeArgumentCount; + if (argumentCount === 0) + return C.List_empty; + list = []; + for (index = 0; index < argumentCount; ++index) { + if (index >= t1.length) + return H.ioore(t1, index); + list.push(t1[index]); + } + list.fixed$length = Array; + list.immutable$list = Array; + return list; + }, + get$namedArguments: function() { + var t1, namedArgumentCount, t2, namedArgumentsStartIndex, map, i, t3, t4, _this = this; + if (_this.__js_helper$_kind !== 0) + return C.Map_empty0; + t1 = _this._namedArgumentNames; + namedArgumentCount = t1.length; + t2 = _this._arguments; + namedArgumentsStartIndex = t2.length - namedArgumentCount - _this._typeArgumentCount; + if (namedArgumentCount === 0) + return C.Map_empty0; + map = new H.JsLinkedHashMap(type$.JsLinkedHashMap_Symbol_dynamic); + for (i = 0; i < namedArgumentCount; ++i) { + if (i >= t1.length) + return H.ioore(t1, i); + t3 = t1[i]; + t4 = namedArgumentsStartIndex + i; + if (t4 < 0 || t4 >= t2.length) + return H.ioore(t2, t4); + map.$indexSet(0, new H.Symbol(t3), t2[t4]); + } + return new H.ConstantMapView(map, type$.ConstantMapView_Symbol_dynamic); + }, + $isInvocation: 1 + }; + H.Primitives_functionNoSuchMethod_closure.prototype = { + call$2: function($name, argument) { + var t1; + H._asStringS($name); + t1 = this._box_0; + t1.names = t1.names + "$" + H.S($name); + C.JSArray_methods.add$1(this.namedArgumentList, $name); + C.JSArray_methods.add$1(this.$arguments, argument); + ++t1.argumentCount; + }, + $signature: 44 + }; + H.TypeErrorDecoder.prototype = { + matchTypeError$1: function(message) { + var result, t1, _this = this, + match = new RegExp(_this._pattern).exec(message); + if (match == null) + return null; + result = Object.create(null); + t1 = _this._arguments; + if (t1 !== -1) + result.arguments = match[t1 + 1]; + t1 = _this._argumentsExpr; + if (t1 !== -1) + result.argumentsExpr = match[t1 + 1]; + t1 = _this._expr; + if (t1 !== -1) + result.expr = match[t1 + 1]; + t1 = _this._method; + if (t1 !== -1) + result.method = match[t1 + 1]; + t1 = _this._receiver; + if (t1 !== -1) + result.receiver = match[t1 + 1]; + return result; + } + }; + H.NullError.prototype = { + toString$0: function(_) { + var t1 = this._method; + if (t1 == null) + return "NoSuchMethodError: " + H.S(this._message); + return "NoSuchMethodError: method not found: '" + t1 + "' on null"; + } + }; + H.JsNoSuchMethodError.prototype = { + toString$0: function(_) { + var t2, _this = this, + _s38_ = "NoSuchMethodError: method not found: '", + t1 = _this._method; + if (t1 == null) + return "NoSuchMethodError: " + H.S(_this._message); + t2 = _this._receiver; + if (t2 == null) + return _s38_ + t1 + "' (" + H.S(_this._message) + ")"; + return _s38_ + t1 + "' on '" + t2 + "' (" + H.S(_this._message) + ")"; + } + }; + H.UnknownJsTypeError.prototype = { + toString$0: function(_) { + var t1 = this._message; + return t1.length === 0 ? "Error" : "Error: " + t1; + } + }; + H.NullThrownFromJavaScriptException.prototype = { + toString$0: function(_) { + return "Throw of null ('" + (this._irritant === null ? "null" : "undefined") + "' from JavaScript)"; + } + }; + H.ExceptionAndStackTrace.prototype = {}; + H._StackTrace.prototype = { + toString$0: function(_) { + var trace, + t1 = this._trace; + if (t1 != null) + return t1; + t1 = this._exception; + trace = t1 !== null && typeof t1 === "object" ? t1.stack : null; + return this._trace = trace == null ? "" : trace; + }, + $isStackTrace: 1 + }; + H.Closure.prototype = { + toString$0: function(_) { + var $constructor = this.constructor, + $name = $constructor == null ? null : $constructor.name; + return "Closure '" + H.unminifyOrTag($name == null ? "unknown" : $name) + "'"; + }, + $isFunction: 1, + get$$call: function() { + return this; + }, + "call*": "call$1", + $requiredArgCount: 1, + $defaultValues: null + }; + H.TearOffClosure.prototype = {}; + H.StaticClosure.prototype = { + toString$0: function(_) { + var $name = this.$static_name; + if ($name == null) + return "Closure of unknown static method"; + return "Closure '" + H.unminifyOrTag($name) + "'"; + } + }; + H.BoundClosure.prototype = { + $eq: function(_, other) { + var _this = this; + if (other == null) + return false; + if (_this === other) + return true; + if (!(other instanceof H.BoundClosure)) + return false; + return _this._self === other._self && _this.__js_helper$_target === other.__js_helper$_target && _this._receiver === other._receiver; + }, + get$hashCode: function(_) { + var receiverHashCode, + t1 = this._receiver; + if (t1 == null) + receiverHashCode = H.Primitives_objectHashCode(this._self); + else + receiverHashCode = typeof t1 !== "object" ? J.get$hashCode$(t1) : H.Primitives_objectHashCode(t1); + return (receiverHashCode ^ H.Primitives_objectHashCode(this.__js_helper$_target)) >>> 0; + }, + toString$0: function(_) { + var receiver = this._receiver; + if (receiver == null) + receiver = this._self; + return "Closure '" + H.S(this._name) + "' of " + ("Instance of '" + H.S(H.Primitives_objectTypeName(receiver)) + "'"); + } + }; + H.RuntimeError.prototype = { + toString$0: function(_) { + return "RuntimeError: " + H.S(this.message); + } + }; + H._AssertionError.prototype = { + toString$0: function(_) { + return "Assertion failed: " + P.Error_safeToString(this.message); + } + }; + H._Required.prototype = {}; + H.JsLinkedHashMap.prototype = { + get$length: function(_) { + return this._length; + }, + get$isEmpty: function(_) { + return this._length === 0; + }, + get$isNotEmpty: function(_) { + return !this.get$isEmpty(this); + }, + get$keys: function() { + return new H.LinkedHashMapKeyIterable(this, H._instanceType(this)._eval$1("LinkedHashMapKeyIterable<1>")); + }, + containsKey$1: function(key) { + var strings, t1; + if (typeof key == "string") { + strings = this._strings; + if (strings == null) + return false; + return this._containsTableEntry$2(strings, key); + } else { + t1 = this.internalContainsKey$1(key); + return t1; + } + }, + internalContainsKey$1: function(key) { + var _this = this, + rest = _this.__js_helper$_rest; + if (rest == null) + return false; + return _this.internalFindBucketIndex$2(_this._getTableBucket$2(rest, _this.internalComputeHashCode$1(key)), key) >= 0; + }, + addAll$1: function(_, other) { + H._instanceType(this)._eval$1("Map<1,2>")._as(other).forEach$1(0, new H.JsLinkedHashMap_addAll_closure(this)); + }, + $index: function(_, key) { + var strings, cell, t1, nums, _this = this, _null = null; + if (typeof key == "string") { + strings = _this._strings; + if (strings == null) + return _null; + cell = _this._getTableCell$2(strings, key); + t1 = cell == null ? _null : cell.hashMapCellValue; + return t1; + } else if (typeof key == "number" && (key & 0x3ffffff) === key) { + nums = _this._nums; + if (nums == null) + return _null; + cell = _this._getTableCell$2(nums, key); + t1 = cell == null ? _null : cell.hashMapCellValue; + return t1; + } else + return _this.internalGet$1(key); + }, + internalGet$1: function(key) { + var bucket, index, _this = this, + rest = _this.__js_helper$_rest; + if (rest == null) + return null; + bucket = _this._getTableBucket$2(rest, _this.internalComputeHashCode$1(key)); + index = _this.internalFindBucketIndex$2(bucket, key); + if (index < 0) + return null; + return bucket[index].hashMapCellValue; + }, + $indexSet: function(_, key, value) { + var strings, nums, _this = this, + t1 = H._instanceType(_this); + t1._precomputed1._as(key); + t1._rest[1]._as(value); + if (typeof key == "string") { + strings = _this._strings; + _this._addHashTableEntry$3(strings == null ? _this._strings = _this._newHashTable$0() : strings, key, value); + } else if (typeof key == "number" && (key & 0x3ffffff) === key) { + nums = _this._nums; + _this._addHashTableEntry$3(nums == null ? _this._nums = _this._newHashTable$0() : nums, key, value); + } else + _this.internalSet$2(key, value); + }, + internalSet$2: function(key, value) { + var rest, hash, bucket, index, _this = this, + t1 = H._instanceType(_this); + t1._precomputed1._as(key); + t1._rest[1]._as(value); + rest = _this.__js_helper$_rest; + if (rest == null) + rest = _this.__js_helper$_rest = _this._newHashTable$0(); + hash = _this.internalComputeHashCode$1(key); + bucket = _this._getTableBucket$2(rest, hash); + if (bucket == null) + _this._setTableEntry$3(rest, hash, [_this._newLinkedCell$2(key, value)]); + else { + index = _this.internalFindBucketIndex$2(bucket, key); + if (index >= 0) + bucket[index].hashMapCellValue = value; + else + bucket.push(_this._newLinkedCell$2(key, value)); + } + }, + putIfAbsent$2: function(key, ifAbsent) { + var value, _this = this, + t1 = H._instanceType(_this); + t1._precomputed1._as(key); + t1._eval$1("2()")._as(ifAbsent); + if (_this.containsKey$1(key)) + return _this.$index(0, key); + value = ifAbsent.call$0(); + _this.$indexSet(0, key, value); + return value; + }, + remove$1: function(_, key) { + var _this = this; + if (typeof key == "string") + return _this._removeHashTableEntry$2(_this._strings, key); + else if (typeof key == "number" && (key & 0x3ffffff) === key) + return _this._removeHashTableEntry$2(_this._nums, key); + else + return _this.internalRemove$1(key); + }, + internalRemove$1: function(key) { + var hash, bucket, index, cell, _this = this, + rest = _this.__js_helper$_rest; + if (rest == null) + return null; + hash = _this.internalComputeHashCode$1(key); + bucket = _this._getTableBucket$2(rest, hash); + index = _this.internalFindBucketIndex$2(bucket, key); + if (index < 0) + return null; + cell = bucket.splice(index, 1)[0]; + _this._unlinkCell$1(cell); + if (bucket.length === 0) + _this._deleteTableEntry$2(rest, hash); + return cell.hashMapCellValue; + }, + forEach$1: function(_, action) { + var cell, modifications, _this = this; + H._instanceType(_this)._eval$1("~(1,2)")._as(action); + cell = _this._first; + modifications = _this._modifications; + for (; cell != null;) { + action.call$2(cell.hashMapCellKey, cell.hashMapCellValue); + if (modifications !== _this._modifications) + throw H.wrapException(P.ConcurrentModificationError$(_this)); + cell = cell._next; + } + }, + _addHashTableEntry$3: function(table, key, value) { + var cell, _this = this, + t1 = H._instanceType(_this); + t1._precomputed1._as(key); + t1._rest[1]._as(value); + cell = _this._getTableCell$2(table, key); + if (cell == null) + _this._setTableEntry$3(table, key, _this._newLinkedCell$2(key, value)); + else + cell.hashMapCellValue = value; + }, + _removeHashTableEntry$2: function(table, key) { + var cell; + if (table == null) + return null; + cell = this._getTableCell$2(table, key); + if (cell == null) + return null; + this._unlinkCell$1(cell); + this._deleteTableEntry$2(table, key); + return cell.hashMapCellValue; + }, + _modified$0: function() { + this._modifications = this._modifications + 1 & 67108863; + }, + _newLinkedCell$2: function(key, value) { + var _this = this, + t1 = H._instanceType(_this), + cell = new H.LinkedHashMapCell(t1._precomputed1._as(key), t1._rest[1]._as(value)); + if (_this._first == null) + _this._first = _this._last = cell; + else { + t1 = _this._last; + t1.toString; + cell._previous = t1; + _this._last = t1._next = cell; + } + ++_this._length; + _this._modified$0(); + return cell; + }, + _unlinkCell$1: function(cell) { + var _this = this, + previous = cell._previous, + next = cell._next; + if (previous == null) + _this._first = next; + else + previous._next = next; + if (next == null) + _this._last = previous; + else + next._previous = previous; + --_this._length; + _this._modified$0(); + }, + internalComputeHashCode$1: function(key) { + return J.get$hashCode$(key) & 0x3ffffff; + }, + internalFindBucketIndex$2: function(bucket, key) { + var $length, i; + if (bucket == null) + return -1; + $length = bucket.length; + for (i = 0; i < $length; ++i) + if (J.$eq$(bucket[i].hashMapCellKey, key)) + return i; + return -1; + }, + toString$0: function(_) { + return P.MapBase_mapToString(this); + }, + _getTableCell$2: function(table, key) { + return table[key]; + }, + _getTableBucket$2: function(table, key) { + return table[key]; + }, + _setTableEntry$3: function(table, key, value) { + table[key] = value; + }, + _deleteTableEntry$2: function(table, key) { + delete table[key]; + }, + _containsTableEntry$2: function(table, key) { + return this._getTableCell$2(table, key) != null; + }, + _newHashTable$0: function() { + var _s20_ = "", + table = Object.create(null); + this._setTableEntry$3(table, _s20_, table); + this._deleteTableEntry$2(table, _s20_); + return table; + }, + $isLinkedHashMap: 1 + }; + H.JsLinkedHashMap_addAll_closure.prototype = { + call$2: function(key, value) { + var t1 = this.$this, + t2 = H._instanceType(t1); + t1.$indexSet(0, t2._precomputed1._as(key), t2._rest[1]._as(value)); + }, + $signature: function() { + return H._instanceType(this.$this)._eval$1("Null(1,2)"); + } + }; + H.LinkedHashMapCell.prototype = {}; + H.LinkedHashMapKeyIterable.prototype = { + get$length: function(_) { + return this._map._length; + }, + get$isEmpty: function(_) { + return this._map._length === 0; + }, + get$iterator: function(_) { + var t1 = this._map, + t2 = new H.LinkedHashMapKeyIterator(t1, t1._modifications, this.$ti._eval$1("LinkedHashMapKeyIterator<1>")); + t2._cell = t1._first; + return t2; + }, + contains$1: function(_, element) { + return this._map.containsKey$1(element); + } + }; + H.LinkedHashMapKeyIterator.prototype = { + get$current: function() { + return this.__js_helper$_current; + }, + moveNext$0: function() { + var cell, _this = this, + t1 = _this._map; + if (_this._modifications !== t1._modifications) + throw H.wrapException(P.ConcurrentModificationError$(t1)); + cell = _this._cell; + if (cell == null) { + _this.set$__js_helper$_current(null); + return false; + } else { + _this.set$__js_helper$_current(cell.hashMapCellKey); + _this._cell = cell._next; + return true; + } + }, + set$__js_helper$_current: function(_current) { + this.__js_helper$_current = this.$ti._eval$1("1?")._as(_current); + }, + $isIterator: 1 + }; + H.initHooks_closure.prototype = { + call$1: function(o) { + return this.getTag(o); + }, + $signature: 3 + }; + H.initHooks_closure0.prototype = { + call$2: function(o, tag) { + return this.getUnknownTag(o, tag); + }, + $signature: 31 + }; + H.initHooks_closure1.prototype = { + call$1: function(tag) { + return this.prototypeForTag(H._asStringS(tag)); + }, + $signature: 41 + }; + H.NativeByteBuffer.prototype = { + get$runtimeType: function(receiver) { + return C.Type_ByteBuffer_RkP; + } + }; + H.NativeTypedData.prototype = {}; + H.NativeByteData.prototype = { + get$runtimeType: function(receiver) { + return C.Type_ByteData_zNC; + }, + _getUint32$2: function(receiver, byteOffset, littleEndian) { + return receiver.getUint32(byteOffset, littleEndian); + }, + $isByteData: 1 + }; + H.NativeTypedArray.prototype = { + get$length: function(receiver) { + return receiver.length; + }, + $isJSIndexable: 1, + $isJavaScriptIndexingBehavior: 1 + }; + H.NativeTypedArrayOfDouble.prototype = { + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + }, + $indexSet: function(receiver, index, value) { + H._asIntS(index); + H._asDoubleS(value); + H._checkValidIndex(index, receiver, receiver.length); + receiver[index] = value; + }, + $isEfficientLengthIterable: 1, + $isIterable: 1, + $isList: 1 + }; + H.NativeTypedArrayOfInt.prototype = { + $indexSet: function(receiver, index, value) { + H._asIntS(index); + H._asIntS(value); + H._checkValidIndex(index, receiver, receiver.length); + receiver[index] = value; + }, + $isEfficientLengthIterable: 1, + $isIterable: 1, + $isList: 1 + }; + H.NativeFloat32List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Float32List_LB7; + } + }; + H.NativeFloat64List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Float64List_LB7; + } + }; + H.NativeInt16List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Int16List_uXf; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + } + }; + H.NativeInt32List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Int32List_O50; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + } + }; + H.NativeInt8List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Int8List_ekJ; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + } + }; + H.NativeUint16List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Uint16List_2bx; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + } + }; + H.NativeUint32List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Uint32List_2bx; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + } + }; + H.NativeUint8ClampedList.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Uint8ClampedList_Jik; + }, + get$length: function(receiver) { + return receiver.length; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + } + }; + H.NativeUint8List.prototype = { + get$runtimeType: function(receiver) { + return C.Type_Uint8List_WLA; + }, + get$length: function(receiver) { + return receiver.length; + }, + $index: function(receiver, index) { + H._asIntS(index); + H._checkValidIndex(index, receiver, receiver.length); + return receiver[index]; + }, + $isUint8List: 1 + }; + H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin.prototype = {}; + H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin.prototype = {}; + H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin.prototype = {}; + H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin.prototype = {}; + H.Rti.prototype = { + _eval$1: function(recipe) { + return H._Universe_evalInEnvironment(init.typeUniverse, this, recipe); + }, + _bind$1: function(typeOrTuple) { + return H._Universe_bind(init.typeUniverse, this, typeOrTuple); + } + }; + H._FunctionParameters.prototype = {}; + H._Type.prototype = { + toString$0: function(_) { + return H._rtiToString(this._rti, null); + } + }; + H._Error.prototype = { + toString$0: function(_) { + return this.__rti$_message; + } + }; + H._TypeError.prototype = {}; + P._AsyncRun__initializeScheduleImmediate_internalCallback.prototype = { + call$1: function(_) { + var t1 = this._box_0, + f = t1.storedCallback; + t1.storedCallback = null; + f.call$0(); + }, + $signature: 11 + }; + P._AsyncRun__initializeScheduleImmediate_closure.prototype = { + call$1: function(callback) { + var t1, t2; + this._box_0.storedCallback = type$.void_Function._as(callback); + t1 = this.div; + t2 = this.span; + t1.firstChild ? t1.removeChild(t2) : t1.appendChild(t2); + }, + $signature: 33 + }; + P._AsyncRun__scheduleImmediateJsOverride_internalCallback.prototype = { + call$0: function() { + this.callback.call$0(); + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 1 + }; + P._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback.prototype = { + call$0: function() { + this.callback.call$0(); + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 1 + }; + P._TimerImpl.prototype = { + _TimerImpl$2: function(milliseconds, callback) { + if (self.setTimeout != null) + this._handle = self.setTimeout(H.convertDartClosureToJS(new P._TimerImpl_internalCallback(this, callback), 0), milliseconds); + else + throw H.wrapException(P.UnsupportedError$("`setTimeout()` not found.")); + }, + cancel$0: function() { + if (self.setTimeout != null) { + var t1 = this._handle; + if (t1 == null) + return; + self.clearTimeout(t1); + this._handle = null; + } else + throw H.wrapException(P.UnsupportedError$("Canceling a timer.")); + }, + $isTimer: 1 + }; + P._TimerImpl_internalCallback.prototype = { + call$0: function() { + this.$this._handle = null; + this.callback.call$0(); + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 0 + }; + P._AsyncAwaitCompleter.prototype = { + complete$1: function(value) { + var t2, _this = this, + t1 = _this.$ti; + t1._eval$1("1/?")._as(value); + if (!_this.isSync) + _this._future._asyncComplete$1(value); + else { + t2 = _this._future; + if (t1._eval$1("Future<1>")._is(value)) + t2._chainFuture$1(value); + else + t2._completeWithValue$1(t1._precomputed1._as(value)); + } + }, + completeError$2: function(e, st) { + var t1; + if (st == null) + st = P.AsyncError_defaultStackTrace(e); + t1 = this._future; + if (this.isSync) + t1._completeError$2(e, st); + else + t1._asyncCompleteError$2(e, st); + }, + completeError$1: function(e) { + return this.completeError$2(e, null); + }, + $isCompleter: 1 + }; + P._awaitOnObject_closure.prototype = { + call$1: function(result) { + return this.bodyFunction.call$2(0, result); + }, + $signature: 2 + }; + P._awaitOnObject_closure0.prototype = { + call$2: function(error, stackTrace) { + this.bodyFunction.call$2(1, new H.ExceptionAndStackTrace(error, type$.StackTrace._as(stackTrace))); + }, + "call*": "call$2", + $requiredArgCount: 2, + $signature: 34 + }; + P._wrapJsFunctionForAsync_closure.prototype = { + call$2: function(errorCode, result) { + this.$protected(H._asIntS(errorCode), result); + }, + $signature: 38 + }; + P._BroadcastSubscription.prototype = { + _onPause$0: function() { + }, + _onResume$0: function() { + }, + set$_async$_next: function(_next) { + this._async$_next = this.$ti._eval$1("_BroadcastSubscription<1>?")._as(_next); + }, + set$_async$_previous: function(_previous) { + this._async$_previous = this.$ti._eval$1("_BroadcastSubscription<1>?")._as(_previous); + } + }; + P._BroadcastStreamController.prototype = { + get$_mayAddEvent: function() { + return this._state < 4; + }, + _removeListener$1: function(subscription) { + var previous, next; + H._instanceType(this)._eval$1("_BroadcastSubscription<1>")._as(subscription); + previous = subscription._async$_previous; + next = subscription._async$_next; + if (previous == null) + this.set$_firstSubscription(next); + else + previous.set$_async$_next(next); + if (next == null) + this.set$_lastSubscription(previous); + else + next.set$_async$_previous(previous); + subscription.set$_async$_previous(subscription); + subscription.set$_async$_next(subscription); + }, + _subscribe$4: function(onData, onError, onDone, cancelOnError) { + var t2, t3, t4, t5, subscription, oldLast, _this = this, + t1 = H._instanceType(_this); + t1._eval$1("~(1)?")._as(onData); + type$.nullable_void_Function._as(onDone); + if ((_this._state & 4) !== 0) { + t1 = new P._DoneStreamSubscription($.Zone__current, onDone, t1._eval$1("_DoneStreamSubscription<1>")); + t1._schedule$0(); + return t1; + } + t2 = $.Zone__current; + t3 = cancelOnError ? 1 : 0; + t4 = P._BufferingStreamSubscription__registerDataHandler(t2, onData, t1._precomputed1); + t5 = P._BufferingStreamSubscription__registerErrorHandler(t2, onError); + t1 = t1._eval$1("_BroadcastSubscription<1>"); + subscription = new P._BroadcastSubscription(_this, t4, t5, type$.void_Function._as(onDone), t2, t3, t1); + subscription.set$_async$_previous(subscription); + subscription.set$_async$_next(subscription); + t1._as(subscription); + subscription._eventState = _this._state & 1; + oldLast = _this._lastSubscription; + _this.set$_lastSubscription(subscription); + subscription.set$_async$_next(null); + subscription.set$_async$_previous(oldLast); + if (oldLast == null) + _this.set$_firstSubscription(subscription); + else + oldLast.set$_async$_next(subscription); + if (_this._firstSubscription == _this._lastSubscription) + P._runGuarded(_this.onListen); + return subscription; + }, + _recordCancel$1: function(sub) { + var _this = this, + t1 = H._instanceType(_this); + sub = t1._eval$1("_BroadcastSubscription<1>")._as(t1._eval$1("StreamSubscription<1>")._as(sub)); + if (sub._async$_next === sub) + return null; + t1 = sub._eventState; + if ((t1 & 2) !== 0) + sub._eventState = t1 | 4; + else { + _this._removeListener$1(sub); + if ((_this._state & 2) === 0 && _this._firstSubscription == null) + _this._callOnCancel$0(); + } + return null; + }, + _recordPause$1: function(subscription) { + H._instanceType(this)._eval$1("StreamSubscription<1>")._as(subscription); + }, + _recordResume$1: function(subscription) { + H._instanceType(this)._eval$1("StreamSubscription<1>")._as(subscription); + }, + _addEventError$0: function() { + if ((this._state & 4) !== 0) + return new P.StateError("Cannot add new events after calling close"); + return new P.StateError("Cannot add new events while doing an addStream"); + }, + add$1: function(_, data) { + var _this = this; + H._instanceType(_this)._precomputed1._as(data); + if (!_this.get$_mayAddEvent()) + throw H.wrapException(_this._addEventError$0()); + _this._sendData$1(data); + }, + _forEachListener$1: function(action) { + var t1, subscription, id, next, _this = this; + H._instanceType(_this)._eval$1("~(_BufferingStreamSubscription<1>)")._as(action); + t1 = _this._state; + if ((t1 & 2) !== 0) + throw H.wrapException(P.StateError$("Cannot fire new event. Controller is already firing an event")); + subscription = _this._firstSubscription; + if (subscription == null) + return; + id = t1 & 1; + _this._state = t1 ^ 3; + for (; subscription != null;) { + t1 = subscription._eventState; + if ((t1 & 1) === id) { + subscription._eventState = t1 | 2; + action.call$1(subscription); + t1 = subscription._eventState ^= 1; + next = subscription._async$_next; + if ((t1 & 4) !== 0) + _this._removeListener$1(subscription); + subscription._eventState &= 4294967293; + subscription = next; + } else + subscription = subscription._async$_next; + } + _this._state &= 4294967293; + if (_this._firstSubscription == null) + _this._callOnCancel$0(); + }, + _callOnCancel$0: function() { + if ((this._state & 4) !== 0) { + var doneFuture = this._doneFuture; + if (doneFuture._state === 0) + doneFuture._asyncComplete$1(null); + } + P._runGuarded(this.onCancel); + }, + set$_firstSubscription: function(_firstSubscription) { + this._firstSubscription = H._instanceType(this)._eval$1("_BroadcastSubscription<1>?")._as(_firstSubscription); + }, + set$_lastSubscription: function(_lastSubscription) { + this._lastSubscription = H._instanceType(this)._eval$1("_BroadcastSubscription<1>?")._as(_lastSubscription); + }, + $isStreamController: 1, + $is_StreamControllerLifecycle: 1, + $is_EventSink: 1, + $is_EventDispatch: 1 + }; + P._SyncBroadcastStreamController.prototype = { + get$_mayAddEvent: function() { + return P._BroadcastStreamController.prototype.get$_mayAddEvent.call(this) && (this._state & 2) === 0; + }, + _addEventError$0: function() { + if ((this._state & 2) !== 0) + return new P.StateError("Cannot fire new event. Controller is already firing an event"); + return this.super$_BroadcastStreamController$_addEventError(); + }, + _sendData$1: function(data) { + var t2, _this = this, + t1 = _this.$ti; + t1._precomputed1._as(data); + t2 = _this._firstSubscription; + if (t2 == null) + return; + if (t2 === _this._lastSubscription) { + _this._state |= 2; + t1._eval$1("_BroadcastSubscription<1>")._as(t2)._add$1(data); + _this._state &= 4294967293; + if (_this._firstSubscription == null) + _this._callOnCancel$0(); + return; + } + _this._forEachListener$1(new P._SyncBroadcastStreamController__sendData_closure(_this, data)); + } + }; + P._SyncBroadcastStreamController__sendData_closure.prototype = { + call$1: function(subscription) { + this.$this.$ti._eval$1("_BufferingStreamSubscription<1>")._as(subscription)._add$1(this.data); + }, + $signature: function() { + return this.$this.$ti._eval$1("Null(_BufferingStreamSubscription<1>)"); + } + }; + P._AsyncBroadcastStreamController.prototype = { + _sendData$1: function(data) { + var subscription, + t1 = this.$ti; + t1._precomputed1._as(data); + for (subscription = this._firstSubscription, t1 = t1._eval$1("_DelayedData<1>"); subscription != null; subscription = subscription._async$_next) + subscription._addPending$1(new P._DelayedData(data, t1)); + } + }; + P.Future.prototype = {}; + P.Completer.prototype = {}; + P._Completer.prototype = { + completeError$2: function(error, stackTrace) { + var t1; + P.ArgumentError_checkNotNull(error, "error", type$.Object); + t1 = this.future; + if (t1._state !== 0) + throw H.wrapException(P.StateError$("Future already completed")); + if (stackTrace == null) + stackTrace = P.AsyncError_defaultStackTrace(error); + t1._asyncCompleteError$2(error, stackTrace); + }, + completeError$1: function(error) { + return this.completeError$2(error, null); + }, + $isCompleter: 1 + }; + P._AsyncCompleter.prototype = { + complete$1: function(value) { + var t2, + t1 = this.$ti; + t1._eval$1("1/?")._as(value); + t2 = this.future; + if (t2._state !== 0) + throw H.wrapException(P.StateError$("Future already completed")); + t2._asyncComplete$1(t1._eval$1("1/")._as(value)); + }, + complete$0: function() { + return this.complete$1(null); + } + }; + P._FutureListener.prototype = { + matchesErrorTest$1: function(asyncError) { + if ((this.state & 15) !== 6) + return true; + return this.result._zone.runUnary$2$2(type$.bool_Function_Object._as(this.callback), asyncError.error, type$.bool, type$.Object); + }, + handleError$1: function(asyncError) { + var errorCallback = this.errorCallback, + t1 = type$.dynamic, + t2 = type$.Object, + t3 = this.$ti._eval$1("2/"), + t4 = this.result._zone; + if (type$.dynamic_Function_Object_StackTrace._is(errorCallback)) + return t3._as(t4.runBinary$3$3(errorCallback, asyncError.error, asyncError.stackTrace, t1, t2, type$.StackTrace)); + else + return t3._as(t4.runUnary$2$2(type$.dynamic_Function_Object._as(errorCallback), asyncError.error, t1, t2)); + } + }; + P._Future.prototype = { + then$1$2$onError: function(f, onError, $R) { + var currentZone, result, t2, + t1 = this.$ti; + t1._bind$1($R)._eval$1("1/(2)")._as(f); + currentZone = $.Zone__current; + if (currentZone !== C.C__RootZone) { + $R._eval$1("@<0/>")._bind$1(t1._precomputed1)._eval$1("1(2)")._as(f); + if (onError != null) + onError = P._registerErrorHandler(onError, currentZone); + } + result = new P._Future($.Zone__current, $R._eval$1("_Future<0>")); + t2 = onError == null ? 1 : 3; + this._addListener$1(new P._FutureListener(result, t2, f, onError, t1._eval$1("@<1>")._bind$1($R)._eval$1("_FutureListener<1,2>"))); + return result; + }, + then$1$1: function(f, $R) { + return this.then$1$2$onError(f, null, $R); + }, + _thenAwait$1$2: function(f, onError, $E) { + var result, + t1 = this.$ti; + t1._bind$1($E)._eval$1("1/(2)")._as(f); + result = new P._Future($.Zone__current, $E._eval$1("_Future<0>")); + this._addListener$1(new P._FutureListener(result, 19, f, onError, t1._eval$1("@<1>")._bind$1($E)._eval$1("_FutureListener<1,2>"))); + return result; + }, + whenComplete$1: function(action) { + var t1, result; + type$.dynamic_Function._as(action); + t1 = this.$ti; + result = new P._Future($.Zone__current, t1); + this._addListener$1(new P._FutureListener(result, 8, action, null, t1._eval$1("@<1>")._bind$1(t1._precomputed1)._eval$1("_FutureListener<1,2>"))); + return result; + }, + _addListener$1: function(listener) { + var source, _this = this, + t1 = _this._state; + if (t1 <= 1) { + listener._nextListener = type$.nullable__FutureListener_dynamic_dynamic._as(_this._resultOrListeners); + _this._resultOrListeners = listener; + } else { + if (t1 === 2) { + source = type$._Future_dynamic._as(_this._resultOrListeners); + t1 = source._state; + if (t1 < 4) { + source._addListener$1(listener); + return; + } + _this._state = t1; + _this._resultOrListeners = source._resultOrListeners; + } + P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__addListener_closure(_this, listener))); + } + }, + _prependListeners$1: function(listeners) { + var t1, existingListeners, next, cursor, next0, source, _this = this, _box_0 = {}; + _box_0.listeners = listeners; + if (listeners == null) + return; + t1 = _this._state; + if (t1 <= 1) { + existingListeners = type$.nullable__FutureListener_dynamic_dynamic._as(_this._resultOrListeners); + _this._resultOrListeners = listeners; + if (existingListeners != null) { + next = listeners._nextListener; + for (cursor = listeners; next != null; cursor = next, next = next0) + next0 = next._nextListener; + cursor._nextListener = existingListeners; + } + } else { + if (t1 === 2) { + source = type$._Future_dynamic._as(_this._resultOrListeners); + t1 = source._state; + if (t1 < 4) { + source._prependListeners$1(listeners); + return; + } + _this._state = t1; + _this._resultOrListeners = source._resultOrListeners; + } + _box_0.listeners = _this._reverseListeners$1(listeners); + P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__prependListeners_closure(_box_0, _this))); + } + }, + _removeListeners$0: function() { + var current = type$.nullable__FutureListener_dynamic_dynamic._as(this._resultOrListeners); + this._resultOrListeners = null; + return this._reverseListeners$1(current); + }, + _reverseListeners$1: function(listeners) { + var current, prev, next; + for (current = listeners, prev = null; current != null; prev = current, current = next) { + next = current._nextListener; + current._nextListener = prev; + } + return prev; + }, + _complete$1: function(value) { + var listeners, _this = this, + t1 = _this.$ti; + t1._eval$1("1/")._as(value); + if (t1._eval$1("Future<1>")._is(value)) + if (t1._is(value)) + P._Future__chainCoreFuture(value, _this); + else + P._Future__chainForeignFuture(value, _this); + else { + listeners = _this._removeListeners$0(); + t1._precomputed1._as(value); + _this._state = 4; + _this._resultOrListeners = value; + P._Future__propagateToListeners(_this, listeners); + } + }, + _completeWithValue$1: function(value) { + var listeners, _this = this; + _this.$ti._precomputed1._as(value); + listeners = _this._removeListeners$0(); + _this._state = 4; + _this._resultOrListeners = value; + P._Future__propagateToListeners(_this, listeners); + }, + _completeError$2: function(error, stackTrace) { + var listeners, t1, _this = this; + type$.StackTrace._as(stackTrace); + listeners = _this._removeListeners$0(); + t1 = P.AsyncError$(error, stackTrace); + _this._state = 8; + _this._resultOrListeners = t1; + P._Future__propagateToListeners(_this, listeners); + }, + _asyncComplete$1: function(value) { + var t1 = this.$ti; + t1._eval$1("1/")._as(value); + if (t1._eval$1("Future<1>")._is(value)) { + this._chainFuture$1(value); + return; + } + this._asyncCompleteWithValue$1(t1._precomputed1._as(value)); + }, + _asyncCompleteWithValue$1: function(value) { + var _this = this; + _this.$ti._precomputed1._as(value); + _this._state = 1; + P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__asyncCompleteWithValue_closure(_this, value))); + }, + _chainFuture$1: function(value) { + var _this = this, + t1 = _this.$ti; + t1._eval$1("Future<1>")._as(value); + if (t1._is(value)) { + if (value._state === 8) { + _this._state = 1; + P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__chainFuture_closure(_this, value))); + } else + P._Future__chainCoreFuture(value, _this); + return; + } + P._Future__chainForeignFuture(value, _this); + }, + _asyncCompleteError$2: function(error, stackTrace) { + type$.StackTrace._as(stackTrace); + this._state = 1; + P._rootScheduleMicrotask(null, null, this._zone, type$.void_Function._as(new P._Future__asyncCompleteError_closure(this, error, stackTrace))); + }, + $isFuture: 1 + }; + P._Future__addListener_closure.prototype = { + call$0: function() { + P._Future__propagateToListeners(this.$this, this.listener); + }, + $signature: 1 + }; + P._Future__prependListeners_closure.prototype = { + call$0: function() { + P._Future__propagateToListeners(this.$this, this._box_0.listeners); + }, + $signature: 1 + }; + P._Future__chainForeignFuture_closure.prototype = { + call$1: function(value) { + var t1 = this.target; + t1._state = 0; + t1._complete$1(value); + }, + $signature: 11 + }; + P._Future__chainForeignFuture_closure0.prototype = { + call$2: function(error, stackTrace) { + type$.StackTrace._as(stackTrace); + this.target._completeError$2(error, stackTrace); + }, + "call*": "call$2", + $requiredArgCount: 2, + $signature: 27 + }; + P._Future__chainForeignFuture_closure1.prototype = { + call$0: function() { + this.target._completeError$2(this.e, this.s); + }, + $signature: 1 + }; + P._Future__asyncCompleteWithValue_closure.prototype = { + call$0: function() { + this.$this._completeWithValue$1(this.value); + }, + $signature: 1 + }; + P._Future__chainFuture_closure.prototype = { + call$0: function() { + P._Future__chainCoreFuture(this.value, this.$this); + }, + $signature: 1 + }; + P._Future__asyncCompleteError_closure.prototype = { + call$0: function() { + this.$this._completeError$2(this.error, this.stackTrace); + }, + $signature: 1 + }; + P._Future__propagateToListeners_handleWhenCompleteCallback.prototype = { + call$0: function() { + var e, s, t1, exception, t2, originalSource, _this = this, completeResult = null; + try { + t1 = _this._box_0.listener; + completeResult = t1.result._zone.run$1$1(type$.dynamic_Function._as(t1.callback), type$.dynamic); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + if (_this.hasError) { + t1 = type$.AsyncError._as(_this._box_1.source._resultOrListeners).error; + t2 = e; + t2 = t1 == null ? t2 == null : t1 === t2; + t1 = t2; + } else + t1 = false; + t2 = _this._box_0; + if (t1) + t2.listenerValueOrError = type$.AsyncError._as(_this._box_1.source._resultOrListeners); + else + t2.listenerValueOrError = P.AsyncError$(e, s); + t2.listenerHasError = true; + return; + } + if (completeResult instanceof P._Future && completeResult._state >= 4) { + if (completeResult._state === 8) { + t1 = _this._box_0; + t1.listenerValueOrError = type$.AsyncError._as(completeResult._resultOrListeners); + t1.listenerHasError = true; + } + return; + } + if (type$.Future_dynamic._is(completeResult)) { + originalSource = _this._box_1.source; + t1 = _this._box_0; + t1.listenerValueOrError = completeResult.then$1$1(new P._Future__propagateToListeners_handleWhenCompleteCallback_closure(originalSource), type$.dynamic); + t1.listenerHasError = false; + } + }, + $signature: 0 + }; + P._Future__propagateToListeners_handleWhenCompleteCallback_closure.prototype = { + call$1: function(_) { + return this.originalSource; + }, + $signature: 28 + }; + P._Future__propagateToListeners_handleValueCallback.prototype = { + call$0: function() { + var e, s, t1, t2, t3, t4, t5, exception; + try { + t1 = this._box_0; + t2 = t1.listener; + t3 = t2.$ti; + t4 = t3._precomputed1; + t5 = t4._as(this.sourceResult); + t1.listenerValueOrError = t2.result._zone.runUnary$2$2(t3._eval$1("2/(1)")._as(t2.callback), t5, t3._eval$1("2/"), t4); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + t1 = this._box_0; + t1.listenerValueOrError = P.AsyncError$(e, s); + t1.listenerHasError = true; + } + }, + $signature: 0 + }; + P._Future__propagateToListeners_handleError.prototype = { + call$0: function() { + var asyncError, e, s, t1, exception, t2, t3, t4, _this = this; + try { + asyncError = type$.AsyncError._as(_this._box_1.source._resultOrListeners); + t1 = _this._box_0; + if (H.boolConversionCheck(t1.listener.matchesErrorTest$1(asyncError)) && t1.listener.errorCallback != null) { + t1.listenerValueOrError = t1.listener.handleError$1(asyncError); + t1.listenerHasError = false; + } + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + t1 = type$.AsyncError._as(_this._box_1.source._resultOrListeners); + t2 = t1.error; + t3 = e; + t4 = _this._box_0; + if (t2 == null ? t3 == null : t2 === t3) + t4.listenerValueOrError = t1; + else + t4.listenerValueOrError = P.AsyncError$(e, s); + t4.listenerHasError = true; + } + }, + $signature: 0 + }; + P._AsyncCallbackEntry.prototype = {}; + P.Stream.prototype = { + map$1: function(_, convert) { + var t1 = H._instanceType(this); + return new P._MapStream(t1._eval$1("@(Stream.T)")._as(convert), this, t1._eval$1("_MapStream")); + }, + get$length: function(_) { + var t1 = {}, + future = new P._Future($.Zone__current, type$._Future_int); + t1.count = 0; + this.listen$4$cancelOnError$onDone$onError(new P.Stream_length_closure(t1, this), true, new P.Stream_length_closure0(t1, future), future.get$_completeError()); + return future; + }, + get$first: function(_) { + var future = new P._Future($.Zone__current, H._instanceType(this)._eval$1("_Future")), + subscription = this.listen$4$cancelOnError$onDone$onError(null, true, new P.Stream_first_closure(future), future.get$_completeError()); + subscription.onData$1(new P.Stream_first_closure0(this, subscription, future)); + return future; + } + }; + P.Stream_length_closure.prototype = { + call$1: function(_) { + H._instanceType(this.$this)._eval$1("Stream.T")._as(_); + ++this._box_0.count; + }, + $signature: function() { + return H._instanceType(this.$this)._eval$1("Null(Stream.T)"); + } + }; + P.Stream_length_closure0.prototype = { + call$0: function() { + this.future._complete$1(this._box_0.count); + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 1 + }; + P.Stream_first_closure.prototype = { + call$0: function() { + var e, s, t1, exception, error, stackTrace; + try { + t1 = H.IterableElementError_noElement(); + throw H.wrapException(t1); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + error = e; + stackTrace = s; + if (stackTrace == null) + stackTrace = P.AsyncError_defaultStackTrace(error); + this.future._completeError$2(error, stackTrace); + } + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 1 + }; + P.Stream_first_closure0.prototype = { + call$1: function(value) { + P._cancelAndValue(this.subscription, this.future, H._instanceType(this.$this)._eval$1("Stream.T")._as(value)); + }, + $signature: function() { + return H._instanceType(this.$this)._eval$1("Null(Stream.T)"); + } + }; + P.StreamSubscription.prototype = {}; + P.StreamTransformerBase.prototype = {}; + P.StreamController.prototype = {}; + P._StreamController.prototype = { + get$_pendingEvents: function() { + var t1, _this = this; + if ((_this._state & 8) === 0) + return H._instanceType(_this)._eval$1("_PendingEvents<1>?")._as(_this._varData); + t1 = H._instanceType(_this); + return t1._eval$1("_PendingEvents<1>?")._as(t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).get$varData()); + }, + _ensurePendingEvents$0: function() { + var events, t1, _this = this; + if ((_this._state & 8) === 0) { + events = _this._varData; + if (events == null) + events = _this._varData = new P._StreamImplEvents(H._instanceType(_this)._eval$1("_StreamImplEvents<1>")); + return H._instanceType(_this)._eval$1("_StreamImplEvents<1>")._as(events); + } + t1 = H._instanceType(_this); + events = t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).get$varData(); + return t1._eval$1("_StreamImplEvents<1>")._as(events); + }, + get$_async$_subscription: function() { + var varData = this._varData; + if ((this._state & 8) !== 0) + varData = type$._StreamControllerAddStreamState_nullable_Object._as(varData).get$varData(); + return H._instanceType(this)._eval$1("_ControllerSubscription<1>")._as(varData); + }, + _badEventState$0: function() { + if ((this._state & 4) !== 0) + return new P.StateError("Cannot add event after closing"); + return new P.StateError("Cannot add event while adding a stream"); + }, + _ensureDoneFuture$0: function() { + var t1 = this._doneFuture; + if (t1 == null) + t1 = this._doneFuture = (this._state & 2) !== 0 ? $.$get$Future__nullFuture() : new P._Future($.Zone__current, type$._Future_void); + return t1; + }, + add$1: function(_, value) { + var t2, _this = this, + t1 = H._instanceType(_this); + t1._precomputed1._as(value); + t2 = _this._state; + if (t2 >= 4) + throw H.wrapException(_this._badEventState$0()); + if ((t2 & 1) !== 0) + _this._sendData$1(value); + else if ((t2 & 3) === 0) + _this._ensurePendingEvents$0().add$1(0, new P._DelayedData(value, t1._eval$1("_DelayedData<1>"))); + }, + close$0: function(_) { + var _this = this, + t1 = _this._state; + if ((t1 & 4) !== 0) + return _this._ensureDoneFuture$0(); + if (t1 >= 4) + throw H.wrapException(_this._badEventState$0()); + t1 = _this._state = t1 | 4; + if ((t1 & 1) !== 0) + _this._sendDone$0(); + else if ((t1 & 3) === 0) + _this._ensurePendingEvents$0().add$1(0, C.C__DelayedDone); + return _this._ensureDoneFuture$0(); + }, + _subscribe$4: function(onData, onError, onDone, cancelOnError) { + var t2, t3, subscription, pendingEvents, addState, _this = this, + t1 = H._instanceType(_this); + t1._eval$1("~(1)?")._as(onData); + type$.nullable_void_Function._as(onDone); + if ((_this._state & 3) !== 0) + throw H.wrapException(P.StateError$("Stream has already been listened to.")); + t2 = $.Zone__current; + t3 = cancelOnError ? 1 : 0; + subscription = new P._ControllerSubscription(_this, P._BufferingStreamSubscription__registerDataHandler(t2, onData, t1._precomputed1), P._BufferingStreamSubscription__registerErrorHandler(t2, onError), P._BufferingStreamSubscription__registerDoneHandler(t2, onDone), t2, t3, t1._eval$1("_ControllerSubscription<1>")); + pendingEvents = _this.get$_pendingEvents(); + t3 = _this._state |= 1; + if ((t3 & 8) !== 0) { + addState = t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData); + addState.set$varData(subscription); + addState.resume$0(); + } else + _this._varData = subscription; + subscription._setPendingEvents$1(pendingEvents); + subscription._guardCallback$1(new P._StreamController__subscribe_closure(_this)); + return subscription; + }, + _recordCancel$1: function(subscription) { + var result, onCancel, cancelResult, e, s, exception, result0, _this = this, + t1 = H._instanceType(_this); + t1._eval$1("StreamSubscription<1>")._as(subscription); + result = null; + if ((_this._state & 8) !== 0) + result = t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).cancel$0(); + _this._varData = null; + _this._state = _this._state & 4294967286 | 2; + onCancel = _this.onCancel; + if (onCancel != null) + if (result == null) + try { + cancelResult = onCancel.call$0(); + if (type$.Future_void._is(cancelResult)) + result = cancelResult; + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + result0 = new P._Future($.Zone__current, type$._Future_void); + result0._asyncCompleteError$2(e, s); + result = result0; + } + else + result = result.whenComplete$1(onCancel); + t1 = new P._StreamController__recordCancel_complete(_this); + if (result != null) + result = result.whenComplete$1(t1); + else + t1.call$0(); + return result; + }, + _recordPause$1: function(subscription) { + var _this = this, + t1 = H._instanceType(_this); + t1._eval$1("StreamSubscription<1>")._as(subscription); + if ((_this._state & 8) !== 0) + t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).pause$0(); + P._runGuarded(_this.onPause); + }, + _recordResume$1: function(subscription) { + var _this = this, + t1 = H._instanceType(_this); + t1._eval$1("StreamSubscription<1>")._as(subscription); + if ((_this._state & 8) !== 0) + t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).resume$0(); + P._runGuarded(_this.onResume); + }, + $isStreamController: 1, + $is_StreamControllerLifecycle: 1, + $is_EventSink: 1, + $is_EventDispatch: 1 + }; + P._StreamController__subscribe_closure.prototype = { + call$0: function() { + P._runGuarded(this.$this.onListen); + }, + $signature: 1 + }; + P._StreamController__recordCancel_complete.prototype = { + call$0: function() { + var doneFuture = this.$this._doneFuture; + if (doneFuture != null && doneFuture._state === 0) + doneFuture._asyncComplete$1(null); + }, + $signature: 0 + }; + P._AsyncStreamControllerDispatch.prototype = { + _sendData$1: function(data) { + var t1 = this.$ti; + t1._precomputed1._as(data); + this.get$_async$_subscription()._addPending$1(new P._DelayedData(data, t1._eval$1("_DelayedData<1>"))); + }, + _sendError$2: function(error, stackTrace) { + this.get$_async$_subscription()._addPending$1(new P._DelayedError(error, stackTrace)); + }, + _sendDone$0: function() { + this.get$_async$_subscription()._addPending$1(C.C__DelayedDone); + } + }; + P._AsyncStreamController.prototype = {}; + P._ControllerStream.prototype = { + get$hashCode: function(_) { + return (H.Primitives_objectHashCode(this._controller) ^ 892482866) >>> 0; + }, + $eq: function(_, other) { + if (other == null) + return false; + if (this === other) + return true; + return other instanceof P._ControllerStream && other._controller === this._controller; + } + }; + P._ControllerSubscription.prototype = { + _onCancel$0: function() { + return this._controller._recordCancel$1(this); + }, + _onPause$0: function() { + this._controller._recordPause$1(this); + }, + _onResume$0: function() { + this._controller._recordResume$1(this); + } + }; + P._StreamSinkWrapper.prototype = {}; + P._BufferingStreamSubscription.prototype = { + _setPendingEvents$1: function(pendingEvents) { + var _this = this; + H._instanceType(_this)._eval$1("_PendingEvents<_BufferingStreamSubscription.T>?")._as(pendingEvents); + if (pendingEvents == null) + return; + _this.set$_pending(pendingEvents); + if (pendingEvents.lastPendingEvent != null) { + _this._state = (_this._state | 64) >>> 0; + pendingEvents.schedule$1(_this); + } + }, + onData$1: function(handleData) { + var t1 = H._instanceType(this); + this.set$_async$_onData(P._BufferingStreamSubscription__registerDataHandler(this._zone, t1._eval$1("~(_BufferingStreamSubscription.T)?")._as(handleData), t1._eval$1("_BufferingStreamSubscription.T"))); + }, + pause$0: function() { + var t2, t3, _this = this, + t1 = _this._state; + if ((t1 & 8) !== 0) + return; + t2 = (t1 + 128 | 4) >>> 0; + _this._state = t2; + if (t1 < 128) { + t3 = _this._pending; + if (t3 != null) + if (t3._state === 1) + t3._state = 3; + } + if ((t1 & 4) === 0 && (t2 & 32) === 0) + _this._guardCallback$1(_this.get$_onPause()); + }, + resume$0: function() { + var _this = this, + t1 = _this._state; + if ((t1 & 8) !== 0) + return; + if (t1 >= 128) { + t1 = _this._state = t1 - 128; + if (t1 < 128) + if ((t1 & 64) !== 0 && _this._pending.lastPendingEvent != null) + _this._pending.schedule$1(_this); + else { + t1 = (t1 & 4294967291) >>> 0; + _this._state = t1; + if ((t1 & 32) === 0) + _this._guardCallback$1(_this.get$_onResume()); + } + } + }, + cancel$0: function() { + var _this = this, + t1 = (_this._state & 4294967279) >>> 0; + _this._state = t1; + if ((t1 & 8) === 0) + _this._cancel$0(); + t1 = _this._cancelFuture; + return t1 == null ? $.$get$Future__nullFuture() : t1; + }, + _cancel$0: function() { + var t2, _this = this, + t1 = _this._state = (_this._state | 8) >>> 0; + if ((t1 & 64) !== 0) { + t2 = _this._pending; + if (t2._state === 1) + t2._state = 3; + } + if ((t1 & 32) === 0) + _this.set$_pending(null); + _this._cancelFuture = _this._onCancel$0(); + }, + _add$1: function(data) { + var t2, _this = this, + t1 = H._instanceType(_this); + t1._eval$1("_BufferingStreamSubscription.T")._as(data); + t2 = _this._state; + if ((t2 & 8) !== 0) + return; + if (t2 < 32) + _this._sendData$1(data); + else + _this._addPending$1(new P._DelayedData(data, t1._eval$1("_DelayedData<_BufferingStreamSubscription.T>"))); + }, + _addError$2: function(error, stackTrace) { + var t1 = this._state; + if ((t1 & 8) !== 0) + return; + if (t1 < 32) + this._sendError$2(error, stackTrace); + else + this._addPending$1(new P._DelayedError(error, stackTrace)); + }, + _close$0: function() { + var _this = this, + t1 = _this._state; + if ((t1 & 8) !== 0) + return; + t1 = (t1 | 2) >>> 0; + _this._state = t1; + if (t1 < 32) + _this._sendDone$0(); + else + _this._addPending$1(C.C__DelayedDone); + }, + _onPause$0: function() { + }, + _onResume$0: function() { + }, + _onCancel$0: function() { + return null; + }, + _addPending$1: function($event) { + var _this = this, + t1 = H._instanceType(_this), + pending = t1._eval$1("_StreamImplEvents<_BufferingStreamSubscription.T>?")._as(_this._pending); + if (pending == null) + pending = new P._StreamImplEvents(t1._eval$1("_StreamImplEvents<_BufferingStreamSubscription.T>")); + _this.set$_pending(pending); + pending.add$1(0, $event); + t1 = _this._state; + if ((t1 & 64) === 0) { + t1 = (t1 | 64) >>> 0; + _this._state = t1; + if (t1 < 128) + pending.schedule$1(_this); + } + }, + _sendData$1: function(data) { + var t2, _this = this, + t1 = H._instanceType(_this)._eval$1("_BufferingStreamSubscription.T"); + t1._as(data); + t2 = _this._state; + _this._state = (t2 | 32) >>> 0; + _this._zone.runUnaryGuarded$1$2(_this._async$_onData, data, t1); + _this._state = (_this._state & 4294967263) >>> 0; + _this._checkState$1((t2 & 4) !== 0); + }, + _sendError$2: function(error, stackTrace) { + var cancelFuture, _this = this, + t1 = _this._state, + t2 = new P._BufferingStreamSubscription__sendError_sendError(_this, error, stackTrace); + if ((t1 & 1) !== 0) { + _this._state = (t1 | 16) >>> 0; + _this._cancel$0(); + cancelFuture = _this._cancelFuture; + if (cancelFuture != null && cancelFuture !== $.$get$Future__nullFuture()) + cancelFuture.whenComplete$1(t2); + else + t2.call$0(); + } else { + t2.call$0(); + _this._checkState$1((t1 & 4) !== 0); + } + }, + _sendDone$0: function() { + var cancelFuture, _this = this, + t1 = new P._BufferingStreamSubscription__sendDone_sendDone(_this); + _this._cancel$0(); + _this._state = (_this._state | 16) >>> 0; + cancelFuture = _this._cancelFuture; + if (cancelFuture != null && cancelFuture !== $.$get$Future__nullFuture()) + cancelFuture.whenComplete$1(t1); + else + t1.call$0(); + }, + _guardCallback$1: function(callback) { + var t1, _this = this; + type$.void_Function._as(callback); + t1 = _this._state; + _this._state = (t1 | 32) >>> 0; + callback.call$0(); + _this._state = (_this._state & 4294967263) >>> 0; + _this._checkState$1((t1 & 4) !== 0); + }, + _checkState$1: function(wasInputPaused) { + var t2, isInputPaused, _this = this, + t1 = _this._state; + if ((t1 & 64) !== 0 && _this._pending.lastPendingEvent == null) { + t1 = _this._state = (t1 & 4294967231) >>> 0; + if ((t1 & 4) !== 0) + if (t1 < 128) { + t2 = _this._pending; + t2 = t2 == null ? null : t2.lastPendingEvent == null; + t2 = t2 !== false; + } else + t2 = false; + else + t2 = false; + if (t2) { + t1 = (t1 & 4294967291) >>> 0; + _this._state = t1; + } + } + for (; true; wasInputPaused = isInputPaused) { + if ((t1 & 8) !== 0) { + _this.set$_pending(null); + return; + } + isInputPaused = (t1 & 4) !== 0; + if (wasInputPaused === isInputPaused) + break; + _this._state = (t1 ^ 32) >>> 0; + if (isInputPaused) + _this._onPause$0(); + else + _this._onResume$0(); + t1 = (_this._state & 4294967263) >>> 0; + _this._state = t1; + } + if ((t1 & 64) !== 0 && t1 < 128) + _this._pending.schedule$1(_this); + }, + set$_async$_onData: function(_onData) { + this._async$_onData = H._instanceType(this)._eval$1("~(_BufferingStreamSubscription.T)")._as(_onData); + }, + set$_pending: function(_pending) { + this._pending = H._instanceType(this)._eval$1("_PendingEvents<_BufferingStreamSubscription.T>?")._as(_pending); + }, + $isStreamSubscription: 1, + $is_EventSink: 1, + $is_EventDispatch: 1 + }; + P._BufferingStreamSubscription__sendError_sendError.prototype = { + call$0: function() { + var onError, t3, t4, + t1 = this.$this, + t2 = t1._state; + if ((t2 & 8) !== 0 && (t2 & 16) === 0) + return; + t1._state = (t2 | 32) >>> 0; + onError = t1._onError; + t2 = this.error; + t3 = type$.Object; + t4 = t1._zone; + if (type$.void_Function_Object_StackTrace._is(onError)) + t4.runBinaryGuarded$2$3(onError, t2, this.stackTrace, t3, type$.StackTrace); + else + t4.runUnaryGuarded$1$2(type$.void_Function_Object._as(onError), t2, t3); + t1._state = (t1._state & 4294967263) >>> 0; + }, + $signature: 0 + }; + P._BufferingStreamSubscription__sendDone_sendDone.prototype = { + call$0: function() { + var t1 = this.$this, + t2 = t1._state; + if ((t2 & 16) === 0) + return; + t1._state = (t2 | 42) >>> 0; + t1._zone.runGuarded$1(t1._onDone); + t1._state = (t1._state & 4294967263) >>> 0; + }, + $signature: 0 + }; + P._StreamImpl.prototype = { + listen$4$cancelOnError$onDone$onError: function(onData, cancelOnError, onDone, onError) { + var t1 = H._instanceType(this); + t1._eval$1("~(1)?")._as(onData); + type$.nullable_void_Function._as(onDone); + return this._controller._subscribe$4(t1._eval$1("~(1)?")._as(onData), onError, onDone, cancelOnError === true); + }, + listen$2$onDone: function(onData, onDone) { + return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, null); + }, + listen$3$onDone$onError: function(onData, onDone, onError) { + return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, onError); + } + }; + P._DelayedEvent.prototype = { + set$next: function(next) { + this.next = type$.nullable__DelayedEvent_dynamic._as(next); + }, + get$next: function() { + return this.next; + } + }; + P._DelayedData.prototype = { + perform$1: function(dispatch) { + this.$ti._eval$1("_EventDispatch<1>")._as(dispatch)._sendData$1(this.value); + } + }; + P._DelayedError.prototype = { + perform$1: function(dispatch) { + dispatch._sendError$2(this.error, this.stackTrace); + } + }; + P._DelayedDone.prototype = { + perform$1: function(dispatch) { + dispatch._sendDone$0(); + }, + get$next: function() { + return null; + }, + set$next: function(_) { + throw H.wrapException(P.StateError$("No events after a done.")); + }, + $is_DelayedEvent: 1 + }; + P._PendingEvents.prototype = { + schedule$1: function(dispatch) { + var t1, _this = this; + _this.$ti._eval$1("_EventDispatch<1>")._as(dispatch); + t1 = _this._state; + if (t1 === 1) + return; + if (t1 >= 1) { + _this._state = 1; + return; + } + P.scheduleMicrotask(new P._PendingEvents_schedule_closure(_this, dispatch)); + _this._state = 1; + } + }; + P._PendingEvents_schedule_closure.prototype = { + call$0: function() { + var t2, $event, nextEvent, + t1 = this.$this, + oldState = t1._state; + t1._state = 0; + if (oldState === 3) + return; + t2 = t1.$ti._eval$1("_EventDispatch<1>")._as(this.dispatch); + $event = t1.firstPendingEvent; + nextEvent = $event.get$next(); + t1.firstPendingEvent = nextEvent; + if (nextEvent == null) + t1.lastPendingEvent = null; + $event.perform$1(t2); + }, + $signature: 1 + }; + P._StreamImplEvents.prototype = { + add$1: function(_, $event) { + var _this = this, + lastEvent = _this.lastPendingEvent; + if (lastEvent == null) + _this.firstPendingEvent = _this.lastPendingEvent = $event; + else { + lastEvent.set$next($event); + _this.lastPendingEvent = $event; + } + } + }; + P._DoneStreamSubscription.prototype = { + _schedule$0: function() { + var _this = this; + if ((_this._state & 2) !== 0) + return; + P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(_this.get$_sendDone())); + _this._state = (_this._state | 2) >>> 0; + }, + onData$1: function(handleData) { + this.$ti._eval$1("~(1)?")._as(handleData); + }, + pause$0: function() { + this._state += 4; + }, + resume$0: function() { + var t1 = this._state; + if (t1 >= 4) { + t1 = this._state = t1 - 4; + if (t1 < 4 && (t1 & 1) === 0) + this._schedule$0(); + } + }, + cancel$0: function() { + return $.$get$Future__nullFuture(); + }, + _sendDone$0: function() { + var _this = this, + t1 = _this._state = (_this._state & 4294967293) >>> 0; + if (t1 >= 4) + return; + _this._state = (t1 | 1) >>> 0; + _this._zone.runGuarded$1(_this._onDone); + }, + $isStreamSubscription: 1 + }; + P._StreamIterator.prototype = { + get$current: function() { + var _this = this; + if (_this._async$_subscription != null && _this._isPaused) + return _this.$ti._precomputed1._as(_this._stateData); + return _this.$ti._precomputed1._as(null); + }, + moveNext$0: function() { + var future, _this = this, + subscription = _this._async$_subscription; + if (subscription != null) { + if (_this._isPaused) { + future = new P._Future($.Zone__current, type$._Future_bool); + _this._stateData = future; + _this._isPaused = false; + subscription.resume$0(); + return future; + } + throw H.wrapException(P.StateError$("Already waiting for next.")); + } + return _this._initializeOrDone$0(); + }, + _initializeOrDone$0: function() { + var _this = this, + stateData = _this._stateData; + if (stateData != null) { + _this.set$_async$_subscription(_this.$ti._eval$1("Stream<1>")._as(stateData).listen$4$cancelOnError$onDone$onError(_this.get$_async$_onData(), true, _this.get$_onDone(), _this.get$_onError())); + return _this._stateData = new P._Future($.Zone__current, type$._Future_bool); + } + return $.$get$Future__falseFuture(); + }, + cancel$0: function() { + var _this = this, + subscription = _this._async$_subscription, + stateData = _this._stateData; + _this._stateData = null; + if (subscription != null) { + _this.set$_async$_subscription(null); + if (!_this._isPaused) + type$._Future_bool._as(stateData)._asyncComplete$1(false); + return subscription.cancel$0(); + } + return $.$get$Future__nullFuture(); + }, + _async$_onData$1: function(data) { + var moveNextFuture, t1, _this = this; + _this.$ti._precomputed1._as(data); + moveNextFuture = type$._Future_bool._as(_this._stateData); + _this._stateData = data; + _this._isPaused = true; + moveNextFuture._complete$1(true); + if (_this._isPaused) { + t1 = _this._async$_subscription; + if (t1 != null) + t1.pause$0(); + } + }, + _onError$2: function(error, stackTrace) { + var moveNextFuture; + type$.StackTrace._as(stackTrace); + moveNextFuture = type$._Future_bool._as(this._stateData); + this.set$_async$_subscription(null); + this._stateData = null; + moveNextFuture._completeError$2(error, stackTrace); + }, + _onDone$0: function() { + var moveNextFuture = type$._Future_bool._as(this._stateData); + this.set$_async$_subscription(null); + this._stateData = null; + moveNextFuture._complete$1(false); + }, + set$_async$_subscription: function(_subscription) { + this._async$_subscription = this.$ti._eval$1("StreamSubscription<1>?")._as(_subscription); + } + }; + P._cancelAndValue_closure.prototype = { + call$0: function() { + return this.future._complete$1(this.value); + }, + $signature: 0 + }; + P._ForwardingStream.prototype = { + listen$4$cancelOnError$onDone$onError: function(onData, cancelOnError, onDone, onError) { + var t2, t3, t4, t5, t6, + t1 = this.$ti; + t1._eval$1("~(2)?")._as(onData); + type$.nullable_void_Function._as(onDone); + t2 = t1._rest[1]; + t3 = $.Zone__current; + t4 = cancelOnError === true ? 1 : 0; + t5 = P._BufferingStreamSubscription__registerDataHandler(t3, onData, t2); + t6 = P._BufferingStreamSubscription__registerErrorHandler(t3, onError); + t1 = new P._ForwardingStreamSubscription(this, t5, t6, type$.void_Function._as(onDone), t3, t4, t1._eval$1("@<1>")._bind$1(t2)._eval$1("_ForwardingStreamSubscription<1,2>")); + t1.set$_async$_subscription(this._async$_source.listen$3$onDone$onError(t1.get$_handleData(), t1.get$_handleDone(), t1.get$_handleError())); + return t1; + }, + listen$3$onDone$onError: function(onData, onDone, onError) { + return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, onError); + } + }; + P._ForwardingStreamSubscription.prototype = { + _add$1: function(data) { + this.$ti._rest[1]._as(data); + if ((this._state & 2) !== 0) + return; + this.super$_BufferingStreamSubscription$_add(data); + }, + _addError$2: function(error, stackTrace) { + if ((this._state & 2) !== 0) + return; + this.super$_BufferingStreamSubscription$_addError(error, stackTrace); + }, + _onPause$0: function() { + var t1 = this._async$_subscription; + if (t1 != null) + t1.pause$0(); + }, + _onResume$0: function() { + var t1 = this._async$_subscription; + if (t1 != null) + t1.resume$0(); + }, + _onCancel$0: function() { + var subscription = this._async$_subscription; + if (subscription != null) { + this.set$_async$_subscription(null); + return subscription.cancel$0(); + } + return null; + }, + _handleData$1: function(data) { + this._stream._handleData$2(this.$ti._precomputed1._as(data), this); + }, + _handleError$2: function(error, stackTrace) { + type$.StackTrace._as(stackTrace); + this._stream.$ti._eval$1("_EventSink<2>")._as(this)._addError$2(error, stackTrace); + }, + _handleDone$0: function() { + this._stream.$ti._eval$1("_EventSink<2>")._as(this)._close$0(); + }, + set$_async$_subscription: function(_subscription) { + this._async$_subscription = this.$ti._eval$1("StreamSubscription<1>?")._as(_subscription); + } + }; + P._MapStream.prototype = { + _handleData$2: function(inputEvent, sink) { + var outputEvent, e, s, exception, + t1 = this.$ti; + t1._precomputed1._as(inputEvent); + t1._eval$1("_EventSink<2>")._as(sink); + outputEvent = null; + try { + outputEvent = this._transform.call$1(inputEvent); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + sink._addError$2(e, s); + return; + } + sink._add$1(outputEvent); + } + }; + P.AsyncError.prototype = { + toString$0: function(_) { + return H.S(this.error); + }, + $isError0: 1, + get$stackTrace: function() { + return this.stackTrace; + } + }; + P._Zone.prototype = {$isZone: 1}; + P._rootHandleUncaughtError_closure.prototype = { + call$0: function() { + var error = H.wrapException(this.error); + error.stack = J.toString$0$(this.stackTrace); + throw error; + }, + $signature: 1 + }; + P._RootZone.prototype = { + runGuarded$1: function(f) { + var e, s, exception, _null = null; + type$.void_Function._as(f); + try { + if (C.C__RootZone === $.Zone__current) { + f.call$0(); + return; + } + P._rootRun(_null, _null, this, f, type$.void); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + P._rootHandleUncaughtError(_null, _null, this, e, type$.StackTrace._as(s)); + } + }, + runUnaryGuarded$1$2: function(f, arg, $T) { + var e, s, exception, _null = null; + $T._eval$1("~(0)")._as(f); + $T._as(arg); + try { + if (C.C__RootZone === $.Zone__current) { + f.call$1(arg); + return; + } + P._rootRunUnary(_null, _null, this, f, arg, type$.void, $T); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + P._rootHandleUncaughtError(_null, _null, this, e, type$.StackTrace._as(s)); + } + }, + runBinaryGuarded$2$3: function(f, arg1, arg2, T1, T2) { + var e, s, exception, _null = null; + T1._eval$1("@<0>")._bind$1(T2)._eval$1("~(1,2)")._as(f); + T1._as(arg1); + T2._as(arg2); + try { + if (C.C__RootZone === $.Zone__current) { + f.call$2(arg1, arg2); + return; + } + P._rootRunBinary(_null, _null, this, f, arg1, arg2, type$.void, T1, T2); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + P._rootHandleUncaughtError(_null, _null, this, e, type$.StackTrace._as(s)); + } + }, + bindCallback$1$1: function(f, $R) { + return new P._RootZone_bindCallback_closure(this, $R._eval$1("0()")._as(f), $R); + }, + bindCallbackGuarded$1: function(f) { + return new P._RootZone_bindCallbackGuarded_closure(this, type$.void_Function._as(f)); + }, + bindUnaryCallbackGuarded$1$1: function(f, $T) { + return new P._RootZone_bindUnaryCallbackGuarded_closure(this, $T._eval$1("~(0)")._as(f), $T); + }, + $index: function(_, key) { + return null; + }, + run$1$1: function(f, $R) { + $R._eval$1("0()")._as(f); + if ($.Zone__current === C.C__RootZone) + return f.call$0(); + return P._rootRun(null, null, this, f, $R); + }, + runUnary$2$2: function(f, arg, $R, $T) { + $R._eval$1("@<0>")._bind$1($T)._eval$1("1(2)")._as(f); + $T._as(arg); + if ($.Zone__current === C.C__RootZone) + return f.call$1(arg); + return P._rootRunUnary(null, null, this, f, arg, $R, $T); + }, + runBinary$3$3: function(f, arg1, arg2, $R, T1, T2) { + $R._eval$1("@<0>")._bind$1(T1)._bind$1(T2)._eval$1("1(2,3)")._as(f); + T1._as(arg1); + T2._as(arg2); + if ($.Zone__current === C.C__RootZone) + return f.call$2(arg1, arg2); + return P._rootRunBinary(null, null, this, f, arg1, arg2, $R, T1, T2); + }, + registerBinaryCallback$3$1: function(f, $R, T1, T2) { + return $R._eval$1("@<0>")._bind$1(T1)._bind$1(T2)._eval$1("1(2,3)")._as(f); + } + }; + P._RootZone_bindCallback_closure.prototype = { + call$0: function() { + return this.$this.run$1$1(this.f, this.R); + }, + $signature: function() { + return this.R._eval$1("0()"); + } + }; + P._RootZone_bindCallbackGuarded_closure.prototype = { + call$0: function() { + return this.$this.runGuarded$1(this.f); + }, + $signature: 0 + }; + P._RootZone_bindUnaryCallbackGuarded_closure.prototype = { + call$1: function(arg) { + var t1 = this.T; + return this.$this.runUnaryGuarded$1$2(this.f, t1._as(arg), t1); + }, + $signature: function() { + return this.T._eval$1("~(0)"); + } + }; + P._LinkedHashSet.prototype = { + get$iterator: function(_) { + var _this = this, + t1 = new P._LinkedHashSetIterator(_this, _this._collection$_modifications, H._instanceType(_this)._eval$1("_LinkedHashSetIterator<1>")); + t1._collection$_cell = _this._collection$_first; + return t1; + }, + get$length: function(_) { + return this._collection$_length; + }, + add$1: function(_, element) { + var strings, nums, _this = this; + H._instanceType(_this)._precomputed1._as(element); + if (typeof element == "string" && element !== "__proto__") { + strings = _this._collection$_strings; + return _this._collection$_addHashTableEntry$2(strings == null ? _this._collection$_strings = P._LinkedHashSet__newHashTable() : strings, element); + } else if (typeof element == "number" && (element & 1073741823) === element) { + nums = _this._collection$_nums; + return _this._collection$_addHashTableEntry$2(nums == null ? _this._collection$_nums = P._LinkedHashSet__newHashTable() : nums, element); + } else + return _this._collection$_add$1(element); + }, + _collection$_add$1: function(element) { + var rest, hash, bucket, _this = this; + H._instanceType(_this)._precomputed1._as(element); + rest = _this._collection$_rest; + if (rest == null) + rest = _this._collection$_rest = P._LinkedHashSet__newHashTable(); + hash = _this._computeHashCode$1(element); + bucket = rest[hash]; + if (bucket == null) + rest[hash] = [_this._collection$_newLinkedCell$1(element)]; + else { + if (_this._findBucketIndex$2(bucket, element) >= 0) + return false; + bucket.push(_this._collection$_newLinkedCell$1(element)); + } + return true; + }, + _collection$_addHashTableEntry$2: function(table, element) { + H._instanceType(this)._precomputed1._as(element); + if (type$.nullable__LinkedHashSetCell._as(table[element]) != null) + return false; + table[element] = this._collection$_newLinkedCell$1(element); + return true; + }, + _collection$_newLinkedCell$1: function(element) { + var _this = this, + cell = new P._LinkedHashSetCell(H._instanceType(_this)._precomputed1._as(element)); + if (_this._collection$_first == null) + _this._collection$_first = _this._collection$_last = cell; + else + _this._collection$_last = _this._collection$_last._collection$_next = cell; + ++_this._collection$_length; + _this._collection$_modifications = 1073741823 & _this._collection$_modifications + 1; + return cell; + }, + _computeHashCode$1: function(element) { + return J.get$hashCode$(element) & 1073741823; + }, + _findBucketIndex$2: function(bucket, element) { + var $length, i; + if (bucket == null) + return -1; + $length = bucket.length; + for (i = 0; i < $length; ++i) + if (J.$eq$(bucket[i]._element, element)) + return i; + return -1; + } + }; + P._LinkedHashSetCell.prototype = {}; + P._LinkedHashSetIterator.prototype = { + get$current: function() { + return this._collection$_current; + }, + moveNext$0: function() { + var _this = this, + cell = _this._collection$_cell, + t1 = _this._set; + if (_this._collection$_modifications !== t1._collection$_modifications) + throw H.wrapException(P.ConcurrentModificationError$(t1)); + else if (cell == null) { + _this.set$_collection$_current(null); + return false; + } else { + _this.set$_collection$_current(_this.$ti._eval$1("1?")._as(cell._element)); + _this._collection$_cell = cell._collection$_next; + return true; + } + }, + set$_collection$_current: function(_current) { + this._collection$_current = this.$ti._eval$1("1?")._as(_current); + }, + $isIterator: 1 + }; + P.ListMixin.prototype = { + get$iterator: function(receiver) { + return new H.ListIterator(receiver, this.get$length(receiver), H.instanceType(receiver)._eval$1("ListIterator")); + }, + elementAt$1: function(receiver, index) { + return this.$index(receiver, index); + }, + get$isNotEmpty: function(receiver) { + return this.get$length(receiver) !== 0; + }, + map$1$1: function(receiver, f, $T) { + var t1 = H.instanceType(receiver); + return new H.MappedListIterable(receiver, t1._bind$1($T)._eval$1("1(ListMixin.E)")._as(f), t1._eval$1("@")._bind$1($T)._eval$1("MappedListIterable<1,2>")); + }, + map$1: function($receiver, f) { + return this.map$1$1($receiver, f, type$.dynamic); + }, + toList$1$growable: function(receiver, growable) { + var t1, first, result, i, _this = this; + if (_this.get$length(receiver) === 0) { + t1 = J.JSArray_JSArray$growable(0, H.instanceType(receiver)._eval$1("ListMixin.E")); + return t1; + } + first = _this.$index(receiver, 0); + result = P.List_List$filled(_this.get$length(receiver), first, true, H.instanceType(receiver)._eval$1("ListMixin.E")); + for (i = 1; i < _this.get$length(receiver); ++i) + C.JSArray_methods.$indexSet(result, i, _this.$index(receiver, i)); + return result; + }, + toList$0: function($receiver) { + return this.toList$1$growable($receiver, true); + }, + $add: function(receiver, other) { + var t2, cur, + t1 = H.instanceType(receiver); + t1._eval$1("List")._as(other); + t2 = H.setRuntimeTypeInfo([], t1._eval$1("JSArray")); + for (t1 = new H.ListIterator(receiver, this.get$length(receiver), t1._eval$1("ListIterator")); t1.moveNext$0();) { + cur = t1._current; + C.JSArray_methods.add$1(t2, cur); + } + for (t1 = other.get$iterator(other); t1.moveNext$0();) + C.JSArray_methods.add$1(t2, t1.get$current()); + return t2; + }, + toString$0: function(receiver) { + return P.IterableBase_iterableToFullString(receiver, "[", "]"); + } + }; + P.MapBase.prototype = {}; + P.MapBase_mapToString_closure.prototype = { + call$2: function(k, v) { + var t2, + t1 = this._box_0; + if (!t1.first) + this.result._contents += ", "; + t1.first = false; + t1 = this.result; + t2 = t1._contents += H.S(k); + t1._contents = t2 + ": "; + t1._contents += H.S(v); + }, + $signature: 13 + }; + P.MapMixin.prototype = { + forEach$1: function(_, action) { + var t1, key; + H._instanceType(this)._eval$1("~(MapMixin.K,MapMixin.V)")._as(action); + for (t1 = this.get$keys(), t1 = t1.get$iterator(t1); t1.moveNext$0();) { + key = t1.get$current(); + action.call$2(key, this.$index(0, key)); + } + }, + map$2$1: function(_, transform, K2, V2) { + var result, t1, key, entry; + H._instanceType(this)._bind$1(K2)._bind$1(V2)._eval$1("MapEntry<1,2>(MapMixin.K,MapMixin.V)")._as(transform); + result = P.LinkedHashMap_LinkedHashMap$_empty(K2, V2); + for (t1 = this.get$keys(), t1 = t1.get$iterator(t1); t1.moveNext$0();) { + key = t1.get$current(); + entry = transform.call$2(key, this.$index(0, key)); + result.$indexSet(0, C.JSNull_methods.get$key(entry), entry.get$value()); + } + return result; + }, + map$1: function($receiver, transform) { + return this.map$2$1($receiver, transform, type$.dynamic, type$.dynamic); + }, + containsKey$1: function(key) { + return this.get$keys().contains$1(0, key); + }, + get$length: function(_) { + var t1 = this.get$keys(); + return t1.get$length(t1); + }, + get$isEmpty: function(_) { + var t1 = this.get$keys(); + return t1.get$isEmpty(t1); + }, + toString$0: function(_) { + return P.MapBase_mapToString(this); + }, + $isMap: 1 + }; + P._UnmodifiableMapMixin.prototype = { + $indexSet: function(_, key, value) { + var t1 = H._instanceType(this); + t1._precomputed1._as(key); + t1._rest[1]._as(value); + throw H.wrapException(P.UnsupportedError$("Cannot modify unmodifiable map")); + } + }; + P.MapView.prototype = { + $index: function(_, key) { + return this._collection$_map.$index(0, key); + }, + $indexSet: function(_, key, value) { + var t1 = H._instanceType(this); + this._collection$_map.$indexSet(0, t1._precomputed1._as(key), t1._rest[1]._as(value)); + }, + containsKey$1: function(key) { + return this._collection$_map.containsKey$1(key); + }, + forEach$1: function(_, action) { + this._collection$_map.forEach$1(0, H._instanceType(this)._eval$1("~(1,2)")._as(action)); + }, + get$isEmpty: function(_) { + var t1 = this._collection$_map; + return t1.get$isEmpty(t1); + }, + get$length: function(_) { + var t1 = this._collection$_map; + return t1.get$length(t1); + }, + get$keys: function() { + return this._collection$_map.get$keys(); + }, + toString$0: function(_) { + return P.MapBase_mapToString(this._collection$_map); + }, + map$2$1: function(_, transform, K2, V2) { + return this._collection$_map.map$2$1(0, H._instanceType(this)._bind$1(K2)._bind$1(V2)._eval$1("MapEntry<1,2>(3,4)")._as(transform), K2, V2); + }, + map$1: function($receiver, transform) { + return this.map$2$1($receiver, transform, type$.dynamic, type$.dynamic); + }, + $isMap: 1 + }; + P.UnmodifiableMapView.prototype = {}; + P.ListQueue.prototype = { + get$iterator: function(_) { + var _this = this; + return new P._ListQueueIterator(_this, _this._tail, _this._modificationCount, _this._head, _this.$ti._eval$1("_ListQueueIterator<1>")); + }, + get$isEmpty: function(_) { + return this._head === this._tail; + }, + get$length: function(_) { + return (this._tail - this._head & this._collection$_table.length - 1) >>> 0; + }, + elementAt$1: function(_, index) { + var t1, t2, t3, _this = this, + $length = _this.get$length(_this); + if (0 > index || index >= $length) + H.throwExpression(P.IndexError$(index, _this, "index", null, $length)); + t1 = _this._collection$_table; + t2 = t1.length; + t3 = (_this._head + index & t2 - 1) >>> 0; + if (t3 < 0 || t3 >= t2) + return H.ioore(t1, t3); + return t1[t3]; + }, + toString$0: function(_) { + return P.IterableBase_iterableToFullString(this, "{", "}"); + }, + set$_collection$_table: function(_table) { + this._collection$_table = this.$ti._eval$1("List<1?>")._as(_table); + }, + $isQueue: 1 + }; + P._ListQueueIterator.prototype = { + get$current: function() { + var cur = this._collection$_current; + return cur; + }, + moveNext$0: function() { + var t2, t3, _this = this, + t1 = _this._queue; + if (_this._modificationCount !== t1._modificationCount) + H.throwExpression(P.ConcurrentModificationError$(t1)); + t2 = _this._position; + if (t2 === _this._end) { + _this.set$_collection$_current(null); + return false; + } + t3 = t1._collection$_table; + if (t2 >= t3.length) + return H.ioore(t3, t2); + _this.set$_collection$_current(t3[t2]); + _this._position = (_this._position + 1 & t1._collection$_table.length - 1) >>> 0; + return true; + }, + set$_collection$_current: function(_current) { + this._collection$_current = this.$ti._eval$1("1?")._as(_current); + }, + $isIterator: 1 + }; + P._SetBase.prototype = { + map$1: function(_, f) { + var t1 = H._instanceType(this); + return new H.EfficientLengthMappedIterable(this, t1._eval$1("@(1)")._as(f), t1._eval$1("EfficientLengthMappedIterable<1,@>")); + }, + toString$0: function(_) { + return P.IterableBase_iterableToFullString(this, "{", "}"); + }, + $isEfficientLengthIterable: 1, + $isIterable: 1 + }; + P._UnmodifiableMapView_MapView__UnmodifiableMapMixin.prototype = {}; + P._JsonMap.prototype = { + $index: function(_, key) { + var result, + t1 = this._processed; + if (t1 == null) + return this._data.$index(0, key); + else if (typeof key != "string") + return null; + else { + result = t1[key]; + return typeof result == "undefined" ? this._process$1(key) : result; + } + }, + get$length: function(_) { + var t1; + if (this._processed == null) { + t1 = this._data; + t1 = t1.get$length(t1); + } else + t1 = this._computeKeys$0().length; + return t1; + }, + get$isEmpty: function(_) { + return this.get$length(this) === 0; + }, + get$keys: function() { + if (this._processed == null) + return this._data.get$keys(); + return new P._JsonMapKeyIterable(this); + }, + $indexSet: function(_, key, value) { + var processed, original, _this = this; + if (_this._processed == null) + _this._data.$indexSet(0, key, value); + else if (_this.containsKey$1(key)) { + processed = _this._processed; + processed[key] = value; + original = _this._original; + if (original == null ? processed != null : original !== processed) + original[key] = null; + } else + _this._upgrade$0().$indexSet(0, key, value); + }, + containsKey$1: function(key) { + if (this._processed == null) + return this._data.containsKey$1(key); + return Object.prototype.hasOwnProperty.call(this._original, key); + }, + forEach$1: function(_, f) { + var keys, i, key, value, _this = this; + type$.void_Function_String_dynamic._as(f); + if (_this._processed == null) + return _this._data.forEach$1(0, f); + keys = _this._computeKeys$0(); + for (i = 0; i < keys.length; ++i) { + key = keys[i]; + value = _this._processed[key]; + if (typeof value == "undefined") { + value = P._convertJsonToDartLazy(_this._original[key]); + _this._processed[key] = value; + } + f.call$2(key, value); + if (keys !== _this._data) + throw H.wrapException(P.ConcurrentModificationError$(_this)); + } + }, + _computeKeys$0: function() { + var keys = type$.nullable_List_dynamic._as(this._data); + if (keys == null) + keys = this._data = H.setRuntimeTypeInfo(Object.keys(this._original), type$.JSArray_String); + return keys; + }, + _upgrade$0: function() { + var result, keys, i, t1, key, _this = this; + if (_this._processed == null) + return _this._data; + result = P.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.dynamic); + keys = _this._computeKeys$0(); + for (i = 0; t1 = keys.length, i < t1; ++i) { + key = keys[i]; + result.$indexSet(0, key, _this.$index(0, key)); + } + if (t1 === 0) + C.JSArray_methods.add$1(keys, ""); + else + C.JSArray_methods.set$length(keys, 0); + _this._original = _this._processed = null; + return _this._data = result; + }, + _process$1: function(key) { + var result; + if (!Object.prototype.hasOwnProperty.call(this._original, key)) + return null; + result = P._convertJsonToDartLazy(this._original[key]); + return this._processed[key] = result; + } + }; + P._JsonMapKeyIterable.prototype = { + get$length: function(_) { + var t1 = this._parent; + return t1.get$length(t1); + }, + elementAt$1: function(_, index) { + var t1 = this._parent; + if (t1._processed == null) + t1 = t1.get$keys().elementAt$1(0, index); + else { + t1 = t1._computeKeys$0(); + if (index < 0 || index >= t1.length) + return H.ioore(t1, index); + t1 = t1[index]; + } + return t1; + }, + get$iterator: function(_) { + var t1 = this._parent; + if (t1._processed == null) { + t1 = t1.get$keys(); + t1 = t1.get$iterator(t1); + } else { + t1 = t1._computeKeys$0(); + t1 = new J.ArrayIterator(t1, t1.length, H._arrayInstanceType(t1)._eval$1("ArrayIterator<1>")); + } + return t1; + }, + contains$1: function(_, key) { + return this._parent.containsKey$1(key); + } + }; + P.Utf8Decoder_closure.prototype = { + call$0: function() { + var t1, exception; + try { + t1 = new TextDecoder("utf-8", {fatal: true}); + return t1; + } catch (exception) { + H.unwrapException(exception); + } + return null; + }, + $signature: 14 + }; + P.Utf8Decoder_closure0.prototype = { + call$0: function() { + var t1, exception; + try { + t1 = new TextDecoder("utf-8", {fatal: false}); + return t1; + } catch (exception) { + H.unwrapException(exception); + } + return null; + }, + $signature: 14 + }; + P.Codec.prototype = {}; + P.Converter.prototype = {}; + P.JsonUnsupportedObjectError.prototype = { + toString$0: function(_) { + var safeString = P.Error_safeToString(this.unsupportedObject); + return (this.cause != null ? "Converting object to an encodable object failed:" : "Converting object did not return an encodable object:") + " " + safeString; + } + }; + P.JsonCyclicError.prototype = { + toString$0: function(_) { + return "Cyclic error in JSON stringify"; + } + }; + P.JsonCodec.prototype = { + decode$2$reviver: function(source, reviver) { + var t1; + type$.nullable_nullable_Object_Function_2_nullable_Object_and_nullable_Object._as(reviver); + t1 = P._parseJson(source, this.get$decoder()._reviver); + return t1; + }, + encode$2$toEncodable: function(value, toEncodable) { + var t1; + type$.nullable_nullable_Object_Function_dynamic._as(toEncodable); + t1 = P._JsonStringStringifier_stringify(value, this.get$encoder()._toEncodable, null); + return t1; + }, + encode$1: function(value) { + return this.encode$2$toEncodable(value, null); + }, + get$encoder: function() { + return C.JsonEncoder_null; + }, + get$decoder: function() { + return C.JsonDecoder_null; + } + }; + P.JsonEncoder.prototype = {}; + P.JsonDecoder.prototype = {}; + P._JsonStringifier.prototype = { + writeStringContent$1: function(s) { + var t1, t2, offset, i, charCode, t3, t4, + $length = s.length; + for (t1 = J.getInterceptor$s(s), t2 = this._sink, offset = 0, i = 0; i < $length; ++i) { + charCode = t1._codeUnitAt$1(s, i); + if (charCode > 92) { + if (charCode >= 55296) { + t3 = charCode & 64512; + if (t3 === 55296) { + t4 = i + 1; + t4 = !(t4 < $length && (C.JSString_methods._codeUnitAt$1(s, t4) & 64512) === 56320); + } else + t4 = false; + if (!t4) + if (t3 === 56320) { + t3 = i - 1; + t3 = !(t3 >= 0 && (C.JSString_methods.codeUnitAt$1(s, t3) & 64512) === 55296); + } else + t3 = false; + else + t3 = true; + if (t3) { + if (i > offset) + t2._contents += C.JSString_methods.substring$2(s, offset, i); + offset = i + 1; + t2._contents += H.Primitives_stringFromCharCode(92); + t2._contents += H.Primitives_stringFromCharCode(117); + t2._contents += H.Primitives_stringFromCharCode(100); + t3 = charCode >>> 8 & 15; + t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3); + t3 = charCode >>> 4 & 15; + t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3); + t3 = charCode & 15; + t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3); + } + } + continue; + } + if (charCode < 32) { + if (i > offset) + t2._contents += C.JSString_methods.substring$2(s, offset, i); + offset = i + 1; + t2._contents += H.Primitives_stringFromCharCode(92); + switch (charCode) { + case 8: + t2._contents += H.Primitives_stringFromCharCode(98); + break; + case 9: + t2._contents += H.Primitives_stringFromCharCode(116); + break; + case 10: + t2._contents += H.Primitives_stringFromCharCode(110); + break; + case 12: + t2._contents += H.Primitives_stringFromCharCode(102); + break; + case 13: + t2._contents += H.Primitives_stringFromCharCode(114); + break; + default: + t2._contents += H.Primitives_stringFromCharCode(117); + t2._contents += H.Primitives_stringFromCharCode(48); + t2._contents += H.Primitives_stringFromCharCode(48); + t3 = charCode >>> 4 & 15; + t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3); + t3 = charCode & 15; + t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3); + break; + } + } else if (charCode === 34 || charCode === 92) { + if (i > offset) + t2._contents += C.JSString_methods.substring$2(s, offset, i); + offset = i + 1; + t2._contents += H.Primitives_stringFromCharCode(92); + t2._contents += H.Primitives_stringFromCharCode(charCode); + } + } + if (offset === 0) + t2._contents += H.S(s); + else if (offset < $length) + t2._contents += t1.substring$2(s, offset, $length); + }, + _checkCycle$1: function(object) { + var t1, t2, i, t3; + for (t1 = this._seen, t2 = t1.length, i = 0; i < t2; ++i) { + t3 = t1[i]; + if (object == null ? t3 == null : object === t3) + throw H.wrapException(new P.JsonCyclicError(object, null)); + } + C.JSArray_methods.add$1(t1, object); + }, + writeObject$1: function(object) { + var customJson, e, t1, exception, _this = this; + if (_this.writeJsonValue$1(object)) + return; + _this._checkCycle$1(object); + try { + customJson = _this._toEncodable.call$1(object); + if (!_this.writeJsonValue$1(customJson)) { + t1 = P.JsonUnsupportedObjectError$(object, null, _this.get$_partialResult()); + throw H.wrapException(t1); + } + t1 = _this._seen; + if (0 >= t1.length) + return H.ioore(t1, -1); + t1.pop(); + } catch (exception) { + e = H.unwrapException(exception); + t1 = P.JsonUnsupportedObjectError$(object, e, _this.get$_partialResult()); + throw H.wrapException(t1); + } + }, + writeJsonValue$1: function(object) { + var t1, success, _this = this; + if (typeof object == "number") { + if (!isFinite(object)) + return false; + _this._sink._contents += C.JSNumber_methods.toString$0(object); + return true; + } else if (object === true) { + _this._sink._contents += "true"; + return true; + } else if (object === false) { + _this._sink._contents += "false"; + return true; + } else if (object == null) { + _this._sink._contents += "null"; + return true; + } else if (typeof object == "string") { + t1 = _this._sink; + t1._contents += '"'; + _this.writeStringContent$1(object); + t1._contents += '"'; + return true; + } else if (type$.List_dynamic._is(object)) { + _this._checkCycle$1(object); + _this.writeList$1(object); + t1 = _this._seen; + if (0 >= t1.length) + return H.ioore(t1, -1); + t1.pop(); + return true; + } else if (type$.Map_dynamic_dynamic._is(object)) { + _this._checkCycle$1(object); + success = _this.writeMap$1(object); + t1 = _this._seen; + if (0 >= t1.length) + return H.ioore(t1, -1); + t1.pop(); + return success; + } else + return false; + }, + writeList$1: function(list) { + var t2, i, + t1 = this._sink; + t1._contents += "["; + t2 = J.getInterceptor$ax(list); + if (t2.get$isNotEmpty(list)) { + this.writeObject$1(t2.$index(list, 0)); + for (i = 1; i < t2.get$length(list); ++i) { + t1._contents += ","; + this.writeObject$1(t2.$index(list, i)); + } + } + t1._contents += "]"; + }, + writeMap$1: function(map) { + var keyValueList, i, t1, separator, t2, _this = this, _box_0 = {}; + if (map.get$isEmpty(map)) { + _this._sink._contents += "{}"; + return true; + } + keyValueList = P.List_List$filled(map.get$length(map) * 2, null, false, type$.nullable_Object); + i = _box_0.i = 0; + _box_0.allStringKeys = true; + map.forEach$1(0, new P._JsonStringifier_writeMap_closure(_box_0, keyValueList)); + if (!_box_0.allStringKeys) + return false; + t1 = _this._sink; + t1._contents += "{"; + for (separator = '"'; i < keyValueList.length; i += 2, separator = ',"') { + t1._contents += separator; + _this.writeStringContent$1(H._asStringS(keyValueList[i])); + t1._contents += '":'; + t2 = i + 1; + if (t2 >= keyValueList.length) + return H.ioore(keyValueList, t2); + _this.writeObject$1(keyValueList[t2]); + } + t1._contents += "}"; + return true; + } + }; + P._JsonStringifier_writeMap_closure.prototype = { + call$2: function(key, value) { + var t1, t2; + if (typeof key != "string") + this._box_0.allStringKeys = false; + t1 = this.keyValueList; + t2 = this._box_0; + C.JSArray_methods.$indexSet(t1, t2.i++, key); + C.JSArray_methods.$indexSet(t1, t2.i++, value); + }, + $signature: 13 + }; + P._JsonStringStringifier.prototype = { + get$_partialResult: function() { + var t1 = this._sink._contents; + return t1.charCodeAt(0) == 0 ? t1 : t1; + } + }; + P.Utf8Decoder.prototype = { + convert$1: function(codeUnits) { + var t1, result; + type$.List_int._as(codeUnits); + t1 = this._allowMalformed; + result = P.Utf8Decoder__convertIntercepted(t1, codeUnits, 0, null); + if (result != null) + return result; + return new P._Utf8Decoder(t1).convertGeneral$4(codeUnits, 0, null, true); + } + }; + P._Utf8Decoder.prototype = { + convertGeneral$4: function(codeUnits, start, maybeEnd, single) { + var end, result, t1, message, _this = this; + type$.List_int._as(codeUnits); + end = P.RangeError_checkValidRange(start, maybeEnd, codeUnits.length); + if (start === end) + return ""; + result = _this._convertRecursive$4(codeUnits, start, end, true); + t1 = _this._convert$_state; + if ((t1 & 1) !== 0) { + message = P._Utf8Decoder_errorDescription(t1); + _this._convert$_state = 0; + throw H.wrapException(P.FormatException$(message, codeUnits, _this._charOrIndex)); + } + return result; + }, + _convertRecursive$4: function(bytes, start, end, single) { + var mid, s1, _this = this; + if (end - start > 1000) { + mid = C.JSInt_methods._tdivFast$1(start + end, 2); + s1 = _this._convertRecursive$4(bytes, start, mid, false); + if ((_this._convert$_state & 1) !== 0) + return s1; + return s1 + _this._convertRecursive$4(bytes, mid, end, single); + } + return _this.decodeGeneral$4(bytes, start, end, single); + }, + decodeGeneral$4: function(bytes, start, end, single) { + var byte, t2, type, t3, i0, markEnd, i1, m, _this = this, _65533 = 65533, + state = _this._convert$_state, + char = _this._charOrIndex, + buffer = new P.StringBuffer(""), + i = start + 1, + t1 = bytes.length; + if (start < 0 || start >= t1) + return H.ioore(bytes, start); + byte = bytes[start]; + $label0$0: + for (t2 = _this.allowMalformed; true;) { + for (; true; i = i0) { + type = C.JSString_methods._codeUnitAt$1("AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFFFFFFFFFFFFFFFFGGGGGGGGGGGGGGGGHHHHHHHHHHHHHHHHHHHHHHHHHHHIHHHJEEBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBKCCCCCCCCCCCCDCLONNNMEEEEEEEEEEE", byte) & 31; + char = state <= 32 ? byte & 61694 >>> type : (byte & 63 | char << 6) >>> 0; + state = C.JSString_methods._codeUnitAt$1(" \x000:XECCCCCN:lDb \x000:XECCCCCNvlDb \x000:XECCCCCN:lDb AAAAA\x00\x00\x00\x00\x00AAAAA00000AAAAA:::::AAAAAGG000AAAAA00KKKAAAAAG::::AAAAA:IIIIAAAAA000\x800AAAAA\x00\x00\x00\x00 AAAAA", state + type); + if (state === 0) { + buffer._contents += H.Primitives_stringFromCharCode(char); + if (i === end) + break $label0$0; + break; + } else if ((state & 1) !== 0) { + if (t2) + switch (state) { + case 69: + case 67: + buffer._contents += H.Primitives_stringFromCharCode(_65533); + break; + case 65: + buffer._contents += H.Primitives_stringFromCharCode(_65533); + --i; + break; + default: + t3 = buffer._contents += H.Primitives_stringFromCharCode(_65533); + buffer._contents = t3 + H.Primitives_stringFromCharCode(_65533); + break; + } + else { + _this._convert$_state = state; + _this._charOrIndex = i - 1; + return ""; + } + state = 0; + } + if (i === end) + break $label0$0; + i0 = i + 1; + if (i < 0 || i >= t1) + return H.ioore(bytes, i); + byte = bytes[i]; + } + i0 = i + 1; + if (i < 0 || i >= t1) + return H.ioore(bytes, i); + byte = bytes[i]; + if (byte < 128) { + while (true) { + if (!(i0 < end)) { + markEnd = end; + break; + } + i1 = i0 + 1; + if (i0 < 0 || i0 >= t1) + return H.ioore(bytes, i0); + byte = bytes[i0]; + if (byte >= 128) { + markEnd = i1 - 1; + i0 = i1; + break; + } + i0 = i1; + } + if (markEnd - i < 20) + for (m = i; m < markEnd; ++m) { + if (m >= t1) + return H.ioore(bytes, m); + buffer._contents += H.Primitives_stringFromCharCode(bytes[m]); + } + else + buffer._contents += P.String_String$fromCharCodes(bytes, i, markEnd); + if (markEnd === end) + break $label0$0; + i = i0; + } else + i = i0; + } + if (single && state > 32) + if (t2) + buffer._contents += H.Primitives_stringFromCharCode(_65533); + else { + _this._convert$_state = 77; + _this._charOrIndex = end; + return ""; + } + _this._convert$_state = state; + _this._charOrIndex = char; + t1 = buffer._contents; + return t1.charCodeAt(0) == 0 ? t1 : t1; + } + }; + P._symbolMapToStringMap_closure.prototype = { + call$2: function(key, value) { + this.result.$indexSet(0, type$.Symbol._as(key).__internal$_name, value); + }, + $signature: 15 + }; + P.NoSuchMethodError_toString_closure.prototype = { + call$2: function(key, value) { + var t1, t2, t3; + type$.Symbol._as(key); + t1 = this.sb; + t2 = this._box_0; + t1._contents += t2.comma; + t3 = t1._contents += H.S(key.__internal$_name); + t1._contents = t3 + ": "; + t1._contents += P.Error_safeToString(value); + t2.comma = ", "; + }, + $signature: 15 + }; + P.bool.prototype = {}; + P.DateTime.prototype = { + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof P.DateTime && this._value === other._value && this.isUtc === other.isUtc; + }, + get$hashCode: function(_) { + var t1 = this._value; + return (t1 ^ C.JSInt_methods._shrOtherPositive$1(t1, 30)) & 1073741823; + }, + toString$0: function(_) { + var _this = this, + y = P.DateTime__fourDigits(H.Primitives_getYear(_this)), + m = P.DateTime__twoDigits(H.Primitives_getMonth(_this)), + d = P.DateTime__twoDigits(H.Primitives_getDay(_this)), + h = P.DateTime__twoDigits(H.Primitives_getHours(_this)), + min = P.DateTime__twoDigits(H.Primitives_getMinutes(_this)), + sec = P.DateTime__twoDigits(H.Primitives_getSeconds(_this)), + ms = P.DateTime__threeDigits(H.Primitives_getMilliseconds(_this)); + if (_this.isUtc) + return y + "-" + m + "-" + d + " " + h + ":" + min + ":" + sec + "." + ms + "Z"; + else + return y + "-" + m + "-" + d + " " + h + ":" + min + ":" + sec + "." + ms; + } + }; + P.double.prototype = {}; + P.Duration.prototype = { + $add: function(_, other) { + return new P.Duration(C.JSInt_methods.$add(this._duration, type$.Duration._as(other).get$_duration())); + }, + $sub: function(_, other) { + return new P.Duration(C.JSInt_methods.$sub(this._duration, type$.Duration._as(other).get$_duration())); + }, + $lt: function(_, other) { + return C.JSInt_methods.$lt(this._duration, type$.Duration._as(other).get$_duration()); + }, + $gt: function(_, other) { + return C.JSInt_methods.$gt(this._duration, type$.Duration._as(other).get$_duration()); + }, + $ge: function(_, other) { + return C.JSInt_methods.$ge(this._duration, type$.Duration._as(other).get$_duration()); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof P.Duration && this._duration === other._duration; + }, + get$hashCode: function(_) { + return C.JSInt_methods.get$hashCode(this._duration); + }, + toString$0: function(_) { + var twoDigitMinutes, twoDigitSeconds, sixDigitUs, + t1 = new P.Duration_toString_twoDigits(), + t2 = this._duration; + if (t2 < 0) + return "-" + new P.Duration(0 - t2).toString$0(0); + twoDigitMinutes = t1.call$1(C.JSInt_methods._tdivFast$1(t2, 60000000) % 60); + twoDigitSeconds = t1.call$1(C.JSInt_methods._tdivFast$1(t2, 1000000) % 60); + sixDigitUs = new P.Duration_toString_sixDigits().call$1(t2 % 1000000); + return "" + C.JSInt_methods._tdivFast$1(t2, 3600000000) + ":" + H.S(twoDigitMinutes) + ":" + H.S(twoDigitSeconds) + "." + H.S(sixDigitUs); + } + }; + P.Duration_toString_sixDigits.prototype = { + call$1: function(n) { + if (n >= 100000) + return "" + n; + if (n >= 10000) + return "0" + n; + if (n >= 1000) + return "00" + n; + if (n >= 100) + return "000" + n; + if (n >= 10) + return "0000" + n; + return "00000" + n; + }, + $signature: 16 + }; + P.Duration_toString_twoDigits.prototype = { + call$1: function(n) { + if (n >= 10) + return "" + n; + return "0" + n; + }, + $signature: 16 + }; + P.Error0.prototype = { + get$stackTrace: function() { + return H.getTraceFromException(this.$thrownJsError); + } + }; + P.AssertionError.prototype = { + toString$0: function(_) { + var t1 = this.message; + if (t1 != null) + return "Assertion failed: " + P.Error_safeToString(t1); + return "Assertion failed"; + } + }; + P.NullThrownError.prototype = { + toString$0: function(_) { + return "Throw of null."; + } + }; + P.ArgumentError.prototype = { + get$_errorName: function() { + return "Invalid argument" + (!this._hasValue ? "(s)" : ""); + }, + get$_errorExplanation: function() { + return ""; + }, + toString$0: function(_) { + var explanation, errorValue, _this = this, + $name = _this.name, + nameString = $name == null ? "" : " (" + $name + ")", + message = _this.message, + messageString = message == null ? "" : ": " + message, + prefix = _this.get$_errorName() + nameString + messageString; + if (!_this._hasValue) + return prefix; + explanation = _this.get$_errorExplanation(); + errorValue = P.Error_safeToString(_this.invalidValue); + return prefix + explanation + ": " + errorValue; + } + }; + P.RangeError.prototype = { + get$_errorName: function() { + return "RangeError"; + }, + get$_errorExplanation: function() { + var explanation, + start = this.start, + end = this.end; + if (start == null) + explanation = end != null ? ": Not less than or equal to " + H.S(end) : ""; + else if (end == null) + explanation = ": Not greater than or equal to " + H.S(start); + else if (end > start) + explanation = ": Not in inclusive range " + H.S(start) + ".." + H.S(end); + else + explanation = end < start ? ": Valid value range is empty" : ": Only valid value is " + H.S(start); + return explanation; + } + }; + P.IndexError.prototype = { + get$_errorName: function() { + return "RangeError"; + }, + get$_errorExplanation: function() { + var t1, + invalidValue = H._asIntS(this.invalidValue); + if (typeof invalidValue !== "number") + return invalidValue.$lt(); + if (invalidValue < 0) + return ": index must not be negative"; + t1 = this.length; + if (t1 === 0) + return ": no indices are valid"; + return ": index should be less than " + H.S(t1); + }, + get$length: function(receiver) { + return this.length; + } + }; + P.NoSuchMethodError.prototype = { + toString$0: function(_) { + var $arguments, t1, _i, t2, t3, argument, receiverText, actualParameters, _this = this, _box_0 = {}, + sb = new P.StringBuffer(""); + _box_0.comma = ""; + $arguments = _this._core$_arguments; + for (t1 = $arguments.length, _i = 0, t2 = "", t3 = ""; _i < t1; ++_i, t3 = ", ") { + argument = $arguments[_i]; + sb._contents = t2 + t3; + t2 = sb._contents += P.Error_safeToString(argument); + _box_0.comma = ", "; + } + _this._namedArguments.forEach$1(0, new P.NoSuchMethodError_toString_closure(_box_0, sb)); + receiverText = P.Error_safeToString(_this._core$_receiver); + actualParameters = sb.toString$0(0); + t1 = "NoSuchMethodError: method not found: '" + H.S(_this._core$_memberName.__internal$_name) + "'\nReceiver: " + receiverText + "\nArguments: [" + actualParameters + "]"; + return t1; + } + }; + P.UnsupportedError.prototype = { + toString$0: function(_) { + return "Unsupported operation: " + this.message; + } + }; + P.UnimplementedError.prototype = { + toString$0: function(_) { + var message = this.message; + return message != null ? "UnimplementedError: " + message : "UnimplementedError"; + } + }; + P.StateError.prototype = { + toString$0: function(_) { + return "Bad state: " + this.message; + } + }; + P.ConcurrentModificationError.prototype = { + toString$0: function(_) { + var t1 = this.modifiedObject; + if (t1 == null) + return "Concurrent modification during iteration."; + return "Concurrent modification during iteration: " + P.Error_safeToString(t1) + "."; + } + }; + P.OutOfMemoryError.prototype = { + toString$0: function(_) { + return "Out of Memory"; + }, + get$stackTrace: function() { + return null; + }, + $isError0: 1 + }; + P.StackOverflowError.prototype = { + toString$0: function(_) { + return "Stack Overflow"; + }, + get$stackTrace: function() { + return null; + }, + $isError0: 1 + }; + P.CyclicInitializationError.prototype = { + toString$0: function(_) { + var variableName = this.variableName; + return variableName == null ? "Reading static variable during its initialization" : "Reading static variable '" + variableName + "' during its initialization"; + } + }; + P._Exception.prototype = { + toString$0: function(_) { + return "Exception: " + this.message; + } + }; + P.FormatException.prototype = { + toString$0: function(_) { + var message = this.message, + report = message != null && "" !== message ? "FormatException: " + H.S(message) : "FormatException", + offset = this.offset; + return offset != null ? report + (" (at offset " + H.S(offset) + ")") : report; + } + }; + P.Function.prototype = {}; + P.int.prototype = {}; + P.Iterable.prototype = { + map$1: function(_, f) { + var t1 = H._instanceType(this); + return H.MappedIterable_MappedIterable(this, t1._eval$1("@(Iterable.E)")._as(f), t1._eval$1("Iterable.E"), type$.dynamic); + }, + get$length: function(_) { + var count, + it = this.get$iterator(this); + for (count = 0; it.moveNext$0();) + ++count; + return count; + }, + elementAt$1: function(_, index) { + var t1, elementIndex, element; + P.RangeError_checkNotNegative(index, "index"); + for (t1 = this.get$iterator(this), elementIndex = 0; t1.moveNext$0();) { + element = t1.get$current(); + if (index === elementIndex) + return element; + ++elementIndex; + } + throw H.wrapException(P.IndexError$(index, this, "index", null, elementIndex)); + }, + toString$0: function(_) { + return P.IterableBase_iterableToShortString(this, "(", ")"); + } + }; + P.Iterator.prototype = {}; + P.List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1}; + P.Map.prototype = {}; + P.MapEntry.prototype = {}; + P.Null.prototype = { + get$hashCode: function(_) { + return P.Object.prototype.get$hashCode.call(C.JSNull_methods, this); + }, + toString$0: function(_) { + return "null"; + } + }; + P.num.prototype = {}; + P.Object.prototype = {constructor: P.Object, $isObject: 1, + $eq: function(_, other) { + return this === other; + }, + get$hashCode: function(_) { + return H.Primitives_objectHashCode(this); + }, + toString$0: function(_) { + return "Instance of '" + H.S(H.Primitives_objectTypeName(this)) + "'"; + }, + noSuchMethod$1: function(_, invocation) { + type$.Invocation._as(invocation); + throw H.wrapException(P.NoSuchMethodError$(this, invocation.get$memberName(), invocation.get$positionalArguments(), invocation.get$namedArguments())); + }, + get$runtimeType: function(_) { + return H.getRuntimeType(this); + }, + toString: function() { + return this.toString$0(this); + } + }; + P.StackTrace.prototype = {}; + P._StringStackTrace.prototype = { + toString$0: function(_) { + return ""; + }, + $isStackTrace: 1 + }; + P.String.prototype = {$isPattern: 1}; + P.StringBuffer.prototype = { + get$length: function(_) { + return this._contents.length; + }, + toString$0: function(_) { + var t1 = this._contents; + return t1.charCodeAt(0) == 0 ? t1 : t1; + }, + $isStringSink: 1 + }; + P.Symbol0.prototype = {}; + W.DomException.prototype = { + toString$0: function(receiver) { + return String(receiver); + } + }; + W.Event0.prototype = {$isEvent0: 1}; + W.EventSource.prototype = {$isEventSource: 1}; + W.EventTarget.prototype = { + addEventListener$3: function(receiver, type, listener, useCapture) { + type$.nullable_dynamic_Function_Event._as(listener); + if (listener != null) + this._addEventListener$3(receiver, type, listener, useCapture); + }, + addEventListener$2: function($receiver, type, listener) { + return this.addEventListener$3($receiver, type, listener, null); + }, + _addEventListener$3: function(receiver, type, listener, options) { + return receiver.addEventListener(type, H.convertDartClosureToJS(type$.nullable_dynamic_Function_Event._as(listener), 1), options); + }, + _removeEventListener$3: function(receiver, type, listener, options) { + return receiver.removeEventListener(type, H.convertDartClosureToJS(type$.nullable_dynamic_Function_Event._as(listener), 1), false); + }, + $isEventTarget: 1 + }; + W.HttpRequest.prototype = { + open$3$async: function(receiver, method, url, async) { + return receiver.open(method, url, true); + }, + $isHttpRequest: 1 + }; + W.HttpRequest_request_closure.prototype = { + call$1: function(e) { + var t1, t2, accepted, unknownRedirect, t3; + type$.ProgressEvent._as(e); + t1 = this.xhr; + t2 = t1.status; + if (typeof t2 !== "number") + return t2.$ge(); + accepted = t2 >= 200 && t2 < 300; + unknownRedirect = t2 > 307 && t2 < 400; + t2 = accepted || t2 === 0 || t2 === 304 || unknownRedirect; + t3 = this.completer; + if (t2) + t3.complete$1(t1); + else + t3.completeError$1(e); + }, + $signature: 40 + }; + W.HttpRequestEventTarget.prototype = {}; + W.MessageEvent.prototype = {$isMessageEvent: 1}; + W.ProgressEvent.prototype = {$isProgressEvent: 1}; + W.EventStreamProvider.prototype = {}; + W._EventStream.prototype = { + listen$4$cancelOnError$onDone$onError: function(onData, cancelOnError, onDone, onError) { + var t1 = this.$ti; + t1._eval$1("~(1)?")._as(onData); + type$.nullable_void_Function._as(onDone); + return W._EventStreamSubscription$(this._target, this._eventType, onData, false, t1._precomputed1); + }, + listen$3$onDone$onError: function(onData, onDone, onError) { + return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, onError); + } + }; + W._EventStreamSubscription.prototype = { + cancel$0: function() { + var _this = this; + if (_this._target == null) + return null; + _this._unlisten$0(); + _this._target = null; + _this.set$_onData(null); + return null; + }, + onData$1: function(handleData) { + var t1, _this = this; + _this.$ti._eval$1("~(1)?")._as(handleData); + if (_this._target == null) + throw H.wrapException(P.StateError$("Subscription has been canceled.")); + _this._unlisten$0(); + t1 = W._wrapZone(new W._EventStreamSubscription_onData_closure(handleData), type$.Event); + _this.set$_onData(t1); + _this._tryResume$0(); + }, + pause$0: function() { + if (this._target == null) + return; + ++this._pauseCount; + this._unlisten$0(); + }, + resume$0: function() { + var _this = this; + if (_this._target == null || _this._pauseCount <= 0) + return; + --_this._pauseCount; + _this._tryResume$0(); + }, + _tryResume$0: function() { + var t2, _this = this, + t1 = _this._onData; + if (t1 != null && _this._pauseCount <= 0) { + t2 = _this._target; + t2.toString; + J.addEventListener$3$x(t2, _this._eventType, t1, false); + } + }, + _unlisten$0: function() { + var t3, + t1 = this._onData, + t2 = t1 != null; + if (t2) { + t3 = this._target; + t3.toString; + type$.nullable_dynamic_Function_Event._as(t1); + if (t2) + J._removeEventListener$3$x(t3, this._eventType, t1, false); + } + }, + set$_onData: function(_onData) { + this._onData = type$.nullable_dynamic_Function_Event._as(_onData); + } + }; + W._EventStreamSubscription_closure.prototype = { + call$1: function(e) { + return this.onData.call$1(type$.Event._as(e)); + }, + $signature: 17 + }; + W._EventStreamSubscription_onData_closure.prototype = { + call$1: function(e) { + return this.handleData.call$1(type$.Event._as(e)); + }, + $signature: 17 + }; + P._AcceptStructuredClone.prototype = { + findSlot$1: function(value) { + var i, + t1 = this.values, + $length = t1.length; + for (i = 0; i < $length; ++i) + if (t1[i] === value) + return i; + C.JSArray_methods.add$1(t1, value); + C.JSArray_methods.add$1(this.copies, null); + return $length; + }, + walk$1: function(e) { + var millisSinceEpoch, t1, proto, slot, copy, t2, l, $length, i, _this = this, _box_0 = {}; + if (e == null) + return e; + if (H._isBool(e)) + return e; + if (typeof e == "number") + return e; + if (typeof e == "string") + return e; + if (e instanceof Date) { + millisSinceEpoch = e.getTime(); + if (Math.abs(millisSinceEpoch) <= 864e13) + t1 = false; + else + t1 = true; + if (t1) + H.throwExpression(P.ArgumentError$("DateTime is outside valid range: " + millisSinceEpoch)); + P.ArgumentError_checkNotNull(true, "isUtc", type$.bool); + return new P.DateTime(millisSinceEpoch, true); + } + if (e instanceof RegExp) + throw H.wrapException(P.UnimplementedError$("structured clone of RegExp")); + if (typeof Promise != "undefined" && e instanceof Promise) + return P.promiseToFuture(e, type$.dynamic); + proto = Object.getPrototypeOf(e); + if (proto === Object.prototype || proto === null) { + slot = _this.findSlot$1(e); + t1 = _this.copies; + if (slot >= t1.length) + return H.ioore(t1, slot); + copy = _box_0.copy = t1[slot]; + if (copy != null) + return copy; + t2 = type$.dynamic; + copy = P.LinkedHashMap_LinkedHashMap$_empty(t2, t2); + _box_0.copy = copy; + C.JSArray_methods.$indexSet(t1, slot, copy); + _this.forEachJsField$2(e, new P._AcceptStructuredClone_walk_closure(_box_0, _this)); + return _box_0.copy; + } + if (e instanceof Array) { + l = e; + slot = _this.findSlot$1(l); + t1 = _this.copies; + if (slot >= t1.length) + return H.ioore(t1, slot); + copy = t1[slot]; + if (copy != null) + return copy; + t2 = J.getInterceptor$asx(l); + $length = t2.get$length(l); + copy = _this.mustCopy ? new Array($length) : l; + C.JSArray_methods.$indexSet(t1, slot, copy); + for (t1 = J.getInterceptor$ax(copy), i = 0; i < $length; ++i) + t1.$indexSet(copy, i, _this.walk$1(t2.$index(l, i))); + return copy; + } + return e; + }, + convertNativeToDart_AcceptStructuredClone$2$mustCopy: function(object, mustCopy) { + this.mustCopy = true; + return this.walk$1(object); + } + }; + P._AcceptStructuredClone_walk_closure.prototype = { + call$2: function(key, value) { + var t1 = this._box_0.copy, + t2 = this.$this.walk$1(value); + J.$indexSet$ax(t1, key, t2); + return t2; + }, + $signature: 47 + }; + P.convertDartToNative_Dictionary_closure.prototype = { + call$2: function(key, value) { + this.object[key] = value; + }, + $signature: 51 + }; + P._AcceptStructuredCloneDart2Js.prototype = { + forEachJsField$2: function(object, action) { + var t1, t2, _i, key; + type$.dynamic_Function_dynamic_dynamic._as(action); + for (t1 = Object.keys(object), t2 = t1.length, _i = 0; _i < t1.length; t1.length === t2 || (0, H.throwConcurrentModificationError)(t1), ++_i) { + key = t1[_i]; + action.call$2(key, object[key]); + } + } + }; + P.promiseToFuture_closure.prototype = { + call$1: function(r) { + return this.completer.complete$1(this.T._eval$1("0/?")._as(r)); + }, + $signature: 2 + }; + P.promiseToFuture_closure0.prototype = { + call$1: function(e) { + return this.completer.completeError$1(e); + }, + $signature: 2 + }; + P._JSRandom.prototype = { + nextDouble$0: function() { + return Math.random(); + } + }; + P.ByteBuffer.prototype = {}; + P.ByteData.prototype = {}; + P.Int8List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Uint8List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Uint8ClampedList.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Int16List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Uint16List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Int32List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Uint32List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Float32List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + P.Float64List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; + V.ErrorResult.prototype = { + complete$1: function(completer) { + completer.completeError$2(this.error, this.stackTrace); + }, + get$hashCode: function(_) { + return (J.get$hashCode$(this.error) ^ J.get$hashCode$(this.stackTrace) ^ 492929599) >>> 0; + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof V.ErrorResult && J.$eq$(this.error, other.error) && this.stackTrace == other.stackTrace; + }, + $isResult: 1 + }; + E.Result.prototype = {}; + F.ValueResult.prototype = { + complete$1: function(completer) { + this.$ti._eval$1("Completer<1*>*")._as(completer).complete$1(this.value); + }, + get$hashCode: function(_) { + return (J.get$hashCode$(this.value) ^ 842997089) >>> 0; + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof F.ValueResult && J.$eq$(this.value, other.value); + }, + $isResult: 1 + }; + G.StreamQueue.prototype = { + get$next: function() { + var t1 = this.$ti, + t2 = new P._Future($.Zone__current, t1._eval$1("_Future<1*>")); + this._addRequest$1(new G._NextRequest(new P._AsyncCompleter(t2, t1._eval$1("_AsyncCompleter<1*>")), t1._eval$1("_NextRequest<1*>"))); + return t2; + }, + _updateRequests$0: function() { + var t1, t2, t3, t4, _this = this; + for (t1 = _this._requestQueue, t2 = _this._eventQueue; !t1.get$isEmpty(t1);) { + t3 = t1._head; + if (t3 === t1._tail) + H.throwExpression(H.IterableElementError_noElement()); + t4 = t1._collection$_table; + if (t3 >= t4.length) + return H.ioore(t4, t3); + if (t4[t3].update$2(t2, _this._isDone)) { + t3 = t1._head; + if (t3 === t1._tail) + H.throwExpression(H.IterableElementError_noElement()); + ++t1._modificationCount; + t4 = t1._collection$_table; + if (t3 >= t4.length) + return H.ioore(t4, t3); + C.JSArray_methods.$indexSet(t4, t3, null); + t1._head = (t1._head + 1 & t1._collection$_table.length - 1) >>> 0; + } else + return; + } + if (!_this._isDone) + _this._subscription.pause$0(); + }, + _ensureListening$0: function() { + var t1, _this = this; + if (_this._isDone) + return; + t1 = _this._subscription; + if (t1 == null) + _this.set$_subscription(_this._source.listen$3$onDone$onError(new G.StreamQueue__ensureListening_closure(_this), new G.StreamQueue__ensureListening_closure0(_this), new G.StreamQueue__ensureListening_closure1(_this))); + else + t1.resume$0(); + }, + _addResult$1: function(result) { + var t1, _this = this; + _this.$ti._eval$1("Result<1*>*")._as(result); + ++_this._eventsReceived; + t1 = _this._eventQueue; + t1._queue_list$_add$1(t1.$ti._eval$1("1*")._as(result)); + _this._updateRequests$0(); + }, + _addRequest$1: function(request) { + var t1, t2, t3, t4, newTable, split, _this = this; + _this.$ti._eval$1("_EventRequest<1*>*")._as(request); + t1 = _this._requestQueue; + if (t1._head === t1._tail) { + if (request.update$2(_this._eventQueue, _this._isDone)) + return; + _this._ensureListening$0(); + } + t2 = t1.$ti; + t2._precomputed1._as(request); + C.JSArray_methods.$indexSet(t1._collection$_table, t1._tail, request); + t3 = t1._tail; + t4 = t1._collection$_table.length; + t3 = (t3 + 1 & t4 - 1) >>> 0; + t1._tail = t3; + if (t1._head === t3) { + newTable = P.List_List$filled(t4 * 2, null, false, t2._eval$1("1?")); + t2 = t1._collection$_table; + t3 = t1._head; + split = t2.length - t3; + C.JSArray_methods.setRange$4(newTable, 0, split, t2, t3); + C.JSArray_methods.setRange$4(newTable, split, split + t1._head, t1._collection$_table, 0); + t1._head = 0; + t1._tail = t1._collection$_table.length; + t1.set$_collection$_table(newTable); + } + ++t1._modificationCount; + }, + set$_subscription: function(_subscription) { + this._subscription = this.$ti._eval$1("StreamSubscription<1*>*")._as(_subscription); + } + }; + G.StreamQueue__ensureListening_closure.prototype = { + call$1: function(data) { + var t1 = this.$this, + t2 = t1.$ti; + t1._addResult$1(new F.ValueResult(t2._eval$1("1*")._as(data), t2._eval$1("ValueResult<1*>"))); + }, + $signature: function() { + return this.$this.$ti._eval$1("Null(1*)"); + } + }; + G.StreamQueue__ensureListening_closure1.prototype = { + call$2: function(error, stackTrace) { + this.$this._addResult$1(new V.ErrorResult(error, type$.legacy_StackTrace._as(stackTrace))); + }, + "call*": "call$2", + $requiredArgCount: 2, + $signature: 56 + }; + G.StreamQueue__ensureListening_closure0.prototype = { + call$0: function() { + var t1 = this.$this; + t1.set$_subscription(null); + t1._isDone = true; + t1._updateRequests$0(); + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 1 + }; + G._EventRequest.prototype = {}; + G._NextRequest.prototype = { + update$2: function(events, isDone) { + var t1, t2, result; + this.$ti._eval$1("QueueList*>*")._as(events); + if (events.get$length(events) !== 0) { + t1 = events._queue_list$_head; + if (t1 === events._queue_list$_tail) + H.throwExpression(P.StateError$("No element")); + t2 = events._table; + if (t1 >= t2.length) + return H.ioore(t2, t1); + result = t2[t1]; + C.JSArray_methods.$indexSet(t2, t1, null); + events._queue_list$_head = (events._queue_list$_head + 1 & events._table.length - 1) >>> 0; + result.complete$1(this._completer); + return true; + } + if (isDone) { + this._completer.completeError$2(new P.StateError("No elements"), P.StackTrace_current()); + return true; + } + return false; + }, + $is_EventRequest: 1 + }; + Q.QueueList.prototype = { + toString$0: function(_) { + return P.IterableBase_iterableToFullString(this, "{", "}"); + }, + get$length: function(_) { + return (this._queue_list$_tail - this._queue_list$_head & this._table.length - 1) >>> 0; + }, + $index: function(_, index) { + var t1, t2, t3, _this = this; + H._asIntS(index); + if (index < 0 || index >= _this.get$length(_this)) + throw H.wrapException(P.RangeError$("Index " + index + " must be in the range [0.." + _this.get$length(_this) + ").")); + t1 = _this._table; + t2 = t1.length; + t3 = (_this._queue_list$_head + index & t2 - 1) >>> 0; + if (t3 < 0 || t3 >= t2) + return H.ioore(t1, t3); + return t1[t3]; + }, + $indexSet: function(_, index, value) { + var t1, _this = this; + H._asIntS(index); + _this.$ti._eval$1("1*")._as(value); + if (typeof index !== "number") + return index.$lt(); + if (index < 0 || index >= _this.get$length(_this)) + throw H.wrapException(P.RangeError$("Index " + index + " must be in the range [0.." + _this.get$length(_this) + ").")); + t1 = _this._table; + C.JSArray_methods.$indexSet(t1, (_this._queue_list$_head + index & t1.length - 1) >>> 0, value); + }, + _queue_list$_add$1: function(element) { + var t2, t3, newTable, split, _this = this, + t1 = _this.$ti; + t1._eval$1("1*")._as(element); + C.JSArray_methods.$indexSet(_this._table, _this._queue_list$_tail, element); + t2 = _this._queue_list$_tail; + t3 = _this._table.length; + t2 = (t2 + 1 & t3 - 1) >>> 0; + _this._queue_list$_tail = t2; + if (_this._queue_list$_head === t2) { + t2 = new Array(t3 * 2); + t2.fixed$length = Array; + newTable = H.setRuntimeTypeInfo(t2, t1._eval$1("JSArray<1*>")); + t1 = _this._table; + t2 = _this._queue_list$_head; + split = t1.length - t2; + C.JSArray_methods.setRange$4(newTable, 0, split, t1, t2); + C.JSArray_methods.setRange$4(newTable, split, split + _this._queue_list$_head, _this._table, 0); + _this._queue_list$_head = 0; + _this._queue_list$_tail = _this._table.length; + _this.set$_table(newTable); + } + }, + set$_table: function(_table) { + this._table = this.$ti._eval$1("List<1*>*")._as(_table); + }, + $isEfficientLengthIterable: 1, + $isQueue: 1, + $isIterable: 1, + $isList: 1 + }; + Q._QueueList_Object_ListMixin.prototype = {}; + N.HexCodec.prototype = { + get$encoder: function() { + return C.C_HexEncoder; + } + }; + R.HexEncoder.prototype = { + convert$1: function(bytes) { + type$.legacy_List_legacy_int._as(bytes); + return R._convert(bytes, 0, bytes.length); + } + }; + Y.Level.prototype = { + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Y.Level && this.value === other.value; + }, + $gt: function(_, other) { + return C.JSInt_methods.$gt(this.value, type$.legacy_Level._as(other).get$value()); + }, + $ge: function(_, other) { + return this.value >= type$.legacy_Level._as(other).value; + }, + get$hashCode: function(_) { + return this.value; + }, + toString$0: function(_) { + return this.name; + } + }; + L.LogRecord0.prototype = { + toString$0: function(_) { + return "[" + this.level.name + "] " + this.loggerName + ": " + H.S(this.message); + } + }; + F.Logger.prototype = { + get$fullName: function() { + var t1 = this.parent, + t2 = t1 == null || t1.name === "", + t3 = this.name; + return t2 ? t3 : t1.get$fullName() + "." + t3; + }, + get$level: function() { + var effectiveLevel, t1; + if (this.parent == null) + effectiveLevel = this._level; + else { + t1 = $.$get$Logger_root(); + effectiveLevel = t1._level; + } + return effectiveLevel; + }, + log$4: function(logLevel, message, error, stackTrace) { + var record, _this = this, + t1 = logLevel.value; + if (t1 >= _this.get$level().value) { + if (t1 >= 2000) { + P.StackTrace_current(); + logLevel.toString$0(0); + } + t1 = _this.get$fullName(); + Date.now(); + $.LogRecord__nextNumber = $.LogRecord__nextNumber + 1; + record = new L.LogRecord0(logLevel, message, t1); + if (_this.parent == null) + _this._publish$1(record); + else + $.$get$Logger_root()._publish$1(record); + } + }, + _publish$1: function(record) { + } + }; + F.Logger_Logger_closure.prototype = { + call$0: function() { + var dot, $parent, t1, + thisName = this.name; + if (C.JSString_methods.startsWith$1(thisName, ".")) + H.throwExpression(P.ArgumentError$("name shouldn't start with a '.'")); + dot = C.JSString_methods.lastIndexOf$1(thisName, "."); + if (dot === -1) + $parent = thisName !== "" ? F.Logger_Logger("") : null; + else { + $parent = F.Logger_Logger(C.JSString_methods.substring$2(thisName, 0, dot)); + thisName = C.JSString_methods.substring$1(thisName, dot + 1); + } + t1 = new F.Logger(thisName, $parent, P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.legacy_Logger)); + if ($parent == null) + t1._level = C.Level_INFO_800; + else + $parent._children.$indexSet(0, thisName, t1); + return t1; + }, + $signature: 60 + }; + M.SseClient.prototype = { + SseClient$1: function(serverUrl) { + var t1, t2, t3, t4, _this = this, + clientId = K.Uuid$().v1$0(); + _this._eventSource = W.EventSource__factoryEventSource(H.S(serverUrl) + "?sseClientId=" + clientId, P.LinkedHashMap_LinkedHashMap$_literal(["withCredentials", true], type$.String, type$.dynamic)); + _this._serverUrl = H.S(serverUrl) + "?sseClientId=" + clientId; + t1 = _this._outgoingController; + new P._ControllerStream(t1, H._instanceType(t1)._eval$1("_ControllerStream<1>")).listen$2$onDone(_this.get$_onOutgoingMessage(), _this.get$_onOutgoingDone()); + C.EventSource_methods.addEventListener$2(_this._eventSource, "message", _this.get$_onIncomingMessage()); + C.EventSource_methods.addEventListener$2(_this._eventSource, "control", _this.get$_onIncomingControlMessage()); + t1 = _this._eventSource; + t2 = type$.nullable_void_Function_legacy_Event; + t3 = t2._as(new M.SseClient_closure(_this)); + type$.nullable_void_Function._as(null); + t4 = type$.legacy_Event_2; + W._EventStreamSubscription$(t1, "open", t3, false, t4); + W._EventStreamSubscription$(_this._eventSource, "error", t2._as(new M.SseClient_closure0(_this)), false, t4); + _this._startPostingMessages$0(); + }, + close$0: function(_) { + this._eventSource.close(); + this._incomingController.close$0(0); + this._outgoingController.close$0(0); + }, + _onIncomingControlMessage$1: function(message) { + var data = new P._AcceptStructuredCloneDart2Js([], []).convertNativeToDart_AcceptStructuredClone$2$mustCopy(type$.legacy_MessageEvent._as(type$.legacy_Event_2._as(message)).data, true); + if (J.$eq$(data, "close")) + this.close$0(0); + else + throw H.wrapException(P.UnsupportedError$('Illegal Control Message "' + H.S(data) + '"')); + }, + _onIncomingMessage$1: function(message) { + this._incomingController.add$1(0, H._asStringS(C.C_JsonCodec.decode$2$reviver(H._asStringS(new P._AcceptStructuredCloneDart2Js([], []).convertNativeToDart_AcceptStructuredClone$2$mustCopy(type$.legacy_MessageEvent._as(type$.legacy_Event_2._as(message)).data, true)), null))); + }, + _onOutgoingDone$0: function() { + this.close$0(0); + }, + _onOutgoingMessage$1: function(message) { + var $async$goto = 0, + $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic), + $async$self = this; + var $async$_onOutgoingMessage$1 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { + if ($async$errorCode === 1) + return P._asyncRethrow($async$result, $async$completer); + while (true) + switch ($async$goto) { + case 0: + // Function start + $async$self._messages.add$1(0, message); + // implicit return + return P._asyncReturn(null, $async$completer); + } + }); + return P._asyncStartSync($async$_onOutgoingMessage$1, $async$completer); + }, + _startPostingMessages$0: function() { + var $async$goto = 0, + $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic), + $async$handler = 1, $async$currentError, $async$next = [], $async$self = this, message, e, e0, t2, exception, t3, t1, $async$exception, $async$temp1; + var $async$_startPostingMessages$0 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { + if ($async$errorCode === 1) { + $async$currentError = $async$result; + $async$goto = $async$handler; + } + while (true) + switch ($async$goto) { + case 0: + // Function start + t1 = $async$self._messages; + t1 = new P._ControllerStream(t1, H._instanceType(t1)._eval$1("_ControllerStream<1>")); + t2 = new P._StreamIterator(t1, type$._StreamIterator_dynamic); + P.ArgumentError_checkNotNull(t1, "stream", type$.Stream_dynamic); + $async$handler = 2; + t1 = $async$self._logger; + case 5: + // for condition + $async$temp1 = H; + $async$goto = 7; + return P._asyncAwait(t2.moveNext$0(), $async$_startPostingMessages$0); + case 7: + // returning from await. + if (!$async$temp1.boolConversionCheck($async$result)) { + // goto after for + $async$goto = 6; + break; + } + message = t2.get$current(); + $async$handler = 9; + $async$goto = 12; + return P._asyncAwait(W.HttpRequest_request($async$self._serverUrl, "POST", C.C_JsonCodec.encode$2$toEncodable(message, null), true), $async$_startPostingMessages$0); + case 12: + // returning from await. + $async$handler = 2; + // goto after finally + $async$goto = 11; + break; + case 9: + // catch + $async$handler = 8; + $async$exception = $async$currentError; + t3 = H.unwrapException($async$exception); + if (t3 instanceof P.JsonUnsupportedObjectError) { + e = t3; + t1.log$4(C.Level_WARNING_900, "Unable to encode outgoing message: " + H.S(e), null, null); + } else if (t3 instanceof P.ArgumentError) { + e0 = t3; + t1.log$4(C.Level_WARNING_900, "Invalid argument: " + H.S(e0), null, null); + } else + throw $async$exception; + // goto after finally + $async$goto = 11; + break; + case 8: + // uncaught + // goto uncaught + $async$goto = 2; + break; + case 11: + // after finally + // goto for condition + $async$goto = 5; + break; + case 6: + // after for + $async$next.push(4); + // goto finally + $async$goto = 3; + break; + case 2: + // uncaught + $async$next = [1]; + case 3: + // finally + $async$handler = 1; + $async$goto = 13; + return P._asyncAwait(t2.cancel$0(), $async$_startPostingMessages$0); + case 13: + // returning from await. + // goto the next finally handler + $async$goto = $async$next.pop(); + break; + case 4: + // after finally + // implicit return + return P._asyncReturn(null, $async$completer); + case 1: + // rethrow + return P._asyncRethrow($async$currentError, $async$completer); + } + }); + return P._asyncStartSync($async$_startPostingMessages$0, $async$completer); + } + }; + M.SseClient_closure.prototype = { + call$1: function(_) { + var t1 = this.$this._errorTimer; + if (t1 != null) + t1.cancel$0(); + }, + $signature: 19 + }; + M.SseClient_closure0.prototype = { + call$1: function(error) { + var t1 = this.$this, + t2 = t1._errorTimer; + t2 = t2 == null ? null : t2._handle != null; + if (t2 !== true) + t1._errorTimer = P.Timer_Timer(C.Duration_5000000, new M.SseClient__closure(t1, error)); + }, + $signature: 19 + }; + M.SseClient__closure.prototype = { + call$0: function() { + var stackTrace, t3, + t1 = this.$this, + t2 = t1._incomingController, + error = this.error; + P.ArgumentError_checkNotNull(error, "error", type$.Object); + if (t2._state >= 4) + H.throwExpression(t2._badEventState$0()); + stackTrace = P.AsyncError_defaultStackTrace(error); + t3 = t2._state; + if ((t3 & 1) !== 0) + t2._sendError$2(error, stackTrace); + else if ((t3 & 3) === 0) + t2._ensurePendingEvents$0().add$1(0, new P._DelayedError(error, stackTrace)); + t1.close$0(0); + }, + $signature: 1 + }; + R.StreamChannelMixin.prototype = {}; + K.Uuid.prototype = { + Uuid$1$options: function(_box_0) { + var t1, t2, i, hex, t3, v1PositionalArgs, v1NamedArgs, _this = this, + _s19_ = "v1rngPositionalArgs", + _s14_ = "v1rngNamedArgs", + _s18_ = "grngPositionalArgs", + _s13_ = "grngNamedArgs", + options = _box_0.options; + if (!(options != null)) + options = new H.JsLinkedHashMap(type$.JsLinkedHashMap_of_legacy_String_and_dynamic); + _box_0.options = options; + t1 = new Array(256); + t1.fixed$length = Array; + _this.set$_byteToHex(H.setRuntimeTypeInfo(t1, type$.JSArray_legacy_String)); + _this.set$_hexToByte(new H.JsLinkedHashMap(type$.JsLinkedHashMap_of_legacy_String_and_legacy_int)); + for (t1 = type$.JSArray_legacy_int, t2 = type$.HexCodec._eval$1("Codec.S"), i = 0; i < 256; ++i) { + hex = H.setRuntimeTypeInfo([], t1); + C.JSArray_methods.add$1(hex, i); + t3 = _this._byteToHex; + t2._as(hex); + (t3 && C.JSArray_methods).$indexSet(t3, i, C.C_HexCodec.get$encoder().convert$1(hex)); + _this._hexToByte.$indexSet(0, _this._byteToHex[i], i); + } + v1PositionalArgs = _box_0.options.$index(0, _s19_) != null ? _box_0.options.$index(0, _s19_) : []; + v1NamedArgs = _box_0.options.$index(0, _s14_) != null ? type$.legacy_Map_of_legacy_Symbol_and_dynamic._as(_box_0.options.$index(0, _s14_)) : C.Map_empty0; + _this._seedBytes = _box_0.options.$index(0, "v1rng") != null ? P.Function_apply(type$.Function._as(_box_0.options.$index(0, "v1rng")), type$.nullable_List_dynamic._as(v1PositionalArgs), v1NamedArgs) : T.UuidUtil_mathRNG(); + if (_box_0.options.$index(0, _s18_) != null) + _box_0.options.$index(0, _s18_); + if (_box_0.options.$index(0, _s13_) != null) + type$.legacy_Map_of_legacy_Symbol_and_dynamic._as(_box_0.options.$index(0, _s13_)); + _this._nodeId = [J.$or$bn(J.$index$asx(_this._seedBytes, 0), 1), J.$index$asx(_this._seedBytes, 1), J.$index$asx(_this._seedBytes, 2), J.$index$asx(_this._seedBytes, 3), J.$index$asx(_this._seedBytes, 4), J.$index$asx(_this._seedBytes, 5)]; + t1 = J.$shl$n(J.$index$asx(_this._seedBytes, 6), 8); + t2 = J.$index$asx(_this._seedBytes, 7); + if (typeof t2 !== "number") + return H.iae(t2); + _this._clockSeq = (t1 | t2) & 262143; + }, + v1$0: function() { + var t1, buf, options, clockSeq, mSecs, nSecs, dt, t2, tl, tmh, node, n, _this = this, + _s8_ = "clockSeq", + _s5_ = "nSecs"; + type$.legacy_Map_of_legacy_String_and_dynamic._as(null); + t1 = new Array(16); + t1.fixed$length = Array; + buf = H.setRuntimeTypeInfo(t1, type$.JSArray_legacy_int); + options = new H.JsLinkedHashMap(type$.JsLinkedHashMap_of_legacy_String_and_dynamic); + clockSeq = options.$index(0, _s8_) != null ? options.$index(0, _s8_) : _this._clockSeq; + mSecs = options.$index(0, "mSecs") != null ? options.$index(0, "mSecs") : Date.now(); + nSecs = options.$index(0, _s5_) != null ? options.$index(0, _s5_) : _this._lastNSecs + 1; + t1 = J.getInterceptor$n(mSecs); + dt = J.$add$ansx(t1.$sub(mSecs, _this._lastMSecs), J.$div$n(J.$sub$n(nSecs, _this._lastNSecs), 10000)); + t2 = J.getInterceptor$n(dt); + if (t2.$lt(dt, 0) && options.$index(0, _s8_) == null) + clockSeq = J.$and$bn(J.$add$ansx(clockSeq, 1), 16383); + if ((t2.$lt(dt, 0) || t1.$gt(mSecs, _this._lastMSecs)) && options.$index(0, _s5_) == null) + nSecs = 0; + if (J.$ge$n(nSecs, 10000)) + throw H.wrapException(P.Exception_Exception("uuid.v1(): Can't create more than 10M uuids/sec")); + H._asIntS(mSecs); + _this._lastMSecs = mSecs; + H._asIntS(nSecs); + _this._lastNSecs = nSecs; + _this._clockSeq = clockSeq; + mSecs += 122192928e5; + tl = C.JSInt_methods.$mod((mSecs & 268435455) * 10000 + nSecs, 4294967296); + C.JSArray_methods.$indexSet(buf, 0, C.JSInt_methods._shrOtherPositive$1(tl, 24) & 255); + C.JSArray_methods.$indexSet(buf, 1, C.JSInt_methods._shrOtherPositive$1(tl, 16) & 255); + C.JSArray_methods.$indexSet(buf, 2, C.JSInt_methods._shrOtherPositive$1(tl, 8) & 255); + C.JSArray_methods.$indexSet(buf, 3, tl & 255); + tmh = C.JSDouble_methods.floor$0(mSecs / 4294967296 * 10000) & 268435455; + C.JSArray_methods.$indexSet(buf, 4, tmh >>> 8 & 255); + C.JSArray_methods.$indexSet(buf, 5, tmh & 255); + C.JSArray_methods.$indexSet(buf, 6, tmh >>> 24 & 15 | 16); + C.JSArray_methods.$indexSet(buf, 7, tmh >>> 16 & 255); + t1 = J.getInterceptor$n(clockSeq); + C.JSArray_methods.$indexSet(buf, 8, (t1.$shr(clockSeq, 8) | 128) >>> 0); + C.JSArray_methods.$indexSet(buf, 9, H._asIntS(t1.$and(clockSeq, 255))); + node = options.$index(0, "node") != null ? options.$index(0, "node") : _this._nodeId; + for (t1 = J.getInterceptor$asx(node), n = 0; n < 6; ++n) + C.JSArray_methods.$indexSet(buf, 10 + n, H._asIntS(t1.$index(node, n))); + type$.legacy_List_legacy_int._as(buf); + t1 = _this._byteToHex; + t1 = H.S((t1 && C.JSArray_methods).$index(t1, buf[0])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[1])); + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[2])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[3])) + "-"; + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[4])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[5])) + "-"; + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[6])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[7])) + "-"; + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[8])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[9])) + "-"; + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[10])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[11])); + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[12])); + t2 = _this._byteToHex; + t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[13])); + t1 = _this._byteToHex; + t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[14])); + t2 = _this._byteToHex; + return t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[15])); + }, + set$_byteToHex: function(_byteToHex) { + this._byteToHex = type$.legacy_List_legacy_String._as(_byteToHex); + }, + set$_hexToByte: function(_hexToByte) { + this._hexToByte = type$.legacy_Map_of_legacy_String_and_legacy_int._as(_hexToByte); + } + }; + Q.createServiceObject_closure.prototype = { + call$1: function(e) { + return Q.createServiceObject(e, this.expectedTypes); + }, + $signature: 29 + }; + Q._createSpecificObject_closure.prototype = { + call$1: function(e) { + return this.creator.call$1(type$.legacy_Map_of_legacy_String_and_dynamic._as(e)); + }, + $signature: 3 + }; + Q.VmService.prototype = { + _getEventController$1: function(eventName) { + var t1 = this._eventControllers, + controller = t1.$index(0, eventName); + if (controller == null) { + controller = P.StreamController_StreamController$broadcast(false, type$.legacy_Event); + t1.$indexSet(0, eventName, controller); + } + return controller; + }, + VmService$5$disposeHandler$log$streamClosed: function(inStream, writeMessage, disposeHandler, log, streamClosed) { + var _this = this; + inStream.listen$2$onDone(_this.get$_processMessage(), new Q.VmService_closure(_this)); + _this._writeMessage = writeMessage; + _this._log = new Q._NullLog(); + _this.set$_disposeHandler(disposeHandler); + }, + _processMessage$1: function(message) { + var t1, _this = this; + if (typeof message == "string") + _this._processMessageStr$1(message); + else if (type$.legacy_List_legacy_int._is(message)) + _this._processMessageByteData$1(H.NativeByteData_NativeByteData$view(new Uint8Array(H._ensureNativeList(message)).buffer, 0, null)); + else if (type$.legacy_ByteData._is(message)) + _this._processMessageByteData$1(message); + else { + t1 = _this._log; + J.get$runtimeType$(message).toString$0(0); + t1.toString; + } + }, + _processMessageByteData$1: function(bytes) { + var t2, t3, meta, data, map, streamId, $event, + dataOffset = C.NativeByteData_methods._getUint32$2(bytes, 0, true), + metaLength = dataOffset - 4, + t1 = bytes.byteLength; + if (typeof t1 !== "number") + return t1.$sub(); + t2 = bytes.buffer; + t3 = bytes.byteOffset; + if (typeof t3 !== "number") + return t3.$add(); + t3 += 4; + H._checkViewArguments(t2, t3, metaLength); + t2 = new Uint8Array(t2, t3, metaLength); + type$.List_int._as(t2); + meta = C.Utf8Decoder_false.convert$1(t2); + t2 = bytes.buffer; + t3 = bytes.byteOffset; + if (typeof t3 !== "number") + return t3.$add(); + data = H.NativeByteData_NativeByteData$view(t2, t3 + dataOffset, t1 - dataOffset); + map = C.C_JsonCodec.decode$2$reviver(meta, null); + if (map != null && J.$eq$(J.$index$asx(map, "method"), "streamNotify")) { + t1 = J.getInterceptor$asx(map); + streamId = H._asStringS(J.$index$asx(t1.$index(map, "params"), "streamId")); + $event = type$.legacy_Map_dynamic_dynamic._as(J.$index$asx(t1.$index(map, "params"), "event")); + $event.$indexSet(0, "data", data); + this._getEventController$1(streamId).add$1(0, type$.legacy_Event._as(Q.createServiceObject($event, C.List_Event))); + } + }, + _processMessageStr$1: function(message) { + var e, s, exception, t1, t2, completer, methodName, returnTypes, result, type, _this = this, _s2_ = "id", _s5_ = "error", json = null; + try { + _this._onReceive.add$1(0, message); + json = C.C_JsonCodec.decode$2$reviver(message, null); + } catch (exception) { + e = H.unwrapException(exception); + s = H.getTraceFromException(exception); + t1 = _this._log; + H.S(e); + H.S(s); + t1.toString; + return; + } + if (json.containsKey$1("method")) { + t1 = type$.legacy_Map_of_legacy_String_and_dynamic; + if (json.containsKey$1(_s2_)) + _this._processRequest$1(t1._as(json)); + else + _this._processNotification$1(t1._as(json)); + } else { + if (json.containsKey$1(_s2_)) + t1 = json.containsKey$1("result") || json.containsKey$1(_s5_); + else + t1 = false; + if (t1) { + t1 = type$.legacy_Map_of_legacy_String_and_dynamic; + t2 = t1._as(json); + completer = _this._completers.remove$1(0, t2.$index(0, _s2_)); + methodName = _this._methodCalls.remove$1(0, t2.$index(0, _s2_)); + returnTypes = $._methodReturnTypes.$index(0, methodName); + if (completer == null) { + t1 = _this._log; + C.C_JsonCodec.encode$2$toEncodable(t2, null); + t1.toString; + } else if (t2.$index(0, _s5_) != null) { + t1 = t2.$index(0, _s5_); + t2 = J.getInterceptor$asx(t1); + completer.completeError$1(new Q.RPCError(methodName, H._asIntS(t2.$index(t1, "code")), H._asStringS(t2.$index(t1, "message")), type$.legacy_Map_dynamic_dynamic._as(t2.$index(t1, "data")))); + } else { + result = t1._as(t2.$index(0, "result")); + type = H._asStringS(result.$index(0, "type")); + if (type === "Sentinel") { + t1 = Q.Sentinel$_fromJson(result); + completer.completeError$1(new Q.SentinelException(methodName, t1)); + } else if ($._typeFactories.$index(0, type) == null) { + t1 = Q.Response$_fromJson(result); + completer.complete$1(t1); + } else + completer.complete$1(Q.createServiceObject(result, returnTypes)); + } + } else + _this._log.toString; + } + }, + _processRequest$1: function(json) { + return this._processRequest$body$VmService(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + }, + _processRequest$body$VmService: function(json) { + var $async$goto = 0, + $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic), + $async$self = this, m, message, t1, t2; + var $async$_processRequest$1 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { + if ($async$errorCode === 1) + return P._asyncRethrow($async$result, $async$completer); + while (true) + switch ($async$goto) { + case 0: + // Function start + t1 = H._asStringS(json.$index(0, "method")); + t2 = json.$index(0, "params"); + if (t2 == null) + t2 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic); + $async$goto = 2; + return P._asyncAwait($async$self._routeRequest$2(t1, type$.legacy_Map_of_legacy_String_and_dynamic._as(t2)), $async$_processRequest$1); + case 2: + // returning from await. + m = $async$result; + m.$indexSet(0, "id", json.$index(0, "id")); + m.$indexSet(0, "jsonrpc", "2.0"); + message = C.C_JsonCodec.encode$2$toEncodable(m, null); + $async$self._onSend.add$1(0, message); + $async$self._writeMessage.call$1(message); + // implicit return + return P._asyncReturn(null, $async$completer); + } + }); + return P._asyncStartSync($async$_processRequest$1, $async$completer); + }, + _processNotification$1: function(json) { + return this._processNotification$body$VmService(type$.legacy_Map_of_legacy_String_and_dynamic._as(json)); + }, + _processNotification$body$VmService: function(json) { + var $async$goto = 0, + $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic), + $async$self = this, method, t1; + var $async$_processNotification$1 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { + if ($async$errorCode === 1) + return P._asyncRethrow($async$result, $async$completer); + while (true) + switch ($async$goto) { + case 0: + // Function start + method = H._asStringS(json.$index(0, "method")); + t1 = json.$index(0, "params"); + if (t1 == null) + t1 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic); + type$.legacy_Map_dynamic_dynamic._as(t1); + $async$goto = method === "streamNotify" ? 2 : 4; + break; + case 2: + // then + $async$self._getEventController$1(H._asStringS(t1.$index(0, "streamId"))).add$1(0, type$.legacy_Event._as(Q.createServiceObject(t1.$index(0, "event"), C.List_Event))); + // goto join + $async$goto = 3; + break; + case 4: + // else + $async$goto = 5; + return P._asyncAwait($async$self._routeRequest$2(method, type$.legacy_Map_of_legacy_String_and_dynamic._as(t1)), $async$_processNotification$1); + case 5: + // returning from await. + case 3: + // join + // implicit return + return P._asyncReturn(null, $async$completer); + } + }); + return P._asyncStartSync($async$_processNotification$1, $async$completer); + }, + _routeRequest$2: function(method, params) { + type$.legacy_Map_of_legacy_String_and_dynamic._as(params); + return this._routeRequest$body$VmService(method, params); + }, + _routeRequest$body$VmService: function(method, params) { + var $async$goto = 0, + $async$completer = P._makeAsyncAwaitCompleter(type$.legacy_Map_dynamic_dynamic), + $async$returnValue, $async$handler = 2, $async$currentError, $async$next = [], $async$self = this, e, st, error, exception, t2, t3, t4, t1, $async$exception; + var $async$_routeRequest$2 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { + if ($async$errorCode === 1) { + $async$currentError = $async$result; + $async$goto = $async$handler; + } + while (true) + switch ($async$goto) { + case 0: + // Function start + t1 = $async$self._services; + if (!t1.containsKey$1(method)) { + t1 = type$.dynamic; + $async$returnValue = P.LinkedHashMap_LinkedHashMap$_literal(["error", new Q.RPCError(method, -32601, "method not found '" + H.S(method) + "'", null).toMap$0()], t1, t1); + // goto return + $async$goto = 1; + break; + } + $async$handler = 4; + $async$goto = 7; + return P._asyncAwait(t1.$index(0, method).call$1(params), $async$_routeRequest$2); + case 7: + // returning from await. + t1 = $async$result; + $async$returnValue = t1; + // goto return + $async$goto = 1; + break; + $async$handler = 2; + // goto after finally + $async$goto = 6; + break; + case 4: + // catch + $async$handler = 3; + $async$exception = $async$currentError; + e = H.unwrapException($async$exception); + st = H.getTraceFromException($async$exception); + t1 = H.S(e); + t2 = H.S(st); + t3 = type$.dynamic; + t4 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, t3); + t4.$indexSet(0, "details", t2); + error = new Q.RPCError(method, -32000, t1, t4); + $async$returnValue = P.LinkedHashMap_LinkedHashMap$_literal(["error", error.toMap$0()], t3, t3); + // goto return + $async$goto = 1; + break; + // goto after finally + $async$goto = 6; + break; + case 3: + // uncaught + // goto rethrow + $async$goto = 2; + break; + case 6: + // after finally + case 1: + // return + return P._asyncReturn($async$returnValue, $async$completer); + case 2: + // rethrow + return P._asyncRethrow($async$currentError, $async$completer); + } + }); + return P._asyncStartSync($async$_routeRequest$2, $async$completer); + }, + set$_disposeHandler: function(_disposeHandler) { + type$.legacy_legacy_Future_dynamic_Function._as(_disposeHandler); + } + }; + Q.VmService_closure.prototype = { + call$0: function() { + return this.$this._onDoneCompleter.complete$0(); + }, + "call*": "call$0", + $requiredArgCount: 0, + $signature: 0 + }; + Q.RPCError.prototype = { + get$details: function() { + var t1 = this.data; + return H._asStringS(t1 == null ? null : t1.$index(0, "details")); + }, + toMap$0: function() { + var map = P.LinkedHashMap_LinkedHashMap$_literal(["code", this.code, "message", this.message], type$.legacy_String, type$.dynamic), + t1 = this.data; + if (t1 != null) + map.$indexSet(0, "data", t1); + return map; + }, + toString$0: function(_) { + var _this = this, + t1 = _this.callingMethod, + t2 = _this.code, + t3 = _this.message; + if (_this.get$details() == null) + return H.S(t1) + ": (" + H.S(t2) + ") " + H.S(t3); + else + return H.S(t1) + ": (" + H.S(t2) + ") " + H.S(t3) + "\n" + H.S(_this.get$details()); + } + }; + Q.SentinelException.prototype = { + toString$0: function(_) { + return H.S(this.sentinel) + " from " + H.S(this.callingMethod) + "()"; + } + }; + Q.ExtensionData.prototype = { + toString$0: function(_) { + return "[ExtensionData " + this.data.toString$0(0) + "]"; + } + }; + Q._NullLog.prototype = {$isLog: 1}; + Q.AllocationProfile.prototype = { + toJson$0: function() { + var t3, t4, t5, _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "AllocationProfile"); + t3 = _this.members; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["members", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.AllocationProfile_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")), "memoryUsage", _this.memoryUsage.toJson$0()], t1, t2)); + Q._setIfNotNull(json, "dateLastAccumulatorReset", _this.dateLastAccumulatorReset); + Q._setIfNotNull(json, "dateLastServiceGC", _this.dateLastServiceGC); + return json; + }, + toString$0: function(_) { + return "[AllocationProfile type: " + H.S(this.type) + ", members: " + H.S(this.members) + ", memoryUsage: " + H.S(this.memoryUsage) + "]"; + }, + set$members: function(members) { + this.members = type$.legacy_List_legacy_ClassHeapStats._as(members); + } + }; + Q.AllocationProfile_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_ClassHeapStats._as(f).toJson$0(); + }, + $signature: 30 + }; + Q.BoundField.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["decl", this.decl.toJson$0(), "value", this.value.toJson$0()], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[BoundField decl: " + H.S(this.decl) + ", value: " + H.S(this.value) + "]"; + } + }; + Q.BoundVariable.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "BoundVariable"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "value", _this.value.toJson$0(), "declarationTokenPos", _this.declarationTokenPos, "scopeStartTokenPos", _this.scopeStartTokenPos, "scopeEndTokenPos", _this.scopeEndTokenPos], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[BoundVariable type: " + H.S(_this.type) + ", name: " + H.S(_this.name) + ", value: " + H.S(_this.value) + ", declarationTokenPos: " + H.S(_this.declarationTokenPos) + ", scopeStartTokenPos: " + H.S(_this.scopeStartTokenPos) + ", scopeEndTokenPos: " + H.S(_this.scopeEndTokenPos) + "]"; + } + }; + Q.Breakpoint.prototype = { + toJson$0: function() { + var _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Breakpoint"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["breakpointNumber", _this.breakpointNumber, "resolved", _this.resolved, "location", _this.location.toJson$0()], type$.legacy_String, type$.dynamic)); + Q._setIfNotNull(json, "isSyntheticAsyncContinuation", _this.isSyntheticAsyncContinuation); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Breakpoint && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Breakpoint type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", breakpointNumber: " + H.S(_this.breakpointNumber) + ", resolved: " + H.S(_this.resolved) + ", location: " + H.S(_this.location) + "]"; + } + }; + Q.ClassRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Class"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_ClassRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + return "[ClassRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", name: " + H.S(this.name) + "]"; + } + }; + Q.Class.prototype = { + toJson$0: function() { + var t1, t2, t3, t4, t5, t6, t7, t8, t9, t10, _this = this, _null = null, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Class"); + t1 = _this.name; + t2 = _this.isAbstract; + t3 = _this.isConst; + t4 = _this.library.toJson$0(); + t5 = _this.interfaces; + t5.toString; + t6 = H._arrayInstanceType(t5); + t7 = t6._eval$1("MappedListIterable<1,Map*>"); + t7 = P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("Map*(1)")._as(new Q.Class_toJson_closure()), t7), true, t7._eval$1("ListIterable.E")); + t6 = _this.fields; + t6.toString; + t5 = H._arrayInstanceType(t6); + t8 = t5._eval$1("MappedListIterable<1,Map*>"); + t8 = P.List_List$from(new H.MappedListIterable(t6, t5._eval$1("Map*(1)")._as(new Q.Class_toJson_closure0()), t8), true, t8._eval$1("ListIterable.E")); + t5 = _this.functions; + t5.toString; + t6 = H._arrayInstanceType(t5); + t9 = t6._eval$1("MappedListIterable<1,Map*>"); + t9 = P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("Map*(1)")._as(new Q.Class_toJson_closure1()), t9), true, t9._eval$1("ListIterable.E")); + t6 = _this.subclasses; + t6.toString; + t5 = H._arrayInstanceType(t6); + t10 = t5._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t1, "abstract", t2, "const", t3, "library", t4, "interfaces", t7, "fields", t8, "functions", t9, "subclasses", P.List_List$from(new H.MappedListIterable(t6, t5._eval$1("Map*(1)")._as(new Q.Class_toJson_closure2()), t10), true, t10._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic)); + t10 = _this.error; + Q._setIfNotNull(json, "error", t10 == null ? _null : t10.toJson$0()); + t1 = _this.location; + Q._setIfNotNull(json, "location", t1 == null ? _null : t1.toJson$0()); + t1 = _this.superClass; + Q._setIfNotNull(json, "super", t1 == null ? _null : t1.toJson$0()); + t1 = _this.superType; + Q._setIfNotNull(json, "superType", t1 == null ? _null : t1.toJson$0()); + t1 = _this.mixin; + Q._setIfNotNull(json, "mixin", t1 == null ? _null : t1.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Class && this.id == other.id; + }, + toString$0: function(_) { + return "[Class]"; + }, + set$interfaces: function(interfaces) { + this.interfaces = type$.legacy_List_legacy_InstanceRef._as(interfaces); + }, + set$fields: function(fields) { + this.fields = type$.legacy_List_legacy_FieldRef._as(fields); + }, + set$functions: function(functions) { + this.functions = type$.legacy_List_legacy_FuncRef._as(functions); + }, + set$subclasses: function(subclasses) { + this.subclasses = type$.legacy_List_legacy_ClassRef._as(subclasses); + }, + $isClassRef: 1 + }; + Q.Class_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_InstanceRef._as(f).toJson$0(); + }, + $signature: 20 + }; + Q.Class_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_FieldRef._as(f).toJson$0(); + }, + $signature: 21 + }; + Q.Class_toJson_closure1.prototype = { + call$1: function(f) { + return type$.legacy_FuncRef._as(f).toJson$0(); + }, + $signature: 22 + }; + Q.Class_toJson_closure2.prototype = { + call$1: function(f) { + return type$.legacy_ClassRef._as(f).toJson$0(); + }, + $signature: 8 + }; + Q.ClassHeapStats.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "ClassHeapStats"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["class", _this.classRef.toJson$0(), "accumulatedSize", _this.accumulatedSize, "bytesCurrent", _this.bytesCurrent, "instancesAccumulated", _this.instancesAccumulated, "instancesCurrent", _this.instancesCurrent], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[ClassHeapStats type: " + H.S(_this.type) + ", classRef: " + H.S(_this.classRef) + ", accumulatedSize: " + H.S(_this.accumulatedSize) + ", bytesCurrent: " + H.S(_this.bytesCurrent) + ", instancesAccumulated: " + H.S(_this.instancesAccumulated) + ", instancesCurrent: " + H.S(_this.instancesCurrent) + "]"; + } + }; + Q.ClassList.prototype = { + toJson$0: function() { + var t3, t4, t5, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "ClassList"); + t3 = this.classes; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["classes", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.ClassList_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[ClassList type: " + H.S(this.type) + ", classes: " + H.S(this.classes) + "]"; + }, + set$classes: function(classes) { + this.classes = type$.legacy_List_legacy_ClassRef._as(classes); + } + }; + Q.ClassList_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_ClassRef._as(f).toJson$0(); + }, + $signature: 8 + }; + Q.ClientName.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "ClientName"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[ClientName type: " + H.S(this.type) + ", name: " + H.S(this.name) + "]"; + } + }; + Q.CodeRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Code"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name, "kind", this.kind], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_CodeRef._is(other) && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[CodeRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", kind: " + H.S(_this.kind) + "]"; + } + }; + Q.Code.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "Code"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name, "kind", this.kind], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Code && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Code type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", kind: " + H.S(_this.kind) + "]"; + }, + $isCodeRef: 1 + }; + Q.ContextRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Context"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["length", this.length], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_ContextRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + return "[ContextRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", length: " + H.S(this.length) + "]"; + }, + get$length: function(receiver) { + return this.length; + } + }; + Q.Context.prototype = { + toJson$0: function() { + var t1, t2, t3, t4, _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Context"); + t1 = _this.length; + t2 = _this.variables; + t2.toString; + t3 = H._arrayInstanceType(t2); + t4 = t3._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["length", t1, "variables", P.List_List$from(new H.MappedListIterable(t2, t3._eval$1("Map*(1)")._as(new Q.Context_toJson_closure()), t4), true, t4._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic)); + t4 = _this.parent; + Q._setIfNotNull(json, "parent", t4 == null ? null : t4.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Context && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Context type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", length: " + H.S(_this.length) + ", variables: " + H.S(_this.variables) + "]"; + }, + set$variables: function(variables) { + this.variables = type$.legacy_List_legacy_ContextElement._as(variables); + }, + $isContextRef: 1, + get$length: function(receiver) { + return this.length; + } + }; + Q.Context_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_ContextElement._as(f).toJson$0(); + }, + $signature: 35 + }; + Q.ContextElement.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["value", this.value.toJson$0()], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[ContextElement value: " + H.S(this.value) + "]"; + } + }; + Q.CpuSamples.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "CpuSamples"); + t3 = _this.samplePeriod; + t4 = _this.maxStackDepth; + t5 = _this.sampleCount; + t6 = _this.timeSpan; + t7 = _this.timeOriginMicros; + t8 = _this.timeExtentMicros; + t9 = _this.pid; + t10 = _this.functions; + t10.toString; + t11 = H._arrayInstanceType(t10); + t12 = t11._eval$1("MappedListIterable<1,Map*>"); + t12 = P.List_List$from(new H.MappedListIterable(t10, t11._eval$1("Map*(1)")._as(new Q.CpuSamples_toJson_closure()), t12), true, t12._eval$1("ListIterable.E")); + t11 = _this.samples; + t11.toString; + t10 = H._arrayInstanceType(t11); + t13 = t10._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["samplePeriod", t3, "maxStackDepth", t4, "sampleCount", t5, "timeSpan", t6, "timeOriginMicros", t7, "timeExtentMicros", t8, "pid", t9, "functions", t12, "samples", P.List_List$from(new H.MappedListIterable(t11, t10._eval$1("Map*(1)")._as(new Q.CpuSamples_toJson_closure0()), t13), true, t13._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[CpuSamples]"; + }, + set$functions: function(functions) { + this.functions = type$.legacy_List_legacy_ProfileFunction._as(functions); + }, + set$samples: function(samples) { + this.samples = type$.legacy_List_legacy_CpuSample._as(samples); + } + }; + Q.CpuSamples_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_ProfileFunction._as(f).toJson$0(); + }, + $signature: 36 + }; + Q.CpuSamples_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_CpuSample._as(f).toJson$0(); + }, + $signature: 37 + }; + Q.CpuSample.prototype = { + toJson$0: function() { + var t6, t7, _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2), + t3 = _this.tid, + t4 = _this.timestamp, + t5 = _this.stack; + t5.toString; + t6 = H._arrayInstanceType(t5); + t7 = t6._eval$1("MappedListIterable<1,int*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["tid", t3, "timestamp", t4, "stack", P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("int*(1)")._as(new Q.CpuSample_toJson_closure()), t7), true, t7._eval$1("ListIterable.E"))], t1, t2)); + Q._setIfNotNull(json, "vmTag", _this.vmTag); + Q._setIfNotNull(json, "userTag", _this.userTag); + Q._setIfNotNull(json, "truncated", _this.truncated); + return json; + }, + toString$0: function(_) { + return "[CpuSample tid: " + H.S(this.tid) + ", timestamp: " + H.S(this.timestamp) + ", stack: " + H.S(this.stack) + "]"; + }, + set$stack: function(stack) { + this.stack = type$.legacy_List_legacy_int._as(stack); + } + }; + Q.CpuSample_toJson_closure.prototype = { + call$1: function(f) { + return H._asIntS(f); + }, + $signature: 4 + }; + Q.ErrorRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Error"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", this.kind, "message", this.message], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_ErrorRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[ErrorRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", message: " + H.S(_this.message) + "]"; + } + }; + Q.Error.prototype = { + toJson$0: function() { + var t1, _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Error"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "message", _this.message], type$.legacy_String, type$.dynamic)); + t1 = _this.exception; + Q._setIfNotNull(json, "exception", t1 == null ? null : t1.toJson$0()); + t1 = _this.stacktrace; + Q._setIfNotNull(json, "stacktrace", t1 == null ? null : t1.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Error && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Error type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", message: " + H.S(_this.message) + "]"; + }, + $isErrorRef: 1 + }; + Q.Event.prototype = { + toJson$0: function() { + var _this = this, _null = null, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Event"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "timestamp", _this.timestamp], t1, t2)); + t2 = _this.isolate; + Q._setIfNotNull(json, "isolate", t2 == null ? _null : t2.toJson$0()); + t1 = _this.vm; + Q._setIfNotNull(json, "vm", t1 == null ? _null : t1.toJson$0()); + t1 = _this.breakpoint; + Q._setIfNotNull(json, "breakpoint", t1 == null ? _null : t1.toJson$0()); + t1 = _this.pauseBreakpoints; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("Map*(1)")._as(new Q.Event_toJson_closure()), t2._eval$1("MappedListIterable<1,Map*>")); + t1 = t2; + } + Q._setIfNotNull(json, "pauseBreakpoints", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + t1 = _this.topFrame; + Q._setIfNotNull(json, "topFrame", t1 == null ? _null : t1.toJson$0()); + t1 = _this.exception; + Q._setIfNotNull(json, "exception", t1 == null ? _null : t1.toJson$0()); + Q._setIfNotNull(json, "bytes", _this.bytes); + t1 = _this.inspectee; + Q._setIfNotNull(json, "inspectee", t1 == null ? _null : t1.toJson$0()); + Q._setIfNotNull(json, "extensionRPC", _this.extensionRPC); + Q._setIfNotNull(json, "extensionKind", _this.extensionKind); + t1 = _this.extensionData; + Q._setIfNotNull(json, "extensionData", t1 == null ? _null : t1.data); + t1 = _this.timelineEvents; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("Map*(1)")._as(new Q.Event_toJson_closure0()), t2._eval$1("MappedListIterable<1,Map*>")); + t1 = t2; + } + Q._setIfNotNull(json, "timelineEvents", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + t1 = _this.updatedStreams; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("String*(1)")._as(new Q.Event_toJson_closure1()), t2._eval$1("MappedListIterable<1,String*>")); + t1 = t2; + } + Q._setIfNotNull(json, "updatedStreams", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + Q._setIfNotNull(json, "atAsyncSuspension", _this.atAsyncSuspension); + Q._setIfNotNull(json, "status", _this.status); + t1 = _this.logRecord; + Q._setIfNotNull(json, "logRecord", t1 == null ? _null : t1.toJson$0()); + Q._setIfNotNull(json, "service", _this.service); + Q._setIfNotNull(json, "method", _this.method); + Q._setIfNotNull(json, "alias", _this.alias); + Q._setIfNotNull(json, "flag", _this.flag); + Q._setIfNotNull(json, "newValue", _this.newValue); + Q._setIfNotNull(json, "last", _this.last); + Q._setIfNotNull(json, "data", _this.data); + return json; + }, + toString$0: function(_) { + return "[Event type: " + H.S(this.type) + ", kind: " + H.S(this.kind) + ", timestamp: " + H.S(this.timestamp) + "]"; + }, + set$pauseBreakpoints: function(pauseBreakpoints) { + this.pauseBreakpoints = type$.legacy_List_legacy_Breakpoint._as(pauseBreakpoints); + }, + set$timelineEvents: function(timelineEvents) { + this.timelineEvents = type$.legacy_List_legacy_TimelineEvent._as(timelineEvents); + }, + set$updatedStreams: function(updatedStreams) { + this.updatedStreams = type$.legacy_List_legacy_String._as(updatedStreams); + } + }; + Q.Event_toJson_closure.prototype = { + call$1: function(f) { + type$.legacy_Breakpoint._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 23 + }; + Q.Event_toJson_closure0.prototype = { + call$1: function(f) { + type$.legacy_TimelineEvent._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 24 + }; + Q.Event_toJson_closure1.prototype = { + call$1: function(f) { + return H._asStringS(f); + }, + $signature: 5 + }; + Q.FieldRef.prototype = { + toJson$0: function() { + var _this = this, + json = _this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Field"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "declaredType", _this.declaredType.toJson$0(), "const", _this.isConst, "final", _this.isFinal, "static", _this.isStatic], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_FieldRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + return "[FieldRef]"; + } + }; + Q.Field.prototype = { + toJson$0: function() { + var t1, _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Field"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "declaredType", _this.declaredType.toJson$0(), "const", _this.isConst, "final", _this.isFinal, "static", _this.isStatic], type$.legacy_String, type$.dynamic)); + t1 = _this.staticValue; + Q._setIfNotNull(json, "staticValue", t1 == null ? null : t1.toJson$0()); + t1 = _this.location; + Q._setIfNotNull(json, "location", t1 == null ? null : t1.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Field && this.id == other.id; + }, + toString$0: function(_) { + return "[Field]"; + }, + $isFieldRef: 1 + }; + Q.Flag.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "comment", _this.comment, "modified", _this.modified], t1, t2)); + Q._setIfNotNull(json, "valueAsString", _this.valueAsString); + return json; + }, + toString$0: function(_) { + return "[Flag name: " + H.S(this.name) + ", comment: " + H.S(this.comment) + ", modified: " + H.S(this.modified) + "]"; + } + }; + Q.FlagList.prototype = { + toJson$0: function() { + var t3, t4, t5, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "FlagList"); + t3 = this.flags; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["flags", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.FlagList_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[FlagList type: " + H.S(this.type) + ", flags: " + H.S(this.flags) + "]"; + }, + set$flags: function(flags) { + this.flags = type$.legacy_List_legacy_Flag._as(flags); + } + }; + Q.FlagList_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_Flag._as(f).toJson$0(); + }, + $signature: 42 + }; + Q.Frame.prototype = { + toJson$0: function() { + var _this = this, _null = null, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Frame"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["index", _this.index], t1, t2)); + t2 = _this.$function; + Q._setIfNotNull(json, "function", t2 == null ? _null : t2.toJson$0()); + t1 = _this.code; + Q._setIfNotNull(json, "code", t1 == null ? _null : t1.toJson$0()); + t1 = _this.location; + Q._setIfNotNull(json, "location", t1 == null ? _null : t1.toJson$0()); + t1 = _this.vars; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("Map*(1)")._as(new Q.Frame_toJson_closure()), t2._eval$1("MappedListIterable<1,Map*>")); + t1 = t2; + } + Q._setIfNotNull(json, "vars", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + Q._setIfNotNull(json, "kind", _this.kind); + return json; + }, + toString$0: function(_) { + return "[Frame type: " + H.S(this.type) + ", index: " + H.S(this.index) + "]"; + }, + set$vars: function(vars) { + this.vars = type$.legacy_List_legacy_BoundVariable._as(vars); + } + }; + Q.Frame_toJson_closure.prototype = { + call$1: function(f) { + type$.legacy_BoundVariable._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 43 + }; + Q.FuncRef.prototype = { + toJson$0: function() { + var _this = this, + json = _this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Function"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "static", _this.isStatic, "const", _this.isConst], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_FuncRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[FuncRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", owner: " + H.S(_this.owner) + ", isStatic: " + H.S(_this.isStatic) + ", isConst: " + H.S(_this.isConst) + "]"; + } + }; + Q.Func.prototype = { + toJson$0: function() { + var t1, _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Function"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "static", _this.isStatic, "const", _this.isConst], type$.legacy_String, type$.dynamic)); + t1 = _this.location; + Q._setIfNotNull(json, "location", t1 == null ? null : t1.toJson$0()); + t1 = _this.code; + Q._setIfNotNull(json, "code", t1 == null ? null : t1.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Func && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Func type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", owner: " + H.S(_this.owner) + ", isStatic: " + H.S(_this.isStatic) + ", isConst: " + H.S(_this.isConst) + "]"; + }, + $isFuncRef: 1 + }; + Q.InstanceRef.prototype = { + InstanceRef$_fromJson$1: function(json) { + var t1, t2, _this = this; + _this.kind = H._asStringS(json.$index(0, "kind")); + t1 = type$.legacy_ClassRef; + _this.classRef = t1._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef)); + _this.set$valueAsString(H._asStringS(json.$index(0, "valueAsString"))); + t2 = json.$index(0, "valueAsStringIsTruncated"); + _this.valueAsStringIsTruncated = H._asBoolS(t2 == null ? false : t2); + _this.length = H._asIntS(json.$index(0, "length")); + _this.name = H._asStringS(json.$index(0, "name")); + _this.typeClass = t1._as(Q.createServiceObject(json.$index(0, "typeClass"), C.List_ClassRef)); + _this.parameterizedClass = t1._as(Q.createServiceObject(json.$index(0, "parameterizedClass"), C.List_ClassRef)); + _this.pattern = type$.legacy_InstanceRef._as(Q.createServiceObject(json.$index(0, "pattern"), C.List_InstanceRef)); + _this.closureFunction = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "closureFunction"), C.List_FuncRef)); + _this.closureContext = type$.legacy_ContextRef._as(Q.createServiceObject(json.$index(0, "closureContext"), C.List_ContextRef)); + }, + toJson$0: function() { + var t1, _this = this, _null = null, + json = _this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Instance"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "class", _this.classRef.toJson$0()], type$.legacy_String, type$.dynamic)); + Q._setIfNotNull(json, "valueAsString", _this.get$valueAsString()); + t1 = _this.valueAsStringIsTruncated; + Q._setIfNotNull(json, "valueAsStringIsTruncated", t1 === true); + Q._setIfNotNull(json, "length", _this.length); + Q._setIfNotNull(json, "name", _this.name); + t1 = _this.typeClass; + Q._setIfNotNull(json, "typeClass", t1 == null ? _null : t1.toJson$0()); + t1 = _this.parameterizedClass; + Q._setIfNotNull(json, "parameterizedClass", t1 == null ? _null : t1.toJson$0()); + t1 = _this.pattern; + Q._setIfNotNull(json, "pattern", t1 == null ? _null : t1.toJson$0()); + t1 = _this.closureFunction; + Q._setIfNotNull(json, "closureFunction", t1 == null ? _null : t1.toJson$0()); + t1 = _this.closureContext; + Q._setIfNotNull(json, "closureContext", t1 == null ? _null : t1.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_InstanceRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[InstanceRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.classRef) + "]"; + }, + set$valueAsString: function(valueAsString) { + this.valueAsString = H._asStringS(valueAsString); + }, + get$valueAsString: function() { + return this.valueAsString; + }, + get$length: function(receiver) { + return this.length; + } + }; + Q.Instance.prototype = { + Instance$_fromJson$1: function(json) { + var t1, t2, _this = this, + _s8_ = "elements", + _s12_ = "associations"; + _this.kind = H._asStringS(json.$index(0, "kind")); + t1 = type$.legacy_ClassRef; + _this.Instance_classRef = t1._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef)); + _this.set$valueAsString(H._asStringS(json.$index(0, "valueAsString"))); + t2 = json.$index(0, "valueAsStringIsTruncated"); + _this.valueAsStringIsTruncated = H._asBoolS(t2 == null ? false : t2); + _this.length = H._asIntS(json.$index(0, "length")); + _this.offset = H._asIntS(json.$index(0, "offset")); + _this.count = H._asIntS(json.$index(0, "count")); + _this.name = H._asStringS(json.$index(0, "name")); + _this.typeClass = t1._as(Q.createServiceObject(json.$index(0, "typeClass"), C.List_ClassRef)); + _this.parameterizedClass = t1._as(Q.createServiceObject(json.$index(0, "parameterizedClass"), C.List_ClassRef)); + _this.set$fields(json.$index(0, "fields") == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, "fields"), C.List_BoundField)), true, type$.legacy_BoundField)); + _this.elements = json.$index(0, _s8_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, _s8_), C.List_dynamic)), true, type$.dynamic); + _this.set$associations(json.$index(0, _s12_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q._createSpecificObject(json.$index(0, _s12_), Q.vm_service_MapAssociation_parse$closure())), true, type$.legacy_MapAssociation)); + _this.bytes = H._asStringS(json.$index(0, "bytes")); + t1 = type$.legacy_InstanceRef; + _this.mirrorReferent = t1._as(Q.createServiceObject(json.$index(0, "mirrorReferent"), C.List_InstanceRef)); + _this.pattern = t1._as(Q.createServiceObject(json.$index(0, "pattern"), C.List_InstanceRef)); + _this.closureFunction = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "closureFunction"), C.List_FuncRef)); + _this.closureContext = type$.legacy_ContextRef._as(Q.createServiceObject(json.$index(0, "closureContext"), C.List_ContextRef)); + _this.isCaseSensitive = H._asBoolS(json.$index(0, "isCaseSensitive")); + _this.isMultiLine = H._asBoolS(json.$index(0, "isMultiLine")); + _this.propertyKey = t1._as(Q.createServiceObject(json.$index(0, "propertyKey"), C.List_InstanceRef)); + _this.propertyValue = t1._as(Q.createServiceObject(json.$index(0, "propertyValue"), C.List_InstanceRef)); + _this.typeArguments = type$.legacy_TypeArgumentsRef._as(Q.createServiceObject(json.$index(0, "typeArguments"), C.List_TypeArgumentsRef)); + _this.parameterIndex = H._asIntS(json.$index(0, "parameterIndex")); + _this.targetType = t1._as(Q.createServiceObject(json.$index(0, "targetType"), C.List_InstanceRef)); + _this.bound = t1._as(Q.createServiceObject(json.$index(0, "bound"), C.List_InstanceRef)); + }, + toJson$0: function() { + var t1, t2, _this = this, _null = null, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Instance"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "class", _this.Instance_classRef.toJson$0()], type$.legacy_String, type$.dynamic)); + Q._setIfNotNull(json, "valueAsString", _this.get$valueAsString()); + t1 = _this.valueAsStringIsTruncated; + Q._setIfNotNull(json, "valueAsStringIsTruncated", t1 === true); + Q._setIfNotNull(json, "length", _this.length); + Q._setIfNotNull(json, "offset", _this.offset); + Q._setIfNotNull(json, "count", _this.count); + Q._setIfNotNull(json, "name", _this.name); + t1 = _this.typeClass; + Q._setIfNotNull(json, "typeClass", t1 == null ? _null : t1.toJson$0()); + t1 = _this.parameterizedClass; + Q._setIfNotNull(json, "parameterizedClass", t1 == null ? _null : t1.toJson$0()); + t1 = _this.fields; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("Map*(1)")._as(new Q.Instance_toJson_closure()), t2._eval$1("MappedListIterable<1,Map*>")); + t1 = t2; + } + Q._setIfNotNull(json, "fields", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + t1 = _this.elements; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("@(1)")._as(new Q.Instance_toJson_closure0()), t2._eval$1("MappedListIterable<1,@>")); + t1 = t2; + } + Q._setIfNotNull(json, "elements", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + t1 = _this.associations; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("Map*(1)")._as(new Q.Instance_toJson_closure1()), t2._eval$1("MappedListIterable<1,Map*>")); + t1 = t2; + } + Q._setIfNotNull(json, "associations", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + Q._setIfNotNull(json, "bytes", _this.bytes); + t1 = _this.mirrorReferent; + Q._setIfNotNull(json, "mirrorReferent", t1 == null ? _null : t1.toJson$0()); + t1 = _this.pattern; + Q._setIfNotNull(json, "pattern", t1 == null ? _null : t1.toJson$0()); + t1 = _this.closureFunction; + Q._setIfNotNull(json, "closureFunction", t1 == null ? _null : t1.toJson$0()); + t1 = _this.closureContext; + Q._setIfNotNull(json, "closureContext", t1 == null ? _null : t1.toJson$0()); + Q._setIfNotNull(json, "isCaseSensitive", _this.isCaseSensitive); + Q._setIfNotNull(json, "isMultiLine", _this.isMultiLine); + t1 = _this.propertyKey; + Q._setIfNotNull(json, "propertyKey", t1 == null ? _null : t1.toJson$0()); + t1 = _this.propertyValue; + Q._setIfNotNull(json, "propertyValue", t1 == null ? _null : t1.toJson$0()); + t1 = _this.typeArguments; + Q._setIfNotNull(json, "typeArguments", t1 == null ? _null : t1.toJson$0()); + Q._setIfNotNull(json, "parameterIndex", _this.parameterIndex); + t1 = _this.targetType; + Q._setIfNotNull(json, "targetType", t1 == null ? _null : t1.toJson$0()); + t1 = _this.bound; + Q._setIfNotNull(json, "bound", t1 == null ? _null : t1.toJson$0()); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Instance && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Instance type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.Instance_classRef) + "]"; + }, + set$classRef: function(classRef) { + this.Instance_classRef = type$.legacy_ClassRef._as(classRef); + }, + set$valueAsString: function(valueAsString) { + this.valueAsString = H._asStringS(valueAsString); + }, + set$fields: function(fields) { + this.fields = type$.legacy_List_legacy_BoundField._as(fields); + }, + set$associations: function(associations) { + this.associations = type$.legacy_List_legacy_MapAssociation._as(associations); + }, + $isInstanceRef: 1, + get$classRef: function() { + return this.Instance_classRef; + }, + get$valueAsString: function() { + return this.valueAsString; + }, + get$length: function(receiver) { + return this.length; + } + }; + Q.Instance_toJson_closure.prototype = { + call$1: function(f) { + type$.legacy_BoundField._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 26 + }; + Q.Instance_toJson_closure0.prototype = { + call$1: function(f) { + return f == null ? null : f.toJson$0(); + }, + $signature: 3 + }; + Q.Instance_toJson_closure1.prototype = { + call$1: function(f) { + type$.legacy_MapAssociation._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 45 + }; + Q.IsolateRef.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "@Isolate"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", this.id, "number", this.number, "name", this.name], t1, t2)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_IsolateRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[IsolateRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", number: " + H.S(_this.number) + ", name: " + H.S(_this.name) + "]"; + }, + get$id: function(receiver) { + return this.id; + } + }; + Q.Isolate.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, t14, _this = this, _null = null, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Isolate"); + t3 = _this.id; + t4 = _this.number; + t5 = _this.name; + t6 = _this.startTime; + t7 = _this.runnable; + t8 = _this.livePorts; + t9 = _this.pauseOnExit; + t10 = _this.pauseEvent.toJson$0(); + t11 = _this.libraries; + t11.toString; + t12 = H._arrayInstanceType(t11); + t13 = t12._eval$1("MappedListIterable<1,Map*>"); + t13 = P.List_List$from(new H.MappedListIterable(t11, t12._eval$1("Map*(1)")._as(new Q.Isolate_toJson_closure()), t13), true, t13._eval$1("ListIterable.E")); + t12 = _this.breakpoints; + t12.toString; + t11 = H._arrayInstanceType(t12); + t14 = t11._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", t3, "number", t4, "name", t5, "startTime", t6, "runnable", t7, "livePorts", t8, "pauseOnExit", t9, "pauseEvent", t10, "libraries", t13, "breakpoints", P.List_List$from(new H.MappedListIterable(t12, t11._eval$1("Map*(1)")._as(new Q.Isolate_toJson_closure0()), t14), true, t14._eval$1("ListIterable.E")), "exceptionPauseMode", _this.exceptionPauseMode], t1, t2)); + t2 = _this.rootLib; + Q._setIfNotNull(json, "rootLib", t2 == null ? _null : t2.toJson$0()); + t1 = _this.error; + Q._setIfNotNull(json, "error", t1 == null ? _null : t1.toJson$0()); + t1 = _this.extensionRPCs; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("String*(1)")._as(new Q.Isolate_toJson_closure1()), t2._eval$1("MappedListIterable<1,String*>")); + t1 = t2; + } + Q._setIfNotNull(json, "extensionRPCs", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Isolate && this.id == other.id; + }, + toString$0: function(_) { + return "[Isolate]"; + }, + set$libraries: function(libraries) { + this.libraries = type$.legacy_List_legacy_LibraryRef._as(libraries); + }, + set$breakpoints: function(breakpoints) { + this.breakpoints = type$.legacy_List_legacy_Breakpoint._as(breakpoints); + }, + set$extensionRPCs: function(extensionRPCs) { + this.extensionRPCs = type$.legacy_List_legacy_String._as(extensionRPCs); + }, + $isIsolateRef: 1, + get$id: function(receiver) { + return this.id; + } + }; + Q.Isolate_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_LibraryRef._as(f).toJson$0(); + }, + $signature: 46 + }; + Q.Isolate_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_Breakpoint._as(f).toJson$0(); + }, + $signature: 23 + }; + Q.Isolate_toJson_closure1.prototype = { + call$1: function(f) { + return H._asStringS(f); + }, + $signature: 5 + }; + Q.IsolateGroupRef.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "@IsolateGroup"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", this.id, "number", this.number, "name", this.name], t1, t2)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_IsolateGroupRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[IsolateGroupRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", number: " + H.S(_this.number) + ", name: " + H.S(_this.name) + "]"; + }, + get$id: function(receiver) { + return this.id; + } + }; + Q.IsolateGroup.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, t7, t8, _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "IsolateGroup"); + t3 = _this.id; + t4 = _this.number; + t5 = _this.name; + t6 = _this.isolates; + t6.toString; + t7 = H._arrayInstanceType(t6); + t8 = t7._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", t3, "number", t4, "name", t5, "isolates", P.List_List$from(new H.MappedListIterable(t6, t7._eval$1("Map*(1)")._as(new Q.IsolateGroup_toJson_closure()), t8), true, t8._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.IsolateGroup && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[IsolateGroup type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", number: " + H.S(_this.number) + ", name: " + H.S(_this.name) + ", isolates: " + H.S(_this.isolates) + "]"; + }, + set$isolates: function(isolates) { + this.isolates = type$.legacy_List_legacy_IsolateRef._as(isolates); + }, + $isIsolateGroupRef: 1, + get$id: function(receiver) { + return this.id; + } + }; + Q.IsolateGroup_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_IsolateRef._as(f).toJson$0(); + }, + $signature: 25 + }; + Q.InboundReferences.prototype = { + toJson$0: function() { + var t3, t4, t5, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "InboundReferences"); + t3 = this.references; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["references", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.InboundReferences_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[InboundReferences type: " + H.S(this.type) + ", references: " + H.S(this.references) + "]"; + }, + set$references: function(references) { + this.references = type$.legacy_List_legacy_InboundReference._as(references); + } + }; + Q.InboundReferences_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_InboundReference._as(f).toJson$0(); + }, + $signature: 48 + }; + Q.InboundReference.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["source", this.source.toJson$0()], t1, t2)); + Q._setIfNotNull(json, "parentListIndex", this.parentListIndex); + t2 = this.parentField; + Q._setIfNotNull(json, "parentField", t2 == null ? null : t2.toJson$0()); + return json; + }, + toString$0: function(_) { + return "[InboundReference source: " + H.S(this.source) + "]"; + } + }; + Q.InstanceSet.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "InstanceSet"); + t3 = this.totalCount; + t4 = this.instances; + t4.toString; + t5 = H._arrayInstanceType(t4); + t6 = t5._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["totalCount", t3, "instances", P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map*(1)")._as(new Q.InstanceSet_toJson_closure()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[InstanceSet type: " + H.S(this.type) + ", totalCount: " + H.S(this.totalCount) + ", instances: " + H.S(this.instances) + "]"; + }, + set$instances: function(instances) { + this.instances = type$.legacy_List_legacy_ObjRef._as(instances); + } + }; + Q.InstanceSet_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_ObjRef._as(f).toJson$0(); + }, + $signature: 49 + }; + Q.LibraryRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Library"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name, "uri", this.uri], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_LibraryRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[LibraryRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", uri: " + H.S(_this.uri) + "]"; + } + }; + Q.Library.prototype = { + toJson$0: function() { + var t1, t2, t3, t4, t5, t6, t7, t8, t9, t10, _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Library"); + t1 = _this.name; + t2 = _this.uri; + t3 = _this.debuggable; + t4 = _this.dependencies; + t4.toString; + t5 = H._arrayInstanceType(t4); + t6 = t5._eval$1("MappedListIterable<1,Map*>"); + t6 = P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map*(1)")._as(new Q.Library_toJson_closure()), t6), true, t6._eval$1("ListIterable.E")); + t5 = _this.scripts; + t5.toString; + t4 = H._arrayInstanceType(t5); + t7 = t4._eval$1("MappedListIterable<1,Map*>"); + t7 = P.List_List$from(new H.MappedListIterable(t5, t4._eval$1("Map*(1)")._as(new Q.Library_toJson_closure0()), t7), true, t7._eval$1("ListIterable.E")); + t4 = _this.variables; + t4.toString; + t5 = H._arrayInstanceType(t4); + t8 = t5._eval$1("MappedListIterable<1,Map*>"); + t8 = P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map*(1)")._as(new Q.Library_toJson_closure1()), t8), true, t8._eval$1("ListIterable.E")); + t5 = _this.functions; + t5.toString; + t4 = H._arrayInstanceType(t5); + t9 = t4._eval$1("MappedListIterable<1,Map*>"); + t9 = P.List_List$from(new H.MappedListIterable(t5, t4._eval$1("Map*(1)")._as(new Q.Library_toJson_closure2()), t9), true, t9._eval$1("ListIterable.E")); + t4 = _this.classes; + t4.toString; + t5 = H._arrayInstanceType(t4); + t10 = t5._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t1, "uri", t2, "debuggable", t3, "dependencies", t6, "scripts", t7, "variables", t8, "functions", t9, "classes", P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map*(1)")._as(new Q.Library_toJson_closure3()), t10), true, t10._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Library && this.id == other.id; + }, + toString$0: function(_) { + return "[Library]"; + }, + set$dependencies: function(dependencies) { + this.dependencies = type$.legacy_List_legacy_LibraryDependency._as(dependencies); + }, + set$scripts: function(scripts) { + this.scripts = type$.legacy_List_legacy_ScriptRef._as(scripts); + }, + set$variables: function(variables) { + this.variables = type$.legacy_List_legacy_FieldRef._as(variables); + }, + set$functions: function(functions) { + this.functions = type$.legacy_List_legacy_FuncRef._as(functions); + }, + set$classes: function(classes) { + this.classes = type$.legacy_List_legacy_ClassRef._as(classes); + }, + $isLibraryRef: 1 + }; + Q.Library_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_LibraryDependency._as(f).toJson$0(); + }, + $signature: 50 + }; + Q.Library_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_ScriptRef._as(f).toJson$0(); + }, + $signature: 9 + }; + Q.Library_toJson_closure1.prototype = { + call$1: function(f) { + return type$.legacy_FieldRef._as(f).toJson$0(); + }, + $signature: 21 + }; + Q.Library_toJson_closure2.prototype = { + call$1: function(f) { + return type$.legacy_FuncRef._as(f).toJson$0(); + }, + $signature: 22 + }; + Q.Library_toJson_closure3.prototype = { + call$1: function(f) { + return type$.legacy_ClassRef._as(f).toJson$0(); + }, + $signature: 8 + }; + Q.LibraryDependency.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["isImport", _this.isImport, "isDeferred", _this.isDeferred, "prefix", _this.prefix, "target", _this.target.toJson$0()], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[LibraryDependency isImport: " + H.S(_this.isImport) + ", isDeferred: " + H.S(_this.isDeferred) + ", prefix: " + H.S(_this.prefix) + ", target: " + H.S(_this.target) + "]"; + } + }; + Q.LogRecord.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "LogRecord"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["message", _this.message.toJson$0(), "time", _this.time, "level", _this.level, "sequenceNumber", _this.sequenceNumber, "loggerName", _this.loggerName.toJson$0(), "zone", _this.zone.toJson$0(), "error", _this.error.toJson$0(), "stackTrace", _this.stackTrace.toJson$0()], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[LogRecord]"; + } + }; + Q.MapAssociation.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["key", this.key.toJson$0(), "value", this.value.toJson$0()], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[MapAssociation key: " + H.S(this.key) + ", value: " + H.S(this.value) + "]"; + } + }; + Q.MemoryUsage.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "MemoryUsage"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["externalUsage", this.externalUsage, "heapCapacity", this.heapCapacity, "heapUsage", this.heapUsage], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[MemoryUsage type: " + H.S(_this.type) + ", externalUsage: " + H.S(_this.externalUsage) + ", heapCapacity: " + H.S(_this.heapCapacity) + ", heapUsage: " + H.S(_this.heapUsage) + "]"; + } + }; + Q.Message.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Message"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["index", _this.index, "name", _this.name, "messageObjectId", _this.messageObjectId, "size", _this.size], t1, t2)); + t2 = _this.handler; + Q._setIfNotNull(json, "handler", t2 == null ? null : t2.toJson$0()); + t1 = _this.location; + Q._setIfNotNull(json, "location", t1 == null ? null : t1.toJson$0()); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[Message type: " + H.S(_this.type) + ", index: " + H.S(_this.index) + ", name: " + H.S(_this.name) + ", messageObjectId: " + H.S(_this.messageObjectId) + ", size: " + H.S(_this.size) + "]"; + } + }; + Q.NativeFunction.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[NativeFunction name: " + H.S(this.name) + "]"; + } + }; + Q.NullValRef.prototype = { + toJson$0: function() { + var json = this.super$InstanceRef$toJson(); + json.$indexSet(0, "type", "@Null"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["valueAsString", this.NullValRef_valueAsString], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_NullValRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + var _this = this; + return "[NullValRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.classRef) + ", valueAsString: " + H.S(_this.NullValRef_valueAsString) + "]"; + }, + set$valueAsString: function(valueAsString) { + this.NullValRef_valueAsString = H._asStringS(valueAsString); + }, + get$valueAsString: function() { + return this.NullValRef_valueAsString; + } + }; + Q.NullVal.prototype = { + toJson$0: function() { + var json = this.super$Instance$toJson(); + json.$indexSet(0, "type", "Null"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["valueAsString", this.NullVal_valueAsString], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.NullVal && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[NullVal type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.Instance_classRef) + ", valueAsString: " + H.S(_this.NullVal_valueAsString) + "]"; + }, + set$valueAsString: function(valueAsString) { + this.NullVal_valueAsString = H._asStringS(valueAsString); + }, + $isNullValRef: 1, + get$valueAsString: function() { + return this.NullVal_valueAsString; + } + }; + Q.ObjRef.prototype = { + ObjRef$_fromJson$1: function(json) { + this.id = H._asStringS(json.$index(0, "id")); + this.fixedId = H._asBoolS(json.$index(0, "fixedId")); + }, + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "@Object"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", this.id], t1, t2)); + Q._setIfNotNull(json, "fixedId", this.fixedId); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_ObjRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + return "[ObjRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + "]"; + }, + get$id: function(receiver) { + return this.id; + } + }; + Q.Obj.prototype = { + Obj$_fromJson$1: function(json) { + var _this = this; + _this.id = H._asStringS(json.$index(0, "id")); + _this.fixedId = H._asBoolS(json.$index(0, "fixedId")); + _this.set$classRef(type$.legacy_ClassRef._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef))); + _this.size = H._asIntS(json.$index(0, "size")); + }, + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Object"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", _this.id], t1, t2)); + Q._setIfNotNull(json, "fixedId", _this.fixedId); + t2 = _this.get$classRef(); + Q._setIfNotNull(json, "class", t2 == null ? null : t2.toJson$0()); + Q._setIfNotNull(json, "size", _this.size); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Obj && this.id == other.id; + }, + toString$0: function(_) { + return "[Obj type: " + H.S(this.type) + ", id: " + H.S(this.id) + "]"; + }, + set$classRef: function(classRef) { + this.classRef = type$.legacy_ClassRef._as(classRef); + }, + $isObjRef: 1, + get$id: function(receiver) { + return this.id; + }, + get$classRef: function() { + return this.classRef; + } + }; + Q.ProfileFunction.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "inclusiveTicks", _this.inclusiveTicks, "exclusiveTicks", _this.exclusiveTicks, "resolvedUrl", _this.resolvedUrl, "function", _this.$function.toJson$0()], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[ProfileFunction kind: " + H.S(_this.kind) + ", inclusiveTicks: " + H.S(_this.inclusiveTicks) + ", exclusiveTicks: " + H.S(_this.exclusiveTicks) + ", resolvedUrl: " + H.S(_this.resolvedUrl) + ", function: " + H.S(_this.$function) + "]"; + } + }; + Q.ReloadReport.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "ReloadReport"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["success", this.success], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[ReloadReport type: " + H.S(this.type) + ", success: " + H.S(this.success) + "]"; + } + }; + Q.RetainingObject.prototype = { + toJson$0: function() { + var _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["value", _this.value.toJson$0()], t1, t2)); + Q._setIfNotNull(json, "parentListIndex", _this.parentListIndex); + t2 = _this.parentMapKey; + Q._setIfNotNull(json, "parentMapKey", t2 == null ? null : t2.toJson$0()); + Q._setIfNotNull(json, "parentField", _this.parentField); + return json; + }, + toString$0: function(_) { + return "[RetainingObject value: " + H.S(this.value) + "]"; + } + }; + Q.RetainingPath.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, t7, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "RetainingPath"); + t3 = this.length; + t4 = this.gcRootType; + t5 = this.elements; + t5.toString; + t6 = H._arrayInstanceType(t5); + t7 = t6._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["length", t3, "gcRootType", t4, "elements", P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("Map*(1)")._as(new Q.RetainingPath_toJson_closure()), t7), true, t7._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[RetainingPath type: " + H.S(_this.type) + ", length: " + H.S(_this.length) + ", gcRootType: " + H.S(_this.gcRootType) + ", elements: " + H.S(_this.elements) + "]"; + }, + set$elements: function(elements) { + this.elements = type$.legacy_List_legacy_RetainingObject._as(elements); + }, + get$length: function(receiver) { + return this.length; + } + }; + Q.RetainingPath_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_RetainingObject._as(f).toJson$0(); + }, + $signature: 52 + }; + Q.Response.prototype = { + toJson$0: function() { + var result = P.LinkedHashMap_LinkedHashMap$of(this.json, type$.legacy_String, type$.dynamic), + t1 = this.type; + result.$indexSet(0, "type", t1 == null ? "Response" : t1); + return result; + }, + toString$0: function(_) { + return "[Response type: " + H.S(this.type) + "]"; + } + }; + Q.Sentinel.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Sentinel"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", this.kind, "valueAsString", this.valueAsString], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[Sentinel type: " + H.S(this.type) + ", kind: " + H.S(this.kind) + ", valueAsString: " + H.S(this.valueAsString) + "]"; + } + }; + Q.ScriptRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@Script"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["uri", this.uri], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_ScriptRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + return "[ScriptRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", uri: " + H.S(this.uri) + "]"; + } + }; + Q.Script.prototype = { + Script$_fromJson$1: function(json) { + var _this = this, + _s13_ = "tokenPosTable"; + _this.uri = H._asStringS(json.$index(0, "uri")); + _this.library = type$.legacy_LibraryRef._as(Q.createServiceObject(json.$index(0, "library"), C.List_LibraryRef)); + _this.lineOffset = H._asIntS(json.$index(0, "lineOffset")); + _this.columnOffset = H._asIntS(json.$index(0, "columnOffset")); + _this.source = H._asStringS(json.$index(0, "source")); + _this.set$tokenPosTable(json.$index(0, _s13_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(J.map$1$ax(json.$index(0, _s13_), new Q.Script$_fromJson_closure())), true, type$.legacy_List_legacy_int)); + _this._parseTokenPosTable$0(); + }, + _parseTokenPosTable$0: function() { + var lineSet, t1, t2, t3, t4, _i, line, t5, lineNumber, pos, tokenOffset, colNumber, _this = this; + if (_this.tokenPosTable == null) + return; + lineSet = P.LinkedHashSet_LinkedHashSet(type$.legacy_int); + for (t1 = _this.tokenPosTable, t2 = t1.length, t3 = _this._tokenToLine, t4 = _this._tokenToColumn, _i = 0; _i < t1.length; t1.length === t2 || (0, H.throwConcurrentModificationError)(t1), ++_i) { + line = t1[_i]; + t5 = J.getInterceptor$asx(line); + lineNumber = H._asIntS(t5.$index(line, 0)); + lineSet.add$1(0, lineNumber); + for (pos = 1; pos < t5.get$length(line); pos += 2) { + tokenOffset = H._asIntS(t5.$index(line, pos)); + colNumber = H._asIntS(t5.$index(line, pos + 1)); + t3.$indexSet(0, tokenOffset, lineNumber); + t4.$indexSet(0, tokenOffset, colNumber); + } + } + }, + toJson$0: function() { + var t1, t2, _this = this, + json = _this.super$Obj$toJson(); + json.$indexSet(0, "type", "Script"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["uri", _this.uri, "library", _this.library.toJson$0()], type$.legacy_String, type$.dynamic)); + Q._setIfNotNull(json, "lineOffset", _this.lineOffset); + Q._setIfNotNull(json, "columnOffset", _this.columnOffset); + Q._setIfNotNull(json, "source", _this.source); + t1 = _this.tokenPosTable; + if (t1 == null) + t1 = null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("List*(1)")._as(new Q.Script_toJson_closure()), t2._eval$1("MappedListIterable<1,List*>")); + t1 = t2; + } + Q._setIfNotNull(json, "tokenPosTable", t1 == null ? null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.Script && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[Script type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", uri: " + H.S(_this.uri) + ", library: " + H.S(_this.library) + "]"; + }, + set$tokenPosTable: function(tokenPosTable) { + this.tokenPosTable = type$.legacy_List_legacy_List_legacy_int._as(tokenPosTable); + }, + $isScriptRef: 1 + }; + Q.Script$_fromJson_closure.prototype = { + call$1: function(list) { + return P.List_List$from(type$.Iterable_dynamic._as(list), true, type$.legacy_int); + }, + $signature: 53 + }; + Q.Script_toJson_closure.prototype = { + call$1: function(f) { + type$.legacy_List_legacy_int._as(f); + return f == null ? null : J.toList$0$ax(f); + }, + $signature: 54 + }; + Q.ScriptList.prototype = { + toJson$0: function() { + var t3, t4, t5, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "ScriptList"); + t3 = this.scripts; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["scripts", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.ScriptList_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[ScriptList type: " + H.S(this.type) + ", scripts: " + H.S(this.scripts) + "]"; + }, + set$scripts: function(scripts) { + this.scripts = type$.legacy_List_legacy_ScriptRef._as(scripts); + } + }; + Q.ScriptList_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_ScriptRef._as(f).toJson$0(); + }, + $signature: 9 + }; + Q.SourceLocation.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "SourceLocation"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["script", this.script.toJson$0(), "tokenPos", this.tokenPos], t1, t2)); + Q._setIfNotNull(json, "endTokenPos", this.endTokenPos); + return json; + }, + toString$0: function(_) { + return "[SourceLocation type: " + H.S(this.type) + ", script: " + H.S(this.script) + ", tokenPos: " + H.S(this.tokenPos) + "]"; + } + }; + Q.SourceReport.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "SourceReport"); + t3 = this.ranges; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + t5 = P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.SourceReport_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")); + t4 = this.scripts; + t4.toString; + t3 = H._arrayInstanceType(t4); + t6 = t3._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["ranges", t5, "scripts", P.List_List$from(new H.MappedListIterable(t4, t3._eval$1("Map*(1)")._as(new Q.SourceReport_toJson_closure0()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[SourceReport type: " + H.S(this.type) + ", ranges: " + H.S(this.ranges) + ", scripts: " + H.S(this.scripts) + "]"; + }, + set$ranges: function(ranges) { + this.ranges = type$.legacy_List_legacy_SourceReportRange._as(ranges); + }, + set$scripts: function(scripts) { + this.scripts = type$.legacy_List_legacy_ScriptRef._as(scripts); + } + }; + Q.SourceReport_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_SourceReportRange._as(f).toJson$0(); + }, + $signature: 55 + }; + Q.SourceReport_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_ScriptRef._as(f).toJson$0(); + }, + $signature: 9 + }; + Q.SourceReportCoverage.prototype = { + toJson$0: function() { + var t4, t5, t6, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2), + t3 = this.hits; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,int*>"); + t5 = P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("int*(1)")._as(new Q.SourceReportCoverage_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")); + t4 = this.misses; + t4.toString; + t3 = H._arrayInstanceType(t4); + t6 = t3._eval$1("MappedListIterable<1,int*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["hits", t5, "misses", P.List_List$from(new H.MappedListIterable(t4, t3._eval$1("int*(1)")._as(new Q.SourceReportCoverage_toJson_closure0()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[SourceReportCoverage hits: " + H.S(this.hits) + ", misses: " + H.S(this.misses) + "]"; + }, + set$hits: function(hits) { + this.hits = type$.legacy_List_legacy_int._as(hits); + }, + set$misses: function(misses) { + this.misses = type$.legacy_List_legacy_int._as(misses); + } + }; + Q.SourceReportCoverage_toJson_closure.prototype = { + call$1: function(f) { + return H._asIntS(f); + }, + $signature: 4 + }; + Q.SourceReportCoverage_toJson_closure0.prototype = { + call$1: function(f) { + return H._asIntS(f); + }, + $signature: 4 + }; + Q.SourceReportRange.prototype = { + toJson$0: function() { + var _this = this, _null = null, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["scriptIndex", _this.scriptIndex, "startPos", _this.startPos, "endPos", _this.endPos, "compiled", _this.compiled], t1, t2)); + t2 = _this.error; + Q._setIfNotNull(json, "error", t2 == null ? _null : t2.toJson$0()); + t1 = _this.coverage; + Q._setIfNotNull(json, "coverage", t1 == null ? _null : t1.toJson$0()); + t1 = _this.possibleBreakpoints; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("int*(1)")._as(new Q.SourceReportRange_toJson_closure()), t2._eval$1("MappedListIterable<1,int*>")); + t1 = t2; + } + Q._setIfNotNull(json, "possibleBreakpoints", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[SourceReportRange scriptIndex: " + H.S(_this.scriptIndex) + ", startPos: " + H.S(_this.startPos) + ", endPos: " + H.S(_this.endPos) + ", compiled: " + H.S(_this.compiled) + "]"; + }, + set$possibleBreakpoints: function(possibleBreakpoints) { + this.possibleBreakpoints = type$.legacy_List_legacy_int._as(possibleBreakpoints); + } + }; + Q.SourceReportRange_toJson_closure.prototype = { + call$1: function(f) { + return H._asIntS(f); + }, + $signature: 4 + }; + Q.Stack.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, _this = this, _null = null, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Stack"); + t3 = _this.frames; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + t5 = P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.Stack_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")); + t4 = _this.messages; + t4.toString; + t3 = H._arrayInstanceType(t4); + t6 = t3._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["frames", t5, "messages", P.List_List$from(new H.MappedListIterable(t4, t3._eval$1("Map*(1)")._as(new Q.Stack_toJson_closure0()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2)); + t2 = _this.asyncCausalFrames; + if (t2 == null) + t1 = _null; + else { + t1 = H._arrayInstanceType(t2); + t1 = new H.MappedListIterable(t2, t1._eval$1("Map*(1)")._as(new Q.Stack_toJson_closure1()), t1._eval$1("MappedListIterable<1,Map*>")); + } + Q._setIfNotNull(json, "asyncCausalFrames", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + t1 = _this.awaiterFrames; + if (t1 == null) + t1 = _null; + else { + t2 = H._arrayInstanceType(t1); + t2 = new H.MappedListIterable(t1, t2._eval$1("Map*(1)")._as(new Q.Stack_toJson_closure2()), t2._eval$1("MappedListIterable<1,Map*>")); + t1 = t2; + } + Q._setIfNotNull(json, "awaiterFrames", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"))); + return json; + }, + toString$0: function(_) { + return "[Stack type: " + H.S(this.type) + ", frames: " + H.S(this.frames) + ", messages: " + H.S(this.messages) + "]"; + }, + set$frames: function($frames) { + this.frames = type$.legacy_List_legacy_Frame._as($frames); + }, + set$asyncCausalFrames: function(asyncCausalFrames) { + this.asyncCausalFrames = type$.legacy_List_legacy_Frame._as(asyncCausalFrames); + }, + set$awaiterFrames: function(awaiterFrames) { + this.awaiterFrames = type$.legacy_List_legacy_Frame._as(awaiterFrames); + }, + set$messages: function(messages) { + this.messages = type$.legacy_List_legacy_Message._as(messages); + } + }; + Q.Stack_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_Frame._as(f).toJson$0(); + }, + $signature: 10 + }; + Q.Stack_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_Message._as(f).toJson$0(); + }, + $signature: 57 + }; + Q.Stack_toJson_closure1.prototype = { + call$1: function(f) { + type$.legacy_Frame._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 10 + }; + Q.Stack_toJson_closure2.prototype = { + call$1: function(f) { + type$.legacy_Frame._as(f); + return f == null ? null : f.toJson$0(); + }, + $signature: 10 + }; + Q.Success.prototype = { + toJson$0: function() { + var json = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic); + json.$indexSet(0, "type", "Success"); + return json; + }, + toString$0: function(_) { + return "[Success type: " + H.S(this.type) + "]"; + } + }; + Q.Timeline.prototype = { + toJson$0: function() { + var t3, t4, t5, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Timeline"); + t3 = this.traceEvents; + t3.toString; + t4 = H._arrayInstanceType(t3); + t5 = t4._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["traceEvents", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map*(1)")._as(new Q.Timeline_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")), "timeOriginMicros", this.timeOriginMicros, "timeExtentMicros", this.timeExtentMicros], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[Timeline type: " + H.S(_this.type) + ", traceEvents: " + H.S(_this.traceEvents) + ", timeOriginMicros: " + H.S(_this.timeOriginMicros) + ", timeExtentMicros: " + H.S(_this.timeExtentMicros) + "]"; + }, + set$traceEvents: function(traceEvents) { + this.traceEvents = type$.legacy_List_legacy_TimelineEvent._as(traceEvents); + } + }; + Q.Timeline_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_TimelineEvent._as(f).toJson$0(); + }, + $signature: 24 + }; + Q.TimelineEvent.prototype = { + toJson$0: function() { + var result = P.LinkedHashMap_LinkedHashMap$of(this.json, type$.legacy_String, type$.dynamic); + result.$indexSet(0, "type", "TimelineEvent"); + return result; + }, + toString$0: function(_) { + return "[TimelineEvent ]"; + } + }; + Q.TimelineFlags.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, t7, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "TimelineFlags"); + t3 = this.recorderName; + t4 = this.availableStreams; + t4.toString; + t5 = H._arrayInstanceType(t4); + t6 = t5._eval$1("MappedListIterable<1,String*>"); + t6 = P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("String*(1)")._as(new Q.TimelineFlags_toJson_closure()), t6), true, t6._eval$1("ListIterable.E")); + t5 = this.recordedStreams; + t5.toString; + t4 = H._arrayInstanceType(t5); + t7 = t4._eval$1("MappedListIterable<1,String*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["recorderName", t3, "availableStreams", t6, "recordedStreams", P.List_List$from(new H.MappedListIterable(t5, t4._eval$1("String*(1)")._as(new Q.TimelineFlags_toJson_closure0()), t7), true, t7._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + var _this = this; + return "[TimelineFlags type: " + H.S(_this.type) + ", recorderName: " + H.S(_this.recorderName) + ", availableStreams: " + H.S(_this.availableStreams) + ", recordedStreams: " + H.S(_this.recordedStreams) + "]"; + }, + set$availableStreams: function(availableStreams) { + this.availableStreams = type$.legacy_List_legacy_String._as(availableStreams); + }, + set$recordedStreams: function(recordedStreams) { + this.recordedStreams = type$.legacy_List_legacy_String._as(recordedStreams); + } + }; + Q.TimelineFlags_toJson_closure.prototype = { + call$1: function(f) { + return H._asStringS(f); + }, + $signature: 5 + }; + Q.TimelineFlags_toJson_closure0.prototype = { + call$1: function(f) { + return H._asStringS(f); + }, + $signature: 5 + }; + Q.Timestamp.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Timestamp"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["timestamp", this.timestamp], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[Timestamp type: " + H.S(this.type) + ", timestamp: " + H.S(this.timestamp) + "]"; + } + }; + Q.TypeArgumentsRef.prototype = { + toJson$0: function() { + var json = this.super$ObjRef$toJson(); + json.$indexSet(0, "type", "@TypeArguments"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return type$.legacy_TypeArgumentsRef._is(other) && this.id == other.get$id(other); + }, + toString$0: function(_) { + return "[TypeArgumentsRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", name: " + H.S(this.name) + "]"; + } + }; + Q.TypeArguments.prototype = { + toJson$0: function() { + var t1, t2, t3, t4, + json = this.super$Obj$toJson(); + json.$indexSet(0, "type", "TypeArguments"); + t1 = this.name; + t2 = this.types; + t2.toString; + t3 = H._arrayInstanceType(t2); + t4 = t3._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t1, "types", P.List_List$from(new H.MappedListIterable(t2, t3._eval$1("Map*(1)")._as(new Q.TypeArguments_toJson_closure()), t4), true, t4._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic)); + return json; + }, + get$hashCode: function(_) { + return J.get$hashCode$(this.id); + }, + $eq: function(_, other) { + if (other == null) + return false; + return other instanceof Q.TypeArguments && this.id == other.id; + }, + toString$0: function(_) { + var _this = this; + return "[TypeArguments type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", types: " + H.S(_this.types) + "]"; + }, + set$types: function(types) { + this.types = type$.legacy_List_legacy_InstanceRef._as(types); + }, + $isTypeArgumentsRef: 1 + }; + Q.TypeArguments_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_InstanceRef._as(f).toJson$0(); + }, + $signature: 20 + }; + Q.UnresolvedSourceLocation.prototype = { + toJson$0: function() { + var t1, _this = this, + json = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic); + json.$indexSet(0, "type", "UnresolvedSourceLocation"); + t1 = _this.script; + Q._setIfNotNull(json, "script", t1 == null ? null : t1.toJson$0()); + Q._setIfNotNull(json, "scriptUri", _this.scriptUri); + Q._setIfNotNull(json, "tokenPos", _this.tokenPos); + Q._setIfNotNull(json, "line", _this.line); + Q._setIfNotNull(json, "column", _this.column); + return json; + }, + toString$0: function(_) { + return "[UnresolvedSourceLocation type: " + H.S(this.type) + "]"; + } + }; + Q.Version.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "Version"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["major", this.major, "minor", this.minor], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[Version type: " + H.S(this.type) + ", major: " + H.S(this.major) + ", minor: " + H.S(this.minor) + "]"; + } + }; + Q.VMRef.prototype = { + toJson$0: function() { + var t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "@VM"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[VMRef type: " + H.S(this.type) + ", name: " + H.S(this.name) + "]"; + } + }; + Q.VM.prototype = { + toJson$0: function() { + var t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, t14, _this = this, + t1 = type$.legacy_String, + t2 = type$.dynamic, + json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2); + json.$indexSet(0, "type", "VM"); + t3 = _this.name; + t4 = _this.architectureBits; + t5 = _this.hostCPU; + t6 = _this.operatingSystem; + t7 = _this.targetCPU; + t8 = _this.version; + t9 = _this.pid; + t10 = _this.startTime; + t11 = _this.isolates; + t11.toString; + t12 = H._arrayInstanceType(t11); + t13 = t12._eval$1("MappedListIterable<1,Map*>"); + t13 = P.List_List$from(new H.MappedListIterable(t11, t12._eval$1("Map*(1)")._as(new Q.VM_toJson_closure()), t13), true, t13._eval$1("ListIterable.E")); + t12 = _this.isolateGroups; + t12.toString; + t11 = H._arrayInstanceType(t12); + t14 = t11._eval$1("MappedListIterable<1,Map*>"); + json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t3, "architectureBits", t4, "hostCPU", t5, "operatingSystem", t6, "targetCPU", t7, "version", t8, "pid", t9, "startTime", t10, "isolates", t13, "isolateGroups", P.List_List$from(new H.MappedListIterable(t12, t11._eval$1("Map*(1)")._as(new Q.VM_toJson_closure0()), t14), true, t14._eval$1("ListIterable.E"))], t1, t2)); + return json; + }, + toString$0: function(_) { + return "[VM]"; + }, + set$isolates: function(isolates) { + this.isolates = type$.legacy_List_legacy_IsolateRef._as(isolates); + }, + set$isolateGroups: function(isolateGroups) { + this.isolateGroups = type$.legacy_List_legacy_IsolateGroupRef._as(isolateGroups); + }, + $isVMRef: 1 + }; + Q.VM_toJson_closure.prototype = { + call$1: function(f) { + return type$.legacy_IsolateRef._as(f).toJson$0(); + }, + $signature: 25 + }; + Q.VM_toJson_closure0.prototype = { + call$1: function(f) { + return type$.legacy_IsolateGroupRef._as(f).toJson$0(); + }, + $signature: 58 + }; + E.main_closure.prototype = { + call$1: function(e) { + var t1 = this.ddsChannel._outgoingController; + t1.add$1(0, H._instanceType(t1)._precomputed1._as(e)); + return null; + }, + $signature: 59 + }; + (function aliases() { + var _ = J.Interceptor.prototype; + _.super$Interceptor$noSuchMethod = _.noSuchMethod$1; + _ = J.JavaScriptObject.prototype; + _.super$JavaScriptObject$toString = _.toString$0; + _ = P._BroadcastStreamController.prototype; + _.super$_BroadcastStreamController$_addEventError = _._addEventError$0; + _ = P._BufferingStreamSubscription.prototype; + _.super$_BufferingStreamSubscription$_add = _._add$1; + _.super$_BufferingStreamSubscription$_addError = _._addError$2; + _ = Q.InstanceRef.prototype; + _.super$InstanceRef$toJson = _.toJson$0; + _ = Q.Instance.prototype; + _.super$Instance$toJson = _.toJson$0; + _ = Q.ObjRef.prototype; + _.super$ObjRef$toJson = _.toJson$0; + _ = Q.Obj.prototype; + _.super$Obj$toJson = _.toJson$0; + })(); + (function installTearOffs() { + var _static_1 = hunkHelpers._static_1, + _static_0 = hunkHelpers._static_0, + _static_2 = hunkHelpers._static_2, + _instance_0_u = hunkHelpers._instance_0u, + _instance = hunkHelpers.installInstanceTearOff, + _instance_2_u = hunkHelpers._instance_2u, + _instance_1_u = hunkHelpers._instance_1u; + _static_1(P, "async__AsyncRun__scheduleImmediateJsOverride$closure", "_AsyncRun__scheduleImmediateJsOverride", 6); + _static_1(P, "async__AsyncRun__scheduleImmediateWithSetImmediate$closure", "_AsyncRun__scheduleImmediateWithSetImmediate", 6); + _static_1(P, "async__AsyncRun__scheduleImmediateWithTimer$closure", "_AsyncRun__scheduleImmediateWithTimer", 6); + _static_0(P, "async___startMicrotaskLoop$closure", "_startMicrotaskLoop", 0); + _static_1(P, "async___nullDataHandler$closure", "_nullDataHandler", 2); + _static_2(P, "async___nullErrorHandler$closure", "_nullErrorHandler", 7); + var _; + _instance_0_u(_ = P._BroadcastSubscription.prototype, "get$_onPause", "_onPause$0", 0); + _instance_0_u(_, "get$_onResume", "_onResume$0", 0); + _instance(P._Completer.prototype, "get$completeError", 0, 1, null, ["call$2", "call$1"], ["completeError$2", "completeError$1"], 39, 0); + _instance_2_u(P._Future.prototype, "get$_completeError", "_completeError$2", 7); + _instance_0_u(_ = P._ControllerSubscription.prototype, "get$_onPause", "_onPause$0", 0); + _instance_0_u(_, "get$_onResume", "_onResume$0", 0); + _instance_0_u(_ = P._BufferingStreamSubscription.prototype, "get$_onPause", "_onPause$0", 0); + _instance_0_u(_, "get$_onResume", "_onResume$0", 0); + _instance_0_u(P._DoneStreamSubscription.prototype, "get$_sendDone", "_sendDone$0", 0); + _instance_1_u(_ = P._StreamIterator.prototype, "get$_async$_onData", "_async$_onData$1", 12); + _instance_2_u(_, "get$_onError", "_onError$2", 7); + _instance_0_u(_, "get$_onDone", "_onDone$0", 0); + _instance_0_u(_ = P._ForwardingStreamSubscription.prototype, "get$_onPause", "_onPause$0", 0); + _instance_0_u(_, "get$_onResume", "_onResume$0", 0); + _instance_1_u(_, "get$_handleData", "_handleData$1", 12); + _instance_2_u(_, "get$_handleError", "_handleError$2", 32); + _instance_0_u(_, "get$_handleDone", "_handleDone$0", 0); + _static_1(P, "convert___defaultToEncodable$closure", "_defaultToEncodable", 3); + _instance_1_u(_ = M.SseClient.prototype, "get$_onIncomingControlMessage", "_onIncomingControlMessage$1", 18); + _instance_1_u(_, "get$_onIncomingMessage", "_onIncomingMessage$1", 18); + _instance_0_u(_, "get$_onOutgoingDone", "_onOutgoingDone$0", 0); + _instance_1_u(_, "get$_onOutgoingMessage", "_onOutgoingMessage$1", 2); + _static_1(Q, "vm_service_ExtensionData_parse$closure", "ExtensionData_parse", 61); + _static_1(Q, "vm_service_AllocationProfile_parse$closure", "AllocationProfile_parse", 62); + _static_1(Q, "vm_service_BoundField_parse$closure", "BoundField_parse", 63); + _static_1(Q, "vm_service_BoundVariable_parse$closure", "BoundVariable_parse", 64); + _static_1(Q, "vm_service_Breakpoint_parse$closure", "Breakpoint_parse", 65); + _static_1(Q, "vm_service_ClassRef_parse$closure", "ClassRef_parse", 66); + _static_1(Q, "vm_service_Class_parse$closure", "Class_parse", 67); + _static_1(Q, "vm_service_ClassHeapStats_parse$closure", "ClassHeapStats_parse", 68); + _static_1(Q, "vm_service_ClassList_parse$closure", "ClassList_parse", 69); + _static_1(Q, "vm_service_ClientName_parse$closure", "ClientName_parse", 70); + _static_1(Q, "vm_service_CodeRef_parse$closure", "CodeRef_parse", 71); + _static_1(Q, "vm_service_Code_parse$closure", "Code_parse", 72); + _static_1(Q, "vm_service_ContextRef_parse$closure", "ContextRef_parse", 73); + _static_1(Q, "vm_service_Context_parse$closure", "Context_parse", 74); + _static_1(Q, "vm_service_ContextElement_parse$closure", "ContextElement_parse", 75); + _static_1(Q, "vm_service_CpuSamples_parse$closure", "CpuSamples_parse", 76); + _static_1(Q, "vm_service_CpuSample_parse$closure", "CpuSample_parse", 77); + _static_1(Q, "vm_service_ErrorRef_parse$closure", "ErrorRef_parse", 78); + _static_1(Q, "vm_service_Error_parse$closure", "Error_parse", 79); + _static_1(Q, "vm_service_Event_parse$closure", "Event_parse", 80); + _static_1(Q, "vm_service_FieldRef_parse$closure", "FieldRef_parse", 81); + _static_1(Q, "vm_service_Field_parse$closure", "Field_parse", 82); + _static_1(Q, "vm_service_Flag_parse$closure", "Flag_parse", 83); + _static_1(Q, "vm_service_FlagList_parse$closure", "FlagList_parse", 84); + _static_1(Q, "vm_service_Frame_parse$closure", "Frame_parse", 85); + _static_1(Q, "vm_service_FuncRef_parse$closure", "FuncRef_parse", 86); + _static_1(Q, "vm_service_Func_parse$closure", "Func_parse", 87); + _static_1(Q, "vm_service_InstanceRef_parse$closure", "InstanceRef_parse", 133); + _static_1(Q, "vm_service_Instance_parse$closure", "Instance_parse", 89); + _static_1(Q, "vm_service_IsolateRef_parse$closure", "IsolateRef_parse", 90); + _static_1(Q, "vm_service_Isolate_parse$closure", "Isolate_parse", 91); + _static_1(Q, "vm_service_IsolateGroupRef_parse$closure", "IsolateGroupRef_parse", 92); + _static_1(Q, "vm_service_IsolateGroup_parse$closure", "IsolateGroup_parse", 93); + _static_1(Q, "vm_service_InboundReferences_parse$closure", "InboundReferences_parse", 94); + _static_1(Q, "vm_service_InboundReference_parse$closure", "InboundReference_parse", 95); + _static_1(Q, "vm_service_InstanceSet_parse$closure", "InstanceSet_parse", 96); + _static_1(Q, "vm_service_LibraryRef_parse$closure", "LibraryRef_parse", 97); + _static_1(Q, "vm_service_Library_parse$closure", "Library_parse", 98); + _static_1(Q, "vm_service_LibraryDependency_parse$closure", "LibraryDependency_parse", 99); + _static_1(Q, "vm_service_LogRecord_parse$closure", "LogRecord_parse", 100); + _static_1(Q, "vm_service_MapAssociation_parse$closure", "MapAssociation_parse", 101); + _static_1(Q, "vm_service_MemoryUsage_parse$closure", "MemoryUsage_parse", 102); + _static_1(Q, "vm_service_Message_parse$closure", "Message_parse", 103); + _static_1(Q, "vm_service_NativeFunction_parse$closure", "NativeFunction_parse", 104); + _static_1(Q, "vm_service_NullValRef_parse$closure", "NullValRef_parse", 105); + _static_1(Q, "vm_service_NullVal_parse$closure", "NullVal_parse", 106); + _static_1(Q, "vm_service_ObjRef_parse$closure", "ObjRef_parse", 107); + _static_1(Q, "vm_service_Obj_parse$closure", "Obj_parse", 108); + _static_1(Q, "vm_service_ProfileFunction_parse$closure", "ProfileFunction_parse", 109); + _static_1(Q, "vm_service_ReloadReport_parse$closure", "ReloadReport_parse", 110); + _static_1(Q, "vm_service_RetainingObject_parse$closure", "RetainingObject_parse", 111); + _static_1(Q, "vm_service_RetainingPath_parse$closure", "RetainingPath_parse", 112); + _static_1(Q, "vm_service_Response_parse$closure", "Response_parse", 113); + _static_1(Q, "vm_service_Sentinel_parse$closure", "Sentinel_parse", 114); + _static_1(Q, "vm_service_ScriptRef_parse$closure", "ScriptRef_parse", 115); + _static_1(Q, "vm_service_Script_parse$closure", "Script_parse", 116); + _static_1(Q, "vm_service_ScriptList_parse$closure", "ScriptList_parse", 117); + _static_1(Q, "vm_service_SourceLocation_parse$closure", "SourceLocation_parse", 118); + _static_1(Q, "vm_service_SourceReport_parse$closure", "SourceReport_parse", 119); + _static_1(Q, "vm_service_SourceReportCoverage_parse$closure", "SourceReportCoverage_parse", 120); + _static_1(Q, "vm_service_SourceReportRange_parse$closure", "SourceReportRange_parse", 121); + _static_1(Q, "vm_service_Stack_parse$closure", "Stack_parse", 122); + _static_1(Q, "vm_service_Success_parse$closure", "Success_parse", 123); + _static_1(Q, "vm_service_Timeline_parse$closure", "Timeline_parse", 124); + _static_1(Q, "vm_service_TimelineEvent_parse$closure", "TimelineEvent_parse", 125); + _static_1(Q, "vm_service_TimelineFlags_parse$closure", "TimelineFlags_parse", 126); + _static_1(Q, "vm_service_Timestamp_parse$closure", "Timestamp_parse", 127); + _static_1(Q, "vm_service_TypeArgumentsRef_parse$closure", "TypeArgumentsRef_parse", 128); + _static_1(Q, "vm_service_TypeArguments_parse$closure", "TypeArguments_parse", 129); + _static_1(Q, "vm_service_UnresolvedSourceLocation_parse$closure", "UnresolvedSourceLocation_parse", 130); + _static_1(Q, "vm_service_Version_parse$closure", "Version_parse", 131); + _static_1(Q, "vm_service_VMRef_parse$closure", "VMRef_parse", 132); + _static_1(Q, "vm_service_VM_parse$closure", "VM_parse", 88); + _instance_1_u(Q.VmService.prototype, "get$_processMessage", "_processMessage$1", 2); + })(); + (function inheritance() { + var _mixin = hunkHelpers.mixin, + _inherit = hunkHelpers.inherit, + _inheritMany = hunkHelpers.inheritMany; + _inherit(P.Object, null); + _inheritMany(P.Object, [H.JS_CONST, J.Interceptor, J.JSObject, J.ArrayIterator, P.Iterable, H.ListIterator, P.Iterator, H.FixedLengthListMixin, H.Symbol, P.MapView, H.ConstantMap, H.Closure, H.JSInvocationMirror, H.TypeErrorDecoder, P.Error0, H.NullThrownFromJavaScriptException, H.ExceptionAndStackTrace, H._StackTrace, H._Required, P.MapMixin, H.LinkedHashMapCell, H.LinkedHashMapKeyIterator, H.Rti, H._FunctionParameters, H._Type, P._TimerImpl, P._AsyncAwaitCompleter, P._BufferingStreamSubscription, P._BroadcastStreamController, P.Future, P.Completer, P._Completer, P._FutureListener, P._Future, P._AsyncCallbackEntry, P.Stream, P.StreamSubscription, P.StreamTransformerBase, P.StreamController, P._StreamController, P._AsyncStreamControllerDispatch, P._StreamSinkWrapper, P._DelayedEvent, P._DelayedDone, P._PendingEvents, P._DoneStreamSubscription, P._StreamIterator, P.AsyncError, P._Zone, P._SetBase, P._LinkedHashSetCell, P._LinkedHashSetIterator, P.ListMixin, P._UnmodifiableMapMixin, P._ListQueueIterator, P.Codec, P._JsonStringifier, P._Utf8Decoder, P.bool, P.DateTime, P.num, P.Duration, P.OutOfMemoryError, P.StackOverflowError, P._Exception, P.FormatException, P.Function, P.List, P.Map, P.MapEntry, P.Null, P.StackTrace, P._StringStackTrace, P.String, P.StringBuffer, P.Symbol0, W.EventStreamProvider, P._AcceptStructuredClone, P._JSRandom, P.ByteBuffer, P.ByteData, P.Int8List, P.Uint8List, P.Uint8ClampedList, P.Int16List, P.Uint16List, P.Int32List, P.Uint32List, P.Float32List, P.Float64List, V.ErrorResult, E.Result, F.ValueResult, G.StreamQueue, G._EventRequest, G._NextRequest, Q._QueueList_Object_ListMixin, Y.Level, L.LogRecord0, F.Logger, R.StreamChannelMixin, K.Uuid, Q.VmService, Q.RPCError, Q.SentinelException, Q.ExtensionData, Q._NullLog, Q.Response, Q.BoundField, Q.ContextElement, Q.CpuSample, Q.Flag, Q.InboundReference, Q.LibraryDependency, Q.MapAssociation, Q.NativeFunction, Q.ProfileFunction, Q.RetainingObject, Q.SourceReportCoverage, Q.SourceReportRange, Q.TimelineEvent]); + _inheritMany(J.Interceptor, [J.JSBool, J.JSNull, J.JavaScriptObject, J.JSArray, J.JSNumber, J.JSString, H.NativeByteBuffer, H.NativeTypedData, W.DomException, W.Event0, W.EventTarget]); + _inheritMany(J.JavaScriptObject, [J.PlainJavaScriptObject, J.UnknownJavaScriptObject, J.JavaScriptFunction]); + _inherit(J.JSUnmodifiableArray, J.JSArray); + _inheritMany(J.JSNumber, [J.JSInt, J.JSDouble]); + _inheritMany(P.Iterable, [H.EfficientLengthIterable, H.MappedIterable, H._ConstantMapKeyIterable]); + _inheritMany(H.EfficientLengthIterable, [H.ListIterable, H.LinkedHashMapKeyIterable]); + _inherit(H.EfficientLengthMappedIterable, H.MappedIterable); + _inherit(H.MappedIterator, P.Iterator); + _inheritMany(H.ListIterable, [H.MappedListIterable, P.ListQueue, P._JsonMapKeyIterable]); + _inherit(P._UnmodifiableMapView_MapView__UnmodifiableMapMixin, P.MapView); + _inherit(P.UnmodifiableMapView, P._UnmodifiableMapView_MapView__UnmodifiableMapMixin); + _inherit(H.ConstantMapView, P.UnmodifiableMapView); + _inheritMany(H.Closure, [H.ConstantMap_map_closure, H.Primitives_functionNoSuchMethod_closure, H.TearOffClosure, H.JsLinkedHashMap_addAll_closure, H.initHooks_closure, H.initHooks_closure0, H.initHooks_closure1, P._AsyncRun__initializeScheduleImmediate_internalCallback, P._AsyncRun__initializeScheduleImmediate_closure, P._AsyncRun__scheduleImmediateJsOverride_internalCallback, P._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback, P._TimerImpl_internalCallback, P._awaitOnObject_closure, P._awaitOnObject_closure0, P._wrapJsFunctionForAsync_closure, P._SyncBroadcastStreamController__sendData_closure, P._Future__addListener_closure, P._Future__prependListeners_closure, P._Future__chainForeignFuture_closure, P._Future__chainForeignFuture_closure0, P._Future__chainForeignFuture_closure1, P._Future__asyncCompleteWithValue_closure, P._Future__chainFuture_closure, P._Future__asyncCompleteError_closure, P._Future__propagateToListeners_handleWhenCompleteCallback, P._Future__propagateToListeners_handleWhenCompleteCallback_closure, P._Future__propagateToListeners_handleValueCallback, P._Future__propagateToListeners_handleError, P.Stream_length_closure, P.Stream_length_closure0, P.Stream_first_closure, P.Stream_first_closure0, P._StreamController__subscribe_closure, P._StreamController__recordCancel_complete, P._BufferingStreamSubscription__sendError_sendError, P._BufferingStreamSubscription__sendDone_sendDone, P._PendingEvents_schedule_closure, P._cancelAndValue_closure, P._rootHandleUncaughtError_closure, P._RootZone_bindCallback_closure, P._RootZone_bindCallbackGuarded_closure, P._RootZone_bindUnaryCallbackGuarded_closure, P.MapBase_mapToString_closure, P.Utf8Decoder_closure, P.Utf8Decoder_closure0, P._JsonStringifier_writeMap_closure, P._symbolMapToStringMap_closure, P.NoSuchMethodError_toString_closure, P.Duration_toString_sixDigits, P.Duration_toString_twoDigits, W.HttpRequest_request_closure, W._EventStreamSubscription_closure, W._EventStreamSubscription_onData_closure, P._AcceptStructuredClone_walk_closure, P.convertDartToNative_Dictionary_closure, P.promiseToFuture_closure, P.promiseToFuture_closure0, G.StreamQueue__ensureListening_closure, G.StreamQueue__ensureListening_closure1, G.StreamQueue__ensureListening_closure0, F.Logger_Logger_closure, M.SseClient_closure, M.SseClient_closure0, M.SseClient__closure, Q.createServiceObject_closure, Q._createSpecificObject_closure, Q.VmService_closure, Q.AllocationProfile_toJson_closure, Q.Class_toJson_closure, Q.Class_toJson_closure0, Q.Class_toJson_closure1, Q.Class_toJson_closure2, Q.ClassList_toJson_closure, Q.Context_toJson_closure, Q.CpuSamples_toJson_closure, Q.CpuSamples_toJson_closure0, Q.CpuSample_toJson_closure, Q.Event_toJson_closure, Q.Event_toJson_closure0, Q.Event_toJson_closure1, Q.FlagList_toJson_closure, Q.Frame_toJson_closure, Q.Instance_toJson_closure, Q.Instance_toJson_closure0, Q.Instance_toJson_closure1, Q.Isolate_toJson_closure, Q.Isolate_toJson_closure0, Q.Isolate_toJson_closure1, Q.IsolateGroup_toJson_closure, Q.InboundReferences_toJson_closure, Q.InstanceSet_toJson_closure, Q.Library_toJson_closure, Q.Library_toJson_closure0, Q.Library_toJson_closure1, Q.Library_toJson_closure2, Q.Library_toJson_closure3, Q.RetainingPath_toJson_closure, Q.Script$_fromJson_closure, Q.Script_toJson_closure, Q.ScriptList_toJson_closure, Q.SourceReport_toJson_closure, Q.SourceReport_toJson_closure0, Q.SourceReportCoverage_toJson_closure, Q.SourceReportCoverage_toJson_closure0, Q.SourceReportRange_toJson_closure, Q.Stack_toJson_closure, Q.Stack_toJson_closure0, Q.Stack_toJson_closure1, Q.Stack_toJson_closure2, Q.Timeline_toJson_closure, Q.TimelineFlags_toJson_closure, Q.TimelineFlags_toJson_closure0, Q.TypeArguments_toJson_closure, Q.VM_toJson_closure, Q.VM_toJson_closure0, E.main_closure]); + _inherit(H.ConstantStringMap, H.ConstantMap); + _inheritMany(P.Error0, [H.NullError, H.JsNoSuchMethodError, H.UnknownJsTypeError, H.RuntimeError, P.AssertionError, H._Error, P.JsonUnsupportedObjectError, P.NullThrownError, P.ArgumentError, P.NoSuchMethodError, P.UnsupportedError, P.UnimplementedError, P.StateError, P.ConcurrentModificationError, P.CyclicInitializationError]); + _inheritMany(H.TearOffClosure, [H.StaticClosure, H.BoundClosure]); + _inherit(H._AssertionError, P.AssertionError); + _inherit(P.MapBase, P.MapMixin); + _inheritMany(P.MapBase, [H.JsLinkedHashMap, P._JsonMap]); + _inheritMany(H.NativeTypedData, [H.NativeByteData, H.NativeTypedArray]); + _inheritMany(H.NativeTypedArray, [H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin]); + _inherit(H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin); + _inherit(H.NativeTypedArrayOfDouble, H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin); + _inherit(H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin, H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin); + _inherit(H.NativeTypedArrayOfInt, H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin); + _inheritMany(H.NativeTypedArrayOfDouble, [H.NativeFloat32List, H.NativeFloat64List]); + _inheritMany(H.NativeTypedArrayOfInt, [H.NativeInt16List, H.NativeInt32List, H.NativeInt8List, H.NativeUint16List, H.NativeUint32List, H.NativeUint8ClampedList, H.NativeUint8List]); + _inherit(H._TypeError, H._Error); + _inheritMany(P._BufferingStreamSubscription, [P._ControllerSubscription, P._ForwardingStreamSubscription]); + _inherit(P._BroadcastSubscription, P._ControllerSubscription); + _inheritMany(P._BroadcastStreamController, [P._SyncBroadcastStreamController, P._AsyncBroadcastStreamController]); + _inherit(P._AsyncCompleter, P._Completer); + _inherit(P._AsyncStreamController, P._StreamController); + _inheritMany(P.Stream, [P._StreamImpl, P._ForwardingStream, W._EventStream]); + _inherit(P._ControllerStream, P._StreamImpl); + _inheritMany(P._DelayedEvent, [P._DelayedData, P._DelayedError]); + _inherit(P._StreamImplEvents, P._PendingEvents); + _inherit(P._MapStream, P._ForwardingStream); + _inherit(P._RootZone, P._Zone); + _inherit(P._LinkedHashSet, P._SetBase); + _inherit(P.Converter, P.StreamTransformerBase); + _inherit(P.JsonCyclicError, P.JsonUnsupportedObjectError); + _inheritMany(P.Codec, [P.JsonCodec, N.HexCodec]); + _inheritMany(P.Converter, [P.JsonEncoder, P.JsonDecoder, P.Utf8Decoder, R.HexEncoder]); + _inherit(P._JsonStringStringifier, P._JsonStringifier); + _inheritMany(P.num, [P.double, P.int]); + _inheritMany(P.ArgumentError, [P.RangeError, P.IndexError]); + _inheritMany(W.EventTarget, [W.EventSource, W.HttpRequestEventTarget]); + _inherit(W.HttpRequest, W.HttpRequestEventTarget); + _inheritMany(W.Event0, [W.MessageEvent, W.ProgressEvent]); + _inherit(W._EventStreamSubscription, P.StreamSubscription); + _inherit(P._AcceptStructuredCloneDart2Js, P._AcceptStructuredClone); + _inherit(Q.QueueList, Q._QueueList_Object_ListMixin); + _inherit(M.SseClient, R.StreamChannelMixin); + _inheritMany(Q.Response, [Q.AllocationProfile, Q.BoundVariable, Q.Obj, Q.ObjRef, Q.ClassHeapStats, Q.ClassList, Q.ClientName, Q.CpuSamples, Q.Event, Q.FlagList, Q.Frame, Q.IsolateRef, Q.Isolate, Q.IsolateGroupRef, Q.IsolateGroup, Q.InboundReferences, Q.InstanceSet, Q.LogRecord, Q.MemoryUsage, Q.Message, Q.ReloadReport, Q.RetainingPath, Q.Sentinel, Q.ScriptList, Q.SourceLocation, Q.SourceReport, Q.Stack, Q.Success, Q.Timeline, Q.TimelineFlags, Q.Timestamp, Q.UnresolvedSourceLocation, Q.Version, Q.VMRef, Q.VM]); + _inheritMany(Q.Obj, [Q.Breakpoint, Q.Class, Q.Context, Q.Error, Q.Field, Q.Func, Q.Instance, Q.Library, Q.Script, Q.TypeArguments]); + _inheritMany(Q.ObjRef, [Q.ClassRef, Q.CodeRef, Q.Code, Q.ContextRef, Q.ErrorRef, Q.FieldRef, Q.FuncRef, Q.InstanceRef, Q.LibraryRef, Q.ScriptRef, Q.TypeArgumentsRef]); + _inherit(Q.NullValRef, Q.InstanceRef); + _inherit(Q.NullVal, Q.Instance); + _mixin(H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, P.ListMixin); + _mixin(H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, H.FixedLengthListMixin); + _mixin(H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin, P.ListMixin); + _mixin(H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin, H.FixedLengthListMixin); + _mixin(P._AsyncStreamController, P._AsyncStreamControllerDispatch); + _mixin(P._UnmodifiableMapView_MapView__UnmodifiableMapMixin, P._UnmodifiableMapMixin); + _mixin(Q._QueueList_Object_ListMixin, P.ListMixin); + })(); + var init = { + typeUniverse: {eC: new Map(), tR: {}, eT: {}, tPV: {}, sEA: []}, + mangledGlobalNames: {int: "int", double: "double", num: "num", String: "String", bool: "bool", Null: "Null", List: "List"}, + mangledNames: {}, + getTypeFromName: getGlobalFromName, + metadata: [], + types: ["~()", "Null()", "~(@)", "@(@)", "int*(int*)", "String*(String*)", "~(~())", "~(Object,StackTrace)", "Map*(ClassRef*)", "Map*(ScriptRef*)", "Map*(Frame*)", "Null(@)", "~(Object?)", "Null(Object?,Object?)", "@()", "Null(Symbol0,@)", "String(int)", "@(Event0)", "~(Event0*)", "Null(Event0*)", "Map*(InstanceRef*)", "Map*(FieldRef*)", "Map*(FuncRef*)", "Map*(Breakpoint*)", "Map*(TimelineEvent*)", "Map*(IsolateRef*)", "Map*(BoundField*)", "Null(Object,StackTrace)", "_Future<@>(@)", "Object*(@)", "Map*(ClassHeapStats*)", "@(@,String)", "~(@,StackTrace)", "Null(~())", "Null(@,StackTrace)", "Map*(ContextElement*)", "Map*(ProfileFunction*)", "Map*(CpuSample*)", "Null(int,@)", "~(Object[StackTrace?])", "Null(ProgressEvent)", "@(String)", "Map*(Flag*)", "Map*(BoundVariable*)", "Null(String,@)", "Map*(MapAssociation*)", "Map*(LibraryRef*)", "@(@,@)", "Map*(InboundReference*)", "Map*(ObjRef*)", "Map*(LibraryDependency*)", "Null(@,@)", "Map*(RetainingObject*)", "List*(@)", "List*(List*)", "Map*(SourceReportRange*)", "Null(@,StackTrace*)", "Map*(Message*)", "Map*(IsolateGroupRef*)", "~(String*)", "Logger*()", "ExtensionData*(Map<@,@>*)", "AllocationProfile*(Map*)", "BoundField*(Map*)", "BoundVariable*(Map*)", "Breakpoint*(Map*)", "ClassRef*(Map*)", "Class*(Map*)", "ClassHeapStats*(Map*)", "ClassList*(Map*)", "ClientName*(Map*)", "CodeRef*(Map*)", "Code*(Map*)", "ContextRef*(Map*)", "Context*(Map*)", "ContextElement*(Map*)", "CpuSamples*(Map*)", "CpuSample*(Map*)", "ErrorRef*(Map*)", "Error*(Map*)", "Event*(Map*)", "FieldRef*(Map*)", "Field*(Map*)", "Flag*(Map*)", "FlagList*(Map*)", "Frame*(Map*)", "FuncRef*(Map*)", "Func*(Map*)", "VM*(Map*)", "Instance*(Map*)", "IsolateRef*(Map*)", "Isolate*(Map*)", "IsolateGroupRef*(Map*)", "IsolateGroup*(Map*)", "InboundReferences*(Map*)", "InboundReference*(Map*)", "InstanceSet*(Map*)", "LibraryRef*(Map*)", "Library*(Map*)", "LibraryDependency*(Map*)", "LogRecord*(Map*)", "MapAssociation*(Map*)", "MemoryUsage*(Map*)", "Message*(Map*)", "NativeFunction*(Map*)", "NullValRef*(Map*)", "NullVal*(Map*)", "ObjRef*(Map*)", "Obj*(Map*)", "ProfileFunction*(Map*)", "ReloadReport*(Map*)", "RetainingObject*(Map*)", "RetainingPath*(Map*)", "Response*(Map*)", "Sentinel*(Map*)", "ScriptRef*(Map*)", "Script*(Map*)", "ScriptList*(Map*)", "SourceLocation*(Map*)", "SourceReport*(Map*)", "SourceReportCoverage*(Map*)", "SourceReportRange*(Map*)", "Stack*(Map*)", "Success*(Map*)", "Timeline*(Map*)", "TimelineEvent*(Map*)", "TimelineFlags*(Map*)", "Timestamp*(Map*)", "TypeArgumentsRef*(Map*)", "TypeArguments*(Map*)", "UnresolvedSourceLocation*(Map*)", "Version*(Map*)", "VMRef*(Map*)", "InstanceRef*(Map*)"], + interceptorsByTag: null, + leafTags: null, + arrayRti: typeof Symbol == "function" && typeof Symbol() == "symbol" ? Symbol("$ti") : "$ti" + }; + H._Universe_addRules(init.typeUniverse, JSON.parse('{"JavaScriptFunction":"JavaScriptObject","PlainJavaScriptObject":"JavaScriptObject","UnknownJavaScriptObject":"JavaScriptObject","AbortPaymentEvent":"Event0","ExtendableEvent":"Event0","_ResourceProgressEvent":"ProgressEvent","MessagePort":"EventTarget","JSBool":{"bool":[]},"JSNull":{"Null":[]},"JavaScriptObject":{"Function":[]},"JSArray":{"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"JSIndexable":["1"]},"JSUnmodifiableArray":{"JSArray":["1"],"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"JSIndexable":["1"]},"ArrayIterator":{"Iterator":["1"]},"JSNumber":{"double":[],"num":[]},"JSInt":{"double":[],"int":[],"num":[]},"JSDouble":{"double":[],"num":[]},"JSString":{"String":[],"Pattern":[],"JSIndexable":["@"]},"EfficientLengthIterable":{"Iterable":["1"]},"ListIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"ListIterator":{"Iterator":["1"]},"MappedIterable":{"Iterable":["2"],"Iterable.E":"2"},"EfficientLengthMappedIterable":{"MappedIterable":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"MappedIterator":{"Iterator":["2"]},"MappedListIterable":{"ListIterable":["2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"ListIterable.E":"2","Iterable.E":"2"},"Symbol":{"Symbol0":[]},"ConstantMapView":{"UnmodifiableMapView":["1","2"],"_UnmodifiableMapView_MapView__UnmodifiableMapMixin":["1","2"],"MapView":["1","2"],"_UnmodifiableMapMixin":["1","2"],"Map":["1","2"]},"ConstantMap":{"Map":["1","2"]},"ConstantStringMap":{"ConstantMap":["1","2"],"Map":["1","2"]},"_ConstantMapKeyIterable":{"Iterable":["1"],"Iterable.E":"1"},"JSInvocationMirror":{"Invocation":[]},"NullError":{"Error0":[]},"JsNoSuchMethodError":{"Error0":[]},"UnknownJsTypeError":{"Error0":[]},"_StackTrace":{"StackTrace":[]},"Closure":{"Function":[]},"TearOffClosure":{"Function":[]},"StaticClosure":{"Function":[]},"BoundClosure":{"Function":[]},"RuntimeError":{"Error0":[]},"_AssertionError":{"Error0":[]},"JsLinkedHashMap":{"MapMixin":["1","2"],"LinkedHashMap":["1","2"],"Map":["1","2"],"MapMixin.K":"1","MapMixin.V":"2"},"LinkedHashMapKeyIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"LinkedHashMapKeyIterator":{"Iterator":["1"]},"NativeByteData":{"ByteData":[]},"NativeTypedArray":{"JavaScriptIndexingBehavior":["1"],"JSIndexable":["1"]},"NativeTypedArrayOfDouble":{"ListMixin":["double"],"JavaScriptIndexingBehavior":["double"],"List":["double"],"EfficientLengthIterable":["double"],"JSIndexable":["double"],"Iterable":["double"],"FixedLengthListMixin":["double"]},"NativeTypedArrayOfInt":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"]},"NativeFloat32List":{"ListMixin":["double"],"JavaScriptIndexingBehavior":["double"],"List":["double"],"EfficientLengthIterable":["double"],"JSIndexable":["double"],"Iterable":["double"],"FixedLengthListMixin":["double"],"ListMixin.E":"double"},"NativeFloat64List":{"ListMixin":["double"],"JavaScriptIndexingBehavior":["double"],"List":["double"],"EfficientLengthIterable":["double"],"JSIndexable":["double"],"Iterable":["double"],"FixedLengthListMixin":["double"],"ListMixin.E":"double"},"NativeInt16List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeInt32List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeInt8List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint16List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint32List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint8ClampedList":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint8List":{"ListMixin":["int"],"Uint8List":[],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"_Error":{"Error0":[]},"_TypeError":{"Error0":[]},"_TimerImpl":{"Timer":[]},"_AsyncAwaitCompleter":{"Completer":["1"]},"_BroadcastSubscription":{"_ControllerSubscription":["1"],"_BufferingStreamSubscription":["1"],"StreamSubscription":["1"],"_EventSink":["1"],"_EventDispatch":["1"],"_BufferingStreamSubscription.T":"1"},"_BroadcastStreamController":{"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_SyncBroadcastStreamController":{"_BroadcastStreamController":["1"],"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_AsyncBroadcastStreamController":{"_BroadcastStreamController":["1"],"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_Completer":{"Completer":["1"]},"_AsyncCompleter":{"_Completer":["1"],"Completer":["1"]},"_Future":{"Future":["1"]},"_StreamController":{"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_AsyncStreamController":{"_AsyncStreamControllerDispatch":["1"],"_StreamController":["1"],"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_ControllerStream":{"_StreamImpl":["1"],"Stream":["1"],"Stream.T":"1"},"_ControllerSubscription":{"_BufferingStreamSubscription":["1"],"StreamSubscription":["1"],"_EventSink":["1"],"_EventDispatch":["1"],"_BufferingStreamSubscription.T":"1"},"_BufferingStreamSubscription":{"StreamSubscription":["1"],"_EventSink":["1"],"_EventDispatch":["1"],"_BufferingStreamSubscription.T":"1"},"_StreamImpl":{"Stream":["1"]},"_DelayedData":{"_DelayedEvent":["1"]},"_DelayedError":{"_DelayedEvent":["@"]},"_DelayedDone":{"_DelayedEvent":["@"]},"_StreamImplEvents":{"_PendingEvents":["1"]},"_DoneStreamSubscription":{"StreamSubscription":["1"]},"_ForwardingStream":{"Stream":["2"]},"_ForwardingStreamSubscription":{"_BufferingStreamSubscription":["2"],"StreamSubscription":["2"],"_EventSink":["2"],"_EventDispatch":["2"],"_BufferingStreamSubscription.T":"2"},"_MapStream":{"_ForwardingStream":["1","2"],"Stream":["2"],"Stream.T":"2"},"AsyncError":{"Error0":[]},"_Zone":{"Zone":[]},"_RootZone":{"_Zone":[],"Zone":[]},"_LinkedHashSet":{"_SetBase":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"_LinkedHashSetIterator":{"Iterator":["1"]},"MapBase":{"MapMixin":["1","2"],"Map":["1","2"]},"MapMixin":{"Map":["1","2"]},"MapView":{"Map":["1","2"]},"UnmodifiableMapView":{"_UnmodifiableMapView_MapView__UnmodifiableMapMixin":["1","2"],"MapView":["1","2"],"_UnmodifiableMapMixin":["1","2"],"Map":["1","2"]},"ListQueue":{"ListIterable":["1"],"Queue":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"ListIterable.E":"1","Iterable.E":"1"},"_ListQueueIterator":{"Iterator":["1"]},"_SetBase":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"_JsonMap":{"MapMixin":["String","@"],"Map":["String","@"],"MapMixin.K":"String","MapMixin.V":"@"},"_JsonMapKeyIterable":{"ListIterable":["String"],"EfficientLengthIterable":["String"],"Iterable":["String"],"ListIterable.E":"String","Iterable.E":"String"},"JsonUnsupportedObjectError":{"Error0":[]},"JsonCyclicError":{"Error0":[]},"JsonCodec":{"Codec":["Object?","String"],"Codec.S":"Object?"},"JsonEncoder":{"Converter":["Object?","String"]},"JsonDecoder":{"Converter":["String","Object?"]},"Utf8Decoder":{"Converter":["List","String"]},"double":{"num":[]},"AssertionError":{"Error0":[]},"NullThrownError":{"Error0":[]},"ArgumentError":{"Error0":[]},"RangeError":{"Error0":[]},"IndexError":{"Error0":[]},"NoSuchMethodError":{"Error0":[]},"UnsupportedError":{"Error0":[]},"UnimplementedError":{"Error0":[]},"StateError":{"Error0":[]},"ConcurrentModificationError":{"Error0":[]},"OutOfMemoryError":{"Error0":[]},"StackOverflowError":{"Error0":[]},"CyclicInitializationError":{"Error0":[]},"int":{"num":[]},"List":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"_StringStackTrace":{"StackTrace":[]},"String":{"Pattern":[]},"StringBuffer":{"StringSink":[]},"EventSource":{"EventTarget":[]},"HttpRequest":{"EventTarget":[]},"HttpRequestEventTarget":{"EventTarget":[]},"MessageEvent":{"Event0":[]},"ProgressEvent":{"Event0":[]},"_EventStream":{"Stream":["1"],"Stream.T":"1"},"_EventStreamSubscription":{"StreamSubscription":["1"]},"Int8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8ClampedList":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Float32List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"Float64List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"ErrorResult":{"Result":["Null"]},"ValueResult":{"Result":["1*"]},"_NextRequest":{"_EventRequest":["1*"]},"QueueList":{"ListMixin":["1*"],"List":["1*"],"Queue":["1*"],"EfficientLengthIterable":["1*"],"Iterable":["1*"],"ListMixin.E":"1*"},"HexCodec":{"Codec":["List*","String*"],"Codec.S":"List*"},"HexEncoder":{"Converter":["List*","String*"]},"_NullLog":{"Log":[]},"Breakpoint":{"ObjRef":[]},"ClassRef":{"ObjRef":[]},"Class":{"ClassRef":[],"ObjRef":[]},"CodeRef":{"ObjRef":[]},"Code":{"CodeRef":[],"ObjRef":[]},"ContextRef":{"ObjRef":[]},"Context":{"ContextRef":[],"ObjRef":[]},"ErrorRef":{"ObjRef":[]},"Error":{"ErrorRef":[],"ObjRef":[]},"FieldRef":{"ObjRef":[]},"Field":{"FieldRef":[],"ObjRef":[]},"FuncRef":{"ObjRef":[]},"Func":{"FuncRef":[],"ObjRef":[]},"InstanceRef":{"ObjRef":[]},"Instance":{"InstanceRef":[],"ObjRef":[]},"Isolate":{"IsolateRef":[]},"IsolateGroup":{"IsolateGroupRef":[]},"LibraryRef":{"ObjRef":[]},"Library":{"LibraryRef":[],"ObjRef":[]},"NullValRef":{"InstanceRef":[],"ObjRef":[]},"NullVal":{"NullValRef":[],"InstanceRef":[],"ObjRef":[]},"Obj":{"ObjRef":[]},"ScriptRef":{"ObjRef":[]},"Script":{"ScriptRef":[],"ObjRef":[]},"TypeArgumentsRef":{"ObjRef":[]},"TypeArguments":{"TypeArgumentsRef":[],"ObjRef":[]},"VM":{"VMRef":[]}}')); + H._Universe_addErasedTypes(init.typeUniverse, JSON.parse('{"EfficientLengthIterable":1,"NativeTypedArray":1,"StreamTransformerBase":2,"MapBase":2,"MapEntry":2,"_QueueList_Object_ListMixin":1,"StreamChannelMixin":1}')); + var type$ = (function rtii() { + var findType = H.findType; + return { + $env_1_1_void: findType("@<~>"), + AsyncError: findType("AsyncError"), + ConstantMapView_Symbol_dynamic: findType("ConstantMapView"), + Duration: findType("Duration"), + EfficientLengthIterable_dynamic: findType("EfficientLengthIterable<@>"), + Error: findType("Error0"), + Event: findType("Event0"), + Function: findType("Function"), + Future_dynamic: findType("Future<@>"), + Future_void: findType("Future<~>"), + HexCodec: findType("HexCodec"), + Invocation: findType("Invocation"), + Iterable_dynamic: findType("Iterable<@>"), + JSArray_String: findType("JSArray"), + JSArray_dynamic: findType("JSArray<@>"), + JSArray_int: findType("JSArray"), + JSArray_legacy_Result_legacy_String: findType("JSArray*>"), + JSArray_legacy_String: findType("JSArray"), + JSArray_legacy_int: findType("JSArray"), + JSIndexable_dynamic: findType("JSIndexable<@>"), + JSNull: findType("JSNull"), + JavaScriptFunction: findType("JavaScriptFunction"), + JavaScriptIndexingBehavior_dynamic: findType("JavaScriptIndexingBehavior<@>"), + JsLinkedHashMap_String_dynamic: findType("JsLinkedHashMap"), + JsLinkedHashMap_Symbol_dynamic: findType("JsLinkedHashMap"), + JsLinkedHashMap_of_legacy_String_and_dynamic: findType("JsLinkedHashMap"), + JsLinkedHashMap_of_legacy_String_and_legacy_int: findType("JsLinkedHashMap"), + ListQueue_legacy__EventRequest_dynamic: findType("ListQueue<_EventRequest<@>*>"), + List_dynamic: findType("List<@>"), + List_int: findType("List"), + Map_dynamic_dynamic: findType("Map<@,@>"), + Null: findType("Null"), + Object: findType("Object"), + ProgressEvent: findType("ProgressEvent"), + QueueList_legacy_Result_legacy_String: findType("QueueList*>"), + StackTrace: findType("StackTrace"), + StreamQueue_legacy_String: findType("StreamQueue"), + Stream_dynamic: findType("Stream<@>"), + String: findType("String"), + Symbol: findType("Symbol0"), + UnknownJavaScriptObject: findType("UnknownJavaScriptObject"), + _AsyncCompleter_HttpRequest: findType("_AsyncCompleter"), + _AsyncCompleter_dynamic: findType("_AsyncCompleter<@>"), + _AsyncCompleter_legacy_Version: findType("_AsyncCompleter"), + _EventStream_legacy_Event: findType("_EventStream"), + _Future_HttpRequest: findType("_Future"), + _Future_bool: findType("_Future"), + _Future_dynamic: findType("_Future<@>"), + _Future_int: findType("_Future"), + _Future_legacy_Version: findType("_Future"), + _Future_void: findType("_Future<~>"), + _StreamControllerAddStreamState_nullable_Object: findType("_StreamControllerAddStreamState"), + _StreamIterator_dynamic: findType("_StreamIterator<@>"), + bool: findType("bool"), + bool_Function_Object: findType("bool(Object)"), + double: findType("double"), + dynamic: findType("@"), + dynamic_Function: findType("@()"), + dynamic_Function_Object: findType("@(Object)"), + dynamic_Function_Object_StackTrace: findType("@(Object,StackTrace)"), + dynamic_Function_dynamic_dynamic: findType("@(@,@)"), + int: findType("int"), + legacy_BoundField: findType("BoundField*"), + legacy_BoundVariable: findType("BoundVariable*"), + legacy_Breakpoint: findType("Breakpoint*"), + legacy_ByteData: findType("ByteData*"), + legacy_ClassHeapStats: findType("ClassHeapStats*"), + legacy_ClassRef: findType("ClassRef*"), + legacy_CodeRef: findType("CodeRef*"), + legacy_Completer_dynamic: findType("Completer<@>*"), + legacy_Context: findType("Context*"), + legacy_ContextElement: findType("ContextElement*"), + legacy_ContextRef: findType("ContextRef*"), + legacy_CpuSample: findType("CpuSample*"), + legacy_Error: findType("Error*"), + legacy_ErrorRef: findType("ErrorRef*"), + legacy_Event: findType("Event*"), + legacy_Event_2: findType("Event0*"), + legacy_FieldRef: findType("FieldRef*"), + legacy_Flag: findType("Flag*"), + legacy_Frame: findType("Frame*"), + legacy_FuncRef: findType("FuncRef*"), + legacy_InboundReference: findType("InboundReference*"), + legacy_InstanceRef: findType("InstanceRef*"), + legacy_IsolateGroupRef: findType("IsolateGroupRef*"), + legacy_IsolateRef: findType("IsolateRef*"), + legacy_Level: findType("Level*"), + legacy_LibraryDependency: findType("LibraryDependency*"), + legacy_LibraryRef: findType("LibraryRef*"), + legacy_List_dynamic: findType("List<@>*"), + legacy_List_legacy_BoundField: findType("List*"), + legacy_List_legacy_BoundVariable: findType("List*"), + legacy_List_legacy_Breakpoint: findType("List*"), + legacy_List_legacy_ClassHeapStats: findType("List*"), + legacy_List_legacy_ClassRef: findType("List*"), + legacy_List_legacy_ContextElement: findType("List*"), + legacy_List_legacy_CpuSample: findType("List*"), + legacy_List_legacy_FieldRef: findType("List*"), + legacy_List_legacy_Flag: findType("List*"), + legacy_List_legacy_Frame: findType("List*"), + legacy_List_legacy_FuncRef: findType("List*"), + legacy_List_legacy_InboundReference: findType("List*"), + legacy_List_legacy_InstanceRef: findType("List*"), + legacy_List_legacy_IsolateGroupRef: findType("List*"), + legacy_List_legacy_IsolateRef: findType("List*"), + legacy_List_legacy_LibraryDependency: findType("List*"), + legacy_List_legacy_LibraryRef: findType("List*"), + legacy_List_legacy_List_legacy_int: findType("List*>*"), + legacy_List_legacy_MapAssociation: findType("List*"), + legacy_List_legacy_Message: findType("List*"), + legacy_List_legacy_ObjRef: findType("List*"), + legacy_List_legacy_ProfileFunction: findType("List*"), + legacy_List_legacy_RetainingObject: findType("List*"), + legacy_List_legacy_ScriptRef: findType("List*"), + legacy_List_legacy_SourceReportRange: findType("List*"), + legacy_List_legacy_String: findType("List*"), + legacy_List_legacy_TimelineEvent: findType("List*"), + legacy_List_legacy_int: findType("List*"), + legacy_LogRecord: findType("LogRecord*"), + legacy_Logger: findType("Logger*"), + legacy_MapAssociation: findType("MapAssociation*"), + legacy_Map_dynamic_dynamic: findType("Map<@,@>*"), + legacy_Map_of_legacy_String_and_dynamic: findType("Map*"), + legacy_Map_of_legacy_String_and_legacy_int: findType("Map*"), + legacy_Map_of_legacy_Symbol_and_dynamic: findType("Map*"), + legacy_MemoryUsage: findType("MemoryUsage*"), + legacy_Message: findType("Message*"), + legacy_MessageEvent: findType("MessageEvent*"), + legacy_Never: findType("0&*"), + legacy_NullValRef: findType("NullValRef*"), + legacy_ObjRef: findType("ObjRef*"), + legacy_Object: findType("Object*"), + legacy_ProfileFunction: findType("ProfileFunction*"), + legacy_ProgressEvent: findType("ProgressEvent*"), + legacy_RetainingObject: findType("RetainingObject*"), + legacy_ScriptRef: findType("ScriptRef*"), + legacy_SourceLocation: findType("SourceLocation*"), + legacy_SourceReportCoverage: findType("SourceReportCoverage*"), + legacy_SourceReportRange: findType("SourceReportRange*"), + legacy_StackTrace: findType("StackTrace*"), + legacy_StreamController_legacy_Event: findType("StreamController*"), + legacy_String: findType("String*"), + legacy_TimelineEvent: findType("TimelineEvent*"), + legacy_TypeArgumentsRef: findType("TypeArgumentsRef*"), + legacy_VMRef: findType("VMRef*"), + legacy_int: findType("int*"), + legacy_legacy_Future_dynamic_Function: findType("Future<@>*()*"), + legacy_legacy_Future_legacy_Map_of_legacy_String_and_dynamic_Function_legacy_Map_of_legacy_String_and_dynamic: findType("Future*>*(Map*)*"), + nullable_Future_Null: findType("Future?"), + nullable_List_dynamic: findType("List<@>?"), + nullable_Object: findType("Object?"), + nullable__DelayedEvent_dynamic: findType("_DelayedEvent<@>?"), + nullable__EventRequest_dynamic: findType("_EventRequest<@>?"), + nullable__FutureListener_dynamic_dynamic: findType("_FutureListener<@,@>?"), + nullable__LinkedHashSetCell: findType("_LinkedHashSetCell?"), + nullable_dynamic_Function_Event: findType("@(Event0)?"), + nullable_nullable_Object_Function_2_nullable_Object_and_nullable_Object: findType("Object?(Object?,Object?)?"), + nullable_nullable_Object_Function_dynamic: findType("Object?(@)?"), + nullable_void_Function: findType("~()?"), + nullable_void_Function_legacy_Event: findType("~(Event0*)?"), + nullable_void_Function_legacy_ProgressEvent: findType("~(ProgressEvent*)?"), + num: findType("num"), + void: findType("~"), + void_Function: findType("~()"), + void_Function_Object: findType("~(Object)"), + void_Function_Object_StackTrace: findType("~(Object,StackTrace)"), + void_Function_String_dynamic: findType("~(String,@)") + }; + })(); + (function constants() { + var makeConstList = hunkHelpers.makeConstList; + C.EventSource_methods = W.EventSource.prototype; + C.HttpRequest_methods = W.HttpRequest.prototype; + C.Interceptor_methods = J.Interceptor.prototype; + C.JSArray_methods = J.JSArray.prototype; + C.JSDouble_methods = J.JSDouble.prototype; + C.JSInt_methods = J.JSInt.prototype; + C.JSNull_methods = J.JSNull.prototype; + C.JSNumber_methods = J.JSNumber.prototype; + C.JSString_methods = J.JSString.prototype; + C.JavaScriptFunction_methods = J.JavaScriptFunction.prototype; + C.NativeByteData_methods = H.NativeByteData.prototype; + C.PlainJavaScriptObject_methods = J.PlainJavaScriptObject.prototype; + C.UnknownJavaScriptObject_methods = J.UnknownJavaScriptObject.prototype; + C.C_HexCodec = new N.HexCodec(); + C.C_HexEncoder = new R.HexEncoder(); + C.C_JS_CONST = function getTagFallback(o) { + var s = Object.prototype.toString.call(o); + return s.substring(8, s.length - 1); +}; + C.C_JS_CONST0 = function() { + var toStringFunction = Object.prototype.toString; + function getTag(o) { + var s = toStringFunction.call(o); + return s.substring(8, s.length - 1); + } + function getUnknownTag(object, tag) { + if (/^HTML[A-Z].*Element$/.test(tag)) { + var name = toStringFunction.call(object); + if (name == "[object Object]") return null; + return "HTMLElement"; + } + } + function getUnknownTagGenericBrowser(object, tag) { + if (self.HTMLElement && object instanceof HTMLElement) return "HTMLElement"; + return getUnknownTag(object, tag); + } + function prototypeForTag(tag) { + if (typeof window == "undefined") return null; + if (typeof window[tag] == "undefined") return null; + var constructor = window[tag]; + if (typeof constructor != "function") return null; + return constructor.prototype; + } + function discriminator(tag) { return null; } + var isBrowser = typeof navigator == "object"; + return { + getTag: getTag, + getUnknownTag: isBrowser ? getUnknownTagGenericBrowser : getUnknownTag, + prototypeForTag: prototypeForTag, + discriminator: discriminator }; +}; + C.C_JS_CONST6 = function(getTagFallback) { + return function(hooks) { + if (typeof navigator != "object") return hooks; + var ua = navigator.userAgent; + if (ua.indexOf("DumpRenderTree") >= 0) return hooks; + if (ua.indexOf("Chrome") >= 0) { + function confirm(p) { + return typeof window == "object" && window[p] && window[p].name == p; + } + if (confirm("Window") && confirm("HTMLElement")) return hooks; + } + hooks.getTag = getTagFallback; + }; +}; + C.C_JS_CONST1 = function(hooks) { + if (typeof dartExperimentalFixupGetTag != "function") return hooks; + hooks.getTag = dartExperimentalFixupGetTag(hooks.getTag); +}; + C.C_JS_CONST2 = function(hooks) { + var getTag = hooks.getTag; + var prototypeForTag = hooks.prototypeForTag; + function getTagFixed(o) { + var tag = getTag(o); + if (tag == "Document") { + if (!!o.xmlVersion) return "!Document"; + return "!HTMLDocument"; + } + return tag; + } + function prototypeForTagFixed(tag) { + if (tag == "Document") return null; + return prototypeForTag(tag); + } + hooks.getTag = getTagFixed; + hooks.prototypeForTag = prototypeForTagFixed; +}; + C.C_JS_CONST5 = function(hooks) { + var userAgent = typeof navigator == "object" ? navigator.userAgent : ""; + if (userAgent.indexOf("Firefox") == -1) return hooks; + var getTag = hooks.getTag; + var quickMap = { + "BeforeUnloadEvent": "Event", + "DataTransfer": "Clipboard", + "GeoGeolocation": "Geolocation", + "Location": "!Location", + "WorkerMessageEvent": "MessageEvent", + "XMLDocument": "!Document"}; + function getTagFirefox(o) { + var tag = getTag(o); + return quickMap[tag] || tag; + } + hooks.getTag = getTagFirefox; +}; + C.C_JS_CONST4 = function(hooks) { + var userAgent = typeof navigator == "object" ? navigator.userAgent : ""; + if (userAgent.indexOf("Trident/") == -1) return hooks; + var getTag = hooks.getTag; + var quickMap = { + "BeforeUnloadEvent": "Event", + "DataTransfer": "Clipboard", + "HTMLDDElement": "HTMLElement", + "HTMLDTElement": "HTMLElement", + "HTMLPhraseElement": "HTMLElement", + "Position": "Geoposition" + }; + function getTagIE(o) { + var tag = getTag(o); + var newTag = quickMap[tag]; + if (newTag) return newTag; + if (tag == "Object") { + if (window.DataView && (o instanceof window.DataView)) return "DataView"; + } + return tag; + } + function prototypeForTagIE(tag) { + var constructor = window[tag]; + if (constructor == null) return null; + return constructor.prototype; + } + hooks.getTag = getTagIE; + hooks.prototypeForTag = prototypeForTagIE; +}; + C.C_JS_CONST3 = function(hooks) { return hooks; } +; + C.C_JsonCodec = new P.JsonCodec(); + C.C_OutOfMemoryError = new P.OutOfMemoryError(); + C.C__DelayedDone = new P._DelayedDone(); + C.C__JSRandom = new P._JSRandom(); + C.C__Required = new H._Required(); + C.C__RootZone = new P._RootZone(); + C.C__StringStackTrace = new P._StringStackTrace(); + C.Duration_0 = new P.Duration(0); + C.Duration_5000000 = new P.Duration(5000000); + C.JsonDecoder_null = new P.JsonDecoder(null); + C.JsonEncoder_null = new P.JsonEncoder(null); + C.Level_INFO_800 = new Y.Level("INFO", 800); + C.Level_WARNING_900 = new Y.Level("WARNING", 900); + C.List_AllocationProfile = H.setRuntimeTypeInfo(makeConstList(["AllocationProfile"]), type$.JSArray_legacy_String); + C.List_BoundField = H.setRuntimeTypeInfo(makeConstList(["BoundField"]), type$.JSArray_legacy_String); + C.List_BoundVariable = H.setRuntimeTypeInfo(makeConstList(["BoundVariable"]), type$.JSArray_legacy_String); + C.List_Breakpoint = H.setRuntimeTypeInfo(makeConstList(["Breakpoint"]), type$.JSArray_legacy_String); + C.List_ClassHeapStats = H.setRuntimeTypeInfo(makeConstList(["ClassHeapStats"]), type$.JSArray_legacy_String); + C.List_ClassList = H.setRuntimeTypeInfo(makeConstList(["ClassList"]), type$.JSArray_legacy_String); + C.List_ClassRef = H.setRuntimeTypeInfo(makeConstList(["ClassRef"]), type$.JSArray_legacy_String); + C.List_ClientName = H.setRuntimeTypeInfo(makeConstList(["ClientName"]), type$.JSArray_legacy_String); + C.List_CodeRef = H.setRuntimeTypeInfo(makeConstList(["CodeRef"]), type$.JSArray_legacy_String); + C.List_Context = H.setRuntimeTypeInfo(makeConstList(["Context"]), type$.JSArray_legacy_String); + C.List_ContextElement = H.setRuntimeTypeInfo(makeConstList(["ContextElement"]), type$.JSArray_legacy_String); + C.List_ContextRef = H.setRuntimeTypeInfo(makeConstList(["ContextRef"]), type$.JSArray_legacy_String); + C.List_CpuSample = H.setRuntimeTypeInfo(makeConstList(["CpuSample"]), type$.JSArray_legacy_String); + C.List_CpuSamples = H.setRuntimeTypeInfo(makeConstList(["CpuSamples"]), type$.JSArray_legacy_String); + C.List_Error = H.setRuntimeTypeInfo(makeConstList(["Error"]), type$.JSArray_legacy_String); + C.List_ErrorRef = H.setRuntimeTypeInfo(makeConstList(["ErrorRef"]), type$.JSArray_legacy_String); + C.List_Event = H.setRuntimeTypeInfo(makeConstList(["Event"]), type$.JSArray_legacy_String); + C.List_FieldRef = H.setRuntimeTypeInfo(makeConstList(["FieldRef"]), type$.JSArray_legacy_String); + C.List_Flag = H.setRuntimeTypeInfo(makeConstList(["Flag"]), type$.JSArray_legacy_String); + C.List_FlagList = H.setRuntimeTypeInfo(makeConstList(["FlagList"]), type$.JSArray_legacy_String); + C.List_Frame = H.setRuntimeTypeInfo(makeConstList(["Frame"]), type$.JSArray_legacy_String); + C.List_FuncRef = H.setRuntimeTypeInfo(makeConstList(["FuncRef"]), type$.JSArray_legacy_String); + C.List_InboundReference = H.setRuntimeTypeInfo(makeConstList(["InboundReference"]), type$.JSArray_legacy_String); + C.List_InboundReferences = H.setRuntimeTypeInfo(makeConstList(["InboundReferences"]), type$.JSArray_legacy_String); + C.List_InstanceRef = H.setRuntimeTypeInfo(makeConstList(["InstanceRef"]), type$.JSArray_legacy_String); + C.List_InstanceRef_ErrorRef = H.setRuntimeTypeInfo(makeConstList(["InstanceRef", "ErrorRef"]), type$.JSArray_legacy_String); + C.List_InstanceRef_Sentinel = H.setRuntimeTypeInfo(makeConstList(["InstanceRef", "Sentinel"]), type$.JSArray_legacy_String); + C.List_InstanceSet = H.setRuntimeTypeInfo(makeConstList(["InstanceSet"]), type$.JSArray_legacy_String); + C.List_Isolate = H.setRuntimeTypeInfo(makeConstList(["Isolate"]), type$.JSArray_legacy_String); + C.List_IsolateGroup = H.setRuntimeTypeInfo(makeConstList(["IsolateGroup"]), type$.JSArray_legacy_String); + C.List_IsolateGroupRef = H.setRuntimeTypeInfo(makeConstList(["IsolateGroupRef"]), type$.JSArray_legacy_String); + C.List_IsolateRef = H.setRuntimeTypeInfo(makeConstList(["IsolateRef"]), type$.JSArray_legacy_String); + C.List_LibraryRef = H.setRuntimeTypeInfo(makeConstList(["LibraryRef"]), type$.JSArray_legacy_String); + C.List_LibraryRef_ClassRef_FuncRef = H.setRuntimeTypeInfo(makeConstList(["LibraryRef", "ClassRef", "FuncRef"]), type$.JSArray_legacy_String); + C.List_LogRecord = H.setRuntimeTypeInfo(makeConstList(["LogRecord"]), type$.JSArray_legacy_String); + C.List_MemoryUsage = H.setRuntimeTypeInfo(makeConstList(["MemoryUsage"]), type$.JSArray_legacy_String); + C.List_Message = H.setRuntimeTypeInfo(makeConstList(["Message"]), type$.JSArray_legacy_String); + C.List_Obj = H.setRuntimeTypeInfo(makeConstList(["Obj"]), type$.JSArray_legacy_String); + C.List_ObjRef = H.setRuntimeTypeInfo(makeConstList(["ObjRef"]), type$.JSArray_legacy_String); + C.List_PAk = H.setRuntimeTypeInfo(makeConstList(["InstanceRef", "TypeArgumentsRef", "Sentinel"]), type$.JSArray_legacy_String); + C.List_ProfileFunction = H.setRuntimeTypeInfo(makeConstList(["ProfileFunction"]), type$.JSArray_legacy_String); + C.List_ReloadReport = H.setRuntimeTypeInfo(makeConstList(["ReloadReport"]), type$.JSArray_legacy_String); + C.List_RetainingObject = H.setRuntimeTypeInfo(makeConstList(["RetainingObject"]), type$.JSArray_legacy_String); + C.List_RetainingPath = H.setRuntimeTypeInfo(makeConstList(["RetainingPath"]), type$.JSArray_legacy_String); + C.List_ScriptList = H.setRuntimeTypeInfo(makeConstList(["ScriptList"]), type$.JSArray_legacy_String); + C.List_ScriptRef = H.setRuntimeTypeInfo(makeConstList(["ScriptRef"]), type$.JSArray_legacy_String); + C.List_SourceLocation = H.setRuntimeTypeInfo(makeConstList(["SourceLocation"]), type$.JSArray_legacy_String); + C.List_SourceReport = H.setRuntimeTypeInfo(makeConstList(["SourceReport"]), type$.JSArray_legacy_String); + C.List_Stack = H.setRuntimeTypeInfo(makeConstList(["Stack"]), type$.JSArray_legacy_String); + C.List_Success = H.setRuntimeTypeInfo(makeConstList(["Success"]), type$.JSArray_legacy_String); + C.List_Success_Error = H.setRuntimeTypeInfo(makeConstList(["Success", "Error"]), type$.JSArray_legacy_String); + C.List_Timeline = H.setRuntimeTypeInfo(makeConstList(["Timeline"]), type$.JSArray_legacy_String); + C.List_TimelineEvent = H.setRuntimeTypeInfo(makeConstList(["TimelineEvent"]), type$.JSArray_legacy_String); + C.List_TimelineFlags = H.setRuntimeTypeInfo(makeConstList(["TimelineFlags"]), type$.JSArray_legacy_String); + C.List_Timestamp = H.setRuntimeTypeInfo(makeConstList(["Timestamp"]), type$.JSArray_legacy_String); + C.List_TypeArgumentsRef = H.setRuntimeTypeInfo(makeConstList(["TypeArgumentsRef"]), type$.JSArray_legacy_String); + C.List_VM = H.setRuntimeTypeInfo(makeConstList(["VM"]), type$.JSArray_legacy_String); + C.List_VMRef = H.setRuntimeTypeInfo(makeConstList(["VMRef"]), type$.JSArray_legacy_String); + C.List_Version = H.setRuntimeTypeInfo(makeConstList(["Version"]), type$.JSArray_legacy_String); + C.List_dynamic = H.setRuntimeTypeInfo(makeConstList(["dynamic"]), type$.JSArray_legacy_String); + C.List_empty = H.setRuntimeTypeInfo(makeConstList([]), type$.JSArray_dynamic); + C.List_oqh = H.setRuntimeTypeInfo(makeConstList(["SourceLocation", "UnresolvedSourceLocation"]), type$.JSArray_legacy_String); + C.Map_empty = new H.ConstantStringMap(0, {}, C.List_empty, H.findType("ConstantStringMap<@,@>")); + C.List_empty0 = H.setRuntimeTypeInfo(makeConstList([]), H.findType("JSArray")); + C.Map_empty0 = new H.ConstantStringMap(0, {}, C.List_empty0, H.findType("ConstantStringMap")); + C.Symbol_call = new H.Symbol("call"); + C.Type_ByteBuffer_RkP = H.typeLiteral("ByteBuffer"); + C.Type_ByteData_zNC = H.typeLiteral("ByteData"); + C.Type_Float32List_LB7 = H.typeLiteral("Float32List"); + C.Type_Float64List_LB7 = H.typeLiteral("Float64List"); + C.Type_Int16List_uXf = H.typeLiteral("Int16List"); + C.Type_Int32List_O50 = H.typeLiteral("Int32List"); + C.Type_Int8List_ekJ = H.typeLiteral("Int8List"); + C.Type_JSObject_8k0 = H.typeLiteral("JSObject"); + C.Type_Null_Yyn = H.typeLiteral("Null"); + C.Type_String_k8F = H.typeLiteral("String"); + C.Type_Uint16List_2bx = H.typeLiteral("Uint16List"); + C.Type_Uint32List_2bx = H.typeLiteral("Uint32List"); + C.Type_Uint8ClampedList_Jik = H.typeLiteral("Uint8ClampedList"); + C.Type_Uint8List_WLA = H.typeLiteral("Uint8List"); + C.Type_bool_lhE = H.typeLiteral("bool"); + C.Type_double_K1J = H.typeLiteral("double"); + C.Type_int_tHn = H.typeLiteral("int"); + C.Type_num_cv7 = H.typeLiteral("num"); + C.Utf8Decoder_false = new P.Utf8Decoder(false); + })(); + (function staticFields() { + $._JS_INTEROP_INTERCEPTOR_TAG = null; + $.Closure_functionCounter = 0; + $.BoundClosure_selfFieldNameCache = null; + $.BoundClosure_receiverFieldNameCache = null; + $.getTagFunction = null; + $.alternateTagFunction = null; + $.prototypeForTagFunction = null; + $.dispatchRecordsForInstanceTags = null; + $.interceptorsForUncacheableTags = null; + $.initNativeDispatchFlag = null; + $._nextCallback = null; + $._lastCallback = null; + $._lastPriorityCallback = null; + $._isInCallbackLoop = false; + $.Zone__current = C.C__RootZone; + $._toStringVisiting = H.setRuntimeTypeInfo([], H.findType("JSArray")); + $.LogRecord__nextNumber = 0; + $.Logger__loggers = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.legacy_Logger); + $._typeFactories = P.LinkedHashMap_LinkedHashMap$_literal(["AllocationProfile", Q.vm_service_AllocationProfile_parse$closure(), "BoundField", Q.vm_service_BoundField_parse$closure(), "BoundVariable", Q.vm_service_BoundVariable_parse$closure(), "Breakpoint", Q.vm_service_Breakpoint_parse$closure(), "@Class", Q.vm_service_ClassRef_parse$closure(), "Class", Q.vm_service_Class_parse$closure(), "ClassHeapStats", Q.vm_service_ClassHeapStats_parse$closure(), "ClassList", Q.vm_service_ClassList_parse$closure(), "ClientName", Q.vm_service_ClientName_parse$closure(), "@Code", Q.vm_service_CodeRef_parse$closure(), "Code", Q.vm_service_Code_parse$closure(), "@Context", Q.vm_service_ContextRef_parse$closure(), "Context", Q.vm_service_Context_parse$closure(), "ContextElement", Q.vm_service_ContextElement_parse$closure(), "CpuSamples", Q.vm_service_CpuSamples_parse$closure(), "CpuSample", Q.vm_service_CpuSample_parse$closure(), "@Error", Q.vm_service_ErrorRef_parse$closure(), "Error", Q.vm_service_Error_parse$closure(), "Event", Q.vm_service_Event_parse$closure(), "ExtensionData", Q.vm_service_ExtensionData_parse$closure(), "@Field", Q.vm_service_FieldRef_parse$closure(), "Field", Q.vm_service_Field_parse$closure(), "Flag", Q.vm_service_Flag_parse$closure(), "FlagList", Q.vm_service_FlagList_parse$closure(), "Frame", Q.vm_service_Frame_parse$closure(), "@Function", Q.vm_service_FuncRef_parse$closure(), "Function", Q.vm_service_Func_parse$closure(), "@Instance", Q.vm_service_InstanceRef_parse$closure(), "Instance", Q.vm_service_Instance_parse$closure(), "@Isolate", Q.vm_service_IsolateRef_parse$closure(), "Isolate", Q.vm_service_Isolate_parse$closure(), "@IsolateGroup", Q.vm_service_IsolateGroupRef_parse$closure(), "IsolateGroup", Q.vm_service_IsolateGroup_parse$closure(), "InboundReferences", Q.vm_service_InboundReferences_parse$closure(), "InboundReference", Q.vm_service_InboundReference_parse$closure(), "InstanceSet", Q.vm_service_InstanceSet_parse$closure(), "@Library", Q.vm_service_LibraryRef_parse$closure(), "Library", Q.vm_service_Library_parse$closure(), "LibraryDependency", Q.vm_service_LibraryDependency_parse$closure(), "LogRecord", Q.vm_service_LogRecord_parse$closure(), "MapAssociation", Q.vm_service_MapAssociation_parse$closure(), "MemoryUsage", Q.vm_service_MemoryUsage_parse$closure(), "Message", Q.vm_service_Message_parse$closure(), "NativeFunction", Q.vm_service_NativeFunction_parse$closure(), "@Null", Q.vm_service_NullValRef_parse$closure(), "Null", Q.vm_service_NullVal_parse$closure(), "@Object", Q.vm_service_ObjRef_parse$closure(), "Object", Q.vm_service_Obj_parse$closure(), "ProfileFunction", Q.vm_service_ProfileFunction_parse$closure(), "ReloadReport", Q.vm_service_ReloadReport_parse$closure(), "RetainingObject", Q.vm_service_RetainingObject_parse$closure(), "RetainingPath", Q.vm_service_RetainingPath_parse$closure(), "Response", Q.vm_service_Response_parse$closure(), "Sentinel", Q.vm_service_Sentinel_parse$closure(), "@Script", Q.vm_service_ScriptRef_parse$closure(), "Script", Q.vm_service_Script_parse$closure(), "ScriptList", Q.vm_service_ScriptList_parse$closure(), "SourceLocation", Q.vm_service_SourceLocation_parse$closure(), "SourceReport", Q.vm_service_SourceReport_parse$closure(), "SourceReportCoverage", Q.vm_service_SourceReportCoverage_parse$closure(), "SourceReportRange", Q.vm_service_SourceReportRange_parse$closure(), "Stack", Q.vm_service_Stack_parse$closure(), "Success", Q.vm_service_Success_parse$closure(), "Timeline", Q.vm_service_Timeline_parse$closure(), "TimelineEvent", Q.vm_service_TimelineEvent_parse$closure(), "TimelineFlags", Q.vm_service_TimelineFlags_parse$closure(), "Timestamp", Q.vm_service_Timestamp_parse$closure(), "@TypeArguments", Q.vm_service_TypeArgumentsRef_parse$closure(), "TypeArguments", Q.vm_service_TypeArguments_parse$closure(), "UnresolvedSourceLocation", Q.vm_service_UnresolvedSourceLocation_parse$closure(), "Version", Q.vm_service_Version_parse$closure(), "@VM", Q.vm_service_VMRef_parse$closure(), "VM", Q.vm_service_VM_parse$closure()], type$.legacy_String, H.findType("Function*")); + $._methodReturnTypes = P.LinkedHashMap_LinkedHashMap$_literal(["addBreakpoint", C.List_Breakpoint, "addBreakpointWithScriptUri", C.List_Breakpoint, "addBreakpointAtEntry", C.List_Breakpoint, "clearCpuSamples", C.List_Success, "clearVMTimeline", C.List_Success, "invoke", C.List_InstanceRef_ErrorRef, "evaluate", C.List_InstanceRef_ErrorRef, "evaluateInFrame", C.List_InstanceRef_ErrorRef, "getAllocationProfile", C.List_AllocationProfile, "getClassList", C.List_ClassList, "getClientName", C.List_ClientName, "getCpuSamples", C.List_CpuSamples, "getFlagList", C.List_FlagList, "getInboundReferences", C.List_InboundReferences, "getInstances", C.List_InstanceSet, "getIsolate", C.List_Isolate, "getIsolateGroup", C.List_IsolateGroup, "getMemoryUsage", C.List_MemoryUsage, "getIsolateGroupMemoryUsage", C.List_MemoryUsage, "getScripts", C.List_ScriptList, "getObject", C.List_Obj, "getRetainingPath", C.List_RetainingPath, "getStack", C.List_Stack, "getSourceReport", C.List_SourceReport, "getVersion", C.List_Version, "getVM", C.List_VM, "getVMTimeline", C.List_Timeline, "getVMTimelineFlags", C.List_TimelineFlags, "getVMTimelineMicros", C.List_Timestamp, "pause", C.List_Success, "kill", C.List_Success, "registerService", C.List_Success, "reloadSources", C.List_ReloadReport, "removeBreakpoint", C.List_Success, "requestHeapSnapshot", C.List_Success, "requirePermissionToResume", C.List_Success, "resume", C.List_Success, "setClientName", C.List_Success, "setExceptionPauseMode", C.List_Success, "setFlag", C.List_Success_Error, "setLibraryDebuggable", C.List_Success, "setName", C.List_Success, "setVMName", C.List_Success, "setVMTimelineFlags", C.List_Success, "streamCancel", C.List_Success, "streamListen", C.List_Success], type$.legacy_String, type$.legacy_List_legacy_String); + })(); + (function lazyInitializers() { + var _lazy = hunkHelpers.lazy; + _lazy($, "DART_CLOSURE_PROPERTY_NAME", "$get$DART_CLOSURE_PROPERTY_NAME", function() { + return H.getIsolateAffinityTag("_$dart_dartClosure"); + }); + _lazy($, "TypeErrorDecoder_noSuchMethodPattern", "$get$TypeErrorDecoder_noSuchMethodPattern", function() { + return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn({ + toString: function() { + return "$receiver$"; + } + })); + }); + _lazy($, "TypeErrorDecoder_notClosurePattern", "$get$TypeErrorDecoder_notClosurePattern", function() { + return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn({$method$: null, + toString: function() { + return "$receiver$"; + } + })); + }); + _lazy($, "TypeErrorDecoder_nullCallPattern", "$get$TypeErrorDecoder_nullCallPattern", function() { + return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn(null)); + }); + _lazy($, "TypeErrorDecoder_nullLiteralCallPattern", "$get$TypeErrorDecoder_nullLiteralCallPattern", function() { + return H.TypeErrorDecoder_extractPattern(function() { + var $argumentsExpr$ = '$arguments$'; + try { + null.$method$($argumentsExpr$); + } catch (e) { + return e.message; + } + }()); + }); + _lazy($, "TypeErrorDecoder_undefinedCallPattern", "$get$TypeErrorDecoder_undefinedCallPattern", function() { + return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn(void 0)); + }); + _lazy($, "TypeErrorDecoder_undefinedLiteralCallPattern", "$get$TypeErrorDecoder_undefinedLiteralCallPattern", function() { + return H.TypeErrorDecoder_extractPattern(function() { + var $argumentsExpr$ = '$arguments$'; + try { + (void 0).$method$($argumentsExpr$); + } catch (e) { + return e.message; + } + }()); + }); + _lazy($, "TypeErrorDecoder_nullPropertyPattern", "$get$TypeErrorDecoder_nullPropertyPattern", function() { + return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokePropertyErrorOn(null)); + }); + _lazy($, "TypeErrorDecoder_nullLiteralPropertyPattern", "$get$TypeErrorDecoder_nullLiteralPropertyPattern", function() { + return H.TypeErrorDecoder_extractPattern(function() { + try { + null.$method$; + } catch (e) { + return e.message; + } + }()); + }); + _lazy($, "TypeErrorDecoder_undefinedPropertyPattern", "$get$TypeErrorDecoder_undefinedPropertyPattern", function() { + return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokePropertyErrorOn(void 0)); + }); + _lazy($, "TypeErrorDecoder_undefinedLiteralPropertyPattern", "$get$TypeErrorDecoder_undefinedLiteralPropertyPattern", function() { + return H.TypeErrorDecoder_extractPattern(function() { + try { + (void 0).$method$; + } catch (e) { + return e.message; + } + }()); + }); + _lazy($, "_AsyncRun__scheduleImmediateClosure", "$get$_AsyncRun__scheduleImmediateClosure", function() { + return P._AsyncRun__initializeScheduleImmediate(); + }); + _lazy($, "Future__nullFuture", "$get$Future__nullFuture", function() { + return P._Future$zoneValue(null, C.C__RootZone, type$.Null); + }); + _lazy($, "Future__falseFuture", "$get$Future__falseFuture", function() { + return P._Future$zoneValue(false, C.C__RootZone, type$.bool); + }); + _lazy($, "Utf8Decoder__decoder", "$get$Utf8Decoder__decoder", function() { + return new P.Utf8Decoder_closure().call$0(); + }); + _lazy($, "Utf8Decoder__decoderNonfatal", "$get$Utf8Decoder__decoderNonfatal", function() { + return new P.Utf8Decoder_closure0().call$0(); + }); + _lazy($, "_hasErrorStackProperty", "$get$_hasErrorStackProperty", function() { + return new Error().stack != void 0; + }); + _lazy($, "Logger_root", "$get$Logger_root", function() { + return F.Logger_Logger(""); + }); + })(); + (function nativeSupport() { + !function() { + var intern = function(s) { + var o = {}; + o[s] = 1; + return Object.keys(hunkHelpers.convertToFastObject(o))[0]; + }; + init.getIsolateTag = function(name) { + return intern("___dart_" + name + init.isolateTag); + }; + var tableProperty = "___dart_isolate_tags_"; + var usedProperties = Object[tableProperty] || (Object[tableProperty] = Object.create(null)); + var rootProperty = "_ZxYxX"; + for (var i = 0;; i++) { + var property = intern(rootProperty + "_" + i + "_"); + if (!(property in usedProperties)) { + usedProperties[property] = 1; + init.isolateTag = property; + break; + } + } + init.dispatchPropertyName = init.getIsolateTag("dispatch_record"); + }(); + hunkHelpers.setOrUpdateInterceptorsByTag({Blob: J.Interceptor, DOMError: J.Interceptor, File: J.Interceptor, MediaError: J.Interceptor, NavigatorUserMediaError: J.Interceptor, OverconstrainedError: J.Interceptor, PositionError: J.Interceptor, SQLError: J.Interceptor, ArrayBuffer: H.NativeByteBuffer, ArrayBufferView: H.NativeTypedData, DataView: H.NativeByteData, Float32Array: H.NativeFloat32List, Float64Array: H.NativeFloat64List, Int16Array: H.NativeInt16List, Int32Array: H.NativeInt32List, Int8Array: H.NativeInt8List, Uint16Array: H.NativeUint16List, Uint32Array: H.NativeUint32List, Uint8ClampedArray: H.NativeUint8ClampedList, CanvasPixelArray: H.NativeUint8ClampedList, Uint8Array: H.NativeUint8List, DOMException: W.DomException, AbortPaymentEvent: W.Event0, AnimationEvent: W.Event0, AnimationPlaybackEvent: W.Event0, ApplicationCacheErrorEvent: W.Event0, BackgroundFetchClickEvent: W.Event0, BackgroundFetchEvent: W.Event0, BackgroundFetchFailEvent: W.Event0, BackgroundFetchedEvent: W.Event0, BeforeInstallPromptEvent: W.Event0, BeforeUnloadEvent: W.Event0, BlobEvent: W.Event0, CanMakePaymentEvent: W.Event0, ClipboardEvent: W.Event0, CloseEvent: W.Event0, CompositionEvent: W.Event0, CustomEvent: W.Event0, DeviceMotionEvent: W.Event0, DeviceOrientationEvent: W.Event0, ErrorEvent: W.Event0, ExtendableEvent: W.Event0, ExtendableMessageEvent: W.Event0, FetchEvent: W.Event0, FocusEvent: W.Event0, FontFaceSetLoadEvent: W.Event0, ForeignFetchEvent: W.Event0, GamepadEvent: W.Event0, HashChangeEvent: W.Event0, InstallEvent: W.Event0, KeyboardEvent: W.Event0, MediaEncryptedEvent: W.Event0, MediaKeyMessageEvent: W.Event0, MediaQueryListEvent: W.Event0, MediaStreamEvent: W.Event0, MediaStreamTrackEvent: W.Event0, MIDIConnectionEvent: W.Event0, MIDIMessageEvent: W.Event0, MouseEvent: W.Event0, DragEvent: W.Event0, MutationEvent: W.Event0, NotificationEvent: W.Event0, PageTransitionEvent: W.Event0, PaymentRequestEvent: W.Event0, PaymentRequestUpdateEvent: W.Event0, PointerEvent: W.Event0, PopStateEvent: W.Event0, PresentationConnectionAvailableEvent: W.Event0, PresentationConnectionCloseEvent: W.Event0, PromiseRejectionEvent: W.Event0, PushEvent: W.Event0, RTCDataChannelEvent: W.Event0, RTCDTMFToneChangeEvent: W.Event0, RTCPeerConnectionIceEvent: W.Event0, RTCTrackEvent: W.Event0, SecurityPolicyViolationEvent: W.Event0, SensorErrorEvent: W.Event0, SpeechRecognitionError: W.Event0, SpeechRecognitionEvent: W.Event0, SpeechSynthesisEvent: W.Event0, StorageEvent: W.Event0, SyncEvent: W.Event0, TextEvent: W.Event0, TouchEvent: W.Event0, TrackEvent: W.Event0, TransitionEvent: W.Event0, WebKitTransitionEvent: W.Event0, UIEvent: W.Event0, VRDeviceEvent: W.Event0, VRDisplayEvent: W.Event0, VRSessionEvent: W.Event0, WheelEvent: W.Event0, MojoInterfaceRequestEvent: W.Event0, USBConnectionEvent: W.Event0, IDBVersionChangeEvent: W.Event0, AudioProcessingEvent: W.Event0, OfflineAudioCompletionEvent: W.Event0, WebGLContextEvent: W.Event0, Event: W.Event0, InputEvent: W.Event0, SubmitEvent: W.Event0, EventSource: W.EventSource, MessagePort: W.EventTarget, EventTarget: W.EventTarget, XMLHttpRequest: W.HttpRequest, XMLHttpRequestEventTarget: W.HttpRequestEventTarget, MessageEvent: W.MessageEvent, ProgressEvent: W.ProgressEvent, ResourceProgressEvent: W.ProgressEvent}); + hunkHelpers.setOrUpdateLeafTags({Blob: true, DOMError: true, File: true, MediaError: true, NavigatorUserMediaError: true, OverconstrainedError: true, PositionError: true, SQLError: true, ArrayBuffer: true, ArrayBufferView: false, DataView: true, Float32Array: true, Float64Array: true, Int16Array: true, Int32Array: true, Int8Array: true, Uint16Array: true, Uint32Array: true, Uint8ClampedArray: true, CanvasPixelArray: true, Uint8Array: false, DOMException: true, AbortPaymentEvent: true, AnimationEvent: true, AnimationPlaybackEvent: true, ApplicationCacheErrorEvent: true, BackgroundFetchClickEvent: true, BackgroundFetchEvent: true, BackgroundFetchFailEvent: true, BackgroundFetchedEvent: true, BeforeInstallPromptEvent: true, BeforeUnloadEvent: true, BlobEvent: true, CanMakePaymentEvent: true, ClipboardEvent: true, CloseEvent: true, CompositionEvent: true, CustomEvent: true, DeviceMotionEvent: true, DeviceOrientationEvent: true, ErrorEvent: true, ExtendableEvent: true, ExtendableMessageEvent: true, FetchEvent: true, FocusEvent: true, FontFaceSetLoadEvent: true, ForeignFetchEvent: true, GamepadEvent: true, HashChangeEvent: true, InstallEvent: true, KeyboardEvent: true, MediaEncryptedEvent: true, MediaKeyMessageEvent: true, MediaQueryListEvent: true, MediaStreamEvent: true, MediaStreamTrackEvent: true, MIDIConnectionEvent: true, MIDIMessageEvent: true, MouseEvent: true, DragEvent: true, MutationEvent: true, NotificationEvent: true, PageTransitionEvent: true, PaymentRequestEvent: true, PaymentRequestUpdateEvent: true, PointerEvent: true, PopStateEvent: true, PresentationConnectionAvailableEvent: true, PresentationConnectionCloseEvent: true, PromiseRejectionEvent: true, PushEvent: true, RTCDataChannelEvent: true, RTCDTMFToneChangeEvent: true, RTCPeerConnectionIceEvent: true, RTCTrackEvent: true, SecurityPolicyViolationEvent: true, SensorErrorEvent: true, SpeechRecognitionError: true, SpeechRecognitionEvent: true, SpeechSynthesisEvent: true, StorageEvent: true, SyncEvent: true, TextEvent: true, TouchEvent: true, TrackEvent: true, TransitionEvent: true, WebKitTransitionEvent: true, UIEvent: true, VRDeviceEvent: true, VRDisplayEvent: true, VRSessionEvent: true, WheelEvent: true, MojoInterfaceRequestEvent: true, USBConnectionEvent: true, IDBVersionChangeEvent: true, AudioProcessingEvent: true, OfflineAudioCompletionEvent: true, WebGLContextEvent: true, Event: false, InputEvent: false, SubmitEvent: false, EventSource: true, MessagePort: true, EventTarget: false, XMLHttpRequest: true, XMLHttpRequestEventTarget: false, MessageEvent: true, ProgressEvent: true, ResourceProgressEvent: true}); + H.NativeTypedArray.$nativeSuperclassTag = "ArrayBufferView"; + H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin.$nativeSuperclassTag = "ArrayBufferView"; + H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin.$nativeSuperclassTag = "ArrayBufferView"; + H.NativeTypedArrayOfDouble.$nativeSuperclassTag = "ArrayBufferView"; + H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin.$nativeSuperclassTag = "ArrayBufferView"; + H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin.$nativeSuperclassTag = "ArrayBufferView"; + H.NativeTypedArrayOfInt.$nativeSuperclassTag = "ArrayBufferView"; + })(); + convertAllToFastObject(holders); + convertToFastObject($); + (function(callback) { + if (typeof document === "undefined") { + callback(null); + return; + } + if (typeof document.currentScript != 'undefined') { + callback(document.currentScript); + return; + } + var scripts = document.scripts; + function onLoad(event) { + for (var i = 0; i < scripts.length; ++i) + scripts[i].removeEventListener("load", onLoad, false); + callback(event.target); + } + for (var i = 0; i < scripts.length; ++i) + scripts[i].addEventListener("load", onLoad, false); + })(function(currentScript) { + init.currentScript = currentScript; + if (typeof dartMainRunner === "function") + dartMainRunner(E.main, []); + else + E.main([]); + }); +})(); + +//# sourceMappingURL=sse_smoke_driver.dart.js.map diff --git a/tools/bots/test_matrix.json b/tools/bots/test_matrix.json index d795d61dfd7..f6e72716c83 100644 --- a/tools/bots/test_matrix.json +++ b/tools/bots/test_matrix.json @@ -313,6 +313,7 @@ "third_party/android_tools/sdk/platform-tools/adb", "third_party/android_tools/ndk/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64/bin/aarch64-linux-android-strip", "third_party/android_tools/ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-strip", + "third_party/webdriver/", "third_party/pkg/", "third_party/pkg_tested/", "tests/.dart_tool/package_config.json",