2
0
mirror of https://github.com/esiur/esiur-dart.git synced 2025-05-06 12:02:57 +00:00
esiur-dart/lib/esiur.js
2022-03-12 16:21:29 +03:00

34619 lines
1.6 MiB

define(['dart_sdk'], (function load__esiur(dart_sdk) {
'use strict';
const core = dart_sdk.core;
const js = dart_sdk.js;
const _interceptors = dart_sdk._interceptors;
const _js_helper = dart_sdk._js_helper;
const _internal = dart_sdk._internal;
const async = dart_sdk.async;
const io = dart_sdk.io;
const collection = dart_sdk.collection;
const typed_data = dart_sdk.typed_data;
const _native_typed_data = dart_sdk._native_typed_data;
const convert = dart_sdk.convert;
const math = dart_sdk.math;
const html = dart_sdk.html;
const dart = dart_sdk.dart;
const dartx = dart_sdk.dartx;
var esiur_js = Object.create(dart.library);
var esiur = Object.create(dart.library);
var Warehouse = Object.create(dart.library);
var Instance = Object.create(dart.library);
var IResource = Object.create(dart.library);
var IStore = Object.create(dart.library);
var ResourceTrigger = Object.create(dart.library);
var StorageMode = Object.create(dart.library);
var EventTemplate = Object.create(dart.library);
var FunctionTemplate = Object.create(dart.library);
var MemberTemplate = Object.create(dart.library);
var MemberType = Object.create(dart.library);
var PropertyPermission = Object.create(dart.library);
var PropertyTemplate = Object.create(dart.library);
var TypeTemplate = Object.create(dart.library);
var TemplateDescriber = Object.create(dart.library);
var TemplateGenerator = Object.create(dart.library);
var ProgressType = Object.create(dart.library);
var AsyncBag$ = Object.create(dart.library);
var AsyncException = Object.create(dart.library);
var AsyncQueue$ = Object.create(dart.library);
var AsyncReply$ = Object.create(dart.library);
var ErrorType = Object.create(dart.library);
var ExceptionCode = Object.create(dart.library);
var IDestructible = Object.create(dart.library);
var IEventHandler = Object.create(dart.library);
var Tuple = Object.create(dart.library);
var AutoList$ = Object.create(dart.library);
var BinaryList = Object.create(dart.library);
var Codec = Object.create(dart.library);
var RepresentationType = Object.create(dart.library);
var DC = Object.create(dart.library);
var Guid = Object.create(dart.library);
var KeyList$ = Object.create(dart.library);
var NotModified = Object.create(dart.library);
var PropertyValue = Object.create(dart.library);
var SizeObject = Object.create(dart.library);
var ValueObject = Object.create(dart.library);
var IRecord = Object.create(dart.library);
var Record = Object.create(dart.library);
var IEnum = Object.create(dart.library);
var IntType = Object.create(dart.library);
var NetworkBuffer = Object.create(dart.library);
var NetworkConnection = Object.create(dart.library);
var SendList = Object.create(dart.library);
var DistributedConnection = Object.create(dart.library);
var DistributedPropertyContext = Object.create(dart.library);
var DistributedResource = Object.create(dart.library);
var DistributedResourceQueueItem = Object.create(dart.library);
var DistributedResourceQueueItemType = Object.create(dart.library);
var IIPAuthPacket = Object.create(dart.library);
var IIPAuthPacketAction = Object.create(dart.library);
var IIPAuthPacketCommand = Object.create(dart.library);
var IIPPacket = Object.create(dart.library);
var IIPPacketAction = Object.create(dart.library);
var IIPPacketCommand = Object.create(dart.library);
var IIPPacketEvent = Object.create(dart.library);
var IIPPacketReport = Object.create(dart.library);
var IPEndPoint = Object.create(dart.library);
var ISocket = Object.create(dart.library);
var SocketState = Object.create(dart.library);
var TCPSocket = Object.create(dart.library);
var Authentication = Object.create(dart.library);
var AuthenticationState = Object.create(dart.library);
var AuthenticationType = Object.create(dart.library);
var AuthenticationMethod = Object.create(dart.library);
var ClientAuthentication = Object.create(dart.library);
var CoHostAuthentication = Object.create(dart.library);
var HostAuthentication = Object.create(dart.library);
var Session = Object.create(dart.library);
var Source = Object.create(dart.library);
var SourceAttributeType = Object.create(dart.library);
var SHA256 = Object.create(dart.library);
var ActionType = Object.create(dart.library);
var IPermissionsManager = Object.create(dart.library);
var Ruling = Object.create(dart.library);
var TransmissionType = Object.create(dart.library);
var FactoryEntry$ = Object.create(dart.library);
var TemplateType = Object.create(dart.library);
var EventOccurredInfo = Object.create(dart.library);
var PropertyModificationInfo = Object.create(dart.library);
var ArgumentTemplate = Object.create(dart.library);
var ConstantTemplate = Object.create(dart.library);
var collection$ = Object.create(dart.library);
var DataDeserializer = Object.create(dart.library);
var DataSerializer = Object.create(dart.library);
var ResourceArrayType = Object.create(dart.library);
var INetworkReceiver$ = Object.create(dart.library);
var PropertyModificationInfo$ = Object.create(dart.library);
var WSocket = Object.create(dart.library);
var DistributedServer = Object.create(dart.library);
var KeyValuePair$ = Object.create(dart.library);
var ParseResult$ = Object.create(dart.library);
var algorithms = Object.create(dart.library);
var canonicalized_map = Object.create(dart.library);
var combined_iterable = Object.create(dart.library);
var combined_list = Object.create(dart.library);
var combined_map = Object.create(dart.library);
var comparators = Object.create(dart.library);
var equality$ = Object.create(dart.library);
var equality_map = Object.create(dart.library);
var equality_set = Object.create(dart.library);
var functions = Object.create(dart.library);
var iterable_extensions = Object.create(dart.library);
var iterable_zip = Object.create(dart.library);
var list_extensions = Object.create(dart.library);
var priority_queue = Object.create(dart.library);
var queue_list = Object.create(dart.library);
var union_set = Object.create(dart.library);
var union_set_controller = Object.create(dart.library);
var unmodifiable_wrappers = Object.create(dart.library);
var wrappers = Object.create(dart.library);
var web_socket_channel = Object.create(dart.library);
var EntryPoint = Object.create(dart.library);
var utils = Object.create(dart.library);
var combined_iterator = Object.create(dart.library);
var empty_unmodifiable_set = Object.create(dart.library);
var channel$ = Object.create(dart.library);
var exception = Object.create(dart.library);
var async$ = Object.create(dart.library);
var crypto = Object.create(dart.library);
var stream_channel = Object.create(dart.library);
var _connect_html = Object.create(dart.library);
var web_socket_impl = Object.create(dart.library);
var async_cache = Object.create(dart.library);
var async_memoizer = Object.create(dart.library);
var byte_collector = Object.create(dart.library);
var cancelable_operation = Object.create(dart.library);
var event_sink = Object.create(dart.library);
var future = Object.create(dart.library);
var sink$ = Object.create(dart.library);
var stream$ = Object.create(dart.library);
var stream_consumer = Object.create(dart.library);
var stream_sink = Object.create(dart.library);
var stream_subscription = Object.create(dart.library);
var future_group = Object.create(dart.library);
var lazy_stream = Object.create(dart.library);
var null_stream_sink = Object.create(dart.library);
var restartable_timer = Object.create(dart.library);
var result$ = Object.create(dart.library);
var error$ = Object.create(dart.library);
var future$ = Object.create(dart.library);
var value$ = Object.create(dart.library);
var single_subscription_transformer = Object.create(dart.library);
var sink_base = Object.create(dart.library);
var stream_closer = Object.create(dart.library);
var stream_completer = Object.create(dart.library);
var stream_extensions = Object.create(dart.library);
var stream_group = Object.create(dart.library);
var stream_queue = Object.create(dart.library);
var stream_sink_completer = Object.create(dart.library);
var stream_sink_extensions = Object.create(dart.library);
var stream_sink_transformer = Object.create(dart.library);
var stream_splitter = Object.create(dart.library);
var stream_subscription_transformer = Object.create(dart.library);
var stream_zip = Object.create(dart.library);
var subscription_stream = Object.create(dart.library);
var typed_stream_transformer = Object.create(dart.library);
var chunked_stream_reader = Object.create(dart.library);
var digest = Object.create(dart.library);
var hash = Object.create(dart.library);
var hmac = Object.create(dart.library);
var md5 = Object.create(dart.library);
var sha1 = Object.create(dart.library);
var sha256 = Object.create(dart.library);
var sha512 = Object.create(dart.library);
var guarantee_channel = Object.create(dart.library);
var close_guarantee_channel = Object.create(dart.library);
var stream_channel_transformer = Object.create(dart.library);
var delegating_stream_channel = Object.create(dart.library);
var disconnector = Object.create(dart.library);
var json_document_transformer = Object.create(dart.library);
var multi_channel = Object.create(dart.library);
var stream_channel_completer = Object.create(dart.library);
var stream_channel_controller = Object.create(dart.library);
var html$ = Object.create(dart.library);
var io_sink = Object.create(dart.library);
var web_socket = Object.create(dart.library);
var utils$ = Object.create(dart.library);
var stream_subscription$ = Object.create(dart.library);
var capture_sink = Object.create(dart.library);
var capture_transformer = Object.create(dart.library);
var release_sink = Object.create(dart.library);
var release_transformer = Object.create(dart.library);
var meta = Object.create(dart.library);
var reject_errors = Object.create(dart.library);
var handler_transformer = Object.create(dart.library);
var stream_transformer_wrapper = Object.create(dart.library);
var typed = Object.create(dart.library);
var digest_sink = Object.create(dart.library);
var hash_sink = Object.create(dart.library);
var utils$0 = Object.create(dart.library);
var sha512_slowsinks = Object.create(dart.library);
var meta_meta = Object.create(dart.library);
var typed_data$ = Object.create(dart.library);
var typed_queue = Object.create(dart.library);
var typed_buffers = Object.create(dart.library);
var typed_buffer = Object.create(dart.library);
dart._checkModuleNullSafetyMode(false);
var T$ = {
KeyListOfGuid$TypeTemplate: () => (T$.KeyListOfGuid$TypeTemplate = dart.constFn(KeyList$.KeyList$(Guid.Guid, TypeTemplate.TypeTemplate)))(),
KeyListOfTemplateType$KeyListOfGuid$TypeTemplate: () => (T$.KeyListOfTemplateType$KeyListOfGuid$TypeTemplate = dart.constFn(KeyList$.KeyList$(TemplateType.TemplateType, T$.KeyListOfGuid$TypeTemplate())))(),
IResourceN: () => (T$.IResourceN = dart.constFn(dart.nullable(IResource.IResource)))(),
AsyncReplyOfIResourceN: () => (T$.AsyncReplyOfIResourceN = dart.constFn(AsyncReply$.AsyncReply$(T$.IResourceN())))(),
AsyncBagOfbool: () => (T$.AsyncBagOfbool = dart.constFn(AsyncBag$.AsyncBag$(core.bool)))(),
AsyncReplyOfbool: () => (T$.AsyncReplyOfbool = dart.constFn(AsyncReply$.AsyncReply$(core.bool)))(),
ListOfbool: () => (T$.ListOfbool = dart.constFn(core.List$(core.bool)))(),
ListOfboolToNull: () => (T$.ListOfboolToNull = dart.constFn(dart.fnType(core.Null, [T$.ListOfbool()])))(),
JSArrayOfIResource: () => (T$.JSArrayOfIResource = dart.constFn(_interceptors.JSArray$(IResource.IResource)))(),
AutoListOfIResource$Instance: () => (T$.AutoListOfIResource$Instance = dart.constFn(AutoList$.AutoList$(IResource.IResource, Instance.Instance)))(),
IStoreTobool: () => (T$.IStoreTobool = dart.constFn(dart.fnType(core.bool, [IStore.IStore])))(),
ListOfIResource: () => (T$.ListOfIResource = dart.constFn(core.List$(IResource.IResource)))(),
ListNOfIResource: () => (T$.ListNOfIResource = dart.constFn(dart.nullable(T$.ListOfIResource())))(),
AsyncReplyOfListNOfIResource: () => (T$.AsyncReplyOfListNOfIResource = dart.constFn(AsyncReply$.AsyncReply$(T$.ListNOfIResource())))(),
AsyncReplyOfListOfIResource: () => (T$.AsyncReplyOfListOfIResource = dart.constFn(AsyncReply$.AsyncReply$(T$.ListOfIResource())))(),
IResourceTobool: () => (T$.IResourceTobool = dart.constFn(dart.fnType(core.bool, [IResource.IResource])))(),
IResourceNToNull: () => (T$.IResourceNToNull = dart.constFn(dart.fnType(core.Null, [T$.IResourceN()])))(),
AsyncReplyOfIStore: () => (T$.AsyncReplyOfIStore = dart.constFn(AsyncReply$.AsyncReply$(IStore.IStore)))(),
MapOfString$dynamic: () => (T$.MapOfString$dynamic = dart.constFn(core.Map$(core.String, dart.dynamic)))(),
MapNOfString$dynamic: () => (T$.MapNOfString$dynamic = dart.constFn(dart.nullable(T$.MapOfString$dynamic())))(),
StringAndMapNOfString$dynamicToAsyncReplyOfIStore: () => (T$.StringAndMapNOfString$dynamicToAsyncReplyOfIStore = dart.constFn(dart.fnType(T$.AsyncReplyOfIStore(), [core.String, T$.MapNOfString$dynamic()])))(),
IStoreToNull: () => (T$.IStoreToNull = dart.constFn(dart.fnType(core.Null, [IStore.IStore])))(),
AsyncExceptionToNull: () => (T$.AsyncExceptionToNull = dart.constFn(dart.fnType(core.Null, [AsyncException.AsyncException])))(),
VoidToNull: () => (T$.VoidToNull = dart.constFn(dart.fnType(core.Null, [])))(),
boolToNull: () => (T$.boolToNull = dart.constFn(dart.fnType(core.Null, [core.bool])))(),
ListNOfIResourceToNull: () => (T$.ListNOfIResourceToNull = dart.constFn(dart.fnType(core.Null, [T$.ListNOfIResource()])))(),
TypeTemplateTobool: () => (T$.TypeTemplateTobool = dart.constFn(dart.fnType(core.bool, [TypeTemplate.TypeTemplate])))(),
KeyListOfString$StringAndMapNOfString$dynamicToAsyncReplyOfIStore: () => (T$.KeyListOfString$StringAndMapNOfString$dynamicToAsyncReplyOfIStore = dart.constFn(KeyList$.KeyList$(core.String, T$.StringAndMapNOfString$dynamicToAsyncReplyOfIStore())))(),
AsyncReplyOfDistributedConnection: () => (T$.AsyncReplyOfDistributedConnection = dart.constFn(AsyncReply$.AsyncReply$(DistributedConnection.DistributedConnection)))(),
StringAndMapNOfString$dynamicToAsyncReplyOfDistributedConnection: () => (T$.StringAndMapNOfString$dynamicToAsyncReplyOfDistributedConnection = dart.constFn(dart.fnType(T$.AsyncReplyOfDistributedConnection(), [core.String, T$.MapNOfString$dynamic()])))(),
IdentityMapOfString$dynamic: () => (T$.IdentityMapOfString$dynamic = dart.constFn(_js_helper.IdentityMap$(core.String, dart.dynamic)))(),
JSArrayOfRepresentationType: () => (T$.JSArrayOfRepresentationType = dart.constFn(_interceptors.JSArray$(RepresentationType.RepresentationType)))(),
JSArrayOfFactoryEntry: () => (T$.JSArrayOfFactoryEntry = dart.constFn(_interceptors.JSArray$(FactoryEntry$.FactoryEntry)))(),
FactoryEntryTovoid: () => (T$.FactoryEntryTovoid = dart.constFn(dart.fnType(dart.void, [FactoryEntry$.FactoryEntry])))(),
KeyListOfType$FactoryEntry: () => (T$.KeyListOfType$FactoryEntry = dart.constFn(KeyList$.KeyList$(core.Type, FactoryEntry$.FactoryEntry)))(),
FactoryEntryOfDistributedConnection: () => (T$.FactoryEntryOfDistributedConnection = dart.constFn(FactoryEntry$.FactoryEntry$(DistributedConnection.DistributedConnection)))(),
VoidToDistributedConnection: () => (T$.VoidToDistributedConnection = dart.constFn(dart.fnType(DistributedConnection.DistributedConnection, [])))(),
VoidToint: () => (T$.VoidToint = dart.constFn(dart.fnType(core.int, [])))(),
VoidTobool: () => (T$.VoidTobool = dart.constFn(dart.fnType(core.bool, [])))(),
VoidTodouble: () => (T$.VoidTodouble = dart.constFn(dart.fnType(core.double, [])))(),
VoidToString: () => (T$.VoidToString = dart.constFn(dart.fnType(core.String, [])))(),
VoidToDateTime: () => (T$.VoidToDateTime = dart.constFn(dart.fnType(core.DateTime, [])))(),
VoidToRecord: () => (T$.VoidToRecord = dart.constFn(dart.fnType(Record.Record, [])))(),
VoidToList: () => (T$.VoidToList = dart.constFn(dart.fnType(core.List, [])))(),
VoidToMap: () => (T$.VoidToMap = dart.constFn(dart.fnType(core.Map, [])))(),
StringL: () => (T$.StringL = dart.constFn(dart.legacy(core.String)))(),
MapOfStringL$dynamic: () => (T$.MapOfStringL$dynamic = dart.constFn(core.Map$(T$.StringL(), dart.dynamic)))(),
VoidToType: () => (T$.VoidToType = dart.constFn(dart.fnType(core.Type, [])))(),
MapOfint$dynamic: () => (T$.MapOfint$dynamic = dart.constFn(core.Map$(core.int, dart.dynamic)))(),
LinkedMapOfint$dynamic: () => (T$.LinkedMapOfint$dynamic = dart.constFn(_js_helper.LinkedMap$(core.int, dart.dynamic)))(),
VoidToMapOfint$dynamic: () => (T$.VoidToMapOfint$dynamic = dart.constFn(dart.fnType(T$.MapOfint$dynamic(), [])))(),
MapOfInt32$dynamic: () => (T$.MapOfInt32$dynamic = dart.constFn(core.Map$(IntType.Int32, dart.dynamic)))(),
LinkedMapOfInt32$dynamic: () => (T$.LinkedMapOfInt32$dynamic = dart.constFn(_js_helper.LinkedMap$(IntType.Int32, dart.dynamic)))(),
VoidToMapOfInt32$dynamic: () => (T$.VoidToMapOfInt32$dynamic = dart.constFn(dart.fnType(T$.MapOfInt32$dynamic(), [])))(),
MapOfUInt8$dynamic: () => (T$.MapOfUInt8$dynamic = dart.constFn(core.Map$(IntType.UInt8, dart.dynamic)))(),
LinkedMapOfUInt8$dynamic: () => (T$.LinkedMapOfUInt8$dynamic = dart.constFn(_js_helper.LinkedMap$(IntType.UInt8, dart.dynamic)))(),
VoidToMapOfUInt8$dynamic: () => (T$.VoidToMapOfUInt8$dynamic = dart.constFn(dart.fnType(T$.MapOfUInt8$dynamic(), [])))(),
VoidToObject: () => (T$.VoidToObject = dart.constFn(dart.fnType(core.Object, [])))(),
AutoListOfIStore$Instance: () => (T$.AutoListOfIStore$Instance = dart.constFn(AutoList$.AutoList$(IStore.IStore, Instance.Instance)))(),
LinkedMapOfint$IResource: () => (T$.LinkedMapOfint$IResource = dart.constFn(_js_helper.LinkedMap$(core.int, IResource.IResource)))(),
JSArrayOfint: () => (T$.JSArrayOfint = dart.constFn(_interceptors.JSArray$(core.int)))(),
JSArrayOfDateTime: () => (T$.JSArrayOfDateTime = dart.constFn(_interceptors.JSArray$(core.DateTime)))(),
KeyListOfString$dynamic: () => (T$.KeyListOfString$dynamic = dart.constFn(KeyList$.KeyList$(core.String, dart.dynamic)))(),
AutoListOfIPermissionsManager$Instance: () => (T$.AutoListOfIPermissionsManager$Instance = dart.constFn(AutoList$.AutoList$(IPermissionsManager.IPermissionsManager, Instance.Instance)))(),
LinkedMapOfString$dynamic: () => (T$.LinkedMapOfString$dynamic = dart.constFn(_js_helper.LinkedMap$(core.String, dart.dynamic)))(),
JSArrayOfMapOfString$dynamic: () => (T$.JSArrayOfMapOfString$dynamic = dart.constFn(_interceptors.JSArray$(T$.MapOfString$dynamic())))(),
JSArrayOfPropertyValue: () => (T$.JSArrayOfPropertyValue = dart.constFn(_interceptors.JSArray$(PropertyValue.PropertyValue)))(),
JSArrayOfString: () => (T$.JSArrayOfString = dart.constFn(_interceptors.JSArray$(core.String)))(),
StreamControllerOfPropertyModificationInfo: () => (T$.StreamControllerOfPropertyModificationInfo = dart.constFn(async.StreamController$(PropertyModificationInfo.PropertyModificationInfo)))(),
ListOfFunction: () => (T$.ListOfFunction = dart.constFn(core.List$(core.Function)))(),
IdentityMapOfString$ListOfFunction: () => (T$.IdentityMapOfString$ListOfFunction = dart.constFn(_js_helper.IdentityMap$(core.String, T$.ListOfFunction())))(),
JSArrayOfFunction: () => (T$.JSArrayOfFunction = dart.constFn(_interceptors.JSArray$(core.Function)))(),
ResourceTriggerL: () => (T$.ResourceTriggerL = dart.constFn(dart.legacy(ResourceTrigger.ResourceTrigger)))(),
MemberTypeL: () => (T$.MemberTypeL = dart.constFn(dart.legacy(MemberType.MemberType)))(),
JSArrayOfMemberTemplate: () => (T$.JSArrayOfMemberTemplate = dart.constFn(_interceptors.JSArray$(MemberTemplate.MemberTemplate)))(),
JSArrayOfFunctionTemplate: () => (T$.JSArrayOfFunctionTemplate = dart.constFn(_interceptors.JSArray$(FunctionTemplate.FunctionTemplate)))(),
JSArrayOfEventTemplate: () => (T$.JSArrayOfEventTemplate = dart.constFn(_interceptors.JSArray$(EventTemplate.EventTemplate)))(),
JSArrayOfPropertyTemplate: () => (T$.JSArrayOfPropertyTemplate = dart.constFn(_interceptors.JSArray$(PropertyTemplate.PropertyTemplate)))(),
JSArrayOfConstantTemplate: () => (T$.JSArrayOfConstantTemplate = dart.constFn(_interceptors.JSArray$(ConstantTemplate.ConstantTemplate)))(),
ListOfConst: () => (T$.ListOfConst = dart.constFn(core.List$(TemplateDescriber.Const)))(),
ListOfProp: () => (T$.ListOfProp = dart.constFn(core.List$(TemplateDescriber.Prop)))(),
ListOfFunc: () => (T$.ListOfFunc = dart.constFn(core.List$(TemplateDescriber.Func)))(),
MapEntryOfint$Arg: () => (T$.MapEntryOfint$Arg = dart.constFn(core.MapEntry$(core.int, TemplateDescriber.Arg)))(),
MapEntryOfint$ArgToArgumentTemplate: () => (T$.MapEntryOfint$ArgToArgumentTemplate = dart.constFn(dart.fnType(ArgumentTemplate.ArgumentTemplate, [T$.MapEntryOfint$Arg()])))(),
ListOfEvt: () => (T$.ListOfEvt = dart.constFn(core.List$(TemplateDescriber.Evt)))(),
MemberTemplateTovoid: () => (T$.MemberTemplateTovoid = dart.constFn(dart.fnType(dart.void, [MemberTemplate.MemberTemplate])))(),
FunctionTemplateTovoid: () => (T$.FunctionTemplateTovoid = dart.constFn(dart.fnType(dart.void, [FunctionTemplate.FunctionTemplate])))(),
PropertyTemplateTovoid: () => (T$.PropertyTemplateTovoid = dart.constFn(dart.fnType(dart.void, [PropertyTemplate.PropertyTemplate])))(),
EventTemplateTovoid: () => (T$.EventTemplateTovoid = dart.constFn(dart.fnType(dart.void, [EventTemplate.EventTemplate])))(),
JSArrayOfArgumentTemplate: () => (T$.JSArrayOfArgumentTemplate = dart.constFn(_interceptors.JSArray$(ArgumentTemplate.ArgumentTemplate)))(),
JSArrayOfTypeTemplate: () => (T$.JSArrayOfTypeTemplate = dart.constFn(_interceptors.JSArray$(TypeTemplate.TypeTemplate)))(),
PropertyTemplateToString: () => (T$.PropertyTemplateToString = dart.constFn(dart.fnType(core.String, [PropertyTemplate.PropertyTemplate])))(),
TypeTemplateTovoid: () => (T$.TypeTemplateTovoid = dart.constFn(dart.fnType(dart.void, [TypeTemplate.TypeTemplate])))(),
TypeTemplateN: () => (T$.TypeTemplateN = dart.constFn(dart.nullable(TypeTemplate.TypeTemplate)))(),
TypeTemplateNToString: () => (T$.TypeTemplateNToString = dart.constFn(dart.fnType(core.String, [T$.TypeTemplateN()])))(),
StringN: () => (T$.StringN = dart.constFn(dart.nullable(core.String)))(),
TypeTemplateToStringN: () => (T$.TypeTemplateToStringN = dart.constFn(dart.fnType(T$.StringN(), [TypeTemplate.TypeTemplate])))(),
TypeTemplateToString: () => (T$.TypeTemplateToString = dart.constFn(dart.fnType(core.String, [TypeTemplate.TypeTemplate])))(),
ConstantTemplateTovoid: () => (T$.ConstantTemplateTovoid = dart.constFn(dart.fnType(dart.void, [ConstantTemplate.ConstantTemplate])))(),
ConstantTemplateToString: () => (T$.ConstantTemplateToString = dart.constFn(dart.fnType(core.String, [ConstantTemplate.ConstantTemplate])))(),
EventTemplateTobool: () => (T$.EventTemplateTobool = dart.constFn(dart.fnType(core.bool, [EventTemplate.EventTemplate])))(),
FunctionTemplateTobool: () => (T$.FunctionTemplateTobool = dart.constFn(dart.fnType(core.bool, [FunctionTemplate.FunctionTemplate])))(),
ArgumentTemplateTobool: () => (T$.ArgumentTemplateTobool = dart.constFn(dart.fnType(core.bool, [ArgumentTemplate.ArgumentTemplate])))(),
ArgumentTemplateToString: () => (T$.ArgumentTemplateToString = dart.constFn(dart.fnType(core.String, [ArgumentTemplate.ArgumentTemplate])))(),
ArgumentTemplateTovoid: () => (T$.ArgumentTemplateTovoid = dart.constFn(dart.fnType(dart.void, [ArgumentTemplate.ArgumentTemplate])))(),
PropertyTemplateTobool: () => (T$.PropertyTemplateTobool = dart.constFn(dart.fnType(core.bool, [PropertyTemplate.PropertyTemplate])))(),
FunctionTemplateToString: () => (T$.FunctionTemplateToString = dart.constFn(dart.fnType(core.String, [FunctionTemplate.FunctionTemplate])))(),
EventTemplateToString: () => (T$.EventTemplateToString = dart.constFn(dart.fnType(core.String, [EventTemplate.EventTemplate])))(),
ProgressTypeL: () => (T$.ProgressTypeL = dart.constFn(dart.legacy(ProgressType.ProgressType)))(),
dynamicTovoid: () => (T$.dynamicTovoid = dart.constFn(dart.fnType(dart.void, [dart.dynamic])))(),
ProgressTypeAndintAndintTodynamic: () => (T$.ProgressTypeAndintAndintTodynamic = dart.constFn(dart.fnType(dart.dynamic, [ProgressType.ProgressType, core.int, core.int])))(),
JSArrayOfProgressTypeAndintAndintTodynamic: () => (T$.JSArrayOfProgressTypeAndintAndintTodynamic = dart.constFn(_interceptors.JSArray$(T$.ProgressTypeAndintAndintTodynamic())))(),
dynamicAnddynamicTodynamic: () => (T$.dynamicAnddynamicTodynamic = dart.constFn(dart.fnType(dart.dynamic, [dart.dynamic, dart.dynamic])))(),
dynamicTodynamic: () => (T$.dynamicTodynamic = dart.constFn(dart.fnType(dart.dynamic, [dart.dynamic])))(),
VoidTodynamic: () => (T$.VoidTodynamic = dart.constFn(dart.fnType(dart.dynamic, [])))(),
ObjectAndStackTraceTodynamic: () => (T$.ObjectAndStackTraceTodynamic = dart.constFn(dart.fnType(dart.dynamic, [core.Object, core.StackTrace])))(),
FunctionTovoid: () => (T$.FunctionTovoid = dart.constFn(dart.fnType(dart.void, [core.Function])))(),
FnTovoid$1: () => (T$.FnTovoid$1 = dart.constFn(dart.fnType(dart.void, [T$.ProgressTypeAndintAndintTodynamic()])))(),
ErrorTypeL: () => (T$.ErrorTypeL = dart.constFn(dart.legacy(ErrorType.ErrorType)))(),
ExceptionCodeL: () => (T$.ExceptionCodeL = dart.constFn(dart.legacy(ExceptionCode.ExceptionCode)))(),
FactoryEntryTobool: () => (T$.FactoryEntryTobool = dart.constFn(dart.fnType(core.bool, [FactoryEntry$.FactoryEntry])))(),
JSArrayOfType: () => (T$.JSArrayOfType = dart.constFn(_interceptors.JSArray$(core.Type)))(),
DistributedConnectionN: () => (T$.DistributedConnectionN = dart.constFn(dart.nullable(DistributedConnection.DistributedConnection)))(),
DCAndintAndint__ToAsyncReply: () => (T$.DCAndintAndint__ToAsyncReply = dart.constFn(dart.fnType(AsyncReply$.AsyncReply, [DC.DC, core.int, core.int, T$.DistributedConnectionN()])))(),
JSArrayOfDCAndintAndint__ToAsyncReply: () => (T$.JSArrayOfDCAndintAndint__ToAsyncReply = dart.constFn(_interceptors.JSArray$(T$.DCAndintAndint__ToAsyncReply())))(),
ListOfDCAndintAndint__ToAsyncReply: () => (T$.ListOfDCAndintAndint__ToAsyncReply = dart.constFn(core.List$(T$.DCAndintAndint__ToAsyncReply())))(),
JSArrayOfListOfDCAndintAndint__ToAsyncReply: () => (T$.JSArrayOfListOfDCAndintAndint__ToAsyncReply = dart.constFn(_interceptors.JSArray$(T$.ListOfDCAndintAndint__ToAsyncReply())))(),
DCAndintAndint__ToAsyncBag: () => (T$.DCAndintAndint__ToAsyncBag = dart.constFn(dart.fnType(AsyncBag$.AsyncBag, [DC.DC, core.int, core.int, T$.DistributedConnectionN()])))(),
dynamicAndDistributedConnectionNToDataSerializerComposeResults: () => (T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults = dart.constFn(dart.fnType(DataSerializer.DataSerializerComposeResults, [dart.dynamic, T$.DistributedConnectionN()])))(),
IResourceL: () => (T$.IResourceL = dart.constFn(dart.legacy(IResource.IResource)))(),
ListOfIResourceL: () => (T$.ListOfIResourceL = dart.constFn(core.List$(T$.IResourceL())))(),
ListOfIResourceN: () => (T$.ListOfIResourceN = dart.constFn(core.List$(T$.IResourceN())))(),
IRecordL: () => (T$.IRecordL = dart.constFn(dart.legacy(IRecord.IRecord)))(),
ListOfIRecordL: () => (T$.ListOfIRecordL = dart.constFn(core.List$(T$.IRecordL())))(),
IRecordN: () => (T$.IRecordN = dart.constFn(dart.nullable(IRecord.IRecord)))(),
ListOfIRecordN: () => (T$.ListOfIRecordN = dart.constFn(core.List$(T$.IRecordN())))(),
PropertyValueL: () => (T$.PropertyValueL = dart.constFn(dart.legacy(PropertyValue.PropertyValue)))(),
ListOfPropertyValueL: () => (T$.ListOfPropertyValueL = dart.constFn(core.List$(T$.PropertyValueL())))(),
LinkedMapOfType$dynamicAndDistributedConnectionNToDataSerializerComposeResults: () => (T$.LinkedMapOfType$dynamicAndDistributedConnectionNToDataSerializerComposeResults = dart.constFn(_js_helper.LinkedMap$(core.Type, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults())))(),
ListOfType: () => (T$.ListOfType = dart.constFn(core.List$(core.Type)))(),
IdentityMapOfint$ListOfType: () => (T$.IdentityMapOfint$ListOfType = dart.constFn(_js_helper.IdentityMap$(core.int, T$.ListOfType())))(),
TypeL: () => (T$.TypeL = dart.constFn(dart.legacy(core.Type)))(),
StringToint: () => (T$.StringToint = dart.constFn(dart.fnType(core.int, [core.String])))(),
ListOfint: () => (T$.ListOfint = dart.constFn(core.List$(core.int)))(),
ListN: () => (T$.ListN = dart.constFn(dart.nullable(core.List)))(),
AsyncReplyOfListN: () => (T$.AsyncReplyOfListN = dart.constFn(AsyncReply$.AsyncReply$(T$.ListN())))(),
KeyListOfint$DistributedResource: () => (T$.KeyListOfint$DistributedResource = dart.constFn(KeyList$.KeyList$(core.int, DistributedResource.DistributedResource)))(),
AsyncReplyOfDistributedResource: () => (T$.AsyncReplyOfDistributedResource = dart.constFn(AsyncReply$.AsyncReply$(DistributedResource.DistributedResource)))(),
KeyListOfint$AsyncReplyOfDistributedResource: () => (T$.KeyListOfint$AsyncReplyOfDistributedResource = dart.constFn(KeyList$.KeyList$(core.int, T$.AsyncReplyOfDistributedResource())))(),
AsyncReplyOfTypeTemplateN: () => (T$.AsyncReplyOfTypeTemplateN = dart.constFn(AsyncReply$.AsyncReply$(T$.TypeTemplateN())))(),
KeyListOfGuid$AsyncReplyOfTypeTemplateN: () => (T$.KeyListOfGuid$AsyncReplyOfTypeTemplateN = dart.constFn(KeyList$.KeyList$(Guid.Guid, T$.AsyncReplyOfTypeTemplateN())))(),
LinkedMapOfGuid$TypeTemplate: () => (T$.LinkedMapOfGuid$TypeTemplate = dart.constFn(_js_helper.LinkedMap$(Guid.Guid, TypeTemplate.TypeTemplate)))(),
KeyListOfint$AsyncReply: () => (T$.KeyListOfint$AsyncReply = dart.constFn(KeyList$.KeyList$(core.int, AsyncReply$.AsyncReply)))(),
AsyncQueueOfDistributedResourceQueueItem: () => (T$.AsyncQueueOfDistributedResourceQueueItem = dart.constFn(AsyncQueue$.AsyncQueue$(DistributedResourceQueueItem.DistributedResourceQueueItem)))(),
LinkedMapOfIResource$ListOfint: () => (T$.LinkedMapOfIResource$ListOfint = dart.constFn(_js_helper.LinkedMap$(IResource.IResource, T$.ListOfint())))(),
intN: () => (T$.intN = dart.constFn(dart.nullable(core.int)))(),
AsyncReplyTovoid: () => (T$.AsyncReplyTovoid = dart.constFn(dart.fnType(dart.void, [AsyncReply$.AsyncReply])))(),
AsyncReplyOfDistributedResourceTovoid: () => (T$.AsyncReplyOfDistributedResourceTovoid = dart.constFn(dart.fnType(dart.void, [T$.AsyncReplyOfDistributedResource()])))(),
AsyncReplyOfTypeTemplateNTovoid: () => (T$.AsyncReplyOfTypeTemplateNTovoid = dart.constFn(dart.fnType(dart.void, [T$.AsyncReplyOfTypeTemplateN()])))(),
DistributedResourceTovoid: () => (T$.DistributedResourceTovoid = dart.constFn(dart.fnType(dart.void, [DistributedResource.DistributedResource])))(),
DistributedResourceQueueItemN: () => (T$.DistributedResourceQueueItemN = dart.constFn(dart.nullable(DistributedResourceQueueItem.DistributedResourceQueueItem)))(),
DistributedResourceQueueItemNToNull: () => (T$.DistributedResourceQueueItemNToNull = dart.constFn(dart.fnType(core.Null, [T$.DistributedResourceQueueItemN()])))(),
dynamicToNull: () => (T$.dynamicToNull = dart.constFn(dart.fnType(core.Null, [dart.dynamic])))(),
AsyncReplyOfDistributedResourceQueueItem: () => (T$.AsyncReplyOfDistributedResourceQueueItem = dart.constFn(AsyncReply$.AsyncReply$(DistributedResourceQueueItem.DistributedResourceQueueItem)))(),
DistributedResourceToNull: () => (T$.DistributedResourceToNull = dart.constFn(dart.fnType(core.Null, [DistributedResource.DistributedResource])))(),
MapOfString$dynamicToNull: () => (T$.MapOfString$dynamicToNull = dart.constFn(dart.fnType(core.Null, [T$.MapOfString$dynamic()])))(),
dynamicTobool: () => (T$.dynamicTobool = dart.constFn(dart.fnType(core.bool, [dart.dynamic])))(),
ListToNull: () => (T$.ListToNull = dart.constFn(dart.fnType(core.Null, [core.List])))(),
IResourceTovoid: () => (T$.IResourceTovoid = dart.constFn(dart.fnType(dart.void, [IResource.IResource])))(),
AsyncExceptionTovoid: () => (T$.AsyncExceptionTovoid = dart.constFn(dart.fnType(dart.void, [AsyncException.AsyncException])))(),
ListOfPropertyValue: () => (T$.ListOfPropertyValue = dart.constFn(core.List$(PropertyValue.PropertyValue)))(),
KeyListOfPropertyTemplate$ListOfPropertyValue: () => (T$.KeyListOfPropertyTemplate$ListOfPropertyValue = dart.constFn(KeyList$.KeyList$(PropertyTemplate.PropertyTemplate, T$.ListOfPropertyValue())))(),
KeyListNOfPropertyTemplate$ListOfPropertyValue: () => (T$.KeyListNOfPropertyTemplate$ListOfPropertyValue = dart.constFn(dart.nullable(T$.KeyListOfPropertyTemplate$ListOfPropertyValue())))(),
KeyListNOfPropertyTemplate$ListOfPropertyValueToNull: () => (T$.KeyListNOfPropertyTemplate$ListOfPropertyValueToNull = dart.constFn(dart.fnType(core.Null, [T$.KeyListNOfPropertyTemplate$ListOfPropertyValue()])))(),
AsyncReplyOfTypeTemplate: () => (T$.AsyncReplyOfTypeTemplate = dart.constFn(AsyncReply$.AsyncReply$(TypeTemplate.TypeTemplate)))(),
ListNToNull: () => (T$.ListNToNull = dart.constFn(dart.fnType(core.Null, [T$.ListN()])))(),
ListOfIResourceNToNull: () => (T$.ListOfIResourceNToNull = dart.constFn(dart.fnType(core.Null, [T$.ListOfIResourceN()])))(),
AsyncExceptionToAsyncReplyOfIResourceN: () => (T$.AsyncExceptionToAsyncReplyOfIResourceN = dart.constFn(dart.fnType(T$.AsyncReplyOfIResourceN(), [AsyncException.AsyncException])))(),
AsyncReplyOfIResource: () => (T$.AsyncReplyOfIResource = dart.constFn(AsyncReply$.AsyncReply$(IResource.IResource)))(),
ListOfTypeTemplate: () => (T$.ListOfTypeTemplate = dart.constFn(core.List$(TypeTemplate.TypeTemplate)))(),
AsyncReplyOfListOfTypeTemplate: () => (T$.AsyncReplyOfListOfTypeTemplate = dart.constFn(AsyncReply$.AsyncReply$(T$.ListOfTypeTemplate())))(),
AsyncExceptionToAsyncReplyOfDistributedResource: () => (T$.AsyncExceptionToAsyncReplyOfDistributedResource = dart.constFn(dart.fnType(T$.AsyncReplyOfDistributedResource(), [AsyncException.AsyncException])))(),
DistributedResourceN: () => (T$.DistributedResourceN = dart.constFn(dart.nullable(DistributedResource.DistributedResource)))(),
DistributedResourceNToNull: () => (T$.DistributedResourceNToNull = dart.constFn(dart.fnType(core.Null, [T$.DistributedResourceN()])))(),
TypeTemplateNToNull: () => (T$.TypeTemplateNToNull = dart.constFn(dart.fnType(core.Null, [T$.TypeTemplateN()])))(),
AsyncReplyOfListOfIResourceN: () => (T$.AsyncReplyOfListOfIResourceN = dart.constFn(AsyncReply$.AsyncReply$(T$.ListOfIResourceN())))(),
AsyncExceptionToAsyncReplyOfListOfIResourceN: () => (T$.AsyncExceptionToAsyncReplyOfListOfIResourceN = dart.constFn(dart.fnType(T$.AsyncReplyOfListOfIResourceN(), [AsyncException.AsyncException])))(),
ListNToAsyncReplyOfbool: () => (T$.ListNToAsyncReplyOfbool = dart.constFn(dart.fnType(T$.AsyncReplyOfbool(), [T$.ListN()])))(),
AsyncExceptionToAsyncReplyOfbool: () => (T$.AsyncExceptionToAsyncReplyOfbool = dart.constFn(dart.fnType(T$.AsyncReplyOfbool(), [AsyncException.AsyncException])))(),
AsyncReplyOfMapOfString$dynamic: () => (T$.AsyncReplyOfMapOfString$dynamic = dart.constFn(AsyncReply$.AsyncReply$(T$.MapOfString$dynamic())))(),
AsyncExceptionToAsyncReplyOfMapOfString$dynamic: () => (T$.AsyncExceptionToAsyncReplyOfMapOfString$dynamic = dart.constFn(dart.fnType(T$.AsyncReplyOfMapOfString$dynamic(), [AsyncException.AsyncException])))(),
AsyncReplyOfKeyListNOfPropertyTemplate$ListOfPropertyValue: () => (T$.AsyncReplyOfKeyListNOfPropertyTemplate$ListOfPropertyValue = dart.constFn(AsyncReply$.AsyncReply$(T$.KeyListNOfPropertyTemplate$ListOfPropertyValue())))(),
AsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue: () => (T$.AsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue = dart.constFn(AsyncReply$.AsyncReply$(T$.KeyListOfPropertyTemplate$ListOfPropertyValue())))(),
KeyListOfPropertyTemplate$ListOfPropertyValueToAsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue: () => (T$.KeyListOfPropertyTemplate$ListOfPropertyValueToAsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue = dart.constFn(dart.fnType(T$.AsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue(), [T$.KeyListOfPropertyTemplate$ListOfPropertyValue()])))(),
AsyncExceptionToAsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue: () => (T$.AsyncExceptionToAsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue = dart.constFn(dart.fnType(T$.AsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue(), [AsyncException.AsyncException])))(),
dynamicToAsyncReplyOfListOfIResourceN: () => (T$.dynamicToAsyncReplyOfListOfIResourceN = dart.constFn(dart.fnType(T$.AsyncReplyOfListOfIResourceN(), [dart.dynamic])))(),
AsyncReplyOfDistributedResourceN: () => (T$.AsyncReplyOfDistributedResourceN = dart.constFn(AsyncReply$.AsyncReply$(T$.DistributedResourceN())))(),
KeyValuePairOfint$dynamic: () => (T$.KeyValuePairOfint$dynamic = dart.constFn(KeyValuePair$.KeyValuePair$(core.int, dart.dynamic)))(),
JSArrayOfKeyValuePairOfint$dynamic: () => (T$.JSArrayOfKeyValuePairOfint$dynamic = dart.constFn(_interceptors.JSArray$(T$.KeyValuePairOfint$dynamic())))(),
intToPropertyValue: () => (T$.intToPropertyValue = dart.constFn(dart.fnType(PropertyValue.PropertyValue, [core.int])))(),
KeyValuePairOfint$dynamicTovoid: () => (T$.KeyValuePairOfint$dynamicTovoid = dart.constFn(dart.fnType(dart.void, [T$.KeyValuePairOfint$dynamic()])))(),
DistributedResourceQueueItemTypeL: () => (T$.DistributedResourceQueueItemTypeL = dart.constFn(dart.legacy(DistributedResourceQueueItemType.DistributedResourceQueueItemType)))(),
SocketStateL: () => (T$.SocketStateL = dart.constFn(dart.legacy(SocketState.SocketState)))(),
SocketToNull: () => (T$.SocketToNull = dart.constFn(dart.fnType(core.Null, [io.Socket])))(),
AsyncReplyOfISocket: () => (T$.AsyncReplyOfISocket = dart.constFn(AsyncReply$.AsyncReply$(ISocket.ISocket)))(),
AuthenticationTypeL: () => (T$.AuthenticationTypeL = dart.constFn(dart.legacy(AuthenticationType.AuthenticationType)))(),
AuthenticationMethodL: () => (T$.AuthenticationMethodL = dart.constFn(dart.legacy(AuthenticationMethod.AuthenticationMethod)))(),
KeyListOfSourceAttributeType$dynamic: () => (T$.KeyListOfSourceAttributeType$dynamic = dart.constFn(KeyList$.KeyList$(SourceAttributeType.SourceAttributeType, dart.dynamic)))(),
SourceAttributeTypeL: () => (T$.SourceAttributeTypeL = dart.constFn(dart.legacy(SourceAttributeType.SourceAttributeType)))(),
ActionTypeL: () => (T$.ActionTypeL = dart.constFn(dart.legacy(ActionType.ActionType)))(),
RulingL: () => (T$.RulingL = dart.constFn(dart.legacy(Ruling.Ruling)))(),
TemplateTypeL: () => (T$.TemplateTypeL = dart.constFn(dart.legacy(TemplateType.TemplateType)))(),
ParseResultOfArgumentTemplate: () => (T$.ParseResultOfArgumentTemplate = dart.constFn(ParseResult$.ParseResult$(ArgumentTemplate.ArgumentTemplate)))(),
AsyncReplyOfNotModified: () => (T$.AsyncReplyOfNotModified = dart.constFn(AsyncReply$.AsyncReply$(NotModified.NotModified)))(),
AsyncReplyOfint: () => (T$.AsyncReplyOfint = dart.constFn(AsyncReply$.AsyncReply$(core.int)))(),
AsyncReplyOfString: () => (T$.AsyncReplyOfString = dart.constFn(AsyncReply$.AsyncReply$(core.String)))(),
AsyncReplyOfdouble: () => (T$.AsyncReplyOfdouble = dart.constFn(AsyncReply$.AsyncReply$(core.double)))(),
AsyncReplyOfDateTime: () => (T$.AsyncReplyOfDateTime = dart.constFn(AsyncReply$.AsyncReply$(core.DateTime)))(),
AsyncReplyOfDC: () => (T$.AsyncReplyOfDC = dart.constFn(AsyncReply$.AsyncReply$(DC.DC)))(),
AsyncReplyOfIRecord: () => (T$.AsyncReplyOfIRecord = dart.constFn(AsyncReply$.AsyncReply$(IRecord.IRecord)))(),
AsyncExceptionToAsyncReplyOfIRecord: () => (T$.AsyncExceptionToAsyncReplyOfIRecord = dart.constFn(dart.fnType(T$.AsyncReplyOfIRecord(), [AsyncException.AsyncException])))(),
AsyncExceptionToAsyncReply: () => (T$.AsyncExceptionToAsyncReply = dart.constFn(dart.fnType(AsyncReply$.AsyncReply, [AsyncException.AsyncException])))(),
AsyncBagOfPropertyValue: () => (T$.AsyncBagOfPropertyValue = dart.constFn(AsyncBag$.AsyncBag$(PropertyValue.PropertyValue)))(),
AsyncReplyOfPropertyValue: () => (T$.AsyncReplyOfPropertyValue = dart.constFn(AsyncReply$.AsyncReply$(PropertyValue.PropertyValue)))(),
ConstantTemplateTobool: () => (T$.ConstantTemplateTobool = dart.constFn(dart.fnType(core.bool, [ConstantTemplate.ConstantTemplate])))(),
ObjectN: () => (T$.ObjectN = dart.constFn(dart.nullable(core.Object)))(),
ObjectNAndObjectNToint: () => (T$.ObjectNAndObjectNToint = dart.constFn(dart.fnType(core.int, [T$.ObjectN(), T$.ObjectN()])))(),
TToT: () => (T$.TToT = dart.constFn(dart.gFnType(T => [T, [T]], T => [T$.ObjectN()])))(),
DefaultEqualityOfNeverL: () => (T$.DefaultEqualityOfNeverL = dart.constFn(equality$.DefaultEquality$(dart.legacy(dart.Never))))(),
LinkedMapOf_MapEntry$int: () => (T$.LinkedMapOf_MapEntry$int = dart.constFn(_js_helper.LinkedMap$(equality$._MapEntry, core.int)))(),
RandomN: () => (T$.RandomN = dart.constFn(dart.nullable(math.Random)))(),
TAndTToint: () => (T$.TAndTToint = dart.constFn(dart.gFnType(T => [core.int, [T, T]], T => [core.Comparable$(T)])))(),
intAndintAndRandomNTovoid: () => (T$.intAndintAndRandomNTovoid = dart.constFn(dart.fnType(dart.void, [core.int, core.int], [T$.RandomN()])))(),
intAndintTovoid: () => (T$.intAndintTovoid = dart.constFn(dart.fnType(dart.void, [core.int, core.int])))(),
ComparableOfObjectN: () => (T$.ComparableOfObjectN = dart.constFn(core.Comparable$(T$.ObjectN())))(),
StreamOfListOfint: () => (T$.StreamOfListOfint = dart.constFn(async.Stream$(T$.ListOfint())))(),
EventSinkTo_WebSocketProtocolTransformer: () => (T$.EventSinkTo_WebSocketProtocolTransformer = dart.constFn(dart.fnType(web_socket_impl._WebSocketProtocolTransformer, [async.EventSink])))(),
EventSinkOfListOfint: () => (T$.EventSinkOfListOfint = dart.constFn(async.EventSink$(T$.ListOfint())))(),
EventSinkOfListOfintTo_WebSocketOutgoingTransformer: () => (T$.EventSinkOfListOfintTo_WebSocketOutgoingTransformer = dart.constFn(dart.fnType(web_socket_impl._WebSocketOutgoingTransformer, [T$.EventSinkOfListOfint()])))(),
ListOfintTovoid: () => (T$.ListOfintTovoid = dart.constFn(dart.fnType(dart.void, [T$.ListOfint()])))(),
JSArrayOfListOfint: () => (T$.JSArrayOfListOfint = dart.constFn(_interceptors.JSArray$(T$.ListOfint())))(),
CompleterOfWebSocketImpl: () => (T$.CompleterOfWebSocketImpl = dart.constFn(async.Completer$(web_socket_impl.WebSocketImpl)))(),
dynamicAndStackTraceToNull: () => (T$.dynamicAndStackTraceToNull = dart.constFn(dart.fnType(core.Null, [dart.dynamic, core.StackTrace])))(),
dynamicToWebSocketImpl: () => (T$.dynamicToWebSocketImpl = dart.constFn(dart.fnType(web_socket_impl.WebSocketImpl, [dart.dynamic])))(),
VoidToFuture: () => (T$.VoidToFuture = dart.constFn(dart.fnType(async.Future, [])))(),
dynamicToFuture: () => (T$.dynamicToFuture = dart.constFn(dart.fnType(async.Future, [dart.dynamic])))(),
dynamicAnddynamicToNull: () => (T$.dynamicAnddynamicToNull = dart.constFn(dart.fnType(core.Null, [dart.dynamic, dart.dynamic])))(),
VoidTovoid: () => (T$.VoidTovoid = dart.constFn(dart.fnType(dart.void, [])))(),
dynamicToMap: () => (T$.dynamicToMap = dart.constFn(dart.fnType(core.Map, [dart.dynamic])))(),
IdentityMapOfint$WebSocketImpl: () => (T$.IdentityMapOfint$WebSocketImpl = dart.constFn(_js_helper.IdentityMap$(core.int, web_socket_impl.WebSocketImpl)))(),
FutureOfUint8List: () => (T$.FutureOfUint8List = dart.constFn(async.Future$(typed_data.Uint8List)))(),
StreamSubscriptionOfListOfint: () => (T$.StreamSubscriptionOfListOfint = dart.constFn(async.StreamSubscription$(T$.ListOfint())))(),
StreamSubscriptionOfListOfintAndFutureOfUint8ListToFutureOfUint8List: () => (T$.StreamSubscriptionOfListOfintAndFutureOfUint8ListToFutureOfUint8List = dart.constFn(dart.fnType(T$.FutureOfUint8List(), [T$.StreamSubscriptionOfListOfint(), T$.FutureOfUint8List()])))(),
CancelableOperationOfUint8List: () => (T$.CancelableOperationOfUint8List = dart.constFn(cancelable_operation.CancelableOperation$(typed_data.Uint8List)))(),
StreamSubscriptionOfListOfintAndFutureOfUint8ListToCancelableOperationOfUint8List: () => (T$.StreamSubscriptionOfListOfintAndFutureOfUint8ListToCancelableOperationOfUint8List = dart.constFn(dart.fnType(T$.CancelableOperationOfUint8List(), [T$.StreamSubscriptionOfListOfint(), T$.FutureOfUint8List()])))(),
CompleterOfUint8List: () => (T$.CompleterOfUint8List = dart.constFn(async.Completer$(typed_data.Uint8List)))(),
ObjectAndStackTraceToNull: () => (T$.ObjectAndStackTraceToNull = dart.constFn(dart.fnType(core.Null, [core.Object, core.StackTrace])))(),
VoidToFutureOr: () => (T$.VoidToFutureOr = dart.constFn(dart.fnType(dart.dynamic, [])))(),
ObjectAndStackTraceToErrorResult: () => (T$.ObjectAndStackTraceToErrorResult = dart.constFn(dart.fnType(error$.ErrorResult, [core.Object, core.StackTrace])))(),
ObjectL: () => (T$.ObjectL = dart.constFn(dart.legacy(core.Object)))(),
CaptureStreamTransformerOfObjectL: () => (T$.CaptureStreamTransformerOfObjectL = dart.constFn(capture_transformer.CaptureStreamTransformer$(T$.ObjectL())))(),
ReleaseStreamTransformerOfObjectL: () => (T$.ReleaseStreamTransformerOfObjectL = dart.constFn(release_transformer.ReleaseStreamTransformer$(T$.ObjectL())))(),
ResultOfObjectL: () => (T$.ResultOfObjectL = dart.constFn(result$.Result$(T$.ObjectL())))(),
ResultLOfObjectL: () => (T$.ResultLOfObjectL = dart.constFn(dart.legacy(T$.ResultOfObjectL())))(),
StreamTransformerWrapperOfObjectL$ResultLOfObjectL: () => (T$.StreamTransformerWrapperOfObjectL$ResultLOfObjectL = dart.constFn(stream_transformer_wrapper.StreamTransformerWrapper$(T$.ObjectL(), T$.ResultLOfObjectL())))(),
StreamTransformerWrapperOfResultLOfObjectL$ObjectL: () => (T$.StreamTransformerWrapperOfResultLOfObjectL$ObjectL = dart.constFn(stream_transformer_wrapper.StreamTransformerWrapper$(T$.ResultLOfObjectL(), T$.ObjectL())))(),
FutureOfNever: () => (T$.FutureOfNever = dart.constFn(async.Future$(dart.Never)))(),
FutureOfvoid: () => (T$.FutureOfvoid = dart.constFn(async.Future$(dart.void)))(),
VoidToFutureOfvoid: () => (T$.VoidToFutureOfvoid = dart.constFn(dart.fnType(T$.FutureOfvoid(), [])))(),
AsyncMemoizerOfvoid: () => (T$.AsyncMemoizerOfvoid = dart.constFn(async_memoizer.AsyncMemoizer$(dart.void)))(),
CompleterOfvoid: () => (T$.CompleterOfvoid = dart.constFn(async.Completer$(dart.void)))()
};
var T$0 = {
JSArrayOfFutureOfvoid: () => (T$0.JSArrayOfFutureOfvoid = dart.constFn(_interceptors.JSArray$(T$.FutureOfvoid())))(),
ListOfvoid: () => (T$0.ListOfvoid = dart.constFn(core.List$(dart.void)))(),
FutureOfListOfvoid: () => (T$0.FutureOfListOfvoid = dart.constFn(async.Future$(T$0.ListOfvoid())))(),
VoidToFutureOfListOfvoid: () => (T$0.VoidToFutureOfListOfvoid = dart.constFn(dart.fnType(T$0.FutureOfListOfvoid(), [])))(),
FutureNOfvoid: () => (T$0.FutureNOfvoid = dart.constFn(dart.nullable(T$.FutureOfvoid())))(),
VoidToFutureNOfvoid: () => (T$0.VoidToFutureNOfvoid = dart.constFn(dart.fnType(T$0.FutureNOfvoid(), [])))(),
StreamControllerOfNull: () => (T$0.StreamControllerOfNull = dart.constFn(async.StreamController$(core.Null)))(),
FutureN: () => (T$0.FutureN = dart.constFn(dart.nullable(async.Future)))(),
ListQueueOf_EventRequest: () => (T$0.ListQueueOf_EventRequest = dart.constFn(collection.ListQueue$(stream_queue._EventRequest)))(),
LinkedHashSetOfStreamQueue: () => (T$0.LinkedHashSetOfStreamQueue = dart.constFn(collection.LinkedHashSet$(stream_queue.StreamQueue)))(),
CompleterOfint: () => (T$0.CompleterOfint = dart.constFn(async.Completer$(core.int)))(),
CompleterOfbool: () => (T$0.CompleterOfbool = dart.constFn(async.Completer$(core.bool)))(),
ObjectAndStackTraceTovoid: () => (T$0.ObjectAndStackTraceTovoid = dart.constFn(dart.fnType(dart.void, [core.Object, core.StackTrace])))(),
intToFutureOfUint8List: () => (T$0.intToFutureOfUint8List = dart.constFn(dart.fnType(T$.FutureOfUint8List(), [core.int])))(),
SinkOfDigest: () => (T$0.SinkOfDigest = dart.constFn(core.Sink$(digest.Digest)))(),
intL: () => (T$0.intL = dart.constFn(dart.legacy(core.int)))(),
FutureOrNTovoid: () => (T$0.FutureOrNTovoid = dart.constFn(dart.fnType(dart.void, [], [dart.dynamic])))(),
StreamChannelOfString: () => (T$0.StreamChannelOfString = dart.constFn(stream_channel.StreamChannel$(core.String)))(),
ObjectNAndObjectNToObjectN: () => (T$0.ObjectNAndObjectNToObjectN = dart.constFn(dart.fnType(T$.ObjectN(), [T$.ObjectN(), T$.ObjectN()])))(),
ObjectNAndObjectNToNObjectN: () => (T$0.ObjectNAndObjectNToNObjectN = dart.constFn(dart.nullable(T$0.ObjectNAndObjectNToObjectN())))(),
String__Todynamic: () => (T$0.String__Todynamic = dart.constFn(dart.fnType(dart.dynamic, [core.String], {reviver: T$0.ObjectNAndObjectNToNObjectN()}, {})))(),
StreamSinkTransformerOfObject$String: () => (T$0.StreamSinkTransformerOfObject$String = dart.constFn(stream_sink_transformer.StreamSinkTransformer$(core.Object, core.String)))(),
EventSinkOfString: () => (T$0.EventSinkOfString = dart.constFn(async.EventSink$(core.String)))(),
ObjectAndEventSinkOfStringTovoid: () => (T$0.ObjectAndEventSinkOfStringTovoid = dart.constFn(dart.fnType(dart.void, [core.Object, T$0.EventSinkOfString()])))(),
StreamChannelOfObjectN: () => (T$0.StreamChannelOfObjectN = dart.constFn(stream_channel.StreamChannel$(T$.ObjectN())))(),
StreamSinkTransformerOfObjectN$String: () => (T$0.StreamSinkTransformerOfObjectN$String = dart.constFn(stream_sink_transformer.StreamSinkTransformer$(T$.ObjectN(), core.String)))(),
StreamTransformerOfString$ObjectN: () => (T$0.StreamTransformerOfString$ObjectN = dart.constFn(async.StreamTransformer$(core.String, T$.ObjectN())))(),
LinkedHashSetOfint: () => (T$0.LinkedHashSetOfint = dart.constFn(collection.LinkedHashSet$(core.int)))(),
JSArrayOfObjectN: () => (T$0.JSArrayOfObjectN = dart.constFn(_interceptors.JSArray$(T$.ObjectN())))(),
ListTovoid: () => (T$0.ListTovoid = dart.constFn(dart.fnType(dart.void, [core.List])))(),
StreamChannelTovoid: () => (T$0.StreamChannelTovoid = dart.constFn(dart.fnType(dart.void, [stream_channel.StreamChannel])))(),
EventToNull: () => (T$0.EventToNull = dart.constFn(dart.fnType(core.Null, [html.Event])))(),
MessageEventTovoid: () => (T$0.MessageEventTovoid = dart.constFn(dart.fnType(dart.void, [html.MessageEvent])))(),
CloseEventToNull: () => (T$0.CloseEventToNull = dart.constFn(dart.fnType(core.Null, [html.CloseEvent])))(),
EventSinkOfResult: () => (T$0.EventSinkOfResult = dart.constFn(async.EventSink$(result$.Result)))(),
EventSinkToEventSinkOfResult: () => (T$0.EventSinkToEventSinkOfResult = dart.constFn(dart.fnType(T$0.EventSinkOfResult(), [async.EventSink])))(),
FutureOrNOfvoidTovoid: () => (T$0.FutureOrNOfvoidTovoid = dart.constFn(dart.fnType(dart.void, [], [dart.void])))(),
voidToNull: () => (T$0.voidToNull = dart.constFn(dart.fnType(core.Null, [dart.void])))(),
EventSinkTovoid: () => (T$0.EventSinkTovoid = dart.constFn(dart.fnType(dart.void, [async.EventSink])))(),
TargetKindL: () => (T$0.TargetKindL = dart.constFn(dart.legacy(meta_meta.TargetKind)))(),
ListOfintN: () => (T$0.ListOfintN = dart.constFn(core.List$(T$.intN())))(),
doubleN: () => (T$0.doubleN = dart.constFn(dart.nullable(core.double)))(),
ListOfdoubleN: () => (T$0.ListOfdoubleN = dart.constFn(core.List$(T$0.doubleN())))(),
Int32x4N: () => (T$0.Int32x4N = dart.constFn(dart.nullable(typed_data.Int32x4)))(),
ListOfInt32x4N: () => (T$0.ListOfInt32x4N = dart.constFn(core.List$(T$0.Int32x4N())))(),
Float32x4N: () => (T$0.Float32x4N = dart.constFn(dart.nullable(typed_data.Float32x4)))(),
ListOfFloat32x4N: () => (T$0.ListOfFloat32x4N = dart.constFn(core.List$(T$0.Float32x4N())))()
};
var S$ = {
$containsKey: dartx.containsKey,
$_get: dartx._get,
$keys: dartx.keys,
$values: dartx.values,
$length: dartx.length,
$add: dartx.add,
$addAll: dartx.addAll,
$toList: dartx.toList,
$split: dartx.split,
$where: dartx.where,
$insert: dartx.insert,
$first: dartx.first,
$_set: dartx._set,
$elementAt: dartx.elementAt,
_Enum__name: dart.privateName(core, "_Enum._name"),
_Enum_index: dart.privateName(core, "_Enum.index"),
$firstWhere: dartx.firstWhere,
$remove: dartx.remove,
$forEach: dartx.forEach,
__Instance__children: dart.privateName(Instance, "_#Instance#_children"),
__Instance__children_isSet: dart.privateName(Instance, "_#Instance#_children#isSet"),
__Instance__parents: dart.privateName(Instance, "_#Instance#_parents"),
__Instance__parents_isSet: dart.privateName(Instance, "_#Instance#_parents#isSet"),
__Instance__template: dart.privateName(Instance, "_#Instance#_template"),
__Instance__template_isSet: dart.privateName(Instance, "_#Instance#_template#isSet"),
__Instance__managers: dart.privateName(Instance, "_#Instance#_managers"),
__Instance__managers_isSet: dart.privateName(Instance, "_#Instance#_managers#isSet"),
__Instance__attributes: dart.privateName(Instance, "_#Instance#_attributes"),
__Instance__attributes_isSet: dart.privateName(Instance, "_#Instance#_attributes#isSet"),
_ages: dart.privateName(Instance, "_ages"),
_modificationDates: dart.privateName(Instance, "_modificationDates"),
_instanceModificationDate: dart.privateName(Instance, "_instanceModificationDate"),
_id: dart.privateName(Instance, "_id"),
_name: dart.privateName(Instance, "_name"),
_resource: dart.privateName(Instance, "_resource"),
_store: dart.privateName(Instance, "_store"),
_instanceAge: dart.privateName(Instance, "_instanceAge"),
_attributes: dart.privateName(Instance, "_attributes"),
_children: dart.privateName(Instance, "_children"),
_parents: dart.privateName(Instance, "_parents"),
_managers: dart.privateName(Instance, "_managers"),
_template: dart.privateName(Instance, "_template"),
$runtimeType: dartx.runtimeType,
$join: dartx.join,
_propertyModifiedController: dart.privateName(IEventHandler, "_propertyModifiedController"),
_events: dart.privateName(IEventHandler, "_events"),
$toLowerCase: dartx.toLowerCase,
instance: dart.privateName(IResource, "IResource.instance"),
_name$1: dart.privateName(core, "_name"),
expansion: dart.privateName(EventTemplate, "EventTemplate.expansion"),
listenable: dart.privateName(EventTemplate, "EventTemplate.listenable"),
argumentType: dart.privateName(EventTemplate, "EventTemplate.argumentType"),
template: dart.privateName(MemberTemplate, "MemberTemplate.template"),
name: dart.privateName(MemberTemplate, "MemberTemplate.name"),
index: dart.privateName(MemberTemplate, "MemberTemplate.index"),
inherited: dart.privateName(MemberTemplate, "MemberTemplate.inherited"),
expansion$1: dart.privateName(FunctionTemplate, "FunctionTemplate.expansion"),
$arguments: dart.privateName(FunctionTemplate, "FunctionTemplate.arguments"),
returnType: dart.privateName(FunctionTemplate, "FunctionTemplate.returnType"),
valueType: dart.privateName(PropertyTemplate, "PropertyTemplate.valueType"),
permission: dart.privateName(PropertyTemplate, "PropertyTemplate.permission"),
recordable: dart.privateName(PropertyTemplate, "PropertyTemplate.recordable"),
readExpansion: dart.privateName(PropertyTemplate, "PropertyTemplate.readExpansion"),
writeExpansion: dart.privateName(PropertyTemplate, "PropertyTemplate.writeExpansion"),
__TypeTemplate__classId: dart.privateName(TypeTemplate, "_#TypeTemplate#_classId"),
__TypeTemplate__classId_isSet: dart.privateName(TypeTemplate, "_#TypeTemplate#_classId#isSet"),
_parentId: dart.privateName(TypeTemplate, "_parentId"),
__TypeTemplate__className: dart.privateName(TypeTemplate, "_#TypeTemplate#_className"),
__TypeTemplate__className_isSet: dart.privateName(TypeTemplate, "_#TypeTemplate#_className#isSet"),
_members: dart.privateName(TypeTemplate, "_members"),
_functions: dart.privateName(TypeTemplate, "_functions"),
_events$1: dart.privateName(TypeTemplate, "_events"),
_properties: dart.privateName(TypeTemplate, "_properties"),
_constants: dart.privateName(TypeTemplate, "_constants"),
__TypeTemplate__version: dart.privateName(TypeTemplate, "_#TypeTemplate#_version"),
__TypeTemplate__version_isSet: dart.privateName(TypeTemplate, "_#TypeTemplate#_version#isSet"),
__TypeTemplate__templateType: dart.privateName(TypeTemplate, "_#TypeTemplate#_templateType"),
__TypeTemplate__templateType_isSet: dart.privateName(TypeTemplate, "_#TypeTemplate#_templateType#isSet"),
__TypeTemplate__content: dart.privateName(TypeTemplate, "_#TypeTemplate#_content"),
__TypeTemplate__content_isSet: dart.privateName(TypeTemplate, "_#TypeTemplate#_content#isSet"),
_definedType: dart.privateName(TypeTemplate, "_definedType"),
_parentDefinedType: dart.privateName(TypeTemplate, "_parentDefinedType"),
_templateType: dart.privateName(TypeTemplate, "_templateType"),
_className: dart.privateName(TypeTemplate, "_className"),
_classId: dart.privateName(TypeTemplate, "_classId"),
_version: dart.privateName(TypeTemplate, "_version"),
$entries: dartx.entries,
$asMap: dartx.asMap,
$map: dartx.map,
_content: dart.privateName(TypeTemplate, "_content"),
properties: dart.privateName(TemplateDescriber, "TemplateDescriber.properties"),
events: dart.privateName(TemplateDescriber, "TemplateDescriber.events"),
functions: dart.privateName(TemplateDescriber, "TemplateDescriber.functions"),
constants: dart.privateName(TemplateDescriber, "TemplateDescriber.constants"),
nameSpace: dart.privateName(TemplateDescriber, "TemplateDescriber.nameSpace"),
version: dart.privateName(TemplateDescriber, "TemplateDescriber.version"),
parent: dart.privateName(TemplateDescriber, "TemplateDescriber.parent"),
name$1: dart.privateName(TemplateDescriber, "Prop.name"),
type: dart.privateName(TemplateDescriber, "Prop.type"),
readAnnotation: dart.privateName(TemplateDescriber, "Prop.readAnnotation"),
writeAnnotation: dart.privateName(TemplateDescriber, "Prop.writeAnnotation"),
name$2: dart.privateName(TemplateDescriber, "Evt.name"),
listenable$1: dart.privateName(TemplateDescriber, "Evt.listenable"),
type$1: dart.privateName(TemplateDescriber, "Evt.type"),
annotation: dart.privateName(TemplateDescriber, "Evt.annotation"),
name$3: dart.privateName(TemplateDescriber, "Const.name"),
type$2: dart.privateName(TemplateDescriber, "Const.type"),
annotation$1: dart.privateName(TemplateDescriber, "Const.annotation"),
value: dart.privateName(TemplateDescriber, "Const.value"),
name$4: dart.privateName(TemplateDescriber, "Func.name"),
returnType$1: dart.privateName(TemplateDescriber, "Func.returnType"),
argsType: dart.privateName(TemplateDescriber, "Func.argsType"),
annotation$2: dart.privateName(TemplateDescriber, "Func.annotation"),
name$5: dart.privateName(TemplateDescriber, "Arg.name"),
type$3: dart.privateName(TemplateDescriber, "Arg.type"),
optional: dart.privateName(TemplateDescriber, "Arg.optional"),
$last: dartx.last,
$singleWhere: dartx.singleWhere,
$take: dartx.take,
$replaceAll: dartx.replaceAll,
$toString: dartx.toString,
arrayType: dart.privateName(AsyncBag$, "AsyncBag.arrayType"),
_replies: dart.privateName(AsyncBag$, "_replies"),
_count: dart.privateName(AsyncBag$, "_count"),
_sealedBag: dart.privateName(AsyncBag$, "_sealedBag"),
$cast: dartx.cast,
_callbacks: dart.privateName(AsyncReply$, "_callbacks"),
__AsyncReply__result: dart.privateName(AsyncReply$, "_#AsyncReply#_result"),
__AsyncReply__result_isSet: dart.privateName(AsyncReply$, "_#AsyncReply#_result#isSet"),
_errorCallbacks: dart.privateName(AsyncReply$, "_errorCallbacks"),
_progressCallbacks: dart.privateName(AsyncReply$, "_progressCallbacks"),
_chunkCallbacks: dart.privateName(AsyncReply$, "_chunkCallbacks"),
_resultReady: dart.privateName(AsyncReply$, "_resultReady"),
_exception: dart.privateName(AsyncReply$, "_exception"),
_result: dart.privateName(AsyncReply$, "_result"),
type$4: dart.privateName(AsyncException, "AsyncException.type"),
code: dart.privateName(AsyncException, "AsyncException.code"),
message: dart.privateName(AsyncException, "AsyncException.message"),
_list: dart.privateName(AsyncQueue$, "_list"),
$removeAt: dartx.removeAt,
_list$1: dart.privateName(Tuple, "Tuple._list"),
_list$2: dart.privateName(Tuple, "_list"),
_list$3: dart.privateName(AutoList$, "_list"),
_state: dart.privateName(AutoList$, "_state"),
__AutoList__removableList: dart.privateName(AutoList$, "_#AutoList#_removableList"),
__AutoList__removableList_isSet: dart.privateName(AutoList$, "_#AutoList#_removableList#isSet"),
_removableList: dart.privateName(AutoList$, "_removableList"),
$sort: dartx.sort,
$iterator: dartx.iterator,
_itemDestroyed: dart.privateName(AutoList$, "_itemDestroyed"),
$clear: dartx.clear,
$contains: dartx.contains,
_list$4: dart.privateName(BinaryList, "_list"),
$insertAll: dartx.insertAll,
Endian__littleEndian: dart.privateName(typed_data, "Endian._littleEndian"),
transmissionTypeIdentifier: dart.privateName(Codec, "CodecComposeResults.transmissionTypeIdentifier"),
data: dart.privateName(Codec, "CodecComposeResults.data"),
reply: dart.privateName(Codec, "CodecParseResults.reply"),
size: dart.privateName(Codec, "CodecParseResults.size"),
type$5: dart.privateName(RepresentationType, "DumClass.type"),
type$6: dart.privateName(RepresentationType, "RepresentationTypeParseResults.type"),
size$1: dart.privateName(RepresentationType, "RepresentationTypeParseResults.size"),
runtimeTypes: dart.privateName(RepresentationType, "RepresentationType.runtimeTypes"),
identifier: dart.privateName(RepresentationType, "RepresentationType.identifier"),
nullable: dart.privateName(RepresentationType, "RepresentationType.nullable"),
guid: dart.privateName(RepresentationType, "RepresentationType.guid"),
subTypes: dart.privateName(RepresentationType, "RepresentationType.subTypes"),
__DC__data: dart.privateName(DC, "_#DC#_data"),
__DC__data_isSet: dart.privateName(DC, "_#DC#_data#isSet"),
__DC__dv: dart.privateName(DC, "_#DC#_dv"),
__DC__dv_isSet: dart.privateName(DC, "_#DC#_dv#isSet"),
_data: dart.privateName(DC, "_data"),
_dv: dart.privateName(DC, "_dv"),
$buffer: dartx.buffer,
$toRadixString: dartx.toRadixString,
$padLeft: dartx.padLeft,
$truncate: dartx.truncate,
$substring: dartx.substring,
$setRange: dartx.setRange,
$getRange: dartx.getRange,
$getInt8: dartx.getInt8,
$getInt16: dartx.getInt16,
$getUint16: dartx.getUint16,
$getInt32: dartx.getInt32,
$getUint32: dartx.getUint32,
$getFloat32: dartx.getFloat32,
$getFloat64: dartx.getFloat64,
$setInt8: dartx.setInt8,
$setUint8: dartx.setUint8,
$setInt16: dartx.setInt16,
$setUint16: dartx.setUint16,
$setInt32: dartx.setInt32,
$setUint32: dartx.setUint32,
$setFloat32: dartx.setFloat32,
$setFloat64: dartx.setFloat64,
$asInt8List: dartx.asInt8List,
$asUint8List: dartx.asUint8List,
$asInt16List: dartx.asInt16List,
$asUint16List: dartx.asUint16List,
$asInt32List: dartx.asInt32List,
$asUint32List: dartx.asUint32List,
$asFloat32List: dartx.asFloat32List,
$asFloat64List: dartx.asFloat64List,
$asInt64List: dartx.asInt64List,
$asUint64List: dartx.asUint64List,
$getUint64: dartx.getUint64,
$setInt64: dartx.setInt64,
$setUint64: dartx.setUint64,
__Guid__data: dart.privateName(Guid, "_#Guid#_data"),
__Guid__data_isSet: dart.privateName(Guid, "_#Guid#_data#isSet"),
_data$1: dart.privateName(Guid, "_data"),
$hashCode: dartx.hashCode,
owner: dart.privateName(KeyList$, "KeyList.owner"),
_map: dart.privateName(KeyList$, "_map"),
__KeyList__removableList: dart.privateName(KeyList$, "_#KeyList#_removableList"),
__KeyList__removableList_isSet: dart.privateName(KeyList$, "_#KeyList#_removableList#isSet"),
_removableList$1: dart.privateName(KeyList$, "_removableList"),
_itemDestroyed$1: dart.privateName(KeyList$, "_itemDestroyed"),
value$1: dart.privateName(PropertyValue, "PropertyValue.value"),
date: dart.privateName(PropertyValue, "PropertyValue.date"),
age: dart.privateName(PropertyValue, "PropertyValue.age"),
size$2: dart.privateName(SizeObject, "SizeObject.size"),
value$2: dart.privateName(ValueObject, "ValueObject.value"),
_props: dart.privateName(Record, "_props"),
index$1: dart.privateName(IEnum, "IEnum.index"),
value$3: dart.privateName(IEnum, "IEnum.value"),
name$6: dart.privateName(IEnum, "IEnum.name"),
_value: dart.privateName(IntType, "_value"),
_data$2: dart.privateName(NetworkBuffer, "_data"),
_neededDataLength: dart.privateName(NetworkBuffer, "_neededDataLength"),
_sock: dart.privateName(NetworkConnection, "_sock"),
_lastAction: dart.privateName(NetworkConnection, "_lastAction"),
_processing: dart.privateName(NetworkConnection, "_processing"),
receiver: dart.privateName(ISocket, "ISocket.receiver"),
remoteEndPoint: dart.privateName(ISocket, "ISocket.remoteEndPoint"),
localEndPoint: dart.privateName(ISocket, "ISocket.localEndPoint"),
connection: dart.privateName(SendList, "SendList.connection"),
reply$1: dart.privateName(SendList, "SendList.reply"),
variables: dart.privateName(DistributedConnection, "DistributedConnection.variables"),
instance$1: dart.privateName(DistributedConnection, "DistributedConnection.instance"),
_openReply: dart.privateName(DistributedConnection, "_openReply"),
_server: dart.privateName(DistributedConnection, "_server"),
_packet: dart.privateName(DistributedConnection, "_packet"),
_authPacket: dart.privateName(DistributedConnection, "_authPacket"),
_session: dart.privateName(DistributedConnection, "_session"),
_localPasswordOrToken: dart.privateName(DistributedConnection, "_localPasswordOrToken"),
_localNonce: dart.privateName(DistributedConnection, "_localNonce"),
_remoteNonce: dart.privateName(DistributedConnection, "_remoteNonce"),
_hostname: dart.privateName(DistributedConnection, "_hostname"),
_port: dart.privateName(DistributedConnection, "_port"),
_ready: dart.privateName(DistributedConnection, "_ready"),
_readyToEstablish: dart.privateName(DistributedConnection, "_readyToEstablish"),
_resources: dart.privateName(DistributedConnection, "_resources"),
_resourceRequests: dart.privateName(DistributedConnection, "_resourceRequests"),
_templateRequests: dart.privateName(DistributedConnection, "_templateRequests"),
_templates: dart.privateName(DistributedConnection, "_templates"),
_requests: dart.privateName(DistributedConnection, "_requests"),
_callbackCounter: dart.privateName(DistributedConnection, "_callbackCounter"),
_queue: dart.privateName(DistributedConnection, "_queue"),
_subscriptions: dart.privateName(DistributedConnection, "_subscriptions"),
_declare: dart.privateName(DistributedConnection, "_declare"),
_unsubscrive: dart.privateName(DistributedConnection, "_unsubscrive"),
_subscribe: dart.privateName(DistributedConnection, "_subscribe"),
_attributes_OnModified: dart.privateName(DistributedConnection, "_attributes_OnModified"),
_children_OnRemoved: dart.privateName(DistributedConnection, "_children_OnRemoved"),
_children_OnAdd: dart.privateName(DistributedConnection, "_children_OnAdd"),
_instance_EventOccurred: dart.privateName(DistributedConnection, "_instance_EventOccurred"),
_instance_PropertyModified: dart.privateName(DistributedConnection, "_instance_PropertyModified"),
_instance_ResourceDestroyed: dart.privateName(DistributedConnection, "_instance_ResourceDestroyed"),
value$4: dart.privateName(DistributedPropertyContext, "DistributedPropertyContext.value"),
connection$1: dart.privateName(DistributedPropertyContext, "DistributedPropertyContext.connection"),
method: dart.privateName(DistributedPropertyContext, "DistributedPropertyContext.method"),
_instanceId: dart.privateName(DistributedResource, "_instanceId"),
_connection: dart.privateName(DistributedResource, "_connection"),
_attached: dart.privateName(DistributedResource, "_attached"),
_link: dart.privateName(DistributedResource, "_link"),
_age: dart.privateName(DistributedResource, "_age"),
_properties$1: dart.privateName(DistributedResource, "_properties"),
_destroyed: dart.privateName(DistributedResource, "_destroyed"),
_queued_updates: dart.privateName(DistributedResource, "_queued_updates"),
_suspended: dart.privateName(DistributedResource, "_suspended"),
$endsWith: dartx.endsWith,
_getMemberName: dart.privateName(DistributedResource, "_getMemberName"),
type$7: dart.privateName(DistributedResourceQueueItem, "DistributedResourceQueueItem.type"),
index$2: dart.privateName(DistributedResourceQueueItem, "DistributedResourceQueueItem.index"),
value$5: dart.privateName(DistributedResourceQueueItem, "DistributedResourceQueueItem.value"),
resource: dart.privateName(DistributedResourceQueueItem, "DistributedResourceQueueItem.resource"),
command: dart.privateName(IIPAuthPacket, "IIPAuthPacket.command"),
action: dart.privateName(IIPAuthPacket, "IIPAuthPacket.action"),
errorCode: dart.privateName(IIPAuthPacket, "IIPAuthPacket.errorCode"),
errorMessage: dart.privateName(IIPAuthPacket, "IIPAuthPacket.errorMessage"),
localMethod: dart.privateName(IIPAuthPacket, "IIPAuthPacket.localMethod"),
sourceInfo: dart.privateName(IIPAuthPacket, "IIPAuthPacket.sourceInfo"),
hash: dart.privateName(IIPAuthPacket, "IIPAuthPacket.hash"),
sessionId: dart.privateName(IIPAuthPacket, "IIPAuthPacket.sessionId"),
remoteMethod: dart.privateName(IIPAuthPacket, "IIPAuthPacket.remoteMethod"),
domain: dart.privateName(IIPAuthPacket, "IIPAuthPacket.domain"),
certificateId: dart.privateName(IIPAuthPacket, "IIPAuthPacket.certificateId"),
localUsername: dart.privateName(IIPAuthPacket, "IIPAuthPacket.localUsername"),
remoteUsername: dart.privateName(IIPAuthPacket, "IIPAuthPacket.remoteUsername"),
localPassword: dart.privateName(IIPAuthPacket, "IIPAuthPacket.localPassword"),
remotePassword: dart.privateName(IIPAuthPacket, "IIPAuthPacket.remotePassword"),
localToken: dart.privateName(IIPAuthPacket, "IIPAuthPacket.localToken"),
remoteToken: dart.privateName(IIPAuthPacket, "IIPAuthPacket.remoteToken"),
asymetricEncryptionKey: dart.privateName(IIPAuthPacket, "IIPAuthPacket.asymetricEncryptionKey"),
localNonce: dart.privateName(IIPAuthPacket, "IIPAuthPacket.localNonce"),
remoteNonce: dart.privateName(IIPAuthPacket, "IIPAuthPacket.remoteNonce"),
remoteTokenIndex: dart.privateName(IIPAuthPacket, "IIPAuthPacket.remoteTokenIndex"),
_dataLengthNeeded: dart.privateName(IIPAuthPacket, "_dataLengthNeeded"),
_notEnough: dart.privateName(IIPAuthPacket, "_notEnough"),
$rightShift: dartx['>>'],
report: dart.privateName(IIPPacket, "IIPPacket.report"),
command$1: dart.privateName(IIPPacket, "IIPPacket.command"),
action$1: dart.privateName(IIPPacket, "IIPPacket.action"),
event: dart.privateName(IIPPacket, "IIPPacket.event"),
previousCommand: dart.privateName(IIPPacket, "IIPPacket.previousCommand"),
previousAction: dart.privateName(IIPPacket, "IIPPacket.previousAction"),
previousEvent: dart.privateName(IIPPacket, "IIPPacket.previousEvent"),
resourceId: dart.privateName(IIPPacket, "IIPPacket.resourceId"),
newResourceId: dart.privateName(IIPPacket, "IIPPacket.newResourceId"),
childId: dart.privateName(IIPPacket, "IIPPacket.childId"),
storeId: dart.privateName(IIPPacket, "IIPPacket.storeId"),
resourceAge: dart.privateName(IIPPacket, "IIPPacket.resourceAge"),
errorCode$1: dart.privateName(IIPPacket, "IIPPacket.errorCode"),
errorMessage$1: dart.privateName(IIPPacket, "IIPPacket.errorMessage"),
className: dart.privateName(IIPPacket, "IIPPacket.className"),
resourceLink: dart.privateName(IIPPacket, "IIPPacket.resourceLink"),
classId: dart.privateName(IIPPacket, "IIPPacket.classId"),
methodIndex: dart.privateName(IIPPacket, "IIPPacket.methodIndex"),
methodName: dart.privateName(IIPPacket, "IIPPacket.methodName"),
callbackId: dart.privateName(IIPPacket, "IIPPacket.callbackId"),
progressValue: dart.privateName(IIPPacket, "IIPPacket.progressValue"),
progressMax: dart.privateName(IIPPacket, "IIPPacket.progressMax"),
fromDate: dart.privateName(IIPPacket, "IIPPacket.fromDate"),
toDate: dart.privateName(IIPPacket, "IIPPacket.toDate"),
fromAge: dart.privateName(IIPPacket, "IIPPacket.fromAge"),
toAge: dart.privateName(IIPPacket, "IIPPacket.toAge"),
resourceName: dart.privateName(IIPPacket, "IIPPacket.resourceName"),
dataType: dart.privateName(IIPPacket, "IIPPacket.dataType"),
_dataLengthNeeded$1: dart.privateName(IIPPacket, "_dataLengthNeeded"),
_originalOffset: dart.privateName(IIPPacket, "_originalOffset"),
_notEnough$1: dart.privateName(IIPPacket, "_notEnough"),
ip: dart.privateName(IPEndPoint, "IPEndPoint.ip"),
port: dart.privateName(IPEndPoint, "IPEndPoint.port"),
sock: dart.privateName(TCPSocket, "TCPSocket.sock"),
receiveNetworkBuffer: dart.privateName(TCPSocket, "TCPSocket.receiveNetworkBuffer"),
began: dart.privateName(TCPSocket, "TCPSocket.began"),
_state$1: dart.privateName(TCPSocket, "_state"),
_localEP: dart.privateName(TCPSocket, "_localEP"),
_remoteEP: dart.privateName(TCPSocket, "_remoteEP"),
tokenIndex: dart.privateName(Authentication, "Authentication.tokenIndex"),
method$1: dart.privateName(Authentication, "Authentication.method"),
username: dart.privateName(Authentication, "Authentication.username"),
domain$1: dart.privateName(Authentication, "Authentication.domain"),
state: dart.privateName(Authentication, "Authentication.state"),
source: dart.privateName(Authentication, "Authentication.source"),
type$8: dart.privateName(Authentication, "Authentication.type"),
id: dart.privateName(Session, "Session.id"),
variables$1: dart.privateName(Session, "Session.variables"),
_localAuth: dart.privateName(Session, "_localAuth"),
_remoteAuth: dart.privateName(Session, "_remoteAuth"),
id$1: dart.privateName(Source, "Source.id"),
attributes: dart.privateName(Source, "Source.attributes"),
$leftShift: dartx['<<'],
$modulo: dartx['%'],
size$3: dart.privateName(TransmissionType, "TransmissionTypeParseResults.size"),
type$9: dart.privateName(TransmissionType, "TransmissionTypeParseResults.type"),
identifier$1: dart.privateName(TransmissionType, "TransmissionType.identifier"),
index$3: dart.privateName(TransmissionType, "TransmissionType.index"),
classType: dart.privateName(TransmissionType, "TransmissionType.classType"),
offset: dart.privateName(TransmissionType, "TransmissionType.offset"),
contentLength: dart.privateName(TransmissionType, "TransmissionType.contentLength"),
exponent: dart.privateName(TransmissionType, "TransmissionType.exponent"),
instanceCreator: dart.privateName(FactoryEntry$, "FactoryEntry.instanceCreator"),
arrayCreator: dart.privateName(FactoryEntry$, "FactoryEntry.arrayCreator"),
representationType: dart.privateName(FactoryEntry$, "FactoryEntry.representationType"),
__FactoryEntry_nullableType: dart.privateName(FactoryEntry$, "_#FactoryEntry#nullableType"),
__FactoryEntry_nullableType_isSet: dart.privateName(FactoryEntry$, "_#FactoryEntry#nullableType#isSet"),
eventTemplate: dart.privateName(EventOccurredInfo, "EventOccurredInfo.eventTemplate"),
resource$1: dart.privateName(EventOccurredInfo, "EventOccurredInfo.resource"),
value$6: dart.privateName(EventOccurredInfo, "EventOccurredInfo.value"),
issuer: dart.privateName(EventOccurredInfo, "EventOccurredInfo.issuer"),
receivers: dart.privateName(EventOccurredInfo, "EventOccurredInfo.receivers"),
propertyTemplate: dart.privateName(PropertyModificationInfo, "PropertyModificationInfo.propertyTemplate"),
value$7: dart.privateName(PropertyModificationInfo, "PropertyModificationInfo.value"),
age$1: dart.privateName(PropertyModificationInfo, "PropertyModificationInfo.age"),
resource$2: dart.privateName(PropertyModificationInfo, "PropertyModificationInfo.resource"),
name$7: dart.privateName(ArgumentTemplate, "ArgumentTemplate.name"),
optional$1: dart.privateName(ArgumentTemplate, "ArgumentTemplate.optional"),
type$10: dart.privateName(ArgumentTemplate, "ArgumentTemplate.type"),
index$4: dart.privateName(ArgumentTemplate, "ArgumentTemplate.index"),
value$8: dart.privateName(ConstantTemplate, "ConstantTemplate.value"),
expansion$2: dart.privateName(ConstantTemplate, "ConstantTemplate.expansion"),
valueType$1: dart.privateName(ConstantTemplate, "ConstantTemplate.valueType"),
size$4: dart.privateName(DataDeserializer, "PropertyValueParserResults.size"),
reply$2: dart.privateName(DataDeserializer, "PropertyValueParserResults.reply"),
identifier$2: dart.privateName(DataSerializer, "DataSerializerComposeResults.identifier"),
data$1: dart.privateName(DataSerializer, "DataSerializerComposeResults.data"),
$isEmpty: dartx.isEmpty,
resource$3: dart.privateName(PropertyModificationInfo$, "PropertyModificationInfo.resource"),
propertyTemplate$1: dart.privateName(PropertyModificationInfo$, "PropertyModificationInfo.propertyTemplate"),
age$2: dart.privateName(PropertyModificationInfo$, "PropertyModificationInfo.age"),
value$9: dart.privateName(PropertyModificationInfo$, "PropertyModificationInfo.value"),
receiveNetworkBuffer$1: dart.privateName(WSocket, "WSocket.receiveNetworkBuffer"),
began$1: dart.privateName(WSocket, "WSocket.began"),
secure: dart.privateName(WSocket, "WSocket.secure"),
_channel: dart.privateName(WSocket, "_channel"),
_state$2: dart.privateName(WSocket, "_state"),
_localEP$1: dart.privateName(WSocket, "_localEP"),
_remoteEP$1: dart.privateName(WSocket, "_remoteEP"),
_dataHandler: dart.privateName(WSocket, "_dataHandler"),
entryPoint: dart.privateName(DistributedServer, "DistributedServer.entryPoint"),
key: dart.privateName(KeyValuePair$, "KeyValuePair.key"),
value$10: dart.privateName(KeyValuePair$, "KeyValuePair.value"),
size$5: dart.privateName(ParseResult$, "ParseResult.size"),
value$11: dart.privateName(ParseResult$, "ParseResult.value"),
_base: dart.privateName(canonicalized_map, "_base"),
_canonicalize: dart.privateName(canonicalized_map, "_canonicalize"),
_isValidKeyFn: dart.privateName(canonicalized_map, "_isValidKeyFn"),
_isValidKey: dart.privateName(canonicalized_map, "_isValidKey"),
$addEntries: dartx.addEntries,
$any: dartx.any,
$isNotEmpty: dartx.isNotEmpty,
$putIfAbsent: dartx.putIfAbsent,
$removeWhere: dartx.removeWhere,
$update: dartx.update,
$updateAll: dartx.updateAll,
$containsValue: dartx.containsValue,
_iterables: dart.privateName(combined_iterable, "CombinedIterableView._iterables"),
_iterables$1: dart.privateName(combined_iterable, "_iterables"),
$every: dartx.every,
$fold: dartx.fold,
_lists: dart.privateName(combined_list, "_lists"),
_source: dart.privateName(combined_list, "_source"),
$noSuchMethod: dartx.noSuchMethod,
_source$1: dart.privateName(collection, "_source"),
_maps: dart.privateName(combined_map, "_maps"),
_iterable: dart.privateName(combined_map, "_DeduplicatingIterableView._iterable"),
_iterable$1: dart.privateName(combined_map, "_iterable"),
_emitted: dart.privateName(combined_map, "_emitted"),
_iterator: dart.privateName(combined_map, "_iterator"),
$codeUnitAt: dartx.codeUnitAt,
$sign: dartx.sign,
_comparisonKey: dart.privateName(equality$, "_comparisonKey"),
_inner: dart.privateName(equality$, "_inner"),
_elementEquality: dart.privateName(equality$, "IterableEquality._elementEquality"),
_elementEquality$1: dart.privateName(equality$, "_elementEquality"),
_elementEquality$2: dart.privateName(equality$, "ListEquality._elementEquality"),
_elementEquality$3: dart.privateName(equality$, "_UnorderedEquality._elementEquality"),
_keyEquality: dart.privateName(equality$, "_keyEquality"),
_valueEquality: dart.privateName(equality$, "_valueEquality"),
_keyEquality$1: dart.privateName(equality$, "MapEquality._keyEquality"),
_valueEquality$1: dart.privateName(equality$, "MapEquality._valueEquality"),
_equalities: dart.privateName(equality$, "MultiEquality._equalities"),
_equalities$1: dart.privateName(equality$, "_equalities"),
_base$1: dart.privateName(equality$, "DeepCollectionEquality._base"),
_unordered: dart.privateName(equality$, "DeepCollectionEquality._unordered"),
_base$2: dart.privateName(equality$, "_base"),
_unordered$1: dart.privateName(equality$, "_unordered"),
_base$3: dart.privateName(wrappers, "DelegatingMap._base"),
_base$4: dart.privateName(wrappers, "_base"),
_base$5: dart.privateName(wrappers, "DelegatingSet._base"),
$expand: dartx.expand,
$followedBy: dartx.followedBy,
$lastWhere: dartx.lastWhere,
$reduce: dartx.reduce,
$single: dartx.single,
$skip: dartx.skip,
$skipWhile: dartx.skipWhile,
$takeWhile: dartx.takeWhile,
$toSet: dartx.toSet,
$whereType: dartx.whereType,
$removeLast: dartx.removeLast,
$reversed: dartx.reversed,
$compareTo: dartx.compareTo,
$remainder: dartx.remainder,
_iterables$2: dart.privateName(iterable_zip, "_iterables"),
_current: dart.privateName(iterable_zip, "_current"),
_iterators: dart.privateName(iterable_zip, "_iterators"),
source$1: dart.privateName(list_extensions, "ListSlice.source"),
start: dart.privateName(list_extensions, "ListSlice.start"),
length: dart.privateName(list_extensions, "ListSlice.length"),
_initialSize: dart.privateName(list_extensions, "_initialSize"),
comparison: dart.privateName(priority_queue, "HeapPriorityQueue.comparison"),
_queue$1: dart.privateName(priority_queue, "_queue"),
_length: dart.privateName(priority_queue, "_length"),
_modificationCount: dart.privateName(priority_queue, "_modificationCount"),
_elementAt: dart.privateName(priority_queue, "_elementAt"),
_add: dart.privateName(priority_queue, "_add"),
_locate: dart.privateName(priority_queue, "_locate"),
_removeLast: dart.privateName(priority_queue, "_removeLast"),
_bubbleUp: dart.privateName(priority_queue, "_bubbleUp"),
_bubbleDown: dart.privateName(priority_queue, "_bubbleDown"),
_toUnorderedList: dart.privateName(priority_queue, "_toUnorderedList"),
_grow: dart.privateName(priority_queue, "_grow"),
$isOdd: dartx.isOdd,
_current$1: dart.privateName(priority_queue, "_current"),
_index: dart.privateName(priority_queue, "_index"),
_initialModificationCount: dart.privateName(priority_queue, "_initialModificationCount"),
_head: dart.privateName(queue_list, "QueueList._head")
};
var S$0 = {
_tail: dart.privateName(queue_list, "QueueList._tail"),
_table: dart.privateName(queue_list, "_table"),
_head$1: dart.privateName(queue_list, "_head"),
_tail$1: dart.privateName(queue_list, "_tail"),
_add$1: dart.privateName(queue_list, "_add"),
_preGrow: dart.privateName(queue_list, "_preGrow"),
_grow$1: dart.privateName(queue_list, "_grow"),
$fillRange: dartx.fillRange,
_writeToList: dart.privateName(queue_list, "_writeToList"),
_delegate: dart.privateName(queue_list, "_delegate"),
_sets: dart.privateName(union_set, "_sets"),
_disjoint: dart.privateName(union_set, "_disjoint"),
_iterable$2: dart.privateName(union_set, "_iterable"),
set: dart.privateName(union_set_controller, "UnionSetController.set"),
_sets$1: dart.privateName(union_set_controller, "_sets"),
_base$6: dart.privateName(wrappers, "DelegatingList._base"),
$plus: dartx['+'],
$indexOf: dartx.indexOf,
$indexWhere: dartx.indexWhere,
$lastIndexOf: dartx.lastIndexOf,
$lastIndexWhere: dartx.lastIndexWhere,
$removeRange: dartx.removeRange,
$replaceRange: dartx.replaceRange,
$retainWhere: dartx.retainWhere,
$setAll: dartx.setAll,
$shuffle: dartx.shuffle,
$sublist: dartx.sublist,
_base$7: dart.privateName(wrappers, "DelegatingIterable._base"),
_base$8: dart.privateName(wrappers, "DelegatingQueue._base"),
_baseMap: dart.privateName(wrappers, "_baseMap"),
_keyForValue: dart.privateName(wrappers, "_keyForValue"),
_iterators$1: dart.privateName(combined_iterator, "_iterators"),
_base$9: dart.privateName(empty_unmodifiable_set, "_base"),
_webSocket: dart.privateName(channel$, "_webSocket"),
$codeUnits: dartx.codeUnits,
_sink: dart.privateName(stream_sink, "_sink"),
message$1: dart.privateName(exception, "WebSocketChannelException.message"),
inner: dart.privateName(exception, "WebSocketChannelException.inner"),
_state$3: dart.privateName(web_socket_impl, "_state"),
_fin: dart.privateName(web_socket_impl, "_fin"),
_opcode: dart.privateName(web_socket_impl, "_opcode"),
_len: dart.privateName(web_socket_impl, "_len"),
_masked: dart.privateName(web_socket_impl, "_masked"),
_remainingLenBytes: dart.privateName(web_socket_impl, "_remainingLenBytes"),
_remainingMaskingKeyBytes: dart.privateName(web_socket_impl, "_remainingMaskingKeyBytes"),
_remainingPayloadBytes: dart.privateName(web_socket_impl, "_remainingPayloadBytes"),
_unmaskingIndex: dart.privateName(web_socket_impl, "_unmaskingIndex"),
_currentMessageType: dart.privateName(web_socket_impl, "_currentMessageType"),
_eventSink: dart.privateName(web_socket_impl, "_eventSink"),
_maskingBytes: dart.privateName(web_socket_impl, "_maskingBytes"),
_payload: dart.privateName(web_socket_impl, "_payload"),
_serverSide: dart.privateName(web_socket_impl, "_serverSide"),
_isControlFrame: dart.privateName(web_socket_impl, "_isControlFrame"),
_lengthDone: dart.privateName(web_socket_impl, "_lengthDone"),
_maskDone: dart.privateName(web_socket_impl, "_maskDone"),
_unmask: dart.privateName(web_socket_impl, "_unmask"),
_controlFrameEnd: dart.privateName(web_socket_impl, "_controlFrameEnd"),
_messageFrameEnd: dart.privateName(web_socket_impl, "_messageFrameEnd"),
_startPayload: dart.privateName(web_socket_impl, "_startPayload"),
_prepareForNextFrame: dart.privateName(web_socket_impl, "_prepareForNextFrame"),
_outCloseCode: dart.privateName(web_socket_impl, "_outCloseCode"),
_outCloseReason: dart.privateName(web_socket_impl, "_outCloseReason"),
_controller: dart.privateName(web_socket_impl, "_controller"),
_subscription: dart.privateName(web_socket_impl, "_subscription"),
_issuedPause: dart.privateName(web_socket_impl, "_issuedPause"),
_closed: dart.privateName(web_socket_impl, "_closed"),
_closeCompleter: dart.privateName(web_socket_impl, "_closeCompleter"),
_completer: dart.privateName(web_socket_impl, "_completer"),
_onListen: dart.privateName(web_socket_impl, "_onListen"),
_onPause: dart.privateName(web_socket_impl, "_onPause"),
_onResume: dart.privateName(web_socket_impl, "_onResume"),
_cancel: dart.privateName(web_socket_impl, "_cancel"),
_done: dart.privateName(web_socket_impl, "_done"),
_ensureController: dart.privateName(web_socket_impl, "_ensureController"),
protocol: dart.privateName(web_socket_impl, "WebSocketImpl.protocol"),
__WebSocketImpl__controller: dart.privateName(web_socket_impl, "_#WebSocketImpl#_controller"),
__WebSocketImpl__controller_isSet: dart.privateName(web_socket_impl, "_#WebSocketImpl#_controller#isSet"),
__WebSocketImpl__sink: dart.privateName(web_socket_impl, "_#WebSocketImpl#_sink"),
__WebSocketImpl__sink_isSet: dart.privateName(web_socket_impl, "_#WebSocketImpl#_sink#isSet"),
_readyState: dart.privateName(web_socket_impl, "_readyState"),
_writeClosed: dart.privateName(web_socket_impl, "_writeClosed"),
_closeCode: dart.privateName(web_socket_impl, "_closeCode"),
_closeReason: dart.privateName(web_socket_impl, "_closeReason"),
_pingInterval: dart.privateName(web_socket_impl, "_pingInterval"),
_pingTimer: dart.privateName(web_socket_impl, "_pingTimer"),
__WebSocketImpl__consumer: dart.privateName(web_socket_impl, "_#WebSocketImpl#_consumer"),
__WebSocketImpl__consumer_isSet: dart.privateName(web_socket_impl, "_#WebSocketImpl#_consumer#isSet"),
_closeTimer: dart.privateName(web_socket_impl, "_closeTimer"),
_consumer: dart.privateName(web_socket_impl, "_consumer"),
_sink$1: dart.privateName(web_socket_impl, "_sink"),
_close: dart.privateName(web_socket_impl, "_close"),
_serviceId: dart.privateName(web_socket_impl, "_serviceId"),
Duration__duration: dart.privateName(core, "Duration._duration"),
__serviceId: dart.privateName(web_socket_impl, "_ServiceObject.__serviceId"),
__serviceId$1: dart.privateName(web_socket_impl, "__serviceId"),
_cachedStreamSplitter: dart.privateName(async_cache, "_cachedStreamSplitter"),
_cachedValueFuture: dart.privateName(async_cache, "_cachedValueFuture"),
_stale: dart.privateName(async_cache, "_stale"),
_duration: dart.privateName(async_cache, "_duration"),
_startStaleTimer: dart.privateName(async_cache, "_startStaleTimer"),
_completer$1: dart.privateName(async_memoizer, "_completer"),
_completer$2: dart.privateName(cancelable_operation, "_completer"),
_inner$1: dart.privateName(cancelable_operation, "_inner"),
_cancel$1: dart.privateName(cancelable_operation, "_cancel"),
_cancelMemo: dart.privateName(cancelable_operation, "_cancelMemo"),
__CancelableCompleter_operation: dart.privateName(cancelable_operation, "_#CancelableCompleter#operation"),
__CancelableCompleter_operation_isSet: dart.privateName(cancelable_operation, "_#CancelableCompleter#operation#isSet"),
_isCompleted: dart.privateName(cancelable_operation, "_isCompleted"),
_isCanceled: dart.privateName(cancelable_operation, "_isCanceled"),
_onCancel: dart.privateName(cancelable_operation, "_onCancel"),
_sink$2: dart.privateName(event_sink, "_sink"),
_future: dart.privateName(future, "_future"),
_sink$3: dart.privateName(sink$, "_sink"),
_consumer$1: dart.privateName(stream_consumer, "_consumer"),
_source$2: dart.privateName(stream_subscription, "_source"),
_pending: dart.privateName(future_group, "_pending"),
_closed$1: dart.privateName(future_group, "_closed"),
_completer$3: dart.privateName(future_group, "_completer"),
_onIdleController: dart.privateName(future_group, "_onIdleController"),
_values: dart.privateName(future_group, "_values"),
_callback: dart.privateName(lazy_stream, "_callback"),
done: dart.privateName(null_stream_sink, "NullStreamSink.done"),
_closed$2: dart.privateName(null_stream_sink, "_closed"),
_addingStream: dart.privateName(null_stream_sink, "_addingStream"),
_checkEventAllowed: dart.privateName(null_stream_sink, "_checkEventAllowed"),
_duration$1: dart.privateName(restartable_timer, "_duration"),
_callback$1: dart.privateName(restartable_timer, "_callback"),
_timer: dart.privateName(restartable_timer, "_timer"),
StreamTransformerWrapper__transformer: dart.privateName(stream_transformer_wrapper, "StreamTransformerWrapper._transformer"),
error: dart.privateName(error$, "ErrorResult.error"),
stackTrace: dart.privateName(error$, "ErrorResult.stackTrace"),
_result$1: dart.privateName(future$, "_result"),
value$12: dart.privateName(value$, "ValueResult.value"),
_closeMemo: dart.privateName(sink_base, "_closeMemo"),
_closed$3: dart.privateName(sink_base, "_closed"),
_checkCanAddEvent: dart.privateName(sink_base, "_checkCanAddEvent"),
_addingStream$1: dart.privateName(sink_base, "_addingStream"),
encoding: dart.privateName(sink_base, "IOSinkBase.encoding"),
Utf8Codec__allowMalformed: dart.privateName(convert, "Utf8Codec._allowMalformed"),
_subscriptions$1: dart.privateName(stream_closer, "_subscriptions"),
_controllers: dart.privateName(stream_closer, "_controllers"),
_closeFuture: dart.privateName(stream_closer, "_closeFuture"),
_stream: dart.privateName(stream_completer, "_stream"),
_isSourceStreamSet: dart.privateName(stream_completer, "_isSourceStreamSet"),
_setSourceStream: dart.privateName(stream_completer, "_setSourceStream"),
_setEmpty: dart.privateName(stream_completer, "_setEmpty"),
_controller$1: dart.privateName(stream_completer, "_controller"),
_sourceStream: dart.privateName(stream_completer, "_sourceStream"),
_ensureController$1: dart.privateName(stream_completer, "_ensureController"),
_linkStreamToController: dart.privateName(stream_completer, "_linkStreamToController"),
__StreamGroup__controller: dart.privateName(stream_group, "_#StreamGroup#_controller"),
__StreamGroup__controller_isSet: dart.privateName(stream_group, "_#StreamGroup#_controller#isSet"),
_closed$4: dart.privateName(stream_group, "_closed"),
_state$4: dart.privateName(stream_group, "_state"),
_onIdleController$1: dart.privateName(stream_group, "_onIdleController"),
_subscriptions$2: dart.privateName(stream_group, "_subscriptions"),
_controller$2: dart.privateName(stream_group, "_controller"),
_onListen$1: dart.privateName(stream_group, "_onListen"),
_onPause$1: dart.privateName(stream_group, "_onPause"),
_onResume$1: dart.privateName(stream_group, "_onResume"),
_onCancel$1: dart.privateName(stream_group, "_onCancel"),
_onCancelBroadcast: dart.privateName(stream_group, "_onCancelBroadcast"),
_listenToStream: dart.privateName(stream_group, "_listenToStream"),
name$8: dart.privateName(stream_group, "_StreamGroupState.name"),
_subscription$1: dart.privateName(stream_queue, "_subscription"),
_isDone: dart.privateName(stream_queue, "_isDone"),
_isClosed: dart.privateName(stream_queue, "_isClosed"),
_eventsReceived: dart.privateName(stream_queue, "_eventsReceived"),
_eventQueue: dart.privateName(stream_queue, "_eventQueue"),
_requestQueue: dart.privateName(stream_queue, "_requestQueue"),
_source$3: dart.privateName(stream_queue, "_source"),
_ensureListening: dart.privateName(stream_queue, "_ensureListening"),
_pause: dart.privateName(stream_queue, "_pause"),
_checkNotClosed: dart.privateName(stream_queue, "_checkNotClosed"),
_addRequest: dart.privateName(stream_queue, "_addRequest"),
_cancel$2: dart.privateName(stream_queue, "_cancel"),
_updateRequests: dart.privateName(stream_queue, "_updateRequests"),
_extractStream: dart.privateName(stream_queue, "_extractStream"),
_addResult: dart.privateName(stream_queue, "_addResult"),
_close$1: dart.privateName(stream_queue, "_close"),
_queues: dart.privateName(stream_queue, "_queues"),
_committed: dart.privateName(stream_queue, "_committed"),
_rejected: dart.privateName(stream_queue, "_rejected"),
_parent: dart.privateName(stream_queue, "_parent"),
_splitter: dart.privateName(stream_queue, "_splitter"),
_assertActive: dart.privateName(stream_queue, "_assertActive"),
_done$1: dart.privateName(stream_queue, "_done"),
_completer$4: dart.privateName(stream_queue, "_completer"),
_eventsToSkip: dart.privateName(stream_queue, "_eventsToSkip"),
_list$5: dart.privateName(stream_queue, "_list"),
_eventsToTake: dart.privateName(stream_queue, "_eventsToTake"),
_streamQueue: dart.privateName(stream_queue, "_streamQueue"),
___TransactionRequest_transaction: dart.privateName(stream_queue, "_#_TransactionRequest#transaction"),
___TransactionRequest_transaction_isSet: dart.privateName(stream_queue, "_#_TransactionRequest#transaction#isSet"),
_controller$3: dart.privateName(stream_queue, "_controller"),
_eventsSent: dart.privateName(stream_queue, "_eventsSent"),
sink: dart.privateName(stream_sink_completer, "StreamSinkCompleter.sink"),
_sink$4: dart.privateName(stream_sink_completer, "_sink"),
_destinationSink: dart.privateName(stream_sink_completer, "_destinationSink"),
_setDestinationSink: dart.privateName(stream_sink_completer, "_setDestinationSink"),
_controller$4: dart.privateName(stream_sink_completer, "_controller"),
_doneCompleter: dart.privateName(stream_sink_completer, "_doneCompleter"),
_canSendDirectly: dart.privateName(stream_sink_completer, "_canSendDirectly"),
_ensureController$2: dart.privateName(stream_sink_completer, "_ensureController"),
_subscription$2: dart.privateName(stream_splitter, "_subscription"),
_buffer: dart.privateName(stream_splitter, "_buffer"),
_controllers$1: dart.privateName(stream_splitter, "_controllers"),
_closeGroup: dart.privateName(stream_splitter, "_closeGroup"),
_isDone$1: dart.privateName(stream_splitter, "_isDone"),
_isClosed$1: dart.privateName(stream_splitter, "_isClosed"),
_stream$1: dart.privateName(stream_splitter, "_stream"),
_onListen$2: dart.privateName(stream_splitter, "_onListen"),
_onPause$2: dart.privateName(stream_splitter, "_onPause"),
_onResume$2: dart.privateName(stream_splitter, "_onResume"),
_onCancel$2: dart.privateName(stream_splitter, "_onCancel"),
_cancelSubscription: dart.privateName(stream_splitter, "_cancelSubscription"),
_onData: dart.privateName(stream_splitter, "_onData"),
_onError: dart.privateName(stream_splitter, "_onError"),
_onDone: dart.privateName(stream_splitter, "_onDone"),
_cancelMemoizer: dart.privateName(stream_subscription_transformer, "_cancelMemoizer"),
_inner$2: dart.privateName(stream_subscription_transformer, "_inner"),
_handleCancel: dart.privateName(stream_subscription_transformer, "_handleCancel"),
_handlePause: dart.privateName(stream_subscription_transformer, "_handlePause"),
_handleResume: dart.privateName(stream_subscription_transformer, "_handleResume"),
_streams: dart.privateName(stream_zip, "_streams"),
_source$4: dart.privateName(subscription_stream, "_source"),
_inner$3: dart.privateName(typed_stream_transformer, "_inner"),
_emptyList: dart.privateName(chunked_stream_reader, "_emptyList"),
_buffer$1: dart.privateName(chunked_stream_reader, "_buffer"),
_offset: dart.privateName(chunked_stream_reader, "_offset"),
_reading: dart.privateName(chunked_stream_reader, "_reading"),
_input: dart.privateName(chunked_stream_reader, "_input"),
bytes: dart.privateName(digest, "Digest.bytes"),
_hash: dart.privateName(hmac, "_hash"),
_key: dart.privateName(hmac, "_key"),
_innerResultSink: dart.privateName(hmac, "_innerResultSink"),
___HmacSink__innerSink: dart.privateName(hmac, "_#_HmacSink#_innerSink"),
___HmacSink__innerSink_isSet: dart.privateName(hmac, "_#_HmacSink#_innerSink#isSet"),
_isClosed$2: dart.privateName(hmac, "_isClosed"),
_outerSink: dart.privateName(hmac, "_outerSink"),
_innerSink: dart.privateName(hmac, "_innerSink"),
blockSize: dart.privateName(md5, "_MD5.blockSize"),
digest: dart.privateName(md5, "_MD5Sink.digest"),
_lengthInBytes: dart.privateName(hash_sink, "_lengthInBytes"),
_pendingData: dart.privateName(hash_sink, "_pendingData"),
_isClosed$3: dart.privateName(hash_sink, "_isClosed"),
_sink$5: dart.privateName(hash_sink, "_sink"),
_endian: dart.privateName(hash_sink, "_endian"),
_signatureBytes: dart.privateName(hash_sink, "_signatureBytes"),
_currentChunk: dart.privateName(hash_sink, "_currentChunk"),
_iterate: dart.privateName(hash_sink, "_iterate"),
_finalizeData: dart.privateName(hash_sink, "_finalizeData"),
_byteDigest: dart.privateName(hash_sink, "_byteDigest"),
$lengthInBytes: dartx.lengthInBytes,
$asByteData: dartx.asByteData,
_roundUp: dart.privateName(hash_sink, "_roundUp"),
blockSize$1: dart.privateName(sha1, "_Sha1.blockSize"),
digest$1: dart.privateName(sha1, "_Sha1Sink.digest"),
_extended: dart.privateName(sha1, "_extended"),
blockSize$2: dart.privateName(sha256, "_Sha256.blockSize"),
blockSize$3: dart.privateName(sha256, "_Sha224.blockSize"),
_extended$1: dart.privateName(sha256, "_extended"),
_digest: dart.privateName(sha256, "_digest"),
_rotr32: dart.privateName(sha256, "_rotr32"),
_ch: dart.privateName(sha256, "_ch"),
_maj: dart.privateName(sha256, "_maj"),
_bsig0: dart.privateName(sha256, "_bsig0"),
_bsig1: dart.privateName(sha256, "_bsig1"),
_ssig0: dart.privateName(sha256, "_ssig0"),
_ssig1: dart.privateName(sha256, "_ssig1"),
blockSize$4: dart.privateName(sha512, "_Sha384.blockSize"),
blockSize$5: dart.privateName(sha512, "_Sha512.blockSize"),
blockSize$6: dart.privateName(sha512, "_Sha512224.blockSize"),
blockSize$7: dart.privateName(sha512, "_Sha512256.blockSize"),
__GuaranteeChannel__sink: dart.privateName(guarantee_channel, "_#GuaranteeChannel#_sink"),
__GuaranteeChannel__sink_isSet: dart.privateName(guarantee_channel, "_#GuaranteeChannel#_sink#isSet"),
__GuaranteeChannel__streamController: dart.privateName(guarantee_channel, "_#GuaranteeChannel#_streamController"),
__GuaranteeChannel__streamController_isSet: dart.privateName(guarantee_channel, "_#GuaranteeChannel#_streamController#isSet"),
_subscription$3: dart.privateName(guarantee_channel, "_subscription"),
_disconnected: dart.privateName(guarantee_channel, "_disconnected"),
_sink$6: dart.privateName(guarantee_channel, "_sink"),
_streamController: dart.privateName(guarantee_channel, "_streamController"),
_onStreamDisconnected: dart.privateName(guarantee_channel, "_onStreamDisconnected"),
_onSinkDisconnected: dart.privateName(guarantee_channel, "_onSinkDisconnected"),
_doneCompleter$1: dart.privateName(guarantee_channel, "_doneCompleter"),
_closed$5: dart.privateName(guarantee_channel, "_closed"),
_addStreamSubscription: dart.privateName(guarantee_channel, "_addStreamSubscription"),
_addStreamCompleter: dart.privateName(guarantee_channel, "_addStreamCompleter"),
_inner$4: dart.privateName(guarantee_channel, "_inner"),
_channel$1: dart.privateName(guarantee_channel, "_channel"),
_allowErrors: dart.privateName(guarantee_channel, "_allowErrors"),
_inAddStream: dart.privateName(guarantee_channel, "_inAddStream"),
_addError: dart.privateName(guarantee_channel, "_addError"),
_subscription$4: dart.privateName(close_guarantee_channel, "CloseGuaranteeChannel._subscription"),
__CloseGuaranteeChannel__stream: dart.privateName(close_guarantee_channel, "_#CloseGuaranteeChannel#_stream"),
__CloseGuaranteeChannel__stream_isSet: dart.privateName(close_guarantee_channel, "_#CloseGuaranteeChannel#_stream#isSet"),
__CloseGuaranteeChannel__sink: dart.privateName(close_guarantee_channel, "_#CloseGuaranteeChannel#_sink"),
__CloseGuaranteeChannel__sink_isSet: dart.privateName(close_guarantee_channel, "_#CloseGuaranteeChannel#_sink#isSet"),
_disconnected$1: dart.privateName(close_guarantee_channel, "_disconnected"),
_sink$7: dart.privateName(close_guarantee_channel, "_sink"),
_stream$2: dart.privateName(close_guarantee_channel, "_stream"),
_subscription$5: dart.privateName(close_guarantee_channel, "_subscription"),
_inner$5: dart.privateName(close_guarantee_channel, "_inner"),
_channel$2: dart.privateName(close_guarantee_channel, "_channel"),
_streamTransformer: dart.privateName(stream_channel_transformer, "StreamChannelTransformer._streamTransformer"),
_sinkTransformer: dart.privateName(stream_channel_transformer, "StreamChannelTransformer._sinkTransformer"),
_streamTransformer$1: dart.privateName(stream_channel_transformer, "_streamTransformer"),
_sinkTransformer$1: dart.privateName(stream_channel_transformer, "_sinkTransformer"),
_inner$6: dart.privateName(delegating_stream_channel, "_inner"),
_sinks: dart.privateName(disconnector, "_sinks"),
_disconnectMemo: dart.privateName(disconnector, "_disconnectMemo"),
_disconnect: dart.privateName(disconnector, "_disconnect"),
_sinkTransformer$2: dart.privateName(disconnector, "_sinkTransformer"),
_streamTransformer$2: dart.privateName(disconnector, "_streamTransformer"),
_isDisconnected: dart.privateName(disconnector, "_isDisconnected"),
_closed$6: dart.privateName(disconnector, "_closed"),
_addStreamSubscription$1: dart.privateName(disconnector, "_addStreamSubscription"),
_addStreamCompleter$1: dart.privateName(disconnector, "_addStreamCompleter"),
_inner$7: dart.privateName(disconnector, "_inner"),
_inAddStream$1: dart.privateName(disconnector, "_inAddStream"),
_sinkTransformer$3: dart.privateName(json_document_transformer, "_sinkTransformer"),
_streamTransformer$3: dart.privateName(json_document_transformer, "_streamTransformer"),
_innerStreamSubscription: dart.privateName(multi_channel, "_innerStreamSubscription"),
_mainController: dart.privateName(multi_channel, "_mainController"),
_controllers$2: dart.privateName(multi_channel, "_controllers"),
_pendingIds: dart.privateName(multi_channel, "_pendingIds"),
_closedIds: dart.privateName(multi_channel, "_closedIds"),
_nextId: dart.privateName(multi_channel, "_nextId"),
_inner$8: dart.privateName(multi_channel, "_inner"),
_closeChannel: dart.privateName(multi_channel, "_closeChannel"),
_closeInnerChannel: dart.privateName(multi_channel, "_closeInnerChannel"),
id$2: dart.privateName(multi_channel, "VirtualChannel.id"),
stream: dart.privateName(multi_channel, "VirtualChannel.stream"),
sink$1: dart.privateName(multi_channel, "VirtualChannel.sink"),
_parent$1: dart.privateName(multi_channel, "_parent"),
_streamCompleter: dart.privateName(stream_channel_completer, "_streamCompleter"),
_sinkCompleter: dart.privateName(stream_channel_completer, "_sinkCompleter"),
__StreamChannelCompleter__channel: dart.privateName(stream_channel_completer, "_#StreamChannelCompleter#_channel"),
__StreamChannelCompleter__channel_isSet: dart.privateName(stream_channel_completer, "_#StreamChannelCompleter#_channel#isSet"),
_set: dart.privateName(stream_channel_completer, "_set"),
_channel$3: dart.privateName(stream_channel_completer, "_channel"),
__StreamChannelController__local: dart.privateName(stream_channel_controller, "_#StreamChannelController#_local"),
__StreamChannelController__local_isSet: dart.privateName(stream_channel_controller, "_#StreamChannelController#_local#isSet"),
__StreamChannelController__foreign: dart.privateName(stream_channel_controller, "_#StreamChannelController#_foreign"),
__StreamChannelController__foreign_isSet: dart.privateName(stream_channel_controller, "_#StreamChannelController#_foreign#isSet"),
_local: dart.privateName(stream_channel_controller, "_local"),
_foreign: dart.privateName(stream_channel_controller, "_foreign"),
_webSocket$1: dart.privateName(html$, "HtmlWebSocketChannel._webSocket"),
_closeCode$1: dart.privateName(html$, "_closeCode"),
_closeReason$1: dart.privateName(html$, "_closeReason"),
_localCloseCode: dart.privateName(html$, "_localCloseCode"),
_localCloseReason: dart.privateName(html$, "_localCloseReason"),
_controller$5: dart.privateName(html$, "_controller"),
__HtmlWebSocketChannel_sink: dart.privateName(html$, "_#HtmlWebSocketChannel#sink"),
__HtmlWebSocketChannel_sink_isSet: dart.privateName(html$, "_#HtmlWebSocketChannel#sink#isSet"),
_webSocket$2: dart.privateName(html$, "_webSocket"),
_listen: dart.privateName(html$, "_listen"),
$onOpen: dartx.onOpen,
$onError: dartx.onError,
$onMessage: dartx.onMessage,
$data: dartx.data,
$onClose: dartx.onClose,
_channel$4: dart.privateName(html$, "_channel"),
name$9: dart.privateName(html$, "BinaryType.name"),
value$13: dart.privateName(html$, "BinaryType.value"),
_doneCompleter$2: dart.privateName(io_sink, "_doneCompleter"),
_controllerInstance: dart.privateName(io_sink, "_controllerInstance"),
_controllerCompleter: dart.privateName(io_sink, "_controllerCompleter"),
_isClosed$4: dart.privateName(io_sink, "_isClosed"),
_isBound: dart.privateName(io_sink, "_isBound"),
_hasError: dart.privateName(io_sink, "_hasError"),
_target: dart.privateName(io_sink, "_target"),
_controller$6: dart.privateName(io_sink, "_controller"),
_closeTarget: dart.privateName(io_sink, "_closeTarget"),
_completeDoneValue: dart.privateName(io_sink, "_completeDoneValue"),
_completeDoneError: dart.privateName(io_sink, "_completeDoneError"),
_subscription$6: dart.privateName(stream_subscription$, "_subscription"),
_sink$8: dart.privateName(capture_sink, "_sink"),
_sink$9: dart.privateName(release_sink, "_sink"),
reason: dart.privateName(meta, "Immutable.reason"),
reason$1: dart.privateName(meta, "Required.reason"),
reason$2: dart.privateName(meta, "UseResult.reason"),
_doneCompleter$3: dart.privateName(reject_errors, "_doneCompleter"),
_closed$7: dart.privateName(reject_errors, "_closed"),
_addStreamSubscription$2: dart.privateName(reject_errors, "_addStreamSubscription"),
_addStreamCompleter$2: dart.privateName(reject_errors, "_addStreamCompleter"),
_inner$9: dart.privateName(reject_errors, "_inner"),
_cancelAddStream: dart.privateName(reject_errors, "_cancelAddStream"),
_canceled: dart.privateName(reject_errors, "_canceled"),
_inAddStream$2: dart.privateName(reject_errors, "_inAddStream"),
_addError$1: dart.privateName(reject_errors, "_addError"),
_handleData: dart.privateName(handler_transformer, "_handleData"),
_handleError: dart.privateName(handler_transformer, "_handleError"),
_handleDone: dart.privateName(handler_transformer, "_handleDone"),
_transformer: dart.privateName(handler_transformer, "_transformer"),
_inner$10: dart.privateName(handler_transformer, "_inner"),
_safeCloseInner: dart.privateName(handler_transformer, "_safeCloseInner"),
_transformer$1: dart.privateName(stream_transformer_wrapper, "StreamTransformerWrapper._transformer"),
_transformer$2: dart.privateName(stream_transformer_wrapper, "_transformer"),
_controller$7: dart.privateName(stream_transformer_wrapper, "_controller"),
_inner$11: dart.privateName(stream_transformer_wrapper, "_inner"),
_inner$12: dart.privateName(typed, "_inner"),
_value$1: dart.privateName(digest_sink, "_value"),
_extended$2: dart.privateName(sha512_slowsinks, "_extended"),
_nums: dart.privateName(sha512_slowsinks, "_nums"),
_digest$1: dart.privateName(sha512_slowsinks, "_digest"),
_shr: dart.privateName(sha512_slowsinks, "_shr"),
_shl: dart.privateName(sha512_slowsinks, "_shl"),
_or: dart.privateName(sha512_slowsinks, "_or"),
_xor: dart.privateName(sha512_slowsinks, "_xor"),
_add$2: dart.privateName(sha512_slowsinks, "_add"),
_addTo2: dart.privateName(sha512_slowsinks, "_addTo2"),
_rotr: dart.privateName(sha512_slowsinks, "_rotr"),
_bsig0$1: dart.privateName(sha512_slowsinks, "_bsig0"),
_bsig1$1: dart.privateName(sha512_slowsinks, "_bsig1"),
_ssig0$1: dart.privateName(sha512_slowsinks, "_ssig0"),
_ssig1$1: dart.privateName(sha512_slowsinks, "_ssig1"),
_ch$1: dart.privateName(sha512_slowsinks, "_ch"),
_maj$1: dart.privateName(sha512_slowsinks, "_maj"),
digestBytes: dart.privateName(sha512_slowsinks, "Sha384Sink.digestBytes"),
digestBytes$1: dart.privateName(sha512_slowsinks, "Sha512Sink.digestBytes"),
digestBytes$2: dart.privateName(sha512_slowsinks, "Sha512224Sink.digestBytes"),
digestBytes$3: dart.privateName(sha512_slowsinks, "Sha512256Sink.digestBytes"),
kinds: dart.privateName(meta_meta, "Target.kinds"),
_table$1: dart.privateName(typed_queue, "_TypedQueue._table"),
_head$2: dart.privateName(typed_queue, "_TypedQueue._head"),
_tail$2: dart.privateName(typed_queue, "_TypedQueue._tail"),
_table$2: dart.privateName(typed_queue, "_table"),
_head$3: dart.privateName(typed_queue, "_head"),
_tail$3: dart.privateName(typed_queue, "_tail"),
_createBuffer: dart.privateName(typed_queue, "_createBuffer"),
_createList: dart.privateName(typed_queue, "_createList"),
_writeToList$1: dart.privateName(typed_queue, "_writeToList"),
_growAtCapacity: dart.privateName(typed_queue, "_growAtCapacity"),
_growTo: dart.privateName(typed_queue, "_growTo"),
_defaultValue: dart.privateName(typed_queue, "_defaultValue"),
_add$3: dart.privateName(typed_queue, "_add"),
_grow$2: dart.privateName(typed_queue, "_grow"),
_preGrow$1: dart.privateName(typed_queue, "_preGrow"),
_head_: dart.privateName(typed_queue, "_head="),
_table_: dart.privateName(typed_queue, "_table="),
_tail_: dart.privateName(typed_queue, "_tail="),
_buffer$2: dart.privateName(typed_buffer, "_buffer"),
_length$1: dart.privateName(typed_buffer, "_length"),
_typedBuffer: dart.privateName(typed_buffer, "_typedBuffer"),
_defaultValue$1: dart.privateName(typed_buffer, "_defaultValue"),
_createBuffer$1: dart.privateName(typed_buffer, "_createBuffer"),
_createBiggerBuffer: dart.privateName(typed_buffer, "_createBiggerBuffer"),
_grow$3: dart.privateName(typed_buffer, "_grow"),
_add$4: dart.privateName(typed_buffer, "_add"),
_addAll: dart.privateName(typed_buffer, "_addAll"),
_insertKnownLength: dart.privateName(typed_buffer, "_insertKnownLength"),
_ensureCapacity: dart.privateName(typed_buffer, "_ensureCapacity"),
_setRange: dart.privateName(typed_buffer, "_setRange"),
$elementSizeInBytes: dartx.elementSizeInBytes,
$offsetInBytes: dartx.offsetInBytes
};
const CT = Object.create({
_: () => (C, CT)
});
dart.defineLazy(CT, {
get C0() {
return C[0] = dart.const({
__proto__: TemplateType.TemplateType.prototype,
[S$._Enum__name]: "Unspecified",
[S$._Enum_index]: 0
});
},
get C1() {
return C[1] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "Open",
[S$._Enum_index]: 0
});
},
get C2() {
return C[2] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "Initialize",
[S$._Enum_index]: 1
});
},
get C3() {
return C[3] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "Terminate",
[S$._Enum_index]: 2
});
},
get C4() {
return C[4] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "Configure",
[S$._Enum_index]: 3
});
},
get C5() {
return C[5] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "SystemInitialized",
[S$._Enum_index]: 4
});
},
get C6() {
return C[6] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "SystemTerminated",
[S$._Enum_index]: 5
});
},
get C7() {
return C[7] = dart.const({
__proto__: ResourceTrigger.ResourceTrigger.prototype,
[S$._Enum__name]: "SystemReload",
[S$._Enum_index]: 6
});
},
get C8() {
return C[8] = dart.constList([C[1] || CT.C1, C[2] || CT.C2, C[3] || CT.C3, C[4] || CT.C4, C[5] || CT.C5, C[6] || CT.C6, C[7] || CT.C7], T$.ResourceTriggerL());
},
get C9() {
return C[9] = dart.const({
__proto__: MemberType.MemberType.prototype,
[S$._Enum__name]: "Function",
[S$._Enum_index]: 0
});
},
get C10() {
return C[10] = dart.const({
__proto__: MemberType.MemberType.prototype,
[S$._Enum__name]: "Property",
[S$._Enum_index]: 1
});
},
get C11() {
return C[11] = dart.const({
__proto__: MemberType.MemberType.prototype,
[S$._Enum__name]: "Event",
[S$._Enum_index]: 2
});
},
get C12() {
return C[12] = dart.constList([C[9] || CT.C9, C[10] || CT.C10, C[11] || CT.C11], T$.MemberTypeL());
},
get C13() {
return C[13] = dart.const({
__proto__: ProgressType.ProgressType.prototype,
[S$._Enum__name]: "Execution",
[S$._Enum_index]: 0
});
},
get C14() {
return C[14] = dart.const({
__proto__: ProgressType.ProgressType.prototype,
[S$._Enum__name]: "Network",
[S$._Enum_index]: 1
});
},
get C15() {
return C[15] = dart.constList([C[13] || CT.C13, C[14] || CT.C14], T$.ProgressTypeL());
},
get C16() {
return C[16] = dart.const({
__proto__: ErrorType.ErrorType.prototype,
[S$._Enum__name]: "Management",
[S$._Enum_index]: 0
});
},
get C17() {
return C[17] = dart.const({
__proto__: ErrorType.ErrorType.prototype,
[S$._Enum__name]: "Exception",
[S$._Enum_index]: 1
});
},
get C18() {
return C[18] = dart.constList([C[16] || CT.C16, C[17] || CT.C17], T$.ErrorTypeL());
},
get C19() {
return C[19] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "HostNotReachable",
[S$._Enum_index]: 0
});
},
get C20() {
return C[20] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AccessDenied",
[S$._Enum_index]: 1
});
},
get C21() {
return C[21] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "UserOrTokenNotFound",
[S$._Enum_index]: 2
});
},
get C22() {
return C[22] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ChallengeFailed",
[S$._Enum_index]: 3
});
},
get C23() {
return C[23] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ResourceNotFound",
[S$._Enum_index]: 4
});
},
get C24() {
return C[24] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AttachDenied",
[S$._Enum_index]: 5
});
},
get C25() {
return C[25] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "InvalidMethod",
[S$._Enum_index]: 6
});
},
get C26() {
return C[26] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "InvokeDenied",
[S$._Enum_index]: 7
});
},
get C27() {
return C[27] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "CreateDenied",
[S$._Enum_index]: 8
});
},
get C28() {
return C[28] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AddParentDenied",
[S$._Enum_index]: 9
});
},
get C29() {
return C[29] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AddChildDenied",
[S$._Enum_index]: 10
});
},
get C30() {
return C[30] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ViewAttributeDenied",
[S$._Enum_index]: 11
});
},
get C31() {
return C[31] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "UpdateAttributeDenied",
[S$._Enum_index]: 12
});
},
get C32() {
return C[32] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "StoreNotFound",
[S$._Enum_index]: 13
});
},
get C33() {
return C[33] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ParentNotFound",
[S$._Enum_index]: 14
});
},
get C34() {
return C[34] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ChildNotFound",
[S$._Enum_index]: 15
});
},
get C35() {
return C[35] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ResourceIsNotStore",
[S$._Enum_index]: 16
});
},
get C36() {
return C[36] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "DeleteDenied",
[S$._Enum_index]: 17
});
},
get C37() {
return C[37] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "DeleteFailed",
[S$._Enum_index]: 18
});
},
get C38() {
return C[38] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "UpdateAttributeFailed",
[S$._Enum_index]: 19
});
},
get C39() {
return C[39] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "GetAttributesFailed",
[S$._Enum_index]: 20
});
},
get C40() {
return C[40] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ClearAttributesFailed",
[S$._Enum_index]: 21
});
},
get C41() {
return C[41] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "TemplateNotFound",
[S$._Enum_index]: 22
});
},
get C42() {
return C[42] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "RenameDenied",
[S$._Enum_index]: 23
});
},
get C43() {
return C[43] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ClassNotFound",
[S$._Enum_index]: 24
});
},
get C44() {
return C[44] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "MethodNotFound",
[S$._Enum_index]: 25
});
},
get C45() {
return C[45] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "PropertyNotFound",
[S$._Enum_index]: 26
});
},
get C46() {
return C[46] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "SetPropertyDenied",
[S$._Enum_index]: 27
});
},
get C47() {
return C[47] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "ReadOnlyProperty",
[S$._Enum_index]: 28
});
},
get C48() {
return C[48] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "GeneralFailure",
[S$._Enum_index]: 29
});
},
get C49() {
return C[49] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AddToStoreFailed",
[S$._Enum_index]: 30
});
},
get C50() {
return C[50] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "NotAttached",
[S$._Enum_index]: 31
});
},
get C51() {
return C[51] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AlreadyListened",
[S$._Enum_index]: 32
});
},
get C52() {
return C[52] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "AlreadyUnlistened",
[S$._Enum_index]: 33
});
},
get C53() {
return C[53] = dart.const({
__proto__: ExceptionCode.ExceptionCode.prototype,
[S$._Enum__name]: "NotListenable",
[S$._Enum_index]: 34
});
},
get C54() {
return C[54] = dart.constList([C[19] || CT.C19, C[20] || CT.C20, C[21] || CT.C21, C[22] || CT.C22, C[23] || CT.C23, C[24] || CT.C24, C[25] || CT.C25, C[26] || CT.C26, C[27] || CT.C27, C[28] || CT.C28, C[29] || CT.C29, C[30] || CT.C30, C[31] || CT.C31, C[32] || CT.C32, C[33] || CT.C33, C[34] || CT.C34, C[35] || CT.C35, C[36] || CT.C36, C[37] || CT.C37, C[38] || CT.C38, C[39] || CT.C39, C[40] || CT.C40, C[41] || CT.C41, C[42] || CT.C42, C[43] || CT.C43, C[44] || CT.C44, C[45] || CT.C45, C[46] || CT.C46, C[47] || CT.C47, C[48] || CT.C48, C[49] || CT.C49, C[50] || CT.C50, C[51] || CT.C51, C[52] || CT.C52, C[53] || CT.C53], T$.ExceptionCodeL());
},
get C55() {
return C[55] = dart.const({
__proto__: typed_data.Endian.prototype,
[S$.Endian__littleEndian]: true
});
},
get C56() {
return C[56] = dart.fn(DataDeserializer.DataDeserializer.nullParser, T$.DCAndintAndint__ToAsyncReply());
},
get C57() {
return C[57] = dart.fn(DataDeserializer.DataDeserializer.booleanFalseParser, T$.DCAndintAndint__ToAsyncReply());
},
get C58() {
return C[58] = dart.fn(DataDeserializer.DataDeserializer.booleanTrueParser, T$.DCAndintAndint__ToAsyncReply());
},
get C59() {
return C[59] = dart.fn(DataDeserializer.DataDeserializer.notModifiedParser, T$.DCAndintAndint__ToAsyncReply());
},
get C60() {
return C[60] = dart.fn(DataDeserializer.DataDeserializer.byteParser, T$.DCAndintAndint__ToAsyncReply());
},
get C61() {
return C[61] = dart.fn(DataDeserializer.DataDeserializer.sByteParser, T$.DCAndintAndint__ToAsyncReply());
},
get C62() {
return C[62] = dart.fn(DataDeserializer.DataDeserializer.char8Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C63() {
return C[63] = dart.fn(DataDeserializer.DataDeserializer.int16Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C64() {
return C[64] = dart.fn(DataDeserializer.DataDeserializer.uInt16Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C65() {
return C[65] = dart.fn(DataDeserializer.DataDeserializer.char16Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C66() {
return C[66] = dart.fn(DataDeserializer.DataDeserializer.int32Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C67() {
return C[67] = dart.fn(DataDeserializer.DataDeserializer.uInt32Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C68() {
return C[68] = dart.fn(DataDeserializer.DataDeserializer.float32Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C69() {
return C[69] = dart.fn(DataDeserializer.DataDeserializer.resourceParser, T$.DCAndintAndint__ToAsyncReply());
},
get C70() {
return C[70] = dart.fn(DataDeserializer.DataDeserializer.localResourceParser, T$.DCAndintAndint__ToAsyncReply());
},
get C71() {
return C[71] = dart.fn(DataDeserializer.DataDeserializer.int64Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C72() {
return C[72] = dart.fn(DataDeserializer.DataDeserializer.uInt64Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C73() {
return C[73] = dart.fn(DataDeserializer.DataDeserializer.float64Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C74() {
return C[74] = dart.fn(DataDeserializer.DataDeserializer.dateTimeParser, T$.DCAndintAndint__ToAsyncReply());
},
get C75() {
return C[75] = dart.fn(DataDeserializer.DataDeserializer.int128Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C76() {
return C[76] = dart.fn(DataDeserializer.DataDeserializer.uInt128Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C77() {
return C[77] = dart.fn(DataDeserializer.DataDeserializer.float128Parser, T$.DCAndintAndint__ToAsyncReply());
},
get C78() {
return C[78] = dart.fn(DataDeserializer.DataDeserializer.rawDataParser, T$.DCAndintAndint__ToAsyncReply());
},
get C79() {
return C[79] = dart.fn(DataDeserializer.DataDeserializer.stringParser, T$.DCAndintAndint__ToAsyncReply());
},
get C80() {
return C[80] = dart.fn(DataDeserializer.DataDeserializer.listParser, T$.DCAndintAndint__ToAsyncBag());
},
get C81() {
return C[81] = dart.fn(DataDeserializer.DataDeserializer.resourceListParser, T$.DCAndintAndint__ToAsyncReply());
},
get C82() {
return C[82] = dart.fn(DataDeserializer.DataDeserializer.recordListParser, T$.DCAndintAndint__ToAsyncReply());
},
get C83() {
return C[83] = dart.fn(DataDeserializer.DataDeserializer.recordParser, T$.DCAndintAndint__ToAsyncReply());
},
get C84() {
return C[84] = dart.fn(DataDeserializer.DataDeserializer.typedListParser, T$.DCAndintAndint__ToAsyncReply());
},
get C85() {
return C[85] = dart.fn(DataDeserializer.DataDeserializer.typedMapParser, T$.DCAndintAndint__ToAsyncReply());
},
get C86() {
return C[86] = dart.fn(DataDeserializer.DataDeserializer.tupleParser, T$.DCAndintAndint__ToAsyncReply());
},
get C87() {
return C[87] = dart.fn(DataDeserializer.DataDeserializer.enumParser, T$.DCAndintAndint__ToAsyncReply());
},
get C88() {
return C[88] = dart.fn(DataDeserializer.DataDeserializer.constantParser, T$.DCAndintAndint__ToAsyncReply());
},
get C89() {
return C[89] = dart.fn(DataSerializer.DataSerializer.boolComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C90() {
return C[90] = dart.fn(DataSerializer.DataSerializer.notModifiedComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C91() {
return C[91] = dart.fn(DataSerializer.DataSerializer.int32Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C92() {
return C[92] = dart.fn(DataSerializer.DataSerializer.uInt32Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C93() {
return C[93] = dart.fn(DataSerializer.DataSerializer.int8Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C94() {
return C[94] = dart.fn(DataSerializer.DataSerializer.uInt8Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C95() {
return C[95] = dart.fn(DataSerializer.DataSerializer.int16Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C96() {
return C[96] = dart.fn(DataSerializer.DataSerializer.uInt16Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C97() {
return C[97] = dart.fn(DataSerializer.DataSerializer.int64Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C98() {
return C[98] = dart.fn(DataSerializer.DataSerializer.float64Composer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C99() {
return C[99] = dart.fn(DataSerializer.DataSerializer.dateTimeComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C100() {
return C[100] = dart.fn(DataSerializer.DataSerializer.rawDataComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C101() {
return C[101] = dart.fn(DataSerializer.DataSerializer.stringComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C102() {
return C[102] = dart.fn(DataSerializer.DataSerializer.listComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C103() {
return C[103] = dart.fn(DataSerializer.DataSerializer.resourceListComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C104() {
return C[104] = dart.fn(DataSerializer.DataSerializer.recordListComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C105() {
return C[105] = dart.fn(DataSerializer.DataSerializer.mapComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C106() {
return C[106] = dart.fn(DataSerializer.DataSerializer.propertyValueArrayComposer, T$.dynamicAndDistributedConnectionNToDataSerializerComposeResults());
},
get C107() {
return C[107] = dart.constMap(T$.StringL(), T$.TypeL(), ["int", dart.wrapType(core.int), "bool", dart.wrapType(core.bool), "double", dart.wrapType(core.double), "String", dart.wrapType(core.String), "IResource", dart.wrapType(IResource.IResource), "IRecord", dart.wrapType(IRecord.IRecord), "IEnum", dart.wrapType(IEnum.IEnum), "DC", dart.wrapType(DC.DC)]);
},
get C108() {
return C[108] = dart.const({
__proto__: AuthenticationMethod.AuthenticationMethod.prototype,
[S$._Enum__name]: "None",
[S$._Enum_index]: 0
});
},
get C109() {
return C[109] = dart.const(new _internal.Symbol.new('setProperty'));
},
get C110() {
return C[110] = dart.const(new _internal.Symbol.new('invoke'));
},
get C111() {
return C[111] = dart.const(new _internal.Symbol.new('getProperty'));
},
get C112() {
return C[112] = dart.const(new _internal.Symbol.new('template'));
},
get C113() {
return C[113] = dart.const({
__proto__: DistributedResourceQueueItemType.DistributedResourceQueueItemType.prototype,
[S$._Enum__name]: "Propery",
[S$._Enum_index]: 0
});
},
get C114() {
return C[114] = dart.const({
__proto__: DistributedResourceQueueItemType.DistributedResourceQueueItemType.prototype,
[S$._Enum__name]: "Event",
[S$._Enum_index]: 1
});
},
get C115() {
return C[115] = dart.constList([C[113] || CT.C113, C[114] || CT.C114], T$.DistributedResourceQueueItemTypeL());
},
get C116() {
return C[116] = dart.const({
__proto__: SocketState.SocketState.prototype,
[S$._Enum__name]: "Initial",
[S$._Enum_index]: 0
});
},
get C117() {
return C[117] = dart.const({
__proto__: SocketState.SocketState.prototype,
[S$._Enum__name]: "Listening",
[S$._Enum_index]: 1
});
},
get C118() {
return C[118] = dart.const({
__proto__: SocketState.SocketState.prototype,
[S$._Enum__name]: "Connecting",
[S$._Enum_index]: 2
});
},
get C119() {
return C[119] = dart.const({
__proto__: SocketState.SocketState.prototype,
[S$._Enum__name]: "Established",
[S$._Enum_index]: 3
});
},
get C120() {
return C[120] = dart.const({
__proto__: SocketState.SocketState.prototype,
[S$._Enum__name]: "Closed",
[S$._Enum_index]: 4
});
},
get C121() {
return C[121] = dart.const({
__proto__: SocketState.SocketState.prototype,
[S$._Enum__name]: "Terminated",
[S$._Enum_index]: 5
});
},
get C122() {
return C[122] = dart.constList([C[116] || CT.C116, C[117] || CT.C117, C[118] || CT.C118, C[119] || CT.C119, C[120] || CT.C120, C[121] || CT.C121], T$.SocketStateL());
},
get C123() {
return C[123] = dart.const({
__proto__: AuthenticationType.AuthenticationType.prototype,
[S$._Enum__name]: "Host",
[S$._Enum_index]: 0
});
},
get C124() {
return C[124] = dart.const({
__proto__: AuthenticationType.AuthenticationType.prototype,
[S$._Enum__name]: "CoHost",
[S$._Enum_index]: 1
});
},
get C125() {
return C[125] = dart.const({
__proto__: AuthenticationType.AuthenticationType.prototype,
[S$._Enum__name]: "Client",
[S$._Enum_index]: 2
});
},
get C126() {
return C[126] = dart.const({
__proto__: AuthenticationType.AuthenticationType.prototype,
[S$._Enum__name]: "Alien",
[S$._Enum_index]: 3
});
},
get C127() {
return C[127] = dart.constList([C[123] || CT.C123, C[124] || CT.C124, C[125] || CT.C125, C[126] || CT.C126], T$.AuthenticationTypeL());
},
get C128() {
return C[128] = dart.const({
__proto__: AuthenticationMethod.AuthenticationMethod.prototype,
[S$._Enum__name]: "Certificate",
[S$._Enum_index]: 1
});
},
get C129() {
return C[129] = dart.const({
__proto__: AuthenticationMethod.AuthenticationMethod.prototype,
[S$._Enum__name]: "Credentials",
[S$._Enum_index]: 2
});
},
get C130() {
return C[130] = dart.const({
__proto__: AuthenticationMethod.AuthenticationMethod.prototype,
[S$._Enum__name]: "Token",
[S$._Enum_index]: 3
});
},
get C131() {
return C[131] = dart.constList([C[108] || CT.C108, C[128] || CT.C128, C[129] || CT.C129, C[130] || CT.C130], T$.AuthenticationMethodL());
},
get C132() {
return C[132] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Mobility",
[S$._Enum_index]: 0
});
},
get C133() {
return C[133] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "CPU",
[S$._Enum_index]: 1
});
},
get C134() {
return C[134] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "IPv4",
[S$._Enum_index]: 2
});
},
get C135() {
return C[135] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "IPv6",
[S$._Enum_index]: 3
});
},
get C136() {
return C[136] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Port",
[S$._Enum_index]: 4
});
},
get C137() {
return C[137] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Proxy",
[S$._Enum_index]: 5
});
},
get C138() {
return C[138] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Route",
[S$._Enum_index]: 6
});
},
get C139() {
return C[139] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Location",
[S$._Enum_index]: 7
});
},
get C140() {
return C[140] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "OS",
[S$._Enum_index]: 8
});
},
get C141() {
return C[141] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Application",
[S$._Enum_index]: 9
});
},
get C142() {
return C[142] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Network",
[S$._Enum_index]: 10
});
},
get C143() {
return C[143] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Display",
[S$._Enum_index]: 11
});
},
get C144() {
return C[144] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Media",
[S$._Enum_index]: 12
});
},
get C145() {
return C[145] = dart.const({
__proto__: SourceAttributeType.SourceAttributeType.prototype,
[S$._Enum__name]: "Identity",
[S$._Enum_index]: 13
});
},
get C146() {
return C[146] = dart.constList([C[132] || CT.C132, C[133] || CT.C133, C[134] || CT.C134, C[135] || CT.C135, C[136] || CT.C136, C[137] || CT.C137, C[138] || CT.C138, C[139] || CT.C139, C[140] || CT.C140, C[141] || CT.C141, C[142] || CT.C142, C[143] || CT.C143, C[144] || CT.C144, C[145] || CT.C145], T$.SourceAttributeTypeL());
},
get C147() {
return C[147] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "Attach",
[S$._Enum_index]: 0
});
},
get C148() {
return C[148] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "Delete",
[S$._Enum_index]: 1
});
},
get C149() {
return C[149] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "Execute",
[S$._Enum_index]: 2
});
},
get C150() {
return C[150] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "GetProperty",
[S$._Enum_index]: 3
});
},
get C151() {
return C[151] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "SetProperty",
[S$._Enum_index]: 4
});
},
get C152() {
return C[152] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "CreateResource",
[S$._Enum_index]: 5
});
},
get C153() {
return C[153] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "UpdateAttributes",
[S$._Enum_index]: 6
});
},
get C154() {
return C[154] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "InquireAttributes",
[S$._Enum_index]: 7
});
},
get C155() {
return C[155] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "AddParent",
[S$._Enum_index]: 8
});
},
get C156() {
return C[156] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "RemoveParent",
[S$._Enum_index]: 9
});
},
get C157() {
return C[157] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "AddChild",
[S$._Enum_index]: 10
});
},
get C158() {
return C[158] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "RemoveChild",
[S$._Enum_index]: 11
});
},
get C159() {
return C[159] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "Rename",
[S$._Enum_index]: 12
});
},
get C160() {
return C[160] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "ReceiveEvent",
[S$._Enum_index]: 13
});
},
get C161() {
return C[161] = dart.const({
__proto__: ActionType.ActionType.prototype,
[S$._Enum__name]: "ViewTemplate",
[S$._Enum_index]: 14
});
},
get C162() {
return C[162] = dart.constList([C[147] || CT.C147, C[148] || CT.C148, C[149] || CT.C149, C[150] || CT.C150, C[151] || CT.C151, C[152] || CT.C152, C[153] || CT.C153, C[154] || CT.C154, C[155] || CT.C155, C[156] || CT.C156, C[157] || CT.C157, C[158] || CT.C158, C[159] || CT.C159, C[160] || CT.C160, C[161] || CT.C161], T$.ActionTypeL());
},
get C163() {
return C[163] = dart.const({
__proto__: Ruling.Ruling.prototype,
[S$._Enum__name]: "Denied",
[S$._Enum_index]: 0
});
},
get C164() {
return C[164] = dart.const({
__proto__: Ruling.Ruling.prototype,
[S$._Enum__name]: "Allowed",
[S$._Enum_index]: 1
});
},
get C165() {
return C[165] = dart.const({
__proto__: Ruling.Ruling.prototype,
[S$._Enum__name]: "DontCare",
[S$._Enum_index]: 2
});
},
get C166() {
return C[166] = dart.constList([C[163] || CT.C163, C[164] || CT.C164, C[165] || CT.C165], T$.RulingL());
},
get C167() {
return C[167] = dart.const({
__proto__: TransmissionType.TransmissionType.prototype,
[S$.exponent]: 0,
[S$.contentLength]: 0,
[S$.offset]: 0,
[S$.classType]: 0,
[S$.index$3]: 0,
[S$.identifier$1]: 0
});
},
get C168() {
return C[168] = dart.const({
__proto__: TemplateType.TemplateType.prototype,
[S$._Enum__name]: "Resource",
[S$._Enum_index]: 1
});
},
get C169() {
return C[169] = dart.const({
__proto__: TemplateType.TemplateType.prototype,
[S$._Enum__name]: "Record",
[S$._Enum_index]: 2
});
},
get C170() {
return C[170] = dart.const({
__proto__: TemplateType.TemplateType.prototype,
[S$._Enum__name]: "Wrapper",
[S$._Enum_index]: 3
});
},
get C171() {
return C[171] = dart.const({
__proto__: TemplateType.TemplateType.prototype,
[S$._Enum__name]: "Enum",
[S$._Enum_index]: 4
});
},
get C172() {
return C[172] = dart.constList([C[0] || CT.C0, C[168] || CT.C168, C[169] || CT.C169, C[170] || CT.C170, C[171] || CT.C171], T$.TemplateTypeL());
},
get C173() {
return C[173] = dart.fn(utils.defaultCompare, T$.ObjectNAndObjectNToint());
},
get C174() {
return C[174] = dart.fn(utils.identity, T$.TToT());
},
get C175() {
return C[175] = dart.const(new _js_helper.PrivateSymbol.new('_source', S$._source));
},
get C176() {
return C[176] = dart.const({
__proto__: T$.DefaultEqualityOfNeverL().prototype
});
},
get C177() {
return C[177] = dart.fn(utils.compareComparable, T$.TAndTToint());
},
get C178() {
return C[178] = dart.constList([], core.Null);
},
get C179() {
return C[179] = dart.const(new _js_helper.PrivateSymbol.new('_base', S$0._base$9));
},
get C180() {
return C[180] = dart.const({
__proto__: core.Duration.prototype,
[S$0.Duration__duration]: 5000000
});
},
get C181() {
return C[181] = dart.const({
__proto__: T$.CaptureStreamTransformerOfObjectL().prototype
});
},
get C182() {
return C[182] = dart.const({
__proto__: T$.ReleaseStreamTransformerOfObjectL().prototype
});
},
get C183() {
return C[183] = dart.const({
__proto__: T$.StreamTransformerWrapperOfObjectL$ResultLOfObjectL().prototype,
[S$0.StreamTransformerWrapper__transformer]: C[181] || CT.C181
});
},
get C184() {
return C[184] = dart.const({
__proto__: T$.StreamTransformerWrapperOfResultLOfObjectL$ObjectL().prototype,
[S$0.StreamTransformerWrapper__transformer]: C[182] || CT.C182
});
},
get C185() {
return C[185] = dart.const({
__proto__: convert.Utf8Codec.prototype,
[S$0.Utf8Codec__allowMalformed]: false
});
},
get C186() {
return C[186] = dart.const({
__proto__: stream_group._StreamGroupState.prototype,
[S$0.name$8]: "dormant"
});
},
get C187() {
return C[187] = dart.const({
__proto__: stream_group._StreamGroupState.prototype,
[S$0.name$8]: "listening"
});
},
get C188() {
return C[188] = dart.const({
__proto__: stream_group._StreamGroupState.prototype,
[S$0.name$8]: "paused"
});
},
get C189() {
return C[189] = dart.const({
__proto__: stream_group._StreamGroupState.prototype,
[S$0.name$8]: "canceled"
});
},
get C190() {
return C[190] = dart.constList([], dart.legacy(dart.Never));
},
get C191() {
return C[191] = dart.const({
__proto__: equality$.ListEquality.prototype,
[S$._elementEquality$2]: C[176] || CT.C176
});
},
get C192() {
return C[192] = dart.const({
__proto__: typed_data.Endian.prototype,
[S$.Endian__littleEndian]: false
});
},
get C193() {
return C[193] = dart.const({
__proto__: md5._MD5.prototype,
[S$0.blockSize]: 64
});
},
get C194() {
return C[194] = dart.constList([3614090360.0, 3905402710.0, 606105819, 3250441966.0, 4118548399.0, 1200080426, 2821735955.0, 4249261313.0, 1770035416, 2336552879.0, 4294925233.0, 2304563134.0, 1804603682, 4254626195.0, 2792965006.0, 1236535329, 4129170786.0, 3225465664.0, 643717713, 3921069994.0, 3593408605.0, 38016083, 3634488961.0, 3889429448.0, 568446438, 3275163606.0, 4107603335.0, 1163531501, 2850285829.0, 4243563512.0, 1735328473, 2368359562.0, 4294588738.0, 2272392833.0, 1839030562, 4259657740.0, 2763975236.0, 1272893353, 4139469664.0, 3200236656.0, 681279174, 3936430074.0, 3572445317.0, 76029189, 3654602809.0, 3873151461.0, 530742520, 3299628645.0, 4096336452.0, 1126891415, 2878612391.0, 4237533241.0, 1700485571, 2399980690.0, 4293915773.0, 2240044497.0, 1873313359, 4264355552.0, 2734768916.0, 1309151649, 4149444226.0, 3174756917.0, 718787259, 3951481745.0], T$0.intL());
},
get C195() {
return C[195] = dart.constList([7, 12, 17, 22, 7, 12, 17, 22, 7, 12, 17, 22, 7, 12, 17, 22, 5, 9, 14, 20, 5, 9, 14, 20, 5, 9, 14, 20, 5, 9, 14, 20, 4, 11, 16, 23, 4, 11, 16, 23, 4, 11, 16, 23, 4, 11, 16, 23, 6, 10, 15, 21, 6, 10, 15, 21, 6, 10, 15, 21, 6, 10, 15, 21], T$0.intL());
},
get C196() {
return C[196] = dart.const({
__proto__: sha1._Sha1.prototype,
[S$0.blockSize$1]: 64
});
},
get C197() {
return C[197] = dart.const({
__proto__: sha256._Sha256.prototype,
[S$0.blockSize$2]: 64
});
},
get C198() {
return C[198] = dart.const({
__proto__: sha256._Sha224.prototype,
[S$0.blockSize$3]: 64
});
},
get C199() {
return C[199] = dart.constList([1116352408, 1899447441, 3049323471.0, 3921009573.0, 961987163, 1508970993, 2453635748.0, 2870763221.0, 3624381080.0, 310598401, 607225278, 1426881987, 1925078388, 2162078206.0, 2614888103.0, 3248222580.0, 3835390401.0, 4022224774.0, 264347078, 604807628, 770255983, 1249150122, 1555081692, 1996064986, 2554220882.0, 2821834349.0, 2952996808.0, 3210313671.0, 3336571891.0, 3584528711.0, 113926993, 338241895, 666307205, 773529912, 1294757372, 1396182291, 1695183700, 1986661051, 2177026350.0, 2456956037.0, 2730485921.0, 2820302411.0, 3259730800.0, 3345764771.0, 3516065817.0, 3600352804.0, 4094571909.0, 275423344, 430227734, 506948616, 659060556, 883997877, 958139571, 1322822218, 1537002063, 1747873779, 1955562222, 2024104815, 2227730452.0, 2361852424.0, 2428436474.0, 2756734187.0, 3204031479.0, 3329325298.0], T$0.intL());
},
get C200() {
return C[200] = dart.const({
__proto__: sha512._Sha384.prototype,
[S$0.blockSize$4]: 128
});
},
get C201() {
return C[201] = dart.const({
__proto__: sha512._Sha512.prototype,
[S$0.blockSize$5]: 128
});
},
get C202() {
return C[202] = dart.const({
__proto__: sha512._Sha512224.prototype,
[S$0.blockSize$6]: 128
});
},
get C203() {
return C[203] = dart.const({
__proto__: sha512._Sha512256.prototype,
[S$0.blockSize$7]: 128
});
},
get C204() {
return C[204] = dart.const(new _js_helper.PrivateSymbol.new('_sinkTransformer', S$0._sinkTransformer$2));
},
get C205() {
return C[205] = dart.const(new _js_helper.PrivateSymbol.new('_streamTransformer', S$0._streamTransformer$2));
},
get C206() {
return C[206] = dart.fn(convert.jsonDecode, T$0.String__Todynamic());
},
get C207() {
return C[207] = dart.const(new _js_helper.PrivateSymbol.new('_sinkTransformer', S$0._sinkTransformer$3));
},
get C208() {
return C[208] = dart.const(new _js_helper.PrivateSymbol.new('_streamTransformer', S$0._streamTransformer$3));
},
get C209() {
return C[209] = dart.const({
__proto__: json_document_transformer._JsonDocument.prototype
});
},
get C210() {
return C[210] = dart.const(new _js_helper.PrivateSymbol.new('_webSocket', S$0._webSocket$2));
},
get C211() {
return C[211] = dart.const({
__proto__: html$.BinaryType.prototype,
[S$0.value$13]: "blob",
[S$0.name$9]: "blob"
});
},
get C212() {
return C[212] = dart.const({
__proto__: html$.BinaryType.prototype,
[S$0.value$13]: "arraybuffer",
[S$0.name$9]: "list"
});
},
get C213() {
return C[213] = dart.fn(release_transformer.ReleaseStreamTransformer._createSink, T$0.EventSinkToEventSinkOfResult());
},
get C214() {
return C[214] = dart.const({
__proto__: meta._AlwaysThrows.prototype
});
},
get C215() {
return C[215] = dart.const({
__proto__: meta._Checked.prototype
});
},
get C216() {
return C[216] = dart.const({
__proto__: meta._DoNotStore.prototype
});
},
get C217() {
return C[217] = dart.const({
__proto__: meta._Experimental.prototype
});
},
get C218() {
return C[218] = dart.const({
__proto__: meta._Factory.prototype
});
},
get C219() {
return C[219] = dart.const({
__proto__: meta.Immutable.prototype,
[S$0.reason]: ""
});
},
get C220() {
return C[220] = dart.const({
__proto__: meta._Internal.prototype
});
},
get C221() {
return C[221] = dart.const({
__proto__: meta._IsTest.prototype
});
},
get C222() {
return C[222] = dart.const({
__proto__: meta._IsTestGroup.prototype
});
},
get C223() {
return C[223] = dart.const({
__proto__: meta._Literal.prototype
});
},
get C224() {
return C[224] = dart.const({
__proto__: meta._MustCallSuper.prototype
});
},
get C225() {
return C[225] = dart.const({
__proto__: meta._NonVirtual.prototype
});
},
get C226() {
return C[226] = dart.const({
__proto__: meta._OptionalTypeArgs.prototype
});
},
get C227() {
return C[227] = dart.const({
__proto__: meta._Protected.prototype
});
},
get C228() {
return C[228] = dart.const({
__proto__: meta.Required.prototype,
[S$0.reason$1]: ""
});
},
get C229() {
return C[229] = dart.const({
__proto__: meta._Sealed.prototype
});
},
get C230() {
return C[230] = dart.const({
__proto__: meta.UseResult.prototype,
[S$0.reason$2]: ""
});
},
get C231() {
return C[231] = dart.const({
__proto__: meta._Virtual.prototype
});
},
get C232() {
return C[232] = dart.const({
__proto__: meta._VisibleForOverriding.prototype
});
},
get C233() {
return C[233] = dart.const({
__proto__: meta._VisibleForTesting.prototype
});
},
get C234() {
return C[234] = dart.fn(handler_transformer._closeSink, T$0.EventSinkTovoid());
},
get C235() {
return C[235] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "classType",
[S$._Enum_index]: 0
});
},
get C236() {
return C[236] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "enumType",
[S$._Enum_index]: 1
});
},
get C237() {
return C[237] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "extension",
[S$._Enum_index]: 2
});
},
get C238() {
return C[238] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "field",
[S$._Enum_index]: 3
});
},
get C239() {
return C[239] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "function",
[S$._Enum_index]: 4
});
},
get C240() {
return C[240] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "library",
[S$._Enum_index]: 5
});
},
get C241() {
return C[241] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "getter",
[S$._Enum_index]: 6
});
},
get C242() {
return C[242] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "method",
[S$._Enum_index]: 7
});
},
get C243() {
return C[243] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "mixinType",
[S$._Enum_index]: 8
});
},
get C244() {
return C[244] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "parameter",
[S$._Enum_index]: 9
});
},
get C245() {
return C[245] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "setter",
[S$._Enum_index]: 10
});
},
get C246() {
return C[246] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "topLevelVariable",
[S$._Enum_index]: 11
});
},
get C247() {
return C[247] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "type",
[S$._Enum_index]: 12
});
},
get C248() {
return C[248] = dart.const({
__proto__: meta_meta.TargetKind.prototype,
[S$._Enum__name]: "typedefType",
[S$._Enum_index]: 13
});
},
get C249() {
return C[249] = dart.constList([C[235] || CT.C235, C[236] || CT.C236, C[237] || CT.C237, C[238] || CT.C238, C[239] || CT.C239, C[240] || CT.C240, C[241] || CT.C241, C[242] || CT.C242, C[243] || CT.C243, C[244] || CT.C244, C[245] || CT.C245, C[246] || CT.C246, C[247] || CT.C247, C[248] || CT.C248], T$0.TargetKindL());
},
get C250() {
return C[250] = dart.const(new _js_helper.PrivateSymbol.new('_head', S$0._head$3));
},
get C251() {
return C[251] = dart.const(new _js_helper.PrivateSymbol.new('_writeToList', S$0._writeToList$1));
},
get C252() {
return C[252] = dart.const(new _js_helper.PrivateSymbol.new('_add', S$0._add$3));
},
get C253() {
return C[253] = dart.const(new _js_helper.PrivateSymbol.new('_grow', S$0._grow$2));
},
get C254() {
return C[254] = dart.const(new _js_helper.PrivateSymbol.new('_table', S$0._table$2));
},
get C255() {
return C[255] = dart.const(new _js_helper.PrivateSymbol.new('_tail', S$0._tail$3));
},
get C256() {
return C[256] = dart.const(new _js_helper.PrivateSymbol.new('_preGrow', S$0._preGrow$1));
},
get C257() {
return C[257] = dart.const(new _js_helper.PrivateSymbol.new('_head=', S$0._head_));
},
get C258() {
return C[258] = dart.const(new _js_helper.PrivateSymbol.new('_table=', S$0._table_));
},
get C259() {
return C[259] = dart.const(new _js_helper.PrivateSymbol.new('_tail=', S$0._tail_));
}
}, false);
var C = Array(260).fill(void 0);
var I = [
"org-dartlang-app:/src/Resource/Warehouse.dart",
"org-dartlang-app:/src/Resource/Instance.dart",
"org-dartlang-app:/src/Core/IEventHandler.dart",
"org-dartlang-app:/src/Core/IDestructible.dart",
"org-dartlang-app:/src/Resource/IResource.dart",
"org-dartlang-app:/src/Resource/IStore.dart",
"org-dartlang-app:/src/Resource/ResourceTrigger.dart",
"org-dartlang-app:/src/Resource/StorageMode.dart",
"org-dartlang-app:/src/Resource/Template/EventTemplate.dart",
"org-dartlang-app:/src/Resource/Template/MemberTemplate.dart",
"org-dartlang-app:/src/Resource/Template/FunctionTemplate.dart",
"org-dartlang-app:/src/Resource/Template/MemberType.dart",
"org-dartlang-app:/src/Resource/Template/PropertyPermission.dart",
"org-dartlang-app:/src/Resource/Template/PropertyTemplate.dart",
"org-dartlang-app:/src/Resource/Template/TypeTemplate.dart",
"org-dartlang-app:/src/Resource/Template/TemplateDescriber.dart",
"org-dartlang-app:/src/Proxy/TemplateGenerator.dart",
"org-dartlang-app:/src/Core/ProgressType.dart",
"org-dartlang-app:/src/Core/AsyncBag.dart",
"org-dartlang-app:/src/Core/AsyncReply.dart",
"org-dartlang-app:/src/Core/AsyncException.dart",
"org-dartlang-app:/src/Core/AsyncQueue.dart",
"org-dartlang-app:/src/Core/ErrorType.dart",
"org-dartlang-app:/src/Core/ExceptionCode.dart",
"org-dartlang-app:/src/Core/Tuple.dart",
"org-dartlang-app:/src/Data/AutoList.dart",
"org-dartlang-app:/src/Data/BinaryList.dart",
"org-dartlang-app:/src/Data/Codec.dart",
"org-dartlang-app:/src/Data/RepresentationType.dart",
"org-dartlang-app:/src/Data/DC.dart",
"org-dartlang-app:/src/Data/Guid.dart",
"org-dartlang-app:/src/Data/KeyList.dart",
"org-dartlang-app:/src/Data/NotModified.dart",
"org-dartlang-app:/src/Data/PropertyValue.dart",
"org-dartlang-app:/src/Data/SizeObject.dart",
"org-dartlang-app:/src/Data/ValueObject.dart",
"org-dartlang-app:/src/Data/IRecord.dart",
"org-dartlang-app:/src/Data/Record.dart",
"org-dartlang-app:/src/Data/IEnum.dart",
"org-dartlang-app:/src/Data/IntType.dart",
"org-dartlang-app:/src/Net/NetworkBuffer.dart",
"org-dartlang-app:/src/Net/NetworkConnection.dart",
"org-dartlang-app:/src/Net/INetworkReceiver.dart",
"org-dartlang-app:/src/Net/Sockets/ISocket.dart",
"org-dartlang-app:/src/Net/SendList.dart",
"org-dartlang-app:/src/Net/IIP/DistributedConnection.dart",
"org-dartlang-app:/src/Net/IIP/DistributedPropertyContext.dart",
"org-dartlang-app:/src/Net/IIP/DistributedResource.dart",
"org-dartlang-app:/src/Net/IIP/DistributedResourceQueueItem.dart",
"org-dartlang-app:/src/Net/IIP/DistributedResourceQueueItemType.dart",
"org-dartlang-app:/src/Net/Packets/IIPAuthPacket.dart",
"org-dartlang-app:/src/Net/Packets/IIPAuthPacketAction.dart",
"org-dartlang-app:/src/Net/Packets/IIPAuthPacketCommand.dart",
"org-dartlang-app:/src/Net/Packets/IIPPacket.dart",
"org-dartlang-app:/src/Net/Packets/IIPPacketAction.dart",
"org-dartlang-app:/src/Net/Packets/IIPPacketCommand.dart",
"org-dartlang-app:/src/Net/Packets/IIPPacketEvent.dart",
"org-dartlang-app:/src/Net/Packets/IIPPacketReport.dart",
"org-dartlang-app:/src/Net/Sockets/IPEndPoint.dart",
"org-dartlang-app:/src/Net/Sockets/SocketState.dart",
"org-dartlang-app:/src/Net/Sockets/TCPSocket.dart",
"org-dartlang-app:/src/Security/Authority/Authentication.dart",
"org-dartlang-app:/src/Security/Authority/AuthenticationState.dart",
"org-dartlang-app:/src/Security/Authority/AuthenticationType.dart",
"org-dartlang-app:/src/Security/Authority/AuthenticationMethod.dart",
"org-dartlang-app:/src/Security/Authority/ClientAuthentication.dart",
"org-dartlang-app:/src/Security/Authority/CoHostAuthentication.dart",
"org-dartlang-app:/src/Security/Authority/HostAuthentication.dart",
"org-dartlang-app:/src/Security/Authority/Session.dart",
"org-dartlang-app:/src/Security/Authority/Source.dart",
"org-dartlang-app:/src/Security/Authority/SourceAttributeType.dart",
"org-dartlang-app:/src/Security/Integrity/SHA256.dart",
"org-dartlang-app:/src/Security/Permissions/ActionType.dart",
"org-dartlang-app:/src/Security/Permissions/IPermissionsManager.dart",
"org-dartlang-app:/src/Security/Permissions/Ruling.dart",
"org-dartlang-app:/src/Data/TransmissionType.dart",
"org-dartlang-app:/src/Resource/FactoryEntry.dart",
"org-dartlang-app:/src/Resource/Template/TemplateType.dart",
"org-dartlang-app:/src/Resource/EventOccurredInfo.dart",
"org-dartlang-app:/src/Core/PropertyModificationInfo.dart",
"org-dartlang-app:/src/Resource/Template/ArgumentTemplate.dart",
"org-dartlang-app:/src/Resource/Template/ConstantTemplate.dart",
"org-dartlang-app:/src/Data/DataDeserializer.dart",
"org-dartlang-app:/src/Data/DataSerializer.dart",
"org-dartlang-app:/src/Data/ResourceArrayType.dart",
"org-dartlang-app:/src/Resource/PropertyModificationInfo.dart",
"org-dartlang-app:/src/Net/Sockets/WSocket.dart",
"org-dartlang-app:/src/Net/IIP/DistributedServer.dart",
"org-dartlang-app:/src/Data/KeyValuePair.dart",
"org-dartlang-app:/src/Data/ParseResult.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/algorithms.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/canonicalized_map.dart",
"package:collection/src/canonicalized_map.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/combined_wrappers/combined_iterable.dart",
"package:collection/src/combined_wrappers/combined_iterable.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/combined_wrappers/combined_list.dart",
"package:collection/src/combined_wrappers/combined_list.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/combined_wrappers/combined_map.dart",
"package:collection/src/combined_wrappers/combined_map.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/comparators.dart",
"package:collection/src/equality.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/equality.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/equality_map.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/wrappers.dart",
"package:collection/src/wrappers.dart",
"package:collection/src/equality_map.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/equality_set.dart",
"package:collection/src/equality_set.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/functions.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/iterable_extensions.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/iterable_zip.dart",
"package:collection/src/iterable_zip.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/list_extensions.dart",
"package:collection/src/list_extensions.dart",
"package:collection/src/priority_queue.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/priority_queue.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/queue_list.dart",
"package:collection/src/queue_list.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/union_set.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/unmodifiable_wrappers.dart",
"package:collection/src/unmodifiable_wrappers.dart",
"package:collection/src/union_set.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/union_set_controller.dart",
"package:collection/src/union_set_controller.dart",
"org-dartlang-app:/src/Net/IIP/EntryPoint.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/utils.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/combined_wrappers/combined_iterator.dart",
"package:collection/src/combined_wrappers/combined_iterator.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/collection-1.15.0/lib/src/empty_unmodifiable_set.dart",
"package:collection/src/empty_unmodifiable_set.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/web_socket_channel-2.1.0/lib/src/channel.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/stream_channel.dart",
"package:stream_channel/stream_channel.dart",
"package:web_socket_channel/src/channel.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/stream_sink.dart",
"package:async/src/delegate/stream_sink.dart",
"package:web_socket_channel/src/exception.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/web_socket_channel-2.1.0/lib/src/_connect_html.dart",
"package:web_socket_channel/src/copy/web_socket_impl.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/web_socket_channel-2.1.0/lib/src/copy/web_socket_impl.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/async_cache.dart",
"package:async/src/async_cache.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/async_memoizer.dart",
"package:async/src/async_memoizer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/byte_collector.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/cancelable_operation.dart",
"package:async/src/cancelable_operation.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/event_sink.dart",
"package:async/src/delegate/event_sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/future.dart",
"package:async/src/delegate/future.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/sink.dart",
"package:async/src/delegate/sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/stream.dart",
"package:async/src/delegate/stream.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/stream_consumer.dart",
"package:async/src/delegate/stream_consumer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/delegate/stream_subscription.dart",
"package:async/src/delegate/stream_subscription.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/future_group.dart",
"package:async/src/future_group.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/lazy_stream.dart",
"package:async/src/lazy_stream.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/null_stream_sink.dart",
"package:async/src/null_stream_sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/restartable_timer.dart",
"package:async/src/restartable_timer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/result.dart",
"package:async/src/result/result.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/error.dart",
"package:async/src/result/error.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/future.dart",
"package:async/src/result/future.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/value.dart",
"package:async/src/result/value.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/single_subscription_transformer.dart",
"package:async/src/single_subscription_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/sink_base.dart",
"package:async/src/sink_base.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_closer.dart",
"package:async/src/stream_closer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_completer.dart",
"package:async/src/stream_completer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_extensions.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_group.dart",
"package:async/src/stream_group.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_queue.dart",
"package:async/src/stream_queue.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_completer.dart",
"package:async/src/stream_sink_completer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_extensions.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_transformer.dart",
"package:async/src/stream_sink_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_splitter.dart",
"package:async/src/stream_splitter.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_subscription_transformer.dart",
"package:async/src/stream_subscription_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_zip.dart",
"package:async/src/stream_zip.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/subscription_stream.dart",
"package:async/src/subscription_stream.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/typed_stream_transformer.dart",
"package:async/src/typed_stream_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/chunked_stream_reader.dart",
"package:async/src/chunked_stream_reader.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/digest.dart",
"package:crypto/src/digest.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/hash.dart",
"package:crypto/src/hash.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/hmac.dart",
"package:crypto/src/hmac.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/md5.dart",
"package:crypto/src/md5.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/hash_sink.dart",
"package:crypto/src/hash_sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/sha1.dart",
"package:crypto/src/sha1.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/sha256.dart",
"package:crypto/src/sha256.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/sha512.dart",
"package:crypto/src/sha512.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/guarantee_channel.dart",
"package:stream_channel/src/guarantee_channel.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/close_guarantee_channel.dart",
"package:stream_channel/src/close_guarantee_channel.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/stream_channel_transformer.dart",
"package:stream_channel/src/stream_channel_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/delegating_stream_channel.dart",
"package:stream_channel/src/delegating_stream_channel.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/disconnector.dart",
"package:stream_channel/src/disconnector.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/json_document_transformer.dart",
"package:stream_channel/src/json_document_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/multi_channel.dart",
"package:stream_channel/src/multi_channel.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/stream_channel_completer.dart",
"package:stream_channel/src/stream_channel_completer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/src/stream_channel_controller.dart",
"package:stream_channel/src/stream_channel_controller.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/web_socket_channel-2.1.0/lib/html.dart",
"package:web_socket_channel/html.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/web_socket_channel-2.1.0/lib/src/copy/io_sink.dart",
"package:web_socket_channel/src/copy/io_sink.dart",
"package:web_socket_channel/src/copy/web_socket.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/typed/stream_subscription.dart",
"package:async/src/typed/stream_subscription.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/capture_sink.dart",
"package:async/src/result/capture_sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/capture_transformer.dart",
"package:async/src/result/capture_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/release_sink.dart",
"package:async/src/result/release_sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/result/release_transformer.dart",
"package:async/src/result/release_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/meta-1.7.0/lib/meta.dart",
"package:meta/meta.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_transformer/reject_errors.dart",
"package:async/src/stream_sink_transformer/reject_errors.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_transformer/handler_transformer.dart",
"package:async/src/stream_sink_transformer/handler_transformer.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_transformer/stream_transformer_wrapper.dart",
"package:async/src/stream_sink_transformer/stream_transformer_wrapper.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/async-2.8.1/lib/src/stream_sink_transformer/typed.dart",
"package:async/src/stream_sink_transformer/typed.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/digest_sink.dart",
"package:crypto/src/digest_sink.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/utils.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/crypto-3.0.1/lib/src/sha512_slowsinks.dart",
"package:crypto/src/sha512_slowsinks.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/meta-1.7.0/lib/meta_meta.dart",
"package:meta/meta_meta.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/typed_data-1.3.0/lib/src/typed_queue.dart",
"package:typed_data/src/typed_queue.dart",
"file:///C:/Users/Ahmed%20Zamil/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/typed_data-1.3.0/lib/src/typed_buffer.dart",
"package:typed_data/src/typed_buffer.dart"
];
esiur_js.main = function main() {
js.context._set("wh", new Warehouse.Warehouse.new());
};
Warehouse.Warehouse = class Warehouse$ extends core.Object {
static _initTemplates() {
let rt = new (T$.KeyListOfTemplateType$KeyListOfGuid$TypeTemplate()).new();
rt.add(TemplateType.TemplateType.Unspecified, new (T$.KeyListOfGuid$TypeTemplate()).new());
rt.add(TemplateType.TemplateType.Resource, new (T$.KeyListOfGuid$TypeTemplate()).new());
rt.add(TemplateType.TemplateType.Record, new (T$.KeyListOfGuid$TypeTemplate()).new());
rt.add(TemplateType.TemplateType.Wrapper, new (T$.KeyListOfGuid$TypeTemplate()).new());
return rt;
}
static getStore(name) {
let t0;
if (name == null) dart.nullFailed(I[0], 90, 34, "name");
for (let s of Warehouse.Warehouse._stores)
if ((t0 = s.instance, t0 == null ? null : t0.name) == name) return s;
return null;
}
static getById(id) {
if (id == null) dart.nullFailed(I[0], 100, 45, "id");
if (dart.test(Warehouse.Warehouse._resources[S$.$containsKey](id)))
return new (T$.AsyncReplyOfIResourceN()).ready(Warehouse.Warehouse._resources[S$.$_get](id));
else
return new (T$.AsyncReplyOfIResourceN()).ready(null);
}
static open() {
let bag = new (T$.AsyncBagOfbool()).new();
for (let s of Warehouse.Warehouse._stores)
bag.add(s.trigger(ResourceTrigger.ResourceTrigger.Initialize));
bag.seal();
let rt = new (T$.AsyncReplyOfbool()).new();
bag.then(core.Null, dart.fn(x => {
if (x == null) dart.nullFailed(I[0], 120, 15, "x");
for (let b of x)
if (b == null || b === false) {
rt.trigger(false);
return;
}
let rBag = new (T$.AsyncBagOfbool()).new();
for (let rk of Warehouse.Warehouse._resources[S$.$keys])
rBag.add(dart.nullCast(Warehouse.Warehouse._resources[S$.$_get](rk), IResource.IResource).trigger(ResourceTrigger.ResourceTrigger.SystemInitialized));
rBag.seal();
rBag.then(core.Null, dart.fn(y => {
if (y == null) dart.nullFailed(I[0], 134, 18, "y");
for (let b of y)
if (b == null || b === false) {
rt.trigger(false);
return;
}
rt.trigger(true);
Warehouse.Warehouse._warehouseIsOpen = true;
}, T$.ListOfboolToNull()));
}, T$.ListOfboolToNull()));
return rt;
}
static close() {
let bag = new (T$.AsyncBagOfbool()).new();
for (let resource of Warehouse.Warehouse._resources[S$.$values])
if (!IStore.IStore.is(resource)) bag.add(resource.trigger(ResourceTrigger.ResourceTrigger.Terminate));
for (let s of Warehouse.Warehouse._stores)
bag.add(s.trigger(ResourceTrigger.ResourceTrigger.Terminate));
for (let resource of Warehouse.Warehouse._resources[S$.$values])
if (!IStore.IStore.is(resource)) bag.add(resource.trigger(ResourceTrigger.ResourceTrigger.SystemTerminated));
for (let store of Warehouse.Warehouse._stores)
bag.add(store.trigger(ResourceTrigger.ResourceTrigger.SystemTerminated));
bag.seal();
let rt = new (T$.AsyncReplyOfbool()).new();
bag.then(core.Null, dart.fn(x => {
if (x == null) dart.nullFailed(I[0], 173, 15, "x");
for (let b of x)
if (b == null || b === false) {
rt.trigger(false);
return;
}
rt.trigger(true);
}, T$.ListOfboolToNull()));
return rt;
}
static qureyIn(path, index, resources) {
let t0, t0$, t0$0;
if (path == null) dart.nullFailed(I[0], 187, 20, "path");
if (index == null) dart.nullFailed(I[0], 187, 30, "index");
if (resources == null) dart.nullFailed(I[0], 187, 67, "resources");
let rt = T$.JSArrayOfIResource().of([]);
if (index === dart.notNull(path[S$.$length]) - 1) {
if (path[S$.$_get](index) === "")
for (let child of resources)
rt[S$.$add](child);
else
for (let child of resources)
if ((t0 = child.instance, t0 == null ? null : t0.name) == path[S$.$_get](index)) rt[S$.$add](child);
} else
for (let child of resources)
if ((t0$ = child.instance, t0$ == null ? null : t0$.name) == path[S$.$_get](index)) rt[S$.$addAll](Warehouse.Warehouse.qureyIn(path, dart.notNull(index) + 1, dart.nullCast((t0$0 = child.instance, t0$0 == null ? null : t0$0.children), T$.AutoListOfIResource$Instance())));
return rt;
}
static query(path) {
if (path == null || path === "") {
let roots = Warehouse.Warehouse._stores.where(dart.fn(s => {
let t0;
if (s == null) dart.nullFailed(I[0], 208, 26, "s");
return (t0 = s.instance, t0 == null ? null : t0.parents.length) === 0;
}, T$.IStoreTobool()))[S$.$toList]();
return new (T$.AsyncReplyOfListNOfIResource()).ready(roots);
} else {
let rt = new (T$.AsyncReplyOfListOfIResource()).new();
Warehouse.Warehouse.get(IResource.IResource, path).then(core.Null, dart.fn(x => {
let p = path[S$.$split]("/");
if (x == null) {
rt.trigger(Warehouse.Warehouse.qureyIn(p, 0, Warehouse.Warehouse._stores));
} else {
let ar = Warehouse.Warehouse.qureyIn(p, 0, Warehouse.Warehouse._stores)[S$.$where](dart.fn(r => {
if (r == null) dart.nullFailed(I[0], 218, 50, "r");
return !dart.equals(r, x);
}, T$.IResourceTobool()))[S$.$toList]();
ar[S$.$insert](0, x);
rt.trigger(ar);
}
}, T$.IResourceNToNull()));
return rt;
}
}
static get(T, path, attributes = null, parent = null, manager = null) {
let t0;
if (path == null) dart.nullFailed(I[0], 234, 57, "path");
let rt = new (AsyncReply$.AsyncReply$(dart.nullable(T))).new();
if (dart.test(Warehouse.Warehouse._urlRegex.hasMatch(path))) {
let url = Warehouse.Warehouse._urlRegex.allMatches(path)[S$.$first];
if (dart.test(Warehouse.Warehouse.protocols.containsKey(url._get(1)))) {
let handler = dart.nullCast(Warehouse.Warehouse.protocols._get(url._get(1)), T$.StringAndMapNOfString$dynamicToAsyncReplyOfIStore());
let getFromStore = dart.fn(() => {
let t0;
t0 = handler(dart.nullCast(url._get(2), core.String), attributes);
(() => {
t0.then(core.Null, dart.fn(store => {
let t1;
if (store == null) dart.nullFailed(I[0], 250, 21, "store");
if (dart.nullCast(url._get(3), core.String).length > 0 && url._get(3) !== "") {
t1 = store.get(dart.nullCast(url._get(3), core.String));
(() => {
t1.then(core.Null, dart.fn(r => {
rt.trigger(T.as(r));
}, T$.IResourceNToNull()));
t1.error(dart.fn(e => {
if (e == null) dart.nullFailed(I[0], 256, 28, "e");
return rt.triggerError(e);
}, dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(T)), [AsyncException.AsyncException])));
return t1;
})();
} else
rt.trigger(T.as(store));
}, T$.IStoreToNull()));
t0.error(dart.fn(e => {
if (e == null) dart.nullFailed(I[0], 260, 22, "e");
rt.triggerError(e);
}, T$.AsyncExceptionToNull()));
return t0;
})();
}, T$.VoidToNull());
if (!dart.test(Warehouse.Warehouse._warehouseIsOpen)) {
t0 = Warehouse.Warehouse.open();
(() => {
t0.then(core.Null, dart.fn(v => {
if (v == null) dart.nullFailed(I[0], 268, 21, "v");
if (dart.test(v))
getFromStore();
else
rt.trigger(null);
}, T$.boolToNull()));
return t0;
})();
} else
getFromStore();
return rt;
}
}
Warehouse.Warehouse.query(path).then(core.Null, dart.fn(rs => {
if (rs != null && dart.notNull(rs[S$.$length]) > 0)
rt.trigger(T.as(rs[S$.$_get](0)));
else
rt.trigger(null);
}, T$.ListNOfIResourceToNull()));
return rt;
}
static put(T, name, resource, store = null, parent = null, customTemplate = null, age = 0, manager = null, attributes = null) {
let t0, t0$, t0$0, t1, t0$1, t0$2, t0$3;
if (name == null) dart.nullFailed(I[0], 367, 57, "name");
if (resource == null) dart.nullFailed(I[0], 367, 65, "resource");
if (age == null) dart.nullFailed(I[0], 371, 11, "age");
let rt = new (AsyncReply$.AsyncReply$(dart.nullable(T))).new();
if (resource.instance != null) {
rt.triggerError(core.Exception.new("Resource has a store."));
return rt;
}
resource.instance = new Instance.Instance.new((t0 = Warehouse.Warehouse.resourceCounter, Warehouse.Warehouse.resourceCounter = dart.notNull(t0) + 1, t0), name, resource, store, customTemplate, age);
if (attributes != null) {
t0$ = resource.instance;
t0$ == null ? null : t0$.setAttributes(attributes);
}
if (manager != null) {
t0$0 = resource.instance;
t0$0 == null ? null : t0$0.managers.add(manager);
}
if (dart.equals(store, parent)) parent = null;
if (parent == null) {
if (!IStore.IStore.is(resource)) {
t0$1 = store;
t0$1 == null ? null : (t1 = t0$1.instance, t1 == null ? null : t1.children.add(resource));
}
} else {
t0$2 = parent.instance;
t0$2 == null ? null : t0$2.children.add(resource);
}
let initResource = dart.fn(() => {
if (resource.instance == null) return;
Warehouse.Warehouse._resources[S$.$_set](dart.nullCast(resource.instance, Instance.Instance).id, resource);
if (dart.test(Warehouse.Warehouse._warehouseIsOpen)) {
resource.trigger(ResourceTrigger.ResourceTrigger.Initialize).then(dart.dynamic, dart.fn(value => {
if (value == null) dart.nullFailed(I[0], 456, 69, "value");
if (IStore.IStore.is(resource))
resource.trigger(ResourceTrigger.ResourceTrigger.Open).then(dart.dynamic, dart.fn(value => {
if (value == null) dart.nullFailed(I[0], 458, 67, "value");
rt.trigger(resource);
}, T$.boolToNull())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[0], 460, 23, "ex");
Warehouse.Warehouse.remove(resource);
rt.triggerError(ex);
}, T$.AsyncExceptionToNull()));
else
rt.trigger(resource);
}, T$.boolToNull())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[0], 466, 19, "ex");
Warehouse.Warehouse.remove(resource);
rt.triggerError(ex);
}, T$.AsyncExceptionToNull()));
}
}, T$.VoidToNull());
if (IStore.IStore.is(resource)) {
Warehouse.Warehouse._stores.add(resource);
initResource();
} else {
t0$3 = store;
t0$3 == null ? null : t0$3.put(resource).then(dart.dynamic, dart.fn(value => {
if (value == null) dart.nullFailed(I[0], 477, 43, "value");
if (dart.test(value))
initResource();
else
rt.trigger(null);
}, T$.boolToNull())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[0], 482, 17, "ex");
Warehouse.Warehouse.remove(resource);
rt.triggerError(ex);
}, T$.AsyncExceptionToNull()));
}
return rt;
}
static get typesFactory() {
return Warehouse.Warehouse._factory;
}
static createInstance(T, type) {
let t0;
if (type == null) dart.nullFailed(I[0], 495, 35, "type");
return T.as((t0 = Warehouse.Warehouse._factory._get(type), t0 == null ? null : dart.dcall(t0.instanceCreator, [])));
}
static createArray(T, type) {
let t0;
if (type == null) dart.nullFailed(I[0], 499, 38, "type");
return core.List$(T).as((t0 = Warehouse.Warehouse._factory._get(type), t0 == null ? null : dart.dcall(t0.arrayCreator, [])));
}
static newResource(T, name, store = null, parent = null, manager = null, attributes = null, properties = null) {
let t0, t0$;
if (name == null) dart.nullFailed(I[0], 503, 64, "name");
if (Warehouse.Warehouse._factory._get(dart.wrapType(T)) == null) dart.throw(core.Exception.new("No Instance Creator was found for type " + dart.str(dart.wrapType(T))));
let resource = T.as((t0 = Warehouse.Warehouse._factory._get(dart.wrapType(T)), t0 == null ? null : dart.dcall(t0.instanceCreator, [])));
if (properties != null) {
let d = resource;
for (let i = 0; i < dart.notNull(properties[S$.$length]); i = i + 1)
dart.dsend(d, '_set', [properties[S$.$keys][S$.$elementAt](i), properties[S$.$values][S$.$elementAt](i)]);
}
let rt = new (AsyncReply$.AsyncReply$(T)).new();
t0$ = Warehouse.Warehouse.put(T, name, resource, store, parent, null, 0, manager, attributes);
(() => {
t0$.then(core.Null, dart.fn(value => {
if (value != null)
rt.trigger(resource);
else
rt.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.GeneralFailure.index, "Can't put the resource"));
}, dart.fnType(core.Null, [dart.nullable(T)])));
t0$.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[0], 534, 16, "ex");
return rt.triggerError(ex);
}, dart.fnType(AsyncReply$.AsyncReply$(T), [AsyncException.AsyncException])));
return t0$;
})();
return rt;
}
static putTemplate(template) {
let t0;
if (template == null) dart.nullFailed(I[0], 550, 40, "template");
t0 = Warehouse.Warehouse._templates._get(template.type);
t0 == null ? null : t0._set(template.classId, template);
}
static getTemplateByType(type) {
if (type == null) dart.nullFailed(I[0], 559, 47, "type");
for (let tmps of Warehouse.Warehouse._templates.values)
for (let tmp of tmps.values)
if (dart.equals(tmp.definedType, type)) return tmp;
let template = new TypeTemplate.TypeTemplate.fromType(type, true);
return template;
}
static getTemplateByClassId(classId, templateType = C[0] || CT.C0) {
let t0, t0$, t0$0, t0$1;
if (classId == null) dart.nullFailed(I[0], 577, 50, "classId");
if (templateType == null) dart.nullFailed(I[0], 578, 21, "templateType");
if (templateType == TemplateType.TemplateType.Unspecified) {
let template = (t0 = Warehouse.Warehouse._templates._get(TemplateType.TemplateType.Resource), t0 == null ? null : t0._get(classId));
if (template != null) return template;
template = (t0$ = Warehouse.Warehouse._templates._get(TemplateType.TemplateType.Record), t0$ == null ? null : t0$._get(classId));
if (template != null) return template;
template = (t0$0 = Warehouse.Warehouse._templates._get(TemplateType.TemplateType.Wrapper), t0$0 == null ? null : t0$0._get(classId));
return template;
} else {
t0$1 = Warehouse.Warehouse._templates._get(templateType);
return t0$1 == null ? null : t0$1._get(classId);
}
}
static getTemplateByClassName(className, templateType = C[0] || CT.C0) {
let t0, t0$, t0$0, t0$1;
if (className == null) dart.nullFailed(I[0], 601, 54, "className");
if (templateType == null) dart.nullFailed(I[0], 602, 21, "templateType");
if (templateType == TemplateType.TemplateType.Unspecified) {
let template = (t0 = Warehouse.Warehouse._templates._get(TemplateType.TemplateType.Resource), t0 == null ? null : t0.values[S$.$firstWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[0], 607, 24, "x");
return x.className == className;
}, T$.TypeTemplateTobool())));
if (template != null) return template;
template = (t0$ = Warehouse.Warehouse._templates._get(TemplateType.TemplateType.Record), t0$ == null ? null : t0$.values[S$.$firstWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[0], 613, 24, "x");
return x.className == className;
}, T$.TypeTemplateTobool())));
if (template != null) return template;
template = (t0$0 = Warehouse.Warehouse._templates._get(TemplateType.TemplateType.Wrapper), t0$0 == null ? null : t0$0.values[S$.$firstWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[0], 619, 24, "x");
return x.className == className;
}, T$.TypeTemplateTobool())));
return template;
} else {
t0$1 = Warehouse.Warehouse._templates._get(templateType);
return t0$1 == null ? null : t0$1.values[S$.$firstWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[0], 624, 24, "x");
return x.className == className;
}, T$.TypeTemplateTobool()));
}
}
static remove(resource) {
let t0, t0$, t0$0, t1, t0$1;
if (resource == null) dart.nullFailed(I[0], 628, 32, "resource");
if (resource.instance == null) return false;
if (dart.test(Warehouse.Warehouse._resources[S$.$containsKey]((t0 = resource.instance, t0 == null ? null : t0.id))))
Warehouse.Warehouse._resources[S$.$remove]((t0$ = resource.instance, t0$ == null ? null : t0$.id));
else
return false;
if (IStore.IStore.is(resource)) {
Warehouse.Warehouse._stores.remove(resource);
let toBeRemoved = Warehouse.Warehouse._resources[S$.$values][S$.$where](dart.fn(x => {
let t0;
if (x == null) dart.nullFailed(I[0], 641, 36, "x");
return dart.equals((t0 = x.instance, t0 == null ? null : t0.store), resource);
}, T$.IResourceTobool()));
for (let o of toBeRemoved)
Warehouse.Warehouse.remove(o);
}
if ((t0$0 = resource.instance, t0$0 == null ? null : t0$0.store) != null) {
t0$1 = resource.instance;
t0$1 == null ? null : (t1 = t0$1.store, t1 == null ? null : t1.remove(resource));
}
resource.destroy();
return true;
}
static _getSupportedProtocols() {
let t0;
let rt = new (T$.KeyListOfString$StringAndMapNOfString$dynamicToAsyncReplyOfIStore()).new();
t0 = rt;
(() => {
t0.add("iip", dart.fn((name, attributes) => {
if (name == null) dart.nullFailed(I[0], 663, 19, "name");
return Warehouse.Warehouse.newResource(DistributedConnection.DistributedConnection, name, null, null, null, attributes);
}, T$.StringAndMapNOfString$dynamicToAsyncReplyOfDistributedConnection()));
t0.add("iipws", dart.fn((name, attributes) => {
if (name == null) dart.nullFailed(I[0], 666, 30, "name");
if (attributes == null) attributes = new (T$.IdentityMapOfString$dynamic()).new();
attributes[S$.$_set]("ws", true);
return Warehouse.Warehouse.newResource(DistributedConnection.DistributedConnection, name, null, null, null, attributes);
}, T$.StringAndMapNOfString$dynamicToAsyncReplyOfDistributedConnection()));
t0.add("iipwss", dart.fn((name, attributes) => {
if (name == null) dart.nullFailed(I[0], 672, 31, "name");
if (attributes == null) attributes = new (T$.IdentityMapOfString$dynamic()).new();
attributes[S$.$_set]("wss", true);
return Warehouse.Warehouse.newResource(DistributedConnection.DistributedConnection, name, null, null, null, attributes);
}, T$.StringAndMapNOfString$dynamicToAsyncReplyOfDistributedConnection()));
return t0;
})();
return rt;
}
static _getTypeEntries(T, instanceCreator, representationType) {
if (instanceCreator == null) dart.nullFailed(I[0], 683, 16, "instanceCreator");
if (representationType == null) dart.nullFailed(I[0], 683, 52, "representationType");
return T$.JSArrayOfFactoryEntry().of([new (FactoryEntry$.FactoryEntry$(T)).new(instanceCreator, representationType), new (FactoryEntry$.FactoryEntry$(dart.nullable(T))).new(instanceCreator, representationType.toNullable()), new (FactoryEntry$.FactoryEntry$(core.List$(T))).new(dart.fn(() => _interceptors.JSArray$(T).of([]), dart.fnType(core.List$(T), [])), new RepresentationType.RepresentationType.new(72, false, null, T$.JSArrayOfRepresentationType().of([representationType]))), new (FactoryEntry$.FactoryEntry$(dart.nullable(core.List$(T)))).new(dart.fn(() => _interceptors.JSArray$(T).of([]), dart.fnType(core.List$(T), [])), new RepresentationType.RepresentationType.new(72, true, null, T$.JSArrayOfRepresentationType().of([representationType]))), new (FactoryEntry$.FactoryEntry$(core.List$(dart.nullable(T)))).new(dart.fn(() => _interceptors.JSArray$(dart.nullable(T)).of([]), dart.fnType(core.List$(dart.nullable(T)), [])), new RepresentationType.RepresentationType.new(72, false, null, T$.JSArrayOfRepresentationType().of([representationType.toNullable()]))), new (FactoryEntry$.FactoryEntry$(dart.nullable(core.List$(dart.nullable(T))))).new(dart.fn(() => _interceptors.JSArray$(dart.nullable(T)).of([]), dart.fnType(core.List$(dart.nullable(T)), [])), new RepresentationType.RepresentationType.new(72, true, null, T$.JSArrayOfRepresentationType().of([representationType.toNullable()])))]);
}
static defineType(T, instanceCreator, representationType) {
if (instanceCreator == null) dart.nullFailed(I[0], 707, 16, "instanceCreator");
if (representationType == null) dart.nullFailed(I[0], 707, 52, "representationType");
let entries = Warehouse.Warehouse._getTypeEntries(T, instanceCreator, representationType);
entries[S$.$forEach](dart.fn(e => {
if (e == null) dart.nullFailed(I[0], 709, 22, "e");
Warehouse.Warehouse._factory.add(e.type, e);
}, T$.FactoryEntryTovoid()));
}
static _getBuiltInTypes() {
let t0;
let rt = new (T$.KeyListOfType$FactoryEntry()).new();
let types = T$.JSArrayOfFactoryEntry().of([new (T$.FactoryEntryOfDistributedConnection()).new(dart.fn(() => new DistributedConnection.DistributedConnection.new(), T$.VoidToDistributedConnection()), RepresentationType.RepresentationType.Void)]);
t0 = types;
(() => {
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IntType.Int8, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(4, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IntType.UInt8, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(3, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IntType.Int16, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(6, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IntType.UInt16, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(7, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IntType.Int32, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(8, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IntType.UInt32, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(9, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.int, dart.fn(() => 0, T$.VoidToint()), new RepresentationType.RepresentationType.new(11, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.bool, dart.fn(() => false, T$.VoidTobool()), new RepresentationType.RepresentationType.new(2, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.double, dart.fn(() => 0.0, T$.VoidTodouble()), new RepresentationType.RepresentationType.new(13, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.String, dart.fn(() => "", T$.VoidToString()), new RepresentationType.RepresentationType.new(18, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.DateTime, dart.fn(() => new core.DateTime.now(), T$.VoidToDateTime()), new RepresentationType.RepresentationType.new(14, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(Record.Record, dart.fn(() => new Record.Record.new(), T$.VoidToRecord()), new RepresentationType.RepresentationType.new(21, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(IResource.IResource, dart.fn(() => null, T$.VoidToNull()), new RepresentationType.RepresentationType.new(20, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.List, dart.fn(() => [], T$.VoidToList()), new RepresentationType.RepresentationType.new(22, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(core.Map, dart.fn(() => new _js_helper.LinkedMap.new(), T$.VoidToMap()), new RepresentationType.RepresentationType.new(23, false)));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(T$.MapOfString$dynamic(), dart.fn(() => dart.wrapType(T$.MapOfStringL$dynamic()), T$.VoidToType()), new RepresentationType.RepresentationType.new(81, false, null, T$.JSArrayOfRepresentationType().of([new RepresentationType.RepresentationType.new(18, false), RepresentationType.RepresentationType.Dynamic]))));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(T$.MapOfint$dynamic(), dart.fn(() => new (T$.LinkedMapOfint$dynamic()).new(), T$.VoidToMapOfint$dynamic()), new RepresentationType.RepresentationType.new(81, false, null, T$.JSArrayOfRepresentationType().of([new RepresentationType.RepresentationType.new(11, false), RepresentationType.RepresentationType.Dynamic]))));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(T$.MapOfInt32$dynamic(), dart.fn(() => new (T$.LinkedMapOfInt32$dynamic()).new(), T$.VoidToMapOfInt32$dynamic()), new RepresentationType.RepresentationType.new(81, false, null, T$.JSArrayOfRepresentationType().of([new RepresentationType.RepresentationType.new(8, false), RepresentationType.RepresentationType.Dynamic]))));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(T$.MapOfUInt8$dynamic(), dart.fn(() => new (T$.LinkedMapOfUInt8$dynamic()).new(), T$.VoidToMapOfUInt8$dynamic()), new RepresentationType.RepresentationType.new(81, false, null, T$.JSArrayOfRepresentationType().of([new RepresentationType.RepresentationType.new(3, false), RepresentationType.RepresentationType.Dynamic]))));
t0[S$.$addAll](Warehouse.Warehouse._getTypeEntries(dart.dynamic, dart.fn(() => new core.Object.new(), T$.VoidToObject()), RepresentationType.RepresentationType.Dynamic));
return t0;
})();
types[S$.$forEach](dart.fn(element => {
if (element == null) dart.nullFailed(I[0], 784, 20, "element");
rt.add(element.type, element);
}, T$.FactoryEntryTovoid()));
return rt;
}
static ['_#new#tearOff']() {
return new Warehouse.Warehouse.new();
}
};
(Warehouse.Warehouse.new = function() {
;
}).prototype = Warehouse.Warehouse.prototype;
dart.addTypeTests(Warehouse.Warehouse);
dart.addTypeCaches(Warehouse.Warehouse);
dart.setStaticMethodSignature(Warehouse.Warehouse, () => ['_initTemplates', 'getStore', 'getById', 'open', 'close', 'qureyIn', 'query', 'get', 'put', 'createInstance', 'createArray', 'newResource', 'putTemplate', 'getTemplateByType', 'getTemplateByClassId', 'getTemplateByClassName', 'remove', '_getSupportedProtocols', '_getTypeEntries', 'defineType', '_getBuiltInTypes']);
dart.setStaticGetterSignature(Warehouse.Warehouse, () => ['typesFactory']);
dart.setLibraryUri(Warehouse.Warehouse, I[0]);
dart.setStaticFieldSignature(Warehouse.Warehouse, () => ['_stores', '_resources', 'resourceCounter', '_templates', '_factory', 'protocols', '_warehouseIsOpen', '_urlRegex']);
dart.defineLazy(Warehouse.Warehouse, {
/*Warehouse.Warehouse._stores*/get _stores() {
return new (T$.AutoListOfIStore$Instance()).new();
},
set _stores(_) {},
/*Warehouse.Warehouse._resources*/get _resources() {
return new (T$.LinkedMapOfint$IResource()).new();
},
set _resources(_) {},
/*Warehouse.Warehouse.resourceCounter*/get resourceCounter() {
return 0;
},
set resourceCounter(_) {},
/*Warehouse.Warehouse._templates*/get _templates() {
return Warehouse.Warehouse._initTemplates();
},
set _templates(_) {},
/*Warehouse.Warehouse._factory*/get _factory() {
return Warehouse.Warehouse._getBuiltInTypes();
},
set _factory(_) {},
/*Warehouse.Warehouse.protocols*/get protocols() {
return Warehouse.Warehouse._getSupportedProtocols();
},
set protocols(_) {},
/*Warehouse.Warehouse._warehouseIsOpen*/get _warehouseIsOpen() {
return false;
},
set _warehouseIsOpen(_) {},
/*Warehouse.Warehouse._urlRegex*/get _urlRegex() {
return core.RegExp.new("^(?:([^\\s|:]*):\\/\\/([^\\/]*)\\/?(.*))");
}
}, false);
IEventHandler.IEventHandler = class IEventHandler$ extends core.Object {
register(event) {
if (event == null) dart.nullFailed(I[2], 11, 24, "event");
this[S$._events][S$.$_set](event[S$.$toLowerCase](), T$.JSArrayOfFunction().of([]));
}
static ['_#new#tearOff']() {
return new IEventHandler.IEventHandler.new();
}
get properyModified() {
return this[S$._propertyModifiedController].stream;
}
emitProperty(event) {
if (event == null) dart.nullFailed(I[2], 20, 46, "event");
this[S$._propertyModifiedController].add(event);
}
emitArgs(event, $arguments) {
if (event == null) dart.nullFailed(I[2], 24, 24, "event");
if ($arguments == null) dart.nullFailed(I[2], 24, 36, "arguments");
let et = this[S$._events][S$.$_get](event[S$.$toLowerCase]());
if (et != null) {
for (let i = 0; i < dart.notNull(et[S$.$length]); i = i + 1)
if (core.Function.apply(et[S$.$_get](i), $arguments) != null) return true;
}
return false;
}
on(event, callback) {
let t6;
if (event == null) dart.nullFailed(I[2], 36, 18, "event");
if (callback == null) dart.nullFailed(I[2], 36, 34, "callback");
event = event[S$.$toLowerCase]();
if (!dart.test(this[S$._events][S$.$containsKey](event))) this.register(event);
t6 = this[S$._events][S$.$_get](event);
t6 == null ? null : t6[S$.$add](callback);
}
off(event, callback) {
let t6;
if (event == null) dart.nullFailed(I[2], 42, 19, "event");
event = event[S$.$toLowerCase]();
if (dart.test(this[S$._events][S$.$containsKey](event))) {
if (callback != null) {
t6 = this[S$._events][S$.$_get](event);
t6 == null ? null : t6[S$.$remove](callback);
} else
this[S$._events][S$.$_set](event, T$.JSArrayOfFunction().of([]));
}
}
};
(IEventHandler.IEventHandler.new = function() {
this[S$._propertyModifiedController] = T$.StreamControllerOfPropertyModificationInfo().new();
this[S$._events] = new (T$.IdentityMapOfString$ListOfFunction()).new();
}).prototype = IEventHandler.IEventHandler.prototype;
dart.addTypeTests(IEventHandler.IEventHandler);
dart.addTypeCaches(IEventHandler.IEventHandler);
dart.setMethodSignature(IEventHandler.IEventHandler, () => ({
__proto__: dart.getMethods(IEventHandler.IEventHandler.__proto__),
register: dart.fnType(dart.void, [core.String]),
emitProperty: dart.fnType(dart.void, [PropertyModificationInfo.PropertyModificationInfo]),
emitArgs: dart.fnType(core.bool, [core.String, core.List]),
on: dart.fnType(dart.void, [core.String, core.Function]),
off: dart.fnType(dart.void, [core.String, dart.nullable(core.Function)])
}));
dart.setGetterSignature(IEventHandler.IEventHandler, () => ({
__proto__: dart.getGetters(IEventHandler.IEventHandler.__proto__),
properyModified: async.Stream$(PropertyModificationInfo.PropertyModificationInfo)
}));
dart.setLibraryUri(IEventHandler.IEventHandler, I[2]);
dart.setFieldSignature(IEventHandler.IEventHandler, () => ({
__proto__: dart.getFields(IEventHandler.IEventHandler.__proto__),
[S$._propertyModifiedController]: dart.finalFieldType(async.StreamController$(PropertyModificationInfo.PropertyModificationInfo)),
[S$._events]: dart.fieldType(core.Map$(core.String, core.List$(core.Function)))
}));
Instance.Instance = class Instance$ extends IEventHandler.IEventHandler {
get [S$._children]() {
let t0;
return dart.test(this[S$.__Instance__children_isSet]) ? (t0 = this[S$.__Instance__children], t0) : dart.throw(new _internal.LateError.fieldNI("_children"));
}
set [S$._children](t0) {
if (t0 == null) dart.nullFailed(I[1], 30, 38, "null");
this[S$.__Instance__children_isSet] = true;
this[S$.__Instance__children] = t0;
}
get [S$._parents]() {
let t1;
return dart.test(this[S$.__Instance__parents_isSet]) ? (t1 = this[S$.__Instance__parents], t1) : dart.throw(new _internal.LateError.fieldNI("_parents"));
}
set [S$._parents](t1) {
if (t1 == null) dart.nullFailed(I[1], 33, 38, "null");
this[S$.__Instance__parents_isSet] = true;
this[S$.__Instance__parents] = t1;
}
get [S$._template]() {
let t2;
return dart.test(this[S$.__Instance__template_isSet]) ? (t2 = this[S$.__Instance__template], t2) : dart.throw(new _internal.LateError.fieldNI("_template"));
}
set [S$._template](t2) {
if (t2 == null) dart.nullFailed(I[1], 35, 21, "null");
this[S$.__Instance__template_isSet] = true;
this[S$.__Instance__template] = t2;
}
get [S$._managers]() {
let t3;
return dart.test(this[S$.__Instance__managers_isSet]) ? (t3 = this[S$.__Instance__managers], t3) : dart.throw(new _internal.LateError.fieldNI("_managers"));
}
set [S$._managers](t3) {
if (t3 == null) dart.nullFailed(I[1], 37, 48, "null");
this[S$.__Instance__managers_isSet] = true;
this[S$.__Instance__managers] = t3;
}
get [S$._attributes]() {
let t4;
return dart.test(this[S$.__Instance__attributes_isSet]) ? (t4 = this[S$.__Instance__attributes], t4) : dart.throw(new _internal.LateError.fieldNI("_attributes"));
}
set [S$._attributes](t4) {
if (t4 == null) dart.nullFailed(I[1], 39, 33, "null");
this[S$.__Instance__attributes_isSet] = true;
this[S$.__Instance__attributes] = t4;
}
get attributes() {
return this[S$._attributes];
}
toString() {
let t5;
return dart.notNull(this[S$._name]) + " (" + dart.notNull((t5 = this.link, t5 == null ? "" : t5)) + ")";
}
removeAttributes(attributes = null) {
if (attributes == null)
this[S$._attributes].clear();
else {
for (let attr of attributes)
this.attributes.remove(attr);
}
return true;
}
getAttributes(attributes = null) {
let st = new (T$.LinkedMapOfString$dynamic()).new();
if (attributes == null) {
let clone = this.attributes.keys[S$.$toList]();
clone[S$.$add]("managers");
attributes = clone[S$.$toList]();
}
for (let attr of attributes) {
if (attr === "name")
st[S$.$_set]("name", this[S$._name]);
else if (attr === "managers") {
let mngrs = T$.JSArrayOfMapOfString$dynamic().of([]);
for (let i = 0; i < dart.notNull(this[S$._managers].length); i = i + 1) {
let mst = new (T$.LinkedMapOfString$dynamic()).new();
mst[S$.$_set]("type", dart.runtimeType(this[S$._managers]._get(i)));
mst[S$.$_set]("settings", this[S$._managers]._get(i).settings);
mngrs[S$.$add](mst);
}
st[S$.$_set]("managers", mngrs);
} else if (attr === "parents") {
st[S$.$_set]("parents", this[S$._parents].toList());
} else if (attr === "children") {
st[S$.$_set]("children", this[S$._children].toList());
} else if (attr === "childrenCount") {
st[S$.$_set]("childrenCount", this[S$._children].count);
} else if (attr === "type") {
st[S$.$_set]("type", dart.runtimeType(this.resource));
} else
st[S$.$_set](attr, this[S$._attributes]._get(attr));
}
return st;
}
setAttributes(attributes, clearAttributes = false) {
if (attributes == null) dart.nullFailed(I[1], 105, 43, "attributes");
if (clearAttributes == null) dart.nullFailed(I[1], 106, 13, "clearAttributes");
try {
if (dart.test(clearAttributes)) this[S$._attributes].clear();
for (let attrKey of attributes[S$.$keys])
if (attrKey === "name")
this[S$._name] = core.String.as(attributes[S$.$_get](attrKey));
else if (attrKey === "managers") {
this[S$._managers].clear();
let mngrs = core.List.as(attributes[S$.$_get](attrKey));
} else {
this[S$._attributes]._set(attrKey, attributes[S$.$_get](attrKey));
}
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
return false;
} else
throw e;
}
return true;
}
getAge(index) {
if (index == null) dart.nullFailed(I[1], 173, 18, "index");
if (dart.notNull(index) < dart.notNull(this[S$._ages][S$.$length]))
return this[S$._ages][S$.$_get](index);
else
return 0;
}
setAge(index, value) {
if (index == null) dart.nullFailed(I[1], 185, 19, "index");
if (value == null) dart.nullFailed(I[1], 185, 30, "value");
if (dart.notNull(index) < dart.notNull(this[S$._ages][S$.$length])) {
this[S$._ages][S$.$_set](index, value);
if (dart.notNull(value) > dart.notNull(this[S$._instanceAge])) this[S$._instanceAge] = value;
}
}
setModificationDate(index, value) {
if (index == null) dart.nullFailed(I[1], 197, 32, "index");
if (value == null) dart.nullFailed(I[1], 197, 48, "value");
if (dart.notNull(index) < dart.notNull(this[S$._modificationDates][S$.$length])) {
this[S$._modificationDates][S$.$_set](index, value);
if (this[S$._instanceModificationDate] == null || dart.notNull(value.millisecondsSinceEpoch) > dart.notNull(dart.nullCast(this[S$._instanceModificationDate], core.DateTime).millisecondsSinceEpoch)) this[S$._instanceModificationDate] = value;
}
}
getModificationDate(index) {
if (index == null) dart.nullFailed(I[1], 212, 36, "index");
if (dart.notNull(index) < dart.notNull(this[S$._modificationDates][S$.$length]))
return this[S$._modificationDates][S$.$_get](index);
else
return new core.DateTime.new(0);
}
loadProperty(name, age, modificationDate, value) {
if (name == null) dart.nullFailed(I[1], 227, 14, "name");
if (age == null) dart.nullFailed(I[1], 227, 24, "age");
if (modificationDate == null) dart.nullFailed(I[1], 227, 38, "modificationDate");
return true;
}
get age() {
return this[S$._instanceAge];
}
set age(value) {
if (value == null) dart.nullFailed(I[1], 259, 15, "value");
return this[S$._instanceAge] = value;
}
get modificationDate() {
return this[S$._instanceModificationDate];
}
get id() {
return this[S$._id];
}
deserialize(properties) {
if (properties == null) dart.nullFailed(I[1], 276, 40, "properties");
for (let i = 0; i < dart.notNull(properties[S$.$length]); i = i + 1) {
let pt = this[S$._template].getPropertyTemplateByIndex(i);
if (pt != null) {
let pv = properties[S$.$_get](i);
this.loadProperty(pt.name, pv.age, pv.date, pv.value);
}
}
return true;
}
serialize() {
let props = T$.JSArrayOfPropertyValue().of([]);
for (let pt of this[S$._template].properties) {
}
return props;
}
isStorable() {
return false;
}
emitModification(pt, value) {
let t6, t6$;
if (pt == null) dart.nullFailed(I[1], 377, 42, "pt");
this[S$._instanceAge] = dart.notNull(this[S$._instanceAge]) + 1;
let now = new core.DateTime.now().toUtc();
this[S$._ages][S$.$_set](pt.index, this[S$._instanceAge]);
this[S$._modificationDates][S$.$_set](pt.index, now);
if (dart.test(pt.recordable)) {
t6 = this[S$._store];
t6 == null ? null : t6.modify(this[S$._resource], pt.name, value, this[S$._ages][S$.$_get](pt.index), now);
} else {
t6$ = this[S$._store];
t6$ == null ? null : t6$.record(this[S$._resource], pt.name, value, this[S$._ages][S$.$_get](pt.index), now);
}
let pmInfo = new PropertyModificationInfo.PropertyModificationInfo.new(this[S$._resource], pt, value, this[S$._instanceAge]);
this.emitArgs("PropertyModified", [pmInfo]);
this[S$._resource].emitArgs(":" + dart.str(pt.name), [value]);
this[S$._resource].emitProperty(pmInfo);
}
modified(propertyName) {
if (propertyName == null) dart.nullFailed(I[1], 405, 19, "propertyName");
let valueObject = new ValueObject.ValueObject.new();
if (dart.test(this.getPropertyValue(propertyName, valueObject))) {
let pt = this[S$._template].getPropertyTemplateByName(propertyName);
if (pt != null) this.emitModification(pt, valueObject.value);
}
}
emitResourceEvent(issuer, receivers, eventTemplate, value) {
if (eventTemplate == null) dart.nullFailed(I[1], 414, 21, "eventTemplate");
this.emitArgs("EventOccurred", [new EventOccurredInfo.EventOccurredInfo.new(this[S$._resource], eventTemplate, value, issuer, receivers)]);
}
getPropertyValue(name, valueObject) {
if (name == null) dart.nullFailed(I[1], 426, 32, "name");
if (valueObject == null) dart.nullFailed(I[1], 426, 50, "valueObject");
let pt = this[S$._template].getPropertyTemplateByName(name);
valueObject.value = null;
return false;
}
get parents() {
return this[S$._parents];
}
get store() {
return this[S$._store];
}
get children() {
return this[S$._children];
}
get link() {
let t6;
if (this[S$._store] != null) {
t6 = this[S$._store];
return t6 == null ? null : t6.link(this[S$._resource]);
} else {
let l = T$.JSArrayOfString().of([]);
let p = this[S$._resource];
while (true) {
if (p.instance != null) break;
let pi = dart.nullCast(p.instance, Instance.Instance);
l[S$.$insert](0, pi.name);
if (dart.equals(pi.parents.count, 0)) break;
p = pi.parents.first;
}
return l[S$.$join]("/");
}
}
get name() {
return this[S$._name];
}
set name(value) {
return this.name = value;
}
get resource() {
return this[S$._resource];
}
get template() {
return this[S$._template];
}
applicable(session, action, member, inquirer = null) {
if (session == null) dart.nullFailed(I[1], 512, 29, "session");
if (action == null) dart.nullFailed(I[1], 512, 49, "action");
for (let i = 0; i < dart.notNull(this[S$._managers].length); i = i + 1) {
let r = this[S$._managers]._get(i).applicable(this.resource, session, action, member, inquirer);
if (r != Ruling.Ruling.DontCare) return r;
}
return Ruling.Ruling.DontCare;
}
get managers() {
return this[S$._managers];
}
static ['_#new#tearOff'](_id, _name, _resource, _store, customTemplate = null, _instanceAge = 0) {
if (_id == null) dart.nullFailed(I[1], 535, 17, "_id");
if (_name == null) dart.nullFailed(I[1], 535, 27, "_name");
if (_resource == null) dart.nullFailed(I[1], 535, 39, "_resource");
if (_instanceAge == null) dart.nullFailed(I[1], 536, 50, "_instanceAge");
return new Instance.Instance.new(_id, _name, _resource, _store, customTemplate, _instanceAge);
}
children_OnRemoved(parent, value) {
let t6;
if (parent == null) dart.nullFailed(I[1], 597, 36, "parent");
if (value == null) dart.nullFailed(I[1], 597, 54, "value");
t6 = value.instance;
t6 == null ? null : t6.parents.remove(this[S$._resource]);
}
children_OnAdd(parent, value) {
let t6;
if (parent == null) dart.nullFailed(I[1], 601, 32, "parent");
if (value == null) dart.nullFailed(I[1], 601, 50, "value");
if (value.instance != null) {
let ins = dart.nullCast(value.instance, Instance.Instance);
if (dart.test(ins.parents.contains(this[S$._resource]))) {
t6 = value.instance;
t6 == null ? null : t6.parents.add(this[S$._resource]);
}
}
}
parents_OnRemoved(parent, value) {
let t6;
if (parent == null) dart.nullFailed(I[1], 609, 35, "parent");
if (value == null) dart.nullFailed(I[1], 609, 53, "value");
t6 = value.instance;
t6 == null ? null : t6.children.remove(this[S$._resource]);
}
parents_OnAdd(parent, value) {
let t6;
if (parent == null) dart.nullFailed(I[1], 613, 31, "parent");
if (value == null) dart.nullFailed(I[1], 613, 49, "value");
if (value.instance != null) {
let ins = dart.nullCast(value.instance, Instance.Instance);
if (!dart.test(ins.children.contains(this[S$._resource]))) {
t6 = value.instance;
t6 == null ? null : t6.children.add(this[S$._resource]);
}
}
}
resource_OnDestroy(sender) {
this.emitArgs("resourceDestroyed", [sender]);
}
};
(Instance.Instance.new = function(_id, _name, _resource, _store, customTemplate = null, _instanceAge = 0) {
if (_id == null) dart.nullFailed(I[1], 535, 17, "_id");
if (_name == null) dart.nullFailed(I[1], 535, 27, "_name");
if (_resource == null) dart.nullFailed(I[1], 535, 39, "_resource");
if (_instanceAge == null) dart.nullFailed(I[1], 536, 50, "_instanceAge");
this[S$.__Instance__children] = null;
this[S$.__Instance__children_isSet] = false;
this[S$.__Instance__parents] = null;
this[S$.__Instance__parents_isSet] = false;
this[S$.__Instance__template] = null;
this[S$.__Instance__template_isSet] = false;
this[S$.__Instance__managers] = null;
this[S$.__Instance__managers_isSet] = false;
this[S$.__Instance__attributes] = null;
this[S$.__Instance__attributes_isSet] = false;
this[S$._ages] = T$.JSArrayOfint().of([]);
this[S$._modificationDates] = T$.JSArrayOfDateTime().of([]);
this[S$._instanceModificationDate] = null;
this[S$._id] = _id;
this[S$._name] = _name;
this[S$._resource] = _resource;
this[S$._store] = _store;
this[S$._instanceAge] = _instanceAge;
Instance.Instance.__proto__.new.call(this);
this[S$._attributes] = new (T$.KeyListOfString$dynamic()).new(this);
this[S$._children] = new (T$.AutoListOfIResource$Instance()).new(this);
this[S$._parents] = new (T$.AutoListOfIResource$Instance()).new(this);
this[S$._managers] = new (T$.AutoListOfIPermissionsManager$Instance()).new(this);
this[S$._children].on("add", dart.bind(this, 'children_OnAdd'));
this[S$._children].on("remove", dart.bind(this, 'children_OnRemoved'));
this[S$._parents].on("add", dart.bind(this, 'parents_OnAdd'));
this[S$._parents].on("remove", dart.bind(this, 'parents_OnRemoved'));
this.resource.on("destroy", dart.bind(this, 'resource_OnDestroy'));
if (customTemplate != null)
this[S$._template] = customTemplate;
else
this[S$._template] = dart.nullCheck(Warehouse.Warehouse.getTemplateByType(dart.runtimeType(this.resource)));
for (let i = 0; i < dart.notNull(this[S$._template].properties[S$.$length]); i = i + 1) {
this[S$._ages][S$.$add](0);
this[S$._modificationDates][S$.$add](new core.DateTime.new(0));
}
}).prototype = Instance.Instance.prototype;
dart.addTypeTests(Instance.Instance);
dart.addTypeCaches(Instance.Instance);
dart.setMethodSignature(Instance.Instance, () => ({
__proto__: dart.getMethods(Instance.Instance.__proto__),
removeAttributes: dart.fnType(core.bool, [], [dart.nullable(core.List$(core.String))]),
getAttributes: dart.fnType(core.Map$(core.String, dart.dynamic), [], [dart.nullable(core.List$(core.String))]),
setAttributes: dart.fnType(core.bool, [core.Map$(core.String, dart.dynamic)], [core.bool]),
getAge: dart.fnType(core.int, [core.int]),
setAge: dart.fnType(dart.void, [core.int, core.int]),
setModificationDate: dart.fnType(dart.void, [core.int, core.DateTime]),
getModificationDate: dart.fnType(core.DateTime, [core.int]),
loadProperty: dart.fnType(core.bool, [core.String, core.int, core.DateTime, dart.dynamic]),
deserialize: dart.fnType(core.bool, [core.List$(PropertyValue.PropertyValue)]),
serialize: dart.fnType(core.List$(PropertyValue.PropertyValue), []),
isStorable: dart.fnType(core.bool, []),
emitModification: dart.fnType(dart.void, [PropertyTemplate.PropertyTemplate, dart.dynamic]),
modified: dart.fnType(dart.dynamic, [core.String]),
emitResourceEvent: dart.fnType(dart.dynamic, [dart.dynamic, dart.nullable(dart.fnType(core.bool, [Session.Session])), EventTemplate.EventTemplate, dart.dynamic]),
getPropertyValue: dart.fnType(core.bool, [core.String, ValueObject.ValueObject]),
applicable: dart.fnType(Ruling.Ruling, [Session.Session, ActionType.ActionType, dart.nullable(MemberTemplate.MemberTemplate)], [dart.dynamic]),
children_OnRemoved: dart.fnType(dart.void, [Instance.Instance, IResource.IResource]),
children_OnAdd: dart.fnType(dart.void, [Instance.Instance, IResource.IResource]),
parents_OnRemoved: dart.fnType(dart.void, [Instance.Instance, IResource.IResource]),
parents_OnAdd: dart.fnType(dart.void, [Instance.Instance, IResource.IResource]),
resource_OnDestroy: dart.fnType(dart.void, [dart.dynamic])
}));
dart.setGetterSignature(Instance.Instance, () => ({
__proto__: dart.getGetters(Instance.Instance.__proto__),
[S$._children]: AutoList$.AutoList$(IResource.IResource, Instance.Instance),
[S$._parents]: AutoList$.AutoList$(IResource.IResource, Instance.Instance),
[S$._template]: TypeTemplate.TypeTemplate,
[S$._managers]: AutoList$.AutoList$(IPermissionsManager.IPermissionsManager, Instance.Instance),
[S$._attributes]: KeyList$.KeyList$(core.String, dart.dynamic),
attributes: KeyList$.KeyList$(core.String, dart.dynamic),
age: core.int,
modificationDate: dart.nullable(core.DateTime),
id: core.int,
parents: AutoList$.AutoList$(IResource.IResource, Instance.Instance),
store: dart.nullable(IStore.IStore),
children: AutoList$.AutoList$(IResource.IResource, Instance.Instance),
link: dart.nullable(core.String),
name: core.String,
resource: IResource.IResource,
template: TypeTemplate.TypeTemplate,
managers: AutoList$.AutoList$(IPermissionsManager.IPermissionsManager, Instance.Instance)
}));
dart.setSetterSignature(Instance.Instance, () => ({
__proto__: dart.getSetters(Instance.Instance.__proto__),
[S$._children]: AutoList$.AutoList$(IResource.IResource, Instance.Instance),
[S$._parents]: AutoList$.AutoList$(IResource.IResource, Instance.Instance),
[S$._template]: TypeTemplate.TypeTemplate,
[S$._managers]: AutoList$.AutoList$(IPermissionsManager.IPermissionsManager, Instance.Instance),
[S$._attributes]: KeyList$.KeyList$(core.String, dart.dynamic),
age: core.int,
name: dart.dynamic
}));
dart.setLibraryUri(Instance.Instance, I[1]);
dart.setFieldSignature(Instance.Instance, () => ({
__proto__: dart.getFields(Instance.Instance.__proto__),
[S$._name]: dart.fieldType(core.String),
[S$.__Instance__children]: dart.fieldType(dart.nullable(AutoList$.AutoList$(IResource.IResource, Instance.Instance))),
[S$.__Instance__children_isSet]: dart.fieldType(core.bool),
[S$._resource]: dart.fieldType(IResource.IResource),
[S$._store]: dart.fieldType(dart.nullable(IStore.IStore)),
[S$.__Instance__parents]: dart.fieldType(dart.nullable(AutoList$.AutoList$(IResource.IResource, Instance.Instance))),
[S$.__Instance__parents_isSet]: dart.fieldType(core.bool),
[S$.__Instance__template]: dart.fieldType(dart.nullable(TypeTemplate.TypeTemplate)),
[S$.__Instance__template_isSet]: dart.fieldType(core.bool),
[S$.__Instance__managers]: dart.fieldType(dart.nullable(AutoList$.AutoList$(IPermissionsManager.IPermissionsManager, Instance.Instance))),
[S$.__Instance__managers_isSet]: dart.fieldType(core.bool),
[S$.__Instance__attributes]: dart.fieldType(dart.nullable(KeyList$.KeyList$(core.String, dart.dynamic))),
[S$.__Instance__attributes_isSet]: dart.fieldType(core.bool),
[S$._ages]: dart.fieldType(core.List$(core.int)),
[S$._modificationDates]: dart.fieldType(core.List$(core.DateTime)),
[S$._instanceAge]: dart.fieldType(core.int),
[S$._instanceModificationDate]: dart.fieldType(dart.nullable(core.DateTime)),
[S$._id]: dart.fieldType(core.int)
}));
dart.defineExtensionMethods(Instance.Instance, ['toString']);
IDestructible.IDestructible = class IDestructible extends IEventHandler.IEventHandler {};
(IDestructible.IDestructible.new = function() {
IDestructible.IDestructible.__proto__.new.call(this);
;
}).prototype = IDestructible.IDestructible.prototype;
dart.addTypeTests(IDestructible.IDestructible);
dart.addTypeCaches(IDestructible.IDestructible);
dart.setLibraryUri(IDestructible.IDestructible, I[3]);
IResource.IResource = class IResource extends IDestructible.IDestructible {
get instance() {
return this[S$.instance];
}
set instance(value) {
this[S$.instance] = value;
}
};
(IResource.IResource.new = function() {
this[S$.instance] = null;
IResource.IResource.__proto__.new.call(this);
;
}).prototype = IResource.IResource.prototype;
dart.addTypeTests(IResource.IResource);
dart.addTypeCaches(IResource.IResource);
dart.setLibraryUri(IResource.IResource, I[4]);
dart.setFieldSignature(IResource.IResource, () => ({
__proto__: dart.getFields(IResource.IResource.__proto__),
instance: dart.fieldType(dart.nullable(Instance.Instance))
}));
IStore.IStore = class IStore extends core.Object {};
(IStore.IStore.new = function() {
;
}).prototype = IStore.IStore.prototype;
dart.addTypeTests(IStore.IStore);
dart.addTypeCaches(IStore.IStore);
IStore.IStore[dart.implements] = () => [IResource.IResource];
dart.setLibraryUri(IStore.IStore, I[5]);
ResourceTrigger.ResourceTrigger = class ResourceTrigger extends core._Enum {
toString() {
return "ResourceTrigger." + dart.str(this[S$._name$1]);
}
};
(ResourceTrigger.ResourceTrigger.new = function(index, name) {
if (index == null) dart.nullFailed(I[6], 25, 6, "index");
if (name == null) dart.nullFailed(I[6], 25, 6, "name");
ResourceTrigger.ResourceTrigger.__proto__.new.call(this, index, name);
;
}).prototype = ResourceTrigger.ResourceTrigger.prototype;
dart.addTypeTests(ResourceTrigger.ResourceTrigger);
dart.addTypeCaches(ResourceTrigger.ResourceTrigger);
dart.setLibraryUri(ResourceTrigger.ResourceTrigger, I[6]);
dart.setStaticFieldSignature(ResourceTrigger.ResourceTrigger, () => ['values', 'Open', 'Initialize', 'Terminate', 'Configure', 'SystemInitialized', 'SystemTerminated', 'SystemReload']);
dart.defineExtensionMethods(ResourceTrigger.ResourceTrigger, ['toString']);
ResourceTrigger.ResourceTrigger.Open = C[1] || CT.C1;
ResourceTrigger.ResourceTrigger.Initialize = C[2] || CT.C2;
ResourceTrigger.ResourceTrigger.Terminate = C[3] || CT.C3;
ResourceTrigger.ResourceTrigger.Configure = C[4] || CT.C4;
ResourceTrigger.ResourceTrigger.SystemInitialized = C[5] || CT.C5;
ResourceTrigger.ResourceTrigger.SystemTerminated = C[6] || CT.C6;
ResourceTrigger.ResourceTrigger.SystemReload = C[7] || CT.C7;
ResourceTrigger.ResourceTrigger.values = C[8] || CT.C8;
StorageMode.StorageMode = class StorageMode$ extends core.Object {
static ['_#new#tearOff']() {
return new StorageMode.StorageMode.new();
}
};
(StorageMode.StorageMode.new = function() {
;
}).prototype = StorageMode.StorageMode.prototype;
dart.addTypeTests(StorageMode.StorageMode);
dart.addTypeCaches(StorageMode.StorageMode);
dart.setLibraryUri(StorageMode.StorageMode, I[7]);
dart.setStaticFieldSignature(StorageMode.StorageMode, () => ['NonVolatile', 'Volatile', 'Recordable']);
dart.defineLazy(StorageMode.StorageMode, {
/*StorageMode.StorageMode.NonVolatile*/get NonVolatile() {
return 0;
},
/*StorageMode.StorageMode.Volatile*/get Volatile() {
return 1;
},
/*StorageMode.StorageMode.Recordable*/get Recordable() {
return 2;
}
}, false);
MemberTemplate.MemberTemplate = class MemberTemplate$ extends core.Object {
get template() {
return this[S$.template];
}
set template(value) {
super.template = value;
}
get name() {
return this[S$.name];
}
set name(value) {
super.name = value;
}
get index() {
return this[S$.index];
}
set index(value) {
super.index = value;
}
get inherited() {
return this[S$.inherited];
}
set inherited(value) {
super.inherited = value;
}
static ['_#new#tearOff'](template, index, name, inherited) {
if (template == null) dart.nullFailed(I[9], 11, 23, "template");
if (index == null) dart.nullFailed(I[9], 11, 38, "index");
if (name == null) dart.nullFailed(I[9], 11, 50, "name");
if (inherited == null) dart.nullFailed(I[9], 11, 61, "inherited");
return new MemberTemplate.MemberTemplate.new(template, index, name, inherited);
}
get fullname() {
return dart.notNull(this.template.className) + "." + dart.notNull(this.name);
}
compose() {
return DC.DC.stringToBytes(this.name);
}
};
(MemberTemplate.MemberTemplate.new = function(template, index, name, inherited) {
if (template == null) dart.nullFailed(I[9], 11, 23, "template");
if (index == null) dart.nullFailed(I[9], 11, 38, "index");
if (name == null) dart.nullFailed(I[9], 11, 50, "name");
if (inherited == null) dart.nullFailed(I[9], 11, 61, "inherited");
this[S$.template] = template;
this[S$.index] = index;
this[S$.name] = name;
this[S$.inherited] = inherited;
}).prototype = MemberTemplate.MemberTemplate.prototype;
dart.addTypeTests(MemberTemplate.MemberTemplate);
dart.addTypeCaches(MemberTemplate.MemberTemplate);
dart.setMethodSignature(MemberTemplate.MemberTemplate, () => ({
__proto__: dart.getMethods(MemberTemplate.MemberTemplate.__proto__),
compose: dart.fnType(DC.DC, [])
}));
dart.setGetterSignature(MemberTemplate.MemberTemplate, () => ({
__proto__: dart.getGetters(MemberTemplate.MemberTemplate.__proto__),
fullname: core.String
}));
dart.setLibraryUri(MemberTemplate.MemberTemplate, I[9]);
dart.setFieldSignature(MemberTemplate.MemberTemplate, () => ({
__proto__: dart.getFields(MemberTemplate.MemberTemplate.__proto__),
template: dart.finalFieldType(TypeTemplate.TypeTemplate),
name: dart.finalFieldType(core.String),
index: dart.finalFieldType(core.int),
inherited: dart.finalFieldType(core.bool)
}));
EventTemplate.EventTemplate = class EventTemplate$ extends MemberTemplate.MemberTemplate {
get expansion() {
return this[S$.expansion];
}
set expansion(value) {
super.expansion = value;
}
get listenable() {
return this[S$.listenable];
}
set listenable(value) {
super.listenable = value;
}
get argumentType() {
return this[S$.argumentType];
}
set argumentType(value) {
super.argumentType = value;
}
compose() {
let t6, t6$;
let name = super.compose();
let hdr = dart.test(this.inherited) ? 128 : 0;
if (dart.test(this.listenable)) hdr = (hdr | 8) >>> 0;
if (this.expansion != null) {
let exp = DC.DC.stringToBytes(dart.nullCast(this.expansion, core.String));
return (t6 = new BinaryList.BinaryList.new(), (() => {
t6.addUint8(hdr);
t6.addUint8(name.length);
t6.addDC(name);
t6.addDC(this.argumentType.compose());
t6.addInt32(exp.length);
t6.addDC(exp);
return t6;
})()).toDC();
} else {
return (t6$ = new BinaryList.BinaryList.new(), (() => {
t6$.addUint8(hdr);
t6$.addUint8(name.length);
t6$.addDC(name);
t6$.addDC(this.argumentType.compose());
return t6$;
})()).toDC();
}
}
static ['_#new#tearOff'](template, index, name, inherited, argumentType, expansion = null, listenable = false) {
if (template == null) dart.nullFailed(I[8], 40, 30, "template");
if (index == null) dart.nullFailed(I[8], 40, 44, "index");
if (name == null) dart.nullFailed(I[8], 40, 58, "name");
if (inherited == null) dart.nullFailed(I[8], 40, 69, "inherited");
if (argumentType == null) dart.nullFailed(I[8], 41, 12, "argumentType");
if (listenable == null) dart.nullFailed(I[8], 42, 36, "listenable");
return new EventTemplate.EventTemplate.new(template, index, name, inherited, argumentType, expansion, listenable);
}
};
(EventTemplate.EventTemplate.new = function(template, index, name, inherited, argumentType, expansion = null, listenable = false) {
if (template == null) dart.nullFailed(I[8], 40, 30, "template");
if (index == null) dart.nullFailed(I[8], 40, 44, "index");
if (name == null) dart.nullFailed(I[8], 40, 58, "name");
if (inherited == null) dart.nullFailed(I[8], 40, 69, "inherited");
if (argumentType == null) dart.nullFailed(I[8], 41, 12, "argumentType");
if (listenable == null) dart.nullFailed(I[8], 42, 36, "listenable");
this[S$.argumentType] = argumentType;
this[S$.expansion] = expansion;
this[S$.listenable] = listenable;
EventTemplate.EventTemplate.__proto__.new.call(this, template, index, name, inherited);
}).prototype = EventTemplate.EventTemplate.prototype;
dart.addTypeTests(EventTemplate.EventTemplate);
dart.addTypeCaches(EventTemplate.EventTemplate);
dart.setLibraryUri(EventTemplate.EventTemplate, I[8]);
dart.setFieldSignature(EventTemplate.EventTemplate, () => ({
__proto__: dart.getFields(EventTemplate.EventTemplate.__proto__),
expansion: dart.finalFieldType(dart.nullable(core.String)),
listenable: dart.finalFieldType(core.bool),
argumentType: dart.finalFieldType(RepresentationType.RepresentationType)
}));
FunctionTemplate.FunctionTemplate = class FunctionTemplate$ extends MemberTemplate.MemberTemplate {
get expansion() {
return this[S$.expansion$1];
}
set expansion(value) {
this[S$.expansion$1] = value;
}
get arguments() {
return this[S$.$arguments];
}
set arguments(value) {
this[S$.$arguments] = value;
}
get returnType() {
return this[S$.returnType];
}
set returnType(value) {
this[S$.returnType] = value;
}
compose() {
let t6, t6$;
let name = super.compose();
let bl = (t6 = new BinaryList.BinaryList.new(), (() => {
t6.addUint8(name.length);
t6.addDC(name);
t6.addDC(this.returnType.compose());
t6.addUint8(this.arguments[S$.$length]);
return t6;
})());
for (let i = 0; i < dart.notNull(this.arguments[S$.$length]); i = i + 1)
bl.addDC(this.arguments[S$.$_get](i).compose());
if (this.expansion != null) {
let exp = DC.DC.stringToBytes(dart.nullCast(this.expansion, core.String));
t6$ = bl;
(() => {
t6$.addInt32(exp.length);
t6$.addDC(exp);
return t6$;
})();
bl.insertUint8(0, dart.test(this.inherited) ? 144 : 16);
} else
bl.insertUint8(0, dart.test(this.inherited) ? 128 : 0);
return bl.toDC();
}
static ['_#new#tearOff'](template, index, name, inherited, $arguments, returnType, expansion = null) {
if (template == null) dart.nullFailed(I[10], 39, 33, "template");
if (index == null) dart.nullFailed(I[10], 39, 47, "index");
if (name == null) dart.nullFailed(I[10], 39, 61, "name");
if (inherited == null) dart.nullFailed(I[10], 40, 12, "inherited");
if ($arguments == null) dart.nullFailed(I[10], 40, 28, "arguments");
if (returnType == null) dart.nullFailed(I[10], 40, 44, "returnType");
return new FunctionTemplate.FunctionTemplate.new(template, index, name, inherited, $arguments, returnType, expansion);
}
};
(FunctionTemplate.FunctionTemplate.new = function(template, index, name, inherited, $arguments, returnType, expansion = null) {
if (template == null) dart.nullFailed(I[10], 39, 33, "template");
if (index == null) dart.nullFailed(I[10], 39, 47, "index");
if (name == null) dart.nullFailed(I[10], 39, 61, "name");
if (inherited == null) dart.nullFailed(I[10], 40, 12, "inherited");
if ($arguments == null) dart.nullFailed(I[10], 40, 28, "arguments");
if (returnType == null) dart.nullFailed(I[10], 40, 44, "returnType");
this[S$.$arguments] = $arguments;
this[S$.returnType] = returnType;
this[S$.expansion$1] = expansion;
FunctionTemplate.FunctionTemplate.__proto__.new.call(this, template, index, name, inherited);
}).prototype = FunctionTemplate.FunctionTemplate.prototype;
dart.addTypeTests(FunctionTemplate.FunctionTemplate);
dart.addTypeCaches(FunctionTemplate.FunctionTemplate);
dart.setLibraryUri(FunctionTemplate.FunctionTemplate, I[10]);
dart.setFieldSignature(FunctionTemplate.FunctionTemplate, () => ({
__proto__: dart.getFields(FunctionTemplate.FunctionTemplate.__proto__),
expansion: dart.fieldType(dart.nullable(core.String)),
arguments: dart.fieldType(core.List$(ArgumentTemplate.ArgumentTemplate)),
returnType: dart.fieldType(RepresentationType.RepresentationType)
}));
MemberType.MemberType = class MemberType extends core._Enum {
toString() {
return "MemberType." + dart.str(this[S$._name$1]);
}
};
(MemberType.MemberType.new = function(index, name) {
if (index == null) dart.nullFailed(I[11], 1, 6, "index");
if (name == null) dart.nullFailed(I[11], 1, 6, "name");
MemberType.MemberType.__proto__.new.call(this, index, name);
;
}).prototype = MemberType.MemberType.prototype;
dart.addTypeTests(MemberType.MemberType);
dart.addTypeCaches(MemberType.MemberType);
dart.setLibraryUri(MemberType.MemberType, I[11]);
dart.setStaticFieldSignature(MemberType.MemberType, () => ['values', 'Function', 'Property', 'Event']);
dart.defineExtensionMethods(MemberType.MemberType, ['toString']);
MemberType.MemberType.Function = C[9] || CT.C9;
MemberType.MemberType.Property = C[10] || CT.C10;
MemberType.MemberType.Event = C[11] || CT.C11;
MemberType.MemberType.values = C[12] || CT.C12;
PropertyPermission.PropertyPermission = class PropertyPermission$ extends core.Object {
static ['_#new#tearOff']() {
return new PropertyPermission.PropertyPermission.new();
}
};
(PropertyPermission.PropertyPermission.new = function() {
;
}).prototype = PropertyPermission.PropertyPermission.prototype;
dart.addTypeTests(PropertyPermission.PropertyPermission);
dart.addTypeCaches(PropertyPermission.PropertyPermission);
dart.setLibraryUri(PropertyPermission.PropertyPermission, I[12]);
dart.setStaticFieldSignature(PropertyPermission.PropertyPermission, () => ['Read', 'Write', 'ReadWrite']);
dart.defineLazy(PropertyPermission.PropertyPermission, {
/*PropertyPermission.PropertyPermission.Read*/get Read() {
return 1;
},
/*PropertyPermission.PropertyPermission.Write*/get Write() {
return 2;
},
/*PropertyPermission.PropertyPermission.ReadWrite*/get ReadWrite() {
return 3;
}
}, false);
PropertyTemplate.PropertyTemplate = class PropertyTemplate$ extends MemberTemplate.MemberTemplate {
get valueType() {
return this[S$.valueType];
}
set valueType(value) {
this[S$.valueType] = value;
}
get permission() {
return this[S$.permission];
}
set permission(value) {
this[S$.permission] = value;
}
get recordable() {
return this[S$.recordable];
}
set recordable(value) {
this[S$.recordable] = value;
}
get readExpansion() {
return this[S$.readExpansion];
}
set readExpansion(value) {
this[S$.readExpansion] = value;
}
get writeExpansion() {
return this[S$.writeExpansion];
}
set writeExpansion(value) {
this[S$.writeExpansion] = value;
}
compose() {
let t6, t6$, t6$0, t6$1;
let name = super.compose();
let pv = (dart.notNull(this.permission) << 1 | (dart.test(this.recordable) ? 1 : 0)) >>> 0;
if (dart.test(this.inherited)) pv = (pv | 128) >>> 0;
if (this.writeExpansion != null && this.readExpansion != null) {
let rexp = DC.DC.stringToBytes(dart.nullCast(this.readExpansion, core.String));
let wexp = DC.DC.stringToBytes(dart.nullCast(this.writeExpansion, core.String));
return (t6 = new BinaryList.BinaryList.new(), (() => {
t6.addUint8((56 | pv) >>> 0);
t6.addUint8(name.length);
t6.addDC(name);
t6.addDC(this.valueType.compose());
t6.addInt32(wexp.length);
t6.addDC(wexp);
t6.addInt32(rexp.length);
t6.addDC(rexp);
return t6;
})()).toDC();
} else if (this.writeExpansion != null) {
let wexp = DC.DC.stringToBytes(dart.nullCast(this.writeExpansion, core.String));
return (t6$ = new BinaryList.BinaryList.new(), (() => {
t6$.addUint8((48 | pv) >>> 0);
t6$.addUint8(name.length);
t6$.addDC(name);
t6$.addDC(this.valueType.compose());
t6$.addInt32(wexp.length);
t6$.addDC(wexp);
return t6$;
})()).toDC();
} else if (this.readExpansion != null) {
let rexp = DC.DC.stringToBytes(dart.nullCast(this.readExpansion, core.String));
return (t6$0 = new BinaryList.BinaryList.new(), (() => {
t6$0.addUint8((40 | pv) >>> 0);
t6$0.addUint8(name.length);
t6$0.addDC(name);
t6$0.addDC(this.valueType.compose());
t6$0.addInt32(rexp.length);
t6$0.addDC(rexp);
return t6$0;
})()).toDC();
} else
return (t6$1 = new BinaryList.BinaryList.new(), (() => {
t6$1.addUint8((32 | pv) >>> 0);
t6$1.addUint8(name.length);
t6$1.addDC(name);
t6$1.addDC(this.valueType.compose());
return t6$1;
})()).toDC();
}
static ['_#new#tearOff'](template, index, name, inherited, valueType, readExpansion = null, writeExpansion = null, recordable = false) {
if (template == null) dart.nullFailed(I[13], 68, 33, "template");
if (index == null) dart.nullFailed(I[13], 68, 47, "index");
if (name == null) dart.nullFailed(I[13], 68, 61, "name");
if (inherited == null) dart.nullFailed(I[13], 69, 12, "inherited");
if (valueType == null) dart.nullFailed(I[13], 69, 28, "valueType");
if (recordable == null) dart.nullFailed(I[13], 72, 12, "recordable");
return new PropertyTemplate.PropertyTemplate.new(template, index, name, inherited, valueType, readExpansion, writeExpansion, recordable);
}
};
(PropertyTemplate.PropertyTemplate.new = function(template, index, name, inherited, valueType, readExpansion = null, writeExpansion = null, recordable = false) {
if (template == null) dart.nullFailed(I[13], 68, 33, "template");
if (index == null) dart.nullFailed(I[13], 68, 47, "index");
if (name == null) dart.nullFailed(I[13], 68, 61, "name");
if (inherited == null) dart.nullFailed(I[13], 69, 12, "inherited");
if (valueType == null) dart.nullFailed(I[13], 69, 28, "valueType");
if (recordable == null) dart.nullFailed(I[13], 72, 12, "recordable");
this[S$.permission] = 0;
this[S$.valueType] = valueType;
this[S$.readExpansion] = readExpansion;
this[S$.writeExpansion] = writeExpansion;
this[S$.recordable] = recordable;
PropertyTemplate.PropertyTemplate.__proto__.new.call(this, template, index, name, inherited);
}).prototype = PropertyTemplate.PropertyTemplate.prototype;
dart.addTypeTests(PropertyTemplate.PropertyTemplate);
dart.addTypeCaches(PropertyTemplate.PropertyTemplate);
dart.setLibraryUri(PropertyTemplate.PropertyTemplate, I[13]);
dart.setFieldSignature(PropertyTemplate.PropertyTemplate, () => ({
__proto__: dart.getFields(PropertyTemplate.PropertyTemplate.__proto__),
valueType: dart.fieldType(RepresentationType.RepresentationType),
permission: dart.fieldType(core.int),
recordable: dart.fieldType(core.bool),
readExpansion: dart.fieldType(dart.nullable(core.String)),
writeExpansion: dart.fieldType(dart.nullable(core.String))
}));
TypeTemplate.TypeTemplate = class TypeTemplate$ extends core.Object {
get [S$._classId]() {
let t6;
return dart.test(this[S$.__TypeTemplate__classId_isSet]) ? (t6 = this[S$.__TypeTemplate__classId], t6) : dart.throw(new _internal.LateError.fieldNI("_classId"));
}
set [S$._classId](t6) {
if (t6 == null) dart.nullFailed(I[14], 27, 13, "null");
this[S$.__TypeTemplate__classId_isSet] = true;
this[S$.__TypeTemplate__classId] = t6;
}
get [S$._className]() {
let t7;
return dart.test(this[S$.__TypeTemplate__className_isSet]) ? (t7 = this[S$.__TypeTemplate__className], t7) : dart.throw(new _internal.LateError.fieldNI("_className"));
}
set [S$._className](t7) {
if (t7 == null) dart.nullFailed(I[14], 30, 15, "null");
this[S$.__TypeTemplate__className_isSet] = true;
this[S$.__TypeTemplate__className] = t7;
}
get [S$._version]() {
let t8;
return dart.test(this[S$.__TypeTemplate__version_isSet]) ? (t8 = this[S$.__TypeTemplate__version], t8) : dart.throw(new _internal.LateError.fieldNI("_version"));
}
set [S$._version](t8) {
if (t8 == null) dart.nullFailed(I[14], 37, 12, "null");
this[S$.__TypeTemplate__version_isSet] = true;
this[S$.__TypeTemplate__version] = t8;
}
get [S$._templateType]() {
let t9;
return dart.test(this[S$.__TypeTemplate__templateType_isSet]) ? (t9 = this[S$.__TypeTemplate__templateType], t9) : dart.throw(new _internal.LateError.fieldNI("_templateType"));
}
set [S$._templateType](t9) {
if (t9 == null) dart.nullFailed(I[14], 40, 21, "null");
this[S$.__TypeTemplate__templateType_isSet] = true;
this[S$.__TypeTemplate__templateType] = t9;
}
get [S$._content]() {
let t10;
return dart.test(this[S$.__TypeTemplate__content_isSet]) ? (t10 = this[S$.__TypeTemplate__content], t10) : dart.throw(new _internal.LateError.fieldNI("_content"));
}
set [S$._content](t10) {
if (t10 == null) dart.nullFailed(I[14], 42, 11, "null");
this[S$.__TypeTemplate__content_isSet] = true;
this[S$.__TypeTemplate__content] = t10;
}
get content() {
return this[S$._content];
}
get type() {
return this[S$._templateType];
}
get parentId() {
return this[S$._parentId];
}
get definedType() {
return this[S$._definedType];
}
get parentDefinedType() {
return this[S$._parentDefinedType];
}
static getDependencies(template) {
if (template == null) dart.nullFailed(I[14], 58, 58, "template");
return T$.JSArrayOfTypeTemplate().of([]);
}
getEventTemplateByName(eventName) {
if (eventName == null) dart.nullFailed(I[14], 60, 48, "eventName");
for (let i of this[S$._events$1])
if (i.name == eventName) return i;
return null;
}
getEventTemplateByIndex(index) {
if (index == null) dart.nullFailed(I[14], 65, 46, "index");
for (let i of this[S$._events$1])
if (i.index == index) return i;
return null;
}
getFunctionTemplateByName(functionName) {
if (functionName == null) dart.nullFailed(I[14], 70, 54, "functionName");
for (let i of this[S$._functions])
if (i.name == functionName) return i;
return null;
}
getFunctionTemplateByIndex(index) {
if (index == null) dart.nullFailed(I[14], 75, 52, "index");
for (let i of this[S$._functions])
if (i.index == index) return i;
return null;
}
getPropertyTemplateByIndex(index) {
if (index == null) dart.nullFailed(I[14], 80, 52, "index");
for (let i of this[S$._properties])
if (i.index == index) return i;
return null;
}
getPropertyTemplateByName(propertyName) {
if (propertyName == null) dart.nullFailed(I[14], 85, 54, "propertyName");
for (let i of this[S$._properties])
if (i.name == propertyName) return i;
return null;
}
getConstantByIndex(index) {
if (index == null) dart.nullFailed(I[14], 90, 44, "index");
for (let i of this[S$._constants])
if (i.index == index) return i;
return null;
}
getConstantByName(constantName) {
if (constantName == null) dart.nullFailed(I[14], 95, 46, "constantName");
for (let i of this[S$._constants])
if (i.name == constantName) return i;
return null;
}
static getTypeGuid(typeName) {
if (typeName == null) dart.nullFailed(I[14], 100, 34, "typeName");
let tn = DC.DC.stringToBytes(typeName);
let hash = SHA256.SHA256.compute(tn).clip(0, 16);
return new Guid.Guid.new(hash);
}
get classId() {
return this[S$._classId];
}
get className() {
return this[S$._className];
}
get methods() {
return this[S$._members];
}
get functions() {
return this[S$._functions];
}
get events() {
return this[S$._events$1];
}
get properties() {
return this[S$._properties];
}
get constants() {
return this[S$._constants];
}
static ['_#fromType#tearOff'](type, addToWarehouse = false) {
if (type == null) dart.nullFailed(I[14], 120, 30, "type");
if (addToWarehouse == null) dart.nullFailed(I[14], 120, 42, "addToWarehouse");
return new TypeTemplate.TypeTemplate.fromType(type, addToWarehouse);
}
static ['_#parse#tearOff'](data, offset = 0, contentLength = null) {
if (data == null) dart.nullFailed(I[14], 482, 25, "data");
if (offset == null) dart.nullFailed(I[14], 482, 36, "offset");
return new TypeTemplate.TypeTemplate.parse(data, offset, contentLength);
}
};
(TypeTemplate.TypeTemplate.fromType = function(type, addToWarehouse = false) {
let t6, t6$, t6$0, t6$1, t6$2;
if (type == null) dart.nullFailed(I[14], 120, 30, "type");
if (addToWarehouse == null) dart.nullFailed(I[14], 120, 42, "addToWarehouse");
this[S$.__TypeTemplate__classId] = null;
this[S$.__TypeTemplate__classId_isSet] = false;
this[S$._parentId] = null;
this[S$.__TypeTemplate__className] = null;
this[S$.__TypeTemplate__className_isSet] = false;
this[S$._members] = T$.JSArrayOfMemberTemplate().of([]);
this[S$._functions] = T$.JSArrayOfFunctionTemplate().of([]);
this[S$._events$1] = T$.JSArrayOfEventTemplate().of([]);
this[S$._properties] = T$.JSArrayOfPropertyTemplate().of([]);
this[S$._constants] = T$.JSArrayOfConstantTemplate().of([]);
this[S$.__TypeTemplate__version] = null;
this[S$.__TypeTemplate__version_isSet] = false;
this[S$.__TypeTemplate__templateType] = null;
this[S$.__TypeTemplate__templateType_isSet] = false;
this[S$.__TypeTemplate__content] = null;
this[S$.__TypeTemplate__content_isSet] = false;
this[S$._definedType] = null;
this[S$._parentDefinedType] = null;
let instance = Warehouse.Warehouse.createInstance(dart.dynamic, type);
let describer = null;
if (DistributedResource.DistributedResource.is(instance)) {
this[S$._templateType] = TemplateType.TemplateType.Wrapper;
describer = instance.template;
} else if (IResource.IResource.is(instance)) {
this[S$._templateType] = TemplateType.TemplateType.Resource;
describer = instance.template;
} else if (IRecord.IRecord.is(instance)) {
this[S$._templateType] = TemplateType.TemplateType.Record;
describer = instance.template;
} else if (IEnum.IEnum.is(instance)) {
this[S$._templateType] = TemplateType.TemplateType.Enum;
describer = instance.template;
} else
dart.throw(core.Exception.new("Type must implement IResource, IRecord or inherit from DistributedResource."));
this[S$._definedType] = type;
this[S$._className] = describer.nameSpace;
this[S$._classId] = TypeTemplate.TypeTemplate.getTypeGuid(this[S$._className]);
this[S$._version] = describer.version;
if (dart.test(addToWarehouse)) Warehouse.Warehouse.putTemplate(this);
if (describer.constants != null) {
let consts = dart.nullCast(describer.constants, T$.ListOfConst());
for (let i = 0; i < dart.notNull(consts[S$.$length]); i = i + 1) {
let ci = consts[S$.$_get](i);
let ct = new ConstantTemplate.ConstantTemplate.new(this, i, ci.name, false, (t6 = RepresentationType.RepresentationType.fromType(ci.type), t6 == null ? RepresentationType.RepresentationType.Void : t6), ci.value, ci.annotation);
this.constants[S$.$add](ct);
}
}
if (describer.properties != null) {
let props = dart.nullCast(describer.properties, T$.ListOfProp());
for (let i = 0; i < dart.notNull(props[S$.$length]); i = i + 1) {
let pi = props[S$.$_get](i);
let pt = new PropertyTemplate.PropertyTemplate.new(this, i, pi.name, false, (t6$ = RepresentationType.RepresentationType.fromType(pi.type), t6$ == null ? RepresentationType.RepresentationType.Dynamic : t6$), pi.readAnnotation, pi.writeAnnotation, false);
this.properties[S$.$add](pt);
}
}
if (describer.functions != null) {
let funcs = dart.nullCast(describer.functions, T$.ListOfFunc());
for (let i = 0; i < dart.notNull(funcs[S$.$length]); i = i + 1) {
let fi = funcs[S$.$_get](i);
let args = fi.argsType[S$.$asMap]()[S$.$entries][S$.$map](ArgumentTemplate.ArgumentTemplate, dart.fn(arg => {
let t6;
if (arg == null) dart.nullFailed(I[14], 206, 19, "arg");
return new ArgumentTemplate.ArgumentTemplate.new(arg.value.name, (t6 = RepresentationType.RepresentationType.fromType(arg.value.type), t6 == null ? RepresentationType.RepresentationType.Dynamic : t6), arg.value.optional, arg.key);
}, T$.MapEntryOfint$ArgToArgumentTemplate()))[S$.$toList]();
let ft = new FunctionTemplate.FunctionTemplate.new(this, i, fi.name, false, args, (t6$0 = RepresentationType.RepresentationType.fromType(fi.returnType), t6$0 == null ? RepresentationType.RepresentationType.Void : t6$0), fi.annotation);
this.functions[S$.$add](ft);
}
}
if (describer.events != null) {
let evts = dart.nullCast(describer.events, T$.ListOfEvt());
for (let i = 0; i < dart.notNull(evts[S$.$length]); i = i + 1) {
let ei = evts[S$.$_get](i);
let et = new EventTemplate.EventTemplate.new(this, i, ei.name, false, (t6$1 = RepresentationType.RepresentationType.fromType(ei.type), t6$1 == null ? RepresentationType.RepresentationType.Dynamic : t6$1), ei.annotation, ei.listenable);
this.events[S$.$add](et);
}
}
this.events[S$.$forEach](T$.MemberTemplateTovoid().as(dart.bind(this[S$._members], S$.$add)));
this.functions[S$.$forEach](T$.MemberTemplateTovoid().as(dart.bind(this[S$._members], S$.$add)));
this.properties[S$.$forEach](T$.MemberTemplateTovoid().as(dart.bind(this[S$._members], S$.$add)));
let b = (t6$2 = new BinaryList.BinaryList.new(), (() => {
t6$2.addUint8(this[S$._templateType].index);
t6$2.addGuid(this.classId);
t6$2.addUint8(this.className.length);
t6$2.addString(this.className);
t6$2.addInt32(this[S$._version]);
t6$2.addUint16(this[S$._members][S$.$length]);
return t6$2;
})());
this.functions[S$.$forEach](dart.fn(ft => {
if (ft == null) dart.nullFailed(I[14], 262, 24, "ft");
return b.addDC(ft.compose());
}, T$.FunctionTemplateTovoid()));
this.properties[S$.$forEach](dart.fn(pt => {
if (pt == null) dart.nullFailed(I[14], 263, 25, "pt");
return b.addDC(pt.compose());
}, T$.PropertyTemplateTovoid()));
this.events[S$.$forEach](dart.fn(et => {
if (et == null) dart.nullFailed(I[14], 264, 21, "et");
return b.addDC(et.compose());
}, T$.EventTemplateTovoid()));
this[S$._content] = b.toDC();
}).prototype = TypeTemplate.TypeTemplate.prototype;
(TypeTemplate.TypeTemplate.parse = function(data, offset = 0, contentLength = null) {
let t6, t6$, t6$0, t6$1, t6$2, t6$3, t6$4, t6$5, t6$6, t6$7;
if (data == null) dart.nullFailed(I[14], 482, 25, "data");
if (offset == null) dart.nullFailed(I[14], 482, 36, "offset");
this[S$.__TypeTemplate__classId] = null;
this[S$.__TypeTemplate__classId_isSet] = false;
this[S$._parentId] = null;
this[S$.__TypeTemplate__className] = null;
this[S$.__TypeTemplate__className_isSet] = false;
this[S$._members] = T$.JSArrayOfMemberTemplate().of([]);
this[S$._functions] = T$.JSArrayOfFunctionTemplate().of([]);
this[S$._events$1] = T$.JSArrayOfEventTemplate().of([]);
this[S$._properties] = T$.JSArrayOfPropertyTemplate().of([]);
this[S$._constants] = T$.JSArrayOfConstantTemplate().of([]);
this[S$.__TypeTemplate__version] = null;
this[S$.__TypeTemplate__version_isSet] = false;
this[S$.__TypeTemplate__templateType] = null;
this[S$.__TypeTemplate__templateType_isSet] = false;
this[S$.__TypeTemplate__content] = null;
this[S$.__TypeTemplate__content_isSet] = false;
this[S$._definedType] = null;
this[S$._parentDefinedType] = null;
contentLength == null ? contentLength = data.length : null;
let ends = dart.notNull(offset) + dart.notNull(contentLength);
let oOffset = offset;
this[S$._content] = data.clip(offset, contentLength);
let hasParent = (dart.notNull(data.getUint8(offset)) & 128) > 0;
this[S$._templateType] = TemplateType.TemplateType.values[S$.$_get](dart.notNull(data.getUint8((t6 = offset, offset = dart.notNull(t6) + 1, t6))) & 15);
this[S$._classId] = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
this[S$._className] = data.getString(dart.notNull(offset) + 1, data._get(offset));
offset = dart.notNull(offset) + (dart.notNull(data._get(offset)) + 1);
if (hasParent) {
this[S$._parentId] = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
}
this[S$._version] = data.getInt32(offset);
offset = dart.notNull(offset) + 4;
let methodsCount = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
let functionIndex = 0;
let propertyIndex = 0;
let eventIndex = 0;
for (let i = 0; i < dart.notNull(methodsCount); i = i + 1) {
let inherited = (dart.notNull(data._get(offset)) & 128) > 0;
let type = dart.notNull(data._get(offset)) >> 5 & 3;
if (type === 0) {
let expansion = null;
let hasExpansion = (dart.notNull(data._get((t6$ = offset, offset = dart.notNull(t6$) + 1, t6$))) & 16) === 16;
let name = data.getString(dart.notNull(offset) + 1, data._get(offset));
offset = dart.notNull(offset) + (dart.notNull(data._get(offset)) + 1);
let dt = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(dt.size);
let argsCount = data._get((t6$0 = offset, offset = dart.notNull(t6$0) + 1, t6$0));
let $arguments = T$.JSArrayOfArgumentTemplate().of([]);
for (let a = 0; a < dart.notNull(argsCount); a = a + 1) {
let art = ArgumentTemplate.ArgumentTemplate.parse(data, offset, a);
$arguments[S$.$add](art.value);
offset = dart.notNull(offset) + dart.notNull(art.size);
}
if (hasExpansion) {
let cs = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
expansion = data.getString(offset, cs);
offset = dart.notNull(offset) + dart.notNull(cs);
}
let ft = new FunctionTemplate.FunctionTemplate.new(this, (t6$1 = functionIndex, functionIndex = t6$1 + 1, t6$1), name, inherited, $arguments, dt.type, expansion);
this[S$._functions][S$.$add](ft);
} else if (type === 1) {
let readExpansion = null;
let writeExpansion = null;
let hasReadExpansion = (dart.notNull(data._get(offset)) & 8) === 8;
let hasWriteExpansion = (dart.notNull(data._get(offset)) & 16) === 16;
let recordable = (dart.notNull(data._get(offset)) & 1) === 1;
let permission = dart.notNull(data._get((t6$2 = offset, offset = dart.notNull(t6$2) + 1, t6$2))) >> 1 & 3;
let name = data.getString(dart.notNull(offset) + 1, data._get(offset));
offset = dart.notNull(offset) + (dart.notNull(data._get(offset)) + 1);
let dt = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(dt.size);
if (hasReadExpansion) {
let cs = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
readExpansion = data.getString(offset, cs);
offset = dart.notNull(offset) + dart.notNull(cs);
}
if (hasWriteExpansion) {
let cs = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
writeExpansion = data.getString(offset, cs);
offset = dart.notNull(offset) + dart.notNull(cs);
}
let pt = new PropertyTemplate.PropertyTemplate.new(this, (t6$3 = propertyIndex, propertyIndex = t6$3 + 1, t6$3), name, inherited, dt.type, readExpansion, writeExpansion, recordable);
this[S$._properties][S$.$add](pt);
} else if (type === 2) {
let expansion = null;
let hasExpansion = (dart.notNull(data._get(offset)) & 16) === 16;
let listenable = (dart.notNull(data._get((t6$4 = offset, offset = dart.notNull(t6$4) + 1, t6$4))) & 8) === 8;
let name = data.getString(dart.notNull(offset) + 1, data._get(offset));
offset = dart.notNull(offset) + (dart.notNull(data._get(offset)) + 1);
let dt = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(dt.size);
if (hasExpansion) {
let cs = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
expansion = data.getString(offset, cs);
offset = dart.notNull(offset) + dart.notNull(cs);
}
let et = new EventTemplate.EventTemplate.new(this, (t6$5 = eventIndex, eventIndex = t6$5 + 1, t6$5), name, inherited, dt.type, expansion, listenable);
this[S$._events$1][S$.$add](et);
} else if (type === 3) {
let expansion = null;
let hasExpansion = (dart.notNull(data._get((t6$6 = offset, offset = dart.notNull(t6$6) + 1, t6$6))) & 16) === 16;
let name = data.getString(dart.notNull(offset) + 1, data._get(offset));
offset = dart.notNull(offset) + (dart.notNull(data._get(offset)) + 1);
let dt = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(dt.size);
let parsed = Codec.Codec.parse(data, offset, null);
offset = dart.notNull(offset) + dart.notNull(parsed.size);
if (hasExpansion) {
let cs = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
expansion = data.getString(offset, cs);
offset = dart.notNull(offset) + dart.notNull(cs);
}
let ct = new ConstantTemplate.ConstantTemplate.new(this, (t6$7 = eventIndex, eventIndex = t6$7 + 1, t6$7), name, inherited, dt.type, parsed.reply.result, expansion);
this[S$._constants][S$.$add](ct);
}
}
for (let i = 0; i < dart.notNull(this[S$._events$1][S$.$length]); i = i + 1)
this[S$._members][S$.$add](this[S$._events$1][S$.$_get](i));
for (let i = 0; i < dart.notNull(this[S$._functions][S$.$length]); i = i + 1)
this[S$._members][S$.$add](this[S$._functions][S$.$_get](i));
for (let i = 0; i < dart.notNull(this[S$._properties][S$.$length]); i = i + 1)
this[S$._members][S$.$add](this[S$._properties][S$.$_get](i));
for (let i = 0; i < dart.notNull(this[S$._constants][S$.$length]); i = i + 1)
this[S$._members][S$.$add](this[S$._constants][S$.$_get](i));
}).prototype = TypeTemplate.TypeTemplate.prototype;
dart.addTypeTests(TypeTemplate.TypeTemplate);
dart.addTypeCaches(TypeTemplate.TypeTemplate);
dart.setMethodSignature(TypeTemplate.TypeTemplate, () => ({
__proto__: dart.getMethods(TypeTemplate.TypeTemplate.__proto__),
getEventTemplateByName: dart.fnType(dart.nullable(EventTemplate.EventTemplate), [core.String]),
getEventTemplateByIndex: dart.fnType(dart.nullable(EventTemplate.EventTemplate), [core.int]),
getFunctionTemplateByName: dart.fnType(dart.nullable(FunctionTemplate.FunctionTemplate), [core.String]),
getFunctionTemplateByIndex: dart.fnType(dart.nullable(FunctionTemplate.FunctionTemplate), [core.int]),
getPropertyTemplateByIndex: dart.fnType(dart.nullable(PropertyTemplate.PropertyTemplate), [core.int]),
getPropertyTemplateByName: dart.fnType(dart.nullable(PropertyTemplate.PropertyTemplate), [core.String]),
getConstantByIndex: dart.fnType(dart.nullable(ConstantTemplate.ConstantTemplate), [core.int]),
getConstantByName: dart.fnType(dart.nullable(ConstantTemplate.ConstantTemplate), [core.String])
}));
dart.setStaticMethodSignature(TypeTemplate.TypeTemplate, () => ['getDependencies', 'getTypeGuid']);
dart.setGetterSignature(TypeTemplate.TypeTemplate, () => ({
__proto__: dart.getGetters(TypeTemplate.TypeTemplate.__proto__),
[S$._classId]: Guid.Guid,
[S$._className]: core.String,
[S$._version]: core.int,
[S$._templateType]: TemplateType.TemplateType,
[S$._content]: DC.DC,
content: DC.DC,
type: TemplateType.TemplateType,
parentId: dart.nullable(Guid.Guid),
definedType: dart.nullable(core.Type),
parentDefinedType: dart.nullable(core.Type),
classId: Guid.Guid,
className: core.String,
methods: core.List$(MemberTemplate.MemberTemplate),
functions: core.List$(FunctionTemplate.FunctionTemplate),
events: core.List$(EventTemplate.EventTemplate),
properties: core.List$(PropertyTemplate.PropertyTemplate),
constants: core.List$(ConstantTemplate.ConstantTemplate)
}));
dart.setSetterSignature(TypeTemplate.TypeTemplate, () => ({
__proto__: dart.getSetters(TypeTemplate.TypeTemplate.__proto__),
[S$._classId]: Guid.Guid,
[S$._className]: core.String,
[S$._version]: core.int,
[S$._templateType]: TemplateType.TemplateType,
[S$._content]: DC.DC
}));
dart.setLibraryUri(TypeTemplate.TypeTemplate, I[14]);
dart.setFieldSignature(TypeTemplate.TypeTemplate, () => ({
__proto__: dart.getFields(TypeTemplate.TypeTemplate.__proto__),
[S$.__TypeTemplate__classId]: dart.fieldType(dart.nullable(Guid.Guid)),
[S$.__TypeTemplate__classId_isSet]: dart.fieldType(core.bool),
[S$._parentId]: dart.fieldType(dart.nullable(Guid.Guid)),
[S$.__TypeTemplate__className]: dart.fieldType(dart.nullable(core.String)),
[S$.__TypeTemplate__className_isSet]: dart.fieldType(core.bool),
[S$._members]: dart.fieldType(core.List$(MemberTemplate.MemberTemplate)),
[S$._functions]: dart.fieldType(core.List$(FunctionTemplate.FunctionTemplate)),
[S$._events$1]: dart.fieldType(core.List$(EventTemplate.EventTemplate)),
[S$._properties]: dart.fieldType(core.List$(PropertyTemplate.PropertyTemplate)),
[S$._constants]: dart.fieldType(core.List$(ConstantTemplate.ConstantTemplate)),
[S$.__TypeTemplate__version]: dart.fieldType(dart.nullable(core.int)),
[S$.__TypeTemplate__version_isSet]: dart.fieldType(core.bool),
[S$.__TypeTemplate__templateType]: dart.fieldType(dart.nullable(TemplateType.TemplateType)),
[S$.__TypeTemplate__templateType_isSet]: dart.fieldType(core.bool),
[S$.__TypeTemplate__content]: dart.fieldType(dart.nullable(DC.DC)),
[S$.__TypeTemplate__content_isSet]: dart.fieldType(core.bool),
[S$._definedType]: dart.fieldType(dart.nullable(core.Type)),
[S$._parentDefinedType]: dart.fieldType(dart.nullable(core.Type))
}));
TemplateDescriber.TemplateDescriber = class TemplateDescriber$ extends core.Object {
get properties() {
return this[S$.properties];
}
set properties(value) {
super.properties = value;
}
get events() {
return this[S$.events];
}
set events(value) {
super.events = value;
}
get functions() {
return this[S$.functions];
}
set functions(value) {
super.functions = value;
}
get constants() {
return this[S$.constants];
}
set constants(value) {
super.constants = value;
}
get nameSpace() {
return this[S$.nameSpace];
}
set nameSpace(value) {
super.nameSpace = value;
}
get version() {
return this[S$.version];
}
set version(value) {
super.version = value;
}
get parent() {
return this[S$.parent];
}
set parent(value) {
super.parent = value;
}
static ['_#new#tearOff'](nameSpace, opts) {
if (nameSpace == null) dart.nullFailed(I[15], 12, 32, "nameSpace");
let parent = opts && 'parent' in opts ? opts.parent : null;
let properties = opts && 'properties' in opts ? opts.properties : null;
let functions = opts && 'functions' in opts ? opts.functions : null;
let events = opts && 'events' in opts ? opts.events : null;
let constants = opts && 'constants' in opts ? opts.constants : null;
let version = opts && 'version' in opts ? opts.version : 0;
if (version == null) dart.nullFailed(I[15], 18, 12, "version");
return new TemplateDescriber.TemplateDescriber.new(nameSpace, {parent: parent, properties: properties, functions: functions, events: events, constants: constants, version: version});
}
};
(TemplateDescriber.TemplateDescriber.new = function(nameSpace, opts) {
if (nameSpace == null) dart.nullFailed(I[15], 12, 32, "nameSpace");
let parent = opts && 'parent' in opts ? opts.parent : null;
let properties = opts && 'properties' in opts ? opts.properties : null;
let functions = opts && 'functions' in opts ? opts.functions : null;
let events = opts && 'events' in opts ? opts.events : null;
let constants = opts && 'constants' in opts ? opts.constants : null;
let version = opts && 'version' in opts ? opts.version : 0;
if (version == null) dart.nullFailed(I[15], 18, 12, "version");
this[S$.nameSpace] = nameSpace;
this[S$.parent] = parent;
this[S$.properties] = properties;
this[S$.functions] = functions;
this[S$.events] = events;
this[S$.constants] = constants;
this[S$.version] = version;
;
}).prototype = TemplateDescriber.TemplateDescriber.prototype;
dart.addTypeTests(TemplateDescriber.TemplateDescriber);
dart.addTypeCaches(TemplateDescriber.TemplateDescriber);
dart.setLibraryUri(TemplateDescriber.TemplateDescriber, I[15]);
dart.setFieldSignature(TemplateDescriber.TemplateDescriber, () => ({
__proto__: dart.getFields(TemplateDescriber.TemplateDescriber.__proto__),
properties: dart.finalFieldType(dart.nullable(core.List$(TemplateDescriber.Prop))),
events: dart.finalFieldType(dart.nullable(core.List$(TemplateDescriber.Evt))),
functions: dart.finalFieldType(dart.nullable(core.List$(TemplateDescriber.Func))),
constants: dart.finalFieldType(dart.nullable(core.List$(TemplateDescriber.Const))),
nameSpace: dart.finalFieldType(core.String),
version: dart.finalFieldType(core.int),
parent: dart.finalFieldType(dart.nullable(core.Type))
}));
TemplateDescriber.Prop = class Prop extends core.Object {
get name() {
return this[S$.name$1];
}
set name(value) {
super.name = value;
}
get type() {
return this[S$.type];
}
set type(value) {
super.type = value;
}
get readAnnotation() {
return this[S$.readAnnotation];
}
set readAnnotation(value) {
super.readAnnotation = value;
}
get writeAnnotation() {
return this[S$.writeAnnotation];
}
set writeAnnotation(value) {
super.writeAnnotation = value;
}
static ['_#new#tearOff'](name, type, readAnnotation = null, writeAnnotation = null) {
if (name == null) dart.nullFailed(I[15], 59, 19, "name");
if (type == null) dart.nullFailed(I[15], 59, 30, "type");
return new TemplateDescriber.Prop.new(name, type, readAnnotation, writeAnnotation);
}
};
(TemplateDescriber.Prop.new = function(name, type, readAnnotation = null, writeAnnotation = null) {
if (name == null) dart.nullFailed(I[15], 59, 19, "name");
if (type == null) dart.nullFailed(I[15], 59, 30, "type");
this[S$.name$1] = name;
this[S$.type] = type;
this[S$.readAnnotation] = readAnnotation;
this[S$.writeAnnotation] = writeAnnotation;
;
}).prototype = TemplateDescriber.Prop.prototype;
dart.addTypeTests(TemplateDescriber.Prop);
dart.addTypeCaches(TemplateDescriber.Prop);
dart.setLibraryUri(TemplateDescriber.Prop, I[15]);
dart.setFieldSignature(TemplateDescriber.Prop, () => ({
__proto__: dart.getFields(TemplateDescriber.Prop.__proto__),
name: dart.finalFieldType(core.String),
type: dart.finalFieldType(core.Type),
readAnnotation: dart.finalFieldType(dart.nullable(core.String)),
writeAnnotation: dart.finalFieldType(dart.nullable(core.String))
}));
TemplateDescriber.Evt = class Evt extends core.Object {
get name() {
return this[S$.name$2];
}
set name(value) {
super.name = value;
}
get listenable() {
return this[S$.listenable$1];
}
set listenable(value) {
super.listenable = value;
}
get type() {
return this[S$.type$1];
}
set type(value) {
super.type = value;
}
get annotation() {
return this[S$.annotation];
}
set annotation(value) {
super.annotation = value;
}
static ['_#new#tearOff'](name, type, listenable = false, annotation = null) {
if (name == null) dart.nullFailed(I[15], 69, 18, "name");
if (type == null) dart.nullFailed(I[15], 69, 29, "type");
if (listenable == null) dart.nullFailed(I[15], 69, 41, "listenable");
return new TemplateDescriber.Evt.new(name, type, listenable, annotation);
}
};
(TemplateDescriber.Evt.new = function(name, type, listenable = false, annotation = null) {
if (name == null) dart.nullFailed(I[15], 69, 18, "name");
if (type == null) dart.nullFailed(I[15], 69, 29, "type");
if (listenable == null) dart.nullFailed(I[15], 69, 41, "listenable");
this[S$.name$2] = name;
this[S$.type$1] = type;
this[S$.listenable$1] = listenable;
this[S$.annotation] = annotation;
;
}).prototype = TemplateDescriber.Evt.prototype;
dart.addTypeTests(TemplateDescriber.Evt);
dart.addTypeCaches(TemplateDescriber.Evt);
dart.setLibraryUri(TemplateDescriber.Evt, I[15]);
dart.setFieldSignature(TemplateDescriber.Evt, () => ({
__proto__: dart.getFields(TemplateDescriber.Evt.__proto__),
name: dart.finalFieldType(core.String),
listenable: dart.finalFieldType(core.bool),
type: dart.finalFieldType(core.Type),
annotation: dart.finalFieldType(dart.nullable(core.String))
}));
TemplateDescriber.Const = class Const extends core.Object {
get name() {
return this[S$.name$3];
}
set name(value) {
super.name = value;
}
get type() {
return this[S$.type$2];
}
set type(value) {
super.type = value;
}
get annotation() {
return this[S$.annotation$1];
}
set annotation(value) {
super.annotation = value;
}
get value() {
return this[S$.value];
}
set value(value) {
super.value = value;
}
static ['_#new#tearOff'](name, type, value, annotation = null) {
if (name == null) dart.nullFailed(I[15], 79, 20, "name");
if (type == null) dart.nullFailed(I[15], 79, 31, "type");
return new TemplateDescriber.Const.new(name, type, value, annotation);
}
};
(TemplateDescriber.Const.new = function(name, type, value, annotation = null) {
if (name == null) dart.nullFailed(I[15], 79, 20, "name");
if (type == null) dart.nullFailed(I[15], 79, 31, "type");
this[S$.name$3] = name;
this[S$.type$2] = type;
this[S$.value] = value;
this[S$.annotation$1] = annotation;
;
}).prototype = TemplateDescriber.Const.prototype;
dart.addTypeTests(TemplateDescriber.Const);
dart.addTypeCaches(TemplateDescriber.Const);
dart.setLibraryUri(TemplateDescriber.Const, I[15]);
dart.setFieldSignature(TemplateDescriber.Const, () => ({
__proto__: dart.getFields(TemplateDescriber.Const.__proto__),
name: dart.finalFieldType(core.String),
type: dart.finalFieldType(core.Type),
annotation: dart.finalFieldType(dart.nullable(core.String)),
value: dart.finalFieldType(dart.dynamic)
}));
TemplateDescriber.Func = class Func extends core.Object {
get name() {
return this[S$.name$4];
}
set name(value) {
super.name = value;
}
get returnType() {
return this[S$.returnType$1];
}
set returnType(value) {
super.returnType = value;
}
get argsType() {
return this[S$.argsType];
}
set argsType(value) {
super.argsType = value;
}
get annotation() {
return this[S$.annotation$2];
}
set annotation(value) {
super.annotation = value;
}
static ['_#new#tearOff'](name, returnType, argsType, annotation = null) {
if (name == null) dart.nullFailed(I[15], 89, 19, "name");
if (returnType == null) dart.nullFailed(I[15], 89, 30, "returnType");
if (argsType == null) dart.nullFailed(I[15], 89, 47, "argsType");
return new TemplateDescriber.Func.new(name, returnType, argsType, annotation);
}
};
(TemplateDescriber.Func.new = function(name, returnType, argsType, annotation = null) {
if (name == null) dart.nullFailed(I[15], 89, 19, "name");
if (returnType == null) dart.nullFailed(I[15], 89, 30, "returnType");
if (argsType == null) dart.nullFailed(I[15], 89, 47, "argsType");
this[S$.name$4] = name;
this[S$.returnType$1] = returnType;
this[S$.argsType] = argsType;
this[S$.annotation$2] = annotation;
;
}).prototype = TemplateDescriber.Func.prototype;
dart.addTypeTests(TemplateDescriber.Func);
dart.addTypeCaches(TemplateDescriber.Func);
dart.setLibraryUri(TemplateDescriber.Func, I[15]);
dart.setFieldSignature(TemplateDescriber.Func, () => ({
__proto__: dart.getFields(TemplateDescriber.Func.__proto__),
name: dart.finalFieldType(core.String),
returnType: dart.finalFieldType(core.Type),
argsType: dart.finalFieldType(core.List$(TemplateDescriber.Arg)),
annotation: dart.finalFieldType(dart.nullable(core.String))
}));
TemplateDescriber.Arg = class Arg extends core.Object {
get name() {
return this[S$.name$5];
}
set name(value) {
super.name = value;
}
get type() {
return this[S$.type$3];
}
set type(value) {
super.type = value;
}
get optional() {
return this[S$.optional];
}
set optional(value) {
super.optional = value;
}
static ['_#new#tearOff'](name, type, optional) {
if (name == null) dart.nullFailed(I[15], 98, 18, "name");
if (type == null) dart.nullFailed(I[15], 98, 29, "type");
if (optional == null) dart.nullFailed(I[15], 98, 40, "optional");
return new TemplateDescriber.Arg.new(name, type, optional);
}
};
(TemplateDescriber.Arg.new = function(name, type, optional) {
if (name == null) dart.nullFailed(I[15], 98, 18, "name");
if (type == null) dart.nullFailed(I[15], 98, 29, "type");
if (optional == null) dart.nullFailed(I[15], 98, 40, "optional");
this[S$.name$5] = name;
this[S$.type$3] = type;
this[S$.optional] = optional;
;
}).prototype = TemplateDescriber.Arg.prototype;
dart.addTypeTests(TemplateDescriber.Arg);
dart.addTypeCaches(TemplateDescriber.Arg);
dart.setLibraryUri(TemplateDescriber.Arg, I[15]);
dart.setFieldSignature(TemplateDescriber.Arg, () => ({
__proto__: dart.getFields(TemplateDescriber.Arg.__proto__),
name: dart.finalFieldType(core.String),
type: dart.finalFieldType(core.Type),
optional: dart.finalFieldType(core.bool)
}));
TemplateGenerator.TemplateGenerator = class TemplateGenerator$ extends core.Object {
static generateRecord(template, templates) {
if (template == null) dart.nullFailed(I[16], 16, 20, "template");
if (templates == null) dart.nullFailed(I[16], 16, 49, "templates");
let className = template.className[S$.$split](".")[S$.$last];
let rt = new core.StringBuffer.new();
let parentName = null;
if (template.parentId != null) {
parentName = TemplateGenerator.TemplateGenerator._translateClassName(templates[S$.$singleWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 24, 25, "x");
return dart.equals(x.classId, template.parentId) && x.type == TemplateType.TemplateType.Record;
}, T$.TypeTemplateTobool())).className);
rt.writeln("class " + dart.str(className) + " extends " + dart.str(parentName) + " {");
} else {
rt.writeln("class " + dart.str(className) + " extends IRecord {");
}
template.properties[S$.$forEach](dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 33, 34, "p");
if (dart.test(p.inherited)) return;
let ptTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, p.valueType, templates);
rt.writeln(dart.str(ptTypeName) + "? " + dart.str(p.name) + ";");
rt.writeln();
}, T$.PropertyTemplateTovoid()));
rt.writeln();
rt.writeln("@override");
rt.writeln("void deserialize(Map<String, dynamic> value) {");
template.properties[S$.$forEach](dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 45, 34, "p");
rt.writeln(dart.str(p.name) + " = value['" + dart.str(p.name) + "'];");
}, T$.PropertyTemplateTovoid()));
rt.writeln("}");
rt.writeln();
rt.writeln("@override");
rt.writeln("Map<String, dynamic> serialize() {");
rt.writeln("var rt = Map<String, dynamic>();");
template.properties[S$.$forEach](dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 56, 34, "p");
rt.writeln("rt['" + dart.str(p.name) + "'] = " + dart.str(p.name) + ";");
}, T$.PropertyTemplateTovoid()));
rt.writeln("return rt;");
rt.writeln("}");
let descProps = template.properties[S$.$map](core.String, dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 65, 15, "p");
let ptTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, p.valueType, templates);
return "Prop('" + dart.str(p.name) + "', getTypeOf<" + dart.str(ptTypeName) + ">(), " + dart.str(TemplateGenerator.TemplateGenerator._escape(p.readExpansion)) + ", " + dart.str(TemplateGenerator.TemplateGenerator._escape(p.writeExpansion)) + ")";
}, T$.PropertyTemplateToString()))[S$.$join](", ");
if (parentName != null)
rt.writeln("@override\n TemplateDescriber get template => TemplateDescriber('" + dart.str(template.className) + "', parent: " + dart.str(parentName) + ", properties: [" + dart.str(descProps) + "]);");
else
rt.writeln("@override\n TemplateDescriber get template => TemplateDescriber('" + dart.str(template.className) + "', properties: [" + dart.str(descProps) + "]);");
rt.writeln("\r\n}");
return rt.toString();
}
static _translateClassName(className) {
if (className == null) dart.nullFailed(I[16], 82, 44, "className");
let cls = className[S$.$split](".");
let nameSpace = cls[S$.$take](dart.notNull(cls[S$.$length]) - 1)[S$.$join]("_")[S$.$toLowerCase]();
return nameSpace + "." + dart.str(cls[S$.$last]);
}
static getTypeName(forTemplate, representationType, templates) {
if (forTemplate == null) dart.nullFailed(I[16], 88, 42, "forTemplate");
if (representationType == null) dart.nullFailed(I[16], 89, 26, "representationType");
if (templates == null) dart.nullFailed(I[16], 89, 65, "templates");
let name = null;
if (representationType.identifier === 69) {
if (dart.equals(representationType.guid, forTemplate.classId))
name = forTemplate.className[S$.$split](".")[S$.$last];
else
name = TemplateGenerator.TemplateGenerator._translateClassName(templates[S$.$singleWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 98, 27, "x");
return dart.equals(x.classId, representationType.guid) && (x.type == TemplateType.TemplateType.Resource || x.type == TemplateType.TemplateType.Wrapper);
}, T$.TypeTemplateTobool())).className);
} else if (representationType.identifier === 70) {
if (dart.equals(representationType.guid, forTemplate.classId))
name = forTemplate.className[S$.$split](".")[S$.$last];
else
name = TemplateGenerator.TemplateGenerator._translateClassName(templates[S$.$singleWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 109, 27, "x");
return dart.equals(x.classId, representationType.guid) && x.type == TemplateType.TemplateType.Record;
}, T$.TypeTemplateTobool())).className);
} else if (representationType.identifier === 24)
if (dart.equals(representationType.guid, forTemplate.classId))
name = forTemplate.className[S$.$split](".")[S$.$last];
else
name = TemplateGenerator.TemplateGenerator._translateClassName(templates[S$.$singleWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 119, 25, "x");
return dart.equals(x.classId, representationType.guid) && x.type == TemplateType.TemplateType.Enum;
}, T$.TypeTemplateTobool())).className);
else if (representationType.identifier === 72)
name = "List<" + dart.notNull(TemplateGenerator.TemplateGenerator.getTypeName(forTemplate, dart.nullCheck(representationType.subTypes)[S$.$_get](0), templates)) + ">";
else if (representationType.identifier === 81)
name = "Map<" + dart.notNull(TemplateGenerator.TemplateGenerator.getTypeName(forTemplate, dart.nullCheck(representationType.subTypes)[S$.$_get](0), templates)) + "," + dart.notNull(TemplateGenerator.TemplateGenerator.getTypeName(forTemplate, dart.nullCheck(representationType.subTypes)[S$.$_get](1), templates)) + ">";
else if (representationType.identifier === 80 || representationType.identifier === 88 || representationType.identifier === 96 || representationType.identifier === 104 || representationType.identifier === 112 || representationType.identifier === 120)
name = "Tuple";
else {
switch (representationType.identifier) {
case 1:
{
name = "dynamic";
break;
}
case 2:
{
name = "bool";
break;
}
case 5:
{
name = "String";
break;
}
case 14:
{
name = "DateTime";
break;
}
case 17:
{
name = "double";
break;
}
case 10:
{
name = "double";
break;
}
case 13:
{
name = "double";
break;
}
case 6:
{
name = "int";
break;
}
case 8:
{
name = "int";
break;
}
case 11:
{
name = "int";
break;
}
case 4:
{
name = "int";
break;
}
case 18:
{
name = "String";
break;
}
case 23:
{
name = "Map";
break;
}
case 7:
{
name = "int";
break;
}
case 9:
{
name = "int";
break;
}
case 12:
{
name = "int";
break;
}
case 3:
{
name = "int";
break;
}
case 22:
{
name = "List";
break;
}
case 20:
{
name = "IResource";
break;
}
case 21:
{
name = "IRecord";
break;
}
default:
{
name = "dynamic";
}
}
}
return dart.test(representationType.nullable) ? dart.notNull(name) + "?" : name;
}
static isNullOrEmpty(v) {
return v == null || dart.equals(v, "");
}
static getTemplate(url, opts) {
if (url == null) dart.nullFailed(I[16], 220, 12, "url");
let dir = opts && 'dir' in opts ? opts.dir : null;
let username = opts && 'username' in opts ? opts.username : null;
let password = opts && 'password' in opts ? opts.password : null;
let getx = opts && 'getx' in opts ? opts.getx : false;
if (getx == null) dart.nullFailed(I[16], 224, 10, "getx");
let namedArgs = opts && 'namedArgs' in opts ? opts.namedArgs : false;
if (namedArgs == null) dart.nullFailed(I[16], 225, 10, "namedArgs");
return async.async(core.String, function* getTemplate() {
let t11;
try {
if (!dart.test(TemplateGenerator.TemplateGenerator._urlRegex.hasMatch(url))) dart.throw(core.Exception.new("Invalid IIP URL"));
let path = TemplateGenerator.TemplateGenerator._urlRegex.allMatches(url)[S$.$first];
let con = (yield Warehouse.Warehouse.get(DistributedConnection.DistributedConnection, dart.notNull(dart.nullCast(path._get(1), core.String)) + "://" + dart.notNull(dart.nullCast(path._get(2), core.String)), username != null ? new (T$.IdentityMapOfString$dynamic()).from(["username", username, "password", (t11 = password, t11 == null ? "" : t11)]) : null));
if (con == null) dart.throw(core.Exception.new("Can't connect to server"));
if (dart.test(TemplateGenerator.TemplateGenerator.isNullOrEmpty(dir))) dir = dart.nullCast(path._get(2), core.String)[S$.$replaceAll](":", "_");
let templates = (yield con.getLinkTemplates(dart.nullCast(path._get(3), core.String)));
Warehouse.Warehouse.remove(con);
let dstDir = io.Directory.new("lib/" + dart.str(dir));
if (!dart.test(dstDir.existsSync())) dstDir.createSync({recursive: true});
let makeImports = dart.fn(skipTemplate => {
let imports = new core.StringBuffer.new();
imports.writeln("import 'dart:async';");
imports.writeln("import 'package:esiur/esiur.dart';");
if (dart.test(getx)) {
imports.writeln("import 'package:get/get.dart';");
}
templates[S$.$forEach](dart.fn(tmp => {
if (tmp == null) dart.nullFailed(I[16], 260, 28, "tmp");
if (!dart.equals(tmp, skipTemplate)) {
let cls = tmp.className[S$.$split](".");
let nameSpace = cls[S$.$take](dart.notNull(cls[S$.$length]) - 1)[S$.$join]("_")[S$.$toLowerCase]();
imports.writeln("import '" + dart.str(tmp.className) + ".g.dart' as " + nameSpace + ";");
}
}, T$.TypeTemplateTovoid()));
imports.writeln();
return imports.toString();
}, T$.TypeTemplateNToString());
templates[S$.$forEach](dart.fn(tmp => {
if (tmp == null) dart.nullFailed(I[16], 273, 26, "tmp");
core.print("Generating `" + dart.str(tmp.className) + "`.");
let filePath = dart.str(dstDir.path) + "/" + dart.str(tmp.className) + ".g.dart";
let f = io.File.new(filePath);
let source = "";
if (tmp.type == TemplateType.TemplateType.Resource) {
source = dart.notNull(makeImports(tmp)) + dart.notNull(TemplateGenerator.TemplateGenerator.generateClass(tmp, templates, {getx: getx, namedArgs: namedArgs}));
} else if (tmp.type == TemplateType.TemplateType.Record) {
source = dart.notNull(makeImports(tmp)) + dart.notNull(TemplateGenerator.TemplateGenerator.generateRecord(tmp, templates));
} else if (tmp.type == TemplateType.TemplateType.Enum) {
source = dart.notNull(makeImports(tmp)) + dart.notNull(TemplateGenerator.TemplateGenerator.generateEnum(tmp, templates));
}
f.writeAsStringSync(source);
}, T$.TypeTemplateTovoid()));
let defineCreators = templates[S$.$map](T$.StringN(), dart.fn(tmp => {
if (tmp == null) dart.nullFailed(I[16], 296, 43, "tmp");
let className = TemplateGenerator.TemplateGenerator._translateClassName(tmp.className);
if (tmp.type == TemplateType.TemplateType.Resource || tmp.type == TemplateType.TemplateType.Wrapper) {
return "Warehouse.defineType<" + dart.str(className) + ">(() => " + dart.str(className) + "(), RepresentationType(RepresentationTypeIdentifier.TypedResource, false, Guid.fromString('" + dart.str(dart.toString(tmp.classId)) + "')));\r\n";
} else if (tmp.type == TemplateType.TemplateType.Record) {
return "Warehouse.defineType<" + dart.str(className) + ">(() => " + dart.str(className) + "(), RepresentationType(RepresentationTypeIdentifier.TypedRecord, false, Guid.fromString('" + dart.str(dart.toString(tmp.classId)) + "')));\r\n";
} else if (tmp.type == TemplateType.TemplateType.Enum) {
return "Warehouse.defineType<" + dart.str(className) + ">(() => " + dart.str(className) + "(), RepresentationType(RepresentationTypeIdentifier.Enum, false, Guid.fromString('" + dart.str(dart.toString(tmp.classId)) + "')));\r\n";
}
}, T$.TypeTemplateToStringN()))[S$.$join]("\r\n");
let putTemplates = templates[S$.$map](core.String, dart.fn(tmp => {
if (tmp == null) dart.nullFailed(I[16], 309, 41, "tmp");
let className = TemplateGenerator.TemplateGenerator._translateClassName(tmp.className);
return "Warehouse.putTemplate(TypeTemplate.fromType(" + dart.str(className) + "));";
}, T$.TypeTemplateToString()))[S$.$join]("\r\n");
let typesFile = dart.notNull(makeImports(null)) + ("\r\n void init_" + dart.str(dir) + "(){ " + dart.str(defineCreators) + " \r\n " + dart.str(putTemplates) + "}");
let f = io.File.new(dart.str(dstDir.path) + "/init.g.dart");
f.writeAsStringSync(typesFile);
io.Process.run("dart", T$.JSArrayOfString().of(["format", dstDir.path]));
return dstDir.path;
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
dart.throw(ex);
} else
throw e;
}
});
}
static _escape(str) {
if (str == null)
return "null";
else
return "r'" + dart.str(str) + "'";
}
static generateEnum(template, templates) {
if (template == null) dart.nullFailed(I[16], 336, 20, "template");
if (templates == null) dart.nullFailed(I[16], 336, 49, "templates");
let className = template.className[S$.$split](".")[S$.$last];
let rt = new core.StringBuffer.new();
rt.writeln("class " + dart.str(className) + " extends IEnum {");
template.constants[S$.$forEach](dart.fn(c => {
if (c == null) dart.nullFailed(I[16], 342, 33, "c");
rt.writeln("static " + dart.str(className) + " " + dart.str(c.name) + " = " + dart.str(className) + "(" + dart.str(c.index) + ", " + dart.str(c.value) + ", '" + dart.str(c.name) + "');");
rt.writeln();
}, T$.ConstantTemplateTovoid()));
rt.writeln();
rt.writeln(dart.str(className) + "([int index = 0, value, String name = '']) : super(index, value, name);");
let descConsts = template.constants[S$.$map](core.String, dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 354, 46, "p");
let ctTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, p.valueType, templates);
return "Const('" + dart.str(p.name) + "', getTypeOf<" + dart.str(ctTypeName) + ">(), " + dart.str(p.value) + ", " + dart.str(TemplateGenerator.TemplateGenerator._escape(p.expansion)) + ")";
}, T$.ConstantTemplateToString()))[S$.$join](", ");
rt.writeln("@override\n TemplateDescriber get template => TemplateDescriber('" + dart.str(template.className) + "', constants: [" + dart.str(descConsts) + "]);");
rt.writeln("\r\n}");
return rt.toString();
}
static generateClass(template, templates, opts) {
if (template == null) dart.nullFailed(I[16], 368, 18, "template");
if (templates == null) dart.nullFailed(I[16], 369, 24, "templates");
let getx = opts && 'getx' in opts ? opts.getx : false;
if (getx == null) dart.nullFailed(I[16], 370, 10, "getx");
let namedArgs = opts && 'namedArgs' in opts ? opts.namedArgs : false;
if (namedArgs == null) dart.nullFailed(I[16], 371, 10, "namedArgs");
let className = template.className[S$.$split](".")[S$.$last];
let parentName = null;
let rt = new core.StringBuffer.new();
if (template.parentId != null) {
parentName = TemplateGenerator.TemplateGenerator._translateClassName(templates[S$.$singleWhere](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 381, 25, "x");
return dart.equals(x.classId, template.parentId) && (x.type == TemplateType.TemplateType.Resource || x.type == TemplateType.TemplateType.Wrapper);
}, T$.TypeTemplateTobool())).className);
rt.writeln("class " + dart.str(className) + " extends " + dart.str(parentName) + " {");
} else {
rt.writeln("class " + dart.str(className) + " extends DistributedResource {");
}
rt.writeln(dart.str(className) + "() {");
template.events[S$.$where](dart.fn(e => {
if (e == null) dart.nullFailed(I[16], 393, 28, "e");
return !dart.test(e.inherited);
}, T$.EventTemplateTobool()))[S$.$forEach](dart.fn(e => {
if (e == null) dart.nullFailed(I[16], 393, 57, "e");
rt.writeln("on('" + dart.str(e.name) + "', (x) => _" + dart.str(e.name) + "Controller.add(x));");
}, T$.EventTemplateTovoid()));
if (dart.test(getx)) {
rt.writeln("ob = obs;");
rt.writeln("_sub = properyModified.listen((_) => ob.trigger(this));");
}
rt.writeln("}");
if (dart.test(getx)) {
rt.writeln("\nlate final Rx<" + dart.str(className) + "> ob;");
rt.writeln("late final StreamSubscription? _sub;\n");
rt.writeln("@override\n void destroy() {\n _sub?.cancel();\n\n super.destroy();\n }");
}
template.functions[S$.$where](dart.fn(f => {
if (f == null) dart.nullFailed(I[16], 416, 31, "f");
return !dart.test(f.inherited);
}, T$.FunctionTemplateTobool()))[S$.$forEach](dart.fn(f => {
if (f == null) dart.nullFailed(I[16], 416, 60, "f");
let rtTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, f.returnType, templates);
let positionalArgs = f.arguments[S$.$where](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 418, 47, "x");
return !dart.test(x.optional);
}, T$.ArgumentTemplateTobool()));
let optionalArgs = f.arguments[S$.$where](dart.fn(x => {
if (x == null) dart.nullFailed(I[16], 419, 45, "x");
return x.optional;
}, T$.ArgumentTemplateTobool()));
rt.write("AsyncReply<" + dart.str(rtTypeName) + "> " + dart.str(f.name) + "(");
if (dart.notNull(positionalArgs[S$.$length]) > 0) rt.write(dart.str(positionalArgs[S$.$map](core.String, dart.fn(a => {
if (a == null) dart.nullFailed(I[16], 425, 36, "a");
return dart.notNull(TemplateGenerator.TemplateGenerator.getTypeName(template, a.type, templates)) + " " + dart.notNull(a.name);
}, T$.ArgumentTemplateToString()))[S$.$join](",")));
if (dart.notNull(optionalArgs[S$.$length]) > 0) {
if (dart.notNull(positionalArgs[S$.$length]) > 0) rt.write(",");
rt.write("[" + dart.str(optionalArgs[S$.$map](core.String, dart.fn(a => {
if (a == null) dart.nullFailed(I[16], 430, 35, "a");
return dart.notNull(TemplateGenerator.TemplateGenerator.getTypeName(template, a.type.toNullable(), templates)) + " " + dart.notNull(a.name);
}, T$.ArgumentTemplateToString()))[S$.$join](",")) + "]");
}
rt.writeln(") {");
rt.writeln("var args = <UInt8, dynamic>{" + dart.str(positionalArgs[S$.$map](core.String, dart.fn(e => {
if (e == null) dart.nullFailed(I[16], 436, 62, "e");
return "UInt8(" + dart.toString(e.index) + ") :" + dart.notNull(e.name);
}, T$.ArgumentTemplateToString()))[S$.$join](",")) + "};");
optionalArgs[S$.$forEach](dart.fn(a => {
if (a == null) dart.nullFailed(I[16], 438, 29, "a");
rt.writeln("if (" + dart.str(a.name) + " != null) args[UInt8(" + dart.str(a.index) + ")] = " + dart.str(a.name) + ";");
}, T$.ArgumentTemplateTovoid()));
rt.writeln("var rt = AsyncReply<" + dart.str(rtTypeName) + ">();");
rt.writeln("internal_invoke(" + dart.str(f.index) + ", args)");
rt.writeln(".then<dynamic>((x) => rt.trigger(x))");
rt.writeln(".error((x) => rt.triggerError(x))");
rt.writeln(".chunk((x) => rt.triggerChunk(x));");
rt.writeln("return rt; }");
}, T$.FunctionTemplateTovoid()));
template.properties[S$.$where](dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 451, 32, "p");
return !dart.test(p.inherited);
}, T$.PropertyTemplateTobool()))[S$.$forEach](dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 451, 61, "p");
let ptTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, p.valueType, templates);
rt.writeln(dart.str(ptTypeName) + " get " + dart.str(p.name) + " { return get(" + dart.str(p.index) + "); }");
rt.writeln("set " + dart.str(p.name) + "(" + dart.str(ptTypeName) + " value) { set(" + dart.str(p.index) + ", value); }");
}, T$.PropertyTemplateTovoid()));
template.events[S$.$where](dart.fn(e => {
if (e == null) dart.nullFailed(I[16], 458, 28, "e");
return !dart.test(e.inherited);
}, T$.EventTemplateTobool()))[S$.$forEach](dart.fn(e => {
if (e == null) dart.nullFailed(I[16], 458, 57, "e");
let etTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, e.argumentType, templates);
rt.writeln("final _" + dart.str(e.name) + "Controller = StreamController<" + dart.str(etTypeName) + ">();");
rt.writeln("Stream<" + dart.str(etTypeName) + "> get " + dart.str(e.name) + " { ");
rt.writeln("return _" + dart.str(e.name) + "Controller.stream;");
rt.writeln("}");
}, T$.EventTemplateTovoid()));
let descProps = template.properties[S$.$map](core.String, dart.fn(p => {
if (p == null) dart.nullFailed(I[16], 470, 15, "p");
let ptTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, p.valueType, templates);
return "Prop('" + dart.str(p.name) + "', getTypeOf<" + dart.str(ptTypeName) + ">(), " + dart.str(TemplateGenerator.TemplateGenerator._escape(p.readExpansion)) + ", " + dart.str(TemplateGenerator.TemplateGenerator._escape(p.writeExpansion)) + ")";
}, T$.PropertyTemplateToString()))[S$.$join](", ");
let descFuncs = template.functions[S$.$map](core.String, dart.fn(f => {
if (f == null) dart.nullFailed(I[16], 476, 15, "f");
let ftTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, f.returnType, templates);
let args = f.arguments[S$.$map](core.String, dart.fn(a => {
if (a == null) dart.nullFailed(I[16], 479, 35, "a");
let atTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, a.type, templates);
return "Arg('" + dart.str(a.name) + "', getTypeOf<" + dart.str(atTypeName) + ">(), " + dart.str(a.optional) + ")";
}, T$.ArgumentTemplateToString()))[S$.$join](", ");
return "Func('" + dart.str(f.name) + "', getTypeOf<" + dart.str(ftTypeName) + ">(), [" + dart.str(args) + "], " + dart.str(TemplateGenerator.TemplateGenerator._escape(f.expansion)) + ")";
}, T$.FunctionTemplateToString()))[S$.$join](", ");
let descEvents = template.events[S$.$map](core.String, dart.fn(e => {
if (e == null) dart.nullFailed(I[16], 489, 15, "e");
let etTypeName = TemplateGenerator.TemplateGenerator.getTypeName(template, e.argumentType, templates);
return "Evt('" + dart.str(e.name) + "', getTypeOf<" + dart.str(etTypeName) + ">(), " + dart.str(e.listenable) + ", " + dart.str(TemplateGenerator.TemplateGenerator._escape(e.expansion)) + ")";
}, T$.EventTemplateToString()))[S$.$join](", ");
if (parentName != null)
rt.writeln("TemplateDescriber get template => TemplateDescriber('" + dart.str(template.className) + "', parent: " + dart.str(parentName) + ", properties: [" + dart.str(descProps) + "], functions: [" + dart.str(descFuncs) + "], events: [" + dart.str(descEvents) + "]);");
else
rt.writeln("TemplateDescriber get template => TemplateDescriber('" + dart.str(template.className) + "', properties: [" + dart.str(descProps) + "], functions: [" + dart.str(descFuncs) + "], events: [" + dart.str(descEvents) + "]);");
rt.writeln("\r\n}");
return rt.toString();
}
static ['_#new#tearOff']() {
return new TemplateGenerator.TemplateGenerator.new();
}
};
(TemplateGenerator.TemplateGenerator.new = function() {
;
}).prototype = TemplateGenerator.TemplateGenerator.prototype;
dart.addTypeTests(TemplateGenerator.TemplateGenerator);
dart.addTypeCaches(TemplateGenerator.TemplateGenerator);
dart.setStaticMethodSignature(TemplateGenerator.TemplateGenerator, () => ['generateRecord', '_translateClassName', 'getTypeName', 'isNullOrEmpty', 'getTemplate', '_escape', 'generateEnum', 'generateClass']);
dart.setLibraryUri(TemplateGenerator.TemplateGenerator, I[16]);
dart.setStaticFieldSignature(TemplateGenerator.TemplateGenerator, () => ['_urlRegex']);
dart.defineLazy(TemplateGenerator.TemplateGenerator, {
/*TemplateGenerator.TemplateGenerator._urlRegex*/get _urlRegex() {
return core.RegExp.new("^(?:([^\\s|:]*):\\/\\/([^\\/]*)\\/?(.*))");
}
}, false);
ProgressType.ProgressType = class ProgressType extends core._Enum {
toString() {
return "ProgressType." + dart.str(this[S$._name$1]);
}
};
(ProgressType.ProgressType.new = function(index, name) {
if (index == null) dart.nullFailed(I[17], 1, 10, "index");
if (name == null) dart.nullFailed(I[17], 1, 10, "name");
ProgressType.ProgressType.__proto__.new.call(this, index, name);
;
}).prototype = ProgressType.ProgressType.prototype;
dart.addTypeTests(ProgressType.ProgressType);
dart.addTypeCaches(ProgressType.ProgressType);
dart.setLibraryUri(ProgressType.ProgressType, I[17]);
dart.setStaticFieldSignature(ProgressType.ProgressType, () => ['values', 'Execution', 'Network']);
dart.defineExtensionMethods(ProgressType.ProgressType, ['toString']);
ProgressType.ProgressType.Execution = C[13] || CT.C13;
ProgressType.ProgressType.Network = C[14] || CT.C14;
ProgressType.ProgressType.values = C[15] || CT.C15;
const _is_AsyncReply_default = Symbol('_is_AsyncReply_default');
AsyncReply$.AsyncReply$ = dart.generic(T => {
var __t$TTodynamic = () => (__t$TTodynamic = dart.constFn(dart.fnType(dart.dynamic, [T])))();
var __t$JSArrayOfTTodynamic = () => (__t$JSArrayOfTTodynamic = dart.constFn(_interceptors.JSArray$(__t$TTodynamic())))();
var __t$_EmptyStreamOfT = () => (__t$_EmptyStreamOfT = dart.constFn(async._EmptyStream$(T)))();
var __t$TN = () => (__t$TN = dart.constFn(dart.nullable(T)))();
var __t$FutureOrOfTN = () => (__t$FutureOrOfTN = dart.constFn(async.FutureOr$(__t$TN())))();
var __t$VoidToFutureOrOfTN = () => (__t$VoidToFutureOrOfTN = dart.constFn(dart.fnType(__t$FutureOrOfTN(), [])))();
var __t$VoidToNFutureOrOfTN = () => (__t$VoidToNFutureOrOfTN = dart.constFn(dart.nullable(__t$VoidToFutureOrOfTN())))();
var __t$FnTovoid = () => (__t$FnTovoid = dart.constFn(dart.fnType(dart.void, [__t$TTodynamic()])))();
class AsyncReply extends core.Object {
get [S$._result]() {
let t12;
return dart.test(this[S$.__AsyncReply__result_isSet]) ? (t12 = this[S$.__AsyncReply__result], t12) : dart.throw(new _internal.LateError.fieldNI("_result"));
}
set [S$._result](t12) {
this[S$.__AsyncReply__result_isSet] = true;
this[S$.__AsyncReply__result] = t12;
}
get ready() {
return this[S$._resultReady];
}
set ready(value) {
if (value == null) dart.nullFailed(I[19], 48, 18, "value");
this[S$._resultReady] = value;
}
get result() {
return this[S$._result];
}
setResultReady(val) {
if (val == null) dart.nullFailed(I[19], 56, 23, "val");
this[S$._resultReady] = val;
}
next(callback) {
if (callback == null) dart.nullFailed(I[19], 60, 34, "callback");
this.then(dart.dynamic, callback);
return this;
}
then(R, onValue, opts) {
if (onValue == null) dart.nullFailed(I[19], 65, 37, "onValue");
let onError = opts && 'onError' in opts ? opts.onError : null;
this[S$._callbacks][S$.$add](onValue);
if (onError != null) {
this[S$._errorCallbacks][S$.$add](onError);
}
if (dart.test(this[S$._resultReady])) onValue(T.as(this.result));
return new (AsyncReply$.AsyncReply$(R)).new();
}
whenComplete(action) {
if (action == null) dart.nullFailed(I[19], 81, 39, "action");
return this;
}
asStream() {
return new (__t$_EmptyStreamOfT()).new();
}
catchError(onError, opts) {
if (onError == null) dart.nullFailed(I[19], 93, 37, "onError");
let test = opts && 'test' in opts ? opts.test : null;
this[S$._errorCallbacks][S$.$add](onError);
if (this[S$._exception] != null) {
if (T$.dynamicAnddynamicTodynamic().is(onError)) {
onError(this[S$._exception], null);
} else if (T$.dynamicTodynamic().is(onError)) {
onError(this[S$._exception]);
} else if (T$.VoidTodynamic().is(onError)) {
onError();
} else if (T$.ObjectAndStackTraceTodynamic().is(onError)) {
onError(core.Object.as(this[S$._exception]), core.StackTrace.current);
}
}
return this;
}
timeout(timeLimit, opts) {
if (timeLimit == null) dart.nullFailed(I[19], 113, 34, "timeLimit");
let onTimeout = opts && 'onTimeout' in opts ? opts.onTimeout : null;
__t$VoidToNFutureOrOfTN().as(onTimeout);
return this;
}
error(callback) {
if (callback == null) dart.nullFailed(I[19], 117, 23, "callback");
this[S$._errorCallbacks][S$.$add](callback);
if (this[S$._exception] != null) callback(dart.nullCast(this[S$._exception], AsyncException.AsyncException));
return this;
}
progress(callback) {
if (callback == null) dart.nullFailed(I[19], 124, 59, "callback");
this[S$._progressCallbacks][S$.$add](callback);
return this;
}
chunk(callback) {
if (callback == null) dart.nullFailed(I[19], 129, 35, "callback");
this[S$._chunkCallbacks][S$.$add](callback);
return this;
}
trigger(result) {
T.as(result);
if (dart.test(this[S$._resultReady])) return this;
this[S$._result] = result;
this[S$._resultReady] = true;
this[S$._callbacks][S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[19], 140, 25, "x");
x(result);
}, __t$FnTovoid()));
return this;
}
triggerError(exception) {
if (exception == null) dart.nullFailed(I[19], 147, 40, "exception");
if (dart.test(this[S$._resultReady])) return this;
if (AsyncException.AsyncException.is(exception))
this[S$._exception] = exception;
else
this[S$._exception] = AsyncException.AsyncException.toAsyncException(exception);
if (this[S$._errorCallbacks][S$.$length] === 0)
dart.throw(dart.nullCast(this[S$._exception], AsyncException.AsyncException));
else
this[S$._errorCallbacks][S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[19], 161, 32, "x");
if (T$.dynamicAnddynamicTodynamic().is(x)) {
x(this[S$._exception], null);
} else if (T$.dynamicTodynamic().is(x)) {
x(this[S$._exception]);
} else if (T$.VoidTodynamic().is(x)) {
x();
} else if (T$.ObjectAndStackTraceTodynamic().is(x)) {
x(core.Object.as(this[S$._exception]), core.StackTrace.current);
}
}, T$.FunctionTovoid()));
return this;
}
triggerProgress(type, value, max) {
if (type == null) dart.nullFailed(I[19], 178, 46, "type");
if (value == null) dart.nullFailed(I[19], 178, 56, "value");
if (max == null) dart.nullFailed(I[19], 178, 67, "max");
this[S$._progressCallbacks][S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[19], 179, 33, "x");
x(type, value, max);
}, T$.FnTovoid$1()));
return this;
}
triggerChunk(value) {
T.as(value);
this[S$._chunkCallbacks][S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[19], 187, 30, "x");
x(value);
}, __t$FnTovoid()));
return this;
}
static ['_#ready#tearOff'](T, result) {
return new (AsyncReply$.AsyncReply$(T)).ready(result);
}
static ['_#new#tearOff'](T) {
return new (AsyncReply$.AsyncReply$(T)).new();
}
}
(AsyncReply.ready = function(result) {
this[S$._callbacks] = __t$JSArrayOfTTodynamic().of([]);
this[S$.__AsyncReply__result] = null;
this[S$.__AsyncReply__result_isSet] = false;
this[S$._errorCallbacks] = T$.JSArrayOfFunction().of([]);
this[S$._progressCallbacks] = T$.JSArrayOfProgressTypeAndintAndintTodynamic().of([]);
this[S$._chunkCallbacks] = __t$JSArrayOfTTodynamic().of([]);
this[S$._resultReady] = false;
this[S$._exception] = null;
this[S$._resultReady] = true;
this[S$._result] = result;
}).prototype = AsyncReply.prototype;
(AsyncReply.new = function() {
this[S$._callbacks] = __t$JSArrayOfTTodynamic().of([]);
this[S$.__AsyncReply__result] = null;
this[S$.__AsyncReply__result_isSet] = false;
this[S$._errorCallbacks] = T$.JSArrayOfFunction().of([]);
this[S$._progressCallbacks] = T$.JSArrayOfProgressTypeAndintAndintTodynamic().of([]);
this[S$._chunkCallbacks] = __t$JSArrayOfTTodynamic().of([]);
this[S$._resultReady] = false;
this[S$._exception] = null;
}).prototype = AsyncReply.prototype;
AsyncReply.prototype[dart.isFuture] = true;
dart.addTypeTests(AsyncReply);
AsyncReply.prototype[_is_AsyncReply_default] = true;
dart.addTypeCaches(AsyncReply);
AsyncReply[dart.implements] = () => [async.Future$(T)];
dart.setMethodSignature(AsyncReply, () => ({
__proto__: dart.getMethods(AsyncReply.__proto__),
setResultReady: dart.fnType(dart.dynamic, [core.bool]),
next: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.fnType(dart.dynamic, [T])]),
then: dart.gFnType(R => [AsyncReply$.AsyncReply$(R), [dart.fnType(async.FutureOr$(R), [T])], {onError: dart.nullable(core.Function)}, {}], R => [dart.nullable(core.Object)]),
whenComplete: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.fnType(dart.dynamic, [])]),
asStream: dart.fnType(async.Stream$(T), []),
catchError: dart.fnType(AsyncReply$.AsyncReply$(T), [core.Function], {test: dart.nullable(dart.fnType(core.bool, [core.Object]))}, {}),
timeout: dart.fnType(AsyncReply$.AsyncReply$(T), [core.Duration], {onTimeout: dart.nullable(core.Object)}, {}),
error: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.fnType(dart.dynamic, [AsyncException.AsyncException])]),
progress: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.fnType(dart.dynamic, [ProgressType.ProgressType, core.int, core.int])]),
chunk: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.fnType(dart.dynamic, [T])]),
trigger: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.nullable(core.Object)]),
triggerError: dart.fnType(AsyncReply$.AsyncReply$(T), [core.Exception]),
triggerProgress: dart.fnType(AsyncReply$.AsyncReply$(T), [ProgressType.ProgressType, core.int, core.int]),
triggerChunk: dart.fnType(AsyncReply$.AsyncReply$(T), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(AsyncReply, () => ({
__proto__: dart.getGetters(AsyncReply.__proto__),
[S$._result]: T,
ready: core.bool,
result: dart.nullable(T)
}));
dart.setSetterSignature(AsyncReply, () => ({
__proto__: dart.getSetters(AsyncReply.__proto__),
[S$._result]: T,
ready: core.bool
}));
dart.setLibraryUri(AsyncReply, I[19]);
dart.setFieldSignature(AsyncReply, () => ({
__proto__: dart.getFields(AsyncReply.__proto__),
[S$._callbacks]: dart.fieldType(core.List$(dart.fnType(dart.dynamic, [T]))),
[S$.__AsyncReply__result]: dart.fieldType(dart.nullable(T)),
[S$.__AsyncReply__result_isSet]: dart.fieldType(core.bool),
[S$._errorCallbacks]: dart.fieldType(core.List$(core.Function)),
[S$._progressCallbacks]: dart.fieldType(core.List$(dart.fnType(dart.dynamic, [ProgressType.ProgressType, core.int, core.int]))),
[S$._chunkCallbacks]: dart.fieldType(core.List$(dart.fnType(dart.dynamic, [T]))),
[S$._resultReady]: dart.fieldType(core.bool),
[S$._exception]: dart.fieldType(dart.nullable(AsyncException.AsyncException))
}));
return AsyncReply;
});
AsyncReply$.AsyncReply = AsyncReply$.AsyncReply$();
dart.addTypeTests(AsyncReply$.AsyncReply, _is_AsyncReply_default);
const _is_AsyncBag_default = Symbol('_is_AsyncBag_default');
AsyncBag$.AsyncBag$ = dart.generic(T => {
var __t$AsyncReplyOfT = () => (__t$AsyncReplyOfT = dart.constFn(AsyncReply$.AsyncReply$(T)))();
var __t$JSArrayOfAsyncReplyOfT = () => (__t$JSArrayOfAsyncReplyOfT = dart.constFn(_interceptors.JSArray$(__t$AsyncReplyOfT())))();
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$JSArrayOfT = () => (__t$JSArrayOfT = dart.constFn(_interceptors.JSArray$(T)))();
var __t$TN = () => (__t$TN = dart.constFn(dart.nullable(T)))();
var __t$ListOfTN = () => (__t$ListOfTN = dart.constFn(core.List$(__t$TN())))();
var __t$TToNull = () => (__t$TToNull = dart.constFn(dart.fnType(core.Null, [T])))();
var __t$AsyncBagOfT = () => (__t$AsyncBagOfT = dart.constFn(AsyncBag$.AsyncBag$(T)))();
var __t$AsyncReplyOfTTovoid = () => (__t$AsyncReplyOfTTovoid = dart.constFn(dart.fnType(dart.void, [__t$AsyncReplyOfT()])))();
class AsyncBag extends AsyncReply$.AsyncReply$(core.List$(T)) {
get arrayType() {
return this[S$.arrayType];
}
set arrayType(value) {
this[S$.arrayType] = value;
}
seal() {
let t12;
if (dart.test(this[S$._sealedBag])) return;
this[S$._sealedBag] = true;
if (this[S$._replies][S$.$length] === 0) {
if (this.arrayType != null) {
let ar = Warehouse.Warehouse.createArray(dart.dynamic, dart.nullCast(this.arrayType, core.Type));
this.trigger(__t$ListOfT().as(ar));
} else {
this.trigger(__t$JSArrayOfT().of([]));
}
}
let results = __t$ListOfTN().filled(this[S$._replies][S$.$length], null);
for (let i = 0; i < dart.notNull(this[S$._replies][S$.$length]); i = i + 1) {
let k = this[S$._replies][S$.$_get](i);
let index = i;
t12 = k;
(() => {
t12.then(core.Null, dart.fn(r => {
results[S$.$_set](index, r);
this[S$._count] = dart.notNull(this[S$._count]) + 1;
if (this[S$._count] == this[S$._replies][S$.$length]) {
if (this.arrayType != null) {
let ar = Warehouse.Warehouse.createArray(dart.dynamic, dart.nullCast(this.arrayType, core.Type));
results[S$.$forEach](T$.dynamicTovoid().as(dart.bind(ar, S$.$add)));
this.trigger(__t$ListOfT().as(ar));
} else {
this.trigger(results[S$.$cast](T));
}
}
}, __t$TToNull()));
t12.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[18], 46, 18, "ex");
this.triggerError(ex);
}, T$.AsyncExceptionToNull()));
return t12;
})();
}
}
add(reply) {
__t$AsyncReplyOfT().as(reply);
if (reply == null) dart.nullFailed(I[18], 52, 26, "reply");
if (!dart.test(this[S$._sealedBag])) {
this[S$._replies][S$.$add](reply);
}
}
addBag(bag) {
__t$AsyncBagOfT().as(bag);
if (bag == null) dart.nullFailed(I[18], 59, 27, "bag");
bag[S$._replies][S$.$forEach](dart.fn(r => {
if (r == null) dart.nullFailed(I[18], 60, 27, "r");
this.add(r);
}, __t$AsyncReplyOfTTovoid()));
}
static ['_#new#tearOff'](T) {
return new (AsyncBag$.AsyncBag$(T)).new();
}
}
(AsyncBag.new = function() {
this[S$._replies] = __t$JSArrayOfAsyncReplyOfT().of([]);
this[S$._count] = 0;
this[S$._sealedBag] = false;
this[S$.arrayType] = null;
AsyncBag.__proto__.new.call(this);
}).prototype = AsyncBag.prototype;
dart.addTypeTests(AsyncBag);
AsyncBag.prototype[_is_AsyncBag_default] = true;
dart.addTypeCaches(AsyncBag);
dart.setMethodSignature(AsyncBag, () => ({
__proto__: dart.getMethods(AsyncBag.__proto__),
seal: dart.fnType(dart.dynamic, []),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addBag: dart.fnType(dart.void, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(AsyncBag, I[18]);
dart.setFieldSignature(AsyncBag, () => ({
__proto__: dart.getFields(AsyncBag.__proto__),
[S$._replies]: dart.fieldType(core.List$(AsyncReply$.AsyncReply$(T))),
[S$._count]: dart.fieldType(core.int),
[S$._sealedBag]: dart.fieldType(core.bool),
arrayType: dart.fieldType(dart.nullable(core.Type))
}));
return AsyncBag;
});
AsyncBag$.AsyncBag = AsyncBag$.AsyncBag$();
dart.addTypeTests(AsyncBag$.AsyncBag, _is_AsyncBag_default);
AsyncException.AsyncException = class AsyncException$ extends core.Object {
get type() {
return this[S$.type$4];
}
set type(value) {
super.type = value;
}
get code() {
return this[S$.code];
}
set code(value) {
super.code = value;
}
get message() {
return this[S$.message];
}
set message(value) {
super.message = value;
}
static ['_#new#tearOff'](type, code, message) {
if (type == null) dart.nullFailed(I[20], 9, 23, "type");
if (code == null) dart.nullFailed(I[20], 9, 34, "code");
return new AsyncException.AsyncException.new(type, code, message);
}
static toAsyncException(ex) {
if (ex == null) dart.nullFailed(I[20], 11, 52, "ex");
return AsyncException.AsyncException.is(ex) ? ex : new AsyncException.AsyncException.new(ErrorType.ErrorType.Exception, 0, dart.toString(ex));
}
errMsg() {
let t13, t13$;
if (this.type == ErrorType.ErrorType.Management)
return dart.notNull(dart.toString(ExceptionCode.ExceptionCode.values[S$.$elementAt](this.code))) + ": " + dart.notNull((t13 = this.message, t13 == null ? "" : t13));
else
return dart.toString(this.code) + ": " + dart.notNull((t13$ = this.message, t13$ == null ? "" : t13$));
}
toString() {
return this.errMsg();
}
};
(AsyncException.AsyncException.new = function(type, code, message) {
if (type == null) dart.nullFailed(I[20], 9, 23, "type");
if (code == null) dart.nullFailed(I[20], 9, 34, "code");
this[S$.type$4] = type;
this[S$.code] = code;
this[S$.message] = message;
}).prototype = AsyncException.AsyncException.prototype;
dart.addTypeTests(AsyncException.AsyncException);
dart.addTypeCaches(AsyncException.AsyncException);
AsyncException.AsyncException[dart.implements] = () => [core.Exception];
dart.setMethodSignature(AsyncException.AsyncException, () => ({
__proto__: dart.getMethods(AsyncException.AsyncException.__proto__),
errMsg: dart.fnType(core.String, [])
}));
dart.setStaticMethodSignature(AsyncException.AsyncException, () => ['toAsyncException']);
dart.setLibraryUri(AsyncException.AsyncException, I[20]);
dart.setFieldSignature(AsyncException.AsyncException, () => ({
__proto__: dart.getFields(AsyncException.AsyncException.__proto__),
type: dart.finalFieldType(ErrorType.ErrorType),
code: dart.finalFieldType(core.int),
message: dart.finalFieldType(dart.nullable(core.String))
}));
dart.defineExtensionMethods(AsyncException.AsyncException, ['toString']);
const _is_AsyncQueue_default = Symbol('_is_AsyncQueue_default');
AsyncQueue$.AsyncQueue$ = dart.generic(T => {
var __t$TN = () => (__t$TN = dart.constFn(dart.nullable(T)))();
var __t$AsyncReplyOfTN = () => (__t$AsyncReplyOfTN = dart.constFn(AsyncReply$.AsyncReply$(__t$TN())))();
var __t$JSArrayOfAsyncReplyOfTN = () => (__t$JSArrayOfAsyncReplyOfTN = dart.constFn(_interceptors.JSArray$(__t$AsyncReplyOfTN())))();
var __t$AsyncReplyOfT = () => (__t$AsyncReplyOfT = dart.constFn(AsyncReply$.AsyncReply$(T)))();
class AsyncQueue extends AsyncReply$.AsyncReply$(dart.nullable(T)) {
add(reply) {
__t$AsyncReplyOfT().as(reply);
if (reply == null) dart.nullFailed(I[21], 10, 21, "reply");
this[S$._list][S$.$add](reply);
super.setResultReady(false);
reply.then(dart.void, dart.bind(this, 'processQueue'));
}
remove(reply) {
__t$AsyncReplyOfT().as(reply);
if (reply == null) dart.nullFailed(I[21], 20, 24, "reply");
this[S$._list][S$.$remove](reply);
this.processQueue(null);
}
processQueue(o) {
__t$TN().as(o);
for (let i = 0; i < dart.notNull(this[S$._list][S$.$length]); i = i + 1)
if (dart.test(this[S$._list][S$.$_get](i).ready)) {
super.trigger(this[S$._list][S$.$_get](i).result);
super.ready = false;
this[S$._list][S$.$removeAt](i);
i = i - 1;
} else
break;
super.setResultReady(this[S$._list][S$.$length] === 0);
}
static ['_#new#tearOff'](T) {
return new (AsyncQueue$.AsyncQueue$(T)).new();
}
}
(AsyncQueue.new = function() {
this[S$._list] = __t$JSArrayOfAsyncReplyOfTN().of([]);
AsyncQueue.__proto__.new.call(this);
}).prototype = AsyncQueue.prototype;
dart.addTypeTests(AsyncQueue);
AsyncQueue.prototype[_is_AsyncQueue_default] = true;
dart.addTypeCaches(AsyncQueue);
dart.setMethodSignature(AsyncQueue, () => ({
__proto__: dart.getMethods(AsyncQueue.__proto__),
add: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
remove: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
processQueue: dart.fnType(dart.void, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(AsyncQueue, I[21]);
dart.setFieldSignature(AsyncQueue, () => ({
__proto__: dart.getFields(AsyncQueue.__proto__),
[S$._list]: dart.fieldType(core.List$(AsyncReply$.AsyncReply$(dart.nullable(T))))
}));
return AsyncQueue;
});
AsyncQueue$.AsyncQueue = AsyncQueue$.AsyncQueue$();
dart.addTypeTests(AsyncQueue$.AsyncQueue, _is_AsyncQueue_default);
ErrorType.ErrorType = class ErrorType extends core._Enum {
toString() {
return "ErrorType." + dart.str(this[S$._name$1]);
}
};
(ErrorType.ErrorType.new = function(index, name) {
if (index == null) dart.nullFailed(I[22], 1, 6, "index");
if (name == null) dart.nullFailed(I[22], 1, 6, "name");
ErrorType.ErrorType.__proto__.new.call(this, index, name);
;
}).prototype = ErrorType.ErrorType.prototype;
dart.addTypeTests(ErrorType.ErrorType);
dart.addTypeCaches(ErrorType.ErrorType);
dart.setLibraryUri(ErrorType.ErrorType, I[22]);
dart.setStaticFieldSignature(ErrorType.ErrorType, () => ['values', 'Management', 'Exception']);
dart.defineExtensionMethods(ErrorType.ErrorType, ['toString']);
ErrorType.ErrorType.Management = C[16] || CT.C16;
ErrorType.ErrorType.Exception = C[17] || CT.C17;
ErrorType.ErrorType.values = C[18] || CT.C18;
ExceptionCode.ExceptionCode = class ExceptionCode extends core._Enum {
toString() {
return "ExceptionCode." + dart.str(this[S$._name$1]);
}
};
(ExceptionCode.ExceptionCode.new = function(index, name) {
if (index == null) dart.nullFailed(I[23], 2, 6, "index");
if (name == null) dart.nullFailed(I[23], 2, 6, "name");
ExceptionCode.ExceptionCode.__proto__.new.call(this, index, name);
;
}).prototype = ExceptionCode.ExceptionCode.prototype;
dart.addTypeTests(ExceptionCode.ExceptionCode);
dart.addTypeCaches(ExceptionCode.ExceptionCode);
dart.setLibraryUri(ExceptionCode.ExceptionCode, I[23]);
dart.setStaticFieldSignature(ExceptionCode.ExceptionCode, () => ['values', 'HostNotReachable', 'AccessDenied', 'UserOrTokenNotFound', 'ChallengeFailed', 'ResourceNotFound', 'AttachDenied', 'InvalidMethod', 'InvokeDenied', 'CreateDenied', 'AddParentDenied', 'AddChildDenied', 'ViewAttributeDenied', 'UpdateAttributeDenied', 'StoreNotFound', 'ParentNotFound', 'ChildNotFound', 'ResourceIsNotStore', 'DeleteDenied', 'DeleteFailed', 'UpdateAttributeFailed', 'GetAttributesFailed', 'ClearAttributesFailed', 'TemplateNotFound', 'RenameDenied', 'ClassNotFound', 'MethodNotFound', 'PropertyNotFound', 'SetPropertyDenied', 'ReadOnlyProperty', 'GeneralFailure', 'AddToStoreFailed', 'NotAttached', 'AlreadyListened', 'AlreadyUnlistened', 'NotListenable']);
dart.defineExtensionMethods(ExceptionCode.ExceptionCode, ['toString']);
ExceptionCode.ExceptionCode.HostNotReachable = C[19] || CT.C19;
ExceptionCode.ExceptionCode.AccessDenied = C[20] || CT.C20;
ExceptionCode.ExceptionCode.UserOrTokenNotFound = C[21] || CT.C21;
ExceptionCode.ExceptionCode.ChallengeFailed = C[22] || CT.C22;
ExceptionCode.ExceptionCode.ResourceNotFound = C[23] || CT.C23;
ExceptionCode.ExceptionCode.AttachDenied = C[24] || CT.C24;
ExceptionCode.ExceptionCode.InvalidMethod = C[25] || CT.C25;
ExceptionCode.ExceptionCode.InvokeDenied = C[26] || CT.C26;
ExceptionCode.ExceptionCode.CreateDenied = C[27] || CT.C27;
ExceptionCode.ExceptionCode.AddParentDenied = C[28] || CT.C28;
ExceptionCode.ExceptionCode.AddChildDenied = C[29] || CT.C29;
ExceptionCode.ExceptionCode.ViewAttributeDenied = C[30] || CT.C30;
ExceptionCode.ExceptionCode.UpdateAttributeDenied = C[31] || CT.C31;
ExceptionCode.ExceptionCode.StoreNotFound = C[32] || CT.C32;
ExceptionCode.ExceptionCode.ParentNotFound = C[33] || CT.C33;
ExceptionCode.ExceptionCode.ChildNotFound = C[34] || CT.C34;
ExceptionCode.ExceptionCode.ResourceIsNotStore = C[35] || CT.C35;
ExceptionCode.ExceptionCode.DeleteDenied = C[36] || CT.C36;
ExceptionCode.ExceptionCode.DeleteFailed = C[37] || CT.C37;
ExceptionCode.ExceptionCode.UpdateAttributeFailed = C[38] || CT.C38;
ExceptionCode.ExceptionCode.GetAttributesFailed = C[39] || CT.C39;
ExceptionCode.ExceptionCode.ClearAttributesFailed = C[40] || CT.C40;
ExceptionCode.ExceptionCode.TemplateNotFound = C[41] || CT.C41;
ExceptionCode.ExceptionCode.RenameDenied = C[42] || CT.C42;
ExceptionCode.ExceptionCode.ClassNotFound = C[43] || CT.C43;
ExceptionCode.ExceptionCode.MethodNotFound = C[44] || CT.C44;
ExceptionCode.ExceptionCode.PropertyNotFound = C[45] || CT.C45;
ExceptionCode.ExceptionCode.SetPropertyDenied = C[46] || CT.C46;
ExceptionCode.ExceptionCode.ReadOnlyProperty = C[47] || CT.C47;
ExceptionCode.ExceptionCode.GeneralFailure = C[48] || CT.C48;
ExceptionCode.ExceptionCode.AddToStoreFailed = C[49] || CT.C49;
ExceptionCode.ExceptionCode.NotAttached = C[50] || CT.C50;
ExceptionCode.ExceptionCode.AlreadyListened = C[51] || CT.C51;
ExceptionCode.ExceptionCode.AlreadyUnlistened = C[52] || CT.C52;
ExceptionCode.ExceptionCode.NotListenable = C[53] || CT.C53;
ExceptionCode.ExceptionCode.values = C[54] || CT.C54;
Tuple.Tuple = class Tuple$ extends core.Object {
get [S$._list$2]() {
return this[S$._list$1];
}
set [S$._list$2](value) {
super[S$._list$2] = value;
}
static ['_#new#tearOff'](_list) {
if (_list == null) dart.nullFailed(I[24], 3, 20, "_list");
return new Tuple.Tuple.new(_list);
}
_get(index) {
if (index == null) dart.nullFailed(I[24], 4, 19, "index");
return this[S$._list$2][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[24], 5, 25, "index");
this[S$._list$2][S$.$_set](index, value);
return value$;
}
get length() {
return this[S$._list$2][S$.$length];
}
};
(Tuple.Tuple.new = function(_list) {
if (_list == null) dart.nullFailed(I[24], 3, 20, "_list");
this[S$._list$1] = _list;
;
}).prototype = Tuple.Tuple.prototype;
dart.addTypeTests(Tuple.Tuple);
dart.addTypeCaches(Tuple.Tuple);
dart.setMethodSignature(Tuple.Tuple, () => ({
__proto__: dart.getMethods(Tuple.Tuple.__proto__),
_get: dart.fnType(dart.dynamic, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.dynamic])
}));
dart.setGetterSignature(Tuple.Tuple, () => ({
__proto__: dart.getGetters(Tuple.Tuple.__proto__),
length: core.int
}));
dart.setLibraryUri(Tuple.Tuple, I[24]);
dart.setFieldSignature(Tuple.Tuple, () => ({
__proto__: dart.getFields(Tuple.Tuple.__proto__),
[S$._list$2]: dart.finalFieldType(core.List)
}));
const _is_Tuple2_default = Symbol('_is_Tuple2_default');
Tuple.Tuple2$ = dart.generic((T1, T2) => {
class Tuple2 extends Tuple.Tuple {
static ['_#new#tearOff'](T1, T2, v1, v2) {
return new (Tuple.Tuple2$(T1, T2)).new(v1, v2);
}
get value1() {
return T1.as(this[S$._list$2][S$.$_get](0));
}
get value2() {
return T2.as(this[S$._list$2][S$.$_get](1));
}
}
(Tuple2.new = function(v1, v2) {
Tuple2.__proto__.new.call(this, [v1, v2]);
;
}).prototype = Tuple2.prototype;
dart.addTypeTests(Tuple2);
Tuple2.prototype[_is_Tuple2_default] = true;
dart.addTypeCaches(Tuple2);
dart.setGetterSignature(Tuple2, () => ({
__proto__: dart.getGetters(Tuple2.__proto__),
value1: T1,
value2: T2
}));
dart.setLibraryUri(Tuple2, I[24]);
return Tuple2;
});
Tuple.Tuple2 = Tuple.Tuple2$();
dart.addTypeTests(Tuple.Tuple2, _is_Tuple2_default);
const _is_Tuple3_default = Symbol('_is_Tuple3_default');
Tuple.Tuple3$ = dart.generic((T1, T2, T3) => {
class Tuple3 extends Tuple.Tuple {
static ['_#new#tearOff'](T1, T2, T3, v1, v2, v3) {
return new (Tuple.Tuple3$(T1, T2, T3)).new(v1, v2, v3);
}
get value1() {
return T1.as(this[S$._list$2][S$.$_get](0));
}
get value2() {
return T2.as(this[S$._list$2][S$.$_get](1));
}
get value3() {
return T3.as(this[S$._list$2][S$.$_get](2));
}
}
(Tuple3.new = function(v1, v2, v3) {
Tuple3.__proto__.new.call(this, [v1, v2, v3]);
;
}).prototype = Tuple3.prototype;
dart.addTypeTests(Tuple3);
Tuple3.prototype[_is_Tuple3_default] = true;
dart.addTypeCaches(Tuple3);
dart.setGetterSignature(Tuple3, () => ({
__proto__: dart.getGetters(Tuple3.__proto__),
value1: T1,
value2: T2,
value3: T3
}));
dart.setLibraryUri(Tuple3, I[24]);
return Tuple3;
});
Tuple.Tuple3 = Tuple.Tuple3$();
dart.addTypeTests(Tuple.Tuple3, _is_Tuple3_default);
const _is_Tuple4_default = Symbol('_is_Tuple4_default');
Tuple.Tuple4$ = dart.generic((T1, T2, T3, T4) => {
class Tuple4 extends Tuple.Tuple {
static ['_#new#tearOff'](T1, T2, T3, T4, v1, v2, v3, v4) {
return new (Tuple.Tuple4$(T1, T2, T3, T4)).new(v1, v2, v3, v4);
}
get value1() {
return T1.as(this[S$._list$2][S$.$_get](0));
}
get value2() {
return T2.as(this[S$._list$2][S$.$_get](1));
}
get value3() {
return T3.as(this[S$._list$2][S$.$_get](2));
}
get value4() {
return T4.as(this[S$._list$2][S$.$_get](3));
}
}
(Tuple4.new = function(v1, v2, v3, v4) {
Tuple4.__proto__.new.call(this, [v1, v2, v3, v4]);
;
}).prototype = Tuple4.prototype;
dart.addTypeTests(Tuple4);
Tuple4.prototype[_is_Tuple4_default] = true;
dart.addTypeCaches(Tuple4);
dart.setGetterSignature(Tuple4, () => ({
__proto__: dart.getGetters(Tuple4.__proto__),
value1: T1,
value2: T2,
value3: T3,
value4: T4
}));
dart.setLibraryUri(Tuple4, I[24]);
return Tuple4;
});
Tuple.Tuple4 = Tuple.Tuple4$();
dart.addTypeTests(Tuple.Tuple4, _is_Tuple4_default);
const _is_Tuple5_default = Symbol('_is_Tuple5_default');
Tuple.Tuple5$ = dart.generic((T1, T2, T3, T4, T5) => {
class Tuple5 extends Tuple.Tuple {
static ['_#new#tearOff'](T1, T2, T3, T4, T5, v1, v2, v3, v4, v5) {
return new (Tuple.Tuple5$(T1, T2, T3, T4, T5)).new(v1, v2, v3, v4, v5);
}
get value1() {
return T1.as(this[S$._list$2][S$.$_get](0));
}
get value2() {
return T2.as(this[S$._list$2][S$.$_get](1));
}
get value3() {
return T3.as(this[S$._list$2][S$.$_get](2));
}
get value4() {
return T4.as(this[S$._list$2][S$.$_get](3));
}
get value5() {
return T5.as(this[S$._list$2][S$.$_get](4));
}
}
(Tuple5.new = function(v1, v2, v3, v4, v5) {
Tuple5.__proto__.new.call(this, [v1, v2, v3, v4, v5]);
;
}).prototype = Tuple5.prototype;
dart.addTypeTests(Tuple5);
Tuple5.prototype[_is_Tuple5_default] = true;
dart.addTypeCaches(Tuple5);
dart.setGetterSignature(Tuple5, () => ({
__proto__: dart.getGetters(Tuple5.__proto__),
value1: T1,
value2: T2,
value3: T3,
value4: T4,
value5: T5
}));
dart.setLibraryUri(Tuple5, I[24]);
return Tuple5;
});
Tuple.Tuple5 = Tuple.Tuple5$();
dart.addTypeTests(Tuple.Tuple5, _is_Tuple5_default);
const _is_Tuple6_default = Symbol('_is_Tuple6_default');
Tuple.Tuple6$ = dart.generic((T1, T2, T3, T4, T5, T6) => {
class Tuple6 extends Tuple.Tuple {
static ['_#new#tearOff'](T1, T2, T3, T4, T5, T6, v1, v2, v3, v4, v5, v6) {
return new (Tuple.Tuple6$(T1, T2, T3, T4, T5, T6)).new(v1, v2, v3, v4, v5, v6);
}
get value1() {
return T1.as(this[S$._list$2][S$.$_get](0));
}
get value2() {
return T2.as(this[S$._list$2][S$.$_get](1));
}
get value3() {
return T3.as(this[S$._list$2][S$.$_get](2));
}
get value4() {
return T4.as(this[S$._list$2][S$.$_get](3));
}
get value5() {
return T5.as(this[S$._list$2][S$.$_get](4));
}
get value6() {
return T6.as(this[S$._list$2][S$.$_get](5));
}
}
(Tuple6.new = function(v1, v2, v3, v4, v5, v6) {
Tuple6.__proto__.new.call(this, [v1, v2, v3, v4, v5, v6]);
;
}).prototype = Tuple6.prototype;
dart.addTypeTests(Tuple6);
Tuple6.prototype[_is_Tuple6_default] = true;
dart.addTypeCaches(Tuple6);
dart.setGetterSignature(Tuple6, () => ({
__proto__: dart.getGetters(Tuple6.__proto__),
value1: T1,
value2: T2,
value3: T3,
value4: T4,
value5: T5,
value6: T6
}));
dart.setLibraryUri(Tuple6, I[24]);
return Tuple6;
});
Tuple.Tuple6 = Tuple.Tuple6$();
dart.addTypeTests(Tuple.Tuple6, _is_Tuple6_default);
const _is_Tuple7_default = Symbol('_is_Tuple7_default');
Tuple.Tuple7$ = dart.generic((T1, T2, T3, T4, T5, T6, T7) => {
class Tuple7 extends Tuple.Tuple {
static ['_#new#tearOff'](T1, T2, T3, T4, T5, T6, T7, v1, v2, v3, v4, v5, v6, v7) {
return new (Tuple.Tuple7$(T1, T2, T3, T4, T5, T6, T7)).new(v1, v2, v3, v4, v5, v6, v7);
}
get value1() {
return T1.as(this[S$._list$2][S$.$_get](0));
}
get value2() {
return T2.as(this[S$._list$2][S$.$_get](1));
}
get value3() {
return T3.as(this[S$._list$2][S$.$_get](2));
}
get value4() {
return T4.as(this[S$._list$2][S$.$_get](3));
}
get value5() {
return T5.as(this[S$._list$2][S$.$_get](4));
}
get value6() {
return T6.as(this[S$._list$2][S$.$_get](5));
}
get value7() {
return T7.as(this[S$._list$2][S$.$_get](6));
}
}
(Tuple7.new = function(v1, v2, v3, v4, v5, v6, v7) {
Tuple7.__proto__.new.call(this, [v1, v2, v3, v4, v5, v6, v5]);
;
}).prototype = Tuple7.prototype;
dart.addTypeTests(Tuple7);
Tuple7.prototype[_is_Tuple7_default] = true;
dart.addTypeCaches(Tuple7);
dart.setGetterSignature(Tuple7, () => ({
__proto__: dart.getGetters(Tuple7.__proto__),
value1: T1,
value2: T2,
value3: T3,
value4: T4,
value5: T5,
value6: T6,
value7: T7
}));
dart.setLibraryUri(Tuple7, I[24]);
return Tuple7;
});
Tuple.Tuple7 = Tuple.Tuple7$();
dart.addTypeTests(Tuple.Tuple7, _is_Tuple7_default);
const _is_AutoList_default = Symbol('_is_AutoList_default');
AutoList$.AutoList$ = dart.generic((T, ST) => {
var __t$JSArrayOfT = () => (__t$JSArrayOfT = dart.constFn(_interceptors.JSArray$(T)))();
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
var __t$AutoListOfT$ST = () => (__t$AutoListOfT$ST = dart.constFn(AutoList$.AutoList$(T, ST)))();
const IDestructible_IterableMixin$36 = class IDestructible_IterableMixin extends IDestructible.IDestructible {};
(IDestructible_IterableMixin$36.new = function() {
IDestructible_IterableMixin$36.__proto__.new.call(this);
}).prototype = IDestructible_IterableMixin$36.prototype;
dart.applyMixin(IDestructible_IterableMixin$36, collection.IterableMixin$(T));
class AutoList extends IDestructible_IterableMixin$36 {
get [S$._removableList]() {
let t13;
return dart.test(this[S$.__AutoList__removableList_isSet]) ? (t13 = this[S$.__AutoList__removableList], t13) : dart.throw(new _internal.LateError.fieldNI("_removableList"));
}
set [S$._removableList](t13) {
if (t13 == null) dart.nullFailed(I[25], 12, 13, "null");
this[S$.__AutoList__removableList_isSet] = true;
this[S$.__AutoList__removableList] = t13;
}
sort(compare) {
this[S$._list$3][S$.$sort](compare);
}
get iterator() {
return this[S$._list$3][S$.$iterator];
}
static ['_#new#tearOff'](T, ST, state = null, values = null) {
return new (AutoList$.AutoList$(T, ST)).new(state, values);
}
_get(index) {
if (index == null) dart.nullFailed(I[25], 44, 21, "index");
return this[S$._list$3][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[25], 48, 25, "index");
T.as(value);
let oldValue = this[S$._list$3][S$.$_get](index);
if (dart.test(this[S$._removableList])) {
if (oldValue != null) IDestructible.IDestructible.as(oldValue).off("destroy", dart.bind(this, S$._itemDestroyed));
if (value != null) IEventHandler.IEventHandler.as(value).on("destroy", dart.bind(this, S$._itemDestroyed));
}
this[S$._list$3][S$.$_set](index, value);
this.emitArgs("modified", [this[S$._state], index, oldValue, value]);
return value$;
}
add(value) {
T.as(value);
if (dart.test(this[S$._removableList])) if (value != null) IDestructible.IDestructible.as(value).on("destroy", dart.bind(this, S$._itemDestroyed));
this[S$._list$3][S$.$add](value);
this.emitArgs("add", [this[S$._state], value]);
}
addRange(values) {
__t$ListOfT().as(values);
if (values == null) dart.nullFailed(I[25], 79, 25, "values");
values[S$.$forEach](dart.fn(x => this.add(x), __t$TTovoid()));
}
[S$._itemDestroyed](sender) {
T.as(sender);
this.remove(sender);
}
clear() {
if (dart.test(this[S$._removableList])) this[S$._list$3][S$.$forEach](dart.fn(x => IDestructible.IDestructible.as(x).off("destroy", dart.bind(this, S$._itemDestroyed)), __t$TTovoid()));
this[S$._list$3][S$.$clear]();
this.emitArgs("cleared", [this[S$._state]]);
}
remove(value) {
T.as(value);
if (!dart.test(this[S$._list$3][S$.$contains](value))) return;
if (dart.test(this[S$._removableList])) if (value != null) IDestructible.IDestructible.as(value).off("destroy", dart.bind(this, S$._itemDestroyed));
this[S$._list$3][S$.$remove](value);
this.emitArgs("removed", [this[S$._state], value]);
}
get count() {
return this[S$._list$3][S$.$length];
}
get length() {
return this[S$._list$3][S$.$length];
}
containsAny(values) {
if (__t$ListOfT().is(values)) {
for (let v of values) {
if (dart.test(this[S$._list$3][S$.$contains](v))) return true;
}
} else if (__t$AutoListOfT$ST().is(values)) {
for (let v of values[S$._list$3]) {
if (dart.test(this[S$._list$3][S$.$contains](v))) return true;
}
}
return false;
}
destroy() {
this.clear();
}
}
(AutoList.new = function(state = null, values = null) {
this[S$._list$3] = __t$JSArrayOfT().of([]);
this[S$._state] = null;
this[S$.__AutoList__removableList] = null;
this[S$.__AutoList__removableList_isSet] = false;
AutoList.__proto__.new.call(this);
this[S$._state] = state;
this[S$._removableList] = Codec.Codec.implementsInterface(T, IDestructible.IDestructible);
if (values != null) this.addRange(values);
this.register("modified");
this.register("added");
this.register("removed");
this.register("cleared");
}).prototype = AutoList.prototype;
dart.addTypeTests(AutoList);
AutoList.prototype[_is_AutoList_default] = true;
dart.addTypeCaches(AutoList);
dart.setMethodSignature(AutoList, () => ({
__proto__: dart.getMethods(AutoList.__proto__),
sort: dart.fnType(dart.void, [dart.nullable(dart.fnType(core.int, [T, T]))]),
_get: dart.fnType(T, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addRange: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$._itemDestroyed]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
remove: dart.fnType(dart.void, [dart.nullable(core.Object)]),
containsAny: dart.fnType(core.bool, [dart.dynamic]),
destroy: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(AutoList, () => ({
__proto__: dart.getGetters(AutoList.__proto__),
[S$._removableList]: core.bool,
iterator: core.Iterator$(T),
[S$.$iterator]: core.Iterator$(T),
count: dart.dynamic
}));
dart.setSetterSignature(AutoList, () => ({
__proto__: dart.getSetters(AutoList.__proto__),
[S$._removableList]: core.bool
}));
dart.setLibraryUri(AutoList, I[25]);
dart.setFieldSignature(AutoList, () => ({
__proto__: dart.getFields(AutoList.__proto__),
[S$._list$3]: dart.fieldType(core.List$(T)),
[S$._state]: dart.fieldType(dart.nullable(ST)),
[S$.__AutoList__removableList]: dart.fieldType(dart.nullable(core.bool)),
[S$.__AutoList__removableList_isSet]: dart.fieldType(core.bool)
}));
dart.defineExtensionAccessors(AutoList, ['iterator', 'length']);
return AutoList;
});
AutoList$.AutoList = AutoList$.AutoList$();
dart.addTypeTests(AutoList$.AutoList, _is_AutoList_default);
BinaryList.BinaryList = class BinaryList$ extends core.Object {
get length() {
return this[S$._list$4][S$.$length];
}
addDateTime(value) {
if (value == null) dart.nullFailed(I[26], 37, 29, "value");
this[S$._list$4][S$.$addAll](DC.DC.dateTimeToBytes(value));
}
insertDateTime(position, value) {
if (position == null) dart.nullFailed(I[26], 41, 27, "position");
if (value == null) dart.nullFailed(I[26], 41, 46, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.dateTimeToBytes(value));
}
addDateTimeArray(value) {
if (value == null) dart.nullFailed(I[26], 45, 40, "value");
this[S$._list$4][S$.$addAll](DC.DC.dateTimeArrayToBytes(value));
}
insertDateTimeArray(position, value) {
if (position == null) dart.nullFailed(I[26], 49, 32, "position");
if (value == null) dart.nullFailed(I[26], 49, 57, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.dateTimeArrayToBytes(value));
}
addGuid(value) {
if (value == null) dart.nullFailed(I[26], 53, 21, "value");
this[S$._list$4][S$.$addAll](DC.DC.guidToBytes(value));
}
insertGuid(position, value) {
if (position == null) dart.nullFailed(I[26], 57, 23, "position");
if (value == null) dart.nullFailed(I[26], 57, 38, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.guidToBytes(value));
}
addUint8Array(value) {
if (value == null) dart.nullFailed(I[26], 61, 32, "value");
this[S$._list$4][S$.$addAll](value);
}
addDC(value) {
if (value == null) dart.nullFailed(I[26], 65, 17, "value");
this[S$._list$4][S$.$addAll](value.toArray());
}
insertUint8Array(position, value) {
if (position == null) dart.nullFailed(I[26], 69, 29, "position");
if (value == null) dart.nullFailed(I[26], 69, 49, "value");
this[S$._list$4][S$.$insertAll](position, value);
}
addString(value) {
if (value == null) dart.nullFailed(I[26], 73, 25, "value");
this[S$._list$4][S$.$addAll](DC.DC.stringToBytes(value));
}
insertString(position, value) {
if (position == null) dart.nullFailed(I[26], 77, 25, "position");
if (value == null) dart.nullFailed(I[26], 77, 42, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.stringToBytes(value));
}
insertUint8(position, value) {
if (position == null) dart.nullFailed(I[26], 81, 24, "position");
if (value == null) dart.nullFailed(I[26], 81, 38, "value");
this[S$._list$4][S$.$insert](position, value);
}
addUint8(value) {
if (value == null) dart.nullFailed(I[26], 85, 21, "value");
this[S$._list$4][S$.$add](value);
}
addInt8(value) {
if (value == null) dart.nullFailed(I[26], 89, 20, "value");
this[S$._list$4][S$.$add](value);
}
insertInt8(position, value) {
if (position == null) dart.nullFailed(I[26], 93, 23, "position");
if (value == null) dart.nullFailed(I[26], 93, 37, "value");
this[S$._list$4][S$.$insert](position, value);
}
addChar(value) {
if (value == null) dart.nullFailed(I[26], 97, 20, "value");
this[S$._list$4][S$.$addAll](DC.DC.charToBytes(value));
}
InsertChar(position, value) {
if (position == null) dart.nullFailed(I[26], 101, 23, "position");
if (value == null) dart.nullFailed(I[26], 101, 37, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.charToBytes(value));
}
addBoolean(value) {
if (value == null) dart.nullFailed(I[26], 105, 24, "value");
this[S$._list$4][S$.$addAll](DC.DC.boolToBytes(value));
}
insertBoolean(position, value) {
if (position == null) dart.nullFailed(I[26], 109, 26, "position");
if (value == null) dart.nullFailed(I[26], 109, 41, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.boolToBytes(value));
}
addUint16(value) {
if (value == null) dart.nullFailed(I[26], 113, 22, "value");
this[S$._list$4][S$.$addAll](DC.DC.uint16ToBytes(value));
}
insertUint16(position, value) {
if (position == null) dart.nullFailed(I[26], 117, 25, "position");
if (value == null) dart.nullFailed(I[26], 117, 39, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.uint16ToBytes(value));
}
addInt16(value) {
if (value == null) dart.nullFailed(I[26], 121, 21, "value");
this[S$._list$4][S$.$addAll](DC.DC.int16ToBytes(value));
}
insertInt16(position, value) {
if (position == null) dart.nullFailed(I[26], 125, 24, "position");
if (value == null) dart.nullFailed(I[26], 125, 38, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.int16ToBytes(value));
}
addUint32(value, endian = C[55] || CT.C55) {
if (value == null) dart.nullFailed(I[26], 129, 22, "value");
if (endian == null) dart.nullFailed(I[26], 129, 37, "endian");
this[S$._list$4][S$.$addAll](DC.DC.uint32ToBytes(value, endian));
}
insertUint32(position, value) {
if (position == null) dart.nullFailed(I[26], 133, 25, "position");
if (value == null) dart.nullFailed(I[26], 133, 39, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.uint32ToBytes(value));
}
addInt32(value) {
if (value == null) dart.nullFailed(I[26], 137, 21, "value");
this[S$._list$4][S$.$addAll](DC.DC.int32ToBytes(value));
}
insertInt32(position, value) {
if (position == null) dart.nullFailed(I[26], 141, 24, "position");
if (value == null) dart.nullFailed(I[26], 141, 38, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.int32ToBytes(value));
}
addUint64(value, endian = C[55] || CT.C55) {
if (value == null) dart.nullFailed(I[26], 145, 22, "value");
if (endian == null) dart.nullFailed(I[26], 145, 37, "endian");
this[S$._list$4][S$.$addAll](DC.DC.uint64ToBytes(value, endian));
}
insertUint64(position, value) {
if (position == null) dart.nullFailed(I[26], 149, 25, "position");
if (value == null) dart.nullFailed(I[26], 149, 39, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.uint64ToBytes(value));
}
addInt64(value) {
if (value == null) dart.nullFailed(I[26], 153, 21, "value");
this[S$._list$4][S$.$addAll](DC.DC.int64ToBytes(value));
}
insertInt64(position, value) {
if (position == null) dart.nullFailed(I[26], 157, 24, "position");
if (value == null) dart.nullFailed(I[26], 157, 38, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.int64ToBytes(value));
}
addFloat32(value) {
if (value == null) dart.nullFailed(I[26], 161, 26, "value");
this[S$._list$4][S$.$addAll](DC.DC.float32ToBytes(value));
}
insertFloat32(position, value) {
if (position == null) dart.nullFailed(I[26], 165, 26, "position");
if (value == null) dart.nullFailed(I[26], 165, 43, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.float32ToBytes(value));
}
addFloat64(value) {
if (value == null) dart.nullFailed(I[26], 169, 26, "value");
this[S$._list$4][S$.$addAll](DC.DC.float64ToBytes(value));
}
insertFloat64(position, value) {
if (position == null) dart.nullFailed(I[26], 173, 26, "position");
if (value == null) dart.nullFailed(I[26], 173, 43, "value");
this[S$._list$4][S$.$insertAll](position, DC.DC.float64ToBytes(value));
}
toArray() {
return _native_typed_data.NativeUint8List.fromList(this[S$._list$4]);
}
toDC() {
return new DC.DC.fromUint8Array(this.toArray());
}
done() {
return new AsyncReply$.AsyncReply.ready(null);
}
static ['_#new#tearOff']() {
return new BinaryList.BinaryList.new();
}
};
(BinaryList.BinaryList.new = function() {
this[S$._list$4] = T$.JSArrayOfint().of([]);
;
}).prototype = BinaryList.BinaryList.prototype;
dart.addTypeTests(BinaryList.BinaryList);
dart.addTypeCaches(BinaryList.BinaryList);
dart.setMethodSignature(BinaryList.BinaryList, () => ({
__proto__: dart.getMethods(BinaryList.BinaryList.__proto__),
addDateTime: dart.fnType(dart.void, [core.DateTime]),
insertDateTime: dart.fnType(dart.void, [core.int, core.DateTime]),
addDateTimeArray: dart.fnType(dart.void, [core.List$(core.DateTime)]),
insertDateTimeArray: dart.fnType(dart.void, [core.int, core.List$(core.DateTime)]),
addGuid: dart.fnType(dart.void, [Guid.Guid]),
insertGuid: dart.fnType(dart.void, [core.int, Guid.Guid]),
addUint8Array: dart.fnType(dart.void, [typed_data.Uint8List]),
addDC: dart.fnType(dart.void, [DC.DC]),
insertUint8Array: dart.fnType(dart.void, [core.int, typed_data.Uint8List]),
addString: dart.fnType(dart.void, [core.String]),
insertString: dart.fnType(dart.void, [core.int, core.String]),
insertUint8: dart.fnType(dart.void, [core.int, core.int]),
addUint8: dart.fnType(dart.void, [core.int]),
addInt8: dart.fnType(dart.void, [core.int]),
insertInt8: dart.fnType(dart.void, [core.int, core.int]),
addChar: dart.fnType(dart.void, [core.int]),
InsertChar: dart.fnType(dart.void, [core.int, core.int]),
addBoolean: dart.fnType(dart.void, [core.bool]),
insertBoolean: dart.fnType(dart.void, [core.int, core.bool]),
addUint16: dart.fnType(dart.void, [core.int]),
insertUint16: dart.fnType(dart.void, [core.int, core.int]),
addInt16: dart.fnType(dart.void, [core.int]),
insertInt16: dart.fnType(dart.void, [core.int, core.int]),
addUint32: dart.fnType(dart.void, [core.int], [typed_data.Endian]),
insertUint32: dart.fnType(dart.void, [core.int, core.int]),
addInt32: dart.fnType(dart.void, [core.int]),
insertInt32: dart.fnType(dart.void, [core.int, core.int]),
addUint64: dart.fnType(dart.void, [core.int], [typed_data.Endian]),
insertUint64: dart.fnType(dart.void, [core.int, core.int]),
addInt64: dart.fnType(dart.void, [core.int]),
insertInt64: dart.fnType(dart.void, [core.int, core.int]),
addFloat32: dart.fnType(dart.void, [core.double]),
insertFloat32: dart.fnType(dart.void, [core.int, core.double]),
addFloat64: dart.fnType(dart.void, [core.double]),
insertFloat64: dart.fnType(dart.void, [core.int, core.double]),
toArray: dart.fnType(typed_data.Uint8List, []),
toDC: dart.fnType(DC.DC, []),
done: dart.fnType(AsyncReply$.AsyncReply, [])
}));
dart.setGetterSignature(BinaryList.BinaryList, () => ({
__proto__: dart.getGetters(BinaryList.BinaryList.__proto__),
length: core.int
}));
dart.setLibraryUri(BinaryList.BinaryList, I[26]);
dart.setFieldSignature(BinaryList.BinaryList, () => ({
__proto__: dart.getFields(BinaryList.BinaryList.__proto__),
[S$._list$4]: dart.fieldType(core.List$(core.int))
}));
Codec.CodecComposeResults = class CodecComposeResults extends core.Object {
get transmissionTypeIdentifier() {
return this[S$.transmissionTypeIdentifier];
}
set transmissionTypeIdentifier(value) {
super.transmissionTypeIdentifier = value;
}
get data() {
return this[S$.data];
}
set data(value) {
super.data = value;
}
static ['_#new#tearOff'](transmissionTypeIdentifier, data) {
if (transmissionTypeIdentifier == null) dart.nullFailed(I[27], 77, 28, "transmissionTypeIdentifier");
if (data == null) dart.nullFailed(I[27], 77, 61, "data");
return new Codec.CodecComposeResults.new(transmissionTypeIdentifier, data);
}
};
(Codec.CodecComposeResults.new = function(transmissionTypeIdentifier, data) {
if (transmissionTypeIdentifier == null) dart.nullFailed(I[27], 77, 28, "transmissionTypeIdentifier");
if (data == null) dart.nullFailed(I[27], 77, 61, "data");
this[S$.transmissionTypeIdentifier] = transmissionTypeIdentifier;
this[S$.data] = data;
;
}).prototype = Codec.CodecComposeResults.prototype;
dart.addTypeTests(Codec.CodecComposeResults);
dart.addTypeCaches(Codec.CodecComposeResults);
dart.setLibraryUri(Codec.CodecComposeResults, I[27]);
dart.setFieldSignature(Codec.CodecComposeResults, () => ({
__proto__: dart.getFields(Codec.CodecComposeResults.__proto__),
transmissionTypeIdentifier: dart.finalFieldType(core.int),
data: dart.finalFieldType(DC.DC)
}));
Codec.CodecParseResults = class CodecParseResults extends core.Object {
get reply() {
return this[S$.reply];
}
set reply(value) {
super.reply = value;
}
get size() {
return this[S$.size];
}
set size(value) {
super.size = value;
}
static ['_#new#tearOff'](size, reply) {
if (size == null) dart.nullFailed(I[27], 84, 26, "size");
if (reply == null) dart.nullFailed(I[27], 84, 37, "reply");
return new Codec.CodecParseResults.new(size, reply);
}
};
(Codec.CodecParseResults.new = function(size, reply) {
if (size == null) dart.nullFailed(I[27], 84, 26, "size");
if (reply == null) dart.nullFailed(I[27], 84, 37, "reply");
this[S$.size] = size;
this[S$.reply] = reply;
;
}).prototype = Codec.CodecParseResults.prototype;
dart.addTypeTests(Codec.CodecParseResults);
dart.addTypeCaches(Codec.CodecParseResults);
dart.setLibraryUri(Codec.CodecParseResults, I[27]);
dart.setFieldSignature(Codec.CodecParseResults, () => ({
__proto__: dart.getFields(Codec.CodecParseResults.__proto__),
reply: dart.finalFieldType(AsyncReply$.AsyncReply),
size: dart.finalFieldType(core.int)
}));
Codec.Codec = class Codec$ extends core.Object {
static parse(data, offset, connection, dataType = null) {
let t14, t14$;
if (data == null) dart.nullFailed(I[27], 154, 10, "data");
if (offset == null) dart.nullFailed(I[27], 154, 20, "offset");
let len = 0;
if (dataType == null) {
let parsedDataTyped = TransmissionType.TransmissionType.parse(data, offset, data.length);
len = parsedDataTyped.size;
dataType = parsedDataTyped.type;
offset = (t14$ = (t14 = dataType, t14 == null ? null : t14.offset), t14$ == null ? 0 : t14$);
} else
len = dataType.contentLength;
if (dataType != null) {
if (dataType.classType === 0) {
return new Codec.CodecParseResults.new(len, Codec.Codec.fixedParsers[S$.$_get](dataType.exponent)[S$.$_get](dataType.index)(data, dataType.offset, dataType.contentLength, connection));
} else if (dataType.classType === 1) {
return new Codec.CodecParseResults.new(len, Codec.Codec.dynamicParsers[S$.$_get](dataType.index)(data, dataType.offset, dataType.contentLength, connection));
} else {
return new Codec.CodecParseResults.new(len, Codec.Codec.typedParsers[S$.$_get](dataType.index)(data, dataType.offset, dataType.contentLength, connection));
}
}
dart.throw(core.Exception.new("Can't parse transmission type."));
}
static getListType(list) {
let t14, t14$;
if (list == null) dart.nullFailed(I[27], 255, 32, "list");
t14$ = (t14 = iterable_extensions['IterableExtension|firstWhereOrNull'](FactoryEntry$.FactoryEntry, Warehouse.Warehouse.typesFactory.values, dart.fn(x => {
if (x == null) dart.nullFailed(I[27], 257, 32, "x");
return x.isListSubType(list);
}, T$.FactoryEntryTobool())), t14 == null ? null : t14.type);
return t14$ == null ? dart.wrapType(dart.dynamic) : t14$;
}
static getMapTypes(map) {
let t14, t14$, t14$0, t14$1;
if (map == null) dart.nullFailed(I[27], 262, 37, "map");
let kt = (t14 = iterable_extensions['IterableExtension|firstWhereOrNull'](FactoryEntry$.FactoryEntry, Warehouse.Warehouse.typesFactory.values, dart.fn(x => {
if (x == null) dart.nullFailed(I[27], 264, 28, "x");
return x.isMapKeySubType(map);
}, T$.FactoryEntryTobool())), t14 == null ? null : t14.type);
let vt = (t14$ = iterable_extensions['IterableExtension|firstWhereOrNull'](FactoryEntry$.FactoryEntry, Warehouse.Warehouse.typesFactory.values, dart.fn(x => {
if (x == null) dart.nullFailed(I[27], 267, 28, "x");
return x.isMapValueSubType(map);
}, T$.FactoryEntryTobool())), t14$ == null ? null : t14$.type);
return T$.JSArrayOfType().of([(t14$0 = kt, t14$0 == null ? dart.wrapType(dart.dynamic) : t14$0), (t14$1 = vt, t14$1 == null ? dart.wrapType(dart.dynamic) : t14$1)]);
}
static compose(valueOrSource, connection) {
if (valueOrSource == null) return TransmissionType.TransmissionType.compose(0, new DC.DC.new(0));
let type = dart.runtimeType(valueOrSource);
if (dart.test(Codec.Codec.composers[S$.$containsKey](type))) {
let results = dart.nullCheck(Codec.Codec.composers[S$.$_get](type))(valueOrSource, connection);
return TransmissionType.TransmissionType.compose(results.identifier, results.data);
} else {
if (core.List.is(valueOrSource)) {
let genericType = Codec.Codec.getListType(valueOrSource);
let results = DataSerializer.DataSerializer.typedListComposer(valueOrSource, genericType, connection);
return TransmissionType.TransmissionType.compose(results.identifier, results.data);
} else if (core.Map.is(valueOrSource)) {
let genericTypes = Codec.Codec.getMapTypes(valueOrSource);
let results = DataSerializer.DataSerializer.typedMapComposer(valueOrSource, genericTypes[S$.$_get](0), genericTypes[S$.$_get](1), connection);
return TransmissionType.TransmissionType.compose(results.identifier, results.data);
} else if (IResource.IResource.is(valueOrSource)) {
let results = DataSerializer.DataSerializer.resourceComposer(valueOrSource, connection);
return TransmissionType.TransmissionType.compose(results.identifier, results.data);
} else if (IRecord.IRecord.is(valueOrSource)) {
let results = DataSerializer.DataSerializer.recordComposer(valueOrSource, connection);
return TransmissionType.TransmissionType.compose(results.identifier, results.data);
} else if (IEnum.IEnum.is(valueOrSource)) {
let results = DataSerializer.DataSerializer.enumComposer(valueOrSource, connection);
return TransmissionType.TransmissionType.compose(results.identifier, results.data);
}
}
return TransmissionType.TransmissionType.compose(0, new DC.DC.new(0));
}
static isLocalResource(resource, connection) {
if (resource == null) dart.nullFailed(I[27], 353, 17, "resource");
if (connection == null) return false;
if (DistributedResource.DistributedResource.is(resource)) {
if (dart.equals(resource.connection, connection)) return true;
}
return false;
}
static implementsInterface(type, ifac) {
return Codec._DummyClass$(ifac).is(new (Codec._DummyClass$(type)).new());
}
static ['_#new#tearOff']() {
return new Codec.Codec.new();
}
};
(Codec.Codec.new = function() {
;
}).prototype = Codec.Codec.prototype;
dart.addTypeTests(Codec.Codec);
dart.addTypeCaches(Codec.Codec);
dart.setStaticMethodSignature(Codec.Codec, () => ['parse', 'getListType', 'getMapTypes', 'compose', 'isLocalResource', 'implementsInterface']);
dart.setLibraryUri(Codec.Codec, I[27]);
dart.setStaticFieldSignature(Codec.Codec, () => ['fixedParsers', 'dynamicParsers', 'typedParsers', 'composers']);
dart.defineLazy(Codec.Codec, {
/*Codec.Codec.fixedParsers*/get fixedParsers() {
return T$.JSArrayOfListOfDCAndintAndint__ToAsyncReply().of([T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[56] || CT.C56, C[57] || CT.C57, C[58] || CT.C58, C[59] || CT.C59]), T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[60] || CT.C60, C[61] || CT.C61, C[62] || CT.C62]), T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[63] || CT.C63, C[64] || CT.C64, C[65] || CT.C65]), T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[66] || CT.C66, C[67] || CT.C67, C[68] || CT.C68, C[69] || CT.C69, C[70] || CT.C70]), T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[71] || CT.C71, C[72] || CT.C72, C[73] || CT.C73, C[74] || CT.C74]), T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[75] || CT.C75, C[76] || CT.C76, C[77] || CT.C77])]);
},
set fixedParsers(_) {},
/*Codec.Codec.dynamicParsers*/get dynamicParsers() {
return T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[78] || CT.C78, C[79] || CT.C79, C[80] || CT.C80, C[81] || CT.C81, C[82] || CT.C82]);
},
set dynamicParsers(_) {},
/*Codec.Codec.typedParsers*/get typedParsers() {
return T$.JSArrayOfDCAndintAndint__ToAsyncReply().of([C[83] || CT.C83, C[84] || CT.C84, C[85] || CT.C85, C[86] || CT.C86, C[87] || CT.C87, C[88] || CT.C88]);
},
set typedParsers(_) {},
/*Codec.Codec.composers*/get composers() {
return new (T$.LinkedMapOfType$dynamicAndDistributedConnectionNToDataSerializerComposeResults()).from([dart.wrapType(core.bool), C[89] || CT.C89, dart.wrapType(NotModified.NotModified), C[90] || CT.C90, dart.wrapType(IntType.Int32), C[91] || CT.C91, dart.wrapType(IntType.UInt32), C[92] || CT.C92, dart.wrapType(IntType.Int8), C[93] || CT.C93, dart.wrapType(IntType.UInt8), C[94] || CT.C94, dart.wrapType(IntType.Int16), C[95] || CT.C95, dart.wrapType(IntType.UInt16), C[96] || CT.C96, dart.wrapType(core.int), C[97] || CT.C97, dart.wrapType(core.double), C[98] || CT.C98, dart.wrapType(core.DateTime), C[99] || CT.C99, dart.wrapType(DC.DC), C[100] || CT.C100, dart.wrapType(core.String), C[101] || CT.C101, dart.wrapType(core.List), C[102] || CT.C102, dart.wrapType(T$.ListOfIResourceL()), C[103] || CT.C103, dart.wrapType(T$.ListOfIResourceN()), C[103] || CT.C103, dart.wrapType(T$.ListOfIRecordL()), C[104] || CT.C104, dart.wrapType(T$.ListOfIRecordN()), C[104] || CT.C104, dart.wrapType(core.Map), C[105] || CT.C105, dart.wrapType(T$.ListOfPropertyValueL()), C[106] || CT.C106]);
},
set composers(_) {}
}, false);
const _is__DummyClass_default = Symbol('_is__DummyClass_default');
Codec._DummyClass$ = dart.generic(T => {
class _DummyClass extends core.Object {
static ['_#new#tearOff'](T) {
return new (Codec._DummyClass$(T)).new();
}
}
(_DummyClass.new = function() {
;
}).prototype = _DummyClass.prototype;
dart.addTypeTests(_DummyClass);
_DummyClass.prototype[_is__DummyClass_default] = true;
dart.addTypeCaches(_DummyClass);
dart.setLibraryUri(_DummyClass, I[27]);
return _DummyClass;
});
Codec._DummyClass = Codec._DummyClass$();
dart.addTypeTests(Codec._DummyClass, _is__DummyClass_default);
RepresentationType.RepresentationTypeIdentifier = class RepresentationTypeIdentifier extends core.Object {
static ['_#new#tearOff']() {
return new RepresentationType.RepresentationTypeIdentifier.new();
}
};
(RepresentationType.RepresentationTypeIdentifier.new = function() {
;
}).prototype = RepresentationType.RepresentationTypeIdentifier.prototype;
dart.addTypeTests(RepresentationType.RepresentationTypeIdentifier);
dart.addTypeCaches(RepresentationType.RepresentationTypeIdentifier);
dart.setLibraryUri(RepresentationType.RepresentationTypeIdentifier, I[28]);
dart.setStaticFieldSignature(RepresentationType.RepresentationTypeIdentifier, () => ['Void', 'Dynamic', 'Bool', 'UInt8', 'Int8', 'Char', 'Int16', 'UInt16', 'Int32', 'UInt32', 'Float32', 'Int64', 'UInt64', 'Float64', 'DateTime', 'Int128', 'UInt128', 'Decimal', 'String', 'RawData', 'Resource', 'Record', 'List', 'Map', 'Enum', 'TypedResource', 'TypedRecord', 'TypedList', 'Tuple2', 'TypedMap', 'Tuple3', 'Tuple4', 'Tuple5', 'Tuple6', 'Tuple7']);
dart.defineLazy(RepresentationType.RepresentationTypeIdentifier, {
/*RepresentationType.RepresentationTypeIdentifier.Void*/get Void() {
return 0;
},
/*RepresentationType.RepresentationTypeIdentifier.Dynamic*/get Dynamic() {
return 1;
},
/*RepresentationType.RepresentationTypeIdentifier.Bool*/get Bool() {
return 2;
},
/*RepresentationType.RepresentationTypeIdentifier.UInt8*/get UInt8() {
return 3;
},
/*RepresentationType.RepresentationTypeIdentifier.Int8*/get Int8() {
return 4;
},
/*RepresentationType.RepresentationTypeIdentifier.Char*/get Char() {
return 5;
},
/*RepresentationType.RepresentationTypeIdentifier.Int16*/get Int16() {
return 6;
},
/*RepresentationType.RepresentationTypeIdentifier.UInt16*/get UInt16() {
return 7;
},
/*RepresentationType.RepresentationTypeIdentifier.Int32*/get Int32() {
return 8;
},
/*RepresentationType.RepresentationTypeIdentifier.UInt32*/get UInt32() {
return 9;
},
/*RepresentationType.RepresentationTypeIdentifier.Float32*/get Float32() {
return 10;
},
/*RepresentationType.RepresentationTypeIdentifier.Int64*/get Int64() {
return 11;
},
/*RepresentationType.RepresentationTypeIdentifier.UInt64*/get UInt64() {
return 12;
},
/*RepresentationType.RepresentationTypeIdentifier.Float64*/get Float64() {
return 13;
},
/*RepresentationType.RepresentationTypeIdentifier.DateTime*/get DateTime() {
return 14;
},
/*RepresentationType.RepresentationTypeIdentifier.Int128*/get Int128() {
return 15;
},
/*RepresentationType.RepresentationTypeIdentifier.UInt128*/get UInt128() {
return 16;
},
/*RepresentationType.RepresentationTypeIdentifier.Decimal*/get Decimal() {
return 17;
},
/*RepresentationType.RepresentationTypeIdentifier.String*/get String() {
return 18;
},
/*RepresentationType.RepresentationTypeIdentifier.RawData*/get RawData() {
return 19;
},
/*RepresentationType.RepresentationTypeIdentifier.Resource*/get Resource() {
return 20;
},
/*RepresentationType.RepresentationTypeIdentifier.Record*/get Record() {
return 21;
},
/*RepresentationType.RepresentationTypeIdentifier.List*/get List() {
return 22;
},
/*RepresentationType.RepresentationTypeIdentifier.Map*/get Map() {
return 23;
},
/*RepresentationType.RepresentationTypeIdentifier.Enum*/get Enum() {
return 24;
},
/*RepresentationType.RepresentationTypeIdentifier.TypedResource*/get TypedResource() {
return 69;
},
/*RepresentationType.RepresentationTypeIdentifier.TypedRecord*/get TypedRecord() {
return 70;
},
/*RepresentationType.RepresentationTypeIdentifier.TypedList*/get TypedList() {
return 72;
},
/*RepresentationType.RepresentationTypeIdentifier.Tuple2*/get Tuple2() {
return 80;
},
/*RepresentationType.RepresentationTypeIdentifier.TypedMap*/get TypedMap() {
return 81;
},
/*RepresentationType.RepresentationTypeIdentifier.Tuple3*/get Tuple3() {
return 88;
},
/*RepresentationType.RepresentationTypeIdentifier.Tuple4*/get Tuple4() {
return 96;
},
/*RepresentationType.RepresentationTypeIdentifier.Tuple5*/get Tuple5() {
return 104;
},
/*RepresentationType.RepresentationTypeIdentifier.Tuple6*/get Tuple6() {
return 112;
},
/*RepresentationType.RepresentationTypeIdentifier.Tuple7*/get Tuple7() {
return 120;
}
}, false);
const _is_DumClass_default = Symbol('_is_DumClass_default');
RepresentationType.DumClass$ = dart.generic(T => {
class DumClass extends core.Object {
get type() {
return this[S$.type$5];
}
set type(value) {
this[S$.type$5] = value;
}
static ['_#new#tearOff'](T) {
return new (RepresentationType.DumClass$(T)).new();
}
}
(DumClass.new = function() {
this[S$.type$5] = dart.wrapType(T);
;
}).prototype = DumClass.prototype;
dart.addTypeTests(DumClass);
DumClass.prototype[_is_DumClass_default] = true;
dart.addTypeCaches(DumClass);
dart.setLibraryUri(DumClass, I[28]);
dart.setFieldSignature(DumClass, () => ({
__proto__: dart.getFields(DumClass.__proto__),
type: dart.fieldType(core.Type)
}));
return DumClass;
});
RepresentationType.DumClass = RepresentationType.DumClass$();
dart.addTypeTests(RepresentationType.DumClass, _is_DumClass_default);
RepresentationType.RepresentationTypeParseResults = class RepresentationTypeParseResults extends core.Object {
get type() {
return this[S$.type$6];
}
set type(value) {
this[S$.type$6] = value;
}
get size() {
return this[S$.size$1];
}
set size(value) {
this[S$.size$1] = value;
}
static ['_#new#tearOff'](size, type) {
if (size == null) dart.nullFailed(I[28], 62, 39, "size");
if (type == null) dart.nullFailed(I[28], 62, 50, "type");
return new RepresentationType.RepresentationTypeParseResults.new(size, type);
}
};
(RepresentationType.RepresentationTypeParseResults.new = function(size, type) {
if (size == null) dart.nullFailed(I[28], 62, 39, "size");
if (type == null) dart.nullFailed(I[28], 62, 50, "type");
this[S$.size$1] = size;
this[S$.type$6] = type;
;
}).prototype = RepresentationType.RepresentationTypeParseResults.prototype;
dart.addTypeTests(RepresentationType.RepresentationTypeParseResults);
dart.addTypeCaches(RepresentationType.RepresentationTypeParseResults);
dart.setLibraryUri(RepresentationType.RepresentationTypeParseResults, I[28]);
dart.setFieldSignature(RepresentationType.RepresentationTypeParseResults, () => ({
__proto__: dart.getFields(RepresentationType.RepresentationTypeParseResults.__proto__),
type: dart.fieldType(RepresentationType.RepresentationType),
size: dart.fieldType(core.int)
}));
RepresentationType.RepresentationType = class RepresentationType$ extends core.Object {
get runtimeTypes() {
return this[S$.runtimeTypes];
}
set runtimeTypes(value) {
this[S$.runtimeTypes] = value;
}
get identifier() {
return this[S$.identifier];
}
set identifier(value) {
this[S$.identifier] = value;
}
get nullable() {
return this[S$.nullable];
}
set nullable(value) {
this[S$.nullable] = value;
}
get guid() {
return this[S$.guid];
}
set guid(value) {
this[S$.guid] = value;
}
get subTypes() {
return this[S$.subTypes];
}
set subTypes(value) {
this[S$.subTypes] = value;
}
static getTypeFromName(name) {
if (name == null) dart.nullFailed(I[28], 66, 38, "name");
let types = C[107] || CT.C107;
if (dart.test(types[S$.$containsKey](name))) {
return dart.nullCheck(types[S$.$_get](name));
} else
return new core.Object.new()[S$.$runtimeType];
}
toNullable() {
return new RepresentationType.RepresentationType.new(this.identifier, true, this.guid, this.subTypes);
}
static fromType(type) {
let t14;
if (type == null) dart.nullFailed(I[28], 94, 44, "type");
t14 = Warehouse.Warehouse.typesFactory._get(type);
return t14 == null ? null : t14.representationType;
}
getRuntimeType() {
let t14, t14$, t14$0;
if (dart.test(this.runtimeTypes[S$.$containsKey](this.identifier))) return dart.test(this.nullable) ? dart.nullCheck(this.runtimeTypes[S$.$_get](this.identifier))[S$.$_get](1) : dart.nullCheck(this.runtimeTypes[S$.$_get](this.identifier))[S$.$_get](0);
if (this.identifier === 70) {
t14 = Warehouse.Warehouse.getTemplateByClassId(dart.nullCheck(this.guid), TemplateType.TemplateType.Record);
return t14 == null ? null : t14.definedType;
} else if (this.identifier === 69) {
t14$ = Warehouse.Warehouse.getTemplateByClassId(dart.nullCheck(this.guid), TemplateType.TemplateType.Unspecified);
return t14$ == null ? null : t14$.definedType;
} else if (this.identifier === 24) {
t14$0 = Warehouse.Warehouse.getTemplateByClassId(dart.nullCheck(this.guid), TemplateType.TemplateType.Enum);
return t14$0 == null ? null : t14$0.definedType;
}
return null;
}
static ['_#new#tearOff'](identifier, nullable, guid = null, subTypes = null) {
if (identifier == null) dart.nullFailed(I[28], 186, 27, "identifier");
if (nullable == null) dart.nullFailed(I[28], 186, 44, "nullable");
return new RepresentationType.RepresentationType.new(identifier, nullable, guid, subTypes);
}
compose() {
let rt = new BinaryList.BinaryList.new();
if (dart.test(this.nullable))
rt.addUint8((128 | dart.notNull(this.identifier)) >>> 0);
else
rt.addUint8(this.identifier);
if (this.guid != null) rt.addDC(DC.DC.guidToBytes(dart.nullCheck(this.guid)));
if (this.subTypes != null) for (let i = 0; i < dart.notNull(dart.nullCheck(this.subTypes)[S$.$length]); i = i + 1)
rt.addDC(dart.nullCheck(this.subTypes)[S$.$_get](i).compose());
return rt.toDC();
}
static parse(data, offset) {
let t14;
if (data == null) dart.nullFailed(I[28], 209, 50, "data");
if (offset == null) dart.nullFailed(I[28], 209, 60, "offset");
let oOffset = offset;
let header = data._get((t14 = offset, offset = dart.notNull(t14) + 1, t14));
let nullable = (dart.notNull(header) & 128) > 0;
let identifier = dart.notNull(header) & 127;
if ((dart.notNull(header) & 64) > 0) {
let hasGUID = (dart.notNull(header) & 4) > 0;
let subsCount = dart.notNull(header) >> 3 & 7;
let guid = null;
if (hasGUID) {
guid = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
}
let subs = T$.JSArrayOfRepresentationType().of([]);
for (let i = 0; i < subsCount; i = i + 1) {
let parsed = RepresentationType.RepresentationType.parse(data, offset);
subs[S$.$add](parsed.type);
offset = dart.notNull(offset) + dart.notNull(parsed.size);
}
return new RepresentationType.RepresentationTypeParseResults.new(dart.notNull(offset) - dart.notNull(oOffset), new RepresentationType.RepresentationType.new(identifier, nullable, guid, subs));
} else {
return new RepresentationType.RepresentationTypeParseResults.new(1, new RepresentationType.RepresentationType.new(identifier, nullable, null, null));
}
}
};
(RepresentationType.RepresentationType.new = function(identifier, nullable, guid = null, subTypes = null) {
if (identifier == null) dart.nullFailed(I[28], 186, 27, "identifier");
if (nullable == null) dart.nullFailed(I[28], 186, 44, "nullable");
this[S$.runtimeTypes] = new (T$.IdentityMapOfint$ListOfType()).from([0, T$.JSArrayOfType().of([dart.wrapType(dart.dynamic), dart.wrapType(dart.dynamic)]), 1, T$.JSArrayOfType().of([dart.wrapType(dart.dynamic), dart.wrapType(dart.dynamic)]), 2, T$.JSArrayOfType().of([dart.wrapType(core.bool), RepresentationType.getNullableType(core.bool)]), 5, T$.JSArrayOfType().of([dart.wrapType(core.String), RepresentationType.getNullableType(core.String)]), 3, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 4, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 6, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 7, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 8, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 9, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 11, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 12, T$.JSArrayOfType().of([dart.wrapType(core.int), RepresentationType.getNullableType(core.int)]), 10, T$.JSArrayOfType().of([dart.wrapType(core.double), RepresentationType.getNullableType(core.double)]), 13, T$.JSArrayOfType().of([dart.wrapType(core.double), RepresentationType.getNullableType(core.double)]), 17, T$.JSArrayOfType().of([dart.wrapType(core.double), RepresentationType.getNullableType(core.double)]), 18, T$.JSArrayOfType().of([dart.wrapType(core.String), RepresentationType.getNullableType(core.String)]), 14, T$.JSArrayOfType().of([dart.wrapType(core.DateTime), RepresentationType.getNullableType(core.DateTime)]), 20, T$.JSArrayOfType().of([dart.wrapType(IResource.IResource), RepresentationType.getNullableType(IResource.IResource)]), 21, T$.JSArrayOfType().of([dart.wrapType(IRecord.IRecord), RepresentationType.getNullableType(IRecord.IRecord)])]);
this[S$.identifier] = identifier;
this[S$.nullable] = nullable;
this[S$.guid] = guid;
this[S$.subTypes] = subTypes;
}).prototype = RepresentationType.RepresentationType.prototype;
dart.addTypeTests(RepresentationType.RepresentationType);
dart.addTypeCaches(RepresentationType.RepresentationType);
dart.setMethodSignature(RepresentationType.RepresentationType, () => ({
__proto__: dart.getMethods(RepresentationType.RepresentationType.__proto__),
toNullable: dart.fnType(RepresentationType.RepresentationType, []),
getRuntimeType: dart.fnType(dart.nullable(core.Type), []),
compose: dart.fnType(DC.DC, [])
}));
dart.setStaticMethodSignature(RepresentationType.RepresentationType, () => ['getTypeFromName', 'fromType', 'parse']);
dart.setLibraryUri(RepresentationType.RepresentationType, I[28]);
dart.setFieldSignature(RepresentationType.RepresentationType, () => ({
__proto__: dart.getFields(RepresentationType.RepresentationType.__proto__),
runtimeTypes: dart.fieldType(core.Map$(core.int, core.List$(core.Type))),
identifier: dart.fieldType(core.int),
nullable: dart.fieldType(core.bool),
guid: dart.fieldType(dart.nullable(Guid.Guid)),
subTypes: dart.fieldType(dart.nullable(core.List$(RepresentationType.RepresentationType)))
}));
dart.setStaticFieldSignature(RepresentationType.RepresentationType, () => ['Void', 'Dynamic']);
dart.defineLazy(RepresentationType.RepresentationType, {
/*RepresentationType.RepresentationType.Void*/get Void() {
return new RepresentationType.RepresentationType.new(0, true, null, null);
},
set Void(_) {},
/*RepresentationType.RepresentationType.Dynamic*/get Dynamic() {
return new RepresentationType.RepresentationType.new(1, true, null, null);
},
set Dynamic(_) {}
}, false);
RepresentationType.getNullableType = function getNullableType(T) {
return new (RepresentationType.DumClass$(dart.nullable(T))).new().type;
};
RepresentationType.getTypeOf = function getTypeOf(T) {
return new (RepresentationType.DumClass$(T)).new().type;
};
const Object_IterableMixin$36 = class Object_IterableMixin extends core.Object {};
(Object_IterableMixin$36.new = function() {
}).prototype = Object_IterableMixin$36.prototype;
dart.applyMixin(Object_IterableMixin$36, collection.IterableMixin$(core.int));
DC.DC = class DC$ extends Object_IterableMixin$36 {
set [S$._data](t14) {
if (t14 == null) dart.nullFailed(I[29], 39, 18, "null");
this[S$.__DC__data_isSet] = true;
this[S$.__DC__data] = t14;
}
get [S$._data]() {
let t15;
return dart.test(this[S$.__DC__data_isSet]) ? (t15 = this[S$.__DC__data], t15) : dart.throw(new _internal.LateError.fieldNI("_data"));
}
get [S$._dv]() {
let t15;
return dart.test(this[S$.__DC__dv_isSet]) ? (t15 = this[S$.__DC__dv], t15) : dart.throw(new _internal.LateError.fieldNI("_dv"));
}
set [S$._dv](t15) {
if (t15 == null) dart.nullFailed(I[29], 40, 17, "null");
this[S$.__DC__dv_isSet] = true;
this[S$.__DC__dv] = t15;
}
static ['_#new#tearOff'](length) {
if (length == null) dart.nullFailed(I[29], 42, 10, "length");
return new DC.DC.new(length);
}
static ['_#fromUint8Array#tearOff'](array) {
if (array == null) dart.nullFailed(I[29], 47, 31, "array");
return new DC.DC.fromUint8Array(array);
}
static ['_#fromList#tearOff'](list) {
if (list == null) dart.nullFailed(I[29], 52, 25, "list");
return new DC.DC.fromList(list);
}
toHex(separator = " ", offset = null, length = null) {
let t16, t16$;
if (separator == null) dart.nullFailed(I[29], 57, 24, "separator");
let start = (t16 = offset, t16 == null ? 0 : t16);
let count = (t16$ = length, t16$ == null ? dart.notNull(this[S$._data][S$.$length]) - dart.notNull(start) : t16$);
if (count === 0) return "";
let rt = this[S$._data][S$.$_get](start)[S$.$toRadixString](16)[S$.$padLeft](2, "0");
for (let i = dart.notNull(start) + 1; i < dart.notNull(count); i = i + 1) {
rt = rt + (dart.notNull(separator) + this[S$._data][S$.$_get](i)[S$.$toRadixString](16)[S$.$padLeft](2, "0"));
}
return rt;
}
static ['_#fromHex#tearOff'](hex, separator = " ") {
if (hex == null) dart.nullFailed(I[29], 72, 21, "hex");
if (separator == null) dart.nullFailed(I[29], 72, 34, "separator");
return new DC.DC.fromHex(hex, separator);
}
_get(index) {
if (index == null) dart.nullFailed(I[29], 79, 23, "index");
return this[S$._data][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
let t18, t17, t16;
if (index == null) dart.nullFailed(I[29], 80, 20, "index");
if (value == null) dart.nullFailed(I[29], 80, 31, "value");
t16 = this[S$._data];
t17 = index;
t18 = value;
t16[S$.$_set](t17, t18);
t18;
return value$;
}
get length() {
return this[S$._data][S$.$length];
}
get iterator() {
return this[S$._data][S$.$iterator];
}
static hexToBytes(value) {
if (value == null) dart.nullFailed(I[29], 85, 31, "value");
let rt = new DC.DC.new((value.length / 2)[S$.$truncate]());
for (let i = 0; i < dart.notNull(rt.length); i = i + 1)
rt._set(i, core.int.parse(value[S$.$substring](i * 2, 2), {radix: 16}));
return rt;
}
static boolToBytes(value) {
if (value == null) dart.nullFailed(I[29], 93, 30, "value");
let rt = new DC.DC.new(1);
rt.setBoolean(0, value);
return rt;
}
static guidToBytes(value) {
if (value == null) dart.nullFailed(I[29], 99, 30, "value");
let rt = new DC.DC.new(16);
rt.setGuid(0, value);
return rt;
}
static int8ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 105, 29, "value");
let rt = new DC.DC.new(1);
rt.setInt8(0, value);
return rt;
}
static int8ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 111, 39, "value");
let rt = new DC.DC.new(value[S$.$length]);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setInt8(i, value[S$.$_get](i));
return rt;
}
static uint8ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 117, 30, "value");
let rt = new DC.DC.new(1);
rt.setUint8(0, value);
return rt;
}
static uint8ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 123, 41, "value");
let rt = new DC.DC.new(value[S$.$length]);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setUint8(i, value[S$.$_get](i));
return rt;
}
static charToBytes(value) {
if (value == null) dart.nullFailed(I[29], 129, 29, "value");
let rt = new DC.DC.new(2);
rt.setChar(0, value);
return rt;
}
static int16ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 135, 30, "value");
let rt = new DC.DC.new(2);
rt.setInt16(0, value);
return rt;
}
static int16ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 141, 41, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 2);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setInt16(i * 2, value[S$.$_get](i));
return rt;
}
static uint16ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 147, 31, "value");
let rt = new DC.DC.new(2);
rt.setUint16(0, value);
return rt;
}
static uint16ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 153, 43, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 2);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setUint16(i * 2, value[S$.$_get](i));
return rt;
}
static int32ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 159, 30, "value");
let rt = new DC.DC.new(4);
rt.setInt32(0, value);
return rt;
}
static int32ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 165, 41, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 4);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setInt32(i * 4, value[S$.$_get](i));
return rt;
}
static uint32ToBytes(value, endian = C[55] || CT.C55) {
if (value == null) dart.nullFailed(I[29], 171, 31, "value");
if (endian == null) dart.nullFailed(I[29], 171, 46, "endian");
let rt = new DC.DC.new(4);
rt.setUint32(0, value, endian);
return rt;
}
static uint32ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 177, 43, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 4);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setUint32(i * 4, value[S$.$_get](i));
return rt;
}
static float32ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 183, 35, "value");
let rt = new DC.DC.new(4);
rt.setFloat32(0, value);
return rt;
}
static float32ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 189, 45, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 4);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setFloat32(i * 4, value[S$.$_get](i));
return rt;
}
static int64ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 195, 30, "value");
let rt = new DC.DC.new(8);
rt.setInt64(0, value);
return rt;
}
static int64ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 201, 41, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 8);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setInt64(i * 8, value[S$.$_get](i));
return rt;
}
static uint64ToBytes(value, endian = C[55] || CT.C55) {
if (value == null) dart.nullFailed(I[29], 207, 31, "value");
if (endian == null) dart.nullFailed(I[29], 207, 46, "endian");
let rt = new DC.DC.new(8);
rt.setUint64(0, value, endian);
return rt;
}
static uint64ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 213, 43, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 8);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setUint64(i * 8, value[S$.$_get](i));
return rt;
}
static float64ToBytes(value) {
if (value == null) dart.nullFailed(I[29], 219, 35, "value");
let rt = new DC.DC.new(8);
rt.setFloat64(0, value);
return rt;
}
static float64ArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 225, 45, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 8);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setFloat64(i * 8, value[S$.$_get](i));
return rt;
}
static dateTimeToBytes(value) {
if (value == null) dart.nullFailed(I[29], 231, 38, "value");
let rt = new DC.DC.new(8);
rt.setDateTime(0, value);
return rt;
}
static dateTimeArrayToBytes(value) {
if (value == null) dart.nullFailed(I[29], 237, 49, "value");
let rt = new DC.DC.new(dart.notNull(value[S$.$length]) * 8);
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1)
rt.setDateTime(i * 8, value[S$.$_get](i));
return rt;
}
static stringToBytes(value) {
if (value == null) dart.nullFailed(I[29], 243, 34, "value");
let bytes = convert.utf8.encode(value);
let rt = new DC.DC.fromList(bytes);
return rt;
}
append(src, offset, length) {
if (src == null) dart.nullFailed(I[29], 249, 16, "src");
if (offset == null) dart.nullFailed(I[29], 249, 25, "offset");
if (length == null) dart.nullFailed(I[29], 249, 37, "length");
let appendix = src.clip(offset, length);
let rt = new DC.DC.new(dart.notNull(this.length) + dart.notNull(appendix.length));
rt.set(this, 0, 0, this.length);
rt.set(appendix, 0, this.length, appendix.length);
this[S$._data] = rt[S$._data];
this[S$._dv] = rt[S$._dv];
return this;
}
set(src, srcOffset, dstOffset, length) {
if (src == null) dart.nullFailed(I[29], 264, 15, "src");
if (srcOffset == null) dart.nullFailed(I[29], 264, 24, "srcOffset");
if (dstOffset == null) dart.nullFailed(I[29], 264, 39, "dstOffset");
if (length == null) dart.nullFailed(I[29], 264, 54, "length");
this[S$._data][S$.$setRange](dstOffset, dart.notNull(dstOffset) + dart.notNull(length), src[S$._data], srcOffset);
}
static combine(a, aOffset, aLength, b, bOffset, bLength) {
if (aOffset == null) dart.nullFailed(I[29], 268, 28, "aOffset");
if (aLength == null) dart.nullFailed(I[29], 268, 41, "aLength");
if (bOffset == null) dart.nullFailed(I[29], 268, 57, "bOffset");
if (bLength == null) dart.nullFailed(I[29], 268, 70, "bLength");
if (!DC.DC.is(a)) a = new DC.DC.fromList(T$.ListOfint().as(a));
if (!DC.DC.is(b)) b = new DC.DC.fromList(T$.ListOfint().as(b));
a = a.clip(aOffset, aLength);
b = b.clip(bOffset, bLength);
let rt = new DC.DC.new(dart.notNull(a.length) + dart.notNull(b.length));
rt.set(a, 0, 0, a.length);
rt.set(b, 0, a.length, b.length);
return rt;
}
clip(offset, length) {
if (offset == null) dart.nullFailed(I[29], 282, 15, "offset");
if (length == null) dart.nullFailed(I[29], 282, 27, "length");
return new DC.DC.fromUint8Array(_native_typed_data.NativeUint8List.fromList(this[S$._data][S$.$getRange](offset, dart.notNull(offset) + dart.notNull(length))[S$.$toList]()));
}
getInt8(offset) {
if (offset == null) dart.nullFailed(I[29], 287, 19, "offset");
return this[S$._dv][S$.$getInt8](offset);
}
getUint8(offset) {
if (offset == null) dart.nullFailed(I[29], 291, 20, "offset");
return this[S$._data][S$.$_get](offset);
}
getInt16(offset, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 295, 20, "offset");
if (endian == null) dart.nullFailed(I[29], 295, 36, "endian");
return this[S$._dv][S$.$getInt16](offset, endian);
}
getUint16(offset, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 299, 21, "offset");
if (endian == null) dart.nullFailed(I[29], 299, 37, "endian");
return this[S$._dv][S$.$getUint16](offset, endian);
}
getInt32(offset, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 303, 20, "offset");
if (endian == null) dart.nullFailed(I[29], 303, 36, "endian");
return this[S$._dv][S$.$getInt32](offset, endian);
}
getUint32(offset, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 307, 21, "offset");
if (endian == null) dart.nullFailed(I[29], 307, 37, "endian");
return this[S$._dv][S$.$getUint32](offset, endian);
}
getFloat32(offset, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 311, 25, "offset");
if (endian == null) dart.nullFailed(I[29], 311, 41, "endian");
return this[S$._dv][S$.$getFloat32](offset, endian);
}
getFloat64(offset, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 315, 25, "offset");
if (endian == null) dart.nullFailed(I[29], 315, 41, "endian");
return this[S$._dv][S$.$getFloat64](offset, endian);
}
setInt8(offset, value) {
if (offset == null) dart.nullFailed(I[29], 319, 20, "offset");
if (value == null) dart.nullFailed(I[29], 319, 32, "value");
return this[S$._dv][S$.$setInt8](offset, value);
}
setUint8(offset, value) {
if (offset == null) dart.nullFailed(I[29], 323, 21, "offset");
if (value == null) dart.nullFailed(I[29], 323, 33, "value");
return this[S$._dv][S$.$setUint8](offset, value);
}
setInt16(offset, value, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 327, 21, "offset");
if (value == null) dart.nullFailed(I[29], 327, 33, "value");
if (endian == null) dart.nullFailed(I[29], 327, 48, "endian");
return this[S$._dv][S$.$setInt16](offset, value, endian);
}
setUint16(offset, value, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 331, 22, "offset");
if (value == null) dart.nullFailed(I[29], 331, 34, "value");
if (endian == null) dart.nullFailed(I[29], 331, 49, "endian");
return this[S$._dv][S$.$setUint16](offset, value, endian);
}
setInt32(offset, value, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 335, 21, "offset");
if (value == null) dart.nullFailed(I[29], 335, 33, "value");
if (endian == null) dart.nullFailed(I[29], 335, 48, "endian");
return this[S$._dv][S$.$setInt32](offset, value, endian);
}
setUint32(offset, value, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 339, 22, "offset");
if (value == null) dart.nullFailed(I[29], 339, 34, "value");
if (endian == null) dart.nullFailed(I[29], 339, 49, "endian");
return this[S$._dv][S$.$setUint32](offset, value, endian);
}
setFloat32(offset, value, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 343, 23, "offset");
if (value == null) dart.nullFailed(I[29], 343, 38, "value");
if (endian == null) dart.nullFailed(I[29], 343, 53, "endian");
return this[S$._dv][S$.$setFloat32](offset, value, endian);
}
setFloat64(offset, value, endian = C[55] || CT.C55) {
if (offset == null) dart.nullFailed(I[29], 347, 23, "offset");
if (value == null) dart.nullFailed(I[29], 347, 38, "value");
if (endian == null) dart.nullFailed(I[29], 347, 53, "endian");
return this[S$._dv][S$.$setFloat64](offset, value, endian);
}
getInt8Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 351, 29, "offset");
if (length == null) dart.nullFailed(I[29], 351, 41, "length");
return this[S$._data][S$.$buffer][S$.$asInt8List](offset, length);
}
getUint8Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 355, 31, "offset");
if (length == null) dart.nullFailed(I[29], 355, 43, "length");
return this[S$._data][S$.$buffer][S$.$asUint8List](offset, length);
}
getInt16Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 359, 31, "offset");
if (length == null) dart.nullFailed(I[29], 359, 43, "length");
return this[S$._data][S$.$buffer][S$.$asInt16List](offset, length);
}
getUint16Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 363, 33, "offset");
if (length == null) dart.nullFailed(I[29], 363, 45, "length");
return this[S$._data][S$.$buffer][S$.$asUint16List](offset, length);
}
getInt32Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 367, 31, "offset");
if (length == null) dart.nullFailed(I[29], 367, 43, "length");
return this[S$._data][S$.$buffer][S$.$asInt32List](offset, length);
}
getUint32Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 371, 33, "offset");
if (length == null) dart.nullFailed(I[29], 371, 45, "length");
return this[S$._data][S$.$buffer][S$.$asUint32List](offset, length);
}
getFloat32Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 375, 35, "offset");
if (length == null) dart.nullFailed(I[29], 375, 47, "length");
return this[S$._data][S$.$buffer][S$.$asFloat32List](offset, length);
}
getFloat64Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 379, 35, "offset");
if (length == null) dart.nullFailed(I[29], 379, 47, "length");
return this[S$._data][S$.$buffer][S$.$asFloat64List](offset, length);
}
getInt64Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 384, 21, "offset");
if (length == null) dart.nullFailed(I[29], 384, 33, "length");
if (true) {
let rt = T$.JSArrayOfint().of([]);
for (let i = offset; dart.notNull(i) < dart.notNull(length); i = dart.notNull(i) + 4)
rt[S$.$add](this.getInt64(offset));
return rt;
} else {
return this[S$._data][S$.$buffer][S$.$asInt64List](offset, length);
}
}
getUint64Array(offset, length) {
if (offset == null) dart.nullFailed(I[29], 395, 22, "offset");
if (length == null) dart.nullFailed(I[29], 395, 34, "length");
if (true) {
let rt = T$.JSArrayOfint().of([]);
for (let i = offset; dart.notNull(i) < dart.notNull(length); i = dart.notNull(i) + 4)
rt[S$.$add](this.getUint64(offset));
return rt;
} else {
return this[S$._data][S$.$buffer][S$.$asUint64List](offset, length);
}
}
getBoolean(offset) {
if (offset == null) dart.nullFailed(I[29], 405, 23, "offset");
return dart.notNull(this.getUint8(offset)) > 0;
}
setBoolean(offset, value) {
if (offset == null) dart.nullFailed(I[29], 409, 23, "offset");
if (value == null) dart.nullFailed(I[29], 409, 36, "value");
this.setUint8(offset, dart.test(value) ? 1 : 0);
}
getChar(offset) {
if (offset == null) dart.nullFailed(I[29], 413, 22, "offset");
return core.String.fromCharCode(this.getUint16(offset));
}
setChar(offset, value) {
if (offset == null) dart.nullFailed(I[29], 417, 20, "offset");
if (value == null) dart.nullFailed(I[29], 417, 32, "value");
this.setUint16(offset, value);
}
getHex(offset, length) {
if (offset == null) dart.nullFailed(I[29], 421, 21, "offset");
if (length == null) dart.nullFailed(I[29], 421, 33, "length");
let rt = "";
for (let i = offset; dart.notNull(i) < dart.notNull(offset) + dart.notNull(length); i = dart.notNull(i) + 1) {
let h = this[S$._data][S$.$_get](i)[S$.$toRadixString](16);
rt = rt + (h.length === 1 ? "0" + h : h);
}
return rt;
}
toArray() {
return this[S$._data];
}
getString(offset, length) {
if (offset == null) dart.nullFailed(I[29], 442, 24, "offset");
if (length == null) dart.nullFailed(I[29], 442, 36, "length");
let bytes = this.clip(offset, length)[S$._data];
let str = convert.utf8.decode(bytes);
return str;
}
getInt64(offset, endian = C[55] || CT.C55) {
let t16, t16$, t16$0, t16$1, t16$2, t16$3, t16$4, t16$5, t16$6, t16$7, t16$8, t16$9, t16$10, t16$11, t16$12, t16$13;
if (offset == null) dart.nullFailed(I[29], 448, 20, "offset");
if (endian == null) dart.nullFailed(I[29], 448, 36, "endian");
if (true) {
if (dart.equals(endian, typed_data.Endian.big)) {
let bi = core._BigIntImpl.from(0);
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16 = offset, offset = dart.notNull(t16) + 1, t16)))['<<'](56));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$ = offset, offset = dart.notNull(t16$) + 1, t16$)))['<<'](48));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$0 = offset, offset = dart.notNull(t16$0) + 1, t16$0)))['<<'](40));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$1 = offset, offset = dart.notNull(t16$1) + 1, t16$1)))['<<'](32));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$2 = offset, offset = dart.notNull(t16$2) + 1, t16$2)))['<<'](24));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$3 = offset, offset = dart.notNull(t16$3) + 1, t16$3)))['<<'](16));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$4 = offset, offset = dart.notNull(t16$4) + 1, t16$4)))['<<'](8));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$5 = offset, offset = dart.notNull(t16$5) + 1, t16$5))));
return bi.toInt();
} else {
let bi = core._BigIntImpl.from(0);
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$6 = offset, offset = dart.notNull(t16$6) + 1, t16$6))));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$7 = offset, offset = dart.notNull(t16$7) + 1, t16$7)))['<<'](8));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$8 = offset, offset = dart.notNull(t16$8) + 1, t16$8)))['<<'](16));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$9 = offset, offset = dart.notNull(t16$9) + 1, t16$9)))['<<'](24));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$10 = offset, offset = dart.notNull(t16$10) + 1, t16$10)))['<<'](32));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$11 = offset, offset = dart.notNull(t16$11) + 1, t16$11)))['<<'](40));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$12 = offset, offset = dart.notNull(t16$12) + 1, t16$12)))['<<'](48));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$13 = offset, offset = dart.notNull(t16$13) + 1, t16$13)))['<<'](56));
return bi.toInt();
}
} else {
return this[S$._dv][S$.$getUint64](offset);
}
}
getUint64(offset, endian = C[55] || CT.C55) {
let t16, t16$, t16$0, t16$1, t16$2, t16$3, t16$4, t16$5, t16$6, t16$7, t16$8, t16$9, t16$10, t16$11, t16$12, t16$13;
if (offset == null) dart.nullFailed(I[29], 486, 21, "offset");
if (endian == null) dart.nullFailed(I[29], 486, 37, "endian");
if (true) {
if (dart.equals(endian, typed_data.Endian.big)) {
let bi = core._BigIntImpl.from(0);
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16 = offset, offset = dart.notNull(t16) + 1, t16)))['<<'](56));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$ = offset, offset = dart.notNull(t16$) + 1, t16$)))['<<'](48));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$0 = offset, offset = dart.notNull(t16$0) + 1, t16$0)))['<<'](40));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$1 = offset, offset = dart.notNull(t16$1) + 1, t16$1)))['<<'](32));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$2 = offset, offset = dart.notNull(t16$2) + 1, t16$2)))['<<'](24));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$3 = offset, offset = dart.notNull(t16$3) + 1, t16$3)))['<<'](16));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$4 = offset, offset = dart.notNull(t16$4) + 1, t16$4)))['<<'](8));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$5 = offset, offset = dart.notNull(t16$5) + 1, t16$5))));
return bi.toInt();
} else {
let bi = core._BigIntImpl.from(0);
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$6 = offset, offset = dart.notNull(t16$6) + 1, t16$6))));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$7 = offset, offset = dart.notNull(t16$7) + 1, t16$7)))['<<'](8));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$8 = offset, offset = dart.notNull(t16$8) + 1, t16$8)))['<<'](16));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$9 = offset, offset = dart.notNull(t16$9) + 1, t16$9)))['<<'](24));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$10 = offset, offset = dart.notNull(t16$10) + 1, t16$10)))['<<'](32));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$11 = offset, offset = dart.notNull(t16$11) + 1, t16$11)))['<<'](40));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$12 = offset, offset = dart.notNull(t16$12) + 1, t16$12)))['<<'](48));
bi = bi['|'](core._BigIntImpl.from(this.getUint8((t16$13 = offset, offset = dart.notNull(t16$13) + 1, t16$13)))['<<'](56));
return bi.toInt();
}
} else {
return this[S$._dv][S$.$getUint64](offset);
}
}
setInt64(offset, value, endian = C[55] || CT.C55) {
let t16, t16$, t16$0, t16$1, t16$2, t16$3, t16$4, t16$5, t16$6, t16$7, t16$8, t16$9, t16$10, t16$11, t16$12, t16$13;
if (offset == null) dart.nullFailed(I[29], 532, 21, "offset");
if (value == null) dart.nullFailed(I[29], 532, 33, "value");
if (endian == null) dart.nullFailed(I[29], 532, 48, "endian");
if (true) {
let bi = core._BigIntImpl.from(value);
let byte = core._BigIntImpl.from(255);
if (dart.equals(endian, typed_data.Endian.big)) {
this[S$._dv][S$.$setUint8]((t16 = offset, offset = dart.notNull(t16) + 1, t16), bi['>>'](56)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$ = offset, offset = dart.notNull(t16$) + 1, t16$), bi['>>'](48)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$0 = offset, offset = dart.notNull(t16$0) + 1, t16$0), bi['>>'](40)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$1 = offset, offset = dart.notNull(t16$1) + 1, t16$1), bi['>>'](32)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$2 = offset, offset = dart.notNull(t16$2) + 1, t16$2), bi['>>'](24)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$3 = offset, offset = dart.notNull(t16$3) + 1, t16$3), bi['>>'](16)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$4 = offset, offset = dart.notNull(t16$4) + 1, t16$4), bi['>>'](8)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$5 = offset, offset = dart.notNull(t16$5) + 1, t16$5), bi['&'](byte).toInt());
} else {
this[S$._dv][S$.$setUint8]((t16$6 = offset, offset = dart.notNull(t16$6) + 1, t16$6), bi['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$7 = offset, offset = dart.notNull(t16$7) + 1, t16$7), bi['>>'](8)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$8 = offset, offset = dart.notNull(t16$8) + 1, t16$8), bi['>>'](16)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$9 = offset, offset = dart.notNull(t16$9) + 1, t16$9), bi['>>'](24)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$10 = offset, offset = dart.notNull(t16$10) + 1, t16$10), bi['>>'](32)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$11 = offset, offset = dart.notNull(t16$11) + 1, t16$11), bi['>>'](40)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$12 = offset, offset = dart.notNull(t16$12) + 1, t16$12), bi['>>'](48)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$13 = offset, offset = dart.notNull(t16$13) + 1, t16$13), bi['>>'](56)['&'](byte).toInt());
}
} else {
this[S$._dv][S$.$setInt64](offset, value, endian);
}
}
setUint64(offset, value, endian = C[55] || CT.C55) {
let t16, t16$, t16$0, t16$1, t16$2, t16$3, t16$4, t16$5, t16$6, t16$7, t16$8, t16$9, t16$10, t16$11, t16$12, t16$13;
if (offset == null) dart.nullFailed(I[29], 561, 22, "offset");
if (value == null) dart.nullFailed(I[29], 561, 34, "value");
if (endian == null) dart.nullFailed(I[29], 561, 49, "endian");
if (true) {
let bi = core._BigIntImpl.from(value);
let byte = core._BigIntImpl.from(255);
if (dart.equals(endian, typed_data.Endian.big)) {
this[S$._dv][S$.$setUint8]((t16 = offset, offset = dart.notNull(t16) + 1, t16), bi['>>'](56)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$ = offset, offset = dart.notNull(t16$) + 1, t16$), bi['>>'](48)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$0 = offset, offset = dart.notNull(t16$0) + 1, t16$0), bi['>>'](40)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$1 = offset, offset = dart.notNull(t16$1) + 1, t16$1), bi['>>'](32)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$2 = offset, offset = dart.notNull(t16$2) + 1, t16$2), bi['>>'](24)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$3 = offset, offset = dart.notNull(t16$3) + 1, t16$3), bi['>>'](16)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$4 = offset, offset = dart.notNull(t16$4) + 1, t16$4), bi['>>'](8)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$5 = offset, offset = dart.notNull(t16$5) + 1, t16$5), bi['&'](byte).toInt());
} else {
this[S$._dv][S$.$setUint8]((t16$6 = offset, offset = dart.notNull(t16$6) + 1, t16$6), bi['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$7 = offset, offset = dart.notNull(t16$7) + 1, t16$7), bi['>>'](8)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$8 = offset, offset = dart.notNull(t16$8) + 1, t16$8), bi['>>'](16)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$9 = offset, offset = dart.notNull(t16$9) + 1, t16$9), bi['>>'](24)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$10 = offset, offset = dart.notNull(t16$10) + 1, t16$10), bi['>>'](32)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$11 = offset, offset = dart.notNull(t16$11) + 1, t16$11), bi['>>'](40)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$12 = offset, offset = dart.notNull(t16$12) + 1, t16$12), bi['>>'](48)['&'](byte).toInt());
this[S$._dv][S$.$setUint8]((t16$13 = offset, offset = dart.notNull(t16$13) + 1, t16$13), bi['>>'](56)['&'](byte).toInt());
}
} else {
this[S$._dv][S$.$setUint64](offset, value, endian);
}
}
setDateTime(offset, value) {
if (offset == null) dart.nullFailed(I[29], 599, 24, "offset");
if (value == null) dart.nullFailed(I[29], 599, 41, "value");
let ticks = 621355968000000000.0 + dart.notNull(value.millisecondsSinceEpoch) * 10000;
this.setUint64(offset, ticks);
}
getDateTime(offset) {
if (offset == null) dart.nullFailed(I[29], 605, 28, "offset");
let ticks = this.getUint64(offset);
return new core.DateTime.fromMillisecondsSinceEpoch(((dart.notNull(ticks) - 621355968000000000.0) / 10000)[S$.$truncate]());
}
getGuid(offset) {
if (offset == null) dart.nullFailed(I[29], 611, 20, "offset");
return new Guid.Guid.new(this.clip(offset, 16));
}
setGuid(offset, guid) {
if (offset == null) dart.nullFailed(I[29], 615, 20, "offset");
if (guid == null) dart.nullFailed(I[29], 615, 33, "guid");
this.set(guid.value, 0, offset, 16);
}
sequenceEqual(ar) {
if (!dart.equals(dart.dload(ar, 'length'), this.length))
return false;
else {
for (let i = 0; i < dart.notNull(this.length); i = i + 1)
if (!dart.equals(dart.dsend(ar, '_get', [i]), this._get(i))) return false;
}
return true;
}
getStringArray(offset, length) {
if (offset == null) dart.nullFailed(I[29], 629, 35, "offset");
if (length == null) dart.nullFailed(I[29], 629, 47, "length");
let rt = T$.JSArrayOfString().of([]);
let i = 0;
while (i < dart.notNull(length)) {
let cl = this.getUint32(dart.notNull(offset) + i);
i = i + 4;
rt[S$.$add](this.getString(dart.notNull(offset) + i, cl));
i = i + dart.notNull(cl);
}
return rt;
}
static stringArrayToBytes(value) {
let t16;
if (value == null) dart.nullFailed(I[29], 643, 45, "value");
let list = new BinaryList.BinaryList.new();
for (let i = 0; i < dart.notNull(value[S$.$length]); i = i + 1) {
let s = DC.DC.stringToBytes(value[S$.$_get](i));
t16 = list;
(() => {
t16.addUint32(s.length);
t16.addUint8Array(s.toArray());
return t16;
})();
}
return list.toDC();
}
};
(DC.DC.new = function(length) {
if (length == null) dart.nullFailed(I[29], 42, 10, "length");
this[S$.__DC__data] = null;
this[S$.__DC__data_isSet] = false;
this[S$.__DC__dv] = null;
this[S$.__DC__dv_isSet] = false;
this[S$._data] = _native_typed_data.NativeUint8List.new(length);
this[S$._dv] = typed_data.ByteData.view(this[S$._data][S$.$buffer]);
}).prototype = DC.DC.prototype;
(DC.DC.fromUint8Array = function(array) {
if (array == null) dart.nullFailed(I[29], 47, 31, "array");
this[S$.__DC__data] = null;
this[S$.__DC__data_isSet] = false;
this[S$.__DC__dv] = null;
this[S$.__DC__dv_isSet] = false;
this[S$._data] = array;
this[S$._dv] = typed_data.ByteData.view(this[S$._data][S$.$buffer]);
}).prototype = DC.DC.prototype;
(DC.DC.fromList = function(list) {
if (list == null) dart.nullFailed(I[29], 52, 25, "list");
this[S$.__DC__data] = null;
this[S$.__DC__data_isSet] = false;
this[S$.__DC__dv] = null;
this[S$.__DC__dv_isSet] = false;
this[S$._data] = _native_typed_data.NativeUint8List.fromList(list);
this[S$._dv] = typed_data.ByteData.view(this[S$._data][S$.$buffer]);
}).prototype = DC.DC.prototype;
(DC.DC.fromHex = function(hex, separator = " ") {
if (hex == null) dart.nullFailed(I[29], 72, 21, "hex");
if (separator == null) dart.nullFailed(I[29], 72, 34, "separator");
this[S$.__DC__data] = null;
this[S$.__DC__data_isSet] = false;
this[S$.__DC__dv] = null;
this[S$.__DC__dv_isSet] = false;
let list = hex[S$.$split](separator)[S$.$map](core.int, dart.fn(e => {
if (e == null) dart.nullFailed(I[29], 74, 35, "e");
return core.int.parse(e, {radix: 16});
}, T$.StringToint()))[S$.$toList]();
this[S$._data] = _native_typed_data.NativeUint8List.fromList(list);
this[S$._dv] = typed_data.ByteData.view(this[S$._data][S$.$buffer]);
}).prototype = DC.DC.prototype;
dart.addTypeTests(DC.DC);
dart.addTypeCaches(DC.DC);
dart.setMethodSignature(DC.DC, () => ({
__proto__: dart.getMethods(DC.DC.__proto__),
toHex: dart.fnType(core.String, [], [core.String, dart.nullable(core.int), dart.nullable(core.int)]),
_get: dart.fnType(core.int, [core.int]),
_set: dart.fnType(dart.void, [core.int, core.int]),
append: dart.fnType(DC.DC, [DC.DC, core.int, core.int]),
set: dart.fnType(dart.void, [DC.DC, core.int, core.int, core.int]),
clip: dart.fnType(DC.DC, [core.int, core.int]),
getInt8: dart.fnType(core.int, [core.int]),
getUint8: dart.fnType(core.int, [core.int]),
getInt16: dart.fnType(core.int, [core.int], [typed_data.Endian]),
getUint16: dart.fnType(core.int, [core.int], [typed_data.Endian]),
getInt32: dart.fnType(core.int, [core.int], [typed_data.Endian]),
getUint32: dart.fnType(core.int, [core.int], [typed_data.Endian]),
getFloat32: dart.fnType(core.double, [core.int], [typed_data.Endian]),
getFloat64: dart.fnType(core.double, [core.int], [typed_data.Endian]),
setInt8: dart.fnType(dart.void, [core.int, core.int]),
setUint8: dart.fnType(dart.void, [core.int, core.int]),
setInt16: dart.fnType(dart.void, [core.int, core.int], [typed_data.Endian]),
setUint16: dart.fnType(dart.void, [core.int, core.int], [typed_data.Endian]),
setInt32: dart.fnType(dart.void, [core.int, core.int], [typed_data.Endian]),
setUint32: dart.fnType(dart.void, [core.int, core.int], [typed_data.Endian]),
setFloat32: dart.fnType(dart.void, [core.int, core.double], [typed_data.Endian]),
setFloat64: dart.fnType(dart.void, [core.int, core.double], [typed_data.Endian]),
getInt8Array: dart.fnType(typed_data.Int8List, [core.int, core.int]),
getUint8Array: dart.fnType(typed_data.Uint8List, [core.int, core.int]),
getInt16Array: dart.fnType(typed_data.Int16List, [core.int, core.int]),
getUint16Array: dart.fnType(typed_data.Uint16List, [core.int, core.int]),
getInt32Array: dart.fnType(typed_data.Int32List, [core.int, core.int]),
getUint32Array: dart.fnType(typed_data.Uint32List, [core.int, core.int]),
getFloat32Array: dart.fnType(typed_data.Float32List, [core.int, core.int]),
getFloat64Array: dart.fnType(typed_data.Float64List, [core.int, core.int]),
getInt64Array: dart.fnType(dart.dynamic, [core.int, core.int]),
getUint64Array: dart.fnType(dart.dynamic, [core.int, core.int]),
getBoolean: dart.fnType(core.bool, [core.int]),
setBoolean: dart.fnType(dart.void, [core.int, core.bool]),
getChar: dart.fnType(core.String, [core.int]),
setChar: dart.fnType(dart.void, [core.int, core.int]),
getHex: dart.fnType(core.String, [core.int, core.int]),
toArray: dart.fnType(typed_data.Uint8List, []),
getString: dart.fnType(core.String, [core.int, core.int]),
getInt64: dart.fnType(core.int, [core.int], [typed_data.Endian]),
getUint64: dart.fnType(core.int, [core.int], [typed_data.Endian]),
setInt64: dart.fnType(dart.void, [core.int, core.int], [typed_data.Endian]),
setUint64: dart.fnType(dart.void, [core.int, core.int], [typed_data.Endian]),
setDateTime: dart.fnType(dart.void, [core.int, core.DateTime]),
getDateTime: dart.fnType(core.DateTime, [core.int]),
getGuid: dart.fnType(Guid.Guid, [core.int]),
setGuid: dart.fnType(dart.void, [core.int, Guid.Guid]),
sequenceEqual: dart.fnType(core.bool, [dart.dynamic]),
getStringArray: dart.fnType(core.List$(core.String), [core.int, core.int])
}));
dart.setStaticMethodSignature(DC.DC, () => ['hexToBytes', 'boolToBytes', 'guidToBytes', 'int8ToBytes', 'int8ArrayToBytes', 'uint8ToBytes', 'uint8ArrayToBytes', 'charToBytes', 'int16ToBytes', 'int16ArrayToBytes', 'uint16ToBytes', 'uint16ArrayToBytes', 'int32ToBytes', 'int32ArrayToBytes', 'uint32ToBytes', 'uint32ArrayToBytes', 'float32ToBytes', 'float32ArrayToBytes', 'int64ToBytes', 'int64ArrayToBytes', 'uint64ToBytes', 'uint64ArrayToBytes', 'float64ToBytes', 'float64ArrayToBytes', 'dateTimeToBytes', 'dateTimeArrayToBytes', 'stringToBytes', 'combine', 'stringArrayToBytes']);
dart.setGetterSignature(DC.DC, () => ({
__proto__: dart.getGetters(DC.DC.__proto__),
[S$._data]: typed_data.Uint8List,
[S$._dv]: typed_data.ByteData,
iterator: core.Iterator$(core.int),
[S$.$iterator]: core.Iterator$(core.int)
}));
dart.setSetterSignature(DC.DC, () => ({
__proto__: dart.getSetters(DC.DC.__proto__),
[S$._data]: typed_data.Uint8List,
[S$._dv]: typed_data.ByteData
}));
dart.setLibraryUri(DC.DC, I[29]);
dart.setFieldSignature(DC.DC, () => ({
__proto__: dart.getFields(DC.DC.__proto__),
[S$.__DC__data]: dart.fieldType(dart.nullable(typed_data.Uint8List)),
[S$.__DC__data_isSet]: dart.fieldType(core.bool),
[S$.__DC__dv]: dart.fieldType(dart.nullable(typed_data.ByteData)),
[S$.__DC__dv_isSet]: dart.fieldType(core.bool)
}));
dart.defineExtensionAccessors(DC.DC, ['length', 'iterator']);
dart.defineLazy(DC, {
/*DC.kIsWeb*/get kIsWeb() {
return true;
},
/*DC.UNIX_EPOCH*/get UNIX_EPOCH() {
return 621355968000000000.0;
},
/*DC.TWO_PWR_32*/get TWO_PWR_32() {
return 4294967296.0;
}
}, false);
Guid.Guid = class Guid$ extends core.Object {
get [S$._data$1]() {
let t16;
return dart.test(this[S$.__Guid__data_isSet]) ? (t16 = this[S$.__Guid__data], t16) : dart.throw(new _internal.LateError.fieldNI("_data"));
}
set [S$._data$1](t16) {
if (t16 == null) dart.nullFailed(I[30], 4, 11, "null");
this[S$.__Guid__data_isSet] = true;
this[S$.__Guid__data] = t16;
}
static ['_#new#tearOff'](_data) {
if (_data == null) dart.nullFailed(I[30], 6, 13, "_data");
return new Guid.Guid.new(_data);
}
static ['_#fromString#tearOff'](data) {
if (data == null) dart.nullFailed(I[30], 8, 26, "data");
return new Guid.Guid.fromString(data);
}
get value() {
return this[S$._data$1];
}
_equals(other) {
if (other == null) return false;
if (Guid.Guid.is(other))
return this[S$._data$1].sequenceEqual(other[S$._data$1]);
else
return false;
}
toString() {
return this[S$._data$1].toHex("");
}
get hashCode() {
return dart.hashCode(dart.toString(this[S$._data$1]));
}
};
(Guid.Guid.new = function(_data) {
if (_data == null) dart.nullFailed(I[30], 6, 13, "_data");
this[S$.__Guid__data] = null;
this[S$.__Guid__data_isSet] = false;
this[S$.__Guid__data_isSet] = true;
this[S$.__Guid__data] = _data;
}).prototype = Guid.Guid.prototype;
(Guid.Guid.fromString = function(data) {
if (data == null) dart.nullFailed(I[30], 8, 26, "data");
this[S$.__Guid__data] = null;
this[S$.__Guid__data_isSet] = false;
this[S$._data$1] = new DC.DC.fromHex(data, "");
}).prototype = Guid.Guid.prototype;
dart.addTypeTests(Guid.Guid);
dart.addTypeCaches(Guid.Guid);
dart.setGetterSignature(Guid.Guid, () => ({
__proto__: dart.getGetters(Guid.Guid.__proto__),
[S$._data$1]: DC.DC,
value: DC.DC
}));
dart.setSetterSignature(Guid.Guid, () => ({
__proto__: dart.getSetters(Guid.Guid.__proto__),
[S$._data$1]: DC.DC
}));
dart.setLibraryUri(Guid.Guid, I[30]);
dart.setFieldSignature(Guid.Guid, () => ({
__proto__: dart.getFields(Guid.Guid.__proto__),
[S$.__Guid__data]: dart.fieldType(dart.nullable(DC.DC)),
[S$.__Guid__data_isSet]: dart.fieldType(core.bool)
}));
dart.defineExtensionMethods(Guid.Guid, ['_equals', 'toString']);
dart.defineExtensionAccessors(Guid.Guid, ['hashCode']);
const _is_KeyList_default = Symbol('_is_KeyList_default');
KeyList$.KeyList$ = dart.generic((KT, T) => {
var __t$LinkedMapOfKT$T = () => (__t$LinkedMapOfKT$T = dart.constFn(_js_helper.LinkedMap$(KT, T)))();
var __t$JSArrayOfKT = () => (__t$JSArrayOfKT = dart.constFn(_interceptors.JSArray$(KT)))();
const IEventHandler_MapMixin$36 = class IEventHandler_MapMixin extends IEventHandler.IEventHandler {};
(IEventHandler_MapMixin$36.new = function() {
IEventHandler_MapMixin$36.__proto__.new.call(this);
}).prototype = IEventHandler_MapMixin$36.prototype;
dart.applyMixin(IEventHandler_MapMixin$36, collection.MapMixin$(KT, T));
class KeyList extends IEventHandler_MapMixin$36 {
get owner() {
return this[S$.owner];
}
set owner(value) {
this[S$.owner] = value;
}
get iterator() {
return this[S$._map][S$.$keys][S$.$iterator];
}
get keys() {
return this[S$._map][S$.$keys];
}
get values() {
return this[S$._map][S$.$values];
}
_get(index) {
return this[S$._map][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
KT.as(index);
T.as(value);
this.add(index, value);
return value$;
}
at(index) {
if (index == null) dart.nullFailed(I[31], 47, 10, "index");
return this[S$._map][S$.$values][S$.$elementAt](index);
}
get [S$._removableList$1]() {
let t17;
return dart.test(this[S$.__KeyList__removableList_isSet]) ? (t17 = this[S$.__KeyList__removableList], t17) : dart.throw(new _internal.LateError.fieldNI("_removableList"));
}
set [S$._removableList$1](t17) {
if (t17 == null) dart.nullFailed(I[31], 49, 13, "null");
this[S$.__KeyList__removableList_isSet] = true;
this[S$.__KeyList__removableList] = t17;
}
take(key) {
KT.as(key);
if (dart.test(this[S$._map][S$.$containsKey](key))) {
let v = this[S$._map][S$.$_get](key);
this.remove(key);
return v;
} else
return null;
}
toArray() {
return this[S$._map][S$.$values][S$.$toList]();
}
add(key, value) {
KT.as(key);
T.as(value);
if (dart.test(this[S$._removableList$1])) if (value != null) IDestructible.IDestructible.as(value).on("destroy", dart.bind(this, S$._itemDestroyed$1));
if (dart.test(this[S$._map][S$.$containsKey](key))) {
let oldValue = this[S$._map][S$.$_get](key);
if (dart.test(this[S$._removableList$1])) if (oldValue != null) IDestructible.IDestructible.as(oldValue).off("destroy", dart.bind(this, S$._itemDestroyed$1));
this[S$._map][S$.$_set](key, value);
this.emitArgs("modified", [key, oldValue, value, this]);
} else {
this[S$._map][S$.$_set](key, value);
this.emitArgs("add", [value, this]);
}
}
[S$._itemDestroyed$1](sender) {
T.as(sender);
this.removeValue(sender);
}
removeValue(value) {
T.as(value);
let toRemove = __t$JSArrayOfKT().of([]);
for (let k of this[S$._map][S$.$keys])
if (dart.equals(this[S$._map][S$.$_get](k), value)) toRemove[S$.$add](k);
for (let k of toRemove)
this.remove(k);
}
clear() {
if (dart.test(this[S$._removableList$1])) for (let v of this[S$._map][S$.$values])
IDestructible.IDestructible.as(v).off("destroy", dart.bind(this, S$._itemDestroyed$1));
this[S$._map][S$.$clear]();
this.emitArgs("cleared", [this]);
}
remove(key) {
if (!dart.test(this[S$._map][S$.$containsKey](key))) return null;
let value = this[S$._map][S$.$_get](key);
if (dart.test(this[S$._removableList$1])) IDestructible.IDestructible.as(value).off("destroy", dart.bind(this, S$._itemDestroyed$1));
this[S$._map][S$.$remove](key);
this.emitArgs("removed", [key, value, this]);
return value;
}
get count() {
return this[S$._map][S$.$length];
}
contains(key) {
KT.as(key);
return this[S$._map][S$.$containsKey](key);
}
static ['_#new#tearOff'](KT, T, owner = null) {
return new (KeyList$.KeyList$(KT, T)).new(owner);
}
}
(KeyList.new = function(owner = null) {
this[S$.owner] = null;
this[S$._map] = new (__t$LinkedMapOfKT$T()).new();
this[S$.__KeyList__removableList] = null;
this[S$.__KeyList__removableList_isSet] = false;
KeyList.__proto__.new.call(this);
this[S$._removableList$1] = Codec.Codec.implementsInterface(T, IDestructible.IDestructible);
this.owner = owner;
}).prototype = KeyList.prototype;
dart.addTypeTests(KeyList);
KeyList.prototype[_is_KeyList_default] = true;
dart.addTypeCaches(KeyList);
dart.setMethodSignature(KeyList, () => ({
__proto__: dart.getMethods(KeyList.__proto__),
_get: dart.fnType(dart.nullable(T), [dart.nullable(core.Object)]),
[S$.$_get]: dart.fnType(dart.nullable(T), [dart.nullable(core.Object)]),
_set: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
at: dart.fnType(dart.dynamic, [core.int]),
take: dart.fnType(dart.nullable(T), [dart.nullable(core.Object)]),
toArray: dart.fnType(core.List$(T), []),
add: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$._itemDestroyed$1]: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
removeValue: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, []),
remove: dart.fnType(dart.nullable(T), [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(dart.nullable(T), [dart.nullable(core.Object)]),
contains: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setGetterSignature(KeyList, () => ({
__proto__: dart.getGetters(KeyList.__proto__),
iterator: core.Iterator$(KT),
keys: core.Iterable$(KT),
[S$.$keys]: core.Iterable$(KT),
[S$._removableList$1]: core.bool,
count: core.int
}));
dart.setSetterSignature(KeyList, () => ({
__proto__: dart.getSetters(KeyList.__proto__),
[S$._removableList$1]: core.bool
}));
dart.setLibraryUri(KeyList, I[31]);
dart.setFieldSignature(KeyList, () => ({
__proto__: dart.getFields(KeyList.__proto__),
owner: dart.fieldType(dart.dynamic),
[S$._map]: dart.fieldType(core.Map$(KT, T)),
[S$.__KeyList__removableList]: dart.fieldType(dart.nullable(core.bool)),
[S$.__KeyList__removableList_isSet]: dart.fieldType(core.bool)
}));
dart.defineExtensionMethods(KeyList, ['_get', '_set', 'clear', 'remove']);
dart.defineExtensionAccessors(KeyList, ['keys', 'values']);
return KeyList;
});
KeyList$.KeyList = KeyList$.KeyList$();
dart.addTypeTests(KeyList$.KeyList, _is_KeyList_default);
NotModified.NotModified = class NotModified$ extends core.Object {
static ['_#new#tearOff']() {
return new NotModified.NotModified.new();
}
};
(NotModified.NotModified.new = function() {
;
}).prototype = NotModified.NotModified.prototype;
dart.addTypeTests(NotModified.NotModified);
dart.addTypeCaches(NotModified.NotModified);
dart.setLibraryUri(NotModified.NotModified, I[32]);
PropertyValue.PropertyValue = class PropertyValue$ extends core.Object {
get value() {
return this[S$.value$1];
}
set value(value) {
this[S$.value$1] = value;
}
get date() {
return this[S$.date];
}
set date(value) {
this[S$.date] = value;
}
get age() {
return this[S$.age];
}
set age(value) {
this[S$.age] = value;
}
static ['_#new#tearOff'](value, age, date) {
if (age == null) dart.nullFailed(I[33], 22, 36, "age");
if (date == null) dart.nullFailed(I[33], 22, 46, "date");
return new PropertyValue.PropertyValue.new(value, age, date);
}
};
(PropertyValue.PropertyValue.new = function(value, age, date) {
if (age == null) dart.nullFailed(I[33], 22, 36, "age");
if (date == null) dart.nullFailed(I[33], 22, 46, "date");
this[S$.value$1] = value;
this[S$.age] = age;
this[S$.date] = date;
;
}).prototype = PropertyValue.PropertyValue.prototype;
dart.addTypeTests(PropertyValue.PropertyValue);
dart.addTypeCaches(PropertyValue.PropertyValue);
dart.setLibraryUri(PropertyValue.PropertyValue, I[33]);
dart.setFieldSignature(PropertyValue.PropertyValue, () => ({
__proto__: dart.getFields(PropertyValue.PropertyValue.__proto__),
value: dart.fieldType(dart.dynamic),
date: dart.fieldType(core.DateTime),
age: dart.fieldType(core.int)
}));
SizeObject.SizeObject = class SizeObject$ extends core.Object {
get size() {
return this[S$.size$2];
}
set size(value) {
this[S$.size$2] = value;
}
static ['_#new#tearOff']() {
return new SizeObject.SizeObject.new();
}
};
(SizeObject.SizeObject.new = function() {
this[S$.size$2] = 0;
;
}).prototype = SizeObject.SizeObject.prototype;
dart.addTypeTests(SizeObject.SizeObject);
dart.addTypeCaches(SizeObject.SizeObject);
dart.setLibraryUri(SizeObject.SizeObject, I[34]);
dart.setFieldSignature(SizeObject.SizeObject, () => ({
__proto__: dart.getFields(SizeObject.SizeObject.__proto__),
size: dart.fieldType(core.int)
}));
ValueObject.ValueObject = class ValueObject$ extends core.Object {
get value() {
return this[S$.value$2];
}
set value(value) {
this[S$.value$2] = value;
}
static ['_#new#tearOff']() {
return new ValueObject.ValueObject.new();
}
};
(ValueObject.ValueObject.new = function() {
this[S$.value$2] = null;
;
}).prototype = ValueObject.ValueObject.prototype;
dart.addTypeTests(ValueObject.ValueObject);
dart.addTypeCaches(ValueObject.ValueObject);
dart.setLibraryUri(ValueObject.ValueObject, I[35]);
dart.setFieldSignature(ValueObject.ValueObject, () => ({
__proto__: dart.getFields(ValueObject.ValueObject.__proto__),
value: dart.fieldType(dart.dynamic)
}));
IRecord.IRecord = class IRecord extends core.Object {
toString() {
return dart.toString(this.serialize());
}
};
(IRecord.IRecord.new = function() {
;
}).prototype = IRecord.IRecord.prototype;
dart.addTypeTests(IRecord.IRecord);
dart.addTypeCaches(IRecord.IRecord);
dart.setLibraryUri(IRecord.IRecord, I[36]);
dart.defineExtensionMethods(IRecord.IRecord, ['toString']);
const IRecord_MapMixin$36 = class IRecord_MapMixin extends IRecord.IRecord {};
(IRecord_MapMixin$36.new = function() {
}).prototype = IRecord_MapMixin$36.prototype;
dart.applyMixin(IRecord_MapMixin$36, collection.MapMixin$(core.String, dart.dynamic));
Record.Record = class Record$ extends IRecord_MapMixin$36 {
serialize() {
return this[S$._props];
}
deserialize(value) {
if (value == null) dart.nullFailed(I[37], 17, 36, "value");
this[S$._props] = value;
}
_get(index) {
return this[S$._props][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
let t20, t19, t18;
core.String.as(index);
if (index == null) dart.nullFailed(I[37], 22, 23, "index");
t18 = this[S$._props];
t19 = index;
t20 = value;
t18[S$.$_set](t19, t20);
t20;
return value$;
}
toString() {
return dart.toString(this[S$._props]);
}
get template() {
return dart.throw(new core.UnimplementedError.new());
}
clear() {
}
get keys() {
return this[S$._props][S$.$keys];
}
remove(key) {
dart.throw(new core.UnimplementedError.new());
}
static ['_#new#tearOff']() {
return new Record.Record.new();
}
};
(Record.Record.new = function() {
this[S$._props] = new (T$.LinkedMapOfString$dynamic()).new();
;
}).prototype = Record.Record.prototype;
dart.addTypeTests(Record.Record);
dart.addTypeCaches(Record.Record);
dart.setMethodSignature(Record.Record, () => ({
__proto__: dart.getMethods(Record.Record.__proto__),
serialize: dart.fnType(core.Map$(core.String, dart.dynamic), []),
deserialize: dart.fnType(dart.void, [core.Map$(core.String, dart.dynamic)]),
_get: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
[S$.$_get]: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
_set: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, []),
remove: dart.fnType(dart.dynamic, [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(dart.dynamic, [dart.nullable(core.Object)])
}));
dart.setGetterSignature(Record.Record, () => ({
__proto__: dart.getGetters(Record.Record.__proto__),
template: TemplateDescriber.TemplateDescriber,
keys: core.Iterable$(core.String),
[S$.$keys]: core.Iterable$(core.String)
}));
dart.setLibraryUri(Record.Record, I[37]);
dart.setFieldSignature(Record.Record, () => ({
__proto__: dart.getFields(Record.Record.__proto__),
[S$._props]: dart.fieldType(core.Map$(core.String, dart.dynamic))
}));
dart.defineExtensionMethods(Record.Record, [
'_get',
'_set',
'toString',
'clear',
'remove'
]);
dart.defineExtensionAccessors(Record.Record, ['keys']);
IEnum.IEnum = class IEnum$ extends core.Object {
get index() {
return this[S$.index$1];
}
set index(value) {
this[S$.index$1] = value;
}
get value() {
return this[S$.value$3];
}
set value(value) {
this[S$.value$3] = value;
}
get name() {
return this[S$.name$6];
}
set name(value) {
this[S$.name$6] = value;
}
static ['_#new#tearOff'](index = 0, value = null, name = "") {
if (index == null) dart.nullFailed(I[38], 7, 15, "index");
if (name == null) dart.nullFailed(I[38], 7, 43, "name");
return new IEnum.IEnum.new(index, value, name);
}
get template() {
return new TemplateDescriber.TemplateDescriber.new("IEnum");
}
toString() {
return dart.str(this.name) + "<" + dart.str(this.value) + ">";
}
};
(IEnum.IEnum.new = function(index = 0, value = null, name = "") {
if (index == null) dart.nullFailed(I[38], 7, 15, "index");
if (name == null) dart.nullFailed(I[38], 7, 43, "name");
this[S$.index$1] = 0;
this[S$.name$6] = "";
this[S$.index$1] = index;
this[S$.value$3] = value;
this[S$.name$6] = name;
;
}).prototype = IEnum.IEnum.prototype;
dart.addTypeTests(IEnum.IEnum);
dart.addTypeCaches(IEnum.IEnum);
dart.setGetterSignature(IEnum.IEnum, () => ({
__proto__: dart.getGetters(IEnum.IEnum.__proto__),
template: TemplateDescriber.TemplateDescriber
}));
dart.setLibraryUri(IEnum.IEnum, I[38]);
dart.setFieldSignature(IEnum.IEnum, () => ({
__proto__: dart.getFields(IEnum.IEnum.__proto__),
index: dart.fieldType(core.int),
value: dart.fieldType(dart.dynamic),
name: dart.fieldType(core.String)
}));
dart.defineExtensionMethods(IEnum.IEnum, ['toString']);
IntType.IntType = class IntType$ extends core.Object {
_equals(other) {
if (other == null) return false;
if (IntType.IntType.is(other))
return this[S$._value] == other[S$._value];
else if (core.int.is(other)) return this[S$._value] == other;
return false;
}
static ['_#new#tearOff'](_value) {
if (_value == null) dart.nullFailed(I[39], 12, 16, "_value");
return new IntType.IntType.new(_value);
}
['>'](other) {
if (other == null) dart.nullFailed(I[39], 14, 27, "other");
return dart.notNull(this[S$._value]) > dart.notNull(other[S$._value]);
}
['<'](other) {
if (other == null) dart.nullFailed(I[39], 18, 27, "other");
return dart.notNull(this[S$._value]) < dart.notNull(other[S$._value]);
}
['>='](other) {
if (other == null) dart.nullFailed(I[39], 22, 28, "other");
return dart.notNull(this[S$._value]) >= dart.notNull(other[S$._value]);
}
['<='](other) {
if (other == null) dart.nullFailed(I[39], 26, 28, "other");
return dart.notNull(this[S$._value]) <= dart.notNull(other[S$._value]);
}
['+'](other) {
if (other == null) dart.nullFailed(I[39], 30, 22, "other");
this[S$._value] = dart.notNull(this[S$._value]) + dart.notNull(other[S$._value]);
}
['-'](other) {
if (other == null) dart.nullFailed(I[39], 34, 22, "other");
this[S$._value] = dart.notNull(this[S$._value]) - dart.notNull(other[S$._value]);
}
toInt() {
return this[S$._value];
}
toString() {
return dart.toString(this[S$._value]);
}
get hashCode() {
return dart.hashCode(this[S$._value]);
}
};
(IntType.IntType.new = function(_value) {
if (_value == null) dart.nullFailed(I[39], 12, 16, "_value");
this[S$._value] = 0;
this[S$._value] = _value;
;
}).prototype = IntType.IntType.prototype;
dart.addTypeTests(IntType.IntType);
dart.addTypeCaches(IntType.IntType);
dart.setMethodSignature(IntType.IntType, () => ({
__proto__: dart.getMethods(IntType.IntType.__proto__),
'>': dart.fnType(core.bool, [IntType.IntType]),
'<': dart.fnType(core.bool, [IntType.IntType]),
'>=': dart.fnType(core.bool, [IntType.IntType]),
'<=': dart.fnType(core.bool, [IntType.IntType]),
'+': dart.fnType(dart.dynamic, [IntType.IntType]),
'-': dart.fnType(dart.dynamic, [IntType.IntType]),
toInt: dart.fnType(core.int, [])
}));
dart.setLibraryUri(IntType.IntType, I[39]);
dart.setFieldSignature(IntType.IntType, () => ({
__proto__: dart.getFields(IntType.IntType.__proto__),
[S$._value]: dart.fieldType(core.int)
}));
dart.defineExtensionMethods(IntType.IntType, ['_equals', 'toString']);
dart.defineExtensionAccessors(IntType.IntType, ['hashCode']);
IntType.Int32 = class Int32 extends IntType.IntType {
static ['_#new#tearOff'](value) {
if (value == null) dart.nullFailed(I[39], 48, 13, "value");
return new IntType.Int32.new(value);
}
};
(IntType.Int32.new = function(value) {
if (value == null) dart.nullFailed(I[39], 48, 13, "value");
IntType.Int32.__proto__.new.call(this, value);
;
}).prototype = IntType.Int32.prototype;
dart.addTypeTests(IntType.Int32);
dart.addTypeCaches(IntType.Int32);
dart.setLibraryUri(IntType.Int32, I[39]);
IntType.Int16 = class Int16 extends IntType.IntType {
static ['_#new#tearOff'](value) {
if (value == null) dart.nullFailed(I[39], 52, 13, "value");
return new IntType.Int16.new(value);
}
};
(IntType.Int16.new = function(value) {
if (value == null) dart.nullFailed(I[39], 52, 13, "value");
IntType.Int16.__proto__.new.call(this, value);
;
}).prototype = IntType.Int16.prototype;
dart.addTypeTests(IntType.Int16);
dart.addTypeCaches(IntType.Int16);
dart.setLibraryUri(IntType.Int16, I[39]);
IntType.Int8 = class Int8 extends IntType.IntType {
static ['_#new#tearOff'](value) {
if (value == null) dart.nullFailed(I[39], 56, 12, "value");
return new IntType.Int8.new(value);
}
};
(IntType.Int8.new = function(value) {
if (value == null) dart.nullFailed(I[39], 56, 12, "value");
IntType.Int8.__proto__.new.call(this, value);
;
}).prototype = IntType.Int8.prototype;
dart.addTypeTests(IntType.Int8);
dart.addTypeCaches(IntType.Int8);
dart.setLibraryUri(IntType.Int8, I[39]);
IntType.UInt32 = class UInt32 extends IntType.IntType {
static ['_#new#tearOff'](value) {
if (value == null) dart.nullFailed(I[39], 60, 14, "value");
return new IntType.UInt32.new(value);
}
};
(IntType.UInt32.new = function(value) {
if (value == null) dart.nullFailed(I[39], 60, 14, "value");
IntType.UInt32.__proto__.new.call(this, value);
;
}).prototype = IntType.UInt32.prototype;
dart.addTypeTests(IntType.UInt32);
dart.addTypeCaches(IntType.UInt32);
dart.setLibraryUri(IntType.UInt32, I[39]);
IntType.UInt16 = class UInt16 extends IntType.IntType {
static ['_#new#tearOff'](value) {
if (value == null) dart.nullFailed(I[39], 64, 14, "value");
return new IntType.UInt16.new(value);
}
};
(IntType.UInt16.new = function(value) {
if (value == null) dart.nullFailed(I[39], 64, 14, "value");
IntType.UInt16.__proto__.new.call(this, value);
;
}).prototype = IntType.UInt16.prototype;
dart.addTypeTests(IntType.UInt16);
dart.addTypeCaches(IntType.UInt16);
dart.setLibraryUri(IntType.UInt16, I[39]);
IntType.UInt8 = class UInt8 extends IntType.IntType {
static ['_#new#tearOff'](value) {
if (value == null) dart.nullFailed(I[39], 68, 13, "value");
return new IntType.UInt8.new(value);
}
};
(IntType.UInt8.new = function(value) {
if (value == null) dart.nullFailed(I[39], 68, 13, "value");
IntType.UInt8.__proto__.new.call(this, value);
;
}).prototype = IntType.UInt8.prototype;
dart.addTypeTests(IntType.UInt8);
dart.addTypeCaches(IntType.UInt8);
dart.setLibraryUri(IntType.UInt8, I[39]);
NetworkBuffer.NetworkBuffer = class NetworkBuffer$ extends core.Object {
static ['_#new#tearOff']() {
return new NetworkBuffer.NetworkBuffer.new();
}
get protected() {
return dart.notNull(this[S$._neededDataLength]) > dart.notNull(this[S$._data$2].length);
}
get available() {
return this[S$._data$2].length;
}
holdForNextWrite(src, offset, size) {
if (src == null) dart.nullFailed(I[40], 39, 28, "src");
if (offset == null) dart.nullFailed(I[40], 39, 37, "offset");
if (size == null) dart.nullFailed(I[40], 39, 49, "size");
this.holdFor(src, offset, size, dart.notNull(size) + 1);
}
holdFor(src, offset, size, needed) {
if (src == null) dart.nullFailed(I[40], 43, 19, "src");
if (offset == null) dart.nullFailed(I[40], 43, 28, "offset");
if (size == null) dart.nullFailed(I[40], 43, 40, "size");
if (needed == null) dart.nullFailed(I[40], 43, 50, "needed");
if (dart.notNull(size) >= dart.notNull(needed)) dart.throw(core.Exception.new("Size >= Needed !"));
this[S$._data$2] = DC.DC.combine(src, offset, size, this[S$._data$2], 0, this[S$._data$2].length);
this[S$._neededDataLength] = needed;
}
holdForNeeded(src, needed) {
if (src == null) dart.nullFailed(I[40], 55, 25, "src");
if (needed == null) dart.nullFailed(I[40], 55, 34, "needed");
this.holdFor(src, 0, src.length, needed);
}
protect(data, offset, needed) {
if (data == null) dart.nullFailed(I[40], 59, 19, "data");
if (offset == null) dart.nullFailed(I[40], 59, 29, "offset");
if (needed == null) dart.nullFailed(I[40], 59, 41, "needed");
let dataLength = dart.notNull(this[S$._data$2].length) - dart.notNull(offset);
if (dataLength < dart.notNull(needed)) {
this.holdFor(data, offset, dataLength, needed);
return true;
} else
return false;
}
write(src, offset, length) {
if (src == null) dart.nullFailed(I[40], 70, 17, "src");
if (offset == null) dart.nullFailed(I[40], 70, 26, "offset");
if (length == null) dart.nullFailed(I[40], 70, 38, "length");
this[S$._data$2].append(src, offset, length);
}
get canRead() {
if (this[S$._data$2].length === 0) return false;
if (dart.notNull(this[S$._data$2].length) < dart.notNull(this[S$._neededDataLength])) return false;
return true;
}
read() {
if (this[S$._data$2].length === 0) return null;
let rt = null;
if (this[S$._neededDataLength] === 0) {
rt = this[S$._data$2];
this[S$._data$2] = new DC.DC.new(0);
} else {
if (dart.notNull(this[S$._data$2].length) >= dart.notNull(this[S$._neededDataLength])) {
rt = this[S$._data$2];
this[S$._data$2] = new DC.DC.new(0);
this[S$._neededDataLength] = 0;
return rt;
} else {
return null;
}
}
return rt;
}
};
(NetworkBuffer.NetworkBuffer.new = function() {
this[S$._data$2] = new DC.DC.new(0);
this[S$._neededDataLength] = 0;
}).prototype = NetworkBuffer.NetworkBuffer.prototype;
dart.addTypeTests(NetworkBuffer.NetworkBuffer);
dart.addTypeCaches(NetworkBuffer.NetworkBuffer);
dart.setMethodSignature(NetworkBuffer.NetworkBuffer, () => ({
__proto__: dart.getMethods(NetworkBuffer.NetworkBuffer.__proto__),
holdForNextWrite: dart.fnType(dart.void, [DC.DC, core.int, core.int]),
holdFor: dart.fnType(dart.void, [DC.DC, core.int, core.int, core.int]),
holdForNeeded: dart.fnType(dart.void, [DC.DC, core.int]),
protect: dart.fnType(core.bool, [DC.DC, core.int, core.int]),
write: dart.fnType(dart.void, [DC.DC, core.int, core.int]),
read: dart.fnType(dart.nullable(DC.DC), [])
}));
dart.setGetterSignature(NetworkBuffer.NetworkBuffer, () => ({
__proto__: dart.getGetters(NetworkBuffer.NetworkBuffer.__proto__),
protected: core.bool,
available: core.int,
canRead: core.bool
}));
dart.setLibraryUri(NetworkBuffer.NetworkBuffer, I[40]);
dart.setFieldSignature(NetworkBuffer.NetworkBuffer, () => ({
__proto__: dart.getFields(NetworkBuffer.NetworkBuffer.__proto__),
[S$._data$2]: dart.fieldType(DC.DC),
[S$._neededDataLength]: dart.fieldType(core.int)
}));
const _is_INetworkReceiver_default = Symbol('_is_INetworkReceiver_default');
INetworkReceiver$.INetworkReceiver$ = dart.generic(T => {
class INetworkReceiver extends core.Object {}
(INetworkReceiver.new = function() {
;
}).prototype = INetworkReceiver.prototype;
dart.addTypeTests(INetworkReceiver);
INetworkReceiver.prototype[_is_INetworkReceiver_default] = true;
dart.addTypeCaches(INetworkReceiver);
dart.setLibraryUri(INetworkReceiver, I[42]);
return INetworkReceiver;
});
INetworkReceiver$.INetworkReceiver = INetworkReceiver$.INetworkReceiver$();
dart.addTypeTests(INetworkReceiver$.INetworkReceiver, _is_INetworkReceiver_default);
ISocket.ISocket = class ISocket extends IDestructible.IDestructible {
get receiver() {
return this[S$.receiver];
}
set receiver(value) {
this[S$.receiver] = value;
}
get remoteEndPoint() {
return this[S$.remoteEndPoint];
}
set remoteEndPoint(value) {
this[S$.remoteEndPoint] = value;
}
get localEndPoint() {
return this[S$.localEndPoint];
}
set localEndPoint(value) {
this[S$.localEndPoint] = value;
}
};
(ISocket.ISocket.new = function() {
this[S$.receiver] = null;
this[S$.remoteEndPoint] = null;
this[S$.localEndPoint] = null;
ISocket.ISocket.__proto__.new.call(this);
;
}).prototype = ISocket.ISocket.prototype;
dart.addTypeTests(ISocket.ISocket);
dart.addTypeCaches(ISocket.ISocket);
dart.setLibraryUri(ISocket.ISocket, I[43]);
dart.setFieldSignature(ISocket.ISocket, () => ({
__proto__: dart.getFields(ISocket.ISocket.__proto__),
receiver: dart.fieldType(dart.nullable(INetworkReceiver$.INetworkReceiver$(ISocket.ISocket))),
remoteEndPoint: dart.fieldType(dart.nullable(IPEndPoint.IPEndPoint)),
localEndPoint: dart.fieldType(dart.nullable(IPEndPoint.IPEndPoint))
}));
const IDestructible_INetworkReceiver$36 = class IDestructible_INetworkReceiver extends IDestructible.IDestructible {};
(IDestructible_INetworkReceiver$36.new = function() {
IDestructible_INetworkReceiver$36.__proto__.new.call(this);
}).prototype = IDestructible_INetworkReceiver$36.prototype;
dart.applyMixin(IDestructible_INetworkReceiver$36, INetworkReceiver$.INetworkReceiver$(ISocket.ISocket));
NetworkConnection.NetworkConnection = class NetworkConnection$ extends IDestructible_INetworkReceiver$36 {
destroy() {
this.close();
}
static ['_#new#tearOff']() {
return new NetworkConnection.NetworkConnection.new();
}
get socket() {
return this[S$._sock];
}
assign(socket) {
if (socket == null) dart.nullFailed(I[41], 62, 23, "socket");
this[S$._lastAction] = new core.DateTime.now();
this[S$._sock] = socket;
socket.receiver = this;
}
unassign() {
let t18;
if (this[S$._sock] != null) {
t18 = this[S$._sock];
t18 == null ? null : t18.receiver = null;
let rt = this[S$._sock];
this[S$._sock] = null;
return rt;
} else
return null;
}
dataReceived(data) {
if (data == null) dart.nullFailed(I[41], 90, 35, "data");
this.emitArgs("dataReceived", [data]);
}
connected() {
}
disconnected() {
}
close() {
let t18;
try {
if (this[S$._sock] != null) {
t18 = this[S$._sock];
t18 == null ? null : t18.close();
}
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
} else
throw e;
}
}
get lastAction() {
return this[S$._lastAction];
}
get remoteEndPoint() {
let t19;
t19 = this[S$._sock];
return t19 == null ? null : t19.remoteEndPoint;
}
get localEndPoint() {
let t19;
t19 = this[S$._sock];
return t19 == null ? null : t19.localEndPoint;
}
get isConnected() {
let t19;
return (t19 = this[S$._sock], t19 == null ? null : t19.state) == SocketState.SocketState.Established;
}
send(msg) {
let t19;
if (msg == null) dart.nullFailed(I[41], 115, 16, "msg");
try {
if (this[S$._sock] != null) {
this[S$._lastAction] = new core.DateTime.now();
t19 = this[S$._sock];
t19 == null ? null : t19.send(msg);
}
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
} else
throw e;
}
}
sendString(data) {
if (data == null) dart.nullFailed(I[41], 126, 26, "data");
this.send(DC.DC.stringToBytes(data));
}
networkClose(sender) {
ISocket.ISocket.as(sender);
if (sender == null) dart.nullFailed(I[41], 131, 21, "sender");
this.disconnected();
this.emitArgs("close", [this]);
}
networkConnect(sender) {
ISocket.ISocket.as(sender);
if (sender == null) dart.nullFailed(I[41], 137, 23, "sender");
this.connected();
this.emitArgs("connect", [this]);
}
networkReceive(sender, buffer) {
let t20, t20$;
ISocket.ISocket.as(sender);
if (sender == null) dart.nullFailed(I[41], 143, 23, "sender");
if (buffer == null) dart.nullFailed(I[41], 143, 45, "buffer");
try {
if (this[S$._sock] == null) return;
if ((t20 = this[S$._sock], t20 == null ? null : t20.state) == SocketState.SocketState.Closed || (t20$ = this[S$._sock], t20$ == null ? null : t20$.state) == SocketState.SocketState.Terminated) return;
this[S$._lastAction] = new core.DateTime.now();
if (!dart.test(this[S$._processing])) {
this[S$._processing] = true;
try {
while (dart.notNull(buffer.available) > 0 && !dart.test(buffer.protected))
this.dataReceived(buffer);
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
} else
throw e;
}
this[S$._processing] = false;
}
} catch (e$) {
let ex = dart.getThrown(e$);
if (core.Object.is(ex)) {
core.print(ex);
} else
throw e$;
}
}
};
(NetworkConnection.NetworkConnection.new = function() {
this[S$._sock] = null;
this[S$._lastAction] = new core.DateTime.now();
this[S$._processing] = false;
NetworkConnection.NetworkConnection.__proto__.new.call(this);
}).prototype = NetworkConnection.NetworkConnection.prototype;
dart.addTypeTests(NetworkConnection.NetworkConnection);
dart.addTypeCaches(NetworkConnection.NetworkConnection);
dart.setMethodSignature(NetworkConnection.NetworkConnection, () => ({
__proto__: dart.getMethods(NetworkConnection.NetworkConnection.__proto__),
destroy: dart.fnType(dart.void, []),
assign: dart.fnType(dart.void, [ISocket.ISocket]),
unassign: dart.fnType(dart.nullable(ISocket.ISocket), []),
dataReceived: dart.fnType(dart.void, [NetworkBuffer.NetworkBuffer]),
connected: dart.fnType(dart.void, []),
disconnected: dart.fnType(dart.void, []),
close: dart.fnType(dart.void, []),
send: dart.fnType(dart.void, [DC.DC]),
sendString: dart.fnType(dart.void, [core.String]),
networkClose: dart.fnType(dart.void, [dart.nullable(core.Object)]),
networkConnect: dart.fnType(dart.void, [dart.nullable(core.Object)]),
networkReceive: dart.fnType(dart.void, [dart.nullable(core.Object), NetworkBuffer.NetworkBuffer])
}));
dart.setGetterSignature(NetworkConnection.NetworkConnection, () => ({
__proto__: dart.getGetters(NetworkConnection.NetworkConnection.__proto__),
socket: dart.nullable(ISocket.ISocket),
lastAction: core.DateTime,
remoteEndPoint: dart.nullable(IPEndPoint.IPEndPoint),
localEndPoint: dart.nullable(IPEndPoint.IPEndPoint),
isConnected: core.bool
}));
dart.setLibraryUri(NetworkConnection.NetworkConnection, I[41]);
dart.setFieldSignature(NetworkConnection.NetworkConnection, () => ({
__proto__: dart.getFields(NetworkConnection.NetworkConnection.__proto__),
[S$._sock]: dart.fieldType(dart.nullable(ISocket.ISocket)),
[S$._lastAction]: dart.fieldType(core.DateTime),
[S$._processing]: dart.fieldType(core.bool)
}));
SendList.SendList = class SendList$ extends BinaryList.BinaryList {
get connection() {
return this[S$.connection];
}
set connection(value) {
this[S$.connection] = value;
}
get reply() {
return this[S$.reply$1];
}
set reply(value) {
this[S$.reply$1] = value;
}
static ['_#new#tearOff'](connection, reply) {
if (connection == null) dart.nullFailed(I[44], 9, 17, "connection");
return new SendList.SendList.new(connection, reply);
}
done() {
let t22;
this.connection.send(super.toDC());
t22 = this.reply;
return t22 == null ? new (T$.AsyncReplyOfListN()).ready([]) : t22;
}
};
(SendList.SendList.new = function(connection, reply) {
if (connection == null) dart.nullFailed(I[44], 9, 17, "connection");
this[S$.connection] = connection;
this[S$.reply$1] = reply;
SendList.SendList.__proto__.new.call(this);
}).prototype = SendList.SendList.prototype;
dart.addTypeTests(SendList.SendList);
dart.addTypeCaches(SendList.SendList);
dart.setMethodSignature(SendList.SendList, () => ({
__proto__: dart.getMethods(SendList.SendList.__proto__),
done: dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(core.List)), [])
}));
dart.setLibraryUri(SendList.SendList, I[44]);
dart.setFieldSignature(SendList.SendList, () => ({
__proto__: dart.getFields(SendList.SendList.__proto__),
connection: dart.fieldType(NetworkConnection.NetworkConnection),
reply: dart.fieldType(dart.nullable(AsyncReply$.AsyncReply$(dart.nullable(core.List))))
}));
const NetworkConnection_IStore$36 = class NetworkConnection_IStore extends NetworkConnection.NetworkConnection {};
(NetworkConnection_IStore$36.new = function() {
NetworkConnection_IStore$36.__proto__.new.call(this);
}).prototype = NetworkConnection_IStore$36.prototype;
dart.applyMixin(NetworkConnection_IStore$36, IStore.IStore);
DistributedConnection.DistributedConnection = class DistributedConnection$ extends NetworkConnection_IStore$36 {
get variables() {
return this[S$.variables];
}
set variables(value) {
super.variables = value;
}
get instance() {
return this[S$.instance$1];
}
set instance(value) {
this[S$.instance$1] = value;
}
get localUsername() {
let t22, t22$;
t22$ = (t22 = this[S$._session], t22 == null ? null : t22.localAuthentication.username);
return t22$ == null ? "" : t22$;
}
get remoteUsername() {
let t22, t22$;
t22$ = (t22 = this[S$._session], t22 == null ? null : t22.remoteAuthentication.username);
return t22$ == null ? "" : t22$;
}
get session() {
return this[S$._session];
}
remove(resource) {
if (resource == null) dart.nullFailed(I[45], 164, 25, "resource");
return true;
}
sendParams(reply = null) {
return new SendList.SendList.new(this, reply);
}
send(data) {
if (data == null) dart.nullFailed(I[45], 181, 16, "data");
super.send(data);
}
trigger(trigger) {
let t22, t22$, t22$0, t22$1, t22$2, t22$3, t22$4, t22$5, t22$6, t22$7, t22$8, t22$9, t22$10, t22$11, t22$12;
if (trigger == null) dart.nullFailed(I[45], 188, 44, "trigger");
if (trigger == ResourceTrigger.ResourceTrigger.Open) {
if (this[S$._server] != null) return new (T$.AsyncReplyOfbool()).ready(true);
let host = dart.nullCast(this.instance, Instance.Instance).name[S$.$split](":");
let address = host[S$.$_get](0);
let port = dart.notNull(host[S$.$length]) > 1 ? core.int.parse(host[S$.$_get](1)) : 10518;
let domain = (t22$ = (t22 = this.instance, t22 == null ? null : dart.toString(t22.attributes._get("domain"))), t22$ == null ? address : t22$);
let ws = (t22$0 = this.instance, t22$0 == null ? null : t22$0.attributes.containsKey("ws")) === true || (t22$1 = this.instance, t22$1 == null ? null : t22$1.attributes.containsKey("wss")) === true;
let secure = (t22$2 = this.instance, t22$2 == null ? null : t22$2.attributes.containsKey("secure")) === true || (t22$3 = this.instance, t22$3 == null ? null : t22$3.attributes.containsKey("wss")) === true;
if ((t22$4 = this.instance, t22$4 == null ? null : t22$4.attributes.containsKey("username")) === true && (t22$5 = this.instance, t22$5 == null ? null : t22$5.attributes.containsKey("password")) === true) {
let username = core.String.as((t22$6 = this.instance, t22$6 == null ? null : t22$6.attributes._get("username")));
let password = DC.DC.stringToBytes(core.String.as((t22$7 = this.instance, t22$7 == null ? null : t22$7.attributes._get("password"))));
return this.connect({method: AuthenticationMethod.AuthenticationMethod.Credentials, domain: domain, hostname: address, port: port, passwordOrToken: password, username: username, useWebsocket: ws, secureWebSocket: secure});
} else if ((t22$8 = this.instance, t22$8 == null ? null : t22$8.attributes.containsKey("token")) === true) {
let token = DC.DC.stringToBytes((t22$10 = (t22$9 = this.instance, t22$9 == null ? null : dart.toString(t22$9.attributes._get("token"))), t22$10 == null ? "" : t22$10));
let tokenIndex = (t22$12 = T$.intN().as((t22$11 = this.instance, t22$11 == null ? null : t22$11.attributes._get("tokenIndex"))), t22$12 == null ? 0 : t22$12);
return this.connect({method: AuthenticationMethod.AuthenticationMethod.Credentials, domain: domain, hostname: address, port: port, passwordOrToken: token, tokenIndex: tokenIndex, useWebsocket: ws, secureWebSocket: secure});
} else {
return this.connect({method: AuthenticationMethod.AuthenticationMethod.None, hostname: address, port: port, domain: domain, useWebsocket: ws, secureWebSocket: secure});
}
}
return new (T$.AsyncReplyOfbool()).ready(true);
}
connect(opts) {
let t22, t22$, t22$0, t22$1, t22$2, t22$3, t22$4;
let method = opts && 'method' in opts ? opts.method : C[108] || CT.C108;
if (method == null) dart.nullFailed(I[45], 248, 29, "method");
let socket = opts && 'socket' in opts ? opts.socket : null;
let hostname = opts && 'hostname' in opts ? opts.hostname : null;
let port = opts && 'port' in opts ? opts.port : null;
let username = opts && 'username' in opts ? opts.username : null;
let tokenIndex = opts && 'tokenIndex' in opts ? opts.tokenIndex : null;
let passwordOrToken = opts && 'passwordOrToken' in opts ? opts.passwordOrToken : null;
let domain = opts && 'domain' in opts ? opts.domain : null;
let useWebsocket = opts && 'useWebsocket' in opts ? opts.useWebsocket : false;
if (useWebsocket == null) dart.nullFailed(I[45], 256, 12, "useWebsocket");
let secureWebSocket = opts && 'secureWebSocket' in opts ? opts.secureWebSocket : false;
if (secureWebSocket == null) dart.nullFailed(I[45], 257, 12, "secureWebSocket");
if (this[S$._openReply] != null) dart.throw(new AsyncException.AsyncException.new(ErrorType.ErrorType.Exception, 0, "Connection in progress"));
this[S$._openReply] = new (T$.AsyncReplyOfbool()).new();
if (hostname != null) {
this[S$._session] = new Session.Session.new(new ClientAuthentication.ClientAuthentication.new(), new HostAuthentication.HostAuthentication.new());
t22 = this[S$._session];
t22 == null ? null : t22.localAuthentication.method = method;
t22$ = this[S$._session];
t22$ == null ? null : t22$.localAuthentication.tokenIndex = tokenIndex;
t22$0 = this[S$._session];
t22$0 == null ? null : t22$0.localAuthentication.domain = domain;
t22$1 = this[S$._session];
t22$1 == null ? null : t22$1.localAuthentication.username = username;
this[S$._localPasswordOrToken] = passwordOrToken;
}
if (this[S$._session] == null) dart.throw(new AsyncException.AsyncException.new(ErrorType.ErrorType.Exception, 0, "Session not initialized"));
if (socket == null) {
if (dart.test(useWebsocket) || true) {
socket = (t22$2 = new WSocket.WSocket.new(), (() => {
t22$2.secure = secureWebSocket;
return t22$2;
})());
} else
socket = new TCPSocket.TCPSocket.new();
}
this[S$._port] = (t22$3 = port, t22$3 == null ? this[S$._port] : t22$3);
this[S$._hostname] = (t22$4 = hostname, t22$4 == null ? this[S$._hostname] : t22$4);
if (this[S$._hostname] == null) dart.throw(core.Exception.new("Host not specified."));
if (socket != null) {
socket.connect(dart.nullCast(this[S$._hostname], core.String), this[S$._port]).then(dart.dynamic, dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 290, 65, "x");
this.assign(dart.nullCast(socket, ISocket.ISocket));
}, T$.boolToNull())).error(dart.fn(x => {
let t22;
if (x == null) dart.nullFailed(I[45], 292, 17, "x");
t22 = this[S$._openReply];
t22 == null ? null : t22.triggerError(x);
this[S$._openReply] = null;
}, T$.AsyncExceptionToNull()));
}
return dart.nullCast(this[S$._openReply], T$.AsyncReplyOfbool());
}
disconnected() {
this[S$._ready] = false;
this[S$._readyToEstablish] = false;
this[S$._requests].values[S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 307, 31, "x");
return x.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, 0, "Connection closed"));
}, T$.AsyncReplyTovoid()));
this[S$._resourceRequests].values[S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 309, 39, "x");
return x.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, 0, "Connection closed"));
}, T$.AsyncReplyOfDistributedResourceTovoid()));
this[S$._templateRequests].values[S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 311, 39, "x");
return x.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, 0, "Connection closed"));
}, T$.AsyncReplyOfTypeTemplateNTovoid()));
this[S$._requests].clear();
this[S$._resourceRequests].clear();
this[S$._templateRequests].clear();
this[S$._resources].values[S$.$forEach](dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 318, 32, "x");
return x.suspend();
}, T$.DistributedResourceTovoid()));
}
reconnect() {
return async.async(core.bool, (function* reconnect() {
if (dart.test(yield this.connect())) {
let bag = new AsyncBag$.AsyncBag.new();
for (let i = 0; i < dart.notNull(this[S$._resources].keys[S$.$length]); i = i + 1) {
let index = this[S$._resources].keys[S$.$elementAt](i);
bag.add(this.fetch(index));
}
bag.seal();
yield bag;
return true;
}
return false;
}).bind(this));
}
[S$._declare]() {
let t22, t22$, t22$0, t22$1, t22$2, t22$3, t22$4, t23, t23$, t22$5, t22$6, t22$7;
let dmn = DC.DC.stringToBytes((t22$ = (t22 = this[S$._session], t22 == null ? null : t22.localAuthentication.domain), t22$ == null ? "" : t22$));
if ((t22$0 = this[S$._session], t22$0 == null ? null : t22$0.localAuthentication.method) == AuthenticationMethod.AuthenticationMethod.Credentials) {
let un = DC.DC.stringToBytes((t22$2 = (t22$1 = this[S$._session], t22$1 == null ? null : t22$1.localAuthentication.username), t22$2 == null ? "" : t22$2));
t22$3 = this.sendParams();
(() => {
t22$3.addUint8(96);
t22$3.addUint8(dmn.length);
t22$3.addDC(dmn);
t22$3.addDC(dart.nullCast(this[S$._localNonce], DC.DC));
t22$3.addUint8(un.length);
t22$3.addDC(un);
t22$3.done();
return t22$3;
})();
} else if ((t22$4 = this[S$._session], t22$4 == null ? null : t22$4.localAuthentication.method) == AuthenticationMethod.AuthenticationMethod.Token) {
t22$5 = this.sendParams();
(() => {
t22$5.addUint8(112);
t22$5.addUint8(dmn.length);
t22$5.addDC(dmn);
t22$5.addDC(dart.nullCast(this[S$._localNonce], DC.DC));
t22$5.addUint64((t23$ = (t23 = this[S$._session], t23 == null ? null : t23.localAuthentication.tokenIndex), t23$ == null ? 0 : t23$));
t22$5.done();
return t22$5;
})();
} else if ((t22$6 = this[S$._session], t22$6 == null ? null : t22$6.localAuthentication.method) == AuthenticationMethod.AuthenticationMethod.None) {
t22$7 = this.sendParams();
(() => {
t22$7.addUint8(64);
t22$7.addUint8(dmn.length);
t22$7.addDC(dmn);
t22$7.done();
return t22$7;
})();
}
}
assign(socket) {
let t24, t23, t22, t24$, t23$, t22$, t24$0, t23$0, t22$0, t24$1, t23$1, t22$1, t22$2;
if (socket == null) dart.nullFailed(I[45], 391, 18, "socket");
super.assign(socket);
t22 = this[S$._session];
t22 == null ? null : (t23 = t22.remoteAuthentication.source, t23 == null ? null : t23.attributes._set(SourceAttributeType.SourceAttributeType.IPv4, (t24 = socket.remoteEndPoint, t24 == null ? null : t24.address)));
t22$ = this[S$._session];
t22$ == null ? null : (t23$ = t22$.remoteAuthentication.source, t23$ == null ? null : t23$.attributes._set(SourceAttributeType.SourceAttributeType.Port, (t24$ = socket.remoteEndPoint, t24$ == null ? null : t24$.port)));
t22$0 = this[S$._session];
t22$0 == null ? null : (t23$0 = t22$0.localAuthentication.source, t23$0 == null ? null : t23$0.attributes._set(SourceAttributeType.SourceAttributeType.IPv4, (t24$0 = socket.localEndPoint, t24$0 == null ? null : t24$0.address)));
t22$1 = this[S$._session];
t22$1 == null ? null : (t23$1 = t22$1.localAuthentication.source, t23$1 == null ? null : t23$1.attributes._set(SourceAttributeType.SourceAttributeType.Port, (t24$1 = socket.localEndPoint, t24$1 == null ? null : t24$1.port)));
if ((t22$2 = this[S$._session], t22$2 == null ? null : t22$2.localAuthentication.type) == AuthenticationType.AuthenticationType.Client) {
this[S$._declare]();
}
}
static ['_#new#tearOff']() {
return new DistributedConnection.DistributedConnection.new();
}
link(resource) {
let t22, t22$, t22$0;
if (resource == null) dart.nullFailed(I[45], 461, 26, "resource");
if (DistributedResource.DistributedResource.is(resource)) {
if (dart.equals((t22 = resource.instance, t22 == null ? null : t22.store), this)) return dart.notNull((t22$0 = (t22$ = this.instance, t22$ == null ? null : t22$.name), t22$0 == null ? "" : t22$0)) + "/" + dart.notNull(dart.toString(resource.id));
}
return null;
}
init() {
this[S$._queue].then(core.Null, dart.fn(x => {
let t22, t22$, t22$0;
if ((t22 = x, t22 == null ? null : t22.type) == DistributedResourceQueueItemType.DistributedResourceQueueItemType.Event) {
t22$ = x;
t22$ == null ? null : t22$.resource.internal_emitEventByIndex(x.index, x.value);
} else {
t22$0 = x;
t22$0 == null ? null : t22$0.resource.internal_updatePropertyByIndex(x.index, x.value);
}
}, T$.DistributedResourceQueueItemNToNull()));
let r = math.Random.new();
let n = new DC.DC.new(32);
for (let i = 0; i < 32; i = i + 1)
n._set(i, r.nextInt(255));
this[S$._localNonce] = n;
}
processPacket(msg, offset, ends, data, chunkId) {
let t22, t22$, t22$0, t22$1, t22$2, t22$3, t22$4, t22$5, t22$6, t22$7, t22$8, t22$9, t22$10, t22$11, t22$12, t22$13, t22$14, t22$15, t22$16, t22$17, t22$18, t22$19, t22$20, t22$21, t22$22, t22$23, t22$24, t22$25;
if (msg == null) dart.nullFailed(I[45], 485, 10, "msg");
if (offset == null) dart.nullFailed(I[45], 485, 19, "offset");
if (ends == null) dart.nullFailed(I[45], 485, 31, "ends");
if (data == null) dart.nullFailed(I[45], 485, 51, "data");
if (chunkId == null) dart.nullFailed(I[45], 485, 61, "chunkId");
let packet = new IIPPacket.IIPPacket.new();
if (dart.test(this[S$._ready])) {
core.print("Inc " + dart.toString(msg.length));
let rt = packet.parse(msg, offset, ends);
core.print("Packet " + dart.notNull(packet.toString()));
if (dart.notNull(rt) <= 0) {
let size = dart.notNull(ends) - dart.notNull(offset);
data.holdFor(msg, offset, size, size - dart.notNull(rt));
return ends;
} else {
offset = dart.notNull(offset) + dart.notNull(rt);
if (packet.command === 0) {
switch (packet.event) {
case 0:
{
this.iipEventResourceReassigned(packet.resourceId, packet.newResourceId);
break;
}
case 1:
{
this.iipEventResourceDestroyed(packet.resourceId);
break;
}
case 16:
{
this.iipEventPropertyUpdated(packet.resourceId, packet.methodIndex, (t22 = packet.dataType, t22 == null ? TransmissionType.TransmissionType.Null : t22), msg);
break;
}
case 17:
{
this.iipEventEventOccurred(packet.resourceId, packet.methodIndex, (t22$ = packet.dataType, t22$ == null ? TransmissionType.TransmissionType.Null : t22$), msg);
break;
}
case 2:
{
this.iipEventChildAdded(packet.resourceId, packet.childId);
break;
}
case 3:
{
this.iipEventChildRemoved(packet.resourceId, packet.childId);
break;
}
case 4:
{
this.iipEventRenamed(packet.resourceId, packet.resourceName);
break;
}
case 24:
{
break;
}
}
} else if (packet.command === 1) {
switch (packet.action) {
case 0:
{
this.iipRequestAttachResource(packet.callbackId, packet.resourceId);
break;
}
case 1:
{
this.iipRequestReattachResource(packet.callbackId, packet.resourceId, packet.resourceAge);
break;
}
case 2:
{
this.iipRequestDetachResource(packet.callbackId, packet.resourceId);
break;
}
case 3:
{
break;
}
case 4:
{
this.iipRequestDeleteResource(packet.callbackId, packet.resourceId);
break;
}
case 5:
{
this.iipRequestAddChild(packet.callbackId, packet.resourceId, packet.childId);
break;
}
case 6:
{
this.iipRequestRemoveChild(packet.callbackId, packet.resourceId, packet.childId);
break;
}
case 7:
{
this.iipRequestRenameResource(packet.callbackId, packet.resourceId, packet.resourceName);
break;
}
case 8:
{
this.iipRequestTemplateFromClassName(packet.callbackId, packet.className);
break;
}
case 9:
{
this.iipRequestTemplateFromClassId(packet.callbackId, packet.classId);
break;
}
case 10:
{
this.iipRequestTemplateFromResourceId(packet.callbackId, packet.resourceId);
break;
}
case 11:
{
this.iipRequestQueryResources(packet.callbackId, packet.resourceLink);
break;
}
case 13:
{
this.iipRequestResourceChildren(packet.callbackId, packet.resourceId);
break;
}
case 14:
{
this.iipRequestResourceParents(packet.callbackId, packet.resourceId);
break;
}
case 12:
{
this.iipRequestInquireResourceHistory(packet.callbackId, packet.resourceId, packet.fromDate, packet.toDate);
break;
}
case 15:
{
this.iipRequestLinkTemplates(packet.callbackId, packet.resourceLink);
break;
}
case 16:
{
this.iipRequestInvokeFunction(packet.callbackId, packet.resourceId, packet.methodIndex, (t22$0 = packet.dataType, t22$0 == null ? TransmissionType.TransmissionType.Null : t22$0), msg);
break;
}
case 18:
{
this.iipRequestListen(packet.callbackId, packet.resourceId, packet.methodIndex);
break;
}
case 19:
{
this.iipRequestUnlisten(packet.callbackId, packet.resourceId, packet.methodIndex);
break;
}
case 20:
{
this.iipRequestSetProperty(packet.callbackId, packet.resourceId, packet.methodIndex, (t22$1 = packet.dataType, t22$1 == null ? TransmissionType.TransmissionType.Null : t22$1), msg);
break;
}
case 24:
{
break;
}
case 25:
{
break;
}
case 26:
{
break;
}
case 27:
{
break;
}
case 28:
{
break;
}
case 29:
{
break;
}
}
} else if (packet.command === 2) {
switch (packet.action) {
case 0:
{
this.iipReply(packet.callbackId, [packet.classId, packet.resourceAge, packet.resourceLink, (t22$2 = packet.dataType, t22$2 == null ? TransmissionType.TransmissionType.Null : t22$2), msg]);
break;
}
case 1:
{
this.iipReply(packet.callbackId, [packet.resourceAge, (t22$3 = packet.dataType, t22$3 == null ? TransmissionType.TransmissionType.Null : t22$3), msg]);
break;
}
case 2:
{
this.iipReply(packet.callbackId);
break;
}
case 3:
{
this.iipReply(packet.callbackId, [packet.resourceId]);
break;
}
case 4:
case 5:
case 6:
case 7:
{
this.iipReply(packet.callbackId);
break;
}
case 8:
case 9:
case 10:
{
if (packet.dataType != null) {
let content = msg.clip((t22$5 = (t22$4 = packet.dataType, t22$4 == null ? null : t22$4.offset), t22$5 == null ? 0 : t22$5), (t22$7 = (t22$6 = packet.dataType, t22$6 == null ? null : t22$6.contentLength), t22$7 == null ? 0 : t22$7));
this.iipReply(packet.callbackId, [new TypeTemplate.TypeTemplate.parse(content)]);
} else {
this.iipReportError(packet.callbackId, ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.TemplateNotFound.index, "Template not found");
}
break;
}
case 11:
case 13:
case 14:
case 12:
case 15:
{
this.iipReply(packet.callbackId, [(t22$8 = packet.dataType, t22$8 == null ? TransmissionType.TransmissionType.Null : t22$8), msg]);
break;
}
case 16:
{
this.iipReplyInvoke(packet.callbackId, (t22$9 = packet.dataType, t22$9 == null ? TransmissionType.TransmissionType.Null : t22$9), msg);
break;
}
case 18:
case 19:
case 20:
{
this.iipReply(packet.callbackId);
break;
}
case 24:
case 27:
{
this.iipReply(packet.callbackId, [(t22$10 = packet.dataType, t22$10 == null ? TransmissionType.TransmissionType.Null : t22$10), msg]);
break;
}
case 25:
case 28:
case 26:
case 29:
{
this.iipReply(packet.callbackId);
break;
}
}
} else if (packet.command === 3) {
switch (packet.report) {
case 0:
{
this.iipReportError(packet.callbackId, ErrorType.ErrorType.Management, packet.errorCode, null);
break;
}
case 1:
{
this.iipReportError(packet.callbackId, ErrorType.ErrorType.Exception, packet.errorCode, packet.errorMessage);
break;
}
case 8:
{
this.iipReportProgress(packet.callbackId, ProgressType.ProgressType.Execution, packet.progressValue, packet.progressMax);
break;
}
case 9:
{
this.iipReportChunk(packet.callbackId, (t22$11 = packet.dataType, t22$11 == null ? TransmissionType.TransmissionType.Null : t22$11), msg);
break;
}
}
}
}
} else {
let rt = this[S$._authPacket].parse(msg, offset, ends);
if (dart.notNull(rt) <= 0) {
data.holdForNeeded(msg, dart.notNull(ends) - dart.notNull(rt));
return ends;
} else {
offset = dart.notNull(offset) + dart.notNull(rt);
if ((t22$12 = this[S$._session], t22$12 == null ? null : t22$12.localAuthentication.type) == AuthenticationType.AuthenticationType.Host) {
if (this[S$._authPacket].command === 1) {
if (this[S$._authPacket].remoteMethod == AuthenticationMethod.AuthenticationMethod.Credentials && this[S$._authPacket].localMethod == AuthenticationMethod.AuthenticationMethod.None) {
}
} else if (this[S$._authPacket].command === 0) {
if (this[S$._authPacket].action === 0) {
let remoteHash = this[S$._authPacket].hash;
} else if (this[S$._authPacket].action === 32) {
if (dart.test(this[S$._readyToEstablish])) {
let r = math.Random.new();
let sid = new DC.DC.new(32);
for (let i = 0; i < 32; i = i + 1)
sid._set(i, r.nextInt(255));
t22$13 = this[S$._session];
t22$13 == null ? null : t22$13.id = sid;
t22$14 = this.sendParams();
(() => {
t22$14.addUint8(40);
t22$14.addDC(sid);
t22$14.done();
return t22$14;
})();
this[S$._ready] = true;
t22$15 = this[S$._openReply];
t22$15 == null ? null : t22$15.trigger(true);
this[S$._openReply] = null;
this.emitArgs("ready", []);
}
}
}
} else if ((t22$16 = this[S$._session], t22$16 == null ? null : t22$16.localAuthentication.type) == AuthenticationType.AuthenticationType.Client) {
if (this[S$._authPacket].command === 2) {
if (this[S$._authPacket].remoteMethod == AuthenticationMethod.AuthenticationMethod.None) {
t22$17 = this.sendParams();
(() => {
t22$17.addUint8(32);
t22$17.addUint16(0);
t22$17.done();
return t22$17;
})();
} else if (this[S$._authPacket].remoteMethod == AuthenticationMethod.AuthenticationMethod.Credentials || this[S$._authPacket].remoteMethod == AuthenticationMethod.AuthenticationMethod.Token) {
this[S$._remoteNonce] = this[S$._authPacket].remoteNonce;
let localHash = SHA256.SHA256.compute((t22$18 = new BinaryList.BinaryList.new(), (() => {
t22$18.addDC(dart.nullCast(this[S$._localPasswordOrToken], DC.DC));
t22$18.addDC(dart.nullCast(this[S$._localNonce], DC.DC));
t22$18.addDC(dart.nullCast(this[S$._remoteNonce], DC.DC));
return t22$18;
})()).toDC());
t22$19 = this.sendParams();
(() => {
t22$19.addUint8(0);
t22$19.addDC(localHash);
t22$19.done();
return t22$19;
})();
}
} else if (this[S$._authPacket].command === 0) {
if (this[S$._authPacket].action === 0) {
let remoteHash = SHA256.SHA256.compute((t22$20 = new BinaryList.BinaryList.new(), (() => {
t22$20.addDC(dart.nullCast(this[S$._remoteNonce], DC.DC));
t22$20.addDC(dart.nullCast(this[S$._localNonce], DC.DC));
t22$20.addDC(dart.nullCast(this[S$._localPasswordOrToken], DC.DC));
return t22$20;
})()).toDC());
if (dart.test(remoteHash.sequenceEqual(this[S$._authPacket].hash))) {
t22$21 = this.sendParams();
(() => {
t22$21.addUint8(32);
t22$21.addUint16(0);
t22$21.done();
return t22$21;
})();
} else {
t22$22 = this.sendParams();
(() => {
t22$22.addUint8(192);
t22$22.addUint8(ExceptionCode.ExceptionCode.ChallengeFailed.index);
t22$22.addUint16(16);
t22$22.addString("Challenge Failed");
t22$22.done();
return t22$22;
})();
}
} else if (this[S$._authPacket].action === 40) {
t22$23 = this[S$._session];
t22$23 == null ? null : t22$23.id = this[S$._authPacket].sessionId;
this[S$._ready] = true;
t22$24 = this[S$._openReply];
t22$24 == null ? null : t22$24.trigger(true);
this[S$._openReply] = null;
this.emitArgs("ready", []);
}
} else if (this[S$._authPacket].command === 3) {
let ex = new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, this[S$._authPacket].errorCode, this[S$._authPacket].errorMessage);
t22$25 = this[S$._openReply];
t22$25 == null ? null : t22$25.triggerError(ex);
this[S$._openReply] = null;
this.emitArgs("error", [ex]);
this.close();
}
}
}
}
return offset;
}
dataReceived(data) {
if (data == null) dart.nullFailed(I[45], 962, 35, "data");
core.print("dataReceived");
let msg = data.read();
let offset = 0;
if (msg != null) {
let ends = msg.length;
let chunkId = math.Random.new().nextInt(1000000);
while (dart.notNull(offset) < dart.notNull(ends)) {
offset = this.processPacket(msg, offset, ends, data, chunkId);
}
}
}
put(resource) {
if (resource == null) dart.nullFailed(I[45], 996, 34, "resource");
if (dart.test(Codec.Codec.isLocalResource(resource, this))) this[S$._resources].add(dart.nullCast(DistributedResource.DistributedResource.as(resource).id, core.int), resource);
return new (T$.AsyncReplyOfbool()).ready(true);
}
record(resource, propertyName, value, age, dateTime) {
if (resource == null) dart.nullFailed(I[45], 1003, 25, "resource");
if (propertyName == null) dart.nullFailed(I[45], 1003, 42, "propertyName");
return true;
}
modify(resource, propertyName, value, age, dateTime) {
if (resource == null) dart.nullFailed(I[45], 1009, 25, "resource");
if (propertyName == null) dart.nullFailed(I[45], 1009, 42, "propertyName");
return true;
}
sendRequest(action) {
let t22, t22$;
if (action == null) dart.nullFailed(I[45], 1021, 28, "action");
let reply = new (T$.AsyncReplyOfListN()).new();
let c = (t22 = this[S$._callbackCounter], this[S$._callbackCounter] = dart.notNull(t22) + 1, t22);
this[S$._requests].add(c, reply);
t22$ = this.sendParams(reply);
return (() => {
t22$.addUint8((64 | dart.notNull(action)) >>> 0);
t22$.addUint32(c);
return t22$;
})();
}
sendReply(action, callbackId) {
let t22;
if (action == null) dart.nullFailed(I[45], 1033, 26, "action");
if (callbackId == null) dart.nullFailed(I[45], 1033, 38, "callbackId");
t22 = this.sendParams();
return (() => {
t22.addUint8((128 | dart.notNull(action)) >>> 0);
t22.addUint32(callbackId);
return t22;
})();
}
sendEvent(evt) {
let t22;
if (evt == null) dart.nullFailed(I[45], 1039, 26, "evt");
t22 = this.sendParams();
return (() => {
t22.addUint8(evt);
return t22;
})();
}
sendListenRequest(instanceId, index) {
let t22, t22$;
if (instanceId == null) dart.nullFailed(I[45], 1043, 45, "instanceId");
if (index == null) dart.nullFailed(I[45], 1043, 61, "index");
let reply = new AsyncReply$.AsyncReply.new();
let c = (t22 = this[S$._callbackCounter], this[S$._callbackCounter] = dart.notNull(t22) + 1, t22);
this[S$._requests].add(c, reply);
t22$ = this.sendParams();
(() => {
t22$.addUint8((64 | 18) >>> 0);
t22$.addUint32(c);
t22$.addUint32(instanceId);
t22$.addUint8(index);
t22$.done();
return t22$;
})();
return reply;
}
sendUnlistenRequest(instanceId, index) {
let t22, t22$;
if (instanceId == null) dart.nullFailed(I[45], 1057, 47, "instanceId");
if (index == null) dart.nullFailed(I[45], 1057, 63, "index");
let reply = new AsyncReply$.AsyncReply.new();
let c = (t22 = this[S$._callbackCounter], this[S$._callbackCounter] = dart.notNull(t22) + 1, t22);
this[S$._requests].add(c, reply);
t22$ = this.sendParams();
(() => {
t22$.addUint8((64 | 19) >>> 0);
t22$.addUint32(c);
t22$.addUint32(instanceId);
t22$.addUint8(index);
t22$.done();
return t22$;
})();
return reply;
}
sendInvoke(instanceId, index, parameters) {
let t22, t22$;
if (instanceId == null) dart.nullFailed(I[45], 1072, 11, "instanceId");
if (index == null) dart.nullFailed(I[45], 1072, 27, "index");
if (parameters == null) dart.nullFailed(I[45], 1072, 54, "parameters");
let pb = Codec.Codec.compose(parameters, this);
let reply = new AsyncReply$.AsyncReply.new();
let c = (t22 = this[S$._callbackCounter], this[S$._callbackCounter] = dart.notNull(t22) + 1, t22);
this[S$._requests].add(c, reply);
t22$ = this.sendParams();
(() => {
t22$.addUint8((64 | 16) >>> 0);
t22$.addUint32(c);
t22$.addUint32(instanceId);
t22$.addUint8(index);
t22$.addDC(pb);
t22$.done();
return t22$;
})();
return reply;
}
sendDetachRequest(instanceId) {
let t22;
if (instanceId == null) dart.nullFailed(I[45], 1089, 46, "instanceId");
try {
return (t22 = this.sendRequest(2), (() => {
t22.addUint32(instanceId);
return t22;
})()).done();
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
return null;
} else
throw e;
}
}
sendError(type, callbackId, errorCode, errorMessage = null) {
let t23, t23$, t23$0;
if (type == null) dart.nullFailed(I[45], 1099, 28, "type");
if (callbackId == null) dart.nullFailed(I[45], 1099, 38, "callbackId");
if (errorCode == null) dart.nullFailed(I[45], 1099, 54, "errorCode");
let msg = DC.DC.stringToBytes((t23 = errorMessage, t23 == null ? "" : t23));
if (type == ErrorType.ErrorType.Management) {
t23$ = this.sendParams();
(() => {
t23$.addUint8((192 | 0) >>> 0);
t23$.addUint32(callbackId);
t23$.addUint16(errorCode);
t23$.done();
return t23$;
})();
} else if (type == ErrorType.ErrorType.Exception) {
t23$0 = this.sendParams();
(() => {
t23$0.addUint8((192 | 1) >>> 0);
t23$0.addUint32(callbackId);
t23$0.addUint16(errorCode);
t23$0.addUint16(msg.length);
t23$0.addDC(msg);
t23$0.done();
return t23$0;
})();
}
}
sendProgress(callbackId, value, max) {
let t23;
if (callbackId == null) dart.nullFailed(I[45], 1118, 25, "callbackId");
if (value == null) dart.nullFailed(I[45], 1118, 41, "value");
if (max == null) dart.nullFailed(I[45], 1118, 52, "max");
t23 = this.sendParams();
(() => {
t23.addUint8((192 | 8) >>> 0);
t23.addUint32(callbackId);
t23.addInt32(value);
t23.addInt32(max);
t23.done();
return t23;
})();
}
sendChunk(callbackId, chunk) {
let t23;
if (callbackId == null) dart.nullFailed(I[45], 1128, 22, "callbackId");
let c = Codec.Codec.compose(chunk, this);
t23 = this.sendParams();
(() => {
t23.addUint8((192 | 9) >>> 0);
t23.addUint32(callbackId);
t23.addDC(c);
t23.done();
return t23;
})();
}
iipReply(callbackId, results = null) {
let t23;
if (callbackId == null) dart.nullFailed(I[45], 1137, 21, "callbackId");
let req = this[S$._requests].take(callbackId);
t23 = req;
t23 == null ? null : t23.trigger(results);
}
iipReplyInvoke(callbackId, dataType, data) {
if (callbackId == null) dart.nullFailed(I[45], 1142, 27, "callbackId");
if (dataType == null) dart.nullFailed(I[45], 1142, 56, "dataType");
if (data == null) dart.nullFailed(I[45], 1142, 69, "data");
let req = this[S$._requests].take(callbackId);
Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn(rt => {
let t23;
t23 = req;
t23 == null ? null : t23.trigger(rt);
}, T$.dynamicToNull()));
}
iipReportError(callbackId, errorType, errorCode, errorMessage) {
let t23;
if (callbackId == null) dart.nullFailed(I[45], 1150, 27, "callbackId");
if (errorType == null) dart.nullFailed(I[45], 1150, 49, "errorType");
if (errorCode == null) dart.nullFailed(I[45], 1150, 64, "errorCode");
let req = this[S$._requests].take(callbackId);
t23 = req;
t23 == null ? null : t23.triggerError(new AsyncException.AsyncException.new(errorType, errorCode, errorMessage));
}
iipReportProgress(callbackId, type, value, max) {
let t23;
if (callbackId == null) dart.nullFailed(I[45], 1157, 11, "callbackId");
if (type == null) dart.nullFailed(I[45], 1157, 36, "type");
if (value == null) dart.nullFailed(I[45], 1157, 46, "value");
if (max == null) dart.nullFailed(I[45], 1157, 57, "max");
let req = this[S$._requests]._get(callbackId);
t23 = req;
t23 == null ? null : t23.triggerProgress(type, value, max);
}
iipReportChunk(callbackId, dataType, data) {
if (callbackId == null) dart.nullFailed(I[45], 1162, 27, "callbackId");
if (dataType == null) dart.nullFailed(I[45], 1162, 56, "dataType");
if (data == null) dart.nullFailed(I[45], 1162, 69, "data");
if (dart.test(this[S$._requests].containsKey(callbackId))) {
let req = this[S$._requests]._get(callbackId);
Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn(x => {
let t23;
t23 = req;
t23 == null ? null : t23.triggerChunk(x);
}, T$.dynamicToNull()));
}
}
iipEventResourceReassigned(resourceId, newResourceId) {
if (resourceId == null) dart.nullFailed(I[45], 1171, 39, "resourceId");
if (newResourceId == null) dart.nullFailed(I[45], 1171, 55, "newResourceId");
}
iipEventResourceDestroyed(resourceId) {
let t23;
if (resourceId == null) dart.nullFailed(I[45], 1173, 38, "resourceId");
if (dart.test(this[S$._resources].contains(resourceId))) {
let r = this[S$._resources]._get(resourceId);
this[S$._resources].remove(resourceId);
t23 = r;
t23 == null ? null : t23.destroy();
}
}
iipEventPropertyUpdated(resourceId, index, dataType, data) {
if (resourceId == null) dart.nullFailed(I[45], 1182, 11, "resourceId");
if (index == null) dart.nullFailed(I[45], 1182, 27, "index");
if (dataType == null) dart.nullFailed(I[45], 1182, 51, "dataType");
if (data == null) dart.nullFailed(I[45], 1182, 64, "data");
this.fetch(resourceId).then(core.Null, dart.fn(r => {
if (r == null) dart.nullFailed(I[45], 1183, 29, "r");
let item = new (T$.AsyncReplyOfDistributedResourceQueueItem()).new();
this[S$._queue].add(item);
Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn($arguments => {
let t23;
let pt = (t23 = r.instance, t23 == null ? null : t23.template.getPropertyTemplateByIndex(index));
if (pt != null) {
item.trigger(new DistributedResourceQueueItem.DistributedResourceQueueItem.new(r, DistributedResourceQueueItemType.DistributedResourceQueueItemType.Propery, $arguments, index));
} else {
this[S$._queue].remove(item);
}
}, T$.dynamicToNull()));
}, T$.DistributedResourceToNull()));
}
iipEventEventOccurred(resourceId, index, dataType, data) {
if (resourceId == null) dart.nullFailed(I[45], 1237, 11, "resourceId");
if (index == null) dart.nullFailed(I[45], 1237, 27, "index");
if (dataType == null) dart.nullFailed(I[45], 1237, 51, "dataType");
if (data == null) dart.nullFailed(I[45], 1237, 64, "data");
this.fetch(resourceId).then(core.Null, dart.fn(r => {
if (r == null) dart.nullFailed(I[45], 1238, 29, "r");
let item = new (T$.AsyncReplyOfDistributedResourceQueueItem()).new();
this[S$._queue].add(item);
Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn($arguments => {
let t23;
let et = (t23 = r.instance, t23 == null ? null : t23.template.getEventTemplateByIndex(index));
if (et != null) {
item.trigger(new DistributedResourceQueueItem.DistributedResourceQueueItem.new(r, DistributedResourceQueueItemType.DistributedResourceQueueItemType.Event, $arguments, index));
} else {
this[S$._queue].remove(item);
}
}, T$.dynamicToNull()));
}, T$.DistributedResourceToNull()));
}
iipEventChildAdded(resourceId, childId) {
if (resourceId == null) dart.nullFailed(I[45], 1291, 31, "resourceId");
if (childId == null) dart.nullFailed(I[45], 1291, 47, "childId");
this.fetch(resourceId).then(core.Null, dart.fn(parent => {
if (parent == null) dart.nullFailed(I[45], 1292, 29, "parent");
if (parent != null) this.fetch(childId).then(core.Null, dart.fn(child => {
let t23;
if (child == null) dart.nullFailed(I[45], 1294, 30, "child");
if (child != null) {
t23 = parent.instance;
t23 == null ? null : t23.children.add(child);
}
}, T$.DistributedResourceToNull()));
}, T$.DistributedResourceToNull()));
}
iipEventChildRemoved(resourceId, childId) {
if (resourceId == null) dart.nullFailed(I[45], 1300, 33, "resourceId");
if (childId == null) dart.nullFailed(I[45], 1300, 49, "childId");
this.fetch(resourceId).then(core.Null, dart.fn(parent => {
if (parent == null) dart.nullFailed(I[45], 1301, 29, "parent");
if (parent != null) this.fetch(childId).then(core.Null, dart.fn(child => {
let t23;
if (child == null) dart.nullFailed(I[45], 1303, 30, "child");
if (child != null) {
t23 = parent.instance;
t23 == null ? null : t23.children.remove(child);
}
}, T$.DistributedResourceToNull()));
}, T$.DistributedResourceToNull()));
}
iipEventRenamed(resourceId, name) {
let t23;
if (resourceId == null) dart.nullFailed(I[45], 1309, 28, "resourceId");
if (name == null) dart.nullFailed(I[45], 1309, 47, "name");
t23 = this.fetch(resourceId);
(() => {
t23.then(core.Null, dart.fn(resource => {
let t24;
if (resource == null) dart.nullFailed(I[45], 1311, 15, "resource");
if (resource != null) {
t24 = resource.instance;
t24 == null ? null : t24.attributes._set("name", name);
}
}, T$.DistributedResourceToNull()));
return t23;
})();
}
iipEventAttributesUpdated(resourceId, attributes) {
let t23;
if (resourceId == null) dart.nullFailed(I[45], 1318, 38, "resourceId");
if (attributes == null) dart.nullFailed(I[45], 1318, 53, "attributes");
t23 = this.fetch(resourceId);
(() => {
t23.then(core.Null, dart.fn(resource => {
if (resource == null) dart.nullFailed(I[45], 1320, 15, "resource");
if (resource != null) {
let attrs = attributes.getStringArray(0, attributes.length);
this.getAttributes(resource, attrs).then(core.Null, dart.fn(s => {
let t24;
if (s == null) dart.nullFailed(I[45], 1324, 48, "s");
t24 = resource.instance;
t24 == null ? null : t24.setAttributes(s);
}, T$.MapOfString$dynamicToNull()));
}
}, T$.DistributedResourceToNull()));
return t23;
})();
}
iipRequestAttachResource(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1331, 37, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1331, 51, "resourceId");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t23, t23$, t23$0, t24, t24$, t23$1, t23$2;
if (r != null) {
if ((t23 = r.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.Attach, null)) == Ruling.Ruling.Denied) {
this.sendError(ErrorType.ErrorType.Management, callback, 6);
return;
}
this[S$._unsubscrive](r);
let link = DC.DC.stringToBytes((t23$0 = (t23$ = r.instance, t23$ == null ? null : t23$.link), t23$0 == null ? "" : t23$0));
if (DistributedResource.DistributedResource.is(r)) {
t23$1 = this.sendReply(0, callback);
(() => {
t23$1.addGuid(dart.nullCast((t24 = r.instance, t24 == null ? null : t24.template.classId), Guid.Guid));
t23$1.addUint64(dart.nullCast((t24$ = r.instance, t24$ == null ? null : t24$.age), core.int));
t23$1.addUint16(link.length);
t23$1.addDC(link);
t23$1.addDC(Codec.Codec.compose(r.internal_serialize(), this));
t23$1.done();
return t23$1;
})();
} else {
t23$2 = this.sendReply(0, callback);
(() => {
t23$2.addGuid(dart.nullCast(r.instance, Instance.Instance).template.classId);
t23$2.addUint64(dart.nullCast(r.instance, Instance.Instance).age);
t23$2.addUint16(link.length);
t23$2.addDC(link);
t23$2.addDC(Codec.Codec.compose(dart.nullCast(r.instance, Instance.Instance).serialize(), this));
t23$2.done();
return t23$2;
})();
}
this[S$._subscribe](r);
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
}
}, T$.IResourceNToNull()));
}
[S$._attributes_OnModified](key, oldValue, newValue, sender) {
let t23;
if (key == null) dart.nullFailed(I[45], 1382, 14, "key");
if (sender == null) dart.nullFailed(I[45], 1382, 64, "sender");
if (key === "name") {
let instance = Instance.Instance.as(sender.owner);
let name = DC.DC.stringToBytes(dart.toString(newValue));
t23 = this.sendEvent(3);
(() => {
t23.addUint32(instance.id);
t23.addUint16(name.length);
t23.addDC(name);
t23.done();
return t23;
})();
}
}
[S$._children_OnRemoved](sender, value) {
let t24, t23;
if (sender == null) dart.nullFailed(I[45], 1394, 37, "sender");
if (value == null) dart.nullFailed(I[45], 1394, 55, "value");
t23 = this.sendEvent(3);
(() => {
t23.addUint32(sender.id);
t23.addUint32(dart.nullCast((t24 = value.instance, t24 == null ? null : t24.id), core.int));
t23.done();
return t23;
})();
}
[S$._children_OnAdd](sender, value) {
let t23;
if (sender == null) dart.nullFailed(I[45], 1401, 33, "sender");
if (value == null) dart.nullFailed(I[45], 1401, 51, "value");
t23 = this.sendEvent(2);
(() => {
t23.addUint32(sender.id);
t23.addUint32(dart.nullCast(value.instance, Instance.Instance).id);
t23.done();
return t23;
})();
}
[S$._subscribe](resource) {
let t23, t23$, t23$0;
if (resource == null) dart.nullFailed(I[45], 1409, 29, "resource");
t23 = resource.instance;
t23 == null ? null : t23.on("resourceEventOccurred", dart.bind(this, S$._instance_EventOccurred));
t23$ = resource.instance;
t23$ == null ? null : t23$.on("resourceModified", dart.bind(this, S$._instance_PropertyModified));
t23$0 = resource.instance;
t23$0 == null ? null : t23$0.on("resourceDestroyed", dart.bind(this, S$._instance_ResourceDestroyed));
this[S$._subscriptions][S$.$_set](resource, T$.JSArrayOfint().of([]));
}
[S$._unsubscrive](resource) {
let t23, t23$, t23$0;
if (resource == null) dart.nullFailed(I[45], 1416, 31, "resource");
t23 = resource.instance;
t23 == null ? null : t23.off("resourceEventOccurred", dart.bind(this, S$._instance_EventOccurred));
t23$ = resource.instance;
t23$ == null ? null : t23$.off("resourceModified", dart.bind(this, S$._instance_PropertyModified));
t23$0 = resource.instance;
t23$0 == null ? null : t23$0.off("resourceDestroyed", dart.bind(this, S$._instance_ResourceDestroyed));
this[S$._subscriptions][S$.$remove](resource);
}
iipRequestReattachResource(callback, resourceId, resourceAge) {
if (callback == null) dart.nullFailed(I[45], 1424, 11, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1424, 25, "resourceId");
if (resourceAge == null) dart.nullFailed(I[45], 1424, 41, "resourceAge");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t23;
if (r != null) {
this[S$._unsubscrive](r);
this[S$._subscribe](r);
t23 = this.sendReply(1, callback);
(() => {
t23.addUint64(dart.nullCast(r.instance, Instance.Instance).age);
t23.addDC(Codec.Codec.compose(dart.nullCast(r.instance, Instance.Instance).serialize(), this));
t23.done();
return t23;
})();
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
}
}, T$.IResourceNToNull()));
}
iipRequestDetachResource(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1443, 37, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1443, 51, "resourceId");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(res => {
if (res != null) {
this[S$._unsubscrive](res);
this.sendReply(2, callback).done();
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
}
}, T$.IResourceNToNull()));
}
iipRequestCreateResource(callback, storeId, parentId, content) {
if (callback == null) dart.nullFailed(I[45], 1459, 11, "callback");
if (storeId == null) dart.nullFailed(I[45], 1459, 25, "storeId");
if (parentId == null) dart.nullFailed(I[45], 1459, 38, "parentId");
if (content == null) dart.nullFailed(I[45], 1459, 51, "content");
Warehouse.Warehouse.getById(storeId).then(core.Null, dart.fn(store => {
let t23;
if (store == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.StoreNotFound.index);
return;
}
if (!IStore.IStore.is(store)) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceIsNotStore.index);
return;
}
if ((t23 = store.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.CreateResource, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.CreateDenied.index);
return;
}
Warehouse.Warehouse.getById(parentId).then(core.Null, dart.fn(parent => {
let t23;
if (parent != null) if ((t23 = parent.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.AddChild, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.AddChildDenied.index);
return;
}
let offset = 0;
let className = content.getString(offset + 1, content._get(0));
offset = offset + (1 + dart.notNull(content._get(0)));
let nameLength = content.getUint16(offset);
offset = offset + 2;
let name = content.getString(offset, nameLength);
let cl = content.getUint32(offset);
offset = offset + 4;
let type = null;
if (type == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ClassNotFound.index);
return;
}
DataDeserializer.DataDeserializer.listParser(content, offset, cl, this).then(core.Null, dart.fn(parameters => {
if (parameters == null) dart.nullFailed(I[45], 1514, 20, "parameters");
offset = offset + dart.notNull(cl);
cl = content.getUint32(offset);
DataDeserializer.DataDeserializer.typedMapParser(content, offset, cl, this).then(core.Null, dart.fn(attributes => {
offset = offset + dart.notNull(cl);
cl = dart.notNull(content.length) - offset;
DataDeserializer.DataDeserializer.typedMapParser(content, offset, cl, this).then(core.Null, dart.fn(values => {
let constructors = [];
let matching = constructors[S$.$where](dart.fn(x => {
let ps = dart.dsend(x, 'GetParameters', []);
return dart.equals(dart.dload(ps, 'length'), parameters[S$.$length]);
}, T$.dynamicTobool()))[S$.$toList]();
let pi = core.List.as(dart.dsend(matching[S$.$_get](0), 'getParameters', []));
if (dart.notNull(pi[S$.$length]) > 0) {
let argsCount = pi[S$.$length];
if (dart.equals(dart.runtimeType(dart.dload(pi[S$.$_get](dart.notNull(pi[S$.$length]) - 1), 'parameterType')), dart.wrapType(DistributedConnection.DistributedConnection))) {
}
if (parameters != null) {
for (let i = 0; i < dart.notNull(argsCount) && i < dart.notNull(parameters[S$.$length]); i = i + 1) {
}
}
}
let resource = null;
Warehouse.Warehouse.put(IResource.IResource, name, dart.nullCast(resource, IResource.IResource), store, parent).then(dart.dynamic, dart.fn(ok => {
let t23;
t23 = this.sendReply(3, callback);
(() => {
t23.addUint32(dart.nullCast(resource.instance, Instance.Instance).id);
t23.done();
return t23;
})();
}, T$.IResourceNToNull())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 1560, 25, "ex");
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.AddToStoreFailed.index);
}, T$.AsyncExceptionToNull()));
}, T$.dynamicToNull()));
}, T$.dynamicToNull()));
}, T$.ListToNull()));
}, T$.IResourceNToNull()));
}, T$.IResourceNToNull()));
}
iipRequestDeleteResource(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1572, 37, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1572, 51, "resourceId");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t25, t24, t23;
if (r == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = r.instance, t23 == null ? null : (t24 = t23.store, t24 == null ? null : (t25 = t24.instance, t25 == null ? null : t25.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.Delete, null)))) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.DeleteDenied.index);
return;
}
if (dart.test(Warehouse.Warehouse.remove(r)))
this.sendReply(4, callback).done();
else
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.DeleteFailed.index);
}, T$.IResourceNToNull()));
}
iipRequestGetAttributes(callback, resourceId, attributes, all = false) {
if (callback == null) dart.nullFailed(I[45], 1597, 36, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1597, 50, "resourceId");
if (attributes == null) dart.nullFailed(I[45], 1597, 65, "attributes");
if (all == null) dart.nullFailed(I[45], 1598, 13, "all");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t23, t23$, t23$0;
if (r == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = r.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.InquireAttributes, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ViewAttributeDenied.index);
return;
}
let attrs = null;
if (!dart.test(all)) attrs = attributes.getStringArray(0, attributes.length);
let st = (t23$ = r.instance, t23$ == null ? null : t23$.getAttributes(attrs));
if (st != null) {
t23$0 = this.sendReply(dart.test(all) ? 24 : 27, callback);
(() => {
t23$0.addDC(Codec.Codec.compose(st, this));
t23$0.done();
return t23$0;
})();
} else
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.GetAttributesFailed.index);
}, T$.IResourceNToNull()));
}
iipRequestAddChild(callback, parentId, childId) {
if (callback == null) dart.nullFailed(I[45], 1635, 31, "callback");
if (parentId == null) dart.nullFailed(I[45], 1635, 45, "parentId");
if (childId == null) dart.nullFailed(I[45], 1635, 59, "childId");
Warehouse.Warehouse.getById(parentId).then(core.Null, dart.fn(parent => {
if (parent == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
Warehouse.Warehouse.getById(childId).then(core.Null, dart.fn(child => {
let t23, t23$, t23$0;
if (child == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = parent.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.AddChild, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.AddChildDenied.index);
return;
}
if ((t23$ = child.instance, t23$ == null ? null : t23$.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.AddParent, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.AddParentDenied.index);
return;
}
t23$0 = parent.instance;
t23$0 == null ? null : t23$0.children.add(child);
this.sendReply(5, callback).done();
}, T$.IResourceNToNull()));
}, T$.IResourceNToNull()));
}
iipRequestRemoveChild(callback, parentId, childId) {
if (callback == null) dart.nullFailed(I[45], 1674, 34, "callback");
if (parentId == null) dart.nullFailed(I[45], 1674, 48, "parentId");
if (childId == null) dart.nullFailed(I[45], 1674, 62, "childId");
Warehouse.Warehouse.getById(parentId).then(core.Null, dart.fn(parent => {
if (parent == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
Warehouse.Warehouse.getById(childId).then(core.Null, dart.fn(child => {
let t23, t23$, t23$0;
if (child == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = parent.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.RemoveChild, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.AddChildDenied.index);
return;
}
if ((t23$ = child.instance, t23$ == null ? null : t23$.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.RemoveParent, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.AddParentDenied.index);
return;
}
t23$0 = parent.instance;
t23$0 == null ? null : t23$0.children.remove(child);
this.sendReply(6, callback).done();
}, T$.IResourceNToNull()));
}, T$.IResourceNToNull()));
}
iipRequestRenameResource(callback, resourceId, name) {
if (callback == null) dart.nullFailed(I[45], 1713, 37, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1713, 51, "resourceId");
if (name == null) dart.nullFailed(I[45], 1713, 70, "name");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(resource => {
let t23, t23$;
if (resource == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = resource.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.Rename, null)) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.RenameDenied.index);
return;
}
t23$ = resource.instance;
t23$ == null ? null : t23$.name = name;
this.sendReply(7, callback).done();
}, T$.IResourceNToNull()));
}
iipRequestResourceChildren(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1734, 39, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1734, 53, "resourceId");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(resource => {
let t24, t23;
if (resource == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
t23 = this.sendReply(13, callback);
(() => {
t23.addDC(Codec.Codec.compose(dart.nullCast((t24 = resource.instance, t24 == null ? null : t24.children.toList()), T$.ListOfIResource()), this));
t23.done();
return t23;
})();
}, T$.IResourceNToNull()));
}
iipRequestResourceParents(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1749, 38, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1749, 52, "resourceId");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(resource => {
let t24, t23;
if (resource == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
t23 = this.sendReply(14, callback);
(() => {
t23.addDC(Codec.Codec.compose(dart.nullCast((t24 = resource.instance, t24 == null ? null : t24.parents.toList()), T$.ListOfIResource()), this));
t23.done();
return t23;
})();
}, T$.IResourceNToNull()));
}
iipRequestClearAttributes(callback, resourceId, attributes, all = false) {
if (callback == null) dart.nullFailed(I[45], 1764, 38, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1764, 52, "resourceId");
if (attributes == null) dart.nullFailed(I[45], 1764, 67, "attributes");
if (all == null) dart.nullFailed(I[45], 1765, 13, "all");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t25, t24, t23, t23$;
if (r == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = r.instance, t23 == null ? null : (t24 = t23.store, t24 == null ? null : (t25 = t24.instance, t25 == null ? null : t25.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.UpdateAttributes, null)))) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.UpdateAttributeDenied.index);
return;
}
let attrs = null;
if (!dart.test(all)) attrs = attributes.getStringArray(0, attributes.length);
if ((t23$ = r.instance, t23$ == null ? null : t23$.removeAttributes(attrs)) === true)
this.sendReply(dart.test(all) ? 26 : 29, callback).done();
else
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.UpdateAttributeFailed.index);
}, T$.IResourceNToNull()));
}
iipRequestUpdateAttributes(callback, resourceId, attributes, clearAttributes = false) {
if (callback == null) dart.nullFailed(I[45], 1798, 39, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1798, 53, "resourceId");
if (attributes == null) dart.nullFailed(I[45], 1798, 68, "attributes");
if (clearAttributes == null) dart.nullFailed(I[45], 1799, 13, "clearAttributes");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t25, t24, t23;
if (r == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
return;
}
if ((t23 = r.instance, t23 == null ? null : (t24 = t23.store, t24 == null ? null : (t25 = t24.instance, t25 == null ? null : t25.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.UpdateAttributes, null)))) != Ruling.Ruling.Allowed) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.UpdateAttributeDenied.index);
return;
}
DataDeserializer.DataDeserializer.typedListParser(attributes, 0, attributes.length, this).then(core.Null, dart.fn(attrs => {
let t23;
if ((t23 = r.instance, t23 == null ? null : t23.setAttributes(T$.MapOfString$dynamic().as(attrs), clearAttributes)) === true)
this.sendReply(dart.test(clearAttributes) ? 26 : 29, callback).done();
else
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.UpdateAttributeFailed.index);
}, T$.dynamicToNull()));
}, T$.IResourceNToNull()));
}
iipRequestLinkTemplates(callback, resourceLink) {
let t23, t24, t23$;
if (callback == null) dart.nullFailed(I[45], 1833, 36, "callback");
if (resourceLink == null) dart.nullFailed(I[45], 1833, 53, "resourceLink");
let queryCallback = dart.fn(r => {
let t23;
if (r == null)
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
else {
let list = r[S$.$where](dart.fn(x => {
let t23;
if (x == null) dart.nullFailed(I[45], 1839, 29, "x");
return (t23 = x.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.ViewTemplate, null)) != Ruling.Ruling.Denied;
}, T$.IResourceTobool()));
if (list[S$.$length] === 0)
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
else {
let msg = new BinaryList.BinaryList.new();
let templates = T$.JSArrayOfTypeTemplate().of([]);
list[S$.$forEach](dart.fn(resource => {
let t23;
if (resource == null) dart.nullFailed(I[45], 1853, 25, "resource");
templates[S$.$addAll](TypeTemplate.TypeTemplate.getDependencies(dart.nullCast((t23 = resource.instance, t23 == null ? null : t23.template), TypeTemplate.TypeTemplate))[S$.$where](dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 1856, 25, "x");
return !dart.test(templates[S$.$contains](x));
}, T$.TypeTemplateTobool())));
}, T$.IResourceTovoid()));
templates[S$.$forEach](dart.fn(t => {
let t23;
if (t == null) dart.nullFailed(I[45], 1859, 30, "t");
t23 = msg;
(() => {
t23.addInt32(t.content.length);
t23.addDC(t.content);
return t23;
})();
}, T$.TypeTemplateTovoid()));
t23 = this.sendReply(15, callback);
(() => {
t23.addDC(TransmissionType.TransmissionType.compose(64, msg.toDC()));
t23.done();
return t23;
})();
}
}
}, T$.ListNOfIResourceToNull());
if ((t23 = this[S$._server], t23 == null ? null : t23.entryPoint) != null) {
t23$ = this[S$._server];
t23$ == null ? null : (t24 = t23$.entryPoint, t24 == null ? null : t24.query(resourceLink, this).then(core.Null, queryCallback));
} else
Warehouse.Warehouse.query(resourceLink).then(core.Null, queryCallback);
}
iipRequestTemplateFromClassName(callback, className) {
let t23;
if (callback == null) dart.nullFailed(I[45], 1880, 44, "callback");
if (className == null) dart.nullFailed(I[45], 1880, 61, "className");
let t = Warehouse.Warehouse.getTemplateByClassName(className);
if (t != null) {
t23 = this.sendReply(8, callback);
(() => {
t23.addDC(TransmissionType.TransmissionType.compose(64, t.content));
t23.done();
return t23;
})();
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.TemplateNotFound.index);
}
}
iipRequestTemplateFromClassId(callback, classId) {
let t23;
if (callback == null) dart.nullFailed(I[45], 1894, 42, "callback");
if (classId == null) dart.nullFailed(I[45], 1894, 57, "classId");
let t = Warehouse.Warehouse.getTemplateByClassId(classId);
if (t != null) {
t23 = this.sendReply(9, callback);
(() => {
t23.addDC(TransmissionType.TransmissionType.compose(64, t.content));
t23.done();
return t23;
})();
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.TemplateNotFound.index);
}
}
iipRequestTemplateFromResourceId(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1908, 45, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1908, 59, "resourceId");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t24, t24$, t23;
if (r != null) {
t23 = this.sendReply(10, callback);
(() => {
t23.addDC(TransmissionType.TransmissionType.compose(64, (t24$ = (t24 = r.instance, t24 == null ? null : t24.template.content), t24$ == null ? new DC.DC.new(0) : t24$)));
t23.done();
return t23;
})();
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.TemplateNotFound.index);
}
}, T$.IResourceNToNull()));
}
iipRequestQueryResources(callback, resourceLink) {
if (callback == null) dart.nullFailed(I[45], 1923, 37, "callback");
if (resourceLink == null) dart.nullFailed(I[45], 1923, 54, "resourceLink");
Warehouse.Warehouse.query(resourceLink).then(core.Null, dart.fn(r => {
let t23;
if (r == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
} else {
let list = r[S$.$where](dart.fn(x => {
let t23;
if (x == null) dart.nullFailed(I[45], 1930, 21, "x");
return (t23 = x.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.Attach, null)) != Ruling.Ruling.Denied;
}, T$.IResourceTobool()))[S$.$toList]();
if (list[S$.$length] === 0)
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
else {
t23 = this.sendReply(11, callback);
(() => {
t23.addDC(Codec.Codec.compose(list, this));
t23.done();
return t23;
})();
}
}
}, T$.ListNOfIResourceToNull()));
}
IIPRequestResourceAttribute(callback, resourceId) {
if (callback == null) dart.nullFailed(I[45], 1947, 40, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1947, 54, "resourceId");
}
iipRequestInvokeFunction(callback, resourceId, index, dataType, data) {
if (callback == null) dart.nullFailed(I[45], 1949, 37, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1949, 51, "resourceId");
if (index == null) dart.nullFailed(I[45], 1949, 67, "index");
if (dataType == null) dart.nullFailed(I[45], 1950, 24, "dataType");
if (data == null) dart.nullFailed(I[45], 1950, 37, "data");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
if (r != null) {
Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn($arguments => {
let t23;
let ft = (t23 = r.instance, t23 == null ? null : t23.template.getFunctionTemplateByIndex(index));
if (ft != null) {
if (DistributedResource.DistributedResource.is(r)) {
let rt = r.internal_invoke(index, T$.MapOfUInt8$dynamic().as($arguments));
if (rt != null) {
rt.then(core.Null, dart.fn(res => {
let t23;
t23 = this.sendReply(16, callback);
(() => {
t23.addDC(Codec.Codec.compose(res, this));
t23.done();
return t23;
})();
}, T$.dynamicToNull()));
} else {
}
} else {
let fi = null;
if (fi != null) {
} else {
}
}
} else {
}
}, T$.dynamicToNull()));
} else {
}
}, T$.IResourceNToNull()));
}
iipRequestListen(callback, resourceId, index) {
if (callback == null) dart.nullFailed(I[45], 1986, 29, "callback");
if (resourceId == null) dart.nullFailed(I[45], 1986, 43, "resourceId");
if (index == null) dart.nullFailed(I[45], 1986, 59, "index");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t23;
if (r != null) {
let et = (t23 = r.instance, t23 == null ? null : t23.template.getEventTemplateByIndex(index));
if (et != null) {
if (DistributedResource.DistributedResource.is(r)) {
r.listen(et.name).then(core.Null, dart.fn(x => {
this.sendReply(18, callback).done();
}, T$.dynamicToNull())).error(dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 1995, 23, "x");
return this.sendError(ErrorType.ErrorType.Exception, callback, ExceptionCode.ExceptionCode.GeneralFailure.index);
}, T$.AsyncExceptionTovoid()));
} else {
}
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.MethodNotFound.index);
}
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
}
}, T$.IResourceNToNull()));
}
iipRequestUnlisten(callback, resourceId, index) {
if (callback == null) dart.nullFailed(I[45], 2027, 31, "callback");
if (resourceId == null) dart.nullFailed(I[45], 2027, 45, "resourceId");
if (index == null) dart.nullFailed(I[45], 2027, 61, "index");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t23;
if (r != null) {
let et = (t23 = r.instance, t23 == null ? null : t23.template.getEventTemplateByIndex(index));
if (et != null) {
if (DistributedResource.DistributedResource.is(r)) {
r.unlisten(et.name).then(core.Null, dart.fn(x => {
this.sendReply(19, callback).done();
}, T$.dynamicToNull())).error(dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 2036, 23, "x");
return this.sendError(ErrorType.ErrorType.Exception, callback, ExceptionCode.ExceptionCode.GeneralFailure.index);
}, T$.AsyncExceptionTovoid()));
} else {
}
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.MethodNotFound.index);
}
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
}
}, T$.IResourceNToNull()));
}
iipRequestInquireResourceHistory(callback, resourceId, fromDate, toDate) {
if (callback == null) dart.nullFailed(I[45], 2100, 11, "callback");
if (resourceId == null) dart.nullFailed(I[45], 2100, 25, "resourceId");
if (fromDate == null) dart.nullFailed(I[45], 2100, 46, "fromDate");
if (toDate == null) dart.nullFailed(I[45], 2100, 65, "toDate");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t24, t23;
if (r != null) {
t23 = r.instance;
t23 == null ? null : (t24 = t23.store, t24 == null ? null : t24.getRecord(r, fromDate, toDate).then(core.Null, dart.fn(results => {
let t25;
if (results != null) {
let history = DataSerializer.DataSerializer.historyComposer(results, this, true);
t25 = this.sendReply(12, callback);
(() => {
t25.addDC(history);
t25.done();
return t25;
})();
}
}, T$.KeyListNOfPropertyTemplate$ListOfPropertyValueToNull())));
}
}, T$.IResourceNToNull()));
}
iipRequestSetProperty(callback, resourceId, index, dataType, data) {
if (callback == null) dart.nullFailed(I[45], 2162, 34, "callback");
if (resourceId == null) dart.nullFailed(I[45], 2162, 48, "resourceId");
if (index == null) dart.nullFailed(I[45], 2162, 64, "index");
if (dataType == null) dart.nullFailed(I[45], 2163, 24, "dataType");
if (data == null) dart.nullFailed(I[45], 2163, 37, "data");
Warehouse.Warehouse.getById(resourceId).then(core.Null, dart.fn(r => {
let t23;
if (r != null) {
let pt = (t23 = r.instance, t23 == null ? null : t23.template.getPropertyTemplateByIndex(index));
if (pt != null) {
Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn(value => {
let t23;
if (DistributedResource.DistributedResource.is(r)) {
r.set(index, value).then(dart.dynamic, dart.fn(x => {
this.sendReply(20, callback).done();
}, T$.dynamicToNull())).error(dart.fn(x => {
if (x == null) dart.nullFailed(I[45], 2173, 25, "x");
this.sendError(x.type, callback, x.code, x.message);
}, T$.AsyncExceptionToNull()));
} else {
let pi = null;
if (pi != null) {
if ((t23 = r.instance, t23 == null ? null : t23.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.SetProperty, pt, this)) == Ruling.Ruling.Denied) {
this.sendError(ErrorType.ErrorType.Exception, callback, ExceptionCode.ExceptionCode.SetPropertyDenied.index);
return;
}
if (pi == null) {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ReadOnlyProperty.index);
return;
}
if (dart.equals(dart.runtimeType(dart.dload(pi, 'propertyType')), dart.wrapType(DistributedPropertyContext.DistributedPropertyContext))) {
value = new DistributedPropertyContext.DistributedPropertyContext.setter(value, this);
} else {
}
try {
dart.dsend(pi, 'setValue', [r, value]);
this.sendReply(20, callback).done();
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
this.sendError(ErrorType.ErrorType.Exception, callback, 0, dart.toString(ex));
} else
throw e;
}
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.PropertyNotFound.index);
}
}
}, T$.dynamicToNull()));
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.PropertyNotFound.index);
}
} else {
this.sendError(ErrorType.ErrorType.Management, callback, ExceptionCode.ExceptionCode.ResourceNotFound.index);
}
}, T$.IResourceNToNull()));
}
getTemplate(classId) {
let t24, t24$;
if (classId == null) dart.nullFailed(I[45], 2239, 46, "classId");
if (dart.test(this[S$._templates][S$.$containsKey](classId)))
return new (T$.AsyncReplyOfTypeTemplateN()).ready(this[S$._templates][S$.$_get](classId));
else if (dart.test(this[S$._templateRequests].containsKey(classId))) return dart.nullCast(this[S$._templateRequests]._get(classId), T$.AsyncReplyOfTypeTemplateN());
let reply = new (T$.AsyncReplyOfTypeTemplate()).new();
this[S$._templateRequests].add(classId, reply);
t24$ = (t24 = this.sendRequest(9), (() => {
t24.addGuid(classId);
return t24;
})()).done();
(() => {
t24$.then(core.Null, dart.fn(rt => {
if (rt != null) {
this[S$._templateRequests].remove(classId);
this[S$._templates][S$.$_set](TypeTemplate.TypeTemplate.as(rt[S$.$_get](0)).classId, TypeTemplate.TypeTemplate.as(rt[S$.$_get](0)));
Warehouse.Warehouse.putTemplate(TypeTemplate.TypeTemplate.as(rt[S$.$_get](0)));
reply.trigger(TypeTemplate.TypeTemplate.as(rt[S$.$_get](0)));
} else {
reply.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
t24$.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2259, 16, "ex");
reply.triggerError(ex);
}, T$.AsyncExceptionToNull()));
return t24$;
})();
return reply;
}
get(path) {
let t24;
if (path == null) dart.nullFailed(I[45], 2272, 37, "path");
let rt = new (T$.AsyncReplyOfIResourceN()).new();
t24 = this.query(path);
(() => {
t24.then(core.Null, dart.fn(ar => {
if (ar == null) dart.nullFailed(I[45], 2276, 15, "ar");
if (dart.notNull(ar[S$.$length]) > 0)
rt.trigger(ar[S$.$_get](0));
else
rt.trigger(null);
}, T$.ListOfIResourceNToNull()));
t24.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2282, 16, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfIResourceN()));
return t24;
})();
return rt;
}
retrieve(iid) {
let t24;
if (iid == null) dart.nullFailed(I[45], 2292, 39, "iid");
for (let r of this[S$._resources].values)
if ((t24 = r.instance, t24 == null ? null : t24.id) == iid) return new (T$.AsyncReplyOfIResource()).ready(r);
return new (T$.AsyncReplyOfIResourceN()).ready(null);
}
getLinkTemplates(link) {
let t24, t24$;
if (link == null) dart.nullFailed(I[45], 2298, 58, "link");
let reply = new (T$.AsyncReplyOfListOfTypeTemplate()).new();
let l = DC.DC.stringToBytes(link);
t24$ = (t24 = this.sendRequest(15), (() => {
t24.addUint16(l.length);
t24.addDC(l);
return t24;
})()).done();
(() => {
t24$.then(core.Null, dart.fn(rt => {
let templates = T$.JSArrayOfTypeTemplate().of([]);
if (rt != null) {
let tt = TransmissionType.TransmissionType.as(rt[S$.$_get](0));
let data = DC.DC.as(rt[S$.$_get](1));
for (let offset = tt.offset; dart.notNull(offset) < dart.notNull(tt.contentLength);) {
let cs = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
templates[S$.$add](new TypeTemplate.TypeTemplate.parse(data, offset, cs));
offset = dart.notNull(offset) + dart.notNull(cs);
}
} else {
reply.triggerError(core.Exception.new("Null response"));
}
reply.trigger(templates);
}, T$.ListNToNull()));
t24$.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2327, 16, "ex");
reply.triggerError(ex);
}, T$.AsyncExceptionToNull()));
return t24$;
})();
return reply;
}
fetch(id) {
let t24, t24$;
if (id == null) dart.nullFailed(I[45], 2340, 45, "id");
let resource = this[S$._resources]._get(id);
let request = this[S$._resourceRequests]._get(id);
if (request != null) {
if (resource != null)
return new (T$.AsyncReplyOfDistributedResource()).ready(resource);
else
return request;
} else if (resource != null && !dart.test(resource.suspended)) return new (T$.AsyncReplyOfDistributedResource()).ready(resource);
let reply = new (T$.AsyncReplyOfDistributedResource()).new();
this[S$._resourceRequests].add(id, reply);
t24$ = (t24 = this.sendRequest(0), (() => {
t24.addUint32(id);
return t24;
})()).done();
(() => {
t24$.then(core.Null, dart.fn(rt => {
let t25, t25$, t25$0;
if (rt != null) {
let dr = null;
if (resource == null) {
let template = Warehouse.Warehouse.getTemplateByClassId(Guid.Guid.as(rt[S$.$_get](0)), TemplateType.TemplateType.Wrapper);
if ((t25 = template, t25 == null ? null : t25.definedType) != null) {
dr = Warehouse.Warehouse.createInstance(DistributedResource.DistributedResource, dart.nullCast((t25$ = template, t25$ == null ? null : t25$.definedType), core.Type));
dr.internal_init(this, id, core.int.as(rt[S$.$_get](1)), core.String.as(rt[S$.$_get](2)));
} else {
dr = new DistributedResource.DistributedResource.new();
dr.internal_init(this, id, core.int.as(rt[S$.$_get](1)), core.String.as(rt[S$.$_get](2)));
}
} else
dr = resource;
let transmissionType = TransmissionType.TransmissionType.as(rt[S$.$_get](3));
let content = DC.DC.as(rt[S$.$_get](4));
t25$0 = this.getTemplate(Guid.Guid.as(rt[S$.$_get](0)));
(() => {
t25$0.then(core.Null, dart.fn(tmp => {
let t26;
if (resource == null) {
t26 = Warehouse.Warehouse.put(DistributedResource.DistributedResource, dart.toString(id), dr, this, null, tmp);
(() => {
t26.then(core.Null, dart.fn(ok => {
let t27;
t27 = Codec.Codec.parse(content, 0, this, transmissionType).reply.then(core.Null, dart.fn(results => {
let pvs = T$.JSArrayOfPropertyValue().of([]);
let ar = core.List.as(results);
for (let i = 0; i < dart.notNull(ar[S$.$length]); i = i + 3)
pvs[S$.$add](new PropertyValue.PropertyValue.new(ar[S$.$_get](i + 2), core.int.as(ar[S$.$_get](i)), core.DateTime.as(ar[S$.$_get](i + 1))));
dr.internal_attach(pvs);
this[S$._resourceRequests].remove(id);
reply.trigger(dr);
}, T$.dynamicToNull()));
(() => {
t27.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2403, 32, "ex");
return reply.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfDistributedResource()));
return t27;
})();
}, T$.DistributedResourceNToNull()));
t26.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2405, 28, "ex");
return reply.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfDistributedResource()));
return t26;
})();
} else {
Codec.Codec.parse(content, 0, this, transmissionType).reply.then(core.Null, dart.fn(results => {
if (results != null) {
let pvs = T$.JSArrayOfPropertyValue().of([]);
let ar = core.List.as(results);
for (let i = 0; i < dart.notNull(ar[S$.$length]); i = i + 3)
pvs[S$.$add](new PropertyValue.PropertyValue.new(ar[S$.$_get](i + 2), core.int.as(ar[S$.$_get](i)), core.DateTime.as(ar[S$.$_get](i + 1))));
dr.internal_attach(pvs);
}
this[S$._resourceRequests].remove(id);
reply.trigger(dr);
}, T$.dynamicToNull()));
}
}, T$.TypeTemplateNToNull()));
t25$0.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2427, 22, "ex");
reply.triggerError(ex);
}, T$.AsyncExceptionToNull()));
return t25$0;
})();
} else {
reply.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
t24$.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2434, 16, "ex");
reply.triggerError(ex);
}, T$.AsyncExceptionToNull()));
return t24$;
})();
return reply;
}
getChildren(resource) {
let t25, t24;
if (resource == null) dart.nullFailed(I[45], 2441, 54, "resource");
let rt = new (T$.AsyncReplyOfListOfIResourceN()).new();
t24 = this.sendRequest(13);
(() => {
t24.addUint32(dart.nullCast((t25 = resource.instance, t25 == null ? null : t25.id), core.int));
t24.done().then(dart.dynamic, dart.fn(ar => {
let t25;
if (ar != null) {
let dataType = TransmissionType.TransmissionType.as(ar[S$.$_get](0));
let data = DC.DC.as(ar[S$.$_get](1));
t25 = Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn(resources => {
rt.trigger(T$.ListOfIResourceN().as(resources));
}, T$.dynamicToNull()));
(() => {
t25.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2454, 22, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfListOfIResourceN()));
return t25;
})();
} else {
rt.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
return t24;
})();
return rt;
}
getParents(resource) {
let t24;
if (resource == null) dart.nullFailed(I[45], 2463, 53, "resource");
let rt = new (T$.AsyncReplyOfListOfIResourceN()).new();
t24 = this.sendRequest(14);
(() => {
t24.addUint32(dart.nullCast(resource.instance, Instance.Instance).id);
t24.done().then(dart.dynamic, dart.fn(ar => {
let t25;
if (ar != null) {
let dataType = TransmissionType.TransmissionType.as(ar[S$.$_get](0));
let data = DC.DC.as(ar[S$.$_get](1));
t25 = Codec.Codec.parse(data, 0, this, dataType).reply.then(dart.dynamic, dart.fn(resources => {
rt.trigger(T$.ListOfIResource().as(resources));
}, T$.dynamicToNull()));
(() => {
t25.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2475, 22, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfListOfIResourceN()));
return t25;
})();
} else {
rt.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
return t24;
})();
return rt;
}
removeAttributes(resource, attributes = null) {
let t25, t24, t24$, t25$, t24$0, t24$1;
if (resource == null) dart.nullFailed(I[45], 2484, 47, "resource");
let rt = new (T$.AsyncReplyOfbool()).new();
if (attributes == null) {
t24$ = (t24 = this.sendRequest(26), (() => {
t24.addUint32(dart.nullCast((t25 = resource.instance, t25 == null ? null : t25.id), core.int));
return t24;
})()).done();
(() => {
t24$.then(core.bool, dart.fn(ar => rt.trigger(true), T$.ListNToAsyncReplyOfbool()));
t24$.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2493, 18, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfbool()));
return t24$;
})();
} else {
let attrs = DC.DC.stringArrayToBytes(attributes);
t24$1 = (t24$0 = this.sendRequest(29), (() => {
t24$0.addUint32(dart.nullCast((t25$ = resource.instance, t25$ == null ? null : t25$.id), core.int));
t24$0.addInt32(attrs.length);
t24$0.addDC(attrs);
return t24$0;
})()).done();
(() => {
t24$1.then(dart.dynamic, dart.fn(ar => rt.trigger(true), T$.ListNToAsyncReplyOfbool()));
t24$1.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2502, 18, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfbool()));
return t24$1;
})();
}
return rt;
}
setAttributes(resource, attributes, clearAttributes = false) {
let t25, t24;
if (resource == null) dart.nullFailed(I[45], 2509, 17, "resource");
if (attributes == null) dart.nullFailed(I[45], 2509, 48, "attributes");
if (clearAttributes == null) dart.nullFailed(I[45], 2510, 13, "clearAttributes");
let rt = new (T$.AsyncReplyOfbool()).new();
t24 = this.sendRequest(dart.test(clearAttributes) ? 25 : 28);
(() => {
t24.addUint32(dart.nullCast((t25 = resource.instance, t25 == null ? null : t25.id), core.int));
t24.addDC(Codec.Codec.compose(attributes, this));
t24.done().then(dart.dynamic, dart.fn(ar => rt.trigger(true), T$.ListNToAsyncReplyOfbool())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2520, 19, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfbool()));
return t24;
})();
return rt;
}
getAttributes(resource, attributes = null) {
let t25, t24, t24$, t25$, t24$0, t24$1;
if (resource == null) dart.nullFailed(I[45], 2525, 60, "resource");
let rt = new (T$.AsyncReplyOfMapOfString$dynamic()).new();
if (attributes == null) {
t24$ = (t24 = this.sendRequest(24), (() => {
t24.addUint32(dart.nullCast((t25 = resource.instance, t25 == null ? null : t25.id), core.int));
return t24;
})()).done();
(() => {
t24$.then(core.Null, dart.fn(ar => {
let t25;
if (ar != null) {
let dataType = TransmissionType.TransmissionType.as(ar[S$.$_get](0));
let data = DC.DC.as(ar[S$.$_get](1));
t25 = Codec.Codec.parse(data, 0, this, dataType).reply.then(core.Null, dart.fn(st => {
let t25;
t25 = resource.instance;
t25 == null ? null : t25.setAttributes(T$.MapOfString$dynamic().as(st));
rt.trigger(T$.MapOfString$dynamic().as(st));
}, T$.dynamicToNull()));
(() => {
t25.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2542, 24, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfMapOfString$dynamic()));
return t25;
})();
} else {
rt.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
return t24$;
})();
} else {
let attrs = DC.DC.stringArrayToBytes(attributes);
t24$1 = (t24$0 = this.sendRequest(27), (() => {
t24$0.addUint32(dart.nullCast((t25$ = resource.instance, t25$ == null ? null : t25$.id), core.int));
t24$0.addInt32(attrs.length);
t24$0.addDC(attrs);
return t24$0;
})()).done();
(() => {
t24$1.then(core.Null, dart.fn(ar => {
let t25;
if (ar != null) {
let dataType = TransmissionType.TransmissionType.as(ar[S$.$_get](0));
let data = DC.DC.as(ar[S$.$_get](1));
t25 = Codec.Codec.parse(data, 0, this, dataType).reply;
(() => {
t25.then(core.Null, dart.fn(st => {
let t26;
t26 = resource.instance;
t26 == null ? null : t26.setAttributes(T$.MapOfString$dynamic().as(st));
rt.trigger(T$.MapOfString$dynamic().as(st));
}, T$.dynamicToNull()));
t25.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2565, 24, "ex");
return rt.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfMapOfString$dynamic()));
return t25;
})();
} else {
rt.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
return t24$1;
})();
}
return rt;
}
getRecord(resource, fromDate, toDate) {
let t24;
if (resource == null) dart.nullFailed(I[45], 2583, 17, "resource");
if (fromDate == null) dart.nullFailed(I[45], 2583, 36, "fromDate");
if (toDate == null) dart.nullFailed(I[45], 2583, 55, "toDate");
if (DistributedResource.DistributedResource.is(resource)) {
let dr = resource;
if (!dart.equals(dr.connection, this)) return new (T$.AsyncReplyOfKeyListNOfPropertyTemplate$ListOfPropertyValue()).ready(null);
let reply = new (T$.AsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue()).new();
t24 = this.sendRequest(12);
(() => {
t24.addUint32(dart.nullCast(dr.id, core.int));
t24.addDateTime(fromDate);
t24.addDateTime(toDate);
t24.done().then(dart.dynamic, dart.fn(rt => {
if (rt != null) {
let content = DC.DC.as(rt[S$.$_get](0));
DataDeserializer.DataDeserializer.historyParser(content, 0, content.length, resource, this).then(T$.KeyListOfPropertyTemplate$ListOfPropertyValue(), dart.fn(history => {
if (history == null) dart.nullFailed(I[45], 2604, 24, "history");
return reply.trigger(history);
}, T$.KeyListOfPropertyTemplate$ListOfPropertyValueToAsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue()));
} else {
reply.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2608, 19, "ex");
return reply.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfKeyListOfPropertyTemplate$ListOfPropertyValue()));
return t24;
})();
return reply;
} else
return new (T$.AsyncReplyOfKeyListNOfPropertyTemplate$ListOfPropertyValue()).ready(null);
}
query(path) {
let t24;
if (path == null) dart.nullFailed(I[45], 2621, 45, "path");
let str = DC.DC.stringToBytes(path);
let reply = new (T$.AsyncReplyOfListOfIResourceN()).new();
t24 = this.sendRequest(11);
(() => {
t24.addUint16(str.length);
t24.addDC(str);
t24.done().then(dart.dynamic, dart.fn(ar => {
let t25;
if (ar != null) {
let dataType = TransmissionType.TransmissionType.as(ar[S$.$_get](0));
let data = DC.DC.as(ar[S$.$_get](1));
t25 = Codec.Codec.parse(data, 0, this, dataType).reply.then(T$.ListOfIResourceN(), dart.fn(resources => reply.trigger(core.List.as(resources)[S$.$cast](T$.IResourceN())), T$.dynamicToAsyncReplyOfListOfIResourceN()));
(() => {
t25.error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2635, 22, "ex");
return reply.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfListOfIResourceN()));
return t25;
})();
} else {
reply.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull())).error(dart.fn(ex => {
if (ex == null) dart.nullFailed(I[45], 2639, 17, "ex");
return reply.triggerError(ex);
}, T$.AsyncExceptionToAsyncReplyOfListOfIResourceN()));
return t24;
})();
return reply;
}
create(store, parent, className, parameters, attributes, values) {
let t24, t24$, t24$0;
if (store == null) dart.nullFailed(I[45], 2654, 14, "store");
if (parent == null) dart.nullFailed(I[45], 2655, 17, "parent");
if (className == null) dart.nullFailed(I[45], 2656, 14, "className");
if (parameters == null) dart.nullFailed(I[45], 2657, 12, "parameters");
if (attributes == null) dart.nullFailed(I[45], 2658, 28, "attributes");
if (values == null) dart.nullFailed(I[45], 2659, 28, "values");
let reply = new (T$.AsyncReplyOfDistributedResourceN()).new();
let pkt = (t24 = new BinaryList.BinaryList.new(), (() => {
t24.addUint32(dart.nullCast(store.instance, Instance.Instance).id);
t24.addUint32(dart.nullCast(parent.instance, Instance.Instance).id);
t24.addUint8(className.length);
t24.addString(className);
t24.addDC(Codec.Codec.compose(parameters, this));
t24.addDC(Codec.Codec.compose(attributes, this));
t24.addDC(Codec.Codec.compose(values, this));
return t24;
})());
pkt.insertInt32(8, pkt.length);
t24$0 = (t24$ = this.sendRequest(3), (() => {
t24$.addDC(pkt.toDC());
return t24$;
})()).done();
(() => {
t24$0.then(core.Null, dart.fn(args => {
if (args != null) {
let rid = args[S$.$_get](0);
this.fetch(core.int.as(rid)).then(core.Null, dart.fn(r => {
if (r == null) dart.nullFailed(I[45], 2677, 35, "r");
reply.trigger(r);
}, T$.DistributedResourceToNull()));
} else {
reply.triggerError(core.Exception.new("Null response"));
}
}, T$.ListNToNull()));
return t24$0;
})();
return reply;
}
[S$._instance_ResourceDestroyed](resource) {
let t24;
if (resource == null) dart.nullFailed(I[45], 2688, 41, "resource");
this[S$._unsubscrive](resource);
t24 = this.sendEvent(1);
(() => {
t24.addUint32(dart.nullCast(resource.instance, Instance.Instance).id);
t24.done();
return t24;
})();
}
[S$._instance_PropertyModified](info) {
let t25, t24;
if (info == null) dart.nullFailed(I[45], 2696, 60, "info");
t24 = this.sendEvent(16);
(() => {
t24.addUint32(dart.nullCast((t25 = info.resource.instance, t25 == null ? null : t25.id), core.int));
t24.addUint8(info.propertyTemplate.index);
t24.addDC(Codec.Codec.compose(info.value, this));
t24.done();
return t24;
})();
}
[S$._instance_EventOccurred](info) {
let t24, t24$;
if (info == null) dart.nullFailed(I[45], 2710, 50, "info");
if (dart.test(info.eventTemplate.listenable)) {
if (this[S$._subscriptions][S$.$_get](info.resource) == null) return;
if (!dart.test(dart.nullCheck(this[S$._subscriptions][S$.$_get](info.resource))[S$.$contains](info.eventTemplate.index))) return;
}
if (info.receivers != null && this[S$._session] != null) if (!dart.test(dart.nullCheck(info.receivers)(dart.nullCheck(this[S$._session])))) return;
if ((t24 = info.resource.instance, t24 == null ? null : t24.applicable(dart.nullCast(this[S$._session], Session.Session), ActionType.ActionType.ReceiveEvent, info.eventTemplate, info.issuer)) == Ruling.Ruling.Denied) return;
t24$ = this.sendEvent(17);
(() => {
t24$.addUint32(dart.nullCast(info.resource.instance, Instance.Instance).id);
t24$.addUint8(info.eventTemplate.index);
t24$.addDC(Codec.Codec.compose(info.value, this));
t24$.done();
return t24$;
})();
}
getProperty(name) {
if (name == null) dart.nullFailed(I[45], 2741, 22, "name");
return null;
}
invoke(name, $arguments) {
if (name == null) dart.nullFailed(I[45], 2744, 17, "name");
if ($arguments == null) dart.nullFailed(I[45], 2744, 28, "arguments");
return null;
}
setProperty(name, value) {
if (name == null) dart.nullFailed(I[45], 2747, 22, "name");
return true;
}
get template() {
return new TemplateDescriber.TemplateDescriber.new("Esiur.Net.IIP.DistributedConnection");
}
};
(DistributedConnection.DistributedConnection.new = function() {
this[S$._openReply] = null;
this[S$._server] = null;
this[S$._packet] = new IIPPacket.IIPPacket.new();
this[S$._authPacket] = new IIPAuthPacket.IIPAuthPacket.new();
this[S$._session] = null;
this[S$._localPasswordOrToken] = null;
this[S$._localNonce] = null;
this[S$._remoteNonce] = null;
this[S$._hostname] = null;
this[S$._port] = 10518;
this[S$._ready] = false;
this[S$._readyToEstablish] = false;
this[S$._resources] = new (T$.KeyListOfint$DistributedResource()).new();
this[S$._resourceRequests] = new (T$.KeyListOfint$AsyncReplyOfDistributedResource()).new();
this[S$._templateRequests] = new (T$.KeyListOfGuid$AsyncReplyOfTypeTemplateN()).new();
this[S$._templates] = new (T$.LinkedMapOfGuid$TypeTemplate()).new();
this[S$._requests] = new (T$.KeyListOfint$AsyncReply()).new();
this[S$._callbackCounter] = 0;
this[S$._queue] = new (T$.AsyncQueueOfDistributedResourceQueueItem()).new();
this[S$._subscriptions] = new (T$.LinkedMapOfIResource$ListOfint()).new();
this[S$.variables] = new (T$.KeyListOfString$dynamic()).new();
this[S$.instance$1] = null;
DistributedConnection.DistributedConnection.__proto__.new.call(this);
this[S$._session] = new Session.Session.new(new HostAuthentication.HostAuthentication.new(), new ClientAuthentication.ClientAuthentication.new());
this.init();
}).prototype = DistributedConnection.DistributedConnection.prototype;
dart.addTypeTests(DistributedConnection.DistributedConnection);
dart.addTypeCaches(DistributedConnection.DistributedConnection);
dart.setMethodSignature(DistributedConnection.DistributedConnection, () => ({
__proto__: dart.getMethods(DistributedConnection.DistributedConnection.__proto__),
remove: dart.fnType(core.bool, [IResource.IResource]),
sendParams: dart.fnType(SendList.SendList, [], [dart.nullable(AsyncReply$.AsyncReply$(dart.nullable(core.List)))]),
trigger: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [ResourceTrigger.ResourceTrigger]),
connect: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [], {domain: dart.nullable(core.String), hostname: dart.nullable(core.String), method: AuthenticationMethod.AuthenticationMethod, passwordOrToken: dart.nullable(DC.DC), port: dart.nullable(core.int), secureWebSocket: core.bool, socket: dart.nullable(ISocket.ISocket), tokenIndex: dart.nullable(core.int), useWebsocket: core.bool, username: dart.nullable(core.String)}, {}),
reconnect: dart.fnType(async.Future$(core.bool), []),
[S$._declare]: dart.fnType(dart.dynamic, []),
link: dart.fnType(dart.nullable(core.String), [IResource.IResource]),
init: dart.fnType(dart.void, []),
processPacket: dart.fnType(core.int, [DC.DC, core.int, core.int, NetworkBuffer.NetworkBuffer, core.int]),
put: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [IResource.IResource]),
record: dart.fnType(core.bool, [IResource.IResource, core.String, dart.dynamic, dart.nullable(core.int), dart.nullable(core.DateTime)]),
modify: dart.fnType(core.bool, [IResource.IResource, core.String, dart.dynamic, dart.nullable(core.int), dart.nullable(core.DateTime)]),
sendRequest: dart.fnType(SendList.SendList, [core.int]),
sendReply: dart.fnType(SendList.SendList, [core.int, core.int]),
sendEvent: dart.fnType(SendList.SendList, [core.int]),
sendListenRequest: dart.fnType(AsyncReply$.AsyncReply, [core.int, core.int]),
sendUnlistenRequest: dart.fnType(AsyncReply$.AsyncReply, [core.int, core.int]),
sendInvoke: dart.fnType(AsyncReply$.AsyncReply, [core.int, core.int, core.Map$(IntType.UInt8, dart.dynamic)]),
sendDetachRequest: dart.fnType(dart.nullable(AsyncReply$.AsyncReply), [core.int]),
sendError: dart.fnType(dart.void, [ErrorType.ErrorType, core.int, core.int], [dart.nullable(core.String)]),
sendProgress: dart.fnType(dart.void, [core.int, core.int, core.int]),
sendChunk: dart.fnType(dart.void, [core.int, dart.dynamic]),
iipReply: dart.fnType(dart.void, [core.int], [dart.nullable(core.List)]),
iipReplyInvoke: dart.fnType(dart.void, [core.int, TransmissionType.TransmissionType, DC.DC]),
iipReportError: dart.fnType(dart.void, [core.int, ErrorType.ErrorType, core.int, dart.nullable(core.String)]),
iipReportProgress: dart.fnType(dart.void, [core.int, ProgressType.ProgressType, core.int, core.int]),
iipReportChunk: dart.fnType(dart.void, [core.int, TransmissionType.TransmissionType, DC.DC]),
iipEventResourceReassigned: dart.fnType(dart.void, [core.int, core.int]),
iipEventResourceDestroyed: dart.fnType(dart.void, [core.int]),
iipEventPropertyUpdated: dart.fnType(dart.void, [core.int, core.int, TransmissionType.TransmissionType, DC.DC]),
iipEventEventOccurred: dart.fnType(dart.void, [core.int, core.int, TransmissionType.TransmissionType, DC.DC]),
iipEventChildAdded: dart.fnType(dart.void, [core.int, core.int]),
iipEventChildRemoved: dart.fnType(dart.void, [core.int, core.int]),
iipEventRenamed: dart.fnType(dart.void, [core.int, core.String]),
iipEventAttributesUpdated: dart.fnType(dart.void, [core.int, DC.DC]),
iipRequestAttachResource: dart.fnType(dart.void, [core.int, core.int]),
[S$._attributes_OnModified]: dart.fnType(dart.void, [core.String, dart.dynamic, dart.dynamic, KeyList$.KeyList$(core.String, dart.dynamic)]),
[S$._children_OnRemoved]: dart.fnType(dart.void, [Instance.Instance, IResource.IResource]),
[S$._children_OnAdd]: dart.fnType(dart.void, [Instance.Instance, IResource.IResource]),
[S$._subscribe]: dart.fnType(dart.void, [IResource.IResource]),
[S$._unsubscrive]: dart.fnType(dart.void, [IResource.IResource]),
iipRequestReattachResource: dart.fnType(dart.void, [core.int, core.int, core.int]),
iipRequestDetachResource: dart.fnType(dart.void, [core.int, core.int]),
iipRequestCreateResource: dart.fnType(dart.void, [core.int, core.int, core.int, DC.DC]),
iipRequestDeleteResource: dart.fnType(dart.void, [core.int, core.int]),
iipRequestGetAttributes: dart.fnType(dart.void, [core.int, core.int, DC.DC], [core.bool]),
iipRequestAddChild: dart.fnType(dart.void, [core.int, core.int, core.int]),
iipRequestRemoveChild: dart.fnType(dart.void, [core.int, core.int, core.int]),
iipRequestRenameResource: dart.fnType(dart.void, [core.int, core.int, core.String]),
iipRequestResourceChildren: dart.fnType(dart.void, [core.int, core.int]),
iipRequestResourceParents: dart.fnType(dart.void, [core.int, core.int]),
iipRequestClearAttributes: dart.fnType(dart.void, [core.int, core.int, DC.DC], [core.bool]),
iipRequestUpdateAttributes: dart.fnType(dart.void, [core.int, core.int, DC.DC], [core.bool]),
iipRequestLinkTemplates: dart.fnType(dart.void, [core.int, core.String]),
iipRequestTemplateFromClassName: dart.fnType(dart.void, [core.int, core.String]),
iipRequestTemplateFromClassId: dart.fnType(dart.void, [core.int, Guid.Guid]),
iipRequestTemplateFromResourceId: dart.fnType(dart.void, [core.int, core.int]),
iipRequestQueryResources: dart.fnType(dart.void, [core.int, core.String]),
IIPRequestResourceAttribute: dart.fnType(dart.void, [core.int, core.int]),
iipRequestInvokeFunction: dart.fnType(dart.void, [core.int, core.int, core.int, TransmissionType.TransmissionType, DC.DC]),
iipRequestListen: dart.fnType(dart.void, [core.int, core.int, core.int]),
iipRequestUnlisten: dart.fnType(dart.void, [core.int, core.int, core.int]),
iipRequestInquireResourceHistory: dart.fnType(dart.void, [core.int, core.int, core.DateTime, core.DateTime]),
iipRequestSetProperty: dart.fnType(dart.void, [core.int, core.int, core.int, TransmissionType.TransmissionType, DC.DC]),
getTemplate: dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(TypeTemplate.TypeTemplate)), [Guid.Guid]),
get: dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(IResource.IResource)), [core.String]),
retrieve: dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(IResource.IResource)), [core.int]),
getLinkTemplates: dart.fnType(AsyncReply$.AsyncReply$(core.List$(TypeTemplate.TypeTemplate)), [core.String]),
fetch: dart.fnType(AsyncReply$.AsyncReply$(DistributedResource.DistributedResource), [core.int]),
getChildren: dart.fnType(AsyncReply$.AsyncReply$(core.List$(dart.nullable(IResource.IResource))), [IResource.IResource]),
getParents: dart.fnType(AsyncReply$.AsyncReply$(core.List$(dart.nullable(IResource.IResource))), [IResource.IResource]),
removeAttributes: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [IResource.IResource], [dart.nullable(core.List$(core.String))]),
setAttributes: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [IResource.IResource, core.Map$(core.String, dart.dynamic)], [core.bool]),
getAttributes: dart.fnType(AsyncReply$.AsyncReply$(core.Map$(core.String, dart.dynamic)), [IResource.IResource], [dart.nullable(core.List$(core.String))]),
getRecord: dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(KeyList$.KeyList$(PropertyTemplate.PropertyTemplate, core.List$(PropertyValue.PropertyValue)))), [IResource.IResource, core.DateTime, core.DateTime]),
query: dart.fnType(AsyncReply$.AsyncReply$(core.List$(dart.nullable(IResource.IResource))), [core.String]),
create: dart.fnType(AsyncReply$.AsyncReply$(dart.nullable(DistributedResource.DistributedResource)), [IStore.IStore, IResource.IResource, core.String, core.List, core.Map$(core.String, dart.dynamic), core.Map$(core.String, dart.dynamic)]),
[S$._instance_ResourceDestroyed]: dart.fnType(dart.dynamic, [IResource.IResource]),
[S$._instance_PropertyModified]: dart.fnType(dart.void, [PropertyModificationInfo$.PropertyModificationInfo]),
[S$._instance_EventOccurred]: dart.fnType(dart.void, [EventOccurredInfo.EventOccurredInfo]),
getProperty: dart.fnType(dart.dynamic, [core.String]),
invoke: dart.fnType(dart.dynamic, [core.String, core.List]),
setProperty: dart.fnType(dart.dynamic, [core.String, dart.dynamic])
}));
dart.setGetterSignature(DistributedConnection.DistributedConnection, () => ({
__proto__: dart.getGetters(DistributedConnection.DistributedConnection.__proto__),
localUsername: core.String,
remoteUsername: core.String,
session: dart.nullable(Session.Session),
template: TemplateDescriber.TemplateDescriber
}));
dart.setLibraryUri(DistributedConnection.DistributedConnection, I[45]);
dart.setFieldSignature(DistributedConnection.DistributedConnection, () => ({
__proto__: dart.getFields(DistributedConnection.DistributedConnection.__proto__),
[S$._openReply]: dart.fieldType(dart.nullable(AsyncReply$.AsyncReply$(core.bool))),
[S$._server]: dart.fieldType(dart.nullable(DistributedServer.DistributedServer)),
[S$._packet]: dart.fieldType(IIPPacket.IIPPacket),
[S$._authPacket]: dart.fieldType(IIPAuthPacket.IIPAuthPacket),
[S$._session]: dart.fieldType(dart.nullable(Session.Session)),
[S$._localPasswordOrToken]: dart.fieldType(dart.nullable(DC.DC)),
[S$._localNonce]: dart.fieldType(dart.nullable(DC.DC)),
[S$._remoteNonce]: dart.fieldType(dart.nullable(DC.DC)),
[S$._hostname]: dart.fieldType(dart.nullable(core.String)),
[S$._port]: dart.fieldType(core.int),
[S$._ready]: dart.fieldType(core.bool),
[S$._readyToEstablish]: dart.fieldType(core.bool),
[S$._resources]: dart.fieldType(KeyList$.KeyList$(core.int, DistributedResource.DistributedResource)),
[S$._resourceRequests]: dart.fieldType(KeyList$.KeyList$(core.int, AsyncReply$.AsyncReply$(DistributedResource.DistributedResource))),
[S$._templateRequests]: dart.fieldType(KeyList$.KeyList$(Guid.Guid, AsyncReply$.AsyncReply$(dart.nullable(TypeTemplate.TypeTemplate)))),
[S$._templates]: dart.fieldType(core.Map$(Guid.Guid, TypeTemplate.TypeTemplate)),
[S$._requests]: dart.fieldType(KeyList$.KeyList$(core.int, AsyncReply$.AsyncReply)),
[S$._callbackCounter]: dart.fieldType(core.int),
[S$._queue]: dart.fieldType(AsyncQueue$.AsyncQueue$(DistributedResourceQueueItem.DistributedResourceQueueItem)),
[S$._subscriptions]: dart.fieldType(core.Map$(IResource.IResource, core.List$(core.int))),
variables: dart.finalFieldType(KeyList$.KeyList$(core.String, dart.dynamic)),
instance: dart.fieldType(dart.nullable(Instance.Instance))
}));
DistributedPropertyContext.DistributedPropertyContext = class DistributedPropertyContext$ extends core.Object {
get value() {
return this[S$.value$4];
}
set value(value) {
this[S$.value$4] = value;
}
get connection() {
return this[S$.connection$1];
}
set connection(value) {
this[S$.connection$1] = value;
}
get method() {
return this[S$.method];
}
set method(value) {
this[S$.method] = value;
}
static ['_#new#tearOff'](method) {
return new DistributedPropertyContext.DistributedPropertyContext.new(method);
}
static ['_#setter#tearOff'](value, connection) {
return new DistributedPropertyContext.DistributedPropertyContext.setter(value, connection);
}
};
(DistributedPropertyContext.DistributedPropertyContext.new = function(method) {
this[S$.connection$1] = null;
this[S$.value$4] = null;
this[S$.method] = method;
}).prototype = DistributedPropertyContext.DistributedPropertyContext.prototype;
(DistributedPropertyContext.DistributedPropertyContext.setter = function(value, connection) {
this[S$.method] = null;
this[S$.value$4] = value;
this[S$.connection$1] = connection;
}).prototype = DistributedPropertyContext.DistributedPropertyContext.prototype;
dart.addTypeTests(DistributedPropertyContext.DistributedPropertyContext);
dart.addTypeCaches(DistributedPropertyContext.DistributedPropertyContext);
dart.setLibraryUri(DistributedPropertyContext.DistributedPropertyContext, I[46]);
dart.setFieldSignature(DistributedPropertyContext.DistributedPropertyContext, () => ({
__proto__: dart.getFields(DistributedPropertyContext.DistributedPropertyContext.__proto__),
value: dart.fieldType(dart.dynamic),
connection: dart.fieldType(dart.nullable(DistributedConnection.DistributedConnection)),
method: dart.fieldType(dart.nullable(dart.fnType(dart.dynamic, [DistributedConnection.DistributedConnection])))
}));
DistributedResource.DistributedResource = class DistributedResource$ extends IResource.IResource {
get connection() {
return this[S$._connection];
}
get link() {
return this[S$._link];
}
get id() {
return this[S$._instanceId];
}
get suspended() {
return this[S$._suspended];
}
trigger(trigger) {
if (trigger == null) dart.nullFailed(I[47], 83, 44, "trigger");
return new (T$.AsyncReplyOfbool()).ready(true);
}
destroy() {
let t24;
this[S$._destroyed] = true;
this[S$._attached] = false;
t24 = this[S$._connection];
t24 == null ? null : t24.sendDetachRequest(dart.nullCast(this[S$._instanceId], core.int));
this.emitArgs("destroy", [this]);
}
suspend() {
this[S$._suspended] = true;
this[S$._attached] = false;
}
get attached() {
return this[S$._attached];
}
internal_init(connection, instanceId, age, link) {
if (connection == null) dart.nullFailed(I[47], 132, 29, "connection");
if (instanceId == null) dart.nullFailed(I[47], 132, 45, "instanceId");
if (age == null) dart.nullFailed(I[47], 132, 61, "age");
if (link == null) dart.nullFailed(I[47], 132, 73, "link");
this[S$._link] = link;
this[S$._connection] = connection;
this[S$._instanceId] = instanceId;
this[S$._age] = age;
}
internal_serialize() {
return T$.ListOfPropertyValue().generate(this[S$._properties$1][S$.$length], dart.fn(i => {
let t24, t24$;
if (i == null) dart.nullFailed(I[47], 153, 10, "i");
return new PropertyValue.PropertyValue.new(this[S$._properties$1][S$.$_get](i), dart.nullCast((t24 = this.instance, t24 == null ? null : t24.getAge(i)), core.int), dart.nullCast((t24$ = this.instance, t24$ == null ? null : t24$.getModificationDate(i)), core.DateTime));
}, T$.intToPropertyValue()));
}
internal_attach(properties) {
let t24, t24$;
if (properties == null) dart.nullFailed(I[47], 159, 44, "properties");
if (dart.test(this[S$._attached]))
return false;
else {
this[S$._suspended] = false;
for (let i = 0; i < dart.notNull(properties[S$.$length]); i = i + 1) {
t24 = this.instance;
t24 == null ? null : t24.setAge(i, properties[S$.$_get](i).age);
t24$ = this.instance;
t24$ == null ? null : t24$.setModificationDate(i, properties[S$.$_get](i).date);
this[S$._properties$1][S$.$add](properties[S$.$_get](i).value);
}
this[S$._attached] = true;
if (dart.notNull(this[S$._queued_updates][S$.$length]) > 0) {
this[S$._queued_updates][S$.$forEach](dart.fn(kv => {
if (kv == null) dart.nullFailed(I[47], 187, 23, "kv");
return this.internal_updatePropertyByIndex(kv.key, kv.value);
}, T$.KeyValuePairOfint$dynamicTovoid()));
this[S$._queued_updates][S$.$clear]();
}
}
return true;
}
listen(event) {
let t24, t24$;
if (dart.test(this[S$._destroyed])) dart.throw(core.Exception.new("Trying to access destroyed object"));
if (dart.test(this[S$._suspended])) dart.throw(core.Exception.new("Trying to access suspended object"));
let et = EventTemplate.EventTemplate.is(event) ? event : (t24 = this.instance, t24 == null ? null : t24.template.getEventTemplateByName(dart.toString(event)));
if (et == null) return new AsyncReply$.AsyncReply.new().triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.MethodNotFound.index, ""));
if (!dart.test(et.listenable)) return new AsyncReply$.AsyncReply.new().triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.NotListenable.index, ""));
return dart.nullCast((t24$ = this[S$._connection], t24$ == null ? null : t24$.sendListenRequest(dart.nullCast(this[S$._instanceId], core.int), et.index)), AsyncReply$.AsyncReply);
}
unlisten(event) {
let t24, t24$;
if (dart.test(this[S$._destroyed])) dart.throw(core.Exception.new("Trying to access destroyed object"));
if (dart.test(this[S$._suspended])) dart.throw(core.Exception.new("Trying to access suspended object"));
let et = EventTemplate.EventTemplate.is(event) ? event : (t24 = this.instance, t24 == null ? null : t24.template.getEventTemplateByName(dart.toString(event)));
if (et == null) return new AsyncReply$.AsyncReply.new().triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.MethodNotFound.index, ""));
if (!dart.test(et.listenable)) return new AsyncReply$.AsyncReply.new().triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.NotListenable.index, ""));
return dart.nullCast((t24$ = this.connection, t24$ == null ? null : t24$.sendUnlistenRequest(dart.nullCast(this[S$._instanceId], core.int), et.index)), AsyncReply$.AsyncReply);
}
internal_emitEventByIndex(index, args) {
let t24, t24$;
if (index == null) dart.nullFailed(I[47], 234, 38, "index");
if (!dart.test(this[S$._attached])) return;
let et = (t24 = this.instance, t24 == null ? null : t24.template.getEventTemplateByIndex(index));
if (et != null) {
this.emitArgs(et.name, [args]);
t24$ = this.instance;
t24$ == null ? null : t24$.emitResourceEvent(null, null, et, args);
}
}
internal_invoke(index, args) {
let t24;
if (index == null) dart.nullFailed(I[47], 245, 43, "index");
if (args == null) dart.nullFailed(I[47], 245, 70, "args");
if (dart.test(this[S$._destroyed])) dart.throw(core.Exception.new("Trying to access destroyed object"));
if (dart.test(this[S$._suspended])) dart.throw(core.Exception.new("Trying to access suspended object"));
if (this.instance == null) dart.throw(core.Exception.new("Object not initialized."));
let ins = dart.nullCast(this.instance, Instance.Instance);
if (dart.notNull(index) >= dart.notNull(ins.template.functions[S$.$length])) dart.throw(core.Exception.new("Function index is incorrect"));
return dart.nullCast((t24 = this[S$._connection], t24 == null ? null : t24.sendInvoke(dart.nullCast(this[S$._instanceId], core.int), index, args)), AsyncReply$.AsyncReply);
}
_get(index) {
let t24;
if (index == null) dart.nullFailed(I[47], 260, 22, "index");
let pt = (t24 = this.instance, t24 == null ? null : t24.template.getPropertyTemplateByName(index));
if (pt != null) return this.get(pt.index);
}
_set(index, value$) {
let value = value$;
let t24;
if (index == null) dart.nullFailed(I[47], 265, 23, "index");
let pt = (t24 = this.instance, t24 == null ? null : t24.template.getPropertyTemplateByName(index));
if (pt != null) this.set(pt.index, value);
return value$;
}
[S$._getMemberName](symbol) {
if (symbol == null) dart.nullFailed(I[47], 270, 32, "symbol");
let memberName = dart.toString(symbol);
if (memberName[S$.$endsWith]("=\")"))
return memberName[S$.$substring](8, memberName.length - 3);
else
return memberName[S$.$substring](8, memberName.length - 2);
}
noSuchMethod(invocation) {
let t24, t24$, t24$0;
if (invocation == null) dart.nullFailed(I[47], 279, 27, "invocation");
let memberName = this[S$._getMemberName](invocation.memberName);
if (dart.test(invocation.isMethod)) {
let ft = (t24 = this.instance, t24 == null ? null : t24.template.getFunctionTemplateByName(memberName));
if (dart.test(this[S$._attached]) && ft != null) {
let args = new (T$.LinkedMapOfUInt8$dynamic()).new();
for (let i = 0; i < dart.notNull(invocation.positionalArguments[S$.$length]) && i < dart.notNull(ft.arguments[S$.$length]); i = i + 1)
args[S$.$_set](new IntType.UInt8.new(i), invocation.positionalArguments[S$.$_get](i));
for (let i = invocation.positionalArguments[S$.$length]; dart.notNull(i) < dart.notNull(ft.arguments[S$.$length]); i = dart.notNull(i) + 1) {
for (let j = 0; j < dart.notNull(invocation.namedArguments[S$.$length]); j = j + 1) {
if (ft.arguments[S$.$_get](i).name == this[S$._getMemberName](invocation.namedArguments[S$.$keys][S$.$elementAt](j))) ;
args[S$.$_set](new IntType.UInt8.new(i), invocation.namedArguments[S$.$values][S$.$elementAt](j));
}
}
return this.internal_invoke(ft.index, args);
}
} else if (dart.test(invocation.isSetter)) {
let pt = (t24$ = this.instance, t24$ == null ? null : t24$.template.getPropertyTemplateByName(memberName));
if (pt != null) {
this.set(pt.index, invocation.positionalArguments[S$.$_get](0));
return true;
}
} else if (dart.test(invocation.isGetter)) {
let pt = (t24$0 = this.instance, t24$0 == null ? null : t24$0.template.getPropertyTemplateByName(memberName));
if (pt != null) {
return this.get(pt.index);
}
}
return null;
}
get(index) {
if (index == null) dart.nullFailed(I[47], 328, 11, "index");
return this[S$._properties$1][S$.$_get](index);
}
internal_updatePropertyByIndex(index, value) {
let t24, t24$;
if (index == null) dart.nullFailed(I[47], 335, 43, "index");
if (!dart.test(this[S$._attached])) {
this[S$._queued_updates][S$.$add](new (T$.KeyValuePairOfint$dynamic()).new(index, value));
} else {
let pt = (t24 = this.instance, t24 == null ? null : t24.template.getPropertyTemplateByIndex(index));
if (pt != null) {
this[S$._properties$1][S$.$_set](index, value);
t24$ = this.instance;
t24$ == null ? null : t24$.emitModification(pt, value);
}
}
}
set(index, value) {
let t24, t24$;
if (index == null) dart.nullFailed(I[47], 354, 31, "index");
if (dart.notNull(index) >= dart.notNull(this[S$._properties$1][S$.$length])) dart.throw(core.Exception.new("Property with index `" + dart.str(index) + "` not found."));
let reply = new AsyncReply$.AsyncReply.new();
let con = dart.nullCast(this[S$._connection], DistributedConnection.DistributedConnection);
let parameters = Codec.Codec.compose(value, con);
t24$ = (t24 = con.sendRequest(20), (() => {
t24.addUint32(dart.nullCast(this[S$._instanceId], core.int));
t24.addUint8(index);
t24.addDC(parameters);
return t24;
})()).done();
(() => {
t24$.then(core.Null, dart.fn(res => {
this[S$._properties$1][S$.$_set](index, value);
reply.trigger(null);
}, T$.ListNToNull()));
return t24$;
})();
return reply;
}
toString() {
let t24, t24$;
return "DR<" + dart.str((t24$ = (t24 = this.instance, t24 == null ? null : t24.template.className), t24$ == null ? "" : t24$)) + ">";
}
static ['_#new#tearOff']() {
return new DistributedResource.DistributedResource.new();
}
setProperty(name, value) {
if (name == null) dart.nullFailed(I[4], 39, 22, "name");
return this.noSuchMethod(new core._Invocation.method(C[109] || CT.C109, null, [name, value]));
}
invoke(name, $arguments) {
if (name == null) dart.nullFailed(I[4], 38, 17, "name");
if ($arguments == null) dart.nullFailed(I[4], 38, 28, "arguments");
return this.noSuchMethod(new core._Invocation.method(C[110] || CT.C110, null, [name, $arguments]));
}
getProperty(name) {
if (name == null) dart.nullFailed(I[4], 40, 22, "name");
return this.noSuchMethod(new core._Invocation.method(C[111] || CT.C111, null, [name]));
}
get template() {
return TemplateDescriber.TemplateDescriber.as(this.noSuchMethod(new core._Invocation.getter(C[112] || CT.C112)));
}
};
(DistributedResource.DistributedResource.new = function() {
this[S$._instanceId] = null;
this[S$._connection] = null;
this[S$._attached] = false;
this[S$._link] = null;
this[S$._age] = null;
this[S$._properties$1] = [];
this[S$._destroyed] = false;
this[S$._queued_updates] = T$.JSArrayOfKeyValuePairOfint$dynamic().of([]);
this[S$._suspended] = true;
DistributedResource.DistributedResource.__proto__.new.call(this);
;
}).prototype = DistributedResource.DistributedResource.prototype;
dart.addTypeTests(DistributedResource.DistributedResource);
dart.addTypeCaches(DistributedResource.DistributedResource);
dart.setMethodSignature(DistributedResource.DistributedResource, () => ({
__proto__: dart.getMethods(DistributedResource.DistributedResource.__proto__),
trigger: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [ResourceTrigger.ResourceTrigger]),
destroy: dart.fnType(dart.void, []),
suspend: dart.fnType(dart.void, []),
internal_init: dart.fnType(dart.void, [DistributedConnection.DistributedConnection, core.int, core.int, core.String]),
internal_serialize: dart.fnType(core.List$(PropertyValue.PropertyValue), []),
internal_attach: dart.fnType(core.bool, [core.List$(PropertyValue.PropertyValue)]),
listen: dart.fnType(AsyncReply$.AsyncReply, [dart.dynamic]),
unlisten: dart.fnType(AsyncReply$.AsyncReply, [dart.dynamic]),
internal_emitEventByIndex: dart.fnType(dart.void, [core.int, dart.dynamic]),
internal_invoke: dart.fnType(AsyncReply$.AsyncReply, [core.int, core.Map$(IntType.UInt8, dart.dynamic)]),
_get: dart.fnType(dart.dynamic, [core.String]),
_set: dart.fnType(dart.void, [core.String, dart.dynamic]),
[S$._getMemberName]: dart.fnType(core.String, [core.Symbol]),
get: dart.fnType(dart.dynamic, [core.int]),
internal_updatePropertyByIndex: dart.fnType(dart.void, [core.int, dart.dynamic]),
set: dart.fnType(AsyncReply$.AsyncReply, [core.int, dart.dynamic]),
setProperty: dart.fnType(dart.dynamic, [core.String, dart.dynamic]),
invoke: dart.fnType(dart.dynamic, [core.String, core.List]),
getProperty: dart.fnType(dart.dynamic, [core.String])
}));
dart.setGetterSignature(DistributedResource.DistributedResource, () => ({
__proto__: dart.getGetters(DistributedResource.DistributedResource.__proto__),
connection: dart.nullable(DistributedConnection.DistributedConnection),
link: dart.nullable(core.String),
id: dart.nullable(core.int),
suspended: core.bool,
attached: core.bool,
template: TemplateDescriber.TemplateDescriber
}));
dart.setLibraryUri(DistributedResource.DistributedResource, I[47]);
dart.setFieldSignature(DistributedResource.DistributedResource, () => ({
__proto__: dart.getFields(DistributedResource.DistributedResource.__proto__),
[S$._instanceId]: dart.fieldType(dart.nullable(core.int)),
[S$._connection]: dart.fieldType(dart.nullable(DistributedConnection.DistributedConnection)),
[S$._attached]: dart.fieldType(core.bool),
[S$._link]: dart.fieldType(dart.nullable(core.String)),
[S$._age]: dart.fieldType(dart.nullable(core.int)),
[S$._properties$1]: dart.fieldType(core.List),
[S$._destroyed]: dart.fieldType(core.bool),
[S$._queued_updates]: dart.fieldType(core.List$(KeyValuePair$.KeyValuePair$(core.int, dart.dynamic))),
[S$._suspended]: dart.fieldType(core.bool)
}));
dart.defineExtensionMethods(DistributedResource.DistributedResource, ['noSuchMethod', 'toString']);
DistributedResourceQueueItem.DistributedResourceQueueItem = class DistributedResourceQueueItem$ extends core.Object {
get type() {
return this[S$.type$7];
}
set type(value) {
super.type = value;
}
get index() {
return this[S$.index$2];
}
set index(value) {
super.index = value;
}
get value() {
return this[S$.value$5];
}
set value(value) {
super.value = value;
}
get resource() {
return this[S$.resource];
}
set resource(value) {
super.resource = value;
}
static ['_#new#tearOff'](resource, type, value, index) {
if (resource == null) dart.nullFailed(I[48], 35, 39, "resource");
if (type == null) dart.nullFailed(I[48], 35, 54, "type");
if (index == null) dart.nullFailed(I[48], 35, 77, "index");
return new DistributedResourceQueueItem.DistributedResourceQueueItem.new(resource, type, value, index);
}
};
(DistributedResourceQueueItem.DistributedResourceQueueItem.new = function(resource, type, value, index) {
if (resource == null) dart.nullFailed(I[48], 35, 39, "resource");
if (type == null) dart.nullFailed(I[48], 35, 54, "type");
if (index == null) dart.nullFailed(I[48], 35, 77, "index");
this[S$.resource] = resource;
this[S$.type$7] = type;
this[S$.value$5] = value;
this[S$.index$2] = index;
}).prototype = DistributedResourceQueueItem.DistributedResourceQueueItem.prototype;
dart.addTypeTests(DistributedResourceQueueItem.DistributedResourceQueueItem);
dart.addTypeCaches(DistributedResourceQueueItem.DistributedResourceQueueItem);
dart.setLibraryUri(DistributedResourceQueueItem.DistributedResourceQueueItem, I[48]);
dart.setFieldSignature(DistributedResourceQueueItem.DistributedResourceQueueItem, () => ({
__proto__: dart.getFields(DistributedResourceQueueItem.DistributedResourceQueueItem.__proto__),
type: dart.finalFieldType(DistributedResourceQueueItemType.DistributedResourceQueueItemType),
index: dart.finalFieldType(core.int),
value: dart.finalFieldType(dart.dynamic),
resource: dart.finalFieldType(DistributedResource.DistributedResource)
}));
DistributedResourceQueueItemType.DistributedResourceQueueItemType = class DistributedResourceQueueItemType extends core._Enum {
toString() {
return "DistributedResourceQueueItemType." + dart.str(this[S$._name$1]);
}
};
(DistributedResourceQueueItemType.DistributedResourceQueueItemType.new = function(index, name) {
if (index == null) dart.nullFailed(I[49], 1, 10, "index");
if (name == null) dart.nullFailed(I[49], 1, 10, "name");
DistributedResourceQueueItemType.DistributedResourceQueueItemType.__proto__.new.call(this, index, name);
;
}).prototype = DistributedResourceQueueItemType.DistributedResourceQueueItemType.prototype;
dart.addTypeTests(DistributedResourceQueueItemType.DistributedResourceQueueItemType);
dart.addTypeCaches(DistributedResourceQueueItemType.DistributedResourceQueueItemType);
dart.setLibraryUri(DistributedResourceQueueItemType.DistributedResourceQueueItemType, I[49]);
dart.setStaticFieldSignature(DistributedResourceQueueItemType.DistributedResourceQueueItemType, () => ['values', 'Propery', 'Event']);
dart.defineExtensionMethods(DistributedResourceQueueItemType.DistributedResourceQueueItemType, ['toString']);
DistributedResourceQueueItemType.DistributedResourceQueueItemType.Propery = C[113] || CT.C113;
DistributedResourceQueueItemType.DistributedResourceQueueItemType.Event = C[114] || CT.C114;
DistributedResourceQueueItemType.DistributedResourceQueueItemType.values = C[115] || CT.C115;
IIPAuthPacket.IIPAuthPacket = class IIPAuthPacket$ extends core.Object {
get command() {
return this[S$.command];
}
set command(value) {
this[S$.command] = value;
}
get action() {
return this[S$.action];
}
set action(value) {
this[S$.action] = value;
}
get errorCode() {
return this[S$.errorCode];
}
set errorCode(value) {
this[S$.errorCode] = value;
}
get errorMessage() {
return this[S$.errorMessage];
}
set errorMessage(value) {
this[S$.errorMessage] = value;
}
get localMethod() {
return this[S$.localMethod];
}
set localMethod(value) {
this[S$.localMethod] = value;
}
get sourceInfo() {
return this[S$.sourceInfo];
}
set sourceInfo(value) {
this[S$.sourceInfo] = value;
}
get hash() {
return this[S$.hash];
}
set hash(value) {
this[S$.hash] = value;
}
get sessionId() {
return this[S$.sessionId];
}
set sessionId(value) {
this[S$.sessionId] = value;
}
get remoteMethod() {
return this[S$.remoteMethod];
}
set remoteMethod(value) {
this[S$.remoteMethod] = value;
}
get domain() {
return this[S$.domain];
}
set domain(value) {
this[S$.domain] = value;
}
get certificateId() {
return this[S$.certificateId];
}
set certificateId(value) {
this[S$.certificateId] = value;
}
get localUsername() {
return this[S$.localUsername];
}
set localUsername(value) {
this[S$.localUsername] = value;
}
get remoteUsername() {
return this[S$.remoteUsername];
}
set remoteUsername(value) {
this[S$.remoteUsername] = value;
}
get localPassword() {
return this[S$.localPassword];
}
set localPassword(value) {
this[S$.localPassword] = value;
}
get remotePassword() {
return this[S$.remotePassword];
}
set remotePassword(value) {
this[S$.remotePassword] = value;
}
get localToken() {
return this[S$.localToken];
}
set localToken(value) {
this[S$.localToken] = value;
}
get remoteToken() {
return this[S$.remoteToken];
}
set remoteToken(value) {
this[S$.remoteToken] = value;
}
get asymetricEncryptionKey() {
return this[S$.asymetricEncryptionKey];
}
set asymetricEncryptionKey(value) {
this[S$.asymetricEncryptionKey] = value;
}
get localNonce() {
return this[S$.localNonce];
}
set localNonce(value) {
this[S$.localNonce] = value;
}
get remoteNonce() {
return this[S$.remoteNonce];
}
set remoteNonce(value) {
this[S$.remoteNonce] = value;
}
get remoteTokenIndex() {
return this[S$.remoteTokenIndex];
}
set remoteTokenIndex(value) {
this[S$.remoteTokenIndex] = value;
}
[S$._notEnough](offset, ends, needed) {
if (offset == null) dart.nullFailed(I[50], 72, 23, "offset");
if (ends == null) dart.nullFailed(I[50], 72, 35, "ends");
if (needed == null) dart.nullFailed(I[50], 72, 45, "needed");
if (dart.notNull(offset) + dart.notNull(needed) > dart.notNull(ends)) {
this[S$._dataLengthNeeded] = dart.notNull(needed) - (dart.notNull(ends) - dart.notNull(offset));
return true;
} else
return false;
}
toString() {
return dart.toString(this.command) + " " + dart.toString(this.action);
}
parse(data, offset, ends) {
let t24, t24$, t24$0, t24$1, t24$2, t24$3;
if (data == null) dart.nullFailed(I[50], 84, 16, "data");
if (offset == null) dart.nullFailed(I[50], 84, 26, "offset");
if (ends == null) dart.nullFailed(I[50], 84, 38, "ends");
let oOffset = offset;
if (dart.test(this[S$._notEnough](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.command = data._get(offset)[S$.$rightShift](6);
if (this.command === 0) {
this.action = dart.notNull(data._get((t24 = offset, offset = dart.notNull(t24) + 1, t24))) & 63;
if (this.action === 0) {
if (dart.test(this[S$._notEnough](offset, ends, 32))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.hash = data.clip(offset, 32);
offset = dart.notNull(offset) + 32;
} else if (this.action === 32) {
if (dart.test(this[S$._notEnough](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded]);
let length = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough](offset, ends, length))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.sourceInfo = data.clip(offset, length);
offset = dart.notNull(offset) + 32;
} else if (this.action === 33 || this.action === 40) {
if (dart.test(this[S$._notEnough](offset, ends, 32))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.sessionId = data.clip(offset, 32);
offset = dart.notNull(offset) + 32;
}
} else if (this.command === 1) {
this.remoteMethod = AuthenticationMethod.AuthenticationMethod.values[S$.$_get](dart.notNull(data._get(offset)) >> 4 & 3);
this.localMethod = AuthenticationMethod.AuthenticationMethod.values[S$.$_get](dart.notNull(data._get(offset)) >> 2 & 3);
let encrypt = (dart.notNull(data._get((t24$ = offset, offset = dart.notNull(t24$) + 1, t24$))) & 2) === 2;
if (dart.test(this[S$._notEnough](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded]);
let domainLength = data._get((t24$0 = offset, offset = dart.notNull(t24$0) + 1, t24$0));
if (dart.test(this[S$._notEnough](offset, ends, domainLength))) return -dart.notNull(this[S$._dataLengthNeeded]);
let domain = data.getString(offset, domainLength);
this.domain = domain;
offset = dart.notNull(offset) + dart.notNull(domainLength);
if (this.remoteMethod == AuthenticationMethod.AuthenticationMethod.Credentials) {
if (this.localMethod == AuthenticationMethod.AuthenticationMethod.None) {
if (dart.test(this[S$._notEnough](offset, ends, 33))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.remoteNonce = data.clip(offset, 32);
offset = dart.notNull(offset) + 32;
let length = data._get((t24$1 = offset, offset = dart.notNull(t24$1) + 1, t24$1));
if (dart.test(this[S$._notEnough](offset, ends, length))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.remoteUsername = data.getString(offset, length);
offset = dart.notNull(offset) + dart.notNull(length);
}
} else if (this.remoteMethod == AuthenticationMethod.AuthenticationMethod.Token) {
if (this.localMethod == AuthenticationMethod.AuthenticationMethod.None) {
if (dart.test(this[S$._notEnough](offset, ends, 40))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.remoteNonce = data.clip(offset, 32);
offset = dart.notNull(offset) + 32;
this.remoteTokenIndex = data.getUint64(offset);
offset = dart.notNull(offset) + 8;
}
}
if (encrypt) {
if (dart.test(this[S$._notEnough](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded]);
let keyLength = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough](offset, ends, keyLength))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.asymetricEncryptionKey = data.clip(offset, keyLength);
offset = dart.notNull(offset) + dart.notNull(keyLength);
}
} else if (this.command === 2) {
this.remoteMethod = AuthenticationMethod.AuthenticationMethod.values[S$.$_get](dart.notNull(data._get(offset)) >> 4 & 3);
this.localMethod = AuthenticationMethod.AuthenticationMethod.values[S$.$_get](dart.notNull(data._get(offset)) >> 2 & 3);
let encrypt = (dart.notNull(data._get((t24$2 = offset, offset = dart.notNull(t24$2) + 1, t24$2))) & 2) === 2;
if (this.remoteMethod == AuthenticationMethod.AuthenticationMethod.None) {
if (this.localMethod == AuthenticationMethod.AuthenticationMethod.None) {
}
} else if (this.remoteMethod == AuthenticationMethod.AuthenticationMethod.Credentials || this.remoteMethod == AuthenticationMethod.AuthenticationMethod.Token) {
if (this.localMethod == AuthenticationMethod.AuthenticationMethod.None) {
if (dart.test(this[S$._notEnough](offset, ends, 32))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.remoteNonce = data.clip(offset, 32);
offset = dart.notNull(offset) + 32;
}
}
if (encrypt) {
if (dart.test(this[S$._notEnough](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded]);
let keyLength = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough](offset, ends, keyLength))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.asymetricEncryptionKey = data.clip(offset, keyLength);
offset = dart.notNull(offset) + dart.notNull(keyLength);
}
} else if (this.command === 3) {
if (dart.test(this[S$._notEnough](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded]);
offset = dart.notNull(offset) + 1;
this.errorCode = data._get((t24$3 = offset, offset = dart.notNull(t24$3) + 1, t24$3));
let cl = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded]);
this.errorMessage = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
}
return dart.notNull(offset) - dart.notNull(oOffset);
}
static ['_#new#tearOff']() {
return new IIPAuthPacket.IIPAuthPacket.new();
}
};
(IIPAuthPacket.IIPAuthPacket.new = function() {
this[S$.command] = 0;
this[S$.action] = 0;
this[S$.errorCode] = 0;
this[S$.errorMessage] = "";
this[S$.localMethod] = AuthenticationMethod.AuthenticationMethod.None;
this[S$.sourceInfo] = null;
this[S$.hash] = null;
this[S$.sessionId] = null;
this[S$.remoteMethod] = AuthenticationMethod.AuthenticationMethod.None;
this[S$.domain] = null;
this[S$.certificateId] = 0;
this[S$.localUsername] = null;
this[S$.remoteUsername] = null;
this[S$.localPassword] = null;
this[S$.remotePassword] = null;
this[S$.localToken] = null;
this[S$.remoteToken] = null;
this[S$.asymetricEncryptionKey] = null;
this[S$.localNonce] = null;
this[S$.remoteNonce] = null;
this[S$.remoteTokenIndex] = 0;
this[S$._dataLengthNeeded] = 0;
;
}).prototype = IIPAuthPacket.IIPAuthPacket.prototype;
dart.addTypeTests(IIPAuthPacket.IIPAuthPacket);
dart.addTypeCaches(IIPAuthPacket.IIPAuthPacket);
dart.setMethodSignature(IIPAuthPacket.IIPAuthPacket, () => ({
__proto__: dart.getMethods(IIPAuthPacket.IIPAuthPacket.__proto__),
[S$._notEnough]: dart.fnType(core.bool, [core.int, core.int, core.int]),
parse: dart.fnType(core.int, [DC.DC, core.int, core.int])
}));
dart.setLibraryUri(IIPAuthPacket.IIPAuthPacket, I[50]);
dart.setFieldSignature(IIPAuthPacket.IIPAuthPacket, () => ({
__proto__: dart.getFields(IIPAuthPacket.IIPAuthPacket.__proto__),
command: dart.fieldType(core.int),
action: dart.fieldType(core.int),
errorCode: dart.fieldType(core.int),
errorMessage: dart.fieldType(core.String),
localMethod: dart.fieldType(AuthenticationMethod.AuthenticationMethod),
sourceInfo: dart.fieldType(dart.nullable(DC.DC)),
hash: dart.fieldType(dart.nullable(DC.DC)),
sessionId: dart.fieldType(dart.nullable(DC.DC)),
remoteMethod: dart.fieldType(AuthenticationMethod.AuthenticationMethod),
domain: dart.fieldType(dart.nullable(core.String)),
certificateId: dart.fieldType(core.int),
localUsername: dart.fieldType(dart.nullable(core.String)),
remoteUsername: dart.fieldType(dart.nullable(core.String)),
localPassword: dart.fieldType(dart.nullable(DC.DC)),
remotePassword: dart.fieldType(dart.nullable(DC.DC)),
localToken: dart.fieldType(dart.nullable(DC.DC)),
remoteToken: dart.fieldType(dart.nullable(DC.DC)),
asymetricEncryptionKey: dart.fieldType(dart.nullable(DC.DC)),
localNonce: dart.fieldType(dart.nullable(DC.DC)),
remoteNonce: dart.fieldType(dart.nullable(DC.DC)),
remoteTokenIndex: dart.fieldType(core.int),
[S$._dataLengthNeeded]: dart.fieldType(core.int)
}));
dart.defineExtensionMethods(IIPAuthPacket.IIPAuthPacket, ['toString']);
IIPAuthPacketAction.IIPAuthPacketAction = class IIPAuthPacketAction$ extends core.Object {
static ['_#new#tearOff']() {
return new IIPAuthPacketAction.IIPAuthPacketAction.new();
}
};
(IIPAuthPacketAction.IIPAuthPacketAction.new = function() {
;
}).prototype = IIPAuthPacketAction.IIPAuthPacketAction.prototype;
dart.addTypeTests(IIPAuthPacketAction.IIPAuthPacketAction);
dart.addTypeCaches(IIPAuthPacketAction.IIPAuthPacketAction);
dart.setLibraryUri(IIPAuthPacketAction.IIPAuthPacketAction, I[51]);
dart.setStaticFieldSignature(IIPAuthPacketAction.IIPAuthPacketAction, () => ['AuthenticateHash', 'NewConnection', 'ResumeConnection', 'ConnectionEstablished']);
dart.defineLazy(IIPAuthPacketAction.IIPAuthPacketAction, {
/*IIPAuthPacketAction.IIPAuthPacketAction.AuthenticateHash*/get AuthenticateHash() {
return 0;
},
/*IIPAuthPacketAction.IIPAuthPacketAction.NewConnection*/get NewConnection() {
return 32;
},
/*IIPAuthPacketAction.IIPAuthPacketAction.ResumeConnection*/get ResumeConnection() {
return 33;
},
/*IIPAuthPacketAction.IIPAuthPacketAction.ConnectionEstablished*/get ConnectionEstablished() {
return 40;
}
}, false);
IIPAuthPacketCommand.IIPAuthPacketCommand = class IIPAuthPacketCommand$ extends core.Object {
static ['_#new#tearOff']() {
return new IIPAuthPacketCommand.IIPAuthPacketCommand.new();
}
};
(IIPAuthPacketCommand.IIPAuthPacketCommand.new = function() {
;
}).prototype = IIPAuthPacketCommand.IIPAuthPacketCommand.prototype;
dart.addTypeTests(IIPAuthPacketCommand.IIPAuthPacketCommand);
dart.addTypeCaches(IIPAuthPacketCommand.IIPAuthPacketCommand);
dart.setLibraryUri(IIPAuthPacketCommand.IIPAuthPacketCommand, I[52]);
dart.setStaticFieldSignature(IIPAuthPacketCommand.IIPAuthPacketCommand, () => ['Action', 'Declare', 'Acknowledge', 'Error']);
dart.defineLazy(IIPAuthPacketCommand.IIPAuthPacketCommand, {
/*IIPAuthPacketCommand.IIPAuthPacketCommand.Action*/get Action() {
return 0;
},
/*IIPAuthPacketCommand.IIPAuthPacketCommand.Declare*/get Declare() {
return 1;
},
/*IIPAuthPacketCommand.IIPAuthPacketCommand.Acknowledge*/get Acknowledge() {
return 2;
},
/*IIPAuthPacketCommand.IIPAuthPacketCommand.Error*/get Error() {
return 3;
}
}, false);
IIPPacket.IIPPacket = class IIPPacket$ extends core.Object {
get report() {
return this[S$.report];
}
set report(value) {
this[S$.report] = value;
}
get command() {
return this[S$.command$1];
}
set command(value) {
this[S$.command$1] = value;
}
get action() {
return this[S$.action$1];
}
set action(value) {
this[S$.action$1] = value;
}
get event() {
return this[S$.event];
}
set event(value) {
this[S$.event] = value;
}
get previousCommand() {
return this[S$.previousCommand];
}
set previousCommand(value) {
this[S$.previousCommand] = value;
}
get previousAction() {
return this[S$.previousAction];
}
set previousAction(value) {
this[S$.previousAction] = value;
}
get previousEvent() {
return this[S$.previousEvent];
}
set previousEvent(value) {
this[S$.previousEvent] = value;
}
get resourceId() {
return this[S$.resourceId];
}
set resourceId(value) {
this[S$.resourceId] = value;
}
get newResourceId() {
return this[S$.newResourceId];
}
set newResourceId(value) {
this[S$.newResourceId] = value;
}
get childId() {
return this[S$.childId];
}
set childId(value) {
this[S$.childId] = value;
}
get storeId() {
return this[S$.storeId];
}
set storeId(value) {
this[S$.storeId] = value;
}
get resourceAge() {
return this[S$.resourceAge];
}
set resourceAge(value) {
this[S$.resourceAge] = value;
}
get errorCode() {
return this[S$.errorCode$1];
}
set errorCode(value) {
this[S$.errorCode$1] = value;
}
get errorMessage() {
return this[S$.errorMessage$1];
}
set errorMessage(value) {
this[S$.errorMessage$1] = value;
}
get className() {
return this[S$.className];
}
set className(value) {
this[S$.className] = value;
}
get resourceLink() {
return this[S$.resourceLink];
}
set resourceLink(value) {
this[S$.resourceLink] = value;
}
get classId() {
return this[S$.classId];
}
set classId(value) {
this[S$.classId] = value;
}
get methodIndex() {
return this[S$.methodIndex];
}
set methodIndex(value) {
this[S$.methodIndex] = value;
}
get methodName() {
return this[S$.methodName];
}
set methodName(value) {
this[S$.methodName] = value;
}
get callbackId() {
return this[S$.callbackId];
}
set callbackId(value) {
this[S$.callbackId] = value;
}
get progressValue() {
return this[S$.progressValue];
}
set progressValue(value) {
this[S$.progressValue] = value;
}
get progressMax() {
return this[S$.progressMax];
}
set progressMax(value) {
this[S$.progressMax] = value;
}
get fromDate() {
return this[S$.fromDate];
}
set fromDate(value) {
this[S$.fromDate] = value;
}
get toDate() {
return this[S$.toDate];
}
set toDate(value) {
this[S$.toDate] = value;
}
get fromAge() {
return this[S$.fromAge];
}
set fromAge(value) {
this[S$.fromAge] = value;
}
get toAge() {
return this[S$.toAge];
}
set toAge(value) {
this[S$.toAge] = value;
}
get resourceName() {
return this[S$.resourceName];
}
set resourceName(value) {
this[S$.resourceName] = value;
}
get dataType() {
return this[S$.dataType];
}
set dataType(value) {
this[S$.dataType] = value;
}
[S$._notEnough$1](offset, ends, needed) {
if (offset == null) dart.nullFailed(I[53], 79, 23, "offset");
if (ends == null) dart.nullFailed(I[53], 79, 35, "ends");
if (needed == null) dart.nullFailed(I[53], 79, 45, "needed");
if (dart.notNull(offset) + dart.notNull(needed) > dart.notNull(ends)) {
this[S$._dataLengthNeeded$1] = dart.notNull(needed) - (dart.notNull(ends) - dart.notNull(offset));
return true;
} else
return false;
}
parse(data, offset, ends) {
let t24, t24$, t24$0, t24$1, t24$2, t24$3, t24$4, t24$5;
if (data == null) dart.nullFailed(I[53], 89, 16, "data");
if (offset == null) dart.nullFailed(I[53], 89, 26, "offset");
if (ends == null) dart.nullFailed(I[53], 89, 38, "ends");
this[S$._originalOffset] = offset;
if (dart.test(this[S$._notEnough$1](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.previousCommand = this.command;
this.command = data._get(offset)[S$.$rightShift](6);
if (this.command === 0) {
this.event = dart.notNull(data._get((t24 = offset, offset = dart.notNull(t24) + 1, t24))) & 63;
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.command === 3) {
this.report = dart.notNull(data._get((t24$ = offset, offset = dart.notNull(t24$) + 1, t24$))) & 63;
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.callbackId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else {
this.previousAction = this.action;
this.action = dart.notNull(data._get((t24$0 = offset, offset = dart.notNull(t24$0) + 1, t24$0))) & 63;
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.callbackId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
}
if (this.command === 0) {
if (this.event === 0) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.newResourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.event === 1) {
} else if (this.event === 2 || this.event === 3) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.childId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.event === 4) {
if (dart.test(this[S$._notEnough$1](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let cl = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceName = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
} else if (this.event === 16 || this.event === 17) {
if (dart.test(this[S$._notEnough$1](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.methodIndex = data._get((t24$1 = offset, offset = dart.notNull(t24$1) + 1, t24$1));
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
} else if (this.event === 24) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let cl = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
offset = dart.notNull(offset) + dart.notNull(cl);
}
} else if (this.command === 1) {
if (this.action === 0) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 1) {
if (dart.test(this[S$._notEnough$1](offset, ends, 12))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.resourceAge = data.getUint64(offset);
offset = dart.notNull(offset) + 8;
} else if (this.action === 2) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 3) {
if (dart.test(this[S$._notEnough$1](offset, ends, 12))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.storeId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
let cl = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
} else if (this.action === 4) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 5 || this.action === 6) {
if (dart.test(this[S$._notEnough$1](offset, ends, 8))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.childId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 7) {
if (dart.test(this[S$._notEnough$1](offset, ends, 6))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
let cl = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceName = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
} else if (this.action === 8) {
if (dart.test(this[S$._notEnough$1](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let cl = data._get((t24$2 = offset, offset = dart.notNull(t24$2) + 1, t24$2));
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.className = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
} else if (this.action === 9) {
if (dart.test(this[S$._notEnough$1](offset, ends, 16))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.classId = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
} else if (this.action === 10) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 11 || this.action === 15) {
if (dart.test(this[S$._notEnough$1](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let cl = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceLink = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
} else if (this.action === 13 || this.action === 14) {
if (dart.test(this[S$._notEnough$1](offset, ends, 4))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 12) {
if (dart.test(this[S$._notEnough$1](offset, ends, 20))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.fromDate = data.getDateTime(offset);
offset = dart.notNull(offset) + 8;
this.toDate = data.getDateTime(offset);
offset = dart.notNull(offset) + 8;
} else if (this.action === 16) {
if (dart.test(this[S$._notEnough$1](offset, ends, 6))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.methodIndex = data._get((t24$3 = offset, offset = dart.notNull(t24$3) + 1, t24$3));
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
} else if (this.action === 18 || this.action === 19) {
if (dart.test(this[S$._notEnough$1](offset, ends, 5))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.methodIndex = data._get((t24$4 = offset, offset = dart.notNull(t24$4) + 1, t24$4));
} else if (this.action === 20) {
if (dart.test(this[S$._notEnough$1](offset, ends, 6))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
this.methodIndex = data._get((t24$5 = offset, offset = dart.notNull(t24$5) + 1, t24$5));
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
} else if (this.action === 25 || this.action === 27 || this.action === 28 || this.action === 29) {
if (dart.test(this[S$._notEnough$1](offset, ends, 8))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
let cl = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
offset = dart.notNull(offset) + dart.notNull(cl);
}
} else if (this.command === 2) {
if (this.action === 0 || this.action === 1) {
if (dart.test(this[S$._notEnough$1](offset, ends, 26))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.classId = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
this.resourceAge = data.getUint64(offset);
offset = dart.notNull(offset) + 8;
let cl = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceLink = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
} else if (this.action === 2) {
} else if (this.action === 3) {
if (dart.test(this[S$._notEnough$1](offset, ends, 20))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.resourceId = data.getUint32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.action === 2) {
} else if (this.action === 8 || this.action === 9 || this.action === 10 || this.action === 11 || this.action === 13 || this.action === 14 || this.action === 12 || this.action === 15 || this.action === 24 || this.action === 27) {
if (dart.test(this[S$._notEnough$1](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
} else if (this.action === 16) {
if (dart.test(this[S$._notEnough$1](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
} else if (this.action === 20 || this.action === 18 || this.action === 19) {
}
} else if (this.command === 3) {
if (this.report === 0) {
if (dart.test(this[S$._notEnough$1](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.errorCode = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
} else if (this.report === 1) {
if (dart.test(this[S$._notEnough$1](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.errorCode = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough$1](offset, ends, 2))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let cl = data.getUint16(offset);
offset = dart.notNull(offset) + 2;
if (dart.test(this[S$._notEnough$1](offset, ends, cl))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.errorMessage = data.getString(offset, cl);
offset = dart.notNull(offset) + dart.notNull(cl);
} else if (this.report === 8) {
if (dart.test(this[S$._notEnough$1](offset, ends, 8))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
this.progressValue = data.getInt32(offset);
offset = dart.notNull(offset) + 4;
this.progressMax = data.getInt32(offset);
offset = dart.notNull(offset) + 4;
} else if (this.report === 9) {
if (dart.test(this[S$._notEnough$1](offset, ends, 1))) return -dart.notNull(this[S$._dataLengthNeeded$1]);
let parsed = TransmissionType.TransmissionType.parse(data, offset, ends);
if (parsed.type == null) return -dart.notNull(parsed.size);
this.dataType = parsed.type;
offset = dart.notNull(offset) + dart.notNull(parsed.size);
}
}
return dart.notNull(offset) - dart.notNull(this[S$._originalOffset]);
}
toString() {
let rt = dart.toString(this.command);
if (this.command === 0) {
rt = rt + (" " + dart.toString(this.event));
} else if (this.command === 1) {
rt = rt + (" " + dart.toString(this.action));
if (this.action === 0) {
rt = rt + (" CID: " + dart.toString(this.callbackId) + " RID: " + dart.toString(this.resourceId));
}
} else if (this.command === 2)
rt = rt + (" " + dart.toString(this.action));
else if (this.command === 3) rt = rt + (" " + dart.toString(this.report));
return rt;
}
static ['_#new#tearOff']() {
return new IIPPacket.IIPPacket.new();
}
};
(IIPPacket.IIPPacket.new = function() {
this[S$.report] = 0;
this[S$.command$1] = 0;
this[S$.action$1] = 0;
this[S$.event] = 0;
this[S$.previousCommand] = 0;
this[S$.previousAction] = 0;
this[S$.previousEvent] = 0;
this[S$.resourceId] = 0;
this[S$.newResourceId] = 0;
this[S$.childId] = 0;
this[S$.storeId] = 0;
this[S$.resourceAge] = 0;
this[S$.errorCode$1] = 0;
this[S$.errorMessage$1] = "";
this[S$.className] = "";
this[S$.resourceLink] = "";
this[S$.classId] = new Guid.Guid.new(new DC.DC.new(0));
this[S$.methodIndex] = 0;
this[S$.methodName] = "";
this[S$.callbackId] = 0;
this[S$.progressValue] = 0;
this[S$.progressMax] = 0;
this[S$.fromDate] = new core.DateTime.new(2000);
this[S$.toDate] = new core.DateTime.new(2000);
this[S$.fromAge] = 0;
this[S$.toAge] = 0;
this[S$.resourceName] = "";
this[S$.dataType] = null;
this[S$._dataLengthNeeded$1] = 0;
this[S$._originalOffset] = 0;
;
}).prototype = IIPPacket.IIPPacket.prototype;
dart.addTypeTests(IIPPacket.IIPPacket);
dart.addTypeCaches(IIPPacket.IIPPacket);
dart.setMethodSignature(IIPPacket.IIPPacket, () => ({
__proto__: dart.getMethods(IIPPacket.IIPPacket.__proto__),
[S$._notEnough$1]: dart.fnType(core.bool, [core.int, core.int, core.int]),
parse: dart.fnType(core.int, [DC.DC, core.int, core.int])
}));
dart.setLibraryUri(IIPPacket.IIPPacket, I[53]);
dart.setFieldSignature(IIPPacket.IIPPacket, () => ({
__proto__: dart.getFields(IIPPacket.IIPPacket.__proto__),
report: dart.fieldType(core.int),
command: dart.fieldType(core.int),
action: dart.fieldType(core.int),
event: dart.fieldType(core.int),
previousCommand: dart.fieldType(core.int),
previousAction: dart.fieldType(core.int),
previousEvent: dart.fieldType(core.int),
resourceId: dart.fieldType(core.int),
newResourceId: dart.fieldType(core.int),
childId: dart.fieldType(core.int),
storeId: dart.fieldType(core.int),
resourceAge: dart.fieldType(core.int),
errorCode: dart.fieldType(core.int),
errorMessage: dart.fieldType(core.String),
className: dart.fieldType(core.String),
resourceLink: dart.fieldType(core.String),
classId: dart.fieldType(Guid.Guid),
methodIndex: dart.fieldType(core.int),
methodName: dart.fieldType(core.String),
callbackId: dart.fieldType(core.int),
progressValue: dart.fieldType(core.int),
progressMax: dart.fieldType(core.int),
fromDate: dart.fieldType(core.DateTime),
toDate: dart.fieldType(core.DateTime),
fromAge: dart.fieldType(core.int),
toAge: dart.fieldType(core.int),
resourceName: dart.fieldType(core.String),
dataType: dart.fieldType(dart.nullable(TransmissionType.TransmissionType)),
[S$._dataLengthNeeded$1]: dart.fieldType(core.int),
[S$._originalOffset]: dart.fieldType(core.int)
}));
dart.defineExtensionMethods(IIPPacket.IIPPacket, ['toString']);
IIPPacketAction.IIPPacketAction = class IIPPacketAction$ extends core.Object {
static ['_#new#tearOff']() {
return new IIPPacketAction.IIPPacketAction.new();
}
};
(IIPPacketAction.IIPPacketAction.new = function() {
;
}).prototype = IIPPacketAction.IIPPacketAction.prototype;
dart.addTypeTests(IIPPacketAction.IIPPacketAction);
dart.addTypeCaches(IIPPacketAction.IIPPacketAction);
dart.setLibraryUri(IIPPacketAction.IIPPacketAction, I[54]);
dart.setStaticFieldSignature(IIPPacketAction.IIPPacketAction, () => ['AttachResource', 'ReattachResource', 'DetachResource', 'CreateResource', 'DeleteResource', 'AddChild', 'RemoveChild', 'RenameResource', 'TemplateFromClassName', 'TemplateFromClassId', 'TemplateFromResourceId', 'QueryLink', 'ResourceHistory', 'ResourceChildren', 'ResourceParents', 'LinkTemplates', 'InvokeFunction', 'Reserved', 'Listen', 'Unlisten', 'SetProperty', 'GetAllAttributes', 'UpdateAllAttributes', 'ClearAllAttributes', 'GetAttributes', 'UpdateAttributes', 'ClearAttributes']);
dart.defineLazy(IIPPacketAction.IIPPacketAction, {
/*IIPPacketAction.IIPPacketAction.AttachResource*/get AttachResource() {
return 0;
},
/*IIPPacketAction.IIPPacketAction.ReattachResource*/get ReattachResource() {
return 1;
},
/*IIPPacketAction.IIPPacketAction.DetachResource*/get DetachResource() {
return 2;
},
/*IIPPacketAction.IIPPacketAction.CreateResource*/get CreateResource() {
return 3;
},
/*IIPPacketAction.IIPPacketAction.DeleteResource*/get DeleteResource() {
return 4;
},
/*IIPPacketAction.IIPPacketAction.AddChild*/get AddChild() {
return 5;
},
/*IIPPacketAction.IIPPacketAction.RemoveChild*/get RemoveChild() {
return 6;
},
/*IIPPacketAction.IIPPacketAction.RenameResource*/get RenameResource() {
return 7;
},
/*IIPPacketAction.IIPPacketAction.TemplateFromClassName*/get TemplateFromClassName() {
return 8;
},
/*IIPPacketAction.IIPPacketAction.TemplateFromClassId*/get TemplateFromClassId() {
return 9;
},
/*IIPPacketAction.IIPPacketAction.TemplateFromResourceId*/get TemplateFromResourceId() {
return 10;
},
/*IIPPacketAction.IIPPacketAction.QueryLink*/get QueryLink() {
return 11;
},
/*IIPPacketAction.IIPPacketAction.ResourceHistory*/get ResourceHistory() {
return 12;
},
/*IIPPacketAction.IIPPacketAction.ResourceChildren*/get ResourceChildren() {
return 13;
},
/*IIPPacketAction.IIPPacketAction.ResourceParents*/get ResourceParents() {
return 14;
},
/*IIPPacketAction.IIPPacketAction.LinkTemplates*/get LinkTemplates() {
return 15;
},
/*IIPPacketAction.IIPPacketAction.InvokeFunction*/get InvokeFunction() {
return 16;
},
/*IIPPacketAction.IIPPacketAction.Reserved*/get Reserved() {
return 17;
},
/*IIPPacketAction.IIPPacketAction.Listen*/get Listen() {
return 18;
},
/*IIPPacketAction.IIPPacketAction.Unlisten*/get Unlisten() {
return 19;
},
/*IIPPacketAction.IIPPacketAction.SetProperty*/get SetProperty() {
return 20;
},
/*IIPPacketAction.IIPPacketAction.GetAllAttributes*/get GetAllAttributes() {
return 24;
},
/*IIPPacketAction.IIPPacketAction.UpdateAllAttributes*/get UpdateAllAttributes() {
return 25;
},
/*IIPPacketAction.IIPPacketAction.ClearAllAttributes*/get ClearAllAttributes() {
return 26;
},
/*IIPPacketAction.IIPPacketAction.GetAttributes*/get GetAttributes() {
return 27;
},
/*IIPPacketAction.IIPPacketAction.UpdateAttributes*/get UpdateAttributes() {
return 28;
},
/*IIPPacketAction.IIPPacketAction.ClearAttributes*/get ClearAttributes() {
return 29;
}
}, false);
IIPPacketCommand.IIPPacketCommand = class IIPPacketCommand$ extends core.Object {
static ['_#new#tearOff']() {
return new IIPPacketCommand.IIPPacketCommand.new();
}
};
(IIPPacketCommand.IIPPacketCommand.new = function() {
;
}).prototype = IIPPacketCommand.IIPPacketCommand.prototype;
dart.addTypeTests(IIPPacketCommand.IIPPacketCommand);
dart.addTypeCaches(IIPPacketCommand.IIPPacketCommand);
dart.setLibraryUri(IIPPacketCommand.IIPPacketCommand, I[55]);
dart.setStaticFieldSignature(IIPPacketCommand.IIPPacketCommand, () => ['Event', 'Request', 'Reply', 'Report']);
dart.defineLazy(IIPPacketCommand.IIPPacketCommand, {
/*IIPPacketCommand.IIPPacketCommand.Event*/get Event() {
return 0;
},
/*IIPPacketCommand.IIPPacketCommand.Request*/get Request() {
return 1;
},
/*IIPPacketCommand.IIPPacketCommand.Reply*/get Reply() {
return 2;
},
/*IIPPacketCommand.IIPPacketCommand.Report*/get Report() {
return 3;
}
}, false);
IIPPacketEvent.IIPPacketEvent = class IIPPacketEvent$ extends core.Object {
static ['_#new#tearOff']() {
return new IIPPacketEvent.IIPPacketEvent.new();
}
};
(IIPPacketEvent.IIPPacketEvent.new = function() {
;
}).prototype = IIPPacketEvent.IIPPacketEvent.prototype;
dart.addTypeTests(IIPPacketEvent.IIPPacketEvent);
dart.addTypeCaches(IIPPacketEvent.IIPPacketEvent);
dart.setLibraryUri(IIPPacketEvent.IIPPacketEvent, I[56]);
dart.setStaticFieldSignature(IIPPacketEvent.IIPPacketEvent, () => ['ResourceReassigned', 'ResourceDestroyed', 'ChildAdded', 'ChildRemoved', 'Renamed', 'PropertyUpdated', 'EventOccurred', 'AttributesUpdated']);
dart.defineLazy(IIPPacketEvent.IIPPacketEvent, {
/*IIPPacketEvent.IIPPacketEvent.ResourceReassigned*/get ResourceReassigned() {
return 0;
},
/*IIPPacketEvent.IIPPacketEvent.ResourceDestroyed*/get ResourceDestroyed() {
return 1;
},
/*IIPPacketEvent.IIPPacketEvent.ChildAdded*/get ChildAdded() {
return 2;
},
/*IIPPacketEvent.IIPPacketEvent.ChildRemoved*/get ChildRemoved() {
return 3;
},
/*IIPPacketEvent.IIPPacketEvent.Renamed*/get Renamed() {
return 4;
},
/*IIPPacketEvent.IIPPacketEvent.PropertyUpdated*/get PropertyUpdated() {
return 16;
},
/*IIPPacketEvent.IIPPacketEvent.EventOccurred*/get EventOccurred() {
return 17;
},
/*IIPPacketEvent.IIPPacketEvent.AttributesUpdated*/get AttributesUpdated() {
return 24;
}
}, false);
IIPPacketReport.IIPPacketReport = class IIPPacketReport$ extends core.Object {
static ['_#new#tearOff']() {
return new IIPPacketReport.IIPPacketReport.new();
}
};
(IIPPacketReport.IIPPacketReport.new = function() {
;
}).prototype = IIPPacketReport.IIPPacketReport.prototype;
dart.addTypeTests(IIPPacketReport.IIPPacketReport);
dart.addTypeCaches(IIPPacketReport.IIPPacketReport);
dart.setLibraryUri(IIPPacketReport.IIPPacketReport, I[57]);
dart.setStaticFieldSignature(IIPPacketReport.IIPPacketReport, () => ['ManagementError', 'ExecutionError', 'ProgressReport', 'ChunkStream']);
dart.defineLazy(IIPPacketReport.IIPPacketReport, {
/*IIPPacketReport.IIPPacketReport.ManagementError*/get ManagementError() {
return 0;
},
/*IIPPacketReport.IIPPacketReport.ExecutionError*/get ExecutionError() {
return 1;
},
/*IIPPacketReport.IIPPacketReport.ProgressReport*/get ProgressReport() {
return 8;
},
/*IIPPacketReport.IIPPacketReport.ChunkStream*/get ChunkStream() {
return 9;
}
}, false);
IPEndPoint.IPEndPoint = class IPEndPoint$ extends core.Object {
get ip() {
return this[S$.ip];
}
set ip(value) {
this[S$.ip] = value;
}
get port() {
return this[S$.port];
}
set port(value) {
this[S$.port] = value;
}
getIP() {
return this.ip[S$.$join](".");
}
get address() {
return this.getIP();
}
toString() {
return dart.str(this.getIP()) + ":" + dart.str(this.port);
}
static ['_#new#tearOff'](ip, port) {
if (ip == null) dart.nullFailed(I[58], 21, 19, "ip");
if (port == null) dart.nullFailed(I[58], 21, 28, "port");
return new IPEndPoint.IPEndPoint.new(ip, port);
}
};
(IPEndPoint.IPEndPoint.new = function(ip, port) {
if (ip == null) dart.nullFailed(I[58], 21, 19, "ip");
if (port == null) dart.nullFailed(I[58], 21, 28, "port");
this[S$.ip] = ip;
this[S$.port] = port;
}).prototype = IPEndPoint.IPEndPoint.prototype;
dart.addTypeTests(IPEndPoint.IPEndPoint);
dart.addTypeCaches(IPEndPoint.IPEndPoint);
dart.setMethodSignature(IPEndPoint.IPEndPoint, () => ({
__proto__: dart.getMethods(IPEndPoint.IPEndPoint.__proto__),
getIP: dart.fnType(core.String, [])
}));
dart.setGetterSignature(IPEndPoint.IPEndPoint, () => ({
__proto__: dart.getGetters(IPEndPoint.IPEndPoint.__proto__),
address: core.String
}));
dart.setLibraryUri(IPEndPoint.IPEndPoint, I[58]);
dart.setFieldSignature(IPEndPoint.IPEndPoint, () => ({
__proto__: dart.getFields(IPEndPoint.IPEndPoint.__proto__),
ip: dart.fieldType(core.List$(core.int)),
port: dart.fieldType(core.int)
}));
dart.defineExtensionMethods(IPEndPoint.IPEndPoint, ['toString']);
SocketState.SocketState = class SocketState extends core._Enum {
toString() {
return "SocketState." + dart.str(this[S$._name$1]);
}
};
(SocketState.SocketState.new = function(index, name) {
if (index == null) dart.nullFailed(I[59], 1, 10, "index");
if (name == null) dart.nullFailed(I[59], 1, 10, "name");
SocketState.SocketState.__proto__.new.call(this, index, name);
;
}).prototype = SocketState.SocketState.prototype;
dart.addTypeTests(SocketState.SocketState);
dart.addTypeCaches(SocketState.SocketState);
dart.setLibraryUri(SocketState.SocketState, I[59]);
dart.setStaticFieldSignature(SocketState.SocketState, () => ['values', 'Initial', 'Listening', 'Connecting', 'Established', 'Closed', 'Terminated']);
dart.defineExtensionMethods(SocketState.SocketState, ['toString']);
SocketState.SocketState.Initial = C[116] || CT.C116;
SocketState.SocketState.Listening = C[117] || CT.C117;
SocketState.SocketState.Connecting = C[118] || CT.C118;
SocketState.SocketState.Established = C[119] || CT.C119;
SocketState.SocketState.Closed = C[120] || CT.C120;
SocketState.SocketState.Terminated = C[121] || CT.C121;
SocketState.SocketState.values = C[122] || CT.C122;
TCPSocket.TCPSocket = class TCPSocket$ extends ISocket.ISocket {
get sock() {
return this[S$.sock];
}
set sock(value) {
this[S$.sock] = value;
}
get receiveNetworkBuffer() {
return this[S$.receiveNetworkBuffer];
}
set receiveNetworkBuffer(value) {
this[S$.receiveNetworkBuffer] = value;
}
get began() {
return this[S$.began];
}
set began(value) {
this[S$.began] = value;
}
begin() {
if (dart.test(this.began)) return false;
this.began = true;
if (this.sock != null) {
let s = dart.nullCast(this.sock, io.Socket);
this[S$._localEP] = new IPEndPoint.IPEndPoint.new(s.address.rawAddress, s.port);
this[S$._remoteEP] = new IPEndPoint.IPEndPoint.new(s.remoteAddress.rawAddress, s.remotePort);
}
return true;
}
dataHandler(data) {
let t24;
if (data == null) dart.nullFailed(I[60], 79, 30, "data");
try {
if (this[S$._state$1] == SocketState.SocketState.Closed || this[S$._state$1] == SocketState.SocketState.Terminated) return;
let dc = new DC.DC.fromList(data);
this.receiveNetworkBuffer.write(dc, 0, dc.length);
t24 = this.receiver;
t24 == null ? null : t24.networkReceive(this, this.receiveNetworkBuffer);
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
if (this[S$._state$1] != SocketState.SocketState.Closed) {
this[S$._state$1] = SocketState.SocketState.Terminated;
this.close();
}
} else
throw e;
}
}
errorHandler(error, trace) {
if (trace == null) dart.nullFailed(I[60], 101, 39, "trace");
core.print(error);
}
doneHandler() {
let t25;
this.close();
t25 = this.sock;
t25 == null ? null : t25.destroy();
}
connect(hostname, port) {
if (hostname == null) dart.nullFailed(I[60], 110, 35, "hostname");
if (port == null) dart.nullFailed(I[60], 110, 49, "port");
let rt = new (T$.AsyncReplyOfbool()).new();
try {
this[S$._state$1] = SocketState.SocketState.Connecting;
io.Socket.connect(hostname, port).then(core.Null, dart.fn(s => {
let t25;
if (s == null) dart.nullFailed(I[60], 116, 44, "s");
this.sock = s;
s.listen(dart.bind(this, 'dataHandler'), {onError: dart.bind(this, 'errorHandler'), onDone: dart.bind(this, 'doneHandler'), cancelOnError: false});
this[S$._state$1] = SocketState.SocketState.Established;
t25 = this.receiver;
t25 == null ? null : t25.networkConnect(this);
this.begin();
rt.trigger(true);
}, T$.SocketToNull())).catchError(dart.fn(ex => {
this.close();
rt.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.HostNotReachable.index, dart.toString(ex)));
}, T$.dynamicToNull()));
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
rt.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.HostNotReachable.index, dart.toString(ex)));
} else
throw e;
}
return rt;
}
get localEndPoint() {
return this[S$._localEP];
}
set localEndPoint(value) {
super.localEndPoint = value;
}
get remoteEndPoint() {
return this[S$._remoteEP];
}
set remoteEndPoint(value) {
super.remoteEndPoint = value;
}
get state() {
return this[S$._state$1];
}
static ['_#fromSocket#tearOff'](sock) {
return new TCPSocket.TCPSocket.fromSocket(sock);
}
static ['_#new#tearOff']() {
return new TCPSocket.TCPSocket.new();
}
close() {
let t26, t26$;
if (this.state != SocketState.SocketState.Closed && this.state != SocketState.SocketState.Terminated) this[S$._state$1] = SocketState.SocketState.Closed;
t26 = this.sock;
t26 == null ? null : t26.close();
t26$ = this.receiver;
t26$ == null ? null : t26$.networkClose(this);
}
send(message, offset = null, size = null) {
let t26, t26$, t26$0;
if (message == null) dart.nullFailed(I[60], 166, 16, "message");
if (this.state == SocketState.SocketState.Established) {
if (offset != null && size == null) {
t26 = this.sock;
t26 == null ? null : t26.add(message.clip(offset, dart.notNull(message.length) - dart.notNull(offset)).toList());
} else if (offset != null && size != null) {
t26$ = this.sock;
t26$ == null ? null : t26$.add(message.clip(offset, size).toList());
} else {
t26$0 = this.sock;
t26$0 == null ? null : t26$0.add(message.toList());
}
}
}
destroy() {
this.close();
this.emitArgs("destroy", [this]);
}
accept() {
let reply = new (T$.AsyncReplyOfISocket()).new();
return reply;
}
};
(TCPSocket.TCPSocket.fromSocket = function(sock) {
this[S$.receiveNetworkBuffer] = new NetworkBuffer.NetworkBuffer.new();
this[S$.began] = false;
this[S$._state$1] = SocketState.SocketState.Initial;
this[S$._localEP] = null;
this[S$._remoteEP] = null;
this[S$.sock] = sock;
TCPSocket.TCPSocket.__proto__.new.call(this);
}).prototype = TCPSocket.TCPSocket.prototype;
(TCPSocket.TCPSocket.new = function() {
this[S$.receiveNetworkBuffer] = new NetworkBuffer.NetworkBuffer.new();
this[S$.began] = false;
this[S$._state$1] = SocketState.SocketState.Initial;
this[S$._localEP] = null;
this[S$._remoteEP] = null;
this[S$.sock] = null;
TCPSocket.TCPSocket.__proto__.new.call(this);
}).prototype = TCPSocket.TCPSocket.prototype;
dart.addTypeTests(TCPSocket.TCPSocket);
dart.addTypeCaches(TCPSocket.TCPSocket);
dart.setMethodSignature(TCPSocket.TCPSocket, () => ({
__proto__: dart.getMethods(TCPSocket.TCPSocket.__proto__),
begin: dart.fnType(core.bool, []),
dataHandler: dart.fnType(dart.void, [core.List$(core.int)]),
errorHandler: dart.fnType(dart.void, [dart.dynamic, core.StackTrace]),
doneHandler: dart.fnType(dart.void, []),
connect: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [core.String, core.int]),
close: dart.fnType(dart.void, []),
send: dart.fnType(dart.void, [DC.DC], [dart.nullable(core.int), dart.nullable(core.int)]),
destroy: dart.fnType(dart.void, []),
accept: dart.fnType(AsyncReply$.AsyncReply$(ISocket.ISocket), [])
}));
dart.setGetterSignature(TCPSocket.TCPSocket, () => ({
__proto__: dart.getGetters(TCPSocket.TCPSocket.__proto__),
localEndPoint: dart.nullable(IPEndPoint.IPEndPoint),
remoteEndPoint: dart.nullable(IPEndPoint.IPEndPoint),
state: SocketState.SocketState
}));
dart.setLibraryUri(TCPSocket.TCPSocket, I[60]);
dart.setFieldSignature(TCPSocket.TCPSocket, () => ({
__proto__: dart.getFields(TCPSocket.TCPSocket.__proto__),
sock: dart.fieldType(dart.nullable(io.Socket)),
receiveNetworkBuffer: dart.fieldType(NetworkBuffer.NetworkBuffer),
began: dart.fieldType(core.bool),
[S$._state$1]: dart.fieldType(SocketState.SocketState),
[S$._localEP]: dart.fieldType(dart.nullable(IPEndPoint.IPEndPoint)),
[S$._remoteEP]: dart.fieldType(dart.nullable(IPEndPoint.IPEndPoint))
}));
Authentication.Authentication = class Authentication$ extends core.Object {
get tokenIndex() {
return this[S$.tokenIndex];
}
set tokenIndex(value) {
this[S$.tokenIndex] = value;
}
get method() {
return this[S$.method$1];
}
set method(value) {
this[S$.method$1] = value;
}
get username() {
return this[S$.username];
}
set username(value) {
this[S$.username] = value;
}
get domain() {
return this[S$.domain$1];
}
set domain(value) {
this[S$.domain$1] = value;
}
get state() {
return this[S$.state];
}
set state(value) {
this[S$.state] = value;
}
get source() {
return this[S$.source];
}
set source(value) {
this[S$.source] = value;
}
get type() {
return this[S$.type$8];
}
set type(value) {
super.type = value;
}
get fullName() {
let t26, t26$;
return dart.notNull((t26 = this.username, t26 == null ? "" : t26)) + "@" + dart.notNull((t26$ = this.domain, t26$ == null ? "" : t26$));
}
static ['_#new#tearOff'](type) {
if (type == null) dart.nullFailed(I[61], 45, 23, "type");
return new Authentication.Authentication.new(type);
}
};
(Authentication.Authentication.new = function(type) {
if (type == null) dart.nullFailed(I[61], 45, 23, "type");
this[S$.tokenIndex] = null;
this[S$.method$1] = AuthenticationMethod.AuthenticationMethod.None;
this[S$.username] = null;
this[S$.domain$1] = null;
this[S$.state] = 0;
this[S$.source] = null;
this[S$.type$8] = type;
}).prototype = Authentication.Authentication.prototype;
dart.addTypeTests(Authentication.Authentication);
dart.addTypeCaches(Authentication.Authentication);
dart.setGetterSignature(Authentication.Authentication, () => ({
__proto__: dart.getGetters(Authentication.Authentication.__proto__),
fullName: core.String
}));
dart.setLibraryUri(Authentication.Authentication, I[61]);
dart.setFieldSignature(Authentication.Authentication, () => ({
__proto__: dart.getFields(Authentication.Authentication.__proto__),
tokenIndex: dart.fieldType(dart.nullable(core.int)),
method: dart.fieldType(AuthenticationMethod.AuthenticationMethod),
username: dart.fieldType(dart.nullable(core.String)),
domain: dart.fieldType(dart.nullable(core.String)),
state: dart.fieldType(core.int),
source: dart.fieldType(dart.nullable(Source.Source)),
type: dart.finalFieldType(AuthenticationType.AuthenticationType)
}));
AuthenticationState.AuthenticationState = class AuthenticationState$ extends core.Object {
static ['_#new#tearOff']() {
return new AuthenticationState.AuthenticationState.new();
}
};
(AuthenticationState.AuthenticationState.new = function() {
;
}).prototype = AuthenticationState.AuthenticationState.prototype;
dart.addTypeTests(AuthenticationState.AuthenticationState);
dart.addTypeCaches(AuthenticationState.AuthenticationState);
dart.setLibraryUri(AuthenticationState.AuthenticationState, I[62]);
dart.setStaticFieldSignature(AuthenticationState.AuthenticationState, () => ['Denied', 'Succeeded', 'Blocked', 'Rejected', 'NeedsUpdate', 'NotFound']);
dart.defineLazy(AuthenticationState.AuthenticationState, {
/*AuthenticationState.AuthenticationState.Denied*/get Denied() {
return 1;
},
/*AuthenticationState.AuthenticationState.Succeeded*/get Succeeded() {
return 2;
},
/*AuthenticationState.AuthenticationState.Blocked*/get Blocked() {
return 4;
},
/*AuthenticationState.AuthenticationState.Rejected*/get Rejected() {
return 8;
},
/*AuthenticationState.AuthenticationState.NeedsUpdate*/get NeedsUpdate() {
return 16;
},
/*AuthenticationState.AuthenticationState.NotFound*/get NotFound() {
return 32;
}
}, false);
AuthenticationType.AuthenticationType = class AuthenticationType extends core._Enum {
toString() {
return "AuthenticationType." + dart.str(this[S$._name$1]);
}
};
(AuthenticationType.AuthenticationType.new = function(index, name) {
if (index == null) dart.nullFailed(I[63], 25, 6, "index");
if (name == null) dart.nullFailed(I[63], 25, 6, "name");
AuthenticationType.AuthenticationType.__proto__.new.call(this, index, name);
;
}).prototype = AuthenticationType.AuthenticationType.prototype;
dart.addTypeTests(AuthenticationType.AuthenticationType);
dart.addTypeCaches(AuthenticationType.AuthenticationType);
dart.setLibraryUri(AuthenticationType.AuthenticationType, I[63]);
dart.setStaticFieldSignature(AuthenticationType.AuthenticationType, () => ['values', 'Host', 'CoHost', 'Client', 'Alien']);
dart.defineExtensionMethods(AuthenticationType.AuthenticationType, ['toString']);
AuthenticationType.AuthenticationType.Host = C[123] || CT.C123;
AuthenticationType.AuthenticationType.CoHost = C[124] || CT.C124;
AuthenticationType.AuthenticationType.Client = C[125] || CT.C125;
AuthenticationType.AuthenticationType.Alien = C[126] || CT.C126;
AuthenticationType.AuthenticationType.values = C[127] || CT.C127;
AuthenticationMethod.AuthenticationMethod = class AuthenticationMethod extends core._Enum {
toString() {
return "AuthenticationMethod." + dart.str(this[S$._name$1]);
}
};
(AuthenticationMethod.AuthenticationMethod.new = function(index, name) {
if (index == null) dart.nullFailed(I[64], 10, 10, "index");
if (name == null) dart.nullFailed(I[64], 10, 10, "name");
AuthenticationMethod.AuthenticationMethod.__proto__.new.call(this, index, name);
;
}).prototype = AuthenticationMethod.AuthenticationMethod.prototype;
dart.addTypeTests(AuthenticationMethod.AuthenticationMethod);
dart.addTypeCaches(AuthenticationMethod.AuthenticationMethod);
dart.setLibraryUri(AuthenticationMethod.AuthenticationMethod, I[64]);
dart.setStaticFieldSignature(AuthenticationMethod.AuthenticationMethod, () => ['values', 'None', 'Certificate', 'Credentials', 'Token']);
dart.defineExtensionMethods(AuthenticationMethod.AuthenticationMethod, ['toString']);
AuthenticationMethod.AuthenticationMethod.None = C[108] || CT.C108;
AuthenticationMethod.AuthenticationMethod.Certificate = C[128] || CT.C128;
AuthenticationMethod.AuthenticationMethod.Credentials = C[129] || CT.C129;
AuthenticationMethod.AuthenticationMethod.Token = C[130] || CT.C130;
AuthenticationMethod.AuthenticationMethod.values = C[131] || CT.C131;
ClientAuthentication.ClientAuthentication = class ClientAuthentication$ extends Authentication.Authentication {
static ['_#new#tearOff']() {
return new ClientAuthentication.ClientAuthentication.new();
}
};
(ClientAuthentication.ClientAuthentication.new = function() {
ClientAuthentication.ClientAuthentication.__proto__.new.call(this, AuthenticationType.AuthenticationType.Client);
}).prototype = ClientAuthentication.ClientAuthentication.prototype;
dart.addTypeTests(ClientAuthentication.ClientAuthentication);
dart.addTypeCaches(ClientAuthentication.ClientAuthentication);
dart.setLibraryUri(ClientAuthentication.ClientAuthentication, I[65]);
CoHostAuthentication.CoHostAuthentication = class CoHostAuthentication$ extends Authentication.Authentication {
static ['_#new#tearOff']() {
return new CoHostAuthentication.CoHostAuthentication.new();
}
};
(CoHostAuthentication.CoHostAuthentication.new = function() {
CoHostAuthentication.CoHostAuthentication.__proto__.new.call(this, AuthenticationType.AuthenticationType.Client);
}).prototype = CoHostAuthentication.CoHostAuthentication.prototype;
dart.addTypeTests(CoHostAuthentication.CoHostAuthentication);
dart.addTypeCaches(CoHostAuthentication.CoHostAuthentication);
dart.setLibraryUri(CoHostAuthentication.CoHostAuthentication, I[66]);
HostAuthentication.HostAuthentication = class HostAuthentication$ extends Authentication.Authentication {
static ['_#new#tearOff']() {
return new HostAuthentication.HostAuthentication.new();
}
};
(HostAuthentication.HostAuthentication.new = function() {
HostAuthentication.HostAuthentication.__proto__.new.call(this, AuthenticationType.AuthenticationType.Client);
}).prototype = HostAuthentication.HostAuthentication.prototype;
dart.addTypeTests(HostAuthentication.HostAuthentication);
dart.addTypeCaches(HostAuthentication.HostAuthentication);
dart.setLibraryUri(HostAuthentication.HostAuthentication, I[67]);
Session.Session = class Session$ extends core.Object {
get id() {
return this[S$.id];
}
set id(value) {
this[S$.id] = value;
}
get variables() {
return this[S$.variables$1];
}
set variables(value) {
super.variables = value;
}
get localAuthentication() {
return this[S$._localAuth];
}
get remoteAuthentication() {
return this[S$._remoteAuth];
}
static ['_#new#tearOff'](_localAuth, _remoteAuth) {
if (_localAuth == null) dart.nullFailed(I[68], 48, 18, "_localAuth");
if (_remoteAuth == null) dart.nullFailed(I[68], 48, 35, "_remoteAuth");
return new Session.Session.new(_localAuth, _remoteAuth);
}
};
(Session.Session.new = function(_localAuth, _remoteAuth) {
if (_localAuth == null) dart.nullFailed(I[68], 48, 18, "_localAuth");
if (_remoteAuth == null) dart.nullFailed(I[68], 48, 35, "_remoteAuth");
this[S$.id] = null;
this[S$.variables$1] = new (T$.KeyListOfString$dynamic()).new();
this[S$._localAuth] = _localAuth;
this[S$._remoteAuth] = _remoteAuth;
}).prototype = Session.Session.prototype;
dart.addTypeTests(Session.Session);
dart.addTypeCaches(Session.Session);
dart.setGetterSignature(Session.Session, () => ({
__proto__: dart.getGetters(Session.Session.__proto__),
localAuthentication: Authentication.Authentication,
remoteAuthentication: Authentication.Authentication
}));
dart.setLibraryUri(Session.Session, I[68]);
dart.setFieldSignature(Session.Session, () => ({
__proto__: dart.getFields(Session.Session.__proto__),
id: dart.fieldType(dart.nullable(DC.DC)),
variables: dart.finalFieldType(KeyList$.KeyList$(core.String, dart.dynamic)),
[S$._localAuth]: dart.fieldType(Authentication.Authentication),
[S$._remoteAuth]: dart.fieldType(Authentication.Authentication)
}));
Source.Source = class Source$ extends core.Object {
get id() {
return this[S$.id$1];
}
set id(value) {
this[S$.id$1] = value;
}
get attributes() {
return this[S$.attributes];
}
set attributes(value) {
this[S$.attributes] = value;
}
static ['_#from#tearOff'](id, attributes) {
if (id == null) dart.nullFailed(I[69], 35, 20, "id");
if (attributes == null) dart.nullFailed(I[69], 35, 29, "attributes");
return new Source.Source.from(id, attributes);
}
};
(Source.Source.from = function(id, attributes) {
if (id == null) dart.nullFailed(I[69], 35, 20, "id");
if (attributes == null) dart.nullFailed(I[69], 35, 29, "attributes");
this[S$.attributes] = new (T$.KeyListOfSourceAttributeType$dynamic()).new();
this[S$.id$1] = id;
this[S$.attributes] = attributes;
}).prototype = Source.Source.prototype;
dart.addTypeTests(Source.Source);
dart.addTypeCaches(Source.Source);
dart.setLibraryUri(Source.Source, I[69]);
dart.setFieldSignature(Source.Source, () => ({
__proto__: dart.getFields(Source.Source.__proto__),
id: dart.fieldType(core.String),
attributes: dart.fieldType(KeyList$.KeyList$(SourceAttributeType.SourceAttributeType, dart.dynamic))
}));
SourceAttributeType.SourceAttributeType = class SourceAttributeType extends core._Enum {
toString() {
return "SourceAttributeType." + dart.str(this[S$._name$1]);
}
};
(SourceAttributeType.SourceAttributeType.new = function(index, name) {
if (index == null) dart.nullFailed(I[70], 26, 6, "index");
if (name == null) dart.nullFailed(I[70], 26, 6, "name");
SourceAttributeType.SourceAttributeType.__proto__.new.call(this, index, name);
;
}).prototype = SourceAttributeType.SourceAttributeType.prototype;
dart.addTypeTests(SourceAttributeType.SourceAttributeType);
dart.addTypeCaches(SourceAttributeType.SourceAttributeType);
dart.setLibraryUri(SourceAttributeType.SourceAttributeType, I[70]);
dart.setStaticFieldSignature(SourceAttributeType.SourceAttributeType, () => ['values', 'Mobility', 'CPU', 'IPv4', 'IPv6', 'Port', 'Proxy', 'Route', 'Location', 'OS', 'Application', 'Network', 'Display', 'Media', 'Identity']);
dart.defineExtensionMethods(SourceAttributeType.SourceAttributeType, ['toString']);
SourceAttributeType.SourceAttributeType.Mobility = C[132] || CT.C132;
SourceAttributeType.SourceAttributeType.CPU = C[133] || CT.C133;
SourceAttributeType.SourceAttributeType.IPv4 = C[134] || CT.C134;
SourceAttributeType.SourceAttributeType.IPv6 = C[135] || CT.C135;
SourceAttributeType.SourceAttributeType.Port = C[136] || CT.C136;
SourceAttributeType.SourceAttributeType.Proxy = C[137] || CT.C137;
SourceAttributeType.SourceAttributeType.Route = C[138] || CT.C138;
SourceAttributeType.SourceAttributeType.Location = C[139] || CT.C139;
SourceAttributeType.SourceAttributeType.OS = C[140] || CT.C140;
SourceAttributeType.SourceAttributeType.Application = C[141] || CT.C141;
SourceAttributeType.SourceAttributeType.Network = C[142] || CT.C142;
SourceAttributeType.SourceAttributeType.Display = C[143] || CT.C143;
SourceAttributeType.SourceAttributeType.Media = C[144] || CT.C144;
SourceAttributeType.SourceAttributeType.Identity = C[145] || CT.C145;
SourceAttributeType.SourceAttributeType.values = C[146] || CT.C146;
SHA256.SHA256 = class SHA256$ extends core.Object {
static RROT(n, d) {
if (n == null) dart.nullFailed(I[71], 6, 23, "n");
if (d == null) dart.nullFailed(I[71], 6, 30, "d");
return (dart.notNull(SHA256.SHA256.ZSHIFT(n, d)) | n[S$.$leftShift](32 - dart.notNull(d))) >>> 0;
}
static ZSHIFT(n, d) {
if (n == null) dart.nullFailed(I[71], 11, 25, "n");
if (d == null) dart.nullFailed(I[71], 11, 32, "d");
return ((dart.notNull(n) & 4294967295) >>> 0)[S$.$rightShift](d);
}
static compute(msg) {
let t26;
if (msg == null) dart.nullFailed(I[71], 15, 24, "msg");
let hash = _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([1779033703, 3144134277, 1013904242, 2773480762, 1359893119, 2600822924, 528734635, 1541459225]));
let k = _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([1116352408, 1899447441, 3049323471, 3921009573, 961987163, 1508970993, 2453635748, 2870763221, 3624381080, 310598401, 607225278, 1426881987, 1925078388, 2162078206, 2614888103, 3248222580, 3835390401, 4022224774, 264347078, 604807628, 770255983, 1249150122, 1555081692, 1996064986, 2554220882, 2821834349, 2952996808, 3210313671, 3336571891, 3584528711, 113926993, 338241895, 666307205, 773529912, 1294757372, 1396182291, 1695183700, 1986661051, 2177026350, 2456956037, 2730485921, 2820302411, 3259730800, 3345764771, 3516065817, 3600352804, 4094571909, 275423344, 430227734, 506948616, 659060556, 883997877, 958139571, 1322822218, 1537002063, 1747873779, 1955562222, 2024104815, 2227730452, 2361852424, 2428436474, 2756734187, 3204031479, 3329325298]));
let L = dart.notNull(msg.length) * 8;
let K = 512 - (L + 1 + 64)[S$.$modulo](512);
if (K === 512) K = 0;
let paddingLength = ((K + 1) / 8)[S$.$truncate]();
let paddingBytes = new DC.DC.new(paddingLength);
paddingBytes._set(0, 128);
let data = (t26 = new BinaryList.BinaryList.new(), (() => {
t26.addDC(msg);
t26.addDC(paddingBytes);
t26.addUint64(L, typed_data.Endian.big);
return t26;
})()).toDC();
for (let chunk = 0; chunk < dart.notNull(data.length); chunk = chunk + 64) {
let w = _native_typed_data.NativeUint32List.new(64);
for (let i = 0; i < 16; i = i + 1)
w[S$.$_set](i, data.getUint32(chunk + i * 4, typed_data.Endian.big));
for (let i = 16; i < 64; i = i + 1) {
let s0 = (dart.notNull(SHA256.SHA256.RROT(w[S$.$_get](i - 15), 7)) ^ dart.notNull(SHA256.SHA256.RROT(w[S$.$_get](i - 15), 18)) ^ dart.notNull(SHA256.SHA256.ZSHIFT(w[S$.$_get](i - 15), 3))) >>> 0;
let s1 = (dart.notNull(SHA256.SHA256.RROT(w[S$.$_get](i - 2), 17)) ^ dart.notNull(SHA256.SHA256.RROT(w[S$.$_get](i - 2), 19)) ^ dart.notNull(SHA256.SHA256.ZSHIFT(w[S$.$_get](i - 2), 10))) >>> 0;
w[S$.$_set](i, dart.notNull(w[S$.$_get](i - 16)) + s0 + dart.notNull(w[S$.$_get](i - 7)) + s1);
}
let a = hash[S$.$_get](0);
let b = hash[S$.$_get](1);
let c = hash[S$.$_get](2);
let d = hash[S$.$_get](3);
let e = hash[S$.$_get](4);
let f = hash[S$.$_get](5);
let g = hash[S$.$_get](6);
let h = hash[S$.$_get](7);
for (let i = 0; i < 64; i = i + 1) {
let S1 = (dart.notNull(SHA256.SHA256.RROT(e, 6)) ^ dart.notNull(SHA256.SHA256.RROT(e, 11)) ^ dart.notNull(SHA256.SHA256.RROT(e, 25))) >>> 0;
let ch = (dart.notNull(e) & dart.notNull(f) ^ (~dart.notNull(e) & dart.notNull(g)) >>> 0) >>> 0;
let temp1 = dart.notNull(h) + S1 + ch + dart.notNull(k[S$.$_get](i)) + dart.notNull(w[S$.$_get](i));
let S0 = (dart.notNull(SHA256.SHA256.RROT(a, 2)) ^ dart.notNull(SHA256.SHA256.RROT(a, 13)) ^ dart.notNull(SHA256.SHA256.RROT(a, 22))) >>> 0;
let maj = (dart.notNull(a) & dart.notNull(b) ^ (dart.notNull(a) & dart.notNull(c)) >>> 0 ^ (dart.notNull(b) & dart.notNull(c)) >>> 0) >>> 0;
let temp2 = S0 + maj;
h = g;
g = f;
f = e;
e = SHA256.SHA256.ZSHIFT(dart.notNull(d) + temp1, 0);
d = c;
c = b;
b = a;
a = SHA256.SHA256.ZSHIFT(temp1 + temp2, 0);
}
hash[S$.$_set](0, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](0)) + dart.notNull(a), 0));
hash[S$.$_set](1, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](1)) + dart.notNull(b), 0));
hash[S$.$_set](2, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](2)) + dart.notNull(c), 0));
hash[S$.$_set](3, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](3)) + dart.notNull(d), 0));
hash[S$.$_set](4, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](4)) + dart.notNull(e), 0));
hash[S$.$_set](5, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](5)) + dart.notNull(f), 0));
hash[S$.$_set](6, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](6)) + dart.notNull(g), 0));
hash[S$.$_set](7, SHA256.SHA256.ZSHIFT(dart.notNull(hash[S$.$_get](7)) + dart.notNull(h), 0));
}
let results = new BinaryList.BinaryList.new();
for (let i = 0; i < 8; i = i + 1)
results.addUint32(hash[S$.$_get](i), typed_data.Endian.big);
return results.toDC();
}
static ['_#new#tearOff']() {
return new SHA256.SHA256.new();
}
};
(SHA256.SHA256.new = function() {
;
}).prototype = SHA256.SHA256.prototype;
dart.addTypeTests(SHA256.SHA256);
dart.addTypeCaches(SHA256.SHA256);
dart.setStaticMethodSignature(SHA256.SHA256, () => ['RROT', 'ZSHIFT', 'compute']);
dart.setLibraryUri(SHA256.SHA256, I[71]);
ActionType.ActionType = class ActionType extends core._Enum {
toString() {
return "ActionType." + dart.str(this[S$._name$1]);
}
};
(ActionType.ActionType.new = function(index, name) {
if (index == null) dart.nullFailed(I[72], 24, 6, "index");
if (name == null) dart.nullFailed(I[72], 24, 6, "name");
ActionType.ActionType.__proto__.new.call(this, index, name);
;
}).prototype = ActionType.ActionType.prototype;
dart.addTypeTests(ActionType.ActionType);
dart.addTypeCaches(ActionType.ActionType);
dart.setLibraryUri(ActionType.ActionType, I[72]);
dart.setStaticFieldSignature(ActionType.ActionType, () => ['values', 'Attach', 'Delete', 'Execute', 'GetProperty', 'SetProperty', 'CreateResource', 'UpdateAttributes', 'InquireAttributes', 'AddParent', 'RemoveParent', 'AddChild', 'RemoveChild', 'Rename', 'ReceiveEvent', 'ViewTemplate']);
dart.defineExtensionMethods(ActionType.ActionType, ['toString']);
ActionType.ActionType.Attach = C[147] || CT.C147;
ActionType.ActionType.Delete = C[148] || CT.C148;
ActionType.ActionType.Execute = C[149] || CT.C149;
ActionType.ActionType.GetProperty = C[150] || CT.C150;
ActionType.ActionType.SetProperty = C[151] || CT.C151;
ActionType.ActionType.CreateResource = C[152] || CT.C152;
ActionType.ActionType.UpdateAttributes = C[153] || CT.C153;
ActionType.ActionType.InquireAttributes = C[154] || CT.C154;
ActionType.ActionType.AddParent = C[155] || CT.C155;
ActionType.ActionType.RemoveParent = C[156] || CT.C156;
ActionType.ActionType.AddChild = C[157] || CT.C157;
ActionType.ActionType.RemoveChild = C[158] || CT.C158;
ActionType.ActionType.Rename = C[159] || CT.C159;
ActionType.ActionType.ReceiveEvent = C[160] || CT.C160;
ActionType.ActionType.ViewTemplate = C[161] || CT.C161;
ActionType.ActionType.values = C[162] || CT.C162;
IPermissionsManager.IPermissionsManager = class IPermissionsManager extends core.Object {};
(IPermissionsManager.IPermissionsManager.new = function() {
;
}).prototype = IPermissionsManager.IPermissionsManager.prototype;
dart.addTypeTests(IPermissionsManager.IPermissionsManager);
dart.addTypeCaches(IPermissionsManager.IPermissionsManager);
dart.setLibraryUri(IPermissionsManager.IPermissionsManager, I[73]);
Ruling.Ruling = class Ruling extends core._Enum {
toString() {
return "Ruling." + dart.str(this[S$._name$1]);
}
};
(Ruling.Ruling.new = function(index, name) {
if (index == null) dart.nullFailed(I[74], 1, 6, "index");
if (name == null) dart.nullFailed(I[74], 1, 6, "name");
Ruling.Ruling.__proto__.new.call(this, index, name);
;
}).prototype = Ruling.Ruling.prototype;
dart.addTypeTests(Ruling.Ruling);
dart.addTypeCaches(Ruling.Ruling);
dart.setLibraryUri(Ruling.Ruling, I[74]);
dart.setStaticFieldSignature(Ruling.Ruling, () => ['values', 'Denied', 'Allowed', 'DontCare']);
dart.defineExtensionMethods(Ruling.Ruling, ['toString']);
Ruling.Ruling.Denied = C[163] || CT.C163;
Ruling.Ruling.Allowed = C[164] || CT.C164;
Ruling.Ruling.DontCare = C[165] || CT.C165;
Ruling.Ruling.values = C[166] || CT.C166;
TransmissionType.TransmissionTypeIdentifier = class TransmissionTypeIdentifier extends core.Object {
static ['_#new#tearOff']() {
return new TransmissionType.TransmissionTypeIdentifier.new();
}
};
(TransmissionType.TransmissionTypeIdentifier.new = function() {
;
}).prototype = TransmissionType.TransmissionTypeIdentifier.prototype;
dart.addTypeTests(TransmissionType.TransmissionTypeIdentifier);
dart.addTypeCaches(TransmissionType.TransmissionTypeIdentifier);
dart.setLibraryUri(TransmissionType.TransmissionTypeIdentifier, I[75]);
dart.setStaticFieldSignature(TransmissionType.TransmissionTypeIdentifier, () => ['Null', 'False', 'True', 'NotModified', 'UInt8', 'Int8', 'Char8', 'Int16', 'UInt16', 'Char16', 'Int32', 'UInt32', 'Float32', 'Resource', 'ResourceLocal', 'Int64', 'UInt64', 'Float64', 'DateTime', 'Int128', 'UInt128', 'Float128', 'RawData', 'String', 'List', 'ResourceList', 'RecordList', 'Map', 'MapList', 'Record', 'TypedList', 'TypedMap', 'Tuple', 'Enum', 'Constant']);
dart.defineLazy(TransmissionType.TransmissionTypeIdentifier, {
/*TransmissionType.TransmissionTypeIdentifier.Null*/get Null() {
return 0;
},
/*TransmissionType.TransmissionTypeIdentifier.False*/get False() {
return 1;
},
/*TransmissionType.TransmissionTypeIdentifier.True*/get True() {
return 2;
},
/*TransmissionType.TransmissionTypeIdentifier.NotModified*/get NotModified() {
return 3;
},
/*TransmissionType.TransmissionTypeIdentifier.UInt8*/get UInt8() {
return 8;
},
/*TransmissionType.TransmissionTypeIdentifier.Int8*/get Int8() {
return 9;
},
/*TransmissionType.TransmissionTypeIdentifier.Char8*/get Char8() {
return 10;
},
/*TransmissionType.TransmissionTypeIdentifier.Int16*/get Int16() {
return 16;
},
/*TransmissionType.TransmissionTypeIdentifier.UInt16*/get UInt16() {
return 17;
},
/*TransmissionType.TransmissionTypeIdentifier.Char16*/get Char16() {
return 18;
},
/*TransmissionType.TransmissionTypeIdentifier.Int32*/get Int32() {
return 24;
},
/*TransmissionType.TransmissionTypeIdentifier.UInt32*/get UInt32() {
return 25;
},
/*TransmissionType.TransmissionTypeIdentifier.Float32*/get Float32() {
return 26;
},
/*TransmissionType.TransmissionTypeIdentifier.Resource*/get Resource() {
return 27;
},
/*TransmissionType.TransmissionTypeIdentifier.ResourceLocal*/get ResourceLocal() {
return 28;
},
/*TransmissionType.TransmissionTypeIdentifier.Int64*/get Int64() {
return 32;
},
/*TransmissionType.TransmissionTypeIdentifier.UInt64*/get UInt64() {
return 33;
},
/*TransmissionType.TransmissionTypeIdentifier.Float64*/get Float64() {
return 34;
},
/*TransmissionType.TransmissionTypeIdentifier.DateTime*/get DateTime() {
return 35;
},
/*TransmissionType.TransmissionTypeIdentifier.Int128*/get Int128() {
return 40;
},
/*TransmissionType.TransmissionTypeIdentifier.UInt128*/get UInt128() {
return 41;
},
/*TransmissionType.TransmissionTypeIdentifier.Float128*/get Float128() {
return 42;
},
/*TransmissionType.TransmissionTypeIdentifier.RawData*/get RawData() {
return 64;
},
/*TransmissionType.TransmissionTypeIdentifier.String*/get String() {
return 65;
},
/*TransmissionType.TransmissionTypeIdentifier.List*/get List() {
return 66;
},
/*TransmissionType.TransmissionTypeIdentifier.ResourceList*/get ResourceList() {
return 67;
},
/*TransmissionType.TransmissionTypeIdentifier.RecordList*/get RecordList() {
return 68;
},
/*TransmissionType.TransmissionTypeIdentifier.Map*/get Map() {
return 69;
},
/*TransmissionType.TransmissionTypeIdentifier.MapList*/get MapList() {
return 70;
},
/*TransmissionType.TransmissionTypeIdentifier.Record*/get Record() {
return 128;
},
/*TransmissionType.TransmissionTypeIdentifier.TypedList*/get TypedList() {
return 129;
},
/*TransmissionType.TransmissionTypeIdentifier.TypedMap*/get TypedMap() {
return 130;
},
/*TransmissionType.TransmissionTypeIdentifier.Tuple*/get Tuple() {
return 131;
},
/*TransmissionType.TransmissionTypeIdentifier.Enum*/get Enum() {
return 132;
},
/*TransmissionType.TransmissionTypeIdentifier.Constant*/get Constant() {
return 133;
}
}, false);
TransmissionType.TransmissionTypeClass = class TransmissionTypeClass extends core.Object {
static ['_#new#tearOff']() {
return new TransmissionType.TransmissionTypeClass.new();
}
};
(TransmissionType.TransmissionTypeClass.new = function() {
;
}).prototype = TransmissionType.TransmissionTypeClass.prototype;
dart.addTypeTests(TransmissionType.TransmissionTypeClass);
dart.addTypeCaches(TransmissionType.TransmissionTypeClass);
dart.setLibraryUri(TransmissionType.TransmissionTypeClass, I[75]);
dart.setStaticFieldSignature(TransmissionType.TransmissionTypeClass, () => ['Fixed', 'Dynamic', 'Typed']);
dart.defineLazy(TransmissionType.TransmissionTypeClass, {
/*TransmissionType.TransmissionTypeClass.Fixed*/get Fixed() {
return 0;
},
/*TransmissionType.TransmissionTypeClass.Dynamic*/get Dynamic() {
return 1;
},
/*TransmissionType.TransmissionTypeClass.Typed*/get Typed() {
return 2;
}
}, false);
TransmissionType.TransmissionTypeParseResults = class TransmissionTypeParseResults extends core.Object {
get size() {
return this[S$.size$3];
}
set size(value) {
this[S$.size$3] = value;
}
get type() {
return this[S$.type$9];
}
set type(value) {
this[S$.type$9] = value;
}
static ['_#new#tearOff'](size, type) {
if (size == null) dart.nullFailed(I[75], 54, 37, "size");
return new TransmissionType.TransmissionTypeParseResults.new(size, type);
}
};
(TransmissionType.TransmissionTypeParseResults.new = function(size, type) {
if (size == null) dart.nullFailed(I[75], 54, 37, "size");
this[S$.size$3] = size;
this[S$.type$9] = type;
}).prototype = TransmissionType.TransmissionTypeParseResults.prototype;
dart.addTypeTests(TransmissionType.TransmissionTypeParseResults);
dart.addTypeCaches(TransmissionType.TransmissionTypeParseResults);
dart.setLibraryUri(TransmissionType.TransmissionTypeParseResults, I[75]);
dart.setFieldSignature(TransmissionType.TransmissionTypeParseResults, () => ({
__proto__: dart.getFields(TransmissionType.TransmissionTypeParseResults.__proto__),
size: dart.fieldType(core.int),
type: dart.fieldType(dart.nullable(TransmissionType.TransmissionType))
}));
TransmissionType.TransmissionType = class TransmissionType$ extends core.Object {
get identifier() {
return this[S$.identifier$1];
}
set identifier(value) {
super.identifier = value;
}
get index() {
return this[S$.index$3];
}
set index(value) {
super.index = value;
}
get classType() {
return this[S$.classType];
}
set classType(value) {
super.classType = value;
}
get offset() {
return this[S$.offset];
}
set offset(value) {
super.offset = value;
}
get contentLength() {
return this[S$.contentLength];
}
set contentLength(value) {
super.contentLength = value;
}
get exponent() {
return this[S$.exponent];
}
set exponent(value) {
super.exponent = value;
}
static ['_#new#tearOff'](identifier, classType, index, offset, contentLength, exponent = 0) {
if (identifier == null) dart.nullFailed(I[75], 68, 31, "identifier");
if (classType == null) dart.nullFailed(I[75], 68, 48, "classType");
if (index == null) dart.nullFailed(I[75], 68, 64, "index");
if (offset == null) dart.nullFailed(I[75], 69, 12, "offset");
if (contentLength == null) dart.nullFailed(I[75], 69, 25, "contentLength");
if (exponent == null) dart.nullFailed(I[75], 70, 13, "exponent");
return new TransmissionType.TransmissionType.new(identifier, classType, index, offset, contentLength, exponent);
}
static compose(identifier, data) {
if (identifier == null) dart.nullFailed(I[75], 72, 25, "identifier");
if (data == null) dart.nullFailed(I[75], 72, 40, "data");
if (data.length === 0) return new DC.DC.fromList(T$.JSArrayOfint().of([identifier]));
let cls = identifier[S$.$rightShift](6);
if (cls === 0) {
return DC.DC.combine(T$.JSArrayOfint().of([identifier]), 0, 1, data, 0, data.length);
} else {
let len = data.length;
if (len === 0) {
return new DC.DC.fromList(T$.JSArrayOfint().of([identifier]));
} else if (dart.notNull(len) <= 255) {
let rt = new DC.DC.new(2 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 8) >>> 0);
rt._set(1, len);
rt.set(data, 0, 2, len);
return rt;
} else if (dart.notNull(len) <= 65535) {
let rt = new DC.DC.new(3 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 16) >>> 0);
rt._set(1, dart.notNull(len) >> 8 & 255);
rt._set(2, dart.notNull(len) & 255);
rt.set(data, 0, 3, len);
return rt;
} else if (dart.notNull(len) <= 16777215) {
let rt = new DC.DC.new(4 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 24) >>> 0);
rt._set(1, dart.notNull(len) >> 16 & 255);
rt._set(2, dart.notNull(len) >> 8 & 255);
rt._set(3, dart.notNull(len) & 255);
rt.set(data, 0, 4, len);
return rt;
} else if (dart.notNull(len) <= 4294967295) {
let rt = new DC.DC.new(5 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 32) >>> 0);
rt._set(1, len[S$.$rightShift](24) & 255);
rt._set(2, dart.notNull(len) >> 16 & 255);
rt._set(3, dart.notNull(len) >> 8 & 255);
rt._set(4, dart.notNull(len) & 255);
rt.set(data, 0, 5, len);
return rt;
} else if (dart.notNull(len) <= 1099511627775) {
let rt = new DC.DC.new(6 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 40) >>> 0);
rt._set(1, len[S$.$rightShift](32) & 255);
rt._set(2, len[S$.$rightShift](24) & 255);
rt._set(3, dart.notNull(len) >> 16 & 255);
rt._set(4, dart.notNull(len) >> 8 & 255);
rt._set(5, dart.notNull(len) & 255);
rt.set(data, 0, 6, len);
return rt;
} else if (dart.notNull(len) <= 281474976710655) {
let rt = new DC.DC.new(7 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 48) >>> 0);
rt._set(1, len[S$.$rightShift](40) & 255);
rt._set(2, len[S$.$rightShift](32) & 255);
rt._set(3, len[S$.$rightShift](24) & 255);
rt._set(4, dart.notNull(len) >> 16 & 255);
rt._set(5, dart.notNull(len) >> 8 & 255);
rt._set(6, dart.notNull(len) & 255);
rt.set(data, 0, 7, len);
return rt;
} else {
let rt = new DC.DC.new(8 + dart.notNull(len));
rt._set(0, (dart.notNull(identifier) | 56) >>> 0);
rt._set(1, len[S$.$rightShift](48) & 255);
rt._set(2, len[S$.$rightShift](40) & 255);
rt._set(3, len[S$.$rightShift](32) & 255);
rt._set(4, len[S$.$rightShift](24) & 255);
rt._set(5, dart.notNull(len) >> 16 & 255);
rt._set(6, dart.notNull(len) >> 8 & 255);
rt._set(7, dart.notNull(len) & 255);
data.set(data, 0, 8, len);
return rt;
}
}
}
static parse(data, offset, ends) {
let t26, t26$;
if (data == null) dart.nullFailed(I[75], 156, 48, "data");
if (offset == null) dart.nullFailed(I[75], 156, 58, "offset");
if (ends == null) dart.nullFailed(I[75], 156, 70, "ends");
let h = data._get((t26 = offset, offset = dart.notNull(t26) + 1, t26));
let cls = h[S$.$rightShift](6);
if (cls === 0) {
let exp = (dart.notNull(h) & 56) >> 3;
if (exp === 0) return new TransmissionType.TransmissionTypeParseResults.new(1, new TransmissionType.TransmissionType.new(h, cls, dart.notNull(h) & 7, 0, exp));
let cl = (1)[S$.$leftShift](exp - 1);
if (dart.notNull(ends) - dart.notNull(offset) < cl) return new TransmissionType.TransmissionTypeParseResults.new(dart.notNull(ends) - dart.notNull(offset) - cl, null);
return new TransmissionType.TransmissionTypeParseResults.new(1 + cl, new TransmissionType.TransmissionType.new(h, cls, dart.notNull(h) & 7, offset, cl, exp));
} else {
let cll = dart.notNull(h) >> 3 & 7;
if (dart.notNull(ends) - dart.notNull(offset) < cll) return new TransmissionType.TransmissionTypeParseResults.new(dart.notNull(ends) - dart.notNull(offset) - cll, null);
let cl = 0;
for (let i = 0; i < cll; i = i + 1)
cl = (cl << 8 | dart.notNull(data._get((t26$ = offset, offset = dart.notNull(t26$) + 1, t26$)))) >>> 0;
return new TransmissionType.TransmissionTypeParseResults.new(1 + cl + cll, new TransmissionType.TransmissionType.new(dart.notNull(h) & 199, cls, dart.notNull(h) & 7, offset, cl));
}
}
};
(TransmissionType.TransmissionType.new = function(identifier, classType, index, offset, contentLength, exponent = 0) {
if (identifier == null) dart.nullFailed(I[75], 68, 31, "identifier");
if (classType == null) dart.nullFailed(I[75], 68, 48, "classType");
if (index == null) dart.nullFailed(I[75], 68, 64, "index");
if (offset == null) dart.nullFailed(I[75], 69, 12, "offset");
if (contentLength == null) dart.nullFailed(I[75], 69, 25, "contentLength");
if (exponent == null) dart.nullFailed(I[75], 70, 13, "exponent");
this[S$.identifier$1] = identifier;
this[S$.classType] = classType;
this[S$.index$3] = index;
this[S$.offset] = offset;
this[S$.contentLength] = contentLength;
this[S$.exponent] = exponent;
;
}).prototype = TransmissionType.TransmissionType.prototype;
dart.addTypeTests(TransmissionType.TransmissionType);
dart.addTypeCaches(TransmissionType.TransmissionType);
dart.setStaticMethodSignature(TransmissionType.TransmissionType, () => ['compose', 'parse']);
dart.setLibraryUri(TransmissionType.TransmissionType, I[75]);
dart.setFieldSignature(TransmissionType.TransmissionType, () => ({
__proto__: dart.getFields(TransmissionType.TransmissionType.__proto__),
identifier: dart.finalFieldType(core.int),
index: dart.finalFieldType(core.int),
classType: dart.finalFieldType(core.int),
offset: dart.finalFieldType(core.int),
contentLength: dart.finalFieldType(core.int),
exponent: dart.finalFieldType(core.int)
}));
dart.setStaticFieldSignature(TransmissionType.TransmissionType, () => ['Null']);
dart.defineLazy(TransmissionType.TransmissionType, {
/*TransmissionType.TransmissionType.Null*/get Null() {
return C[167] || CT.C167;
}
}, false);
const _is_FactoryEntry_default = Symbol('_is_FactoryEntry_default');
FactoryEntry$.FactoryEntry$ = dart.generic(T => {
var __t$JSArrayOfT = () => (__t$JSArrayOfT = dart.constFn(_interceptors.JSArray$(T)))();
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$VoidToListOfT = () => (__t$VoidToListOfT = dart.constFn(dart.fnType(__t$ListOfT(), [])))();
var __t$MapOfT$dynamic = () => (__t$MapOfT$dynamic = dart.constFn(core.Map$(T, dart.dynamic)))();
var __t$MapOfdynamic$T = () => (__t$MapOfdynamic$T = dart.constFn(core.Map$(dart.dynamic, T)))();
class FactoryEntry extends core.Object {
get instanceCreator() {
return this[S$.instanceCreator];
}
set instanceCreator(value) {
super.instanceCreator = value;
}
get arrayCreator() {
return this[S$.arrayCreator];
}
set arrayCreator(value) {
super.arrayCreator = value;
}
get representationType() {
return this[S$.representationType];
}
set representationType(value) {
super.representationType = value;
}
get type() {
return dart.wrapType(T);
}
get nullableType() {
let t26;
return dart.test(this[S$.__FactoryEntry_nullableType_isSet]) ? (t26 = this[S$.__FactoryEntry_nullableType], t26) : dart.throw(new _internal.LateError.fieldNI("nullableType"));
}
set nullableType(t26) {
if (t26 == null) dart.nullFailed(I[76], 13, 13, "null");
this[S$.__FactoryEntry_nullableType_isSet] = true;
this[S$.__FactoryEntry_nullableType] = t26;
}
isMapKeySubType(map) {
if (map == null) dart.nullFailed(I[76], 18, 28, "map");
return __t$MapOfT$dynamic().is(map);
}
isMapValueSubType(map) {
if (map == null) dart.nullFailed(I[76], 22, 30, "map");
return __t$MapOfdynamic$T().is(map);
}
isListSubType(list) {
if (list == null) dart.nullFailed(I[76], 26, 27, "list");
return __t$ListOfT().is(list);
}
static ['_#new#tearOff'](T, instanceCreator, representationType) {
if (instanceCreator == null) dart.nullFailed(I[76], 30, 21, "instanceCreator");
if (representationType == null) dart.nullFailed(I[76], 30, 43, "representationType");
return new (FactoryEntry$.FactoryEntry$(T)).new(instanceCreator, representationType);
}
}
(FactoryEntry.new = function(instanceCreator, representationType) {
if (instanceCreator == null) dart.nullFailed(I[76], 30, 21, "instanceCreator");
if (representationType == null) dart.nullFailed(I[76], 30, 43, "representationType");
this[S$.__FactoryEntry_nullableType] = null;
this[S$.__FactoryEntry_nullableType_isSet] = false;
this[S$.arrayCreator] = dart.fn(() => __t$JSArrayOfT().of([]), __t$VoidToListOfT());
this[S$.instanceCreator] = instanceCreator;
this[S$.representationType] = representationType;
this.nullableType = RepresentationType.getNullableType(T);
}).prototype = FactoryEntry.prototype;
dart.addTypeTests(FactoryEntry);
FactoryEntry.prototype[_is_FactoryEntry_default] = true;
dart.addTypeCaches(FactoryEntry);
dart.setMethodSignature(FactoryEntry, () => ({
__proto__: dart.getMethods(FactoryEntry.__proto__),
isMapKeySubType: dart.fnType(core.bool, [core.Map]),
isMapValueSubType: dart.fnType(core.bool, [core.Map]),
isListSubType: dart.fnType(core.bool, [core.List])
}));
dart.setGetterSignature(FactoryEntry, () => ({
__proto__: dart.getGetters(FactoryEntry.__proto__),
type: core.Type,
nullableType: core.Type
}));
dart.setSetterSignature(FactoryEntry, () => ({
__proto__: dart.getSetters(FactoryEntry.__proto__),
nullableType: core.Type
}));
dart.setLibraryUri(FactoryEntry, I[76]);
dart.setFieldSignature(FactoryEntry, () => ({
__proto__: dart.getFields(FactoryEntry.__proto__),
[S$.__FactoryEntry_nullableType]: dart.fieldType(dart.nullable(core.Type)),
[S$.__FactoryEntry_nullableType_isSet]: dart.fieldType(core.bool),
instanceCreator: dart.finalFieldType(core.Function),
arrayCreator: dart.finalFieldType(core.Function),
representationType: dart.finalFieldType(RepresentationType.RepresentationType)
}));
return FactoryEntry;
});
FactoryEntry$.FactoryEntry = FactoryEntry$.FactoryEntry$();
dart.addTypeTests(FactoryEntry$.FactoryEntry, _is_FactoryEntry_default);
TemplateType.TemplateType = class TemplateType extends core._Enum {
toString() {
return "TemplateType." + dart.str(this[S$._name$1]);
}
};
(TemplateType.TemplateType.new = function(index, name) {
if (index == null) dart.nullFailed(I[77], 1, 6, "index");
if (name == null) dart.nullFailed(I[77], 1, 6, "name");
TemplateType.TemplateType.__proto__.new.call(this, index, name);
;
}).prototype = TemplateType.TemplateType.prototype;
dart.addTypeTests(TemplateType.TemplateType);
dart.addTypeCaches(TemplateType.TemplateType);
dart.setLibraryUri(TemplateType.TemplateType, I[77]);
dart.setStaticFieldSignature(TemplateType.TemplateType, () => ['values', 'Unspecified', 'Resource', 'Record', 'Wrapper', 'Enum']);
dart.defineExtensionMethods(TemplateType.TemplateType, ['toString']);
TemplateType.TemplateType.Unspecified = C[0] || CT.C0;
TemplateType.TemplateType.Resource = C[168] || CT.C168;
TemplateType.TemplateType.Record = C[169] || CT.C169;
TemplateType.TemplateType.Wrapper = C[170] || CT.C170;
TemplateType.TemplateType.Enum = C[171] || CT.C171;
TemplateType.TemplateType.values = C[172] || CT.C172;
EventOccurredInfo.EventOccurredInfo = class EventOccurredInfo$ extends core.Object {
get eventTemplate() {
return this[S$.eventTemplate];
}
set eventTemplate(value) {
super.eventTemplate = value;
}
get resource() {
return this[S$.resource$1];
}
set resource(value) {
super.resource = value;
}
get value() {
return this[S$.value$6];
}
set value(value) {
super.value = value;
}
get issuer() {
return this[S$.issuer];
}
set issuer(value) {
super.issuer = value;
}
get receivers() {
return this[S$.receivers];
}
set receivers(value) {
super.receivers = value;
}
get name() {
return this.eventTemplate.name;
}
static ['_#new#tearOff'](resource, eventTemplate, value, issuer, receivers) {
if (resource == null) dart.nullFailed(I[78], 16, 26, "resource");
if (eventTemplate == null) dart.nullFailed(I[78], 16, 41, "eventTemplate");
return new EventOccurredInfo.EventOccurredInfo.new(resource, eventTemplate, value, issuer, receivers);
}
};
(EventOccurredInfo.EventOccurredInfo.new = function(resource, eventTemplate, value, issuer, receivers) {
if (resource == null) dart.nullFailed(I[78], 16, 26, "resource");
if (eventTemplate == null) dart.nullFailed(I[78], 16, 41, "eventTemplate");
this[S$.resource$1] = resource;
this[S$.eventTemplate] = eventTemplate;
this[S$.value$6] = value;
this[S$.issuer] = issuer;
this[S$.receivers] = receivers;
}).prototype = EventOccurredInfo.EventOccurredInfo.prototype;
dart.addTypeTests(EventOccurredInfo.EventOccurredInfo);
dart.addTypeCaches(EventOccurredInfo.EventOccurredInfo);
dart.setGetterSignature(EventOccurredInfo.EventOccurredInfo, () => ({
__proto__: dart.getGetters(EventOccurredInfo.EventOccurredInfo.__proto__),
name: core.String
}));
dart.setLibraryUri(EventOccurredInfo.EventOccurredInfo, I[78]);
dart.setFieldSignature(EventOccurredInfo.EventOccurredInfo, () => ({
__proto__: dart.getFields(EventOccurredInfo.EventOccurredInfo.__proto__),
eventTemplate: dart.finalFieldType(EventTemplate.EventTemplate),
resource: dart.finalFieldType(IResource.IResource),
value: dart.finalFieldType(dart.dynamic),
issuer: dart.finalFieldType(dart.dynamic),
receivers: dart.finalFieldType(dart.nullable(dart.fnType(core.bool, [Session.Session])))
}));
PropertyModificationInfo.PropertyModificationInfo = class PropertyModificationInfo$ extends core.Object {
get propertyTemplate() {
return this[S$.propertyTemplate];
}
set propertyTemplate(value) {
super.propertyTemplate = value;
}
get value() {
return this[S$.value$7];
}
set value(value) {
super.value = value;
}
get age() {
return this[S$.age$1];
}
set age(value) {
super.age = value;
}
get resource() {
return this[S$.resource$2];
}
set resource(value) {
super.resource = value;
}
get name() {
return this.propertyTemplate.name;
}
static ['_#new#tearOff'](resource, propertyTemplate, value, age) {
if (resource == null) dart.nullFailed(I[79], 13, 12, "resource");
if (propertyTemplate == null) dart.nullFailed(I[79], 13, 27, "propertyTemplate");
if (age == null) dart.nullFailed(I[79], 13, 62, "age");
return new PropertyModificationInfo.PropertyModificationInfo.new(resource, propertyTemplate, value, age);
}
};
(PropertyModificationInfo.PropertyModificationInfo.new = function(resource, propertyTemplate, value, age) {
if (resource == null) dart.nullFailed(I[79], 13, 12, "resource");
if (propertyTemplate == null) dart.nullFailed(I[79], 13, 27, "propertyTemplate");
if (age == null) dart.nullFailed(I[79], 13, 62, "age");
this[S$.resource$2] = resource;
this[S$.propertyTemplate] = propertyTemplate;
this[S$.value$7] = value;
this[S$.age$1] = age;
;
}).prototype = PropertyModificationInfo.PropertyModificationInfo.prototype;
dart.addTypeTests(PropertyModificationInfo.PropertyModificationInfo);
dart.addTypeCaches(PropertyModificationInfo.PropertyModificationInfo);
dart.setGetterSignature(PropertyModificationInfo.PropertyModificationInfo, () => ({
__proto__: dart.getGetters(PropertyModificationInfo.PropertyModificationInfo.__proto__),
name: core.String
}));
dart.setLibraryUri(PropertyModificationInfo.PropertyModificationInfo, I[79]);
dart.setFieldSignature(PropertyModificationInfo.PropertyModificationInfo, () => ({
__proto__: dart.getFields(PropertyModificationInfo.PropertyModificationInfo.__proto__),
propertyTemplate: dart.finalFieldType(PropertyTemplate.PropertyTemplate),
value: dart.finalFieldType(dart.dynamic),
age: dart.finalFieldType(core.int),
resource: dart.finalFieldType(IResource.IResource)
}));
ArgumentTemplate.ArgumentTemplate = class ArgumentTemplate$ extends core.Object {
get name() {
return this[S$.name$7];
}
set name(value) {
super.name = value;
}
get optional() {
return this[S$.optional$1];
}
set optional(value) {
super.optional = value;
}
get type() {
return this[S$.type$10];
}
set type(value) {
super.type = value;
}
get index() {
return this[S$.index$4];
}
set index(value) {
super.index = value;
}
static parse(data, offset, index) {
let t27, t27$;
if (data == null) dart.nullFailed(I[80], 13, 49, "data");
if (offset == null) dart.nullFailed(I[80], 13, 59, "offset");
if (index == null) dart.nullFailed(I[80], 13, 71, "index");
let optional = (dart.notNull(data._get((t27 = offset, offset = dart.notNull(t27) + 1, t27))) & 1) === 1;
let cs = data._get((t27$ = offset, offset = dart.notNull(t27$) + 1, t27$));
let name = data.getString(offset, cs);
offset = dart.notNull(offset) + dart.notNull(cs);
let tdr = RepresentationType.RepresentationType.parse(data, offset);
return new (T$.ParseResultOfArgumentTemplate()).new(dart.notNull(cs) + 2 + dart.notNull(tdr.size), new ArgumentTemplate.ArgumentTemplate.new(name, tdr.type, optional, index));
}
static ['_#new#tearOff'](name, type, optional, index) {
if (name == null) dart.nullFailed(I[80], 25, 25, "name");
if (type == null) dart.nullFailed(I[80], 25, 36, "type");
if (optional == null) dart.nullFailed(I[80], 25, 47, "optional");
if (index == null) dart.nullFailed(I[80], 25, 62, "index");
return new ArgumentTemplate.ArgumentTemplate.new(name, type, optional, index);
}
compose() {
let t27;
let name = DC.DC.stringToBytes(this.name);
return (t27 = new BinaryList.BinaryList.new(), (() => {
t27.addUint8(dart.test(this.optional) ? 1 : 0);
t27.addUint8(name.length);
t27.addDC(name);
t27.addDC(this.type.compose());
return t27;
})()).toDC();
}
};
(ArgumentTemplate.ArgumentTemplate.new = function(name, type, optional, index) {
if (name == null) dart.nullFailed(I[80], 25, 25, "name");
if (type == null) dart.nullFailed(I[80], 25, 36, "type");
if (optional == null) dart.nullFailed(I[80], 25, 47, "optional");
if (index == null) dart.nullFailed(I[80], 25, 62, "index");
this[S$.name$7] = name;
this[S$.type$10] = type;
this[S$.optional$1] = optional;
this[S$.index$4] = index;
;
}).prototype = ArgumentTemplate.ArgumentTemplate.prototype;
dart.addTypeTests(ArgumentTemplate.ArgumentTemplate);
dart.addTypeCaches(ArgumentTemplate.ArgumentTemplate);
dart.setMethodSignature(ArgumentTemplate.ArgumentTemplate, () => ({
__proto__: dart.getMethods(ArgumentTemplate.ArgumentTemplate.__proto__),
compose: dart.fnType(DC.DC, [])
}));
dart.setStaticMethodSignature(ArgumentTemplate.ArgumentTemplate, () => ['parse']);
dart.setLibraryUri(ArgumentTemplate.ArgumentTemplate, I[80]);
dart.setFieldSignature(ArgumentTemplate.ArgumentTemplate, () => ({
__proto__: dart.getFields(ArgumentTemplate.ArgumentTemplate.__proto__),
name: dart.finalFieldType(core.String),
optional: dart.finalFieldType(core.bool),
type: dart.finalFieldType(RepresentationType.RepresentationType),
index: dart.finalFieldType(core.int)
}));
ConstantTemplate.ConstantTemplate = class ConstantTemplate$ extends MemberTemplate.MemberTemplate {
get value() {
return this[S$.value$8];
}
set value(value) {
super.value = value;
}
get expansion() {
return this[S$.expansion$2];
}
set expansion(value) {
super.expansion = value;
}
get valueType() {
return this[S$.valueType$1];
}
set valueType(value) {
super.valueType = value;
}
static ['_#new#tearOff'](template, index, name, inherited, valueType, value, expansion) {
if (template == null) dart.nullFailed(I[81], 14, 33, "template");
if (index == null) dart.nullFailed(I[81], 14, 47, "index");
if (name == null) dart.nullFailed(I[81], 14, 61, "name");
if (inherited == null) dart.nullFailed(I[81], 15, 12, "inherited");
if (valueType == null) dart.nullFailed(I[81], 15, 28, "valueType");
return new ConstantTemplate.ConstantTemplate.new(template, index, name, inherited, valueType, value, expansion);
}
compose() {
let t27, t27$;
let name = super.compose();
let hdr = dart.test(this.inherited) ? 128 : 0;
if (this.expansion != null) {
let exp = DC.DC.stringToBytes(dart.nullCheck(this.expansion));
hdr = (hdr | 112) >>> 0;
return (t27 = new BinaryList.BinaryList.new(), (() => {
t27.addUint8(hdr);
t27.addUint8(name.length);
t27.addDC(name);
t27.addDC(this.valueType.compose());
t27.addDC(Codec.Codec.compose(this.value, null));
t27.addInt32(exp.length);
t27.addDC(exp);
return t27;
})()).toDC();
} else {
hdr = (hdr | 96) >>> 0;
return (t27$ = new BinaryList.BinaryList.new(), (() => {
t27$.addUint8(hdr);
t27$.addUint8(name.length);
t27$.addDC(name);
t27$.addDC(this.valueType.compose());
t27$.addDC(Codec.Codec.compose(this.value, null));
return t27$;
})()).toDC();
}
}
};
(ConstantTemplate.ConstantTemplate.new = function(template, index, name, inherited, valueType, value, expansion) {
if (template == null) dart.nullFailed(I[81], 14, 33, "template");
if (index == null) dart.nullFailed(I[81], 14, 47, "index");
if (name == null) dart.nullFailed(I[81], 14, 61, "name");
if (inherited == null) dart.nullFailed(I[81], 15, 12, "inherited");
if (valueType == null) dart.nullFailed(I[81], 15, 28, "valueType");
this[S$.valueType$1] = valueType;
this[S$.value$8] = value;
this[S$.expansion$2] = expansion;
ConstantTemplate.ConstantTemplate.__proto__.new.call(this, template, index, name, inherited);
}).prototype = ConstantTemplate.ConstantTemplate.prototype;
dart.addTypeTests(ConstantTemplate.ConstantTemplate);
dart.addTypeCaches(ConstantTemplate.ConstantTemplate);
dart.setLibraryUri(ConstantTemplate.ConstantTemplate, I[81]);
dart.setFieldSignature(ConstantTemplate.ConstantTemplate, () => ({
__proto__: dart.getFields(ConstantTemplate.ConstantTemplate.__proto__),
value: dart.finalFieldType(dart.dynamic),
expansion: dart.finalFieldType(dart.nullable(core.String)),
valueType: dart.finalFieldType(RepresentationType.RepresentationType)
}));
DataDeserializer.PropertyValueParserResults = class PropertyValueParserResults extends core.Object {
get size() {
return this[S$.size$4];
}
set size(value) {
super.size = value;
}
get reply() {
return this[S$.reply$2];
}
set reply(value) {
super.reply = value;
}
static ['_#new#tearOff'](size, reply) {
if (size == null) dart.nullFailed(I[82], 22, 35, "size");
if (reply == null) dart.nullFailed(I[82], 22, 46, "reply");
return new DataDeserializer.PropertyValueParserResults.new(size, reply);
}
};
(DataDeserializer.PropertyValueParserResults.new = function(size, reply) {
if (size == null) dart.nullFailed(I[82], 22, 35, "size");
if (reply == null) dart.nullFailed(I[82], 22, 46, "reply");
this[S$.size$4] = size;
this[S$.reply$2] = reply;
;
}).prototype = DataDeserializer.PropertyValueParserResults.prototype;
dart.addTypeTests(DataDeserializer.PropertyValueParserResults);
dart.addTypeCaches(DataDeserializer.PropertyValueParserResults);
dart.setLibraryUri(DataDeserializer.PropertyValueParserResults, I[82]);
dart.setFieldSignature(DataDeserializer.PropertyValueParserResults, () => ({
__proto__: dart.getFields(DataDeserializer.PropertyValueParserResults.__proto__),
size: dart.finalFieldType(core.int),
reply: dart.finalFieldType(AsyncReply$.AsyncReply$(PropertyValue.PropertyValue))
}));
DataDeserializer.DataDeserializer = class DataDeserializer$ extends core.Object {
static nullParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 27, 10, "data");
if (offset == null) dart.nullFailed(I[82], 27, 20, "offset");
if (length == null) dart.nullFailed(I[82], 27, 32, "length");
return new AsyncReply$.AsyncReply.ready(null);
}
static booleanTrueParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 32, 10, "data");
if (offset == null) dart.nullFailed(I[82], 32, 20, "offset");
if (length == null) dart.nullFailed(I[82], 32, 32, "length");
return new (T$.AsyncReplyOfbool()).ready(true);
}
static booleanFalseParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 37, 10, "data");
if (offset == null) dart.nullFailed(I[82], 37, 20, "offset");
if (length == null) dart.nullFailed(I[82], 37, 32, "length");
return new (T$.AsyncReplyOfbool()).ready(false);
}
static notModifiedParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 42, 10, "data");
if (offset == null) dart.nullFailed(I[82], 42, 20, "offset");
if (length == null) dart.nullFailed(I[82], 42, 32, "length");
return new (T$.AsyncReplyOfNotModified()).ready(new NotModified.NotModified.new());
}
static byteParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 47, 10, "data");
if (offset == null) dart.nullFailed(I[82], 47, 20, "offset");
if (length == null) dart.nullFailed(I[82], 47, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data._get(offset));
}
static sByteParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 52, 10, "data");
if (offset == null) dart.nullFailed(I[82], 52, 20, "offset");
if (length == null) dart.nullFailed(I[82], 52, 32, "length");
return new (T$.AsyncReplyOfint()).ready(dart.notNull(data._get(offset)) > 127 ? dart.notNull(data._get(offset)) - 256 : data._get(offset));
}
static char16Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 58, 10, "data");
if (offset == null) dart.nullFailed(I[82], 58, 20, "offset");
if (length == null) dart.nullFailed(I[82], 58, 32, "length");
return new (T$.AsyncReplyOfString()).ready(data.getChar(offset));
}
static char8Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 63, 10, "data");
if (offset == null) dart.nullFailed(I[82], 63, 20, "offset");
if (length == null) dart.nullFailed(I[82], 63, 32, "length");
return new (T$.AsyncReplyOfString()).ready(core.String.fromCharCode(data._get(offset)));
}
static int16Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 68, 10, "data");
if (offset == null) dart.nullFailed(I[82], 68, 20, "offset");
if (length == null) dart.nullFailed(I[82], 68, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getInt16(offset));
}
static uInt16Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 73, 10, "data");
if (offset == null) dart.nullFailed(I[82], 73, 20, "offset");
if (length == null) dart.nullFailed(I[82], 73, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getUint16(offset));
}
static int32Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 78, 10, "data");
if (offset == null) dart.nullFailed(I[82], 78, 20, "offset");
if (length == null) dart.nullFailed(I[82], 78, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getInt32(offset));
}
static uInt32Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 83, 10, "data");
if (offset == null) dart.nullFailed(I[82], 83, 20, "offset");
if (length == null) dart.nullFailed(I[82], 83, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getUint32(offset));
}
static float32Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 88, 10, "data");
if (offset == null) dart.nullFailed(I[82], 88, 20, "offset");
if (length == null) dart.nullFailed(I[82], 88, 32, "length");
return new (T$.AsyncReplyOfdouble()).ready(data.getFloat32(offset));
}
static float64Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 93, 10, "data");
if (offset == null) dart.nullFailed(I[82], 93, 20, "offset");
if (length == null) dart.nullFailed(I[82], 93, 32, "length");
return new (T$.AsyncReplyOfdouble()).ready(data.getFloat64(offset));
}
static float128Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 98, 10, "data");
if (offset == null) dart.nullFailed(I[82], 98, 20, "offset");
if (length == null) dart.nullFailed(I[82], 98, 32, "length");
return new (T$.AsyncReplyOfdouble()).ready(data.getFloat64(offset));
}
static int128Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 104, 10, "data");
if (offset == null) dart.nullFailed(I[82], 104, 20, "offset");
if (length == null) dart.nullFailed(I[82], 104, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getInt64(offset));
}
static uInt128Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 110, 10, "data");
if (offset == null) dart.nullFailed(I[82], 110, 20, "offset");
if (length == null) dart.nullFailed(I[82], 110, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getUint64(offset));
}
static int64Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 115, 10, "data");
if (offset == null) dart.nullFailed(I[82], 115, 20, "offset");
if (length == null) dart.nullFailed(I[82], 115, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getInt64(offset));
}
static uInt64Parser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 120, 10, "data");
if (offset == null) dart.nullFailed(I[82], 120, 20, "offset");
if (length == null) dart.nullFailed(I[82], 120, 32, "length");
return new (T$.AsyncReplyOfint()).ready(data.getUint64(offset));
}
static dateTimeParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 125, 10, "data");
if (offset == null) dart.nullFailed(I[82], 125, 20, "offset");
if (length == null) dart.nullFailed(I[82], 125, 32, "length");
return new (T$.AsyncReplyOfDateTime()).ready(data.getDateTime(offset));
}
static resourceParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 130, 10, "data");
if (offset == null) dart.nullFailed(I[82], 130, 20, "offset");
if (length == null) dart.nullFailed(I[82], 130, 32, "length");
if (connection != null) {
let id = data.getUint32(offset);
return connection.fetch(id);
}
dart.throw(core.Exception.new("Can't parse resource with no connection"));
}
static localResourceParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 139, 10, "data");
if (offset == null) dart.nullFailed(I[82], 139, 20, "offset");
if (length == null) dart.nullFailed(I[82], 139, 32, "length");
let id = data.getUint32(offset);
return Warehouse.Warehouse.getById(id);
}
static rawDataParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 145, 10, "data");
if (offset == null) dart.nullFailed(I[82], 145, 20, "offset");
if (length == null) dart.nullFailed(I[82], 145, 32, "length");
return new (T$.AsyncReplyOfDC()).ready(data.clip(offset, length));
}
static stringParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 150, 10, "data");
if (offset == null) dart.nullFailed(I[82], 150, 20, "offset");
if (length == null) dart.nullFailed(I[82], 150, 32, "length");
return new (T$.AsyncReplyOfString()).ready(data.getString(offset, length));
}
static recordParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 155, 10, "data");
if (offset == null) dart.nullFailed(I[82], 155, 20, "offset");
if (length == null) dart.nullFailed(I[82], 155, 32, "length");
let reply = new (T$.AsyncReplyOfIRecord()).new();
let classId = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
length = dart.notNull(length) - 16;
let template = Warehouse.Warehouse.getTemplateByClassId(classId, TemplateType.TemplateType.Record);
if (template != null) {
DataDeserializer.DataDeserializer.listParser(data, offset, length, connection).then(core.Null, dart.fn(r => {
if (r == null) dart.nullFailed(I[82], 165, 58, "r");
let ar = r;
let record = null;
if (template.definedType != null) {
record = IRecord.IRecord.as(Warehouse.Warehouse.createInstance(dart.dynamic, dart.nullCheck(template.definedType)));
} else {
record = new Record.Record.new();
}
let kv = new (T$.LinkedMapOfString$dynamic()).new();
for (let i = 0; i < dart.notNull(template.properties[S$.$length]); i = i + 1)
kv[S$.$_set](template.properties[S$.$_get](i).name, ar[S$.$_get](i));
record.deserialize(kv);
reply.trigger(record);
}, T$.ListToNull()));
} else {
if (connection == null) dart.throw(core.Exception.new("Can't parse record with no connection"));
connection.getTemplate(classId).then(core.Null, dart.fn(tmp => {
if (tmp == null) reply.triggerError(core.Exception.new("Couldn't fetch record template."));
DataDeserializer.DataDeserializer.listParser(data, offset, length, connection).then(core.Null, dart.fn(r => {
if (r == null) dart.nullFailed(I[82], 192, 60, "r");
let ar = r;
let record = new Record.Record.new();
let kv = new (T$.LinkedMapOfString$dynamic()).new();
for (let i = 0; i < dart.notNull(dart.nullCheck(tmp).properties[S$.$length]); i = i + 1)
kv[S$.$_set](tmp.properties[S$.$_get](i).name, ar[S$.$_get](i));
record.deserialize(kv);
reply.trigger(record);
}, T$.ListToNull()));
}, T$.TypeTemplateNToNull())).error(dart.fn(x => {
if (x == null) dart.nullFailed(I[82], 206, 17, "x");
return reply.triggerError(x);
}, T$.AsyncExceptionToAsyncReplyOfIRecord()));
}
return reply;
}
static constantParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 213, 10, "data");
if (offset == null) dart.nullFailed(I[82], 213, 20, "offset");
if (length == null) dart.nullFailed(I[82], 213, 32, "length");
dart.throw(core.Exception.new("NotImplementedException"));
}
static enumParser(data, offset, length, connection) {
let t27;
if (data == null) dart.nullFailed(I[82], 218, 10, "data");
if (offset == null) dart.nullFailed(I[82], 218, 20, "offset");
if (length == null) dart.nullFailed(I[82], 218, 32, "length");
let classId = data.getGuid(offset);
offset = dart.notNull(offset) + 16;
let index = data._get((t27 = offset, offset = dart.notNull(t27) + 1, t27));
let template = Warehouse.Warehouse.getTemplateByClassId(classId, TemplateType.TemplateType.Enum);
if (template != null) {
if (template.definedType != null) {
let enumVal = IEnum.IEnum.as(Warehouse.Warehouse.createInstance(dart.dynamic, dart.nullCheck(template.definedType)));
enumVal.index = index;
enumVal.name = template.constants[S$.$_get](index).name;
enumVal.value = template.constants[S$.$_get](index).value;
return new AsyncReply$.AsyncReply.ready(enumVal);
} else {
return new AsyncReply$.AsyncReply.ready(new IEnum.IEnum.new(index, template.constants[S$.$_get](index).value, template.constants[S$.$_get](index).name));
}
} else {
let reply = new AsyncReply$.AsyncReply.new();
if (connection == null) dart.throw(core.Exception.new("Can't parse enum with no connection"));
connection.getTemplate(classId).then(core.Null, dart.fn(tmp => {
if (tmp != null) {
if (tmp.definedType != null) {
let enumVal = IEnum.IEnum.as(Warehouse.Warehouse.createInstance(dart.dynamic, dart.nullCheck(tmp.definedType)));
enumVal.index = index;
enumVal.name = tmp.constants[S$.$_get](index).name;
enumVal.value = tmp.constants[S$.$_get](index).value;
reply.trigger(enumVal);
} else {
reply.trigger(new IEnum.IEnum.new(index, tmp.constants[S$.$_get](index).value, tmp.constants[S$.$_get](index).name));
}
} else
reply.triggerError(core.Exception.new("Template not found for enum"));
}, T$.TypeTemplateNToNull())).error(dart.fn(x => {
if (x == null) dart.nullFailed(I[82], 255, 17, "x");
return reply.triggerError(x);
}, T$.AsyncExceptionToAsyncReply()));
return reply;
}
}
static recordListParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 262, 10, "data");
if (offset == null) dart.nullFailed(I[82], 262, 20, "offset");
if (length == null) dart.nullFailed(I[82], 262, 32, "length");
let rt = new AsyncBag$.AsyncBag.new();
while (dart.notNull(length) > 0) {
let parsed = Codec.Codec.parse(data, offset, connection);
rt.add(parsed.reply);
if (dart.notNull(parsed.size) > 0) {
offset = dart.notNull(offset) + dart.notNull(parsed.size);
length = dart.notNull(length) - dart.notNull(parsed.size);
} else
dart.throw(core.Exception.new("Error while parsing structured data"));
}
rt.seal();
return rt;
}
static resourceListParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 282, 10, "data");
if (offset == null) dart.nullFailed(I[82], 282, 20, "offset");
if (length == null) dart.nullFailed(I[82], 282, 32, "length");
let rt = new AsyncBag$.AsyncBag.new();
while (dart.notNull(length) > 0) {
let parsed = Codec.Codec.parse(data, offset, connection);
rt.add(parsed.reply);
if (dart.notNull(parsed.size) > 0) {
offset = dart.notNull(offset) + dart.notNull(parsed.size);
length = dart.notNull(length) - dart.notNull(parsed.size);
} else
dart.throw(core.Exception.new("Error while parsing structured data"));
}
rt.seal();
return rt;
}
static listParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 302, 10, "data");
if (offset == null) dart.nullFailed(I[82], 302, 20, "offset");
if (length == null) dart.nullFailed(I[82], 302, 32, "length");
let rt = new AsyncBag$.AsyncBag.new();
while (dart.notNull(length) > 0) {
let parsed = Codec.Codec.parse(data, offset, connection);
rt.add(parsed.reply);
if (dart.notNull(parsed.size) > 0) {
offset = dart.notNull(offset) + dart.notNull(parsed.size);
length = dart.notNull(length) - dart.notNull(parsed.size);
} else
dart.throw(core.Exception.new("Error while parsing structured data"));
}
rt.seal();
return rt;
}
static typedMapParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 322, 10, "data");
if (offset == null) dart.nullFailed(I[82], 322, 20, "offset");
if (length == null) dart.nullFailed(I[82], 322, 32, "length");
let keyRep = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(keyRep.size);
length = dart.notNull(length) - dart.notNull(keyRep.size);
let valueRep = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(valueRep.size);
length = dart.notNull(length) - dart.notNull(valueRep.size);
let map = new _js_helper.LinkedMap.new();
let rt = new AsyncReply$.AsyncReply.new();
let results = new AsyncBag$.AsyncBag.new();
while (dart.notNull(length) > 0) {
let parsed = Codec.Codec.parse(data, offset, connection);
results.add(parsed.reply);
if (dart.notNull(parsed.size) > 0) {
offset = dart.notNull(offset) + dart.notNull(parsed.size);
length = dart.notNull(length) - dart.notNull(parsed.size);
} else
dart.throw(core.Exception.new("Error while parsing structured data"));
}
results.seal();
results.then(core.Null, dart.fn(ar => {
if (ar == null) dart.nullFailed(I[82], 353, 19, "ar");
for (let i = 0; i < dart.notNull(ar[S$.$length]); i = i + 2)
map[S$.$_set](ar[S$.$_get](i), ar[S$.$_get](i + 1));
rt.trigger(map);
}, T$.ListToNull()));
return rt;
}
static tupleParser(data, offset, length, connection) {
let t27, t27$;
if (data == null) dart.nullFailed(I[82], 363, 10, "data");
if (offset == null) dart.nullFailed(I[82], 363, 20, "offset");
if (length == null) dart.nullFailed(I[82], 363, 32, "length");
let results = new AsyncBag$.AsyncBag.new();
let rt = new AsyncReply$.AsyncReply.new();
let tupleSize = data._get((t27 = offset, offset = dart.notNull(t27) + 1, t27));
length = dart.notNull(length) - 1;
let types = T$.JSArrayOfType().of([]);
for (let i = 0; i < dart.notNull(tupleSize); i = i + 1) {
let rep = RepresentationType.RepresentationType.parse(data, offset);
if (rep.type != null) types[S$.$add]((t27$ = rep.type.getRuntimeType(), t27$ == null ? dart.wrapType(core.Object) : t27$));
offset = dart.notNull(offset) + dart.notNull(rep.size);
length = dart.notNull(length) - dart.notNull(rep.size);
}
while (dart.notNull(length) > 0) {
let parsed = Codec.Codec.parse(data, offset, connection);
results.add(parsed.reply);
if (dart.notNull(parsed.size) > 0) {
offset = dart.notNull(offset) + dart.notNull(parsed.size);
length = dart.notNull(length) - dart.notNull(parsed.size);
} else
dart.throw(core.Exception.new("Error while parsing structured data"));
}
results.seal();
results.then(core.Null, dart.fn(ar => {
if (ar == null) dart.nullFailed(I[82], 393, 19, "ar");
rt.trigger(new Tuple.Tuple.new(ar));
}, T$.ListToNull()));
return rt;
}
static typedListParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 401, 10, "data");
if (offset == null) dart.nullFailed(I[82], 401, 20, "offset");
if (length == null) dart.nullFailed(I[82], 401, 32, "length");
let rt = new AsyncBag$.AsyncBag.new();
let rep = RepresentationType.RepresentationType.parse(data, offset);
offset = dart.notNull(offset) + dart.notNull(rep.size);
length = dart.notNull(length) - dart.notNull(rep.size);
let runtimeType = rep.type.getRuntimeType();
rt.arrayType = runtimeType;
while (dart.notNull(length) > 0) {
let parsed = Codec.Codec.parse(data, offset, connection);
rt.add(parsed.reply);
if (dart.notNull(parsed.size) > 0) {
offset = dart.notNull(offset) + dart.notNull(parsed.size);
length = dart.notNull(length) - dart.notNull(parsed.size);
} else
dart.throw(core.Exception.new("Error while parsing structured data"));
}
rt.seal();
return rt;
}
static PropertyValueArrayParser(data, offset, length, connection) {
if (data == null) dart.nullFailed(I[82], 431, 10, "data");
if (offset == null) dart.nullFailed(I[82], 432, 11, "offset");
if (length == null) dart.nullFailed(I[82], 433, 11, "length");
let rt = new (T$.AsyncBagOfPropertyValue()).new();
DataDeserializer.DataDeserializer.listParser(data, offset, length, connection).then(core.Null, dart.fn(x => {
if (x == null) dart.nullFailed(I[82], 438, 56, "x");
let pvs = T$.JSArrayOfPropertyValue().of([]);
for (let i = 0; i < dart.notNull(x[S$.$length]); i = i + 3)
pvs[S$.$add](new PropertyValue.PropertyValue.new(x[S$.$_get](2), core.int.as(x[S$.$_get](0)), core.DateTime.as(x[S$.$_get](1))));
rt.trigger(pvs);
}, T$.ListToNull()));
return rt;
}
static propertyValueParser(data, offset, connection) {
if (data == null) dart.nullFailed(I[82], 450, 60, "data");
if (offset == null) dart.nullFailed(I[82], 450, 70, "offset");
let reply = new (T$.AsyncReplyOfPropertyValue()).new();
let age = data.getUint64(offset);
offset = dart.notNull(offset) + 8;
let date = data.getDateTime(offset);
offset = dart.notNull(offset) + 8;
let parsed = Codec.Codec.parse(data, offset, connection);
parsed.reply.then(core.Null, dart.fn(value => {
reply.trigger(new PropertyValue.PropertyValue.new(value, age, date));
}, T$.dynamicToNull()));
return new DataDeserializer.PropertyValueParserResults.new(16 + dart.notNull(parsed.size), reply);
}
static historyParser(data, offset, length, resource, connection) {
if (data == null) dart.nullFailed(I[82], 471, 24, "data");
if (offset == null) dart.nullFailed(I[82], 471, 34, "offset");
if (length == null) dart.nullFailed(I[82], 471, 46, "length");
if (resource == null) dart.nullFailed(I[82], 471, 64, "resource");
dart.throw(core.Exception.new("Not implemented"));
}
static ['_#new#tearOff']() {
return new DataDeserializer.DataDeserializer.new();
}
};
(DataDeserializer.DataDeserializer.new = function() {
;
}).prototype = DataDeserializer.DataDeserializer.prototype;
dart.addTypeTests(DataDeserializer.DataDeserializer);
dart.addTypeCaches(DataDeserializer.DataDeserializer);
dart.setStaticMethodSignature(DataDeserializer.DataDeserializer, () => ['nullParser', 'booleanTrueParser', 'booleanFalseParser', 'notModifiedParser', 'byteParser', 'sByteParser', 'char16Parser', 'char8Parser', 'int16Parser', 'uInt16Parser', 'int32Parser', 'uInt32Parser', 'float32Parser', 'float64Parser', 'float128Parser', 'int128Parser', 'uInt128Parser', 'int64Parser', 'uInt64Parser', 'dateTimeParser', 'resourceParser', 'localResourceParser', 'rawDataParser', 'stringParser', 'recordParser', 'constantParser', 'enumParser', 'recordListParser', 'resourceListParser', 'listParser', 'typedMapParser', 'tupleParser', 'typedListParser', 'PropertyValueArrayParser', 'propertyValueParser', 'historyParser']);
dart.setLibraryUri(DataDeserializer.DataDeserializer, I[82]);
DataSerializer.DataSerializerComposeResults = class DataSerializerComposeResults extends core.Object {
get identifier() {
return this[S$.identifier$2];
}
set identifier(value) {
this[S$.identifier$2] = value;
}
get data() {
return this[S$.data$1];
}
set data(value) {
this[S$.data$1] = value;
}
static ['_#new#tearOff'](identifier, data) {
if (identifier == null) dart.nullFailed(I[83], 24, 37, "identifier");
if (data == null) dart.nullFailed(I[83], 24, 54, "data");
return new DataSerializer.DataSerializerComposeResults.new(identifier, data);
}
};
(DataSerializer.DataSerializerComposeResults.new = function(identifier, data) {
if (identifier == null) dart.nullFailed(I[83], 24, 37, "identifier");
if (data == null) dart.nullFailed(I[83], 24, 54, "data");
this[S$.identifier$2] = identifier;
this[S$.data$1] = data;
;
}).prototype = DataSerializer.DataSerializerComposeResults.prototype;
dart.addTypeTests(DataSerializer.DataSerializerComposeResults);
dart.addTypeCaches(DataSerializer.DataSerializerComposeResults);
dart.setLibraryUri(DataSerializer.DataSerializerComposeResults, I[83]);
dart.setFieldSignature(DataSerializer.DataSerializerComposeResults, () => ({
__proto__: dart.getFields(DataSerializer.DataSerializerComposeResults.__proto__),
identifier: dart.fieldType(core.int),
data: dart.fieldType(DC.DC)
}));
DataSerializer.DataSerializer = class DataSerializer$ extends core.Object {
static historyComposer(history, connection, prependLength = false) {
if (history == null) dart.nullFailed(I[83], 30, 72, "history");
if (connection == null) dart.nullFailed(I[83], 31, 29, "connection");
if (prependLength == null) dart.nullFailed(I[83], 32, 13, "prependLength");
dart.throw(core.Exception.new("Not implemented"));
}
static int32Composer(value, connection) {
let rt = new DC.DC.new(4);
rt.setInt32(0, IntType.Int32.as(value).toInt());
return new DataSerializer.DataSerializerComposeResults.new(24, rt);
}
static uInt32Composer(value, connection) {
let rt = new DC.DC.new(4);
rt.setUint32(0, IntType.UInt32.as(value).toInt());
return new DataSerializer.DataSerializerComposeResults.new(25, rt);
}
static int16Composer(value, connection) {
let rt = new DC.DC.new(2);
rt.setInt16(0, IntType.Int16.as(value).toInt());
return new DataSerializer.DataSerializerComposeResults.new(16, rt);
}
static uInt16Composer(value, connection) {
let rt = new DC.DC.new(2);
rt.setUint16(0, IntType.UInt16.as(value).toInt());
return new DataSerializer.DataSerializerComposeResults.new(17, rt);
}
static float32Composer(value, connection) {
let rt = new DC.DC.new(4);
rt.setFloat32(0, core.double.as(value));
return new DataSerializer.DataSerializerComposeResults.new(26, rt);
}
static float64Composer(value, connection) {
let rt = new DC.DC.new(8);
rt.setFloat64(0, core.double.as(value));
return new DataSerializer.DataSerializerComposeResults.new(34, rt);
}
static int64Composer(value, connection) {
let rt = new DC.DC.new(8);
rt.setInt64(0, core.int.as(value));
return new DataSerializer.DataSerializerComposeResults.new(32, rt);
}
static uInt64Composer(value, connection) {
let rt = new DC.DC.new(8);
rt.setUint64(0, core.int.as(value));
return new DataSerializer.DataSerializerComposeResults.new(33, rt);
}
static dateTimeComposer(value, connection) {
let rt = new DC.DC.new(8);
rt.setDateTime(0, core.DateTime.as(value));
return new DataSerializer.DataSerializerComposeResults.new(35, rt);
}
static float128Composer(value, connection) {
let rt = new DC.DC.new(16);
rt.setFloat64(0, core.double.as(value));
return new DataSerializer.DataSerializerComposeResults.new(34, rt);
}
static stringComposer(value, connection) {
return new DataSerializer.DataSerializerComposeResults.new(65, DC.DC.stringToBytes(core.String.as(value)));
}
static enumComposer(value, connection) {
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let template = Warehouse.Warehouse.getTemplateByType(dart.runtimeType(value));
if (template == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let cts = template.constants[S$.$where](dart.fn(x => {
if (x == null) dart.nullFailed(I[83], 126, 41, "x");
return dart.equals(x.value, value);
}, T$.ConstantTemplateTobool()));
if (dart.test(cts[S$.$isEmpty])) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let rt = new BinaryList.BinaryList.new();
rt.addGuid(template.classId);
rt.addUint8(cts[S$.$first].index);
return new DataSerializer.DataSerializerComposeResults.new(132, rt.toDC());
}
static uInt8Composer(value, connection) {
let rt = new DC.DC.new(1);
rt._set(0, IntType.UInt8.as(value).toInt());
return new DataSerializer.DataSerializerComposeResults.new(8, rt);
}
static int8Composer(value, connection) {
let rt = new DC.DC.new(1);
rt._set(0, IntType.Int8.as(value).toInt());
return new DataSerializer.DataSerializerComposeResults.new(9, rt);
}
static char8Composer(value, connection) {
let rt = new DC.DC.new(1);
rt._set(0, core.int.as(value));
return new DataSerializer.DataSerializerComposeResults.new(10, rt);
}
static char16Composer(value, connection) {
let rt = new DC.DC.new(2);
rt.setUint16(0, core.int.as(value));
return new DataSerializer.DataSerializerComposeResults.new(18, rt);
}
static boolComposer(value, connection) {
return new DataSerializer.DataSerializerComposeResults.new(dart.test(core.bool.as(value)) ? 2 : 1, new DC.DC.new(0));
}
static notModifiedComposer(value, connection) {
return new DataSerializer.DataSerializerComposeResults.new(3, new DC.DC.new(0));
}
static rawDataComposer(value, connection) {
return new DataSerializer.DataSerializerComposeResults.new(64, DC.DC.as(value));
}
static listComposer(value, connection) {
if (value == null)
return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
else
return new DataSerializer.DataSerializerComposeResults.new(66, DataSerializer.DataSerializer.arrayComposer(core.List.as(value), connection));
}
static typedListComposer(value, type, connection) {
let t27, t27$;
if (type == null) dart.nullFailed(I[83], 209, 19, "type");
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let composed = DataSerializer.DataSerializer.arrayComposer(core.List.as(value), connection);
let header = (t27 = RepresentationType.RepresentationType.fromType(type), t27 == null ? RepresentationType.RepresentationType.Dynamic : t27).compose();
let rt = (t27$ = new BinaryList.BinaryList.new(), (() => {
t27$.addDC(header);
t27$.addDC(composed);
return t27$;
})());
return new DataSerializer.DataSerializerComposeResults.new(129, rt.toDC());
}
static propertyValueArrayComposer(value, connection) {
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let rt = new BinaryList.BinaryList.new();
let ar = T$.ListOfPropertyValue().as(value);
for (let pv of ar) {
rt.addDC(Codec.Codec.compose(pv.age, connection));
rt.addDC(Codec.Codec.compose(pv.date, connection));
rt.addDC(Codec.Codec.compose(pv.value, connection));
}
return new DataSerializer.DataSerializerComposeResults.new(66, rt.toDC());
}
static typedMapComposer(value, keyType, valueType, connection) {
let t27, t27$;
if (keyType == null) dart.nullFailed(I[83], 248, 19, "keyType");
if (valueType == null) dart.nullFailed(I[83], 248, 33, "valueType");
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let kt = (t27 = RepresentationType.RepresentationType.fromType(keyType), t27 == null ? RepresentationType.RepresentationType.Dynamic : t27).compose();
let vt = (t27$ = RepresentationType.RepresentationType.fromType(valueType), t27$ == null ? RepresentationType.RepresentationType.Dynamic : t27$).compose();
let rt = new BinaryList.BinaryList.new();
rt.addDC(kt);
rt.addDC(vt);
let map = core.Map.as(value);
for (let el of map[S$.$entries]) {
rt.addDC(Codec.Codec.compose(el.key, connection));
rt.addDC(Codec.Codec.compose(el.value, connection));
}
return new DataSerializer.DataSerializerComposeResults.new(130, rt.toDC());
}
static arrayComposer(value, connection) {
if (value == null) dart.nullFailed(I[83], 276, 32, "value");
let rt = new BinaryList.BinaryList.new();
for (let i of value)
rt.addDC(Codec.Codec.compose(i, connection));
return rt.toDC();
}
static resourceListComposer(value, connection) {
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
return new DataSerializer.DataSerializerComposeResults.new(67, DataSerializer.DataSerializer.arrayComposer(core.List.as(value), connection));
}
static recordListComposer(value, connection) {
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
return new DataSerializer.DataSerializerComposeResults.new(68, DataSerializer.DataSerializer.arrayComposer(core.List.as(value), connection));
}
static resourceComposer(value, connection) {
let t27, t27$, t27$0;
let resource = IResource.IResource.as(value);
let rt = new DC.DC.new(4);
if (dart.test(Codec.Codec.isLocalResource(resource, connection))) {
rt.setUint32(0, (t27 = DistributedResource.DistributedResource.as(resource).id, t27 == null ? 0 : t27));
return new DataSerializer.DataSerializerComposeResults.new(28, rt);
} else {
rt.setUint32(0, (t27$0 = (t27$ = resource.instance, t27$ == null ? null : t27$.id), t27$0 == null ? 0 : t27$0));
return new DataSerializer.DataSerializerComposeResults.new(27, rt);
}
}
static mapComposer(value, connection) {
if (value == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
let rt = new BinaryList.BinaryList.new();
let map = core.Map.as(value);
for (let el of map[S$.$entries]) {
rt.addDC(Codec.Codec.compose(el.key, connection));
rt.addDC(Codec.Codec.compose(el.value, connection));
}
return new DataSerializer.DataSerializerComposeResults.new(69, rt.toDC());
}
static recordComposer(value, connection) {
let rt = new BinaryList.BinaryList.new();
let record = IRecord.IRecord.as(value);
let template = Warehouse.Warehouse.getTemplateByType(dart.runtimeType(record));
if (template == null) return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
rt.addDC(DC.DC.guidToBytes(template.classId));
let recordData = record.serialize();
for (let pt of template.properties) {
let propValue = recordData[S$.$_get](pt.name);
rt.addDC(Codec.Codec.compose(propValue, connection));
}
return new DataSerializer.DataSerializerComposeResults.new(128, rt.toDC());
}
(value, connection) {
if (connection == null) dart.nullFailed(I[83], 381, 36, "connection");
return new DataSerializer.DataSerializerComposeResults.new(0, new DC.DC.new(0));
}
static ['_#new#tearOff']() {
return new DataSerializer.DataSerializer.new();
}
};
(DataSerializer.DataSerializer.new = function() {
;
}).prototype = DataSerializer.DataSerializer.prototype;
dart.addTypeTests(DataSerializer.DataSerializer);
dart.addTypeCaches(DataSerializer.DataSerializer);
dart.setStaticMethodSignature(DataSerializer.DataSerializer, () => ['historyComposer', 'int32Composer', 'uInt32Composer', 'int16Composer', 'uInt16Composer', 'float32Composer', 'float64Composer', 'int64Composer', 'uInt64Composer', 'dateTimeComposer', 'float128Composer', 'stringComposer', 'enumComposer', 'uInt8Composer', 'int8Composer', 'char8Composer', 'char16Composer', 'boolComposer', 'notModifiedComposer', 'rawDataComposer', 'listComposer', 'typedListComposer', 'propertyValueArrayComposer', 'typedMapComposer', 'arrayComposer', 'resourceListComposer', 'recordListComposer', 'resourceComposer', 'mapComposer', 'recordComposer', 'TupleComposer']);
dart.setLibraryUri(DataSerializer.DataSerializer, I[83]);
ResourceArrayType.ResourceArrayType = class ResourceArrayType$ extends core.Object {
static ['_#new#tearOff']() {
return new ResourceArrayType.ResourceArrayType.new();
}
};
(ResourceArrayType.ResourceArrayType.new = function() {
;
}).prototype = ResourceArrayType.ResourceArrayType.prototype;
dart.addTypeTests(ResourceArrayType.ResourceArrayType);
dart.addTypeCaches(ResourceArrayType.ResourceArrayType);
dart.setLibraryUri(ResourceArrayType.ResourceArrayType, I[84]);
dart.setStaticFieldSignature(ResourceArrayType.ResourceArrayType, () => ['Dynamic', 'Static', 'Wrapper']);
dart.defineLazy(ResourceArrayType.ResourceArrayType, {
/*ResourceArrayType.ResourceArrayType.Dynamic*/get Dynamic() {
return 0;
},
/*ResourceArrayType.ResourceArrayType.Static*/get Static() {
return 16;
},
/*ResourceArrayType.ResourceArrayType.Wrapper*/get Wrapper() {
return 32;
}
}, false);
PropertyModificationInfo$.PropertyModificationInfo = class PropertyModificationInfo extends core.Object {
get resource() {
return this[S$.resource$3];
}
set resource(value) {
super.resource = value;
}
get propertyTemplate() {
return this[S$.propertyTemplate$1];
}
set propertyTemplate(value) {
super.propertyTemplate = value;
}
get age() {
return this[S$.age$2];
}
set age(value) {
super.age = value;
}
get value() {
return this[S$.value$9];
}
set value(value) {
super.value = value;
}
get name() {
return this.propertyTemplate.name;
}
static ['_#new#tearOff'](resource, propertyTemplate, value, age) {
if (resource == null) dart.nullFailed(I[85], 13, 12, "resource");
if (propertyTemplate == null) dart.nullFailed(I[85], 13, 27, "propertyTemplate");
if (age == null) dart.nullFailed(I[85], 13, 62, "age");
return new PropertyModificationInfo$.PropertyModificationInfo.new(resource, propertyTemplate, value, age);
}
};
(PropertyModificationInfo$.PropertyModificationInfo.new = function(resource, propertyTemplate, value, age) {
if (resource == null) dart.nullFailed(I[85], 13, 12, "resource");
if (propertyTemplate == null) dart.nullFailed(I[85], 13, 27, "propertyTemplate");
if (age == null) dart.nullFailed(I[85], 13, 62, "age");
this[S$.resource$3] = resource;
this[S$.propertyTemplate$1] = propertyTemplate;
this[S$.value$9] = value;
this[S$.age$2] = age;
}).prototype = PropertyModificationInfo$.PropertyModificationInfo.prototype;
dart.addTypeTests(PropertyModificationInfo$.PropertyModificationInfo);
dart.addTypeCaches(PropertyModificationInfo$.PropertyModificationInfo);
dart.setGetterSignature(PropertyModificationInfo$.PropertyModificationInfo, () => ({
__proto__: dart.getGetters(PropertyModificationInfo$.PropertyModificationInfo.__proto__),
name: core.String
}));
dart.setLibraryUri(PropertyModificationInfo$.PropertyModificationInfo, I[85]);
dart.setFieldSignature(PropertyModificationInfo$.PropertyModificationInfo, () => ({
__proto__: dart.getFields(PropertyModificationInfo$.PropertyModificationInfo.__proto__),
resource: dart.finalFieldType(IResource.IResource),
propertyTemplate: dart.finalFieldType(PropertyTemplate.PropertyTemplate),
age: dart.finalFieldType(core.int),
value: dart.finalFieldType(dart.dynamic)
}));
WSocket.WSocket = class WSocket$ extends ISocket.ISocket {
get receiveNetworkBuffer() {
return this[S$.receiveNetworkBuffer$1];
}
set receiveNetworkBuffer(value) {
this[S$.receiveNetworkBuffer$1] = value;
}
get began() {
return this[S$.began$1];
}
set began(value) {
this[S$.began$1] = value;
}
get secure() {
return this[S$.secure];
}
set secure(value) {
this[S$.secure] = value;
}
begin() {
let t27;
if (dart.test(this.began)) return false;
this.began = true;
if (this[S$._channel] != null) {
this[S$._localEP$1] = new IPEndPoint.IPEndPoint.new(T$.JSArrayOfint().of([0, 0, 0, 0]), 0);
this[S$._remoteEP$1] = new IPEndPoint.IPEndPoint.new(T$.JSArrayOfint().of([0, 0, 0, 0]), 0);
t27 = this[S$._channel];
t27 == null ? null : t27.stream.listen(dart.bind(this, S$._dataHandler), {onError: dart.bind(this, 'errorHandler'), onDone: dart.bind(this, 'doneHandler')});
}
return true;
}
[S$._dataHandler](data) {
let t27;
try {
if (this[S$._state$2] == SocketState.SocketState.Closed || this[S$._state$2] == SocketState.SocketState.Terminated) return;
let dc = new DC.DC.fromList(T$.ListOfint().as(data));
this.receiveNetworkBuffer.write(dc, 0, dc.length);
t27 = this.receiver;
t27 == null ? null : t27.networkReceive(this, this.receiveNetworkBuffer);
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
if (this[S$._state$2] != SocketState.SocketState.Closed) {
this[S$._state$2] = SocketState.SocketState.Terminated;
this.close();
}
} else
throw e;
}
}
errorHandler(error, trace) {
if (trace == null) dart.nullFailed(I[86], 86, 39, "trace");
core.print(error);
this.close();
}
doneHandler() {
this.close();
}
connect(hostname, port) {
let t28;
if (hostname == null) dart.nullFailed(I[86], 96, 35, "hostname");
if (port == null) dart.nullFailed(I[86], 96, 49, "port");
let rt = new (T$.AsyncReplyOfbool()).new();
try {
this[S$._state$2] = SocketState.SocketState.Connecting;
this[S$._channel] = channel$.WebSocketChannel.connect(core.Uri.parse((dart.test(this.secure) ? "wss" : "ws") + "://" + dart.str(hostname) + ":" + dart.str(port)));
this[S$._state$2] = SocketState.SocketState.Established;
this.begin();
t28 = this.receiver;
t28 == null ? null : t28.networkConnect(this);
rt.trigger(true);
} catch (e) {
let ex = dart.getThrown(e);
if (core.Object.is(ex)) {
rt.triggerError(new AsyncException.AsyncException.new(ErrorType.ErrorType.Management, ExceptionCode.ExceptionCode.HostNotReachable.index, dart.toString(ex)));
} else
throw e;
}
return rt;
}
get localEndPoint() {
return this[S$._localEP$1];
}
set localEndPoint(value) {
super.localEndPoint = value;
}
get remoteEndPoint() {
return this[S$._remoteEP$1];
}
set remoteEndPoint(value) {
super.remoteEndPoint = value;
}
get state() {
return this[S$._state$2];
}
TCPSocket() {
}
close() {
let t29, t29$;
if (this.state != SocketState.SocketState.Closed && this.state != SocketState.SocketState.Terminated) this[S$._state$2] = SocketState.SocketState.Closed;
t29 = this[S$._channel];
t29 == null ? null : t29.sink.close();
t29$ = this.receiver;
t29$ == null ? null : t29$.networkClose(this);
}
send(message, offset = null, size = null) {
let t29, t29$, t29$0;
if (message == null) dart.nullFailed(I[86], 136, 16, "message");
if (this.state == SocketState.SocketState.Established) {
if (offset != null && size == null) {
t29 = this[S$._channel];
t29 == null ? null : t29.sink.add(message.clip(offset, dart.notNull(message.length) - dart.notNull(offset)).toArray());
} else if (offset != null && size != null) {
t29$ = this[S$._channel];
t29$ == null ? null : t29$.sink.add(message.clip(offset, size).toArray());
} else {
t29$0 = this[S$._channel];
t29$0 == null ? null : t29$0.sink.add(message.toArray());
}
}
}
destroy() {
this.close();
this.emitArgs("destroy", [this]);
}
accept() {
let reply = new (T$.AsyncReplyOfISocket()).new();
return reply;
}
static ['_#new#tearOff']() {
return new WSocket.WSocket.new();
}
};
(WSocket.WSocket.new = function() {
this[S$._channel] = null;
this[S$.receiveNetworkBuffer$1] = new NetworkBuffer.NetworkBuffer.new();
this[S$.began$1] = false;
this[S$.secure] = false;
this[S$._state$2] = SocketState.SocketState.Initial;
this[S$._localEP$1] = null;
this[S$._remoteEP$1] = null;
WSocket.WSocket.__proto__.new.call(this);
;
}).prototype = WSocket.WSocket.prototype;
dart.addTypeTests(WSocket.WSocket);
dart.addTypeCaches(WSocket.WSocket);
dart.setMethodSignature(WSocket.WSocket, () => ({
__proto__: dart.getMethods(WSocket.WSocket.__proto__),
begin: dart.fnType(core.bool, []),
[S$._dataHandler]: dart.fnType(dart.void, [dart.dynamic]),
errorHandler: dart.fnType(dart.void, [dart.dynamic, core.StackTrace]),
doneHandler: dart.fnType(dart.void, []),
connect: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [core.String, core.int]),
TCPSocket: dart.fnType(dart.dynamic, []),
close: dart.fnType(dart.void, []),
send: dart.fnType(dart.void, [DC.DC], [dart.nullable(core.int), dart.nullable(core.int)]),
destroy: dart.fnType(dart.void, []),
accept: dart.fnType(AsyncReply$.AsyncReply$(ISocket.ISocket), [])
}));
dart.setGetterSignature(WSocket.WSocket, () => ({
__proto__: dart.getGetters(WSocket.WSocket.__proto__),
localEndPoint: dart.nullable(IPEndPoint.IPEndPoint),
remoteEndPoint: dart.nullable(IPEndPoint.IPEndPoint),
state: SocketState.SocketState
}));
dart.setLibraryUri(WSocket.WSocket, I[86]);
dart.setFieldSignature(WSocket.WSocket, () => ({
__proto__: dart.getFields(WSocket.WSocket.__proto__),
[S$._channel]: dart.fieldType(dart.nullable(channel$.WebSocketChannel)),
receiveNetworkBuffer: dart.fieldType(NetworkBuffer.NetworkBuffer),
began: dart.fieldType(core.bool),
secure: dart.fieldType(core.bool),
[S$._state$2]: dart.fieldType(SocketState.SocketState),
[S$._localEP$1]: dart.fieldType(dart.nullable(IPEndPoint.IPEndPoint)),
[S$._remoteEP$1]: dart.fieldType(dart.nullable(IPEndPoint.IPEndPoint))
}));
DistributedServer.DistributedServer = class DistributedServer$ extends IResource.IResource {
get entryPoint() {
return this[S$.entryPoint];
}
set entryPoint(value) {
this[S$.entryPoint] = value;
}
destroy() {
this.emitArgs("destroy", []);
}
trigger(trigger) {
if (trigger == null) dart.nullFailed(I[87], 16, 44, "trigger");
return new (T$.AsyncReplyOfbool()).ready(true);
}
getProperty(name) {
if (name == null) dart.nullFailed(I[87], 23, 22, "name");
return null;
}
invoke(name, $arguments) {
if (name == null) dart.nullFailed(I[87], 26, 17, "name");
if ($arguments == null) dart.nullFailed(I[87], 26, 28, "arguments");
return null;
}
setProperty(name, value) {
if (name == null) dart.nullFailed(I[87], 29, 22, "name");
return true;
}
get template() {
return new TemplateDescriber.TemplateDescriber.new("Esiur.Net.IIP.DistributedServer");
}
static ['_#new#tearOff']() {
return new DistributedServer.DistributedServer.new();
}
};
(DistributedServer.DistributedServer.new = function() {
this[S$.entryPoint] = null;
DistributedServer.DistributedServer.__proto__.new.call(this);
;
}).prototype = DistributedServer.DistributedServer.prototype;
dart.addTypeTests(DistributedServer.DistributedServer);
dart.addTypeCaches(DistributedServer.DistributedServer);
dart.setMethodSignature(DistributedServer.DistributedServer, () => ({
__proto__: dart.getMethods(DistributedServer.DistributedServer.__proto__),
destroy: dart.fnType(dart.void, []),
trigger: dart.fnType(AsyncReply$.AsyncReply$(core.bool), [ResourceTrigger.ResourceTrigger]),
getProperty: dart.fnType(dart.dynamic, [core.String]),
invoke: dart.fnType(dart.dynamic, [core.String, core.List]),
setProperty: dart.fnType(dart.dynamic, [core.String, dart.dynamic])
}));
dart.setGetterSignature(DistributedServer.DistributedServer, () => ({
__proto__: dart.getGetters(DistributedServer.DistributedServer.__proto__),
template: TemplateDescriber.TemplateDescriber
}));
dart.setLibraryUri(DistributedServer.DistributedServer, I[87]);
dart.setFieldSignature(DistributedServer.DistributedServer, () => ({
__proto__: dart.getFields(DistributedServer.DistributedServer.__proto__),
entryPoint: dart.fieldType(dart.nullable(EntryPoint.EntryPoint))
}));
const _is_KeyValuePair_default = Symbol('_is_KeyValuePair_default');
KeyValuePair$.KeyValuePair$ = dart.generic((K, V) => {
class KeyValuePair extends core.Object {
get key() {
return this[S$.key];
}
set key(value) {
this[S$.key] = K.as(value);
}
get value() {
return this[S$.value$10];
}
set value(value) {
this[S$.value$10] = V.as(value);
}
static ['_#new#tearOff'](K, V, key, value) {
return new (KeyValuePair$.KeyValuePair$(K, V)).new(key, value);
}
}
(KeyValuePair.new = function(key, value) {
this[S$.key] = key;
this[S$.value$10] = value;
;
}).prototype = KeyValuePair.prototype;
dart.addTypeTests(KeyValuePair);
KeyValuePair.prototype[_is_KeyValuePair_default] = true;
dart.addTypeCaches(KeyValuePair);
dart.setLibraryUri(KeyValuePair, I[88]);
dart.setFieldSignature(KeyValuePair, () => ({
__proto__: dart.getFields(KeyValuePair.__proto__),
key: dart.fieldType(K),
value: dart.fieldType(V)
}));
return KeyValuePair;
});
KeyValuePair$.KeyValuePair = KeyValuePair$.KeyValuePair$();
dart.addTypeTests(KeyValuePair$.KeyValuePair, _is_KeyValuePair_default);
const _is_ParseResult_default = Symbol('_is_ParseResult_default');
ParseResult$.ParseResult$ = dart.generic(T => {
class ParseResult extends core.Object {
get size() {
return this[S$.size$5];
}
set size(value) {
this[S$.size$5] = value;
}
get value() {
return this[S$.value$11];
}
set value(value) {
this[S$.value$11] = T.as(value);
}
static ['_#new#tearOff'](T, size, value) {
if (size == null) dart.nullFailed(I[89], 5, 20, "size");
return new (ParseResult$.ParseResult$(T)).new(size, value);
}
}
(ParseResult.new = function(size, value) {
if (size == null) dart.nullFailed(I[89], 5, 20, "size");
this[S$.size$5] = size;
this[S$.value$11] = value;
;
}).prototype = ParseResult.prototype;
dart.addTypeTests(ParseResult);
ParseResult.prototype[_is_ParseResult_default] = true;
dart.addTypeCaches(ParseResult);
dart.setLibraryUri(ParseResult, I[89]);
dart.setFieldSignature(ParseResult, () => ({
__proto__: dart.getFields(ParseResult.__proto__),
size: dart.fieldType(core.int),
value: dart.fieldType(T)
}));
return ParseResult;
});
ParseResult$.ParseResult = ParseResult$.ParseResult$();
dart.addTypeTests(ParseResult$.ParseResult, _is_ParseResult_default);
algorithms.binarySearch = function binarySearch(E, sortedList, value, opts) {
if (sortedList == null) dart.nullFailed(I[90], 21, 29, "sortedList");
let compare = opts && 'compare' in opts ? opts.compare : null;
compare == null ? compare = C[173] || CT.C173 : null;
return algorithms.binarySearchBy(E, E, sortedList, dart.gbind(C[174] || CT.C174, E), compare, value);
};
algorithms.binarySearchBy = function binarySearchBy(E, K, sortedList, keyOf, compare, value, start = 0, end = null) {
if (sortedList == null) dart.nullFailed(I[90], 36, 34, "sortedList");
if (keyOf == null) dart.nullFailed(I[90], 36, 68, "keyOf");
if (compare == null) dart.nullFailed(I[90], 37, 24, "compare");
if (start == null) dart.nullFailed(I[90], 38, 10, "start");
end = core.RangeError.checkValidRange(start, end, sortedList[S$.$length]);
let min = start;
let max = end;
let key = keyOf(value);
while (dart.notNull(min) < dart.notNull(max)) {
let mid = dart.notNull(min) + (dart.notNull(max) - dart.notNull(min))[S$.$rightShift](1);
let element = sortedList[S$.$_get](mid);
let comp = compare(keyOf(element), key);
if (comp === 0) return mid;
if (dart.notNull(comp) < 0) {
min = mid + 1;
} else {
max = mid;
}
}
return -1;
};
algorithms.lowerBound = function lowerBound(E, sortedList, value, opts) {
if (sortedList == null) dart.nullFailed(I[90], 68, 27, "sortedList");
let compare = opts && 'compare' in opts ? opts.compare : null;
compare == null ? compare = C[173] || CT.C173 : null;
return algorithms.lowerBoundBy(E, E, sortedList, dart.gbind(C[174] || CT.C174, E), compare, value);
};
algorithms.lowerBoundBy = function lowerBoundBy(E, K, sortedList, keyOf, compare, value, start = 0, end = null) {
if (sortedList == null) dart.nullFailed(I[90], 83, 32, "sortedList");
if (keyOf == null) dart.nullFailed(I[90], 83, 66, "keyOf");
if (compare == null) dart.nullFailed(I[90], 84, 24, "compare");
if (start == null) dart.nullFailed(I[90], 85, 10, "start");
end = core.RangeError.checkValidRange(start, end, sortedList[S$.$length]);
let min = start;
let max = end;
let key = keyOf(value);
while (dart.notNull(min) < dart.notNull(max)) {
let mid = dart.notNull(min) + (dart.notNull(max) - dart.notNull(min))[S$.$rightShift](1);
let element = sortedList[S$.$_get](mid);
let comp = compare(keyOf(element), key);
if (dart.notNull(comp) < 0) {
min = mid + 1;
} else {
max = mid;
}
}
return min;
};
algorithms.shuffle = function shuffle(elements, start = 0, end = null, random = null) {
if (elements == null) dart.nullFailed(I[90], 111, 19, "elements");
if (start == null) dart.nullFailed(I[90], 111, 34, "start");
random == null ? random = math.Random.new() : null;
end == null ? end = elements[S$.$length] : null;
let length = dart.notNull(end) - dart.notNull(start);
while (length > 1) {
let pos = random.nextInt(length);
length = length - 1;
let tmp1 = elements[S$.$_get](dart.notNull(start) + dart.notNull(pos));
elements[S$.$_set](dart.notNull(start) + dart.notNull(pos), elements[S$.$_get](dart.notNull(start) + length));
elements[S$.$_set](dart.notNull(start) + length, tmp1);
}
};
algorithms.reverse = function reverse(E, elements, start = 0, end = null) {
if (elements == null) dart.nullFailed(I[90], 125, 25, "elements");
if (start == null) dart.nullFailed(I[90], 125, 40, "start");
end = core.RangeError.checkValidRange(start, end, elements[S$.$length]);
algorithms._reverse(E, elements, start, end);
};
algorithms._reverse = function _reverse(E, elements, start, end) {
if (elements == null) dart.nullFailed(I[90], 131, 26, "elements");
if (start == null) dart.nullFailed(I[90], 131, 40, "start");
if (end == null) dart.nullFailed(I[90], 131, 51, "end");
for (let i = start, j = dart.notNull(end) - 1; dart.notNull(i) < j; i = dart.notNull(i) + 1, j = j - 1) {
let tmp = elements[S$.$_get](i);
elements[S$.$_set](i, elements[S$.$_get](j));
elements[S$.$_set](j, tmp);
}
};
algorithms.insertionSort = function insertionSort(E, elements, opts) {
if (elements == null) dart.nullFailed(I[90], 154, 31, "elements");
let compare = opts && 'compare' in opts ? opts.compare : null;
let start = opts && 'start' in opts ? opts.start : 0;
if (start == null) dart.nullFailed(I[90], 155, 39, "start");
let end = opts && 'end' in opts ? opts.end : null;
compare == null ? compare = C[173] || CT.C173 : null;
end == null ? end = elements[S$.$length] : null;
for (let pos = dart.notNull(start) + 1; pos < dart.notNull(end); pos = pos + 1) {
let min = start;
let max = pos;
let element = elements[S$.$_get](pos);
while (dart.notNull(min) < max) {
let mid = dart.notNull(min) + (max - dart.notNull(min))[S$.$rightShift](1);
let comparison = compare(element, elements[S$.$_get](mid));
if (dart.notNull(comparison) < 0) {
max = mid;
} else {
min = mid + 1;
}
}
elements[S$.$setRange](dart.notNull(min) + 1, pos + 1, elements, min);
elements[S$.$_set](min, element);
}
};
algorithms.insertionSortBy = function insertionSortBy(E, K, elements, keyOf, compare, start = 0, end = null) {
if (elements == null) dart.nullFailed(I[90], 183, 36, "elements");
if (keyOf == null) dart.nullFailed(I[90], 183, 68, "keyOf");
if (compare == null) dart.nullFailed(I[90], 184, 28, "compare");
if (start == null) dart.nullFailed(I[90], 185, 10, "start");
end = core.RangeError.checkValidRange(start, end, elements[S$.$length]);
algorithms._movingInsertionSort(E, K, elements, keyOf, compare, start, end, elements, start);
};
algorithms.mergeSort = function mergeSort(E, elements, opts) {
if (elements == null) dart.nullFailed(I[90], 208, 27, "elements");
let start = opts && 'start' in opts ? opts.start : 0;
if (start == null) dart.nullFailed(I[90], 209, 10, "start");
let end = opts && 'end' in opts ? opts.end : null;
let compare = opts && 'compare' in opts ? opts.compare : null;
end = core.RangeError.checkValidRange(start, end, elements[S$.$length]);
compare == null ? compare = C[173] || CT.C173 : null;
let length = dart.notNull(end) - dart.notNull(start);
if (length < 2) return;
if (length < 32) {
algorithms.insertionSort(E, elements, {compare: compare, start: start, end: end});
return;
}
let firstLength = (dart.notNull(end) - dart.notNull(start))[S$.$rightShift](1);
let middle = dart.notNull(start) + firstLength;
let secondLength = dart.notNull(end) - middle;
let scratchSpace = core.List$(E).filled(secondLength, elements[S$.$_get](start));
let id = dart.gbind(C[174] || CT.C174, E);
algorithms._mergeSort(E, E, elements, id, compare, middle, end, scratchSpace, 0);
let firstTarget = dart.notNull(end) - firstLength;
algorithms._mergeSort(E, E, elements, id, compare, start, middle, elements, firstTarget);
algorithms._merge(E, E, id, compare, elements, firstTarget, end, scratchSpace, 0, secondLength, elements, start);
};
algorithms.mergeSortBy = function mergeSortBy(E, K, elements, keyOf, compare, start = 0, end = null) {
if (elements == null) dart.nullFailed(I[90], 247, 32, "elements");
if (keyOf == null) dart.nullFailed(I[90], 247, 64, "keyOf");
if (compare == null) dart.nullFailed(I[90], 248, 28, "compare");
if (start == null) dart.nullFailed(I[90], 249, 10, "start");
end = core.RangeError.checkValidRange(start, end, elements[S$.$length]);
let length = dart.notNull(end) - dart.notNull(start);
if (length < 2) return;
if (length < 32) {
algorithms._movingInsertionSort(E, K, elements, keyOf, compare, start, end, elements, start);
return;
}
let middle = dart.notNull(start) + length[S$.$rightShift](1);
let firstLength = middle - dart.notNull(start);
let secondLength = dart.notNull(end) - middle;
let scratchSpace = core.List$(E).filled(secondLength, elements[S$.$_get](start));
algorithms._mergeSort(E, K, elements, keyOf, compare, middle, end, scratchSpace, 0);
let firstTarget = dart.notNull(end) - firstLength;
algorithms._mergeSort(E, K, elements, keyOf, compare, start, middle, elements, firstTarget);
algorithms._merge(E, K, keyOf, compare, elements, firstTarget, end, scratchSpace, 0, secondLength, elements, start);
};
algorithms._movingInsertionSort = function _movingInsertionSort(E, K, list, keyOf, compare, start, end, target, targetOffset) {
if (list == null) dart.nullFailed(I[90], 280, 13, "list");
if (keyOf == null) dart.nullFailed(I[90], 281, 27, "keyOf");
if (compare == null) dart.nullFailed(I[90], 282, 24, "compare");
if (start == null) dart.nullFailed(I[90], 283, 9, "start");
if (end == null) dart.nullFailed(I[90], 284, 9, "end");
if (target == null) dart.nullFailed(I[90], 285, 13, "target");
if (targetOffset == null) dart.nullFailed(I[90], 286, 9, "targetOffset");
let length = dart.notNull(end) - dart.notNull(start);
if (length === 0) return;
target[S$.$_set](targetOffset, list[S$.$_get](start));
for (let i = 1; i < length; i = i + 1) {
let element = list[S$.$_get](dart.notNull(start) + i);
let elementKey = keyOf(element);
let min = targetOffset;
let max = dart.notNull(targetOffset) + i;
while (dart.notNull(min) < max) {
let mid = dart.notNull(min) + (max - dart.notNull(min))[S$.$rightShift](1);
if (dart.notNull(compare(elementKey, keyOf(target[S$.$_get](mid)))) < 0) {
max = mid;
} else {
min = mid + 1;
}
}
target[S$.$setRange](dart.notNull(min) + 1, dart.notNull(targetOffset) + i + 1, target, min);
target[S$.$_set](min, element);
}
};
algorithms._mergeSort = function _mergeSort(E, K, elements, keyOf, compare, start, end, target, targetOffset) {
if (elements == null) dart.nullFailed(I[90], 316, 13, "elements");
if (keyOf == null) dart.nullFailed(I[90], 317, 27, "keyOf");
if (compare == null) dart.nullFailed(I[90], 318, 24, "compare");
if (start == null) dart.nullFailed(I[90], 319, 9, "start");
if (end == null) dart.nullFailed(I[90], 320, 9, "end");
if (target == null) dart.nullFailed(I[90], 321, 13, "target");
if (targetOffset == null) dart.nullFailed(I[90], 322, 9, "targetOffset");
let length = dart.notNull(end) - dart.notNull(start);
if (length < 32) {
algorithms._movingInsertionSort(E, K, elements, keyOf, compare, start, end, target, targetOffset);
return;
}
let middle = dart.notNull(start) + length[S$.$rightShift](1);
let firstLength = middle - dart.notNull(start);
let secondLength = dart.notNull(end) - middle;
let targetMiddle = dart.notNull(targetOffset) + firstLength;
algorithms._mergeSort(E, K, elements, keyOf, compare, middle, end, target, targetMiddle);
algorithms._mergeSort(E, K, elements, keyOf, compare, start, middle, elements, middle);
algorithms._merge(E, K, keyOf, compare, elements, middle, middle + firstLength, target, targetMiddle, targetMiddle + secondLength, target, targetOffset);
};
algorithms._merge = function _merge(E, K, keyOf, compare, firstList, firstStart, firstEnd, secondList, secondStart, secondEnd, target, targetOffset) {
let t29, t29$, t29$0, t29$1, t29$2, t29$3, t29$4, t29$5;
if (keyOf == null) dart.nullFailed(I[90], 352, 27, "keyOf");
if (compare == null) dart.nullFailed(I[90], 353, 24, "compare");
if (firstList == null) dart.nullFailed(I[90], 354, 13, "firstList");
if (firstStart == null) dart.nullFailed(I[90], 355, 9, "firstStart");
if (firstEnd == null) dart.nullFailed(I[90], 356, 9, "firstEnd");
if (secondList == null) dart.nullFailed(I[90], 357, 13, "secondList");
if (secondStart == null) dart.nullFailed(I[90], 358, 9, "secondStart");
if (secondEnd == null) dart.nullFailed(I[90], 359, 9, "secondEnd");
if (target == null) dart.nullFailed(I[90], 360, 13, "target");
if (targetOffset == null) dart.nullFailed(I[90], 361, 9, "targetOffset");
if (!(dart.notNull(firstStart) < dart.notNull(firstEnd))) dart.assertFailed(null, I[90], 363, 10, "firstStart < firstEnd");
if (!(dart.notNull(secondStart) < dart.notNull(secondEnd))) dart.assertFailed(null, I[90], 364, 10, "secondStart < secondEnd");
let cursor1 = firstStart;
let cursor2 = secondStart;
let firstElement = firstList[S$.$_get]((t29 = cursor1, cursor1 = dart.notNull(t29) + 1, t29));
let firstKey = keyOf(firstElement);
let secondElement = secondList[S$.$_get]((t29$ = cursor2, cursor2 = dart.notNull(t29$) + 1, t29$));
let secondKey = keyOf(secondElement);
while (true) {
if (dart.notNull(compare(firstKey, secondKey)) <= 0) {
target[S$.$_set]((t29$0 = targetOffset, targetOffset = dart.notNull(t29$0) + 1, t29$0), firstElement);
if (cursor1 == firstEnd) break;
firstElement = firstList[S$.$_get]((t29$1 = cursor1, cursor1 = dart.notNull(t29$1) + 1, t29$1));
firstKey = keyOf(firstElement);
} else {
target[S$.$_set]((t29$2 = targetOffset, targetOffset = dart.notNull(t29$2) + 1, t29$2), secondElement);
if (cursor2 != secondEnd) {
secondElement = secondList[S$.$_get]((t29$3 = cursor2, cursor2 = dart.notNull(t29$3) + 1, t29$3));
secondKey = keyOf(secondElement);
continue;
}
target[S$.$_set]((t29$4 = targetOffset, targetOffset = dart.notNull(t29$4) + 1, t29$4), firstElement);
target[S$.$setRange](targetOffset, dart.notNull(targetOffset) + (dart.notNull(firstEnd) - dart.notNull(cursor1)), firstList, cursor1);
return;
}
}
target[S$.$_set]((t29$5 = targetOffset, targetOffset = dart.notNull(t29$5) + 1, t29$5), secondElement);
target[S$.$setRange](targetOffset, dart.notNull(targetOffset) + (dart.notNull(secondEnd) - dart.notNull(cursor2)), secondList, cursor2);
};
algorithms.quickSort = function quickSort(E, elements, compare, start = 0, end = null) {
if (elements == null) dart.nullFailed(I[90], 403, 27, "elements");
if (compare == null) dart.nullFailed(I[90], 403, 60, "compare");
if (start == null) dart.nullFailed(I[90], 404, 10, "start");
end = core.RangeError.checkValidRange(start, end, elements[S$.$length]);
algorithms._quickSort(E, E, elements, dart.gbind(C[174] || CT.C174, E), compare, math.Random.new(), start, end);
};
algorithms.quickSortBy = function quickSortBy(E, K, list, keyOf, compare, start = 0, end = null) {
if (list == null) dart.nullFailed(I[90], 417, 13, "list");
if (keyOf == null) dart.nullFailed(I[90], 417, 41, "keyOf");
if (compare == null) dart.nullFailed(I[90], 417, 71, "compare");
if (start == null) dart.nullFailed(I[90], 418, 10, "start");
end = core.RangeError.checkValidRange(start, end, list[S$.$length]);
algorithms._quickSort(E, K, list, keyOf, compare, math.Random.new(), start, end);
};
algorithms._quickSort = function _quickSort(E, K, list, keyOf, compare, random, start, end) {
if (list == null) dart.nullFailed(I[90], 423, 31, "list");
if (keyOf == null) dart.nullFailed(I[90], 423, 59, "keyOf");
if (compare == null) dart.nullFailed(I[90], 424, 28, "compare");
if (random == null) dart.nullFailed(I[90], 424, 44, "random");
if (start == null) dart.nullFailed(I[90], 424, 56, "start");
if (end == null) dart.nullFailed(I[90], 424, 67, "end");
let length = dart.notNull(end) - dart.notNull(start);
while (length >= 24) {
let pivotIndex = dart.notNull(random.nextInt(length)) + dart.notNull(start);
let pivot = list[S$.$_get](pivotIndex);
let pivotKey = keyOf(pivot);
let endSmaller = start;
let startGreater = end;
let startPivots = dart.notNull(end) - 1;
list[S$.$_set](pivotIndex, list[S$.$_get](startPivots));
list[S$.$_set](startPivots, pivot);
while (dart.notNull(endSmaller) < startPivots) {
let current = list[S$.$_get](endSmaller);
let relation = compare(keyOf(current), pivotKey);
if (dart.notNull(relation) < 0) {
endSmaller = dart.notNull(endSmaller) + 1;
} else {
startPivots = startPivots - 1;
let currentTarget = startPivots;
list[S$.$_set](endSmaller, list[S$.$_get](startPivots));
if (dart.notNull(relation) > 0) {
startGreater = dart.notNull(startGreater) - 1;
currentTarget = startGreater;
list[S$.$_set](startPivots, list[S$.$_get](startGreater));
}
list[S$.$_set](currentTarget, current);
}
}
if (dart.notNull(endSmaller) - dart.notNull(start) < dart.notNull(end) - dart.notNull(startGreater)) {
algorithms._quickSort(E, K, list, keyOf, compare, random, start, endSmaller);
start = startGreater;
} else {
algorithms._quickSort(E, K, list, keyOf, compare, random, startGreater, end);
end = endSmaller;
}
length = dart.notNull(end) - dart.notNull(start);
}
algorithms._movingInsertionSort(E, K, list, keyOf, compare, start, end, list, start);
};
dart.defineLazy(algorithms, {
/*algorithms._mergeSortLimit*/get _mergeSortLimit() {
return 32;
}
}, false);
const _is_CanonicalizedMap_default = Symbol('_is_CanonicalizedMap_default');
canonicalized_map.CanonicalizedMap$ = dart.generic((C, K, V) => {
var __t$LinkedMapOfC$MapEntryOfK$V = () => (__t$LinkedMapOfC$MapEntryOfK$V = dart.constFn(_js_helper.LinkedMap$(C, __t$MapEntryOfK$V())))();
var __t$MapEntryOfC$MapEntryOfK$V = () => (__t$MapEntryOfC$MapEntryOfK$V = dart.constFn(core.MapEntry$(C, __t$MapEntryOfK$V())))();
var __t$MapEntryOfK$VToMapEntryOfC$MapEntryOfK$V = () => (__t$MapEntryOfK$VToMapEntryOfC$MapEntryOfK$V = dart.constFn(dart.fnType(__t$MapEntryOfC$MapEntryOfK$V(), [__t$MapEntryOfK$V()])))();
var __t$MapEntryOfC$MapEntryOfK$VToMapEntryOfK$V = () => (__t$MapEntryOfC$MapEntryOfK$VToMapEntryOfK$V = dart.constFn(dart.fnType(__t$MapEntryOfK$V(), [__t$MapEntryOfC$MapEntryOfK$V()])))();
var __t$CAndMapEntryOfK$VTovoid = () => (__t$CAndMapEntryOfK$VTovoid = dart.constFn(dart.fnType(dart.void, [C, __t$MapEntryOfK$V()])))();
var __t$CAndMapEntryOfK$VTobool = () => (__t$CAndMapEntryOfK$VTobool = dart.constFn(dart.fnType(core.bool, [C, __t$MapEntryOfK$V()])))();
var __t$CAndMapEntryOfK$VToMapEntryOfK$V = () => (__t$CAndMapEntryOfK$VToMapEntryOfK$V = dart.constFn(dart.fnType(__t$MapEntryOfK$V(), [C, __t$MapEntryOfK$V()])))();
var __t$MapEntryOfK$V = () => (__t$MapEntryOfK$V = dart.constFn(core.MapEntry$(K, V)))();
var __t$MapOfK$V = () => (__t$MapOfK$V = dart.constFn(core.Map$(K, V)))();
var __t$KAndVTovoid = () => (__t$KAndVTovoid = dart.constFn(dart.fnType(dart.void, [K, V])))();
var __t$IterableOfMapEntryOfK$V = () => (__t$IterableOfMapEntryOfK$V = dart.constFn(core.Iterable$(__t$MapEntryOfK$V())))();
var __t$MapEntryOfK$VTobool = () => (__t$MapEntryOfK$VTobool = dart.constFn(dart.fnType(core.bool, [__t$MapEntryOfK$V()])))();
var __t$MapEntryOfK$VToK = () => (__t$MapEntryOfK$VToK = dart.constFn(dart.fnType(K, [__t$MapEntryOfK$V()])))();
var __t$VoidToMapEntryOfK$V = () => (__t$VoidToMapEntryOfK$V = dart.constFn(dart.fnType(__t$MapEntryOfK$V(), [])))();
var __t$MapEntryOfK$VToMapEntryOfK$V = () => (__t$MapEntryOfK$VToMapEntryOfK$V = dart.constFn(dart.fnType(__t$MapEntryOfK$V(), [__t$MapEntryOfK$V()])))();
var __t$KAndVToV = () => (__t$KAndVToV = dart.constFn(dart.fnType(V, [K, V])))();
var __t$MapEntryOfK$VToV = () => (__t$MapEntryOfK$VToV = dart.constFn(dart.fnType(V, [__t$MapEntryOfK$V()])))();
var __t$VoidToV = () => (__t$VoidToV = dart.constFn(dart.fnType(V, [])))();
var __t$VToV = () => (__t$VToV = dart.constFn(dart.fnType(V, [V])))();
var __t$VoidToNV = () => (__t$VoidToNV = dart.constFn(dart.nullable(__t$VoidToV())))();
class CanonicalizedMap extends core.Object {
static ['_#new#tearOff'](C, K, V, canonicalize, opts) {
if (canonicalize == null) dart.nullFailed(I[91], 28, 38, "canonicalize");
let isValidKey = opts && 'isValidKey' in opts ? opts.isValidKey : null;
return new (canonicalized_map.CanonicalizedMap$(C, K, V)).new(canonicalize, {isValidKey: isValidKey});
}
static ['_#from#tearOff'](C, K, V, other, canonicalize, opts) {
if (other == null) dart.nullFailed(I[91], 42, 35, "other");
if (canonicalize == null) dart.nullFailed(I[91], 42, 60, "canonicalize");
let isValidKey = opts && 'isValidKey' in opts ? opts.isValidKey : null;
return new (canonicalized_map.CanonicalizedMap$(C, K, V)).from(other, canonicalize, {isValidKey: isValidKey});
}
_get(key) {
let t29;
if (!dart.test(this[S$._isValidKey](key))) return null;
let pair = this[S$._base][S$.$_get]((t29 = K.as(key), this[S$._canonicalize](t29)));
return pair == null ? null : pair.value;
}
_set(key, value$) {
let value = value$;
let t29;
K.as(key);
V.as(value);
if (!dart.test(this[S$._isValidKey](key))) return value$;
this[S$._base][S$.$_set]((t29 = key, this[S$._canonicalize](t29)), new (__t$MapEntryOfK$V()).__(key, value));
return value$;
}
addAll(other) {
__t$MapOfK$V().as(other);
if (other == null) dart.nullFailed(I[91], 63, 25, "other");
other[S$.$forEach](dart.fn((key, value) => {
let t30, t29;
t29 = key;
t30 = value;
this._set(t29, t30);
return t30;
}, __t$KAndVTovoid()));
}
addEntries(entries) {
__t$IterableOfMapEntryOfK$V().as(entries);
if (entries == null) dart.nullFailed(I[91], 68, 44, "entries");
return this[S$._base][S$.$addEntries](entries[S$.$map](__t$MapEntryOfC$MapEntryOfK$V(), dart.fn(e => {
let t29;
if (e == null) dart.nullFailed(I[91], 69, 13, "e");
return new (__t$MapEntryOfC$MapEntryOfK$V()).__((t29 = e.key, this[S$._canonicalize](t29)), new (__t$MapEntryOfK$V()).__(e.key, e.value));
}, __t$MapEntryOfK$VToMapEntryOfC$MapEntryOfK$V())));
}
cast(K2, V2) {
return this[S$._base][S$.$cast](K2, V2);
}
clear() {
this[S$._base][S$.$clear]();
}
containsKey(key) {
let t29;
if (!dart.test(this[S$._isValidKey](key))) return false;
return this[S$._base][S$.$containsKey]((t29 = K.as(key), this[S$._canonicalize](t29)));
}
containsValue(value) {
return this[S$._base][S$.$values][S$.$any](dart.fn(pair => {
if (pair == null) dart.nullFailed(I[91], 87, 25, "pair");
return dart.equals(pair.value, value);
}, __t$MapEntryOfK$VTobool()));
}
get entries() {
return this[S$._base][S$.$entries][S$.$map](__t$MapEntryOfK$V(), dart.fn(e => {
if (e == null) dart.nullFailed(I[91], 91, 26, "e");
return new (__t$MapEntryOfK$V()).__(e.value.key, e.value.value);
}, __t$MapEntryOfC$MapEntryOfK$VToMapEntryOfK$V()));
}
forEach(f) {
if (f == null) dart.nullFailed(I[91], 94, 36, "f");
this[S$._base][S$.$forEach](dart.fn((key, pair) => {
if (pair == null) dart.nullFailed(I[91], 95, 25, "pair");
return f(pair.key, pair.value);
}, __t$CAndMapEntryOfK$VTovoid()));
}
get isEmpty() {
return this[S$._base][S$.$isEmpty];
}
get isNotEmpty() {
return this[S$._base][S$.$isNotEmpty];
}
get keys() {
return this[S$._base][S$.$values][S$.$map](K, dart.fn(pair => {
if (pair == null) dart.nullFailed(I[91], 105, 45, "pair");
return pair.key;
}, __t$MapEntryOfK$VToK()));
}
get length() {
return this[S$._base][S$.$length];
}
map(K2, V2, transform) {
if (transform == null) dart.nullFailed(I[91], 111, 59, "transform");
return this[S$._base][S$.$map](K2, V2, dart.fn((_, pair) => {
if (pair == null) dart.nullFailed(I[91], 112, 21, "pair");
return transform(pair.key, pair.value);
}, dart.fnType(core.MapEntry$(K2, V2), [C, __t$MapEntryOfK$V()])));
}
putIfAbsent(key, ifAbsent) {
let t29;
K.as(key);
__t$VoidToV().as(ifAbsent);
if (ifAbsent == null) dart.nullFailed(I[91], 115, 37, "ifAbsent");
return this[S$._base][S$.$putIfAbsent]((t29 = key, this[S$._canonicalize](t29)), dart.fn(() => new (__t$MapEntryOfK$V()).__(key, ifAbsent()), __t$VoidToMapEntryOfK$V())).value;
}
remove(key) {
let t29, t29$;
if (!dart.test(this[S$._isValidKey](key))) return null;
let pair = this[S$._base][S$.$remove]((t29 = K.as(key), this[S$._canonicalize](t29)));
t29$ = pair;
return t29$ == null ? null : t29$.value;
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[91], 129, 50, "test");
return this[S$._base][S$.$removeWhere](dart.fn((_, pair) => {
if (pair == null) dart.nullFailed(I[91], 130, 29, "pair");
return test(pair.key, pair.value);
}, __t$CAndMapEntryOfK$VTobool()));
}
retype(K2, V2) {
return this.cast(K2, V2);
}
update(key, update, opts) {
let t29;
K.as(key);
__t$VToV().as(update);
if (update == null) dart.nullFailed(I[91], 136, 33, "update");
let ifAbsent = opts && 'ifAbsent' in opts ? opts.ifAbsent : null;
__t$VoidToNV().as(ifAbsent);
return this[S$._base][S$.$update]((t29 = key, this[S$._canonicalize](t29)), dart.fn(pair => {
if (pair == null) dart.nullFailed(I[91], 137, 41, "pair");
let value = pair.value;
let newValue = update(value);
if (core.identical(newValue, value)) return pair;
return new (__t$MapEntryOfK$V()).__(key, newValue);
}, __t$MapEntryOfK$VToMapEntryOfK$V()), {ifAbsent: ifAbsent == null ? null : dart.fn(() => new (__t$MapEntryOfK$V()).__(key, ifAbsent()), __t$VoidToMapEntryOfK$V())}).value;
}
updateAll(update) {
__t$KAndVToV().as(update);
if (update == null) dart.nullFailed(I[91], 147, 45, "update");
return this[S$._base][S$.$updateAll](dart.fn((_, pair) => {
if (pair == null) dart.nullFailed(I[91], 148, 27, "pair");
let value = pair.value;
let key = pair.key;
let newValue = update(key, value);
if (core.identical(value, newValue)) return pair;
return new (__t$MapEntryOfK$V()).__(key, newValue);
}, __t$CAndMapEntryOfK$VToMapEntryOfK$V()));
}
get values() {
return this[S$._base][S$.$values][S$.$map](V, dart.fn(pair => {
if (pair == null) dart.nullFailed(I[91], 157, 47, "pair");
return pair.value;
}, __t$MapEntryOfK$VToV()));
}
toString() {
return collection.MapBase.mapToString(this);
}
[S$._isValidKey](key) {
return K.is(key) && (this[S$._isValidKeyFn] == null || dart.test(dart.nullCheck(this[S$._isValidKeyFn])(key)));
}
}
(CanonicalizedMap.new = function(canonicalize, opts) {
if (canonicalize == null) dart.nullFailed(I[91], 28, 38, "canonicalize");
let isValidKey = opts && 'isValidKey' in opts ? opts.isValidKey : null;
this[S$._base] = new (__t$LinkedMapOfC$MapEntryOfK$V()).new();
this[S$._canonicalize] = canonicalize;
this[S$._isValidKeyFn] = isValidKey;
;
}).prototype = CanonicalizedMap.prototype;
(CanonicalizedMap.from = function(other, canonicalize, opts) {
if (other == null) dart.nullFailed(I[91], 42, 35, "other");
if (canonicalize == null) dart.nullFailed(I[91], 42, 60, "canonicalize");
let isValidKey = opts && 'isValidKey' in opts ? opts.isValidKey : null;
this[S$._base] = new (__t$LinkedMapOfC$MapEntryOfK$V()).new();
this[S$._canonicalize] = canonicalize;
this[S$._isValidKeyFn] = isValidKey;
this.addAll(other);
}).prototype = CanonicalizedMap.prototype;
CanonicalizedMap.prototype[dart.isMap] = true;
dart.addTypeTests(CanonicalizedMap);
CanonicalizedMap.prototype[_is_CanonicalizedMap_default] = true;
dart.addTypeCaches(CanonicalizedMap);
CanonicalizedMap[dart.implements] = () => [core.Map$(K, V)];
dart.setMethodSignature(CanonicalizedMap, () => ({
__proto__: dart.getMethods(CanonicalizedMap.__proto__),
_get: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
[S$.$_get]: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
_set: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addAll]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addEntries: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addEntries]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
cast: dart.gFnType((K2, V2) => [core.Map$(K2, V2), []], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType((K2, V2) => [core.Map$(K2, V2), []], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, []),
containsKey: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$containsKey]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
containsValue: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$containsValue]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
forEach: dart.fnType(dart.void, [dart.fnType(dart.void, [K, V])]),
[S$.$forEach]: dart.fnType(dart.void, [dart.fnType(dart.void, [K, V])]),
map: dart.gFnType((K2, V2) => [core.Map$(K2, V2), [dart.fnType(core.MapEntry$(K2, V2), [K, V])]], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$map]: dart.gFnType((K2, V2) => [core.Map$(K2, V2), [dart.fnType(core.MapEntry$(K2, V2), [K, V])]], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
putIfAbsent: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$putIfAbsent]: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)]),
remove: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [K, V])]),
[S$.$removeWhere]: dart.fnType(dart.void, [dart.fnType(core.bool, [K, V])]),
retype: dart.gFnType((K2, V2) => [core.Map$(K2, V2), []], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
update: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)], {ifAbsent: dart.nullable(core.Object)}, {}),
[S$.$update]: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)], {ifAbsent: dart.nullable(core.Object)}, {}),
updateAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$updateAll]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$._isValidKey]: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setGetterSignature(CanonicalizedMap, () => ({
__proto__: dart.getGetters(CanonicalizedMap.__proto__),
entries: core.Iterable$(core.MapEntry$(K, V)),
[S$.$entries]: core.Iterable$(core.MapEntry$(K, V)),
isEmpty: core.bool,
[S$.$isEmpty]: core.bool,
isNotEmpty: core.bool,
[S$.$isNotEmpty]: core.bool,
keys: core.Iterable$(K),
[S$.$keys]: core.Iterable$(K),
length: core.int,
[S$.$length]: core.int,
values: core.Iterable$(V),
[S$.$values]: core.Iterable$(V)
}));
dart.setLibraryUri(CanonicalizedMap, I[92]);
dart.setFieldSignature(CanonicalizedMap, () => ({
__proto__: dart.getFields(CanonicalizedMap.__proto__),
[S$._canonicalize]: dart.finalFieldType(dart.fnType(C, [K])),
[S$._isValidKeyFn]: dart.finalFieldType(dart.nullable(dart.fnType(core.bool, [K]))),
[S$._base]: dart.finalFieldType(core.Map$(C, core.MapEntry$(K, V)))
}));
dart.defineExtensionMethods(CanonicalizedMap, [
'_get',
'_set',
'addAll',
'addEntries',
'cast',
'clear',
'containsKey',
'containsValue',
'forEach',
'map',
'putIfAbsent',
'remove',
'removeWhere',
'update',
'updateAll',
'toString'
]);
dart.defineExtensionAccessors(CanonicalizedMap, [
'entries',
'isEmpty',
'isNotEmpty',
'keys',
'length',
'values'
]);
return CanonicalizedMap;
});
canonicalized_map.CanonicalizedMap = canonicalized_map.CanonicalizedMap$();
dart.addTypeTests(canonicalized_map.CanonicalizedMap, _is_CanonicalizedMap_default);
const _is_CombinedIterableView_default = Symbol('_is_CombinedIterableView_default');
combined_iterable.CombinedIterableView$ = dart.generic(T => {
var __t$CombinedIteratorOfT = () => (__t$CombinedIteratorOfT = dart.constFn(combined_iterator.CombinedIterator$(T)))();
var __t$IteratorOfT = () => (__t$IteratorOfT = dart.constFn(core.Iterator$(T)))();
var __t$IterableOfT = () => (__t$IterableOfT = dart.constFn(core.Iterable$(T)))();
var __t$IterableOfTToIteratorOfT = () => (__t$IterableOfTToIteratorOfT = dart.constFn(dart.fnType(__t$IteratorOfT(), [__t$IterableOfT()])))();
var __t$IterableOfTTobool = () => (__t$IterableOfTTobool = dart.constFn(dart.fnType(core.bool, [__t$IterableOfT()])))();
var __t$intAndIterableOfTToint = () => (__t$intAndIterableOfTToint = dart.constFn(dart.fnType(core.int, [core.int, __t$IterableOfT()])))();
class CombinedIterableView extends collection.IterableBase$(T) {
get [S$._iterables$1]() {
return this[S$._iterables];
}
set [S$._iterables$1](value) {
super[S$._iterables$1] = value;
}
static ['_#new#tearOff'](T, _iterables) {
if (_iterables == null) dart.nullFailed(I[93], 21, 35, "_iterables");
return new (combined_iterable.CombinedIterableView$(T)).new(_iterables);
}
get iterator() {
return new (__t$CombinedIteratorOfT()).new(this[S$._iterables$1][S$.$map](__t$IteratorOfT(), dart.fn(i => {
if (i == null) dart.nullFailed(I[93], 25, 43, "i");
return i[S$.$iterator];
}, __t$IterableOfTToIteratorOfT()))[S$.$iterator]);
}
contains(element) {
return this[S$._iterables$1][S$.$any](dart.fn(i => {
if (i == null) dart.nullFailed(I[93], 31, 53, "i");
return i[S$.$contains](element);
}, __t$IterableOfTTobool()));
}
get isEmpty() {
return this[S$._iterables$1][S$.$every](dart.fn(i => {
if (i == null) dart.nullFailed(I[93], 34, 41, "i");
return i[S$.$isEmpty];
}, __t$IterableOfTTobool()));
}
get length() {
return this[S$._iterables$1][S$.$fold](core.int, 0, dart.fn((length, i) => {
if (length == null) dart.nullFailed(I[93], 37, 41, "length");
if (i == null) dart.nullFailed(I[93], 37, 49, "i");
return dart.notNull(length) + dart.notNull(i[S$.$length]);
}, __t$intAndIterableOfTToint()));
}
}
(CombinedIterableView.new = function(_iterables) {
if (_iterables == null) dart.nullFailed(I[93], 21, 35, "_iterables");
this[S$._iterables] = _iterables;
CombinedIterableView.__proto__.new.call(this);
;
}).prototype = CombinedIterableView.prototype;
dart.addTypeTests(CombinedIterableView);
CombinedIterableView.prototype[_is_CombinedIterableView_default] = true;
dart.addTypeCaches(CombinedIterableView);
dart.setGetterSignature(CombinedIterableView, () => ({
__proto__: dart.getGetters(CombinedIterableView.__proto__),
iterator: core.Iterator$(T),
[S$.$iterator]: core.Iterator$(T)
}));
dart.setLibraryUri(CombinedIterableView, I[94]);
dart.setFieldSignature(CombinedIterableView, () => ({
__proto__: dart.getFields(CombinedIterableView.__proto__),
[S$._iterables$1]: dart.finalFieldType(core.Iterable$(core.Iterable$(T)))
}));
dart.defineExtensionMethods(CombinedIterableView, ['contains']);
dart.defineExtensionAccessors(CombinedIterableView, ['iterator', 'isEmpty', 'length']);
return CombinedIterableView;
});
combined_iterable.CombinedIterableView = combined_iterable.CombinedIterableView$();
dart.addTypeTests(combined_iterable.CombinedIterableView, _is_CombinedIterableView_default);
const _is_CombinedListView_default = Symbol('_is_CombinedListView_default');
combined_list.CombinedListView$ = dart.generic(T => {
var __t$CombinedIteratorOfT = () => (__t$CombinedIteratorOfT = dart.constFn(combined_iterator.CombinedIterator$(T)))();
var __t$IteratorOfT = () => (__t$IteratorOfT = dart.constFn(core.Iterator$(T)))();
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$ListOfTToIteratorOfT = () => (__t$ListOfTToIteratorOfT = dart.constFn(dart.fnType(__t$IteratorOfT(), [__t$ListOfT()])))();
var __t$intAndListOfTToint = () => (__t$intAndListOfTToint = dart.constFn(dart.fnType(core.int, [core.int, __t$ListOfT()])))();
var __t$IterableOfT = () => (__t$IterableOfT = dart.constFn(core.Iterable$(T)))();
class CombinedListView extends collection.ListBase$(T) {
static _throw() {
dart.throw(new core.UnsupportedError.new("Cannot modify an unmodifiable List"));
}
static ['_#new#tearOff'](T, _lists) {
if (_lists == null) dart.nullFailed(I[95], 28, 25, "_lists");
return new (combined_list.CombinedListView$(T)).new(_lists);
}
get iterator() {
return new (__t$CombinedIteratorOfT()).new(this[S$._lists][S$.$map](__t$IteratorOfT(), dart.fn(i => {
if (i == null) dart.nullFailed(I[95], 32, 39, "i");
return i[S$.$iterator];
}, __t$ListOfTToIteratorOfT()))[S$.$iterator]);
}
set length(length) {
if (length == null) dart.nullFailed(I[95], 35, 18, "length");
combined_list.CombinedListView._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
get length() {
return this[S$._lists][S$.$fold](core.int, 0, dart.fn((length, list) => {
if (length == null) dart.nullFailed(I[95], 40, 37, "length");
if (list == null) dart.nullFailed(I[95], 40, 45, "list");
return dart.notNull(length) + dart.notNull(list[S$.$length]);
}, __t$intAndListOfTToint()));
}
_get(index) {
if (index == null) dart.nullFailed(I[95], 43, 21, "index");
let initialIndex = index;
for (let i = 0; i < dart.notNull(this[S$._lists][S$.$length]); i = i + 1) {
let list = this[S$._lists][S$.$_get](i);
if (dart.notNull(index) < dart.notNull(list[S$.$length])) {
return list[S$.$_get](index);
}
index = dart.notNull(index) - dart.notNull(list[S$.$length]);
}
dart.throw(new core.IndexError.new(initialIndex, this, "index", null, this.length));
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[95], 56, 25, "index");
T.as(value);
combined_list.CombinedListView._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
return value$;
}
clear() {
combined_list.CombinedListView._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
remove(element) {
combined_list.CombinedListView._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[95], 71, 37, "test");
combined_list.CombinedListView._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[95], 76, 37, "test");
combined_list.CombinedListView._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
get [S$._source$1]() {
return __t$IterableOfT().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[175] || CT.C175)));
}
}
(CombinedListView.new = function(_lists) {
if (_lists == null) dart.nullFailed(I[95], 28, 25, "_lists");
this[S$._lists] = _lists;
;
}).prototype = CombinedListView.prototype;
dart.addTypeTests(CombinedListView);
CombinedListView.prototype[_is_CombinedListView_default] = true;
dart.addTypeCaches(CombinedListView);
CombinedListView[dart.implements] = () => [collection.UnmodifiableListView$(T)];
dart.setMethodSignature(CombinedListView, () => ({
__proto__: dart.getMethods(CombinedListView.__proto__),
_get: dart.fnType(T, [core.int]),
[S$.$_get]: dart.fnType(T, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)])
}));
dart.setStaticMethodSignature(CombinedListView, () => ['_throw']);
dart.setGetterSignature(CombinedListView, () => ({
__proto__: dart.getGetters(CombinedListView.__proto__),
length: core.int,
[S$.$length]: core.int,
[S$._source$1]: core.Iterable$(T)
}));
dart.setSetterSignature(CombinedListView, () => ({
__proto__: dart.getSetters(CombinedListView.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(CombinedListView, I[96]);
dart.setFieldSignature(CombinedListView, () => ({
__proto__: dart.getFields(CombinedListView.__proto__),
[S$._lists]: dart.finalFieldType(core.List$(core.List$(T)))
}));
dart.defineExtensionMethods(CombinedListView, [
'_get',
'_set',
'clear',
'remove',
'removeWhere',
'retainWhere'
]);
dart.defineExtensionAccessors(CombinedListView, ['iterator', 'length']);
return CombinedListView;
});
combined_list.CombinedListView = combined_list.CombinedListView$();
dart.addTypeTests(combined_list.CombinedListView, _is_CombinedListView_default);
const _is_CombinedMapView_default = Symbol('_is_CombinedMapView_default');
combined_map.CombinedMapView$ = dart.generic((K, V) => {
var __t$_DeduplicatingIterableViewOfK = () => (__t$_DeduplicatingIterableViewOfK = dart.constFn(combined_map._DeduplicatingIterableView$(K)))();
var __t$CombinedIterableViewOfK = () => (__t$CombinedIterableViewOfK = dart.constFn(combined_iterable.CombinedIterableView$(K)))();
var __t$IterableOfK = () => (__t$IterableOfK = dart.constFn(core.Iterable$(K)))();
var __t$MapOfK$V = () => (__t$MapOfK$V = dart.constFn(core.Map$(K, V)))();
var __t$MapOfK$VToIterableOfK = () => (__t$MapOfK$VToIterableOfK = dart.constFn(dart.fnType(__t$IterableOfK(), [__t$MapOfK$V()])))();
class CombinedMapView extends collection.UnmodifiableMapBase$(K, V) {
static ['_#new#tearOff'](K, V, _maps) {
if (_maps == null) dart.nullFailed(I[97], 29, 24, "_maps");
return new (combined_map.CombinedMapView$(K, V)).new(_maps);
}
_get(key) {
for (let map of this[S$._maps]) {
let value = map[S$.$_get](key);
if (value != null || dart.test(map[S$.$containsKey](value))) {
return value;
}
}
return null;
}
get keys() {
return new (__t$_DeduplicatingIterableViewOfK()).new(new (__t$CombinedIterableViewOfK()).new(this[S$._maps][S$.$map](__t$IterableOfK(), dart.fn(m => {
if (m == null) dart.nullFailed(I[97], 59, 39, "m");
return m[S$.$keys];
}, __t$MapOfK$VToIterableOfK()))));
}
}
(CombinedMapView.new = function(_maps) {
if (_maps == null) dart.nullFailed(I[97], 29, 24, "_maps");
this[S$._maps] = _maps;
;
}).prototype = CombinedMapView.prototype;
dart.addTypeTests(CombinedMapView);
CombinedMapView.prototype[_is_CombinedMapView_default] = true;
dart.addTypeCaches(CombinedMapView);
dart.setMethodSignature(CombinedMapView, () => ({
__proto__: dart.getMethods(CombinedMapView.__proto__),
_get: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
[S$.$_get]: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(CombinedMapView, () => ({
__proto__: dart.getGetters(CombinedMapView.__proto__),
keys: core.Iterable$(K),
[S$.$keys]: core.Iterable$(K)
}));
dart.setLibraryUri(CombinedMapView, I[98]);
dart.setFieldSignature(CombinedMapView, () => ({
__proto__: dart.getFields(CombinedMapView.__proto__),
[S$._maps]: dart.finalFieldType(core.Iterable$(core.Map$(K, V)))
}));
dart.defineExtensionMethods(CombinedMapView, ['_get']);
dart.defineExtensionAccessors(CombinedMapView, ['keys']);
return CombinedMapView;
});
combined_map.CombinedMapView = combined_map.CombinedMapView$();
dart.addTypeTests(combined_map.CombinedMapView, _is_CombinedMapView_default);
const _is__DeduplicatingIterableView_default = Symbol('_is__DeduplicatingIterableView_default');
combined_map._DeduplicatingIterableView$ = dart.generic(T => {
var __t$_DeduplicatingIteratorOfT = () => (__t$_DeduplicatingIteratorOfT = dart.constFn(combined_map._DeduplicatingIterator$(T)))();
class _DeduplicatingIterableView extends collection.IterableBase$(T) {
get [S$._iterable$1]() {
return this[S$._iterable];
}
set [S$._iterable$1](value) {
super[S$._iterable$1] = value;
}
static ['_#new#tearOff'](T, _iterable) {
if (_iterable == null) dart.nullFailed(I[97], 66, 41, "_iterable");
return new (combined_map._DeduplicatingIterableView$(T)).new(_iterable);
}
get iterator() {
return new (__t$_DeduplicatingIteratorOfT()).new(this[S$._iterable$1][S$.$iterator]);
}
contains(element) {
return this[S$._iterable$1][S$.$contains](element);
}
get isEmpty() {
return this[S$._iterable$1][S$.$isEmpty];
}
}
(_DeduplicatingIterableView.new = function(_iterable) {
if (_iterable == null) dart.nullFailed(I[97], 66, 41, "_iterable");
this[S$._iterable] = _iterable;
_DeduplicatingIterableView.__proto__.new.call(this);
;
}).prototype = _DeduplicatingIterableView.prototype;
dart.addTypeTests(_DeduplicatingIterableView);
_DeduplicatingIterableView.prototype[_is__DeduplicatingIterableView_default] = true;
dart.addTypeCaches(_DeduplicatingIterableView);
dart.setGetterSignature(_DeduplicatingIterableView, () => ({
__proto__: dart.getGetters(_DeduplicatingIterableView.__proto__),
iterator: core.Iterator$(T),
[S$.$iterator]: core.Iterator$(T)
}));
dart.setLibraryUri(_DeduplicatingIterableView, I[98]);
dart.setFieldSignature(_DeduplicatingIterableView, () => ({
__proto__: dart.getFields(_DeduplicatingIterableView.__proto__),
[S$._iterable$1]: dart.finalFieldType(core.Iterable$(T))
}));
dart.defineExtensionMethods(_DeduplicatingIterableView, ['contains']);
dart.defineExtensionAccessors(_DeduplicatingIterableView, ['iterator', 'isEmpty']);
return _DeduplicatingIterableView;
});
combined_map._DeduplicatingIterableView = combined_map._DeduplicatingIterableView$();
dart.addTypeTests(combined_map._DeduplicatingIterableView, _is__DeduplicatingIterableView_default);
const _is__DeduplicatingIterator_default = Symbol('_is__DeduplicatingIterator_default');
combined_map._DeduplicatingIterator$ = dart.generic(T => {
var __t$_HashSetOfT = () => (__t$_HashSetOfT = dart.constFn(collection._HashSet$(T)))();
class _DeduplicatingIterator extends core.Object {
static ['_#new#tearOff'](T, _iterator) {
if (_iterator == null) dart.nullFailed(I[97], 90, 31, "_iterator");
return new (combined_map._DeduplicatingIterator$(T)).new(_iterator);
}
get current() {
return this[S$._iterator].current;
}
moveNext() {
while (dart.test(this[S$._iterator].moveNext())) {
if (dart.test(this[S$._emitted].add(this.current))) {
return true;
}
}
return false;
}
}
(_DeduplicatingIterator.new = function(_iterator) {
if (_iterator == null) dart.nullFailed(I[97], 90, 31, "_iterator");
this[S$._emitted] = new (__t$_HashSetOfT()).new();
this[S$._iterator] = _iterator;
;
}).prototype = _DeduplicatingIterator.prototype;
dart.addTypeTests(_DeduplicatingIterator);
_DeduplicatingIterator.prototype[_is__DeduplicatingIterator_default] = true;
dart.addTypeCaches(_DeduplicatingIterator);
_DeduplicatingIterator[dart.implements] = () => [core.Iterator$(T)];
dart.setMethodSignature(_DeduplicatingIterator, () => ({
__proto__: dart.getMethods(_DeduplicatingIterator.__proto__),
moveNext: dart.fnType(core.bool, [])
}));
dart.setGetterSignature(_DeduplicatingIterator, () => ({
__proto__: dart.getGetters(_DeduplicatingIterator.__proto__),
current: T
}));
dart.setLibraryUri(_DeduplicatingIterator, I[98]);
dart.setFieldSignature(_DeduplicatingIterator, () => ({
__proto__: dart.getFields(_DeduplicatingIterator.__proto__),
[S$._iterator]: dart.finalFieldType(core.Iterator$(T)),
[S$._emitted]: dart.finalFieldType(collection.HashSet$(T))
}));
return _DeduplicatingIterator;
});
combined_map._DeduplicatingIterator = combined_map._DeduplicatingIterator$();
dart.addTypeTests(combined_map._DeduplicatingIterator, _is__DeduplicatingIterator_default);
comparators.equalsIgnoreAsciiCase = function equalsIgnoreAsciiCase(a, b) {
if (a == null) dart.nullFailed(I[99], 27, 35, "a");
if (b == null) dart.nullFailed(I[99], 27, 45, "b");
if (a.length !== b.length) return false;
for (let i = 0; i < a.length; i = i + 1) {
let aChar = a[S$.$codeUnitAt](i);
let bChar = b[S$.$codeUnitAt](i);
if (aChar === bChar) continue;
if ((aChar ^ bChar) >>> 0 !== 32) return false;
let aCharLowerCase = (aChar | 32) >>> 0;
if (97 <= aCharLowerCase && aCharLowerCase <= 122) {
continue;
}
return false;
}
return true;
};
comparators.hashIgnoreAsciiCase = function hashIgnoreAsciiCase(string) {
if (string == null) dart.nullFailed(I[99], 50, 32, "string");
let hash = 0;
for (let i = 0; i < string.length; i = i + 1) {
let char = string[S$.$codeUnitAt](i);
if (97 <= char && char <= 122) char = char - 32;
hash = 536870911 & hash + char;
hash = 536870911 & hash + ((524287 & hash) << 10);
hash = hash[S$.$rightShift](6);
}
hash = 536870911 & hash + ((67108863 & hash) << 3);
hash = hash[S$.$rightShift](11);
return 536870911 & hash + ((16383 & hash) << 15);
};
comparators.compareAsciiUpperCase = function compareAsciiUpperCase(a, b) {
if (a == null) dart.nullFailed(I[99], 85, 34, "a");
if (b == null) dart.nullFailed(I[99], 85, 44, "b");
let defaultResult = 0;
for (let i = 0; i < a.length; i = i + 1) {
if (i >= b.length) return 1;
let aChar = a[S$.$codeUnitAt](i);
let bChar = b[S$.$codeUnitAt](i);
if (aChar === bChar) continue;
let aUpperCase = aChar;
let bUpperCase = bChar;
if (97 <= aChar && aChar <= 122) {
aUpperCase = aUpperCase - 32;
}
if (97 <= bChar && bChar <= 122) {
bUpperCase = bUpperCase - 32;
}
if (aUpperCase !== bUpperCase) return (aUpperCase - bUpperCase)[S$.$sign];
if (defaultResult === 0) defaultResult = aChar - bChar;
}
if (b.length > a.length) return -1;
return defaultResult[S$.$sign];
};
comparators.compareAsciiLowerCase = function compareAsciiLowerCase(a, b) {
if (a == null) dart.nullFailed(I[99], 122, 34, "a");
if (b == null) dart.nullFailed(I[99], 122, 44, "b");
let defaultResult = 0;
for (let i = 0; i < a.length; i = i + 1) {
if (i >= b.length) return 1;
let aChar = a[S$.$codeUnitAt](i);
let bChar = b[S$.$codeUnitAt](i);
if (aChar === bChar) continue;
let aLowerCase = aChar;
let bLowerCase = bChar;
if (65 <= bChar && bChar <= 90) {
bLowerCase = bLowerCase + 32;
}
if (65 <= aChar && aChar <= 90) {
aLowerCase = aLowerCase + 32;
}
if (aLowerCase !== bLowerCase) return (aLowerCase - bLowerCase)[S$.$sign];
if (defaultResult === 0) defaultResult = aChar - bChar;
}
if (b.length > a.length) return -1;
return defaultResult[S$.$sign];
};
comparators.compareNatural = function compareNatural(a, b) {
if (a == null) dart.nullFailed(I[99], 161, 27, "a");
if (b == null) dart.nullFailed(I[99], 161, 37, "b");
for (let i = 0; i < a.length; i = i + 1) {
if (i >= b.length) return 1;
let aChar = a[S$.$codeUnitAt](i);
let bChar = b[S$.$codeUnitAt](i);
if (aChar !== bChar) {
return comparators._compareNaturally(a, b, i, aChar, bChar);
}
}
if (b.length > a.length) return -1;
return 0;
};
comparators.compareAsciiLowerCaseNatural = function compareAsciiLowerCaseNatural(a, b) {
if (a == null) dart.nullFailed(I[99], 187, 41, "a");
if (b == null) dart.nullFailed(I[99], 187, 51, "b");
let defaultResult = 0;
for (let i = 0; i < a.length; i = i + 1) {
if (i >= b.length) return 1;
let aChar = a[S$.$codeUnitAt](i);
let bChar = b[S$.$codeUnitAt](i);
if (aChar === bChar) continue;
let aLowerCase = aChar;
let bLowerCase = bChar;
if (65 <= aChar && aChar <= 90) {
aLowerCase = aLowerCase + 32;
}
if (65 <= bChar && bChar <= 90) {
bLowerCase = bLowerCase + 32;
}
if (aLowerCase !== bLowerCase) {
return comparators._compareNaturally(a, b, i, aLowerCase, bLowerCase);
}
if (defaultResult === 0) defaultResult = aChar - bChar;
}
if (b.length > a.length) return -1;
return defaultResult[S$.$sign];
};
comparators.compareAsciiUpperCaseNatural = function compareAsciiUpperCaseNatural(a, b) {
if (a == null) dart.nullFailed(I[99], 224, 41, "a");
if (b == null) dart.nullFailed(I[99], 224, 51, "b");
let defaultResult = 0;
for (let i = 0; i < a.length; i = i + 1) {
if (i >= b.length) return 1;
let aChar = a[S$.$codeUnitAt](i);
let bChar = b[S$.$codeUnitAt](i);
if (aChar === bChar) continue;
let aUpperCase = aChar;
let bUpperCase = bChar;
if (97 <= aChar && aChar <= 122) {
aUpperCase = aUpperCase - 32;
}
if (97 <= bChar && bChar <= 122) {
bUpperCase = bUpperCase - 32;
}
if (aUpperCase !== bUpperCase) {
return comparators._compareNaturally(a, b, i, aUpperCase, bUpperCase);
}
if (defaultResult === 0) defaultResult = aChar - bChar;
}
if (b.length > a.length) return -1;
return defaultResult[S$.$sign];
};
comparators._compareNaturally = function _compareNaturally(a, b, index, aChar, bChar) {
if (a == null) dart.nullFailed(I[99], 258, 30, "a");
if (b == null) dart.nullFailed(I[99], 258, 40, "b");
if (index == null) dart.nullFailed(I[99], 258, 47, "index");
if (aChar == null) dart.nullFailed(I[99], 258, 58, "aChar");
if (bChar == null) dart.nullFailed(I[99], 258, 69, "bChar");
if (!(aChar != bChar)) dart.assertFailed(null, I[99], 259, 10, "aChar != bChar");
let aIsDigit = comparators._isDigit(aChar);
let bIsDigit = comparators._isDigit(bChar);
if (dart.test(aIsDigit)) {
if (dart.test(bIsDigit)) {
return comparators._compareNumerically(a, b, aChar, bChar, index);
} else if (dart.notNull(index) > 0 && dart.test(comparators._isDigit(a[S$.$codeUnitAt](dart.notNull(index) - 1)))) {
return 1;
}
} else if (dart.test(bIsDigit) && dart.notNull(index) > 0 && dart.test(comparators._isDigit(b[S$.$codeUnitAt](dart.notNull(index) - 1)))) {
return -1;
}
return (dart.notNull(aChar) - dart.notNull(bChar))[S$.$sign];
};
comparators._compareNumerically = function _compareNumerically(a, b, aChar, bChar, index) {
if (a == null) dart.nullFailed(I[99], 283, 32, "a");
if (b == null) dart.nullFailed(I[99], 283, 42, "b");
if (aChar == null) dart.nullFailed(I[99], 283, 49, "aChar");
if (bChar == null) dart.nullFailed(I[99], 283, 60, "bChar");
if (index == null) dart.nullFailed(I[99], 283, 71, "index");
if (dart.test(comparators._isNonZeroNumberSuffix(a, index))) {
let result = comparators._compareDigitCount(a, b, index, index);
if (result !== 0) return result;
return (dart.notNull(aChar) - dart.notNull(bChar))[S$.$sign];
}
let aIndex = index;
let bIndex = index;
if (aChar === 48) {
do {
aIndex = dart.notNull(aIndex) + 1;
if (aIndex === a.length) return -1;
aChar = a[S$.$codeUnitAt](aIndex);
} while (aChar === 48);
if (!dart.test(comparators._isDigit(aChar))) return -1;
} else if (bChar === 48) {
do {
bIndex = dart.notNull(bIndex) + 1;
if (bIndex === b.length) return 1;
bChar = b[S$.$codeUnitAt](bIndex);
} while (bChar === 48);
if (!dart.test(comparators._isDigit(bChar))) return 1;
}
if (aChar != bChar) {
let result = comparators._compareDigitCount(a, b, aIndex, bIndex);
if (result !== 0) return result;
return (dart.notNull(aChar) - dart.notNull(bChar))[S$.$sign];
}
while (true) {
let aIsDigit = false;
let bIsDigit = false;
aChar = 0;
bChar = 0;
if ((aIndex = dart.notNull(aIndex) + 1) < a.length) {
aChar = a[S$.$codeUnitAt](aIndex);
aIsDigit = comparators._isDigit(aChar);
}
if ((bIndex = dart.notNull(bIndex) + 1) < b.length) {
bChar = b[S$.$codeUnitAt](bIndex);
bIsDigit = comparators._isDigit(bChar);
}
if (dart.test(aIsDigit)) {
if (dart.test(bIsDigit)) {
if (aChar == bChar) continue;
break;
}
return 1;
} else if (dart.test(bIsDigit)) {
return -1;
} else {
return (dart.notNull(aIndex) - dart.notNull(bIndex))[S$.$sign];
}
}
let result = comparators._compareDigitCount(a, b, aIndex, bIndex);
if (result !== 0) return result;
return (dart.notNull(aChar) - dart.notNull(bChar))[S$.$sign];
};
comparators._compareDigitCount = function _compareDigitCount(a, b, i, j) {
if (a == null) dart.nullFailed(I[99], 360, 31, "a");
if (b == null) dart.nullFailed(I[99], 360, 41, "b");
if (i == null) dart.nullFailed(I[99], 360, 48, "i");
if (j == null) dart.nullFailed(I[99], 360, 55, "j");
while ((i = dart.notNull(i) + 1) < a.length) {
let aIsDigit = comparators._isDigit(a[S$.$codeUnitAt](i));
if ((j = dart.notNull(j) + 1) === b.length) return dart.test(aIsDigit) ? 1 : 0;
let bIsDigit = comparators._isDigit(b[S$.$codeUnitAt](j));
if (dart.test(aIsDigit)) {
if (dart.test(bIsDigit)) continue;
return 1;
} else if (dart.test(bIsDigit)) {
return -1;
} else {
return 0;
}
}
if ((j = dart.notNull(j) + 1) < b.length && dart.test(comparators._isDigit(b[S$.$codeUnitAt](j)))) {
return -1;
}
return 0;
};
comparators._isDigit = function _isDigit(charCode) {
if (charCode == null) dart.nullFailed(I[99], 380, 19, "charCode");
return (dart.notNull(charCode) ^ 48) >>> 0 <= 9;
};
comparators._isNonZeroNumberSuffix = function _isNonZeroNumberSuffix(string, index) {
if (string == null) dart.nullFailed(I[99], 387, 36, "string");
if (index == null) dart.nullFailed(I[99], 387, 48, "index");
while ((index = dart.notNull(index) - 1) >= 0) {
let char = string[S$.$codeUnitAt](index);
if (char !== 48) return comparators._isDigit(char);
}
return false;
};
dart.defineLazy(comparators, {
/*comparators._zero*/get _zero() {
return 48;
},
/*comparators._upperCaseA*/get _upperCaseA() {
return 65;
},
/*comparators._upperCaseZ*/get _upperCaseZ() {
return 90;
},
/*comparators._lowerCaseA*/get _lowerCaseA() {
return 97;
},
/*comparators._lowerCaseZ*/get _lowerCaseZ() {
return 122;
},
/*comparators._asciiCaseBit*/get _asciiCaseBit() {
return 32;
}
}, false);
const _is_Equality_default = Symbol('_is_Equality_default');
equality$.Equality$ = dart.generic(E => {
class Equality extends core.Object {
static ['_#new#tearOff'](E) {
return new (equality$.DefaultEquality$(E)).new();
}
}
(Equality[dart.mixinNew] = function() {
}).prototype = Equality.prototype;
dart.addTypeTests(Equality);
Equality.prototype[_is_Equality_default] = true;
dart.addTypeCaches(Equality);
dart.setStaticMethodSignature(Equality, () => ['new']);
dart.setLibraryUri(Equality, I[100]);
dart.setStaticFieldSignature(Equality, () => ['_redirecting#']);
return Equality;
});
equality$.Equality = equality$.Equality$();
dart.addTypeTests(equality$.Equality, _is_Equality_default);
const _is_EqualityBy_default = Symbol('_is_EqualityBy_default');
equality$.EqualityBy$ = dart.generic((E, F) => {
class EqualityBy extends core.Object {
static ['_#new#tearOff'](E, F, comparisonKey, inner = C[176] || CT.C176) {
if (comparisonKey == null) dart.nullFailed(I[101], 54, 28, "comparisonKey");
if (inner == null) dart.nullFailed(I[101], 55, 20, "inner");
return new (equality$.EqualityBy$(E, F)).new(comparisonKey, inner);
}
equals(e1, e2) {
let t29, t29$;
E.as(e1);
E.as(e2);
return this[S$._inner].equals((t29 = e1, this[S$._comparisonKey](t29)), (t29$ = e2, this[S$._comparisonKey](t29$)));
}
hash(e) {
let t29;
E.as(e);
return this[S$._inner].hash((t29 = e, this[S$._comparisonKey](t29)));
}
isValidKey(o) {
let t29;
if (E.is(o)) {
let value = (t29 = o, this[S$._comparisonKey](t29));
return F.is(value) && dart.test(this[S$._inner].isValidKey(value));
}
return false;
}
}
(EqualityBy.new = function(comparisonKey, inner = C[176] || CT.C176) {
if (comparisonKey == null) dart.nullFailed(I[101], 54, 28, "comparisonKey");
if (inner == null) dart.nullFailed(I[101], 55, 20, "inner");
this[S$._comparisonKey] = comparisonKey;
this[S$._inner] = inner;
;
}).prototype = EqualityBy.prototype;
dart.addTypeTests(EqualityBy);
EqualityBy.prototype[_is_EqualityBy_default] = true;
dart.addTypeCaches(EqualityBy);
EqualityBy[dart.implements] = () => [equality$.Equality$(E)];
dart.setMethodSignature(EqualityBy, () => ({
__proto__: dart.getMethods(EqualityBy.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(EqualityBy, I[100]);
dart.setFieldSignature(EqualityBy, () => ({
__proto__: dart.getFields(EqualityBy.__proto__),
[S$._comparisonKey]: dart.finalFieldType(dart.fnType(F, [E])),
[S$._inner]: dart.finalFieldType(equality$.Equality$(F))
}));
return EqualityBy;
});
equality$.EqualityBy = equality$.EqualityBy$();
dart.addTypeTests(equality$.EqualityBy, _is_EqualityBy_default);
const _is_DefaultEquality_default = Symbol('_is_DefaultEquality_default');
equality$.DefaultEquality$ = dart.generic(E => {
class DefaultEquality extends core.Object {
static ['_#new#tearOff'](E) {
return new (equality$.DefaultEquality$(E)).new();
}
equals(e1, e2) {
return dart.equals(e1, e2);
}
hash(e) {
return dart.hashCode(e);
}
isValidKey(o) {
return true;
}
}
(DefaultEquality.new = function() {
;
}).prototype = DefaultEquality.prototype;
dart.addTypeTests(DefaultEquality);
DefaultEquality.prototype[_is_DefaultEquality_default] = true;
dart.addTypeCaches(DefaultEquality);
DefaultEquality[dart.implements] = () => [equality$.Equality$(E)];
dart.setMethodSignature(DefaultEquality, () => ({
__proto__: dart.getMethods(DefaultEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(DefaultEquality, I[100]);
return DefaultEquality;
});
equality$.DefaultEquality = equality$.DefaultEquality$();
dart.addTypeTests(equality$.DefaultEquality, _is_DefaultEquality_default);
const _is_IdentityEquality_default = Symbol('_is_IdentityEquality_default');
equality$.IdentityEquality$ = dart.generic(E => {
class IdentityEquality extends core.Object {
static ['_#new#tearOff'](E) {
return new (equality$.IdentityEquality$(E)).new();
}
equals(e1, e2) {
E.as(e1);
E.as(e2);
return core.identical(e1, e2);
}
hash(e) {
E.as(e);
return core.identityHashCode(e);
}
isValidKey(o) {
return true;
}
}
(IdentityEquality.new = function() {
;
}).prototype = IdentityEquality.prototype;
dart.addTypeTests(IdentityEquality);
IdentityEquality.prototype[_is_IdentityEquality_default] = true;
dart.addTypeCaches(IdentityEquality);
IdentityEquality[dart.implements] = () => [equality$.Equality$(E)];
dart.setMethodSignature(IdentityEquality, () => ({
__proto__: dart.getMethods(IdentityEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(IdentityEquality, I[100]);
return IdentityEquality;
});
equality$.IdentityEquality = equality$.IdentityEquality$();
dart.addTypeTests(equality$.IdentityEquality, _is_IdentityEquality_default);
const _is_IterableEquality_default = Symbol('_is_IterableEquality_default');
equality$.IterableEquality$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$IterableNOfE = () => (__t$IterableNOfE = dart.constFn(dart.nullable(__t$IterableOfE())))();
class IterableEquality extends core.Object {
get [S$._elementEquality$1]() {
return this[S$._elementEquality];
}
set [S$._elementEquality$1](value) {
super[S$._elementEquality$1] = value;
}
static ['_#new#tearOff'](E, elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 115, 20, "elementEquality");
return new (equality$.IterableEquality$(E)).new(elementEquality);
}
equals(elements1, elements2) {
__t$IterableNOfE().as(elements1);
__t$IterableNOfE().as(elements2);
if (elements1 == elements2) return true;
if (elements1 == null || elements2 == null) return false;
let it1 = elements1[S$.$iterator];
let it2 = elements2[S$.$iterator];
while (true) {
let hasNext = it1.moveNext();
if (hasNext != it2.moveNext()) return false;
if (!dart.test(hasNext)) return true;
if (!dart.test(this[S$._elementEquality$1].equals(it1.current, it2.current))) return false;
}
}
hash(elements) {
__t$IterableNOfE().as(elements);
if (elements == null) return dart.hashCode(null);
let hash = 0;
for (let element of elements) {
let c = this[S$._elementEquality$1].hash(element);
hash = (hash + dart.notNull(c) & 2147483647) >>> 0;
hash = (hash + (hash << 10 >>> 0) & 2147483647) >>> 0;
hash = (hash ^ hash[S$.$rightShift](6)) >>> 0;
}
hash = (hash + (hash << 3 >>> 0) & 2147483647) >>> 0;
hash = (hash ^ hash[S$.$rightShift](11)) >>> 0;
hash = (hash + (hash << 15 >>> 0) & 2147483647) >>> 0;
return hash;
}
isValidKey(o) {
return __t$IterableOfE().is(o);
}
}
(IterableEquality.new = function(elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 115, 20, "elementEquality");
this[S$._elementEquality] = elementEquality;
;
}).prototype = IterableEquality.prototype;
dart.addTypeTests(IterableEquality);
IterableEquality.prototype[_is_IterableEquality_default] = true;
dart.addTypeCaches(IterableEquality);
IterableEquality[dart.implements] = () => [equality$.Equality$(core.Iterable$(E))];
dart.setMethodSignature(IterableEquality, () => ({
__proto__: dart.getMethods(IterableEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(IterableEquality, I[100]);
dart.setFieldSignature(IterableEquality, () => ({
__proto__: dart.getFields(IterableEquality.__proto__),
[S$._elementEquality$1]: dart.finalFieldType(equality$.Equality$(dart.nullable(E)))
}));
return IterableEquality;
});
equality$.IterableEquality = equality$.IterableEquality$();
dart.addTypeTests(equality$.IterableEquality, _is_IterableEquality_default);
const _is_ListEquality_default = Symbol('_is_ListEquality_default');
equality$.ListEquality$ = dart.generic(E => {
var __t$ListOfE = () => (__t$ListOfE = dart.constFn(core.List$(E)))();
var __t$ListNOfE = () => (__t$ListNOfE = dart.constFn(dart.nullable(__t$ListOfE())))();
class ListEquality extends core.Object {
get [S$._elementEquality$1]() {
return this[S$._elementEquality$2];
}
set [S$._elementEquality$1](value) {
super[S$._elementEquality$1] = value;
}
static ['_#new#tearOff'](E, elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 167, 20, "elementEquality");
return new (equality$.ListEquality$(E)).new(elementEquality);
}
equals(list1, list2) {
__t$ListNOfE().as(list1);
__t$ListNOfE().as(list2);
if (list1 == list2) return true;
if (list1 == null || list2 == null) return false;
let length = list1[S$.$length];
if (length != list2[S$.$length]) return false;
for (let i = 0; i < dart.notNull(length); i = i + 1) {
if (!dart.test(this[S$._elementEquality$1].equals(list1[S$.$_get](i), list2[S$.$_get](i)))) return false;
}
return true;
}
hash(list) {
__t$ListNOfE().as(list);
if (list == null) return dart.hashCode(null);
let hash = 0;
for (let i = 0; i < dart.notNull(list[S$.$length]); i = i + 1) {
let c = this[S$._elementEquality$1].hash(list[S$.$_get](i));
hash = (hash + dart.notNull(c) & 2147483647) >>> 0;
hash = (hash + (hash << 10 >>> 0) & 2147483647) >>> 0;
hash = (hash ^ hash[S$.$rightShift](6)) >>> 0;
}
hash = (hash + (hash << 3 >>> 0) & 2147483647) >>> 0;
hash = (hash ^ hash[S$.$rightShift](11)) >>> 0;
hash = (hash + (hash << 15 >>> 0) & 2147483647) >>> 0;
return hash;
}
isValidKey(o) {
return __t$ListOfE().is(o);
}
}
(ListEquality.new = function(elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 167, 20, "elementEquality");
this[S$._elementEquality$2] = elementEquality;
;
}).prototype = ListEquality.prototype;
dart.addTypeTests(ListEquality);
ListEquality.prototype[_is_ListEquality_default] = true;
dart.addTypeCaches(ListEquality);
ListEquality[dart.implements] = () => [equality$.Equality$(core.List$(E))];
dart.setMethodSignature(ListEquality, () => ({
__proto__: dart.getMethods(ListEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(ListEquality, I[100]);
dart.setFieldSignature(ListEquality, () => ({
__proto__: dart.getFields(ListEquality.__proto__),
[S$._elementEquality$1]: dart.finalFieldType(equality$.Equality$(E))
}));
return ListEquality;
});
equality$.ListEquality = equality$.ListEquality$();
dart.addTypeTests(equality$.ListEquality, _is_ListEquality_default);
const _is__UnorderedEquality_default = Symbol('_is__UnorderedEquality_default');
equality$._UnorderedEquality$ = dart.generic((E, T) => {
var __t$HashMapOfE$dynamic = () => (__t$HashMapOfE$dynamic = dart.constFn(collection.HashMap$(E, dart.dynamic)))();
var __t$EAndETobool = () => (__t$EAndETobool = dart.constFn(dart.fnType(core.bool, [E, E])))();
var __t$EToint = () => (__t$EToint = dart.constFn(dart.fnType(core.int, [E])))();
class _UnorderedEquality extends core.Object {
get [S$._elementEquality$1]() {
return this[S$._elementEquality$3];
}
set [S$._elementEquality$1](value) {
super[S$._elementEquality$1] = value;
}
equals(elements1, elements2) {
let t29;
T.as(elements1);
T.as(elements2);
if (elements1 == elements2) return true;
if (elements1 == null || elements2 == null) return false;
let counts = __t$HashMapOfE$dynamic().new({equals: __t$EAndETobool().as(dart.bind(this[S$._elementEquality$1], 'equals')), hashCode: __t$EToint().as(dart.bind(this[S$._elementEquality$1], 'hash')), isValidKey: dart.bind(this[S$._elementEquality$1], 'isValidKey')});
let length = 0;
for (let e of elements1) {
let count = (t29 = counts[S$.$_get](e), t29 == null ? 0 : t29);
counts[S$.$_set](e, dart.dsend(count, '+', [1]));
length = length + 1;
}
for (let e of elements2) {
let count = counts[S$.$_get](e);
if (count == null || dart.equals(count, 0)) return false;
counts[S$.$_set](e, dart.dsend(count, '-', [1]));
length = length - 1;
}
return length === 0;
}
hash(elements) {
T.as(elements);
if (elements == null) return dart.hashCode(null);
let hash = 0;
for (let element of elements) {
let c = this[S$._elementEquality$1].hash(element);
hash = (hash + dart.notNull(c) & 2147483647) >>> 0;
}
hash = (hash + (hash << 3 >>> 0) & 2147483647) >>> 0;
hash = (hash ^ hash[S$.$rightShift](11)) >>> 0;
hash = (hash + (hash << 15 >>> 0) & 2147483647) >>> 0;
return hash;
}
}
(_UnorderedEquality.new = function(_elementEquality) {
if (_elementEquality == null) dart.nullFailed(I[101], 209, 33, "_elementEquality");
this[S$._elementEquality$3] = _elementEquality;
;
}).prototype = _UnorderedEquality.prototype;
dart.addTypeTests(_UnorderedEquality);
_UnorderedEquality.prototype[_is__UnorderedEquality_default] = true;
dart.addTypeCaches(_UnorderedEquality);
_UnorderedEquality[dart.implements] = () => [equality$.Equality$(T)];
dart.setMethodSignature(_UnorderedEquality, () => ({
__proto__: dart.getMethods(_UnorderedEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(_UnorderedEquality, I[100]);
dart.setFieldSignature(_UnorderedEquality, () => ({
__proto__: dart.getFields(_UnorderedEquality.__proto__),
[S$._elementEquality$1]: dart.finalFieldType(equality$.Equality$(E))
}));
return _UnorderedEquality;
});
equality$._UnorderedEquality = equality$._UnorderedEquality$();
dart.addTypeTests(equality$._UnorderedEquality, _is__UnorderedEquality_default);
const _is_UnorderedIterableEquality_default = Symbol('_is_UnorderedIterableEquality_default');
equality$.UnorderedIterableEquality$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
class UnorderedIterableEquality extends equality$._UnorderedEquality$(E, dart.nullable(core.Iterable$(E))) {
static ['_#new#tearOff'](E, elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 256, 20, "elementEquality");
return new (equality$.UnorderedIterableEquality$(E)).new(elementEquality);
}
isValidKey(o) {
return __t$IterableOfE().is(o);
}
}
(UnorderedIterableEquality.new = function(elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 256, 20, "elementEquality");
UnorderedIterableEquality.__proto__.new.call(this, elementEquality);
;
}).prototype = UnorderedIterableEquality.prototype;
dart.addTypeTests(UnorderedIterableEquality);
UnorderedIterableEquality.prototype[_is_UnorderedIterableEquality_default] = true;
dart.addTypeCaches(UnorderedIterableEquality);
dart.setMethodSignature(UnorderedIterableEquality, () => ({
__proto__: dart.getMethods(UnorderedIterableEquality.__proto__),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(UnorderedIterableEquality, I[100]);
return UnorderedIterableEquality;
});
equality$.UnorderedIterableEquality = equality$.UnorderedIterableEquality$();
dart.addTypeTests(equality$.UnorderedIterableEquality, _is_UnorderedIterableEquality_default);
const _is_SetEquality_default = Symbol('_is_SetEquality_default');
equality$.SetEquality$ = dart.generic(E => {
var __t$SetOfE = () => (__t$SetOfE = dart.constFn(core.Set$(E)))();
class SetEquality extends equality$._UnorderedEquality$(E, dart.nullable(core.Set$(E))) {
static ['_#new#tearOff'](E, elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 277, 20, "elementEquality");
return new (equality$.SetEquality$(E)).new(elementEquality);
}
isValidKey(o) {
return __t$SetOfE().is(o);
}
}
(SetEquality.new = function(elementEquality = C[176] || CT.C176) {
if (elementEquality == null) dart.nullFailed(I[101], 277, 20, "elementEquality");
SetEquality.__proto__.new.call(this, elementEquality);
;
}).prototype = SetEquality.prototype;
dart.addTypeTests(SetEquality);
SetEquality.prototype[_is_SetEquality_default] = true;
dart.addTypeCaches(SetEquality);
dart.setMethodSignature(SetEquality, () => ({
__proto__: dart.getMethods(SetEquality.__proto__),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(SetEquality, I[100]);
return SetEquality;
});
equality$.SetEquality = equality$.SetEquality$();
dart.addTypeTests(equality$.SetEquality, _is_SetEquality_default);
equality$._MapEntry = class _MapEntry extends core.Object {
static ['_#new#tearOff'](equality, key, value) {
if (equality == null) dart.nullFailed(I[101], 292, 18, "equality");
return new equality$._MapEntry.new(equality, key, value);
}
get hashCode() {
return (3 * dart.notNull(this.equality[S$._keyEquality].hash(this.key)) + 7 * dart.notNull(this.equality[S$._valueEquality].hash(this.value)) & 2147483647) >>> 0;
}
_equals(other) {
if (other == null) return false;
return equality$._MapEntry.is(other) && dart.test(this.equality[S$._keyEquality].equals(this.key, other.key)) && dart.test(this.equality[S$._valueEquality].equals(this.value, other.value));
}
};
(equality$._MapEntry.new = function(equality, key, value) {
if (equality == null) dart.nullFailed(I[101], 292, 18, "equality");
this.equality = equality;
this.key = key;
this.value = value;
;
}).prototype = equality$._MapEntry.prototype;
dart.addTypeTests(equality$._MapEntry);
dart.addTypeCaches(equality$._MapEntry);
dart.setLibraryUri(equality$._MapEntry, I[100]);
dart.setFieldSignature(equality$._MapEntry, () => ({
__proto__: dart.getFields(equality$._MapEntry.__proto__),
equality: dart.finalFieldType(equality$.MapEquality),
key: dart.finalFieldType(dart.dynamic),
value: dart.finalFieldType(dart.dynamic)
}));
dart.defineExtensionMethods(equality$._MapEntry, ['_equals']);
dart.defineExtensionAccessors(equality$._MapEntry, ['hashCode']);
const _is_MapEquality_default = Symbol('_is_MapEquality_default');
equality$.MapEquality$ = dart.generic((K, V) => {
var __t$MapOfK$V = () => (__t$MapOfK$V = dart.constFn(core.Map$(K, V)))();
var __t$MapNOfK$V = () => (__t$MapNOfK$V = dart.constFn(dart.nullable(__t$MapOfK$V())))();
class MapEquality extends core.Object {
get [S$._keyEquality]() {
return this[S$._keyEquality$1];
}
set [S$._keyEquality](value) {
super[S$._keyEquality] = value;
}
get [S$._valueEquality]() {
return this[S$._valueEquality$1];
}
set [S$._valueEquality](value) {
super[S$._valueEquality] = value;
}
static ['_#new#tearOff'](K, V, opts) {
let keys = opts && 'keys' in opts ? opts.keys : C[176] || CT.C176;
if (keys == null) dart.nullFailed(I[101], 319, 20, "keys");
let values = opts && 'values' in opts ? opts.values : C[176] || CT.C176;
if (values == null) dart.nullFailed(I[101], 320, 19, "values");
return new (equality$.MapEquality$(K, V)).new({keys: keys, values: values});
}
equals(map1, map2) {
let t29;
__t$MapNOfK$V().as(map1);
__t$MapNOfK$V().as(map2);
if (map1 == map2) return true;
if (map1 == null || map2 == null) return false;
let length = map1[S$.$length];
if (length != map2[S$.$length]) return false;
let equalElementCounts = new (T$.LinkedMapOf_MapEntry$int()).new();
for (let key of map1[S$.$keys]) {
let entry = new equality$._MapEntry.new(this, key, map1[S$.$_get](key));
let count = (t29 = equalElementCounts[S$.$_get](entry), t29 == null ? 0 : t29);
equalElementCounts[S$.$_set](entry, dart.notNull(count) + 1);
}
for (let key of map2[S$.$keys]) {
let entry = new equality$._MapEntry.new(this, key, map2[S$.$_get](key));
let count = equalElementCounts[S$.$_get](entry);
if (count == null || count === 0) return false;
equalElementCounts[S$.$_set](entry, dart.notNull(count) - 1);
}
return true;
}
hash(map) {
__t$MapNOfK$V().as(map);
if (map == null) return dart.hashCode(null);
let hash = 0;
for (let key of map[S$.$keys]) {
let keyHash = this[S$._keyEquality].hash(key);
let valueHash = this[S$._valueEquality].hash(V.as(map[S$.$_get](key)));
hash = (hash + 3 * dart.notNull(keyHash) + 7 * dart.notNull(valueHash) & 2147483647) >>> 0;
}
hash = (hash + (hash << 3 >>> 0) & 2147483647) >>> 0;
hash = (hash ^ hash[S$.$rightShift](11)) >>> 0;
hash = (hash + (hash << 15 >>> 0) & 2147483647) >>> 0;
return hash;
}
isValidKey(o) {
return __t$MapOfK$V().is(o);
}
}
(MapEquality.new = function(opts) {
let keys = opts && 'keys' in opts ? opts.keys : C[176] || CT.C176;
if (keys == null) dart.nullFailed(I[101], 319, 20, "keys");
let values = opts && 'values' in opts ? opts.values : C[176] || CT.C176;
if (values == null) dart.nullFailed(I[101], 320, 19, "values");
this[S$._keyEquality$1] = keys;
this[S$._valueEquality$1] = values;
;
}).prototype = MapEquality.prototype;
dart.addTypeTests(MapEquality);
MapEquality.prototype[_is_MapEquality_default] = true;
dart.addTypeCaches(MapEquality);
MapEquality[dart.implements] = () => [equality$.Equality$(core.Map$(K, V))];
dart.setMethodSignature(MapEquality, () => ({
__proto__: dart.getMethods(MapEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(MapEquality, I[100]);
dart.setFieldSignature(MapEquality, () => ({
__proto__: dart.getFields(MapEquality.__proto__),
[S$._keyEquality]: dart.finalFieldType(equality$.Equality$(K)),
[S$._valueEquality]: dart.finalFieldType(equality$.Equality$(V))
}));
return MapEquality;
});
equality$.MapEquality = equality$.MapEquality$();
dart.addTypeTests(equality$.MapEquality, _is_MapEquality_default);
const _is_MultiEquality_default = Symbol('_is_MultiEquality_default');
equality$.MultiEquality$ = dart.generic(E => {
class MultiEquality extends core.Object {
get [S$._equalities$1]() {
return this[S$._equalities];
}
set [S$._equalities$1](value) {
super[S$._equalities$1] = value;
}
static ['_#new#tearOff'](E, equalities) {
if (equalities == null) dart.nullFailed(I[101], 381, 45, "equalities");
return new (equality$.MultiEquality$(E)).new(equalities);
}
equals(e1, e2) {
E.as(e1);
E.as(e2);
for (let eq of this[S$._equalities$1]) {
if (dart.test(eq.isValidKey(e1))) return dart.test(eq.isValidKey(e2)) && dart.test(eq.equals(e1, e2));
}
return false;
}
hash(e) {
E.as(e);
for (let eq of this[S$._equalities$1]) {
if (dart.test(eq.isValidKey(e))) return eq.hash(e);
}
return 0;
}
isValidKey(o) {
for (let eq of this[S$._equalities$1]) {
if (dart.test(eq.isValidKey(o))) return true;
}
return false;
}
}
(MultiEquality.new = function(equalities) {
if (equalities == null) dart.nullFailed(I[101], 381, 45, "equalities");
this[S$._equalities] = equalities;
;
}).prototype = MultiEquality.prototype;
dart.addTypeTests(MultiEquality);
MultiEquality.prototype[_is_MultiEquality_default] = true;
dart.addTypeCaches(MultiEquality);
MultiEquality[dart.implements] = () => [equality$.Equality$(E)];
dart.setMethodSignature(MultiEquality, () => ({
__proto__: dart.getMethods(MultiEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(MultiEquality, I[100]);
dart.setFieldSignature(MultiEquality, () => ({
__proto__: dart.getFields(MultiEquality.__proto__),
[S$._equalities$1]: dart.finalFieldType(core.Iterable$(equality$.Equality$(E)))
}));
return MultiEquality;
});
equality$.MultiEquality = equality$.MultiEquality$();
dart.addTypeTests(equality$.MultiEquality, _is_MultiEquality_default);
equality$.DeepCollectionEquality = class DeepCollectionEquality extends core.Object {
get [S$._base$2]() {
return this[S$._base$1];
}
set [S$._base$2](value) {
super[S$._base$2] = value;
}
get [S$._unordered$1]() {
return this[S$._unordered];
}
set [S$._unordered$1](value) {
super[S$._unordered$1] = value;
}
static ['_#new#tearOff'](base = C[176] || CT.C176) {
if (base == null) dart.nullFailed(I[101], 427, 42, "base");
return new equality$.DeepCollectionEquality.new(base);
}
static ['_#unordered#tearOff'](base = C[176] || CT.C176) {
if (base == null) dart.nullFailed(I[101], 435, 17, "base");
return new equality$.DeepCollectionEquality.unordered(base);
}
equals(e1, e2) {
if (core.Set.is(e1)) {
return core.Set.is(e2) && dart.test(new equality$.SetEquality.new(this).equals(e1, e2));
}
if (core.Map.is(e1)) {
return core.Map.is(e2) && dart.test(new equality$.MapEquality.new({keys: this, values: this}).equals(e1, e2));
}
if (!dart.test(this[S$._unordered$1])) {
if (core.List.is(e1)) {
return core.List.is(e2) && dart.test(new equality$.ListEquality.new(this).equals(e1, e2));
}
if (core.Iterable.is(e1)) {
return core.Iterable.is(e2) && dart.test(new equality$.IterableEquality.new(this).equals(e1, e2));
}
} else if (core.Iterable.is(e1)) {
if (core.List.is(e1) !== core.List.is(e2)) return false;
return core.Iterable.is(e2) && dart.test(new equality$.UnorderedIterableEquality.new(this).equals(e1, e2));
}
return this[S$._base$2].equals(e1, e2);
}
hash(o) {
if (core.Set.is(o)) return new equality$.SetEquality.new(this).hash(o);
if (core.Map.is(o)) return new equality$.MapEquality.new({keys: this, values: this}).hash(o);
if (!dart.test(this[S$._unordered$1])) {
if (core.List.is(o)) return new equality$.ListEquality.new(this).hash(o);
if (core.Iterable.is(o)) return new equality$.IterableEquality.new(this).hash(o);
} else if (core.Iterable.is(o)) {
return new equality$.UnorderedIterableEquality.new(this).hash(o);
}
return this[S$._base$2].hash(o);
}
isValidKey(o) {
return core.Iterable.is(o) || core.Map.is(o) || dart.test(this[S$._base$2].isValidKey(o));
}
};
(equality$.DeepCollectionEquality.new = function(base = C[176] || CT.C176) {
if (base == null) dart.nullFailed(I[101], 427, 42, "base");
this[S$._base$1] = base;
this[S$._unordered] = false;
;
}).prototype = equality$.DeepCollectionEquality.prototype;
(equality$.DeepCollectionEquality.unordered = function(base = C[176] || CT.C176) {
if (base == null) dart.nullFailed(I[101], 435, 17, "base");
this[S$._base$1] = base;
this[S$._unordered] = true;
;
}).prototype = equality$.DeepCollectionEquality.prototype;
dart.addTypeTests(equality$.DeepCollectionEquality);
dart.addTypeCaches(equality$.DeepCollectionEquality);
equality$.DeepCollectionEquality[dart.implements] = () => [equality$.Equality];
dart.setMethodSignature(equality$.DeepCollectionEquality, () => ({
__proto__: dart.getMethods(equality$.DeepCollectionEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(equality$.DeepCollectionEquality, I[100]);
dart.setFieldSignature(equality$.DeepCollectionEquality, () => ({
__proto__: dart.getFields(equality$.DeepCollectionEquality.__proto__),
[S$._base$2]: dart.finalFieldType(equality$.Equality),
[S$._unordered$1]: dart.finalFieldType(core.bool)
}));
equality$.CaseInsensitiveEquality = class CaseInsensitiveEquality extends core.Object {
static ['_#new#tearOff']() {
return new equality$.CaseInsensitiveEquality.new();
}
equals(string1, string2) {
core.String.as(string1);
if (string1 == null) dart.nullFailed(I[101], 486, 22, "string1");
core.String.as(string2);
if (string2 == null) dart.nullFailed(I[101], 486, 38, "string2");
return comparators.equalsIgnoreAsciiCase(string1, string2);
}
hash(string) {
core.String.as(string);
if (string == null) dart.nullFailed(I[101], 490, 19, "string");
return comparators.hashIgnoreAsciiCase(string);
}
isValidKey(object) {
return typeof object == 'string';
}
};
(equality$.CaseInsensitiveEquality.new = function() {
;
}).prototype = equality$.CaseInsensitiveEquality.prototype;
dart.addTypeTests(equality$.CaseInsensitiveEquality);
dart.addTypeCaches(equality$.CaseInsensitiveEquality);
equality$.CaseInsensitiveEquality[dart.implements] = () => [equality$.Equality$(core.String)];
dart.setMethodSignature(equality$.CaseInsensitiveEquality, () => ({
__proto__: dart.getMethods(equality$.CaseInsensitiveEquality.__proto__),
equals: dart.fnType(core.bool, [dart.nullable(core.Object), dart.nullable(core.Object)]),
hash: dart.fnType(core.int, [dart.nullable(core.Object)]),
isValidKey: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(equality$.CaseInsensitiveEquality, I[100]);
dart.defineLazy(equality$, {
/*equality$._HASH_MASK*/get _HASH_MASK() {
return 2147483647;
}
}, false);
const _is_DelegatingMap_default = Symbol('_is_DelegatingMap_default');
wrappers.DelegatingMap$ = dart.generic((K, V) => {
var __t$MapOfK$V = () => (__t$MapOfK$V = dart.constFn(core.Map$(K, V)))();
var __t$MapEntryOfK$V = () => (__t$MapEntryOfK$V = dart.constFn(core.MapEntry$(K, V)))();
var __t$IterableOfMapEntryOfK$V = () => (__t$IterableOfMapEntryOfK$V = dart.constFn(core.Iterable$(__t$MapEntryOfK$V())))();
var __t$KAndVToV = () => (__t$KAndVToV = dart.constFn(dart.fnType(V, [K, V])))();
var __t$VoidToV = () => (__t$VoidToV = dart.constFn(dart.fnType(V, [])))();
var __t$VToV = () => (__t$VToV = dart.constFn(dart.fnType(V, [V])))();
var __t$VoidToNV = () => (__t$VoidToNV = dart.constFn(dart.nullable(__t$VoidToV())))();
class DelegatingMap extends core.Object {
get [S$._base$4]() {
return this[S$._base$3];
}
set [S$._base$4](value) {
super[S$._base$4] = value;
}
static ['_#new#tearOff'](K, V, base) {
if (base == null) dart.nullFailed(I[103], 484, 33, "base");
return new (wrappers.DelegatingMap$(K, V)).new(base);
}
static typed(K, V, base) {
if (base == null) dart.nullFailed(I[103], 498, 36, "base");
return base[S$.$cast](K, V);
}
_get(key) {
return this[S$._base$4][S$.$_get](key);
}
_set(key, value$) {
let value = value$;
K.as(key);
V.as(value);
this[S$._base$4][S$.$_set](key, value);
return value$;
}
addAll(other) {
__t$MapOfK$V().as(other);
if (other == null) dart.nullFailed(I[103], 509, 25, "other");
this[S$._base$4][S$.$addAll](other);
}
addEntries(entries) {
__t$IterableOfMapEntryOfK$V().as(entries);
if (entries == null) dart.nullFailed(I[103], 514, 44, "entries");
this[S$._base$4][S$.$addEntries](entries);
}
clear() {
this[S$._base$4][S$.$clear]();
}
cast(K2, V2) {
return this[S$._base$4][S$.$cast](K2, V2);
}
containsKey(key) {
return this[S$._base$4][S$.$containsKey](key);
}
containsValue(value) {
return this[S$._base$4][S$.$containsValue](value);
}
get entries() {
return this[S$._base$4][S$.$entries];
}
forEach(f) {
if (f == null) dart.nullFailed(I[103], 536, 36, "f");
this[S$._base$4][S$.$forEach](f);
}
get isEmpty() {
return this[S$._base$4][S$.$isEmpty];
}
get isNotEmpty() {
return this[S$._base$4][S$.$isNotEmpty];
}
get keys() {
return this[S$._base$4][S$.$keys];
}
get length() {
return this[S$._base$4][S$.$length];
}
map(K2, V2, transform) {
if (transform == null) dart.nullFailed(I[103], 553, 59, "transform");
return this[S$._base$4][S$.$map](K2, V2, transform);
}
putIfAbsent(key, ifAbsent) {
K.as(key);
__t$VoidToV().as(ifAbsent);
if (ifAbsent == null) dart.nullFailed(I[103], 557, 37, "ifAbsent");
return this[S$._base$4][S$.$putIfAbsent](key, ifAbsent);
}
remove(key) {
return this[S$._base$4][S$.$remove](key);
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[103], 564, 40, "test");
return this[S$._base$4][S$.$removeWhere](test);
}
retype(K2, V2) {
return this.cast(K2, V2);
}
get values() {
return this[S$._base$4][S$.$values];
}
toString() {
return dart.toString(this[S$._base$4]);
}
update(key, update, opts) {
K.as(key);
__t$VToV().as(update);
if (update == null) dart.nullFailed(I[103], 576, 33, "update");
let ifAbsent = opts && 'ifAbsent' in opts ? opts.ifAbsent : null;
__t$VoidToNV().as(ifAbsent);
return this[S$._base$4][S$.$update](key, update, {ifAbsent: ifAbsent});
}
updateAll(update) {
__t$KAndVToV().as(update);
if (update == null) dart.nullFailed(I[103], 580, 35, "update");
return this[S$._base$4][S$.$updateAll](update);
}
}
(DelegatingMap.new = function(base) {
if (base == null) dart.nullFailed(I[103], 484, 33, "base");
this[S$._base$3] = base;
;
}).prototype = DelegatingMap.prototype;
DelegatingMap.prototype[dart.isMap] = true;
dart.addTypeTests(DelegatingMap);
DelegatingMap.prototype[_is_DelegatingMap_default] = true;
dart.addTypeCaches(DelegatingMap);
DelegatingMap[dart.implements] = () => [core.Map$(K, V)];
dart.setMethodSignature(DelegatingMap, () => ({
__proto__: dart.getMethods(DelegatingMap.__proto__),
_get: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
[S$.$_get]: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
_set: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addAll]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addEntries: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addEntries]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, []),
cast: dart.gFnType((K2, V2) => [core.Map$(K2, V2), []], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType((K2, V2) => [core.Map$(K2, V2), []], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
containsKey: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$containsKey]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
containsValue: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$containsValue]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
forEach: dart.fnType(dart.void, [dart.fnType(dart.void, [K, V])]),
[S$.$forEach]: dart.fnType(dart.void, [dart.fnType(dart.void, [K, V])]),
map: dart.gFnType((K2, V2) => [core.Map$(K2, V2), [dart.fnType(core.MapEntry$(K2, V2), [K, V])]], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$map]: dart.gFnType((K2, V2) => [core.Map$(K2, V2), [dart.fnType(core.MapEntry$(K2, V2), [K, V])]], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
putIfAbsent: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$putIfAbsent]: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)]),
remove: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [K, V])]),
[S$.$removeWhere]: dart.fnType(dart.void, [dart.fnType(core.bool, [K, V])]),
retype: dart.gFnType((K2, V2) => [core.Map$(K2, V2), []], (K2, V2) => [dart.nullable(core.Object), dart.nullable(core.Object)]),
update: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)], {ifAbsent: dart.nullable(core.Object)}, {}),
[S$.$update]: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)], {ifAbsent: dart.nullable(core.Object)}, {}),
updateAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$updateAll]: dart.fnType(dart.void, [dart.nullable(core.Object)])
}));
dart.setStaticMethodSignature(DelegatingMap, () => ['typed']);
dart.setGetterSignature(DelegatingMap, () => ({
__proto__: dart.getGetters(DelegatingMap.__proto__),
entries: core.Iterable$(core.MapEntry$(K, V)),
[S$.$entries]: core.Iterable$(core.MapEntry$(K, V)),
isEmpty: core.bool,
[S$.$isEmpty]: core.bool,
isNotEmpty: core.bool,
[S$.$isNotEmpty]: core.bool,
keys: core.Iterable$(K),
[S$.$keys]: core.Iterable$(K),
length: core.int,
[S$.$length]: core.int,
values: core.Iterable$(V),
[S$.$values]: core.Iterable$(V)
}));
dart.setLibraryUri(DelegatingMap, I[104]);
dart.setFieldSignature(DelegatingMap, () => ({
__proto__: dart.getFields(DelegatingMap.__proto__),
[S$._base$4]: dart.finalFieldType(core.Map$(K, V))
}));
dart.defineExtensionMethods(DelegatingMap, [
'_get',
'_set',
'addAll',
'addEntries',
'clear',
'cast',
'containsKey',
'containsValue',
'forEach',
'map',
'putIfAbsent',
'remove',
'removeWhere',
'toString',
'update',
'updateAll'
]);
dart.defineExtensionAccessors(DelegatingMap, [
'entries',
'isEmpty',
'isNotEmpty',
'keys',
'length',
'values'
]);
return DelegatingMap;
});
wrappers.DelegatingMap = wrappers.DelegatingMap$();
dart.addTypeTests(wrappers.DelegatingMap, _is_DelegatingMap_default);
const _is_EqualityMap_default = Symbol('_is_EqualityMap_default');
equality_map.EqualityMap$ = dart.generic((K, V) => {
var __t$LinkedHashMapOfK$V = () => (__t$LinkedHashMapOfK$V = dart.constFn(collection.LinkedHashMap$(K, V)))();
var __t$KAndKTobool = () => (__t$KAndKTobool = dart.constFn(dart.fnType(core.bool, [K, K])))();
var __t$KToint = () => (__t$KToint = dart.constFn(dart.fnType(core.int, [K])))();
class EqualityMap extends wrappers.DelegatingMap$(K, V) {
static ['_#new#tearOff'](K, V, equality) {
if (equality == null) dart.nullFailed(I[102], 13, 27, "equality");
return new (equality_map.EqualityMap$(K, V)).new(equality);
}
static ['_#from#tearOff'](K, V, equality, other) {
if (equality == null) dart.nullFailed(I[102], 24, 32, "equality");
if (other == null) dart.nullFailed(I[102], 24, 52, "other");
return new (equality_map.EqualityMap$(K, V)).from(equality, other);
}
}
(EqualityMap.new = function(equality) {
if (equality == null) dart.nullFailed(I[102], 13, 27, "equality");
EqualityMap.__proto__.new.call(this, __t$LinkedHashMapOfK$V().new({equals: __t$KAndKTobool().as(dart.bind(equality, 'equals')), hashCode: __t$KToint().as(dart.bind(equality, 'hash')), isValidKey: dart.bind(equality, 'isValidKey')}));
;
}).prototype = EqualityMap.prototype;
(EqualityMap.from = function(equality, other) {
if (equality == null) dart.nullFailed(I[102], 24, 32, "equality");
if (other == null) dart.nullFailed(I[102], 24, 52, "other");
EqualityMap.__proto__.new.call(this, __t$LinkedHashMapOfK$V().new({equals: __t$KAndKTobool().as(dart.bind(equality, 'equals')), hashCode: __t$KToint().as(dart.bind(equality, 'hash')), isValidKey: dart.bind(equality, 'isValidKey')}));
this.addAll(other);
}).prototype = EqualityMap.prototype;
dart.addTypeTests(EqualityMap);
EqualityMap.prototype[_is_EqualityMap_default] = true;
dart.addTypeCaches(EqualityMap);
dart.setLibraryUri(EqualityMap, I[105]);
return EqualityMap;
});
equality_map.EqualityMap = equality_map.EqualityMap$();
dart.addTypeTests(equality_map.EqualityMap, _is_EqualityMap_default);
const _is__DelegatingIterableBase_default = Symbol('_is__DelegatingIterableBase_default');
wrappers._DelegatingIterableBase$ = dart.generic(E => {
var __t$VoidToE = () => (__t$VoidToE = dart.constFn(dart.fnType(E, [])))();
var __t$VoidToNE = () => (__t$VoidToNE = dart.constFn(dart.nullable(__t$VoidToE())))();
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$EAndEToE = () => (__t$EAndEToE = dart.constFn(dart.fnType(E, [E, E])))();
class _DelegatingIterableBase extends core.Object {
any(test) {
if (test == null) dart.nullFailed(I[103], 20, 29, "test");
return this[S$._base$4][S$.$any](test);
}
cast(T) {
return this[S$._base$4][S$.$cast](T);
}
contains(element) {
return this[S$._base$4][S$.$contains](element);
}
elementAt(index) {
if (index == null) dart.nullFailed(I[103], 29, 19, "index");
return this[S$._base$4][S$.$elementAt](index);
}
every(test) {
if (test == null) dart.nullFailed(I[103], 32, 31, "test");
return this[S$._base$4][S$.$every](test);
}
expand(T, f) {
if (f == null) dart.nullFailed(I[103], 35, 49, "f");
return this[S$._base$4][S$.$expand](T, f);
}
get first() {
return this[S$._base$4][S$.$first];
}
firstWhere(test, opts) {
if (test == null) dart.nullFailed(I[103], 41, 33, "test");
let orElse = opts && 'orElse' in opts ? opts.orElse : null;
__t$VoidToNE().as(orElse);
return this[S$._base$4][S$.$firstWhere](test, {orElse: orElse});
}
fold(T, initialValue, combine) {
if (combine == null) dart.nullFailed(I[103], 45, 68, "combine");
return this[S$._base$4][S$.$fold](T, initialValue, combine);
}
followedBy(other) {
__t$IterableOfE().as(other);
if (other == null) dart.nullFailed(I[103], 49, 38, "other");
return this[S$._base$4][S$.$followedBy](other);
}
forEach(f) {
if (f == null) dart.nullFailed(I[103], 52, 33, "f");
return this[S$._base$4][S$.$forEach](f);
}
get isEmpty() {
return this[S$._base$4][S$.$isEmpty];
}
get isNotEmpty() {
return this[S$._base$4][S$.$isNotEmpty];
}
get iterator() {
return this[S$._base$4][S$.$iterator];
}
[Symbol.iterator]() {
return new dart.JsIterator(this[S$.$iterator]);
}
join(separator = "") {
if (separator == null) dart.nullFailed(I[103], 64, 23, "separator");
return this[S$._base$4][S$.$join](separator);
}
get last() {
return this[S$._base$4][S$.$last];
}
lastWhere(test, opts) {
if (test == null) dart.nullFailed(I[103], 70, 32, "test");
let orElse = opts && 'orElse' in opts ? opts.orElse : null;
__t$VoidToNE().as(orElse);
return this[S$._base$4][S$.$lastWhere](test, {orElse: orElse});
}
get length() {
return this[S$._base$4][S$.$length];
}
map(T, f) {
if (f == null) dart.nullFailed(I[103], 77, 36, "f");
return this[S$._base$4][S$.$map](T, f);
}
reduce(combine) {
__t$EAndEToE().as(combine);
if (combine == null) dart.nullFailed(I[103], 80, 43, "combine");
return this[S$._base$4][S$.$reduce](combine);
}
retype(T) {
return this.cast(T);
}
get single() {
return this[S$._base$4][S$.$single];
}
singleWhere(test, opts) {
if (test == null) dart.nullFailed(I[103], 89, 34, "test");
let orElse = opts && 'orElse' in opts ? opts.orElse : null;
__t$VoidToNE().as(orElse);
return this[S$._base$4][S$.$singleWhere](test, {orElse: orElse});
}
skip(n) {
if (n == null) dart.nullFailed(I[103], 94, 24, "n");
return this[S$._base$4][S$.$skip](n);
}
skipWhile(test) {
if (test == null) dart.nullFailed(I[103], 97, 42, "test");
return this[S$._base$4][S$.$skipWhile](test);
}
take(n) {
if (n == null) dart.nullFailed(I[103], 100, 24, "n");
return this[S$._base$4][S$.$take](n);
}
takeWhile(test) {
if (test == null) dart.nullFailed(I[103], 103, 42, "test");
return this[S$._base$4][S$.$takeWhile](test);
}
toList(opts) {
let growable = opts && 'growable' in opts ? opts.growable : true;
if (growable == null) dart.nullFailed(I[103], 106, 24, "growable");
return this[S$._base$4][S$.$toList]({growable: growable});
}
toSet() {
return this[S$._base$4][S$.$toSet]();
}
where(test) {
if (test == null) dart.nullFailed(I[103], 112, 38, "test");
return this[S$._base$4][S$.$where](test);
}
whereType(T) {
return this[S$._base$4][S$.$whereType](T);
}
toString() {
return dart.toString(this[S$._base$4]);
}
}
(_DelegatingIterableBase.new = function() {
;
}).prototype = _DelegatingIterableBase.prototype;
_DelegatingIterableBase.prototype[dart.isIterable] = true;
dart.addTypeTests(_DelegatingIterableBase);
_DelegatingIterableBase.prototype[_is__DelegatingIterableBase_default] = true;
dart.addTypeCaches(_DelegatingIterableBase);
_DelegatingIterableBase[dart.implements] = () => [core.Iterable$(E)];
dart.setMethodSignature(_DelegatingIterableBase, () => ({
__proto__: dart.getMethods(_DelegatingIterableBase.__proto__),
any: dart.fnType(core.bool, [dart.fnType(core.bool, [E])]),
[S$.$any]: dart.fnType(core.bool, [dart.fnType(core.bool, [E])]),
cast: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)]),
contains: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$contains]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
elementAt: dart.fnType(E, [core.int]),
[S$.$elementAt]: dart.fnType(E, [core.int]),
every: dart.fnType(core.bool, [dart.fnType(core.bool, [E])]),
[S$.$every]: dart.fnType(core.bool, [dart.fnType(core.bool, [E])]),
expand: dart.gFnType(T => [core.Iterable$(T), [dart.fnType(core.Iterable$(T), [E])]], T => [dart.nullable(core.Object)]),
[S$.$expand]: dart.gFnType(T => [core.Iterable$(T), [dart.fnType(core.Iterable$(T), [E])]], T => [dart.nullable(core.Object)]),
firstWhere: dart.fnType(E, [dart.fnType(core.bool, [E])], {orElse: dart.nullable(core.Object)}, {}),
[S$.$firstWhere]: dart.fnType(E, [dart.fnType(core.bool, [E])], {orElse: dart.nullable(core.Object)}, {}),
fold: dart.gFnType(T => [T, [T, dart.fnType(T, [T, E])]], T => [dart.nullable(core.Object)]),
[S$.$fold]: dart.gFnType(T => [T, [T, dart.fnType(T, [T, E])]], T => [dart.nullable(core.Object)]),
followedBy: dart.fnType(core.Iterable$(E), [dart.nullable(core.Object)]),
[S$.$followedBy]: dart.fnType(core.Iterable$(E), [dart.nullable(core.Object)]),
forEach: dart.fnType(dart.void, [dart.fnType(dart.void, [E])]),
[S$.$forEach]: dart.fnType(dart.void, [dart.fnType(dart.void, [E])]),
join: dart.fnType(core.String, [], [core.String]),
[S$.$join]: dart.fnType(core.String, [], [core.String]),
lastWhere: dart.fnType(E, [dart.fnType(core.bool, [E])], {orElse: dart.nullable(core.Object)}, {}),
[S$.$lastWhere]: dart.fnType(E, [dart.fnType(core.bool, [E])], {orElse: dart.nullable(core.Object)}, {}),
map: dart.gFnType(T => [core.Iterable$(T), [dart.fnType(T, [E])]], T => [dart.nullable(core.Object)]),
[S$.$map]: dart.gFnType(T => [core.Iterable$(T), [dart.fnType(T, [E])]], T => [dart.nullable(core.Object)]),
reduce: dart.fnType(E, [dart.nullable(core.Object)]),
[S$.$reduce]: dart.fnType(E, [dart.nullable(core.Object)]),
retype: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)]),
singleWhere: dart.fnType(E, [dart.fnType(core.bool, [E])], {orElse: dart.nullable(core.Object)}, {}),
[S$.$singleWhere]: dart.fnType(E, [dart.fnType(core.bool, [E])], {orElse: dart.nullable(core.Object)}, {}),
skip: dart.fnType(core.Iterable$(E), [core.int]),
[S$.$skip]: dart.fnType(core.Iterable$(E), [core.int]),
skipWhile: dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [E])]),
[S$.$skipWhile]: dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [E])]),
take: dart.fnType(core.Iterable$(E), [core.int]),
[S$.$take]: dart.fnType(core.Iterable$(E), [core.int]),
takeWhile: dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [E])]),
[S$.$takeWhile]: dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [E])]),
toList: dart.fnType(core.List$(E), [], {growable: core.bool}, {}),
[S$.$toList]: dart.fnType(core.List$(E), [], {growable: core.bool}, {}),
toSet: dart.fnType(core.Set$(E), []),
[S$.$toSet]: dart.fnType(core.Set$(E), []),
where: dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [E])]),
[S$.$where]: dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [E])]),
whereType: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)]),
[S$.$whereType]: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)])
}));
dart.setGetterSignature(_DelegatingIterableBase, () => ({
__proto__: dart.getGetters(_DelegatingIterableBase.__proto__),
first: E,
[S$.$first]: E,
isEmpty: core.bool,
[S$.$isEmpty]: core.bool,
isNotEmpty: core.bool,
[S$.$isNotEmpty]: core.bool,
iterator: core.Iterator$(E),
[S$.$iterator]: core.Iterator$(E),
last: E,
[S$.$last]: E,
length: core.int,
[S$.$length]: core.int,
single: E,
[S$.$single]: E
}));
dart.setLibraryUri(_DelegatingIterableBase, I[104]);
dart.defineExtensionMethods(_DelegatingIterableBase, [
'any',
'cast',
'contains',
'elementAt',
'every',
'expand',
'firstWhere',
'fold',
'followedBy',
'forEach',
'join',
'lastWhere',
'map',
'reduce',
'singleWhere',
'skip',
'skipWhile',
'take',
'takeWhile',
'toList',
'toSet',
'where',
'whereType',
'toString'
]);
dart.defineExtensionAccessors(_DelegatingIterableBase, [
'first',
'isEmpty',
'isNotEmpty',
'iterator',
'last',
'length',
'single'
]);
return _DelegatingIterableBase;
});
wrappers._DelegatingIterableBase = wrappers._DelegatingIterableBase$();
dart.addTypeTests(wrappers._DelegatingIterableBase, _is__DelegatingIterableBase_default);
const _is_DelegatingSet_default = Symbol('_is_DelegatingSet_default');
wrappers.DelegatingSet$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$SetOfE = () => (__t$SetOfE = dart.constFn(core.Set$(E)))();
var __t$DelegatingSetOfE = () => (__t$DelegatingSetOfE = dart.constFn(wrappers.DelegatingSet$(E)))();
class DelegatingSet extends wrappers._DelegatingIterableBase$(E) {
get [S$._base$4]() {
return this[S$._base$5];
}
set [S$._base$4](value) {
super[S$._base$4] = value;
}
static ['_#new#tearOff'](E, base) {
if (base == null) dart.nullFailed(I[103], 320, 30, "base");
return new (wrappers.DelegatingSet$(E)).new(base);
}
static typed(E, base) {
if (base == null) dart.nullFailed(I[103], 334, 30, "base");
return base.cast(E);
}
add(value) {
E.as(value);
return this[S$._base$4].add(value);
}
addAll(elements) {
__t$IterableOfE().as(elements);
if (elements == null) dart.nullFailed(I[103], 340, 27, "elements");
this[S$._base$4].addAll(elements);
}
cast(T) {
return this[S$._base$4].cast(T);
}
clear() {
this[S$._base$4].clear();
}
containsAll(other) {
if (other == null) dart.nullFailed(I[103], 353, 38, "other");
return this[S$._base$4].containsAll(other);
}
difference(other) {
if (other == null) dart.nullFailed(I[103], 356, 34, "other");
return this[S$._base$4].difference(other);
}
intersection(other) {
if (other == null) dart.nullFailed(I[103], 359, 36, "other");
return this[S$._base$4].intersection(other);
}
lookup(element) {
return this[S$._base$4].lookup(element);
}
remove(value) {
return this[S$._base$4].remove(value);
}
removeAll(elements) {
if (elements == null) dart.nullFailed(I[103], 368, 36, "elements");
this[S$._base$4].removeAll(elements);
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[103], 373, 37, "test");
this[S$._base$4].removeWhere(test);
}
retainAll(elements) {
if (elements == null) dart.nullFailed(I[103], 378, 36, "elements");
this[S$._base$4].retainAll(elements);
}
retype(T) {
return this.cast(T);
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[103], 387, 37, "test");
this[S$._base$4].retainWhere(test);
}
union(other) {
__t$SetOfE().as(other);
if (other == null) dart.nullFailed(I[103], 392, 23, "other");
return this[S$._base$4].union(other);
}
toSet() {
return new (__t$DelegatingSetOfE()).new(this[S$._base$4].toSet());
}
}
(DelegatingSet.new = function(base) {
if (base == null) dart.nullFailed(I[103], 320, 30, "base");
this[S$._base$5] = base;
DelegatingSet.__proto__.new.call(this);
;
}).prototype = DelegatingSet.prototype;
dart.addTypeTests(DelegatingSet);
DelegatingSet.prototype[_is_DelegatingSet_default] = true;
dart.addTypeCaches(DelegatingSet);
DelegatingSet[dart.implements] = () => [core.Set$(E)];
dart.setMethodSignature(DelegatingSet, () => ({
__proto__: dart.getMethods(DelegatingSet.__proto__),
add: dart.fnType(core.bool, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
cast: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
containsAll: dart.fnType(core.bool, [core.Iterable$(dart.nullable(core.Object))]),
difference: dart.fnType(core.Set$(E), [core.Set$(dart.nullable(core.Object))]),
intersection: dart.fnType(core.Set$(E), [core.Set$(dart.nullable(core.Object))]),
lookup: dart.fnType(dart.nullable(E), [dart.nullable(core.Object)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeAll: dart.fnType(dart.void, [core.Iterable$(dart.nullable(core.Object))]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
retainAll: dart.fnType(dart.void, [core.Iterable$(dart.nullable(core.Object))]),
retype: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
retainWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
union: dart.fnType(core.Set$(E), [dart.nullable(core.Object)])
}));
dart.setStaticMethodSignature(DelegatingSet, () => ['typed']);
dart.setLibraryUri(DelegatingSet, I[104]);
dart.setFieldSignature(DelegatingSet, () => ({
__proto__: dart.getFields(DelegatingSet.__proto__),
[S$._base$4]: dart.finalFieldType(core.Set$(E))
}));
dart.defineExtensionMethods(DelegatingSet, ['cast', 'toSet']);
return DelegatingSet;
});
wrappers.DelegatingSet = wrappers.DelegatingSet$();
dart.addTypeTests(wrappers.DelegatingSet, _is_DelegatingSet_default);
const _is_EqualitySet_default = Symbol('_is_EqualitySet_default');
equality_set.EqualitySet$ = dart.generic(E => {
var __t$LinkedHashSetOfE = () => (__t$LinkedHashSetOfE = dart.constFn(collection.LinkedHashSet$(E)))();
var __t$EAndETobool = () => (__t$EAndETobool = dart.constFn(dart.fnType(core.bool, [E, E])))();
var __t$EToint = () => (__t$EToint = dart.constFn(dart.fnType(core.int, [E])))();
class EqualitySet extends wrappers.DelegatingSet$(E) {
static ['_#new#tearOff'](E, equality) {
if (equality == null) dart.nullFailed(I[106], 13, 27, "equality");
return new (equality_set.EqualitySet$(E)).new(equality);
}
static ['_#from#tearOff'](E, equality, other) {
if (equality == null) dart.nullFailed(I[106], 24, 32, "equality");
if (other == null) dart.nullFailed(I[106], 24, 54, "other");
return new (equality_set.EqualitySet$(E)).from(equality, other);
}
}
(EqualitySet.new = function(equality) {
if (equality == null) dart.nullFailed(I[106], 13, 27, "equality");
EqualitySet.__proto__.new.call(this, __t$LinkedHashSetOfE().new({equals: __t$EAndETobool().as(dart.bind(equality, 'equals')), hashCode: __t$EToint().as(dart.bind(equality, 'hash')), isValidKey: dart.bind(equality, 'isValidKey')}));
;
}).prototype = EqualitySet.prototype;
(EqualitySet.from = function(equality, other) {
if (equality == null) dart.nullFailed(I[106], 24, 32, "equality");
if (other == null) dart.nullFailed(I[106], 24, 54, "other");
EqualitySet.__proto__.new.call(this, __t$LinkedHashSetOfE().new({equals: __t$EAndETobool().as(dart.bind(equality, 'equals')), hashCode: __t$EToint().as(dart.bind(equality, 'hash')), isValidKey: dart.bind(equality, 'isValidKey')}));
this.addAll(other);
}).prototype = EqualitySet.prototype;
dart.addTypeTests(EqualitySet);
EqualitySet.prototype[_is_EqualitySet_default] = true;
dart.addTypeCaches(EqualitySet);
dart.setLibraryUri(EqualitySet, I[107]);
return EqualitySet;
});
equality_set.EqualitySet = equality_set.EqualitySet$();
dart.addTypeTests(equality_set.EqualitySet, _is_EqualitySet_default);
functions.mapMap = function mapMap(K1, V1, K2, V2, map, opts) {
let t29, t29$;
if (map == null) dart.nullFailed(I[108], 15, 48, "map");
let key = opts && 'key' in opts ? opts.key : null;
let value = opts && 'value' in opts ? opts.value : null;
let keyFn = (t29 = key, t29 == null ? dart.fn((mapKey, _) => K2.as(mapKey), dart.fnType(K2, [K1, V1])) : t29);
let valueFn = (t29$ = value, t29$ == null ? dart.fn((_, mapValue) => V2.as(mapValue), dart.fnType(V2, [K1, V1])) : t29$);
let result = new (_js_helper.LinkedMap$(K2, V2)).new();
map[S$.$forEach](dart.fn((mapKey, mapValue) => {
result[S$.$_set](keyFn(mapKey, mapValue), valueFn(mapKey, mapValue));
}, dart.fnType(dart.void, [K1, V1])));
return result;
};
functions.mergeMaps = function mergeMaps(K, V, map1, map2, opts) {
let t29;
if (map1 == null) dart.nullFailed(I[108], 32, 37, "map1");
if (map2 == null) dart.nullFailed(I[108], 32, 53, "map2");
let value = opts && 'value' in opts ? opts.value : null;
let result = collection.LinkedHashMap$(K, V).of(map1);
if (value == null) {
t29 = result;
return (() => {
t29[S$.$addAll](map2);
return t29;
})();
}
map2[S$.$forEach](dart.fn((key, mapValue) => {
result[S$.$_set](key, dart.test(result[S$.$containsKey](key)) ? value(V.as(result[S$.$_get](key)), mapValue) : mapValue);
}, dart.fnType(dart.void, [K, V])));
return result;
};
functions.groupBy = function groupBy(S, T, values, key) {
let t32, t31, t30, t29;
if (values == null) dart.nullFailed(I[108], 49, 43, "values");
if (key == null) dart.nullFailed(I[108], 49, 65, "key");
let map = new (_js_helper.LinkedMap$(T, core.List$(S))).new();
for (let element of values) {
(t29 = map, t30 = key(element), t31 = t29[S$.$_get](t30), t31 == null ? (t32 = _interceptors.JSArray$(S).of([]), t29[S$.$_set](t30, t32), t32) : t31)[S$.$add](element);
}
return map;
};
functions.minBy = function minBy(S, T, values, orderBy, opts) {
if (values == null) dart.nullFailed(I[108], 65, 28, "values");
if (orderBy == null) dart.nullFailed(I[108], 65, 50, "orderBy");
let compare = opts && 'compare' in opts ? opts.compare : null;
compare == null ? compare = C[173] || CT.C173 : null;
let minValue = null;
let minOrderBy = null;
for (let element of values) {
let elementOrderBy = orderBy(element);
if (minOrderBy == null || dart.notNull(compare(elementOrderBy, minOrderBy)) < 0) {
minValue = element;
minOrderBy = elementOrderBy;
}
}
return minValue;
};
functions.maxBy = function maxBy(S, T, values, orderBy, opts) {
if (values == null) dart.nullFailed(I[108], 89, 28, "values");
if (orderBy == null) dart.nullFailed(I[108], 89, 51, "orderBy");
let compare = opts && 'compare' in opts ? opts.compare : null;
compare == null ? compare = C[173] || CT.C173 : null;
let maxValue = null;
let maxOrderBy = null;
for (let element of values) {
let elementOrderBy = orderBy(element);
if (maxOrderBy == null || dart.nullCheck(compare(elementOrderBy, maxOrderBy)) > 0) {
maxValue = element;
maxOrderBy = elementOrderBy;
}
}
return maxValue;
};
functions.transitiveClosure = function transitiveClosure(T, graph) {
if (graph == null) dart.nullFailed(I[108], 116, 57, "graph");
let result = new (_js_helper.LinkedMap$(T, core.Set$(T))).new();
graph[S$.$forEach](dart.fn((vertex, edges) => {
if (edges == null) dart.nullFailed(I[108], 122, 26, "edges");
result[S$.$_set](vertex, collection.LinkedHashSet$(T).from(edges));
}, dart.fnType(dart.void, [T, core.Iterable$(T)])));
let keys = graph[S$.$keys][S$.$toList]();
for (let vertex1 of keys) {
for (let vertex2 of keys) {
for (let vertex3 of keys) {
if (dart.test(dart.nullCheck(result[S$.$_get](vertex2)).contains(vertex1)) && dart.test(dart.nullCheck(result[S$.$_get](vertex1)).contains(vertex3))) {
dart.nullCheck(result[S$.$_get](vertex2)).add(vertex3);
}
}
}
}
return result;
};
functions.stronglyConnectedComponents = function stronglyConnectedComponents(T, graph) {
if (graph == null) dart.nullFailed(I[108], 155, 65, "graph");
let index = 0;
let stack = _interceptors.JSArray$(dart.nullable(T)).of([]);
let result = _interceptors.JSArray$(core.Set$(T)).of([]);
let indices = new (_js_helper.LinkedMap$(T, core.int)).new();
let lowLinks = new (_js_helper.LinkedMap$(T, core.int)).new();
let onStack = new (collection._HashSet$(T)).new();
function strongConnect(vertex) {
indices[S$.$_set](vertex, index);
lowLinks[S$.$_set](vertex, index);
index = index + 1;
stack[S$.$add](vertex);
onStack.add(vertex);
for (let successor of dart.nullCheck(graph[S$.$_get](vertex))) {
if (!dart.test(indices[S$.$containsKey](successor))) {
strongConnect(successor);
lowLinks[S$.$_set](vertex, math.min(core.int, dart.nullCheck(lowLinks[S$.$_get](vertex)), dart.nullCheck(lowLinks[S$.$_get](successor))));
} else if (dart.test(onStack.contains(successor))) {
lowLinks[S$.$_set](vertex, math.min(core.int, dart.nullCheck(lowLinks[S$.$_get](vertex)), dart.nullCheck(lowLinks[S$.$_get](successor))));
}
}
if (lowLinks[S$.$_get](vertex) == indices[S$.$_get](vertex)) {
let component = collection.LinkedHashSet$(T).new();
let neighbor = null;
do {
neighbor = stack[S$.$removeLast]();
onStack.remove(neighbor);
component.add(T.as(neighbor));
} while (!dart.equals(neighbor, vertex));
result[S$.$add](component);
}
}
dart.fn(strongConnect, dart.fnType(dart.void, [T]));
for (let vertex of graph[S$.$keys]) {
if (!dart.test(indices[S$.$containsKey](vertex))) strongConnect(vertex);
}
return result[S$.$reversed][S$.$toList]();
};
iterable_extensions['IterableExtension|sample'] = function IterableExtension$124sample(T, $this, count, random = null) {
if ($this == null) dart.nullFailed(I[109], 31, 11, "#this");
if (count == null) dart.nullFailed(I[109], 31, 22, "count");
core.RangeError.checkNotNegative(count, "count");
let iterator = $this[S$.$iterator];
let chosen = _interceptors.JSArray$(T).of([]);
for (let i = 0; i < dart.notNull(count); i = i + 1) {
if (dart.test(iterator.moveNext())) {
chosen[S$.$add](iterator.current);
} else {
return chosen;
}
}
let index = count;
random == null ? random = math.Random.new() : null;
while (dart.test(iterator.moveNext())) {
index = dart.notNull(index) + 1;
let position = random.nextInt(index);
if (dart.notNull(position) < dart.notNull(count)) chosen[S$.$_set](position, iterator.current);
}
return chosen;
};
iterable_extensions['IterableExtension|get#sample'] = function IterableExtension$124get$35sample(T, $this) {
if ($this == null) dart.nullFailed(I[109], 31, 11, "#this");
return dart.fn((count, random = null) => {
if (count == null) dart.nullFailed(I[109], 31, 22, "count");
return iterable_extensions['IterableExtension|sample'](T, $this, count, random);
}, dart.fnType(core.List$(T), [core.int], [T$.RandomN()]));
};
iterable_extensions['IterableExtension|whereNot'] = function IterableExtension$124whereNot(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 53, 15, "#this");
if (test == null) dart.nullFailed(I[109], 53, 49, "test");
return $this[S$.$where](dart.fn(element => !dart.test(test(element)), dart.fnType(core.bool, [T])));
};
iterable_extensions['IterableExtension|get#whereNot'] = function IterableExtension$124get$35whereNot(T, $this) {
if ($this == null) dart.nullFailed(I[109], 53, 15, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 53, 49, "test");
return iterable_extensions['IterableExtension|whereNot'](T, $this, test);
}, dart.fnType(core.Iterable$(T), [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|sorted'] = function IterableExtension$124sorted(T, $this, compare) {
let t35;
if ($this == null) dart.nullFailed(I[109], 59, 11, "#this");
if (compare == null) dart.nullFailed(I[109], 59, 32, "compare");
t35 = (() => {
let t34 = core.List$(T).of($this);
return t34;
})();
return (() => {
t35[S$.$sort](compare);
return t35;
})();
};
iterable_extensions['IterableExtension|get#sorted'] = function IterableExtension$124get$35sorted(T, $this) {
if ($this == null) dart.nullFailed(I[109], 59, 11, "#this");
return dart.fn(compare => {
if (compare == null) dart.nullFailed(I[109], 59, 32, "compare");
return iterable_extensions['IterableExtension|sorted'](T, $this, compare);
}, dart.fnType(core.List$(T), [dart.fnType(core.int, [T, T])]));
};
iterable_extensions['IterableExtension|sortedBy'] = function IterableExtension$124sortedBy(T, K, $this, keyOf) {
if ($this == null) dart.nullFailed(I[109], 65, 11, "#this");
if (keyOf == null) dart.nullFailed(I[109], 65, 67, "keyOf");
let elements = (() => {
let t37 = core.List$(T).of($this);
return t37;
})();
algorithms.quickSortBy(T, K, elements, keyOf, dart.gbind(C[177] || CT.C177, K));
return elements;
};
iterable_extensions['IterableExtension|get#sortedBy'] = function IterableExtension$124get$35sortedBy(T, $this) {
if ($this == null) dart.nullFailed(I[109], 65, 11, "#this");
return dart.fn((K, keyOf) => {
if (keyOf == null) dart.nullFailed(I[109], 65, 67, "keyOf");
return iterable_extensions['IterableExtension|sortedBy'](T, K, $this, keyOf);
}, dart.gFnType(K => [core.List$(T), [dart.fnType(K, [T])]], K => {
var __t$ComparableOfK = () => (__t$ComparableOfK = dart.constFn(core.Comparable$(K)))();
return [__t$ComparableOfK()];
}));
};
iterable_extensions['IterableExtension|sortedByCompare'] = function IterableExtension$124sortedByCompare(T, K, $this, keyOf, compare) {
if ($this == null) dart.nullFailed(I[109], 75, 11, "#this");
if (keyOf == null) dart.nullFailed(I[109], 76, 29, "keyOf");
if (compare == null) dart.nullFailed(I[109], 76, 50, "compare");
let elements = (() => {
let t40 = core.List$(T).of($this);
return t40;
})();
algorithms.quickSortBy(T, K, elements, keyOf, compare);
return elements;
};
iterable_extensions['IterableExtension|get#sortedByCompare'] = function IterableExtension$124get$35sortedByCompare(T, $this) {
if ($this == null) dart.nullFailed(I[109], 75, 11, "#this");
return dart.fn((K, keyOf, compare) => {
if (keyOf == null) dart.nullFailed(I[109], 76, 29, "keyOf");
if (compare == null) dart.nullFailed(I[109], 76, 50, "compare");
return iterable_extensions['IterableExtension|sortedByCompare'](T, K, $this, keyOf, compare);
}, dart.gFnType(K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [core.List$(T), [dart.fnType(K, [T]), __t$KAndKToint()]];
}, K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [T$.ObjectN()];
}));
};
iterable_extensions['IterableExtension|isSorted'] = function IterableExtension$124isSorted(T, $this, compare) {
if ($this == null) dart.nullFailed(I[109], 90, 8, "#this");
if (compare == null) dart.nullFailed(I[109], 90, 31, "compare");
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) return true;
let previousElement = iterator.current;
while (dart.test(iterator.moveNext())) {
let element = iterator.current;
if (dart.notNull(compare(previousElement, element)) > 0) return false;
previousElement = element;
}
return true;
};
iterable_extensions['IterableExtension|get#isSorted'] = function IterableExtension$124get$35isSorted(T, $this) {
if ($this == null) dart.nullFailed(I[109], 90, 8, "#this");
return dart.fn(compare => {
if (compare == null) dart.nullFailed(I[109], 90, 31, "compare");
return iterable_extensions['IterableExtension|isSorted'](T, $this, compare);
}, dart.fnType(core.bool, [dart.fnType(core.int, [T, T])]));
};
iterable_extensions['IterableExtension|isSortedBy'] = function IterableExtension$124isSortedBy(T, K, $this, keyOf) {
if ($this == null) dart.nullFailed(I[109], 106, 8, "#this");
if (keyOf == null) dart.nullFailed(I[109], 106, 66, "keyOf");
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) return true;
let previousKey = keyOf(iterator.current);
while (dart.test(iterator.moveNext())) {
let key = keyOf(iterator.current);
if (dart.notNull(previousKey[S$.$compareTo](key)) > 0) return false;
previousKey = key;
}
return true;
};
iterable_extensions['IterableExtension|get#isSortedBy'] = function IterableExtension$124get$35isSortedBy(T, $this) {
if ($this == null) dart.nullFailed(I[109], 106, 8, "#this");
return dart.fn((K, keyOf) => {
if (keyOf == null) dart.nullFailed(I[109], 106, 66, "keyOf");
return iterable_extensions['IterableExtension|isSortedBy'](T, K, $this, keyOf);
}, dart.gFnType(K => [core.bool, [dart.fnType(K, [T])]], K => {
var __t$ComparableOfK = () => (__t$ComparableOfK = dart.constFn(core.Comparable$(K)))();
return [__t$ComparableOfK()];
}));
};
iterable_extensions['IterableExtension|isSortedByCompare'] = function IterableExtension$124isSortedByCompare(T, K, $this, keyOf, compare) {
if ($this == null) dart.nullFailed(I[109], 123, 8, "#this");
if (keyOf == null) dart.nullFailed(I[109], 124, 29, "keyOf");
if (compare == null) dart.nullFailed(I[109], 124, 50, "compare");
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) return true;
let previousKey = keyOf(iterator.current);
while (dart.test(iterator.moveNext())) {
let key = keyOf(iterator.current);
if (dart.notNull(compare(previousKey, key)) > 0) return false;
previousKey = key;
}
return true;
};
iterable_extensions['IterableExtension|get#isSortedByCompare'] = function IterableExtension$124get$35isSortedByCompare(T, $this) {
if ($this == null) dart.nullFailed(I[109], 123, 8, "#this");
return dart.fn((K, keyOf, compare) => {
if (keyOf == null) dart.nullFailed(I[109], 124, 29, "keyOf");
if (compare == null) dart.nullFailed(I[109], 124, 50, "compare");
return iterable_extensions['IterableExtension|isSortedByCompare'](T, K, $this, keyOf, compare);
}, dart.gFnType(K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [core.bool, [dart.fnType(K, [T]), __t$KAndKToint()]];
}, K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [T$.ObjectN()];
}));
};
iterable_extensions['IterableExtension|forEachIndexed'] = function IterableExtension$124forEachIndexed(T, $this, action) {
let t49;
if ($this == null) dart.nullFailed(I[109], 140, 8, "#this");
if (action == null) dart.nullFailed(I[109], 140, 59, "action");
let index = 0;
for (let element of $this) {
action((t49 = index, index = t49 + 1, t49), element);
}
};
iterable_extensions['IterableExtension|get#forEachIndexed'] = function IterableExtension$124get$35forEachIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 140, 8, "#this");
return dart.fn(action => {
if (action == null) dart.nullFailed(I[109], 140, 59, "action");
return iterable_extensions['IterableExtension|forEachIndexed'](T, $this, action);
}, dart.fnType(dart.void, [dart.fnType(dart.void, [core.int, T])]));
};
iterable_extensions['IterableExtension|forEachWhile'] = function IterableExtension$124forEachWhile(T, $this, action) {
if ($this == null) dart.nullFailed(I[109], 151, 8, "#this");
if (action == null) dart.nullFailed(I[109], 151, 46, "action");
for (let element of $this) {
if (!dart.test(action(element))) break;
}
};
iterable_extensions['IterableExtension|get#forEachWhile'] = function IterableExtension$124get$35forEachWhile(T, $this) {
if ($this == null) dart.nullFailed(I[109], 151, 8, "#this");
return dart.fn(action => {
if (action == null) dart.nullFailed(I[109], 151, 46, "action");
return iterable_extensions['IterableExtension|forEachWhile'](T, $this, action);
}, dart.fnType(dart.void, [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|forEachIndexedWhile'] = function IterableExtension$124forEachIndexedWhile(T, $this, action) {
let t53;
if ($this == null) dart.nullFailed(I[109], 162, 8, "#this");
if (action == null) dart.nullFailed(I[109], 162, 64, "action");
let index = 0;
for (let element of $this) {
if (!dart.test(action((t53 = index, index = t53 + 1, t53), element))) break;
}
};
iterable_extensions['IterableExtension|get#forEachIndexedWhile'] = function IterableExtension$124get$35forEachIndexedWhile(T, $this) {
if ($this == null) dart.nullFailed(I[109], 162, 8, "#this");
return dart.fn(action => {
if (action == null) dart.nullFailed(I[109], 162, 64, "action");
return iterable_extensions['IterableExtension|forEachIndexedWhile'](T, $this, action);
}, dart.fnType(dart.void, [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|mapIndexed'] = function IterableExtension$124mapIndexed(T, R, $this, convert) {
if ($this == null) dart.nullFailed(I[109], 170, 15, "#this");
if (convert == null) dart.nullFailed(I[109], 170, 62, "convert");
return new (_js_helper.SyncIterable$(R)).new(function* IterableExtension$124mapIndexed() {
let t55;
let index = 0;
for (let element of $this) {
yield convert((t55 = index, index = t55 + 1, t55), element);
}
});
};
iterable_extensions['IterableExtension|get#mapIndexed'] = function IterableExtension$124get$35mapIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 170, 15, "#this");
return dart.fn((R, convert) => {
if (convert == null) dart.nullFailed(I[109], 170, 62, "convert");
return iterable_extensions['IterableExtension|mapIndexed'](T, R, $this, convert);
}, dart.gFnType(R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [__t$IterableOfR(), [dart.fnType(R, [core.int, T])]];
}, R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [T$.ObjectN()];
}));
};
iterable_extensions['IterableExtension|whereIndexed'] = function IterableExtension$124whereIndexed(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 178, 15, "#this");
if (test == null) dart.nullFailed(I[109], 178, 64, "test");
return new (_js_helper.SyncIterable$(T)).new(function* IterableExtension$124whereIndexed() {
let t57;
let index = 0;
for (let element of $this) {
if (dart.test(test((t57 = index, index = t57 + 1, t57), element))) yield element;
}
});
};
iterable_extensions['IterableExtension|get#whereIndexed'] = function IterableExtension$124get$35whereIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 178, 15, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 178, 64, "test");
return iterable_extensions['IterableExtension|whereIndexed'](T, $this, test);
}, dart.fnType(core.Iterable$(T), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|whereNotIndexed'] = function IterableExtension$124whereNotIndexed(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 186, 15, "#this");
if (test == null) dart.nullFailed(I[109], 186, 67, "test");
return new (_js_helper.SyncIterable$(T)).new(function* IterableExtension$124whereNotIndexed() {
let t59;
let index = 0;
for (let element of $this) {
if (!dart.test(test((t59 = index, index = t59 + 1, t59), element))) yield element;
}
});
};
iterable_extensions['IterableExtension|get#whereNotIndexed'] = function IterableExtension$124get$35whereNotIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 186, 15, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 186, 67, "test");
return iterable_extensions['IterableExtension|whereNotIndexed'](T, $this, test);
}, dart.fnType(core.Iterable$(T), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|get#expandIndexed'] = function IterableExtension$124get$35expandIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 194, 15, "#this");
return dart.fn((R, expend) => {
if (expend == null) dart.nullFailed(I[109], 195, 50, "expend");
return iterable_extensions['IterableExtension|expandIndexed'](T, R, $this, expend);
}, dart.gFnType(R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [__t$IterableOfR(), [dart.fnType(__t$IterableOfR(), [core.int, T])]];
}, R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [T$.ObjectN()];
}));
};
iterable_extensions['IterableExtension|expandIndexed'] = function IterableExtension$124expandIndexed(T, R, $this, expend) {
if ($this == null) dart.nullFailed(I[109], 194, 15, "#this");
if (expend == null) dart.nullFailed(I[109], 195, 50, "expend");
return new (_js_helper.SyncIterable$(R)).new(function* IterableExtension$124expandIndexed() {
let t62;
let index = 0;
for (let element of $this) {
yield* expend((t62 = index, index = t62 + 1, t62), element);
}
});
};
iterable_extensions['IterableExtension|reduceIndexed'] = function IterableExtension$124reduceIndexed(T, $this, combine) {
let t63;
if ($this == null) dart.nullFailed(I[109], 212, 5, "#this");
if (combine == null) dart.nullFailed(I[109], 212, 64, "combine");
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) {
dart.throw(new core.StateError.new("no elements"));
}
let index = 1;
let result = iterator.current;
while (dart.test(iterator.moveNext())) {
result = combine((t63 = index, index = t63 + 1, t63), result, iterator.current);
}
return result;
};
iterable_extensions['IterableExtension|get#reduceIndexed'] = function IterableExtension$124get$35reduceIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 212, 5, "#this");
return dart.fn(combine => {
if (combine == null) dart.nullFailed(I[109], 212, 64, "combine");
return iterable_extensions['IterableExtension|reduceIndexed'](T, $this, combine);
}, dart.fnType(T, [dart.fnType(T, [core.int, T, T])]));
};
iterable_extensions['IterableExtension|foldIndexed'] = function IterableExtension$124foldIndexed(T, R, $this, initialValue, combine) {
let t65;
if ($this == null) dart.nullFailed(I[109], 233, 5, "#this");
if (combine == null) dart.nullFailed(I[109], 234, 68, "combine");
let result = initialValue;
let index = 0;
for (let element of $this) {
result = combine((t65 = index, index = t65 + 1, t65), result, element);
}
return result;
};
iterable_extensions['IterableExtension|get#foldIndexed'] = function IterableExtension$124get$35foldIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 233, 5, "#this");
return dart.fn((R, initialValue, combine) => {
if (combine == null) dart.nullFailed(I[109], 234, 68, "combine");
return iterable_extensions['IterableExtension|foldIndexed'](T, R, $this, initialValue, combine);
}, dart.gFnType(R => [R, [R, dart.fnType(R, [core.int, R, T])]], R => [T$.ObjectN()]));
};
iterable_extensions['IterableExtension|firstWhereOrNull'] = function IterableExtension$124firstWhereOrNull(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 244, 6, "#this");
if (test == null) dart.nullFailed(I[109], 244, 48, "test");
for (let element of $this) {
if (dart.test(test(element))) return element;
}
return null;
};
iterable_extensions['IterableExtension|get#firstWhereOrNull'] = function IterableExtension$124get$35firstWhereOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 244, 6, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 244, 48, "test");
return iterable_extensions['IterableExtension|firstWhereOrNull'](T, $this, test);
}, dart.fnType(dart.nullable(T), [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|firstWhereIndexedOrNull'] = function IterableExtension$124firstWhereIndexedOrNull(T, $this, test) {
let t69;
if ($this == null) dart.nullFailed(I[109], 254, 6, "#this");
if (test == null) dart.nullFailed(I[109], 254, 66, "test");
let index = 0;
for (let element of $this) {
if (dart.test(test((t69 = index, index = t69 + 1, t69), element))) return element;
}
return null;
};
iterable_extensions['IterableExtension|get#firstWhereIndexedOrNull'] = function IterableExtension$124get$35firstWhereIndexedOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 254, 6, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 254, 66, "test");
return iterable_extensions['IterableExtension|firstWhereIndexedOrNull'](T, $this, test);
}, dart.fnType(dart.nullable(T), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|get#firstOrNull'] = function IterableExtension$124get$35firstOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 263, 10, "#this");
let iterator = $this[S$.$iterator];
if (dart.test(iterator.moveNext())) return iterator.current;
return null;
};
iterable_extensions['IterableExtension|lastWhereOrNull'] = function IterableExtension$124lastWhereOrNull(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 270, 6, "#this");
if (test == null) dart.nullFailed(I[109], 270, 47, "test");
let result = null;
for (let element of $this) {
if (dart.test(test(element))) result = element;
}
return result;
};
iterable_extensions['IterableExtension|get#lastWhereOrNull'] = function IterableExtension$124get$35lastWhereOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 270, 6, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 270, 47, "test");
return iterable_extensions['IterableExtension|lastWhereOrNull'](T, $this, test);
}, dart.fnType(dart.nullable(T), [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|lastWhereIndexedOrNull'] = function IterableExtension$124lastWhereIndexedOrNull(T, $this, test) {
let t74;
if ($this == null) dart.nullFailed(I[109], 281, 6, "#this");
if (test == null) dart.nullFailed(I[109], 281, 65, "test");
let result = null;
let index = 0;
for (let element of $this) {
if (dart.test(test((t74 = index, index = t74 + 1, t74), element))) result = element;
}
return result;
};
iterable_extensions['IterableExtension|get#lastWhereIndexedOrNull'] = function IterableExtension$124get$35lastWhereIndexedOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 281, 6, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 281, 65, "test");
return iterable_extensions['IterableExtension|lastWhereIndexedOrNull'](T, $this, test);
}, dart.fnType(dart.nullable(T), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|get#lastOrNull'] = function IterableExtension$124get$35lastOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 291, 10, "#this");
if (dart.test($this[S$.$isEmpty])) return null;
return $this[S$.$last];
};
iterable_extensions['IterableExtension|singleWhereOrNull'] = function IterableExtension$124singleWhereOrNull(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 304, 6, "#this");
if (test == null) dart.nullFailed(I[109], 304, 49, "test");
let result = null;
let found = false;
for (let element of $this) {
if (dart.test(test(element))) {
if (!found) {
result = element;
found = true;
} else {
return null;
}
}
}
return result;
};
iterable_extensions['IterableExtension|get#singleWhereOrNull'] = function IterableExtension$124get$35singleWhereOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 304, 6, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 304, 49, "test");
return iterable_extensions['IterableExtension|singleWhereOrNull'](T, $this, test);
}, dart.fnType(dart.nullable(T), [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|singleWhereIndexedOrNull'] = function IterableExtension$124singleWhereIndexedOrNull(T, $this, test) {
let t79;
if ($this == null) dart.nullFailed(I[109], 324, 6, "#this");
if (test == null) dart.nullFailed(I[109], 324, 67, "test");
let result = null;
let found = false;
let index = 0;
for (let element of $this) {
if (dart.test(test((t79 = index, index = t79 + 1, t79), element))) {
if (!found) {
result = element;
found = true;
} else {
return null;
}
}
}
return result;
};
iterable_extensions['IterableExtension|get#singleWhereIndexedOrNull'] = function IterableExtension$124get$35singleWhereIndexedOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 324, 6, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 324, 67, "test");
return iterable_extensions['IterableExtension|singleWhereIndexedOrNull'](T, $this, test);
}, dart.fnType(dart.nullable(T), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|get#singleOrNull'] = function IterableExtension$124get$35singleOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 345, 10, "#this");
let iterator = $this[S$.$iterator];
if (dart.test(iterator.moveNext())) {
let result = iterator.current;
if (!dart.test(iterator.moveNext())) {
return result;
}
}
return null;
};
iterable_extensions['IterableExtension|groupFoldBy'] = function IterableExtension$124groupFoldBy(T, K, G, $this, keyOf, combine) {
if ($this == null) dart.nullFailed(I[109], 369, 13, "#this");
if (keyOf == null) dart.nullFailed(I[109], 370, 29, "keyOf");
if (combine == null) dart.nullFailed(I[109], 370, 71, "combine");
let result = new (_js_helper.LinkedMap$(K, G)).new();
for (let element of $this) {
let key = keyOf(element);
result[S$.$_set](key, combine(result[S$.$_get](key), element));
}
return result;
};
iterable_extensions['IterableExtension|get#groupFoldBy'] = function IterableExtension$124get$35groupFoldBy(T, $this) {
if ($this == null) dart.nullFailed(I[109], 369, 13, "#this");
return dart.fn((K, G, keyOf, combine) => {
if (keyOf == null) dart.nullFailed(I[109], 370, 29, "keyOf");
if (combine == null) dart.nullFailed(I[109], 370, 71, "combine");
return iterable_extensions['IterableExtension|groupFoldBy'](T, K, G, $this, keyOf, combine);
}, dart.gFnType((K, G) => {
var __t$MapOfK$G = () => (__t$MapOfK$G = dart.constFn(core.Map$(K, G)))();
var __t$GN = () => (__t$GN = dart.constFn(dart.nullable(G)))();
return [__t$MapOfK$G(), [dart.fnType(K, [T]), dart.fnType(G, [__t$GN(), T])]];
}, (K, G) => {
var __t$MapOfK$G = () => (__t$MapOfK$G = dart.constFn(core.Map$(K, G)))();
var __t$GN = () => (__t$GN = dart.constFn(dart.nullable(G)))();
return [T$.ObjectN(), T$.ObjectN()];
}));
};
iterable_extensions['IterableExtension|groupSetsBy'] = function IterableExtension$124groupSetsBy(T, K, $this, keyOf) {
let t87, t86, t85, t84, t84$;
if ($this == null) dart.nullFailed(I[109], 380, 18, "#this");
if (keyOf == null) dart.nullFailed(I[109], 380, 55, "keyOf");
let result = new (_js_helper.LinkedMap$(K, core.Set$(T))).new();
for (let element of $this) {
t84$ = (t84 = result, t85 = keyOf(element), t86 = t84[S$.$_get](t85), t86 == null ? (t87 = collection.LinkedHashSet$(T).new(), t84[S$.$_set](t85, t87), t87) : t86);
(() => {
t84$.add(element);
return t84$;
})();
}
return result;
};
iterable_extensions['IterableExtension|get#groupSetsBy'] = function IterableExtension$124get$35groupSetsBy(T, $this) {
if ($this == null) dart.nullFailed(I[109], 380, 18, "#this");
return dart.fn((K, keyOf) => {
if (keyOf == null) dart.nullFailed(I[109], 380, 55, "keyOf");
return iterable_extensions['IterableExtension|groupSetsBy'](T, K, $this, keyOf);
}, dart.gFnType(K => [core.Map$(K, core.Set$(T)), [dart.fnType(K, [T])]], K => [T$.ObjectN()]));
};
iterable_extensions['IterableExtension|groupListsBy'] = function IterableExtension$124groupListsBy(T, K, $this, keyOf) {
let t89, t88, t87, t86, t86$;
if ($this == null) dart.nullFailed(I[109], 389, 19, "#this");
if (keyOf == null) dart.nullFailed(I[109], 389, 57, "keyOf");
let result = new (_js_helper.LinkedMap$(K, core.List$(T))).new();
for (let element of $this) {
t86$ = (t86 = result, t87 = keyOf(element), t88 = t86[S$.$_get](t87), t88 == null ? (t89 = _interceptors.JSArray$(T).of([]), t86[S$.$_set](t87, t89), t89) : t88);
(() => {
t86$[S$.$add](element);
return t86$;
})();
}
return result;
};
iterable_extensions['IterableExtension|get#groupListsBy'] = function IterableExtension$124get$35groupListsBy(T, $this) {
if ($this == null) dart.nullFailed(I[109], 389, 19, "#this");
return dart.fn((K, keyOf) => {
if (keyOf == null) dart.nullFailed(I[109], 389, 57, "keyOf");
return iterable_extensions['IterableExtension|groupListsBy'](T, K, $this, keyOf);
}, dart.gFnType(K => [core.Map$(K, core.List$(T)), [dart.fnType(K, [T])]], K => [T$.ObjectN()]));
};
iterable_extensions['IterableExtension|splitBefore'] = function IterableExtension$124splitBefore(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 411, 21, "#this");
if (test == null) dart.nullFailed(I[109], 411, 58, "test");
return iterable_extensions['IterableExtension|splitBeforeIndexed'](T, $this, dart.fn((_, element) => {
if (_ == null) dart.nullFailed(I[109], 412, 27, "_");
return test(element);
}, dart.fnType(core.bool, [core.int, T])));
};
iterable_extensions['IterableExtension|get#splitBefore'] = function IterableExtension$124get$35splitBefore(T, $this) {
if ($this == null) dart.nullFailed(I[109], 411, 21, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 411, 58, "test");
return iterable_extensions['IterableExtension|splitBefore'](T, $this, test);
}, dart.fnType(core.Iterable$(core.List$(T)), [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|splitAfter'] = function IterableExtension$124splitAfter(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 426, 21, "#this");
if (test == null) dart.nullFailed(I[109], 426, 57, "test");
return iterable_extensions['IterableExtension|splitAfterIndexed'](T, $this, dart.fn((_, element) => {
if (_ == null) dart.nullFailed(I[109], 427, 26, "_");
return test(element);
}, dart.fnType(core.bool, [core.int, T])));
};
iterable_extensions['IterableExtension|get#splitAfter'] = function IterableExtension$124get$35splitAfter(T, $this) {
if ($this == null) dart.nullFailed(I[109], 426, 21, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 426, 57, "test");
return iterable_extensions['IterableExtension|splitAfter'](T, $this, test);
}, dart.fnType(core.Iterable$(core.List$(T)), [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableExtension|get#splitBetween'] = function IterableExtension$124get$35splitBetween(T, $this) {
if ($this == null) dart.nullFailed(I[109], 442, 21, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 442, 67, "test");
return iterable_extensions['IterableExtension|splitBetween'](T, $this, test);
}, dart.fnType(core.Iterable$(core.List$(T)), [dart.fnType(core.bool, [T, T])]));
};
iterable_extensions['IterableExtension|splitBetween'] = function IterableExtension$124splitBetween(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 442, 21, "#this");
if (test == null) dart.nullFailed(I[109], 442, 67, "test");
return iterable_extensions['IterableExtension|splitBetweenIndexed'](T, $this, dart.fn((_, first, second) => {
if (_ == null) dart.nullFailed(I[109], 443, 28, "_");
return test(first, second);
}, dart.fnType(core.bool, [core.int, T, T])));
};
iterable_extensions['IterableExtension|splitBeforeIndexed'] = function IterableExtension$124splitBeforeIndexed(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 459, 21, "#this");
if (test == null) dart.nullFailed(I[109], 460, 43, "test");
return new (_js_helper.SyncIterable$(core.List$(T))).new(function* IterableExtension$124splitBeforeIndexed() {
let t94;
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) {
return;
}
let index = 1;
let chunk = _interceptors.JSArray$(T).of([iterator.current]);
while (dart.test(iterator.moveNext())) {
let element = iterator.current;
if (dart.test(test((t94 = index, index = t94 + 1, t94), element))) {
yield chunk;
chunk = _interceptors.JSArray$(T).of([]);
}
chunk[S$.$add](element);
}
yield chunk;
});
};
iterable_extensions['IterableExtension|get#splitBeforeIndexed'] = function IterableExtension$124get$35splitBeforeIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 459, 21, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 460, 43, "test");
return iterable_extensions['IterableExtension|splitBeforeIndexed'](T, $this, test);
}, dart.fnType(core.Iterable$(core.List$(T)), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|splitAfterIndexed'] = function IterableExtension$124splitAfterIndexed(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 492, 21, "#this");
if (test == null) dart.nullFailed(I[109], 493, 43, "test");
return new (_js_helper.SyncIterable$(core.List$(T))).new(function* IterableExtension$124splitAfterIndexed() {
let t96, t96$;
let index = 0;
let chunk = null;
for (let element of $this) {
(t96 = chunk, t96 == null ? chunk = _interceptors.JSArray$(T).of([]) : t96)[S$.$add](element);
if (dart.test(test((t96$ = index, index = t96$ + 1, t96$), element))) {
yield chunk;
chunk = null;
}
}
if (chunk != null) yield chunk;
});
};
iterable_extensions['IterableExtension|get#splitAfterIndexed'] = function IterableExtension$124get$35splitAfterIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 492, 21, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 493, 43, "test");
return iterable_extensions['IterableExtension|splitAfterIndexed'](T, $this, test);
}, dart.fnType(core.Iterable$(core.List$(T)), [dart.fnType(core.bool, [core.int, T])]));
};
iterable_extensions['IterableExtension|splitBetweenIndexed'] = function IterableExtension$124splitBetweenIndexed(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 520, 21, "#this");
if (test == null) dart.nullFailed(I[109], 521, 51, "test");
return new (_js_helper.SyncIterable$(core.List$(T))).new(function* IterableExtension$124splitBetweenIndexed() {
let t98;
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) return;
let previous = iterator.current;
let chunk = _interceptors.JSArray$(T).of([previous]);
let index = 1;
while (dart.test(iterator.moveNext())) {
let element = iterator.current;
if (dart.test(test((t98 = index, index = t98 + 1, t98), previous, element))) {
yield chunk;
chunk = _interceptors.JSArray$(T).of([]);
}
chunk[S$.$add](element);
previous = element;
}
yield chunk;
});
};
iterable_extensions['IterableExtension|get#splitBetweenIndexed'] = function IterableExtension$124get$35splitBetweenIndexed(T, $this) {
if ($this == null) dart.nullFailed(I[109], 520, 21, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 521, 51, "test");
return iterable_extensions['IterableExtension|splitBetweenIndexed'](T, $this, test);
}, dart.fnType(core.Iterable$(core.List$(T)), [dart.fnType(core.bool, [core.int, T, T])]));
};
iterable_extensions['IterableExtension|none'] = function IterableExtension$124none(T, $this, test) {
if ($this == null) dart.nullFailed(I[109], 546, 8, "#this");
if (test == null) dart.nullFailed(I[109], 546, 30, "test");
for (let element of $this) {
if (dart.test(test(element))) return false;
}
return true;
};
iterable_extensions['IterableExtension|get#none'] = function IterableExtension$124get$35none(T, $this) {
if ($this == null) dart.nullFailed(I[109], 546, 8, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[109], 546, 30, "test");
return iterable_extensions['IterableExtension|none'](T, $this, test);
}, dart.fnType(core.bool, [dart.fnType(core.bool, [T])]));
};
iterable_extensions['IterableNullableExtension|whereNotNull'] = function IterableNullableExtension$124whereNotNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 562, 15, "#this");
return new (_js_helper.SyncIterable$(T)).new(function* IterableNullableExtension$124whereNotNull() {
for (let element of $this) {
if (element != null) yield element;
}
});
};
iterable_extensions['IterableNullableExtension|get#whereNotNull'] = function IterableNullableExtension$124get$35whereNotNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 562, 15, "#this");
return dart.fn(() => iterable_extensions['IterableNullableExtension|whereNotNull'](T, $this), dart.fnType(core.Iterable$(T), []));
};
iterable_extensions['IterableNumberExtension|get#sum'] = function IterableNumberExtension$124get$35sum($this) {
if ($this == null) dart.nullFailed(I[109], 574, 11, "#this");
let result = 0;
for (let value of $this) {
result = result + dart.notNull(value);
}
return result;
};
iterable_extensions['IterableNumberExtension|get#average'] = function IterableNumberExtension$124get$35average($this) {
if ($this == null) dart.nullFailed(I[109], 588, 14, "#this");
let result = 0.0;
let count = 0;
for (let value of $this) {
count = count + 1;
result = result + (dart.notNull(value) - result) / count;
}
if (count === 0) dart.throw(new core.StateError.new("No elements"));
return result;
};
iterable_extensions['IterableIntegerExtension|get#sum'] = function IterableIntegerExtension$124get$35sum($this) {
if ($this == null) dart.nullFailed(I[109], 607, 11, "#this");
let result = 0;
for (let value of $this) {
result = result + dart.notNull(value);
}
return result;
};
iterable_extensions['IterableIntegerExtension|get#average'] = function IterableIntegerExtension$124get$35average($this) {
if ($this == null) dart.nullFailed(I[109], 625, 14, "#this");
let average = 0;
let remainder = 0;
let count = 0;
for (let value of $this) {
count = count + 1;
let delta = dart.notNull(value) - average + remainder;
average = average + (delta / count)[S$.$truncate]();
remainder = delta[S$.$remainder](count);
}
if (count === 0) dart.throw(new core.StateError.new("No elements"));
return average + remainder / count;
};
iterable_extensions['IterableDoubleExtension|get#sum'] = function IterableDoubleExtension$124get$35sum($this) {
if ($this == null) dart.nullFailed(I[109], 649, 14, "#this");
let result = 0.0;
for (let value of $this) {
result = result + dart.notNull(value);
}
return result;
};
iterable_extensions['IterableIterableExtension|get#flattened'] = function IterableIterableExtension$124get$35flattened(T, $this) {
if ($this == null) dart.nullFailed(I[109], 666, 19, "#this");
return new (_js_helper.SyncIterable$(T)).new(function* IterableIterableExtension$124get$35flattened() {
for (let elements of $this) {
yield* elements;
}
});
};
iterable_extensions['IterableComparableExtension|get#minOrNull'] = function IterableComparableExtension$124get$35minOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 680, 10, "#this");
let iterator = $this[S$.$iterator];
if (dart.test(iterator.moveNext())) {
let value = iterator.current;
while (dart.test(iterator.moveNext())) {
let newValue = iterator.current;
if (dart.notNull(value[S$.$compareTo](newValue)) > 0) {
value = newValue;
}
}
return value;
}
return null;
};
iterable_extensions['IterableComparableExtension|get#min'] = function IterableComparableExtension$124get$35min(T, $this) {
if ($this == null) dart.nullFailed(I[109], 698, 9, "#this");
let iterator = $this[S$.$iterator];
if (dart.test(iterator.moveNext())) {
let value = iterator.current;
while (dart.test(iterator.moveNext())) {
let newValue = iterator.current;
if (dart.notNull(value[S$.$compareTo](newValue)) > 0) {
value = newValue;
}
}
return value;
}
dart.throw(new core.StateError.new("No element"));
};
iterable_extensions['IterableComparableExtension|get#maxOrNull'] = function IterableComparableExtension$124get$35maxOrNull(T, $this) {
if ($this == null) dart.nullFailed(I[109], 714, 10, "#this");
let iterator = $this[S$.$iterator];
if (dart.test(iterator.moveNext())) {
let value = iterator.current;
while (dart.test(iterator.moveNext())) {
let newValue = iterator.current;
if (dart.notNull(value[S$.$compareTo](newValue)) < 0) {
value = newValue;
}
}
return value;
}
return null;
};
iterable_extensions['IterableComparableExtension|get#max'] = function IterableComparableExtension$124get$35max(T, $this) {
if ($this == null) dart.nullFailed(I[109], 732, 9, "#this");
let iterator = $this[S$.$iterator];
if (dart.test(iterator.moveNext())) {
let value = iterator.current;
while (dart.test(iterator.moveNext())) {
let newValue = iterator.current;
if (dart.notNull(value[S$.$compareTo](newValue)) < 0) {
value = newValue;
}
}
return value;
}
dart.throw(new core.StateError.new("No element"));
};
iterable_extensions['IterableComparableExtension|sorted'] = function IterableComparableExtension$124sorted(T, $this, compare = null) {
let t115;
if ($this == null) dart.nullFailed(I[109], 751, 11, "#this");
t115 = (() => {
let t114 = core.List$(T).of($this);
return t114;
})();
return (() => {
t115[S$.$sort](compare);
return t115;
})();
};
iterable_extensions['IterableComparableExtension|get#sorted'] = function IterableComparableExtension$124get$35sorted(T, $this) {
if ($this == null) dart.nullFailed(I[109], 751, 11, "#this");
return dart.fn((compare = null) => iterable_extensions['IterableComparableExtension|sorted'](T, $this, compare), dart.fnType(core.List$(T), [], [dart.nullable(dart.fnType(core.int, [T, T]))]));
};
iterable_extensions['IterableComparableExtension|isSorted'] = function IterableComparableExtension$124isSorted(T, $this, compare = null) {
if ($this == null) dart.nullFailed(I[109], 757, 8, "#this");
if (compare != null) {
return iterable_extensions['IterableExtension|isSorted'](T, $this, compare);
}
let iterator = $this[S$.$iterator];
if (!dart.test(iterator.moveNext())) return true;
let previousElement = iterator.current;
while (dart.test(iterator.moveNext())) {
let element = iterator.current;
if (dart.notNull(previousElement[S$.$compareTo](element)) > 0) return false;
previousElement = element;
}
return true;
};
iterable_extensions['IterableComparableExtension|get#isSorted'] = function IterableComparableExtension$124get$35isSorted(T, $this) {
if ($this == null) dart.nullFailed(I[109], 757, 8, "#this");
return dart.fn((compare = null) => iterable_extensions['IterableComparableExtension|isSorted'](T, $this, compare), dart.fnType(core.bool, [], [dart.nullable(dart.fnType(core.int, [T, T]))]));
};
iterable_extensions['ComparatorExtension|get#inverse'] = function ComparatorExtension$124get$35inverse(T, $this) {
if ($this == null) dart.nullFailed(I[109], 776, 21, "#this");
return dart.fn((a, b) => $this(b, a), dart.fnType(core.int, [T, T]));
};
iterable_extensions['ComparatorExtension|compareBy'] = function ComparatorExtension$124compareBy(T, R, $this, keyOf) {
if ($this == null) dart.nullFailed(I[109], 782, 17, "#this");
if (keyOf == null) dart.nullFailed(I[109], 782, 44, "keyOf");
return dart.fn((a, b) => $this(keyOf(a), keyOf(b)), dart.fnType(core.int, [R, R]));
};
iterable_extensions['ComparatorExtension|get#compareBy'] = function ComparatorExtension$124get$35compareBy(T, $this) {
if ($this == null) dart.nullFailed(I[109], 782, 17, "#this");
return dart.fn((R, keyOf) => {
if (keyOf == null) dart.nullFailed(I[109], 782, 44, "keyOf");
return iterable_extensions['ComparatorExtension|compareBy'](T, R, $this, keyOf);
}, dart.gFnType(R => {
var __t$RAndRToint = () => (__t$RAndRToint = dart.constFn(dart.fnType(core.int, [R, R])))();
return [__t$RAndRToint(), [dart.fnType(T, [R])]];
}, R => {
var __t$RAndRToint = () => (__t$RAndRToint = dart.constFn(dart.fnType(core.int, [R, R])))();
return [T$.ObjectN()];
}));
};
iterable_extensions['ComparatorExtension|then'] = function ComparatorExtension$124then(T, $this, tieBreaker) {
if ($this == null) dart.nullFailed(I[109], 790, 17, "#this");
if (tieBreaker == null) dart.nullFailed(I[109], 790, 36, "tieBreaker");
return dart.fn((a, b) => {
let result = $this(a, b);
if (result === 0) result = tieBreaker(a, b);
return result;
}, dart.fnType(core.int, [T, T]));
};
iterable_extensions['ComparatorExtension|get#then'] = function ComparatorExtension$124get$35then(T, $this) {
if ($this == null) dart.nullFailed(I[109], 790, 17, "#this");
return dart.fn(tieBreaker => {
if (tieBreaker == null) dart.nullFailed(I[109], 790, 36, "tieBreaker");
return iterable_extensions['ComparatorExtension|then'](T, $this, tieBreaker);
}, dart.fnType(dart.fnType(core.int, [T, T]), [dart.fnType(core.int, [T, T])]));
};
const _is_IterableZip_default = Symbol('_is_IterableZip_default');
iterable_zip.IterableZip$ = dart.generic(T => {
var __t$IteratorOfT = () => (__t$IteratorOfT = dart.constFn(core.Iterator$(T)))();
var __t$IterableOfT = () => (__t$IterableOfT = dart.constFn(core.Iterable$(T)))();
var __t$IterableOfTToIteratorOfT = () => (__t$IterableOfTToIteratorOfT = dart.constFn(dart.fnType(__t$IteratorOfT(), [__t$IterableOfT()])))();
var __t$_IteratorZipOfT = () => (__t$_IteratorZipOfT = dart.constFn(iterable_zip._IteratorZip$(T)))();
class IterableZip extends collection.IterableBase$(core.List$(T)) {
static ['_#new#tearOff'](T, iterables) {
if (iterables == null) dart.nullFailed(I[110], 19, 37, "iterables");
return new (iterable_zip.IterableZip$(T)).new(iterables);
}
get iterator() {
let iterators = this[S$._iterables$2][S$.$map](__t$IteratorOfT(), dart.fn(x => {
if (x == null) dart.nullFailed(I[110], 25, 37, "x");
return x[S$.$iterator];
}, __t$IterableOfTToIteratorOfT()))[S$.$toList]({growable: false});
return new (__t$_IteratorZipOfT()).new(iterators);
}
}
(IterableZip.new = function(iterables) {
if (iterables == null) dart.nullFailed(I[110], 19, 37, "iterables");
this[S$._iterables$2] = iterables;
IterableZip.__proto__.new.call(this);
;
}).prototype = IterableZip.prototype;
dart.addTypeTests(IterableZip);
IterableZip.prototype[_is_IterableZip_default] = true;
dart.addTypeCaches(IterableZip);
dart.setGetterSignature(IterableZip, () => ({
__proto__: dart.getGetters(IterableZip.__proto__),
iterator: core.Iterator$(core.List$(T)),
[S$.$iterator]: core.Iterator$(core.List$(T))
}));
dart.setLibraryUri(IterableZip, I[111]);
dart.setFieldSignature(IterableZip, () => ({
__proto__: dart.getFields(IterableZip.__proto__),
[S$._iterables$2]: dart.finalFieldType(core.Iterable$(core.Iterable$(T)))
}));
dart.defineExtensionAccessors(IterableZip, ['iterator']);
return IterableZip;
});
iterable_zip.IterableZip = iterable_zip.IterableZip$();
dart.addTypeTests(iterable_zip.IterableZip, _is_IterableZip_default);
const _is__IteratorZip_default = Symbol('_is__IteratorZip_default');
iterable_zip._IteratorZip$ = dart.generic(T => {
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$intToT = () => (__t$intToT = dart.constFn(dart.fnType(T, [core.int])))();
class _IteratorZip extends core.Object {
static ['_#new#tearOff'](T, iterators) {
if (iterators == null) dart.nullFailed(I[110], 34, 34, "iterators");
return new (iterable_zip._IteratorZip$(T)).new(iterators);
}
moveNext() {
if (dart.test(this[S$._iterators][S$.$isEmpty])) return false;
for (let i = 0; i < dart.notNull(this[S$._iterators][S$.$length]); i = i + 1) {
if (!dart.test(this[S$._iterators][S$.$_get](i).moveNext())) {
this[S$._current] = null;
return false;
}
}
this[S$._current] = __t$ListOfT().generate(this[S$._iterators][S$.$length], dart.fn(i => {
if (i == null) dart.nullFailed(I[110], 45, 50, "i");
return this[S$._iterators][S$.$_get](i).current;
}, __t$intToT()), {growable: false});
return true;
}
get current() {
let t123;
t123 = this[S$._current];
return t123 == null ? dart.throw(new core.StateError.new("No element")) : t123;
}
}
(_IteratorZip.new = function(iterators) {
if (iterators == null) dart.nullFailed(I[110], 34, 34, "iterators");
this[S$._current] = null;
this[S$._iterators] = iterators;
;
}).prototype = _IteratorZip.prototype;
dart.addTypeTests(_IteratorZip);
_IteratorZip.prototype[_is__IteratorZip_default] = true;
dart.addTypeCaches(_IteratorZip);
_IteratorZip[dart.implements] = () => [core.Iterator$(core.List$(T))];
dart.setMethodSignature(_IteratorZip, () => ({
__proto__: dart.getMethods(_IteratorZip.__proto__),
moveNext: dart.fnType(core.bool, [])
}));
dart.setGetterSignature(_IteratorZip, () => ({
__proto__: dart.getGetters(_IteratorZip.__proto__),
current: core.List$(T)
}));
dart.setLibraryUri(_IteratorZip, I[111]);
dart.setFieldSignature(_IteratorZip, () => ({
__proto__: dart.getFields(_IteratorZip.__proto__),
[S$._iterators]: dart.finalFieldType(core.List$(core.Iterator$(T))),
[S$._current]: dart.fieldType(dart.nullable(core.List$(T)))
}));
return _IteratorZip;
});
iterable_zip._IteratorZip = iterable_zip._IteratorZip$();
dart.addTypeTests(iterable_zip._IteratorZip, _is__IteratorZip_default);
const _is_ListSlice_default = Symbol('_is_ListSlice_default');
list_extensions.ListSlice$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$ListSliceOfE = () => (__t$ListSliceOfE = dart.constFn(list_extensions.ListSlice$(E)))();
class ListSlice extends collection.ListBase$(E) {
get source() {
return this[S$.source$1];
}
set source(value) {
super.source = value;
}
get start() {
return this[S$.start];
}
set start(value) {
super.start = value;
}
get length() {
return this[S$.length];
}
set length(value) {
super.length = value;
}
static ['_#new#tearOff'](E, source, start, end) {
if (source == null) dart.nullFailed(I[112], 318, 18, "source");
if (start == null) dart.nullFailed(I[112], 318, 31, "start");
if (end == null) dart.nullFailed(I[112], 318, 42, "end");
return new (list_extensions.ListSlice$(E)).new(source, start, end);
}
static ['_#_#tearOff'](E, _initialSize, source, start, length) {
if (_initialSize == null) dart.nullFailed(I[112], 325, 20, "_initialSize");
if (source == null) dart.nullFailed(I[112], 325, 39, "source");
if (start == null) dart.nullFailed(I[112], 325, 52, "start");
if (length == null) dart.nullFailed(I[112], 325, 64, "length");
return new (list_extensions.ListSlice$(E)).__(_initialSize, source, start, length);
}
get end() {
return dart.notNull(this.start) + dart.notNull(this.length);
}
_get(index) {
if (index == null) dart.nullFailed(I[112], 331, 21, "index");
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
core.RangeError.checkValidIndex(index, this, null, this.length);
return this.source[S$.$_get](dart.notNull(this.start) + dart.notNull(index));
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[112], 340, 25, "index");
E.as(value);
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
core.RangeError.checkValidIndex(index, this, null, this.length);
this.source[S$.$_set](dart.notNull(this.start) + dart.notNull(index), value);
return value$;
}
setRange(start, end, iterable, skipCount = 0) {
if (start == null) dart.nullFailed(I[112], 349, 21, "start");
if (end == null) dart.nullFailed(I[112], 349, 32, "end");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[112], 349, 49, "iterable");
if (skipCount == null) dart.nullFailed(I[112], 349, 64, "skipCount");
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
core.RangeError.checkValidRange(start, end, this.length);
this.source[S$.$setRange](dart.notNull(start) + dart.notNull(start), dart.notNull(start) + dart.notNull(end), iterable, skipCount);
}
slice(start, end = null) {
if (start == null) dart.nullFailed(I[112], 369, 26, "start");
end = core.RangeError.checkValidRange(start, end, this.length);
return new (__t$ListSliceOfE()).__(this[S$._initialSize], this.source, dart.notNull(start) + dart.notNull(start), dart.notNull(end) - dart.notNull(start));
}
shuffle(random = null) {
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
algorithms.shuffle(this.source, this.start, this.end, random);
}
sort(compare = null) {
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
compare == null ? compare = C[173] || CT.C173 : null;
algorithms.quickSort(E, this.source, compare, this.start, dart.notNull(this.start) + dart.notNull(this.length));
}
sortRange(start, end, compare) {
if (start == null) dart.nullFailed(I[112], 392, 22, "start");
if (end == null) dart.nullFailed(I[112], 392, 33, "end");
if (compare == null) dart.nullFailed(I[112], 392, 61, "compare");
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
list_extensions['ListExtensions|sortRange'](E, this.source, start, end, compare);
}
shuffleRange(start, end, random = null) {
if (start == null) dart.nullFailed(I[112], 402, 25, "start");
if (end == null) dart.nullFailed(I[112], 402, 36, "end");
if (this.source[S$.$length] != this[S$._initialSize]) {
dart.throw(new core.ConcurrentModificationError.new(this.source));
}
core.RangeError.checkValidRange(start, end, this.length);
algorithms.shuffle(this.source, dart.notNull(this.start) + dart.notNull(start), dart.notNull(this.start) + dart.notNull(end), random);
}
reverseRange(start, end) {
if (start == null) dart.nullFailed(I[112], 411, 25, "start");
if (end == null) dart.nullFailed(I[112], 411, 36, "end");
core.RangeError.checkValidRange(start, end, this.length);
list_extensions['ListExtensions|reverseRange'](E, this.source, dart.notNull(this.start) + dart.notNull(start), dart.notNull(this.start) + dart.notNull(end));
}
set length(newLength) {
if (newLength == null) dart.nullFailed(I[112], 419, 18, "newLength");
dart.throw(new core.UnsupportedError.new("Cannot change the length of a fixed-length list"));
}
add(element) {
E.as(element);
dart.throw(new core.UnsupportedError.new("Cannot add to a fixed-length list"));
}
insert(index, element) {
if (index == null) dart.nullFailed(I[112], 429, 19, "index");
E.as(element);
dart.throw(new core.UnsupportedError.new("Cannot add to a fixed-length list"));
}
insertAll(index, iterable) {
if (index == null) dart.nullFailed(I[112], 434, 22, "index");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[112], 434, 41, "iterable");
dart.throw(new core.UnsupportedError.new("Cannot add to a fixed-length list"));
}
addAll(iterable) {
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[112], 439, 27, "iterable");
dart.throw(new core.UnsupportedError.new("Cannot add to a fixed-length list"));
}
remove(element) {
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[112], 449, 45, "test");
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[112], 454, 45, "test");
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
clear() {
dart.throw(new core.UnsupportedError.new("Cannot clear a fixed-length list"));
}
removeAt(index) {
if (index == null) dart.nullFailed(I[112], 464, 18, "index");
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
removeLast() {
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
removeRange(start, end) {
if (start == null) dart.nullFailed(I[112], 474, 24, "start");
if (end == null) dart.nullFailed(I[112], 474, 35, "end");
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
replaceRange(start, end, newContents) {
if (start == null) dart.nullFailed(I[112], 479, 25, "start");
if (end == null) dart.nullFailed(I[112], 479, 36, "end");
__t$IterableOfE().as(newContents);
if (newContents == null) dart.nullFailed(I[112], 479, 53, "newContents");
dart.throw(new core.UnsupportedError.new("Cannot remove from a fixed-length list"));
}
}
(ListSlice.new = function(source, start, end) {
if (source == null) dart.nullFailed(I[112], 318, 18, "source");
if (start == null) dart.nullFailed(I[112], 318, 31, "start");
if (end == null) dart.nullFailed(I[112], 318, 42, "end");
this[S$.source$1] = source;
this[S$.start] = start;
this[S$.length] = dart.notNull(end) - dart.notNull(start);
this[S$._initialSize] = source[S$.$length];
core.RangeError.checkValidRange(this.start, end, this.source[S$.$length]);
}).prototype = ListSlice.prototype;
(ListSlice.__ = function(_initialSize, source, start, length) {
if (_initialSize == null) dart.nullFailed(I[112], 325, 20, "_initialSize");
if (source == null) dart.nullFailed(I[112], 325, 39, "source");
if (start == null) dart.nullFailed(I[112], 325, 52, "start");
if (length == null) dart.nullFailed(I[112], 325, 64, "length");
this[S$._initialSize] = _initialSize;
this[S$.source$1] = source;
this[S$.start] = start;
this[S$.length] = length;
;
}).prototype = ListSlice.prototype;
dart.addTypeTests(ListSlice);
ListSlice.prototype[_is_ListSlice_default] = true;
dart.addTypeCaches(ListSlice);
dart.setMethodSignature(ListSlice, () => ({
__proto__: dart.getMethods(ListSlice.__proto__),
_get: dart.fnType(E, [core.int]),
[S$.$_get]: dart.fnType(E, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
slice: dart.fnType(list_extensions.ListSlice$(E), [core.int], [dart.nullable(core.int)]),
sortRange: dart.fnType(dart.void, [core.int, core.int, dart.fnType(core.int, [E, E])]),
shuffleRange: dart.fnType(dart.void, [core.int, core.int], [dart.nullable(math.Random)]),
reverseRange: dart.fnType(dart.void, [core.int, core.int])
}));
dart.setGetterSignature(ListSlice, () => ({
__proto__: dart.getGetters(ListSlice.__proto__),
end: core.int
}));
dart.setSetterSignature(ListSlice, () => ({
__proto__: dart.getSetters(ListSlice.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(ListSlice, I[113]);
dart.setFieldSignature(ListSlice, () => ({
__proto__: dart.getFields(ListSlice.__proto__),
[S$._initialSize]: dart.finalFieldType(core.int),
source: dart.finalFieldType(core.List$(E)),
start: dart.finalFieldType(core.int),
length: dart.finalFieldType(core.int)
}));
dart.defineExtensionMethods(ListSlice, [
'_get',
'_set',
'setRange',
'shuffle',
'sort',
'add',
'insert',
'insertAll',
'addAll',
'remove',
'removeWhere',
'retainWhere',
'clear',
'removeAt',
'removeLast',
'removeRange',
'replaceRange'
]);
dart.defineExtensionAccessors(ListSlice, ['length']);
return ListSlice;
});
list_extensions.ListSlice = list_extensions.ListSlice$();
dart.addTypeTests(list_extensions.ListSlice, _is_ListSlice_default);
list_extensions['ListExtensions|binarySearch'] = function ListExtensions$124binarySearch(E, $this, element, compare) {
if ($this == null) dart.nullFailed(I[112], 23, 7, "#this");
if (compare == null) dart.nullFailed(I[112], 23, 50, "compare");
return algorithms.binarySearchBy(E, E, $this, dart.gbind(C[174] || CT.C174, E), compare, element);
};
list_extensions['ListExtensions|get#binarySearch'] = function ListExtensions$124get$35binarySearch(E, $this) {
if ($this == null) dart.nullFailed(I[112], 23, 7, "#this");
return dart.fn((element, compare) => {
if (compare == null) dart.nullFailed(I[112], 23, 50, "compare");
return list_extensions['ListExtensions|binarySearch'](E, $this, element, compare);
}, dart.fnType(core.int, [E, dart.fnType(core.int, [E, E])]));
};
list_extensions['ListExtensions|binarySearchByCompare'] = function ListExtensions$124binarySearchByCompare(E, K, $this, element, keyOf, compare, start = 0, end = null) {
if ($this == null) dart.nullFailed(I[112], 36, 7, "#this");
if (keyOf == null) dart.nullFailed(I[112], 37, 44, "keyOf");
if (compare == null) dart.nullFailed(I[112], 37, 70, "compare");
if (start == null) dart.nullFailed(I[112], 38, 16, "start");
return algorithms.binarySearchBy(E, K, $this, keyOf, compare, element, start, end);
};
list_extensions['ListExtensions|get#binarySearchByCompare'] = function ListExtensions$124get$35binarySearchByCompare(E, $this) {
if ($this == null) dart.nullFailed(I[112], 36, 7, "#this");
return dart.fn((K, element, keyOf, compare, start = 0, end = null) => {
if (keyOf == null) dart.nullFailed(I[112], 37, 44, "keyOf");
if (compare == null) dart.nullFailed(I[112], 37, 70, "compare");
if (start == null) dart.nullFailed(I[112], 38, 16, "start");
return list_extensions['ListExtensions|binarySearchByCompare'](E, K, $this, element, keyOf, compare, start, end);
}, dart.gFnType(K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [core.int, [E, dart.fnType(K, [E]), __t$KAndKToint()], [core.int, T$.intN()]];
}, K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [T$.ObjectN()];
}));
};
list_extensions['ListExtensions|binarySearchBy'] = function ListExtensions$124binarySearchBy(E, K, $this, element, keyOf, start = 0, end = null) {
if ($this == null) dart.nullFailed(I[112], 52, 7, "#this");
if (keyOf == null) dart.nullFailed(I[112], 53, 44, "keyOf");
if (start == null) dart.nullFailed(I[112], 53, 56, "start");
return algorithms.binarySearchBy(E, K, $this, keyOf, dart.fn((a, b) => {
if (a == null) dart.nullFailed(I[112], 55, 25, "a");
if (b == null) dart.nullFailed(I[112], 55, 28, "b");
return a[S$.$compareTo](b);
}, dart.fnType(core.int, [K, K])), element, start, end);
};
list_extensions['ListExtensions|get#binarySearchBy'] = function ListExtensions$124get$35binarySearchBy(E, $this) {
if ($this == null) dart.nullFailed(I[112], 52, 7, "#this");
return dart.fn((K, element, keyOf, start = 0, end = null) => {
if (keyOf == null) dart.nullFailed(I[112], 53, 44, "keyOf");
if (start == null) dart.nullFailed(I[112], 53, 56, "start");
return list_extensions['ListExtensions|binarySearchBy'](E, K, $this, element, keyOf, start, end);
}, dart.gFnType(K => [core.int, [E, dart.fnType(K, [E])], [core.int, T$.intN()]], K => {
var __t$ComparableOfK = () => (__t$ComparableOfK = dart.constFn(core.Comparable$(K)))();
return [__t$ComparableOfK()];
}));
};
list_extensions['ListExtensions|lowerBound'] = function ListExtensions$124lowerBound(E, $this, element, compare) {
if ($this == null) dart.nullFailed(I[112], 68, 7, "#this");
if (compare == null) dart.nullFailed(I[112], 68, 48, "compare");
return algorithms.lowerBoundBy(E, E, $this, dart.gbind(C[174] || CT.C174, E), compare, element);
};
list_extensions['ListExtensions|get#lowerBound'] = function ListExtensions$124get$35lowerBound(E, $this) {
if ($this == null) dart.nullFailed(I[112], 68, 7, "#this");
return dart.fn((element, compare) => {
if (compare == null) dart.nullFailed(I[112], 68, 48, "compare");
return list_extensions['ListExtensions|lowerBound'](E, $this, element, compare);
}, dart.fnType(core.int, [E, dart.fnType(core.int, [E, E])]));
};
list_extensions['ListExtensions|lowerBoundByCompare'] = function ListExtensions$124lowerBoundByCompare(E, K, $this, element, keyOf, compare, start = 0, end = null) {
if ($this == null) dart.nullFailed(I[112], 85, 7, "#this");
if (keyOf == null) dart.nullFailed(I[112], 86, 36, "keyOf");
if (compare == null) dart.nullFailed(I[112], 86, 62, "compare");
if (start == null) dart.nullFailed(I[112], 87, 16, "start");
return algorithms.lowerBoundBy(E, K, $this, keyOf, compare, element, start, end);
};
list_extensions['ListExtensions|get#lowerBoundByCompare'] = function ListExtensions$124get$35lowerBoundByCompare(E, $this) {
if ($this == null) dart.nullFailed(I[112], 85, 7, "#this");
return dart.fn((K, element, keyOf, compare, start = 0, end = null) => {
if (keyOf == null) dart.nullFailed(I[112], 86, 36, "keyOf");
if (compare == null) dart.nullFailed(I[112], 86, 62, "compare");
if (start == null) dart.nullFailed(I[112], 87, 16, "start");
return list_extensions['ListExtensions|lowerBoundByCompare'](E, K, $this, element, keyOf, compare, start, end);
}, dart.gFnType(K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [core.int, [E, dart.fnType(K, [E]), __t$KAndKToint()], [core.int, T$.intN()]];
}, K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [T$.ObjectN()];
}));
};
list_extensions['ListExtensions|lowerBoundBy'] = function ListExtensions$124lowerBoundBy(E, K, $this, element, keyOf, start = 0, end = null) {
if ($this == null) dart.nullFailed(I[112], 105, 7, "#this");
if (keyOf == null) dart.nullFailed(I[112], 105, 70, "keyOf");
if (start == null) dart.nullFailed(I[112], 106, 16, "start");
return algorithms.lowerBoundBy(E, K, $this, keyOf, dart.gbind(C[177] || CT.C177, K), element, start, end);
};
list_extensions['ListExtensions|get#lowerBoundBy'] = function ListExtensions$124get$35lowerBoundBy(E, $this) {
if ($this == null) dart.nullFailed(I[112], 105, 7, "#this");
return dart.fn((K, element, keyOf, start = 0, end = null) => {
if (keyOf == null) dart.nullFailed(I[112], 105, 70, "keyOf");
if (start == null) dart.nullFailed(I[112], 106, 16, "start");
return list_extensions['ListExtensions|lowerBoundBy'](E, K, $this, element, keyOf, start, end);
}, dart.gFnType(K => [core.int, [E, dart.fnType(K, [E])], [core.int, T$.intN()]], K => {
var __t$ComparableOfK = () => (__t$ComparableOfK = dart.constFn(core.Comparable$(K)))();
return [__t$ComparableOfK()];
}));
};
list_extensions['ListExtensions|forEachIndexed'] = function ListExtensions$124forEachIndexed(E, $this, action) {
if ($this == null) dart.nullFailed(I[112], 114, 8, "#this");
if (action == null) dart.nullFailed(I[112], 114, 59, "action");
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
action(index, $this[S$.$_get](index));
}
};
list_extensions['ListExtensions|get#forEachIndexed'] = function ListExtensions$124get$35forEachIndexed(E, $this) {
if ($this == null) dart.nullFailed(I[112], 114, 8, "#this");
return dart.fn(action => {
if (action == null) dart.nullFailed(I[112], 114, 59, "action");
return list_extensions['ListExtensions|forEachIndexed'](E, $this, action);
}, dart.fnType(dart.void, [dart.fnType(dart.void, [core.int, E])]));
};
list_extensions['ListExtensions|get#forEachWhile'] = function ListExtensions$124get$35forEachWhile(E, $this) {
if ($this == null) dart.nullFailed(I[112], 124, 8, "#this");
return dart.fn(action => {
if (action == null) dart.nullFailed(I[112], 124, 46, "action");
return list_extensions['ListExtensions|forEachWhile'](E, $this, action);
}, dart.fnType(dart.void, [dart.fnType(core.bool, [E])]));
};
list_extensions['ListExtensions|forEachWhile'] = function ListExtensions$124forEachWhile(E, $this, action) {
if ($this == null) dart.nullFailed(I[112], 124, 8, "#this");
if (action == null) dart.nullFailed(I[112], 124, 46, "action");
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
if (!dart.test(action($this[S$.$_get](index)))) break;
}
};
list_extensions['ListExtensions|forEachIndexedWhile'] = function ListExtensions$124forEachIndexedWhile(E, $this, action) {
if ($this == null) dart.nullFailed(I[112], 135, 8, "#this");
if (action == null) dart.nullFailed(I[112], 135, 64, "action");
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
if (!dart.test(action(index, $this[S$.$_get](index)))) break;
}
};
list_extensions['ListExtensions|get#forEachIndexedWhile'] = function ListExtensions$124get$35forEachIndexedWhile(E, $this) {
if ($this == null) dart.nullFailed(I[112], 135, 8, "#this");
return dart.fn(action => {
if (action == null) dart.nullFailed(I[112], 135, 64, "action");
return list_extensions['ListExtensions|forEachIndexedWhile'](E, $this, action);
}, dart.fnType(dart.void, [dart.fnType(core.bool, [core.int, E])]));
};
list_extensions['ListExtensions|mapIndexed'] = function ListExtensions$124mapIndexed(E, R, $this, convert) {
if ($this == null) dart.nullFailed(I[112], 142, 15, "#this");
if (convert == null) dart.nullFailed(I[112], 142, 62, "convert");
return new (_js_helper.SyncIterable$(R)).new(function* ListExtensions$124mapIndexed() {
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
yield convert(index, $this[S$.$_get](index));
}
});
};
list_extensions['ListExtensions|get#mapIndexed'] = function ListExtensions$124get$35mapIndexed(E, $this) {
if ($this == null) dart.nullFailed(I[112], 142, 15, "#this");
return dart.fn((R, convert) => {
if (convert == null) dart.nullFailed(I[112], 142, 62, "convert");
return list_extensions['ListExtensions|mapIndexed'](E, R, $this, convert);
}, dart.gFnType(R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [__t$IterableOfR(), [dart.fnType(R, [core.int, E])]];
}, R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [T$.ObjectN()];
}));
};
list_extensions['ListExtensions|whereIndexed'] = function ListExtensions$124whereIndexed(E, $this, test) {
if ($this == null) dart.nullFailed(I[112], 149, 15, "#this");
if (test == null) dart.nullFailed(I[112], 149, 64, "test");
return new (_js_helper.SyncIterable$(E)).new(function* ListExtensions$124whereIndexed() {
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
let element = $this[S$.$_get](index);
if (dart.test(test(index, element))) yield element;
}
});
};
list_extensions['ListExtensions|get#whereIndexed'] = function ListExtensions$124get$35whereIndexed(E, $this) {
if ($this == null) dart.nullFailed(I[112], 149, 15, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[112], 149, 64, "test");
return list_extensions['ListExtensions|whereIndexed'](E, $this, test);
}, dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [core.int, E])]));
};
list_extensions['ListExtensions|whereNotIndexed'] = function ListExtensions$124whereNotIndexed(E, $this, test) {
if ($this == null) dart.nullFailed(I[112], 157, 15, "#this");
if (test == null) dart.nullFailed(I[112], 157, 67, "test");
return new (_js_helper.SyncIterable$(E)).new(function* ListExtensions$124whereNotIndexed() {
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
let element = $this[S$.$_get](index);
if (!dart.test(test(index, element))) yield element;
}
});
};
list_extensions['ListExtensions|get#whereNotIndexed'] = function ListExtensions$124get$35whereNotIndexed(E, $this) {
if ($this == null) dart.nullFailed(I[112], 157, 15, "#this");
return dart.fn(test => {
if (test == null) dart.nullFailed(I[112], 157, 67, "test");
return list_extensions['ListExtensions|whereNotIndexed'](E, $this, test);
}, dart.fnType(core.Iterable$(E), [dart.fnType(core.bool, [core.int, E])]));
};
list_extensions['ListExtensions|expandIndexed'] = function ListExtensions$124expandIndexed(E, R, $this, expand) {
if ($this == null) dart.nullFailed(I[112], 168, 15, "#this");
if (expand == null) dart.nullFailed(I[112], 169, 50, "expand");
return new (_js_helper.SyncIterable$(R)).new(function* ListExtensions$124expandIndexed() {
for (let index = 0; index < dart.notNull($this[S$.$length]); index = index + 1) {
yield* expand(index, $this[S$.$_get](index));
}
});
};
list_extensions['ListExtensions|get#expandIndexed'] = function ListExtensions$124get$35expandIndexed(E, $this) {
if ($this == null) dart.nullFailed(I[112], 168, 15, "#this");
return dart.fn((R, expand) => {
if (expand == null) dart.nullFailed(I[112], 169, 50, "expand");
return list_extensions['ListExtensions|expandIndexed'](E, R, $this, expand);
}, dart.gFnType(R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [__t$IterableOfR(), [dart.fnType(__t$IterableOfR(), [core.int, E])]];
}, R => {
var __t$IterableOfR = () => (__t$IterableOfR = dart.constFn(core.Iterable$(R)))();
return [T$.ObjectN()];
}));
};
list_extensions['ListExtensions|sortRange'] = function ListExtensions$124sortRange(E, $this, start, end, compare) {
if ($this == null) dart.nullFailed(I[112], 176, 8, "#this");
if (start == null) dart.nullFailed(I[112], 176, 22, "start");
if (end == null) dart.nullFailed(I[112], 176, 33, "end");
if (compare == null) dart.nullFailed(I[112], 176, 61, "compare");
algorithms.quickSortBy(E, E, $this, dart.gbind(C[174] || CT.C174, E), compare, start, end);
};
list_extensions['ListExtensions|get#sortRange'] = function ListExtensions$124get$35sortRange(E, $this) {
if ($this == null) dart.nullFailed(I[112], 176, 8, "#this");
return dart.fn((start, end, compare) => {
if (start == null) dart.nullFailed(I[112], 176, 22, "start");
if (end == null) dart.nullFailed(I[112], 176, 33, "end");
if (compare == null) dart.nullFailed(I[112], 176, 61, "compare");
return list_extensions['ListExtensions|sortRange'](E, $this, start, end, compare);
}, dart.fnType(dart.void, [core.int, core.int, dart.fnType(core.int, [E, E])]));
};
list_extensions['ListExtensions|sortByCompare'] = function ListExtensions$124sortByCompare(E, K, $this, keyOf, compare, start = 0, end = null) {
if ($this == null) dart.nullFailed(I[112], 183, 8, "#this");
if (keyOf == null) dart.nullFailed(I[112], 184, 29, "keyOf");
if (compare == null) dart.nullFailed(I[112], 184, 59, "compare");
if (start == null) dart.nullFailed(I[112], 185, 12, "start");
algorithms.quickSortBy(E, K, $this, keyOf, compare, start, end);
};
list_extensions['ListExtensions|get#sortByCompare'] = function ListExtensions$124get$35sortByCompare(E, $this) {
if ($this == null) dart.nullFailed(I[112], 183, 8, "#this");
return dart.fn((K, keyOf, compare, start = 0, end = null) => {
if (keyOf == null) dart.nullFailed(I[112], 184, 29, "keyOf");
if (compare == null) dart.nullFailed(I[112], 184, 59, "compare");
if (start == null) dart.nullFailed(I[112], 185, 12, "start");
return list_extensions['ListExtensions|sortByCompare'](E, K, $this, keyOf, compare, start, end);
}, dart.gFnType(K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [dart.void, [dart.fnType(K, [E]), __t$KAndKToint()], [core.int, T$.intN()]];
}, K => {
var __t$KAndKToint = () => (__t$KAndKToint = dart.constFn(dart.fnType(core.int, [K, K])))();
return [T$.ObjectN()];
}));
};
list_extensions['ListExtensions|sortBy'] = function ListExtensions$124sortBy(E, K, $this, keyOf, start = 0, end = null) {
if ($this == null) dart.nullFailed(I[112], 192, 8, "#this");
if (keyOf == null) dart.nullFailed(I[112], 192, 62, "keyOf");
if (start == null) dart.nullFailed(I[112], 193, 12, "start");
algorithms.quickSortBy(E, K, $this, keyOf, dart.gbind(C[177] || CT.C177, K), start, end);
};
list_extensions['ListExtensions|get#sortBy'] = function ListExtensions$124get$35sortBy(E, $this) {
if ($this == null) dart.nullFailed(I[112], 192, 8, "#this");
return dart.fn((K, keyOf, start = 0, end = null) => {
if (keyOf == null) dart.nullFailed(I[112], 192, 62, "keyOf");
if (start == null) dart.nullFailed(I[112], 193, 12, "start");
return list_extensions['ListExtensions|sortBy'](E, K, $this, keyOf, start, end);
}, dart.gFnType(K => [dart.void, [dart.fnType(K, [E])], [core.int, T$.intN()]], K => {
var __t$ComparableOfK = () => (__t$ComparableOfK = dart.constFn(core.Comparable$(K)))();
return [__t$ComparableOfK()];
}));
};
list_extensions['ListExtensions|shuffleRange'] = function ListExtensions$124shuffleRange(E, $this, start, end, random = null) {
if ($this == null) dart.nullFailed(I[112], 198, 8, "#this");
if (start == null) dart.nullFailed(I[112], 198, 25, "start");
if (end == null) dart.nullFailed(I[112], 198, 36, "end");
core.RangeError.checkValidRange(start, end, $this[S$.$length]);
algorithms.shuffle($this, start, end, random);
};
list_extensions['ListExtensions|get#shuffleRange'] = function ListExtensions$124get$35shuffleRange(E, $this) {
if ($this == null) dart.nullFailed(I[112], 198, 8, "#this");
return dart.fn((start, end, random = null) => {
if (start == null) dart.nullFailed(I[112], 198, 25, "start");
if (end == null) dart.nullFailed(I[112], 198, 36, "end");
return list_extensions['ListExtensions|shuffleRange'](E, $this, start, end, random);
}, T$.intAndintAndRandomNTovoid());
};
list_extensions['ListExtensions|reverseRange'] = function ListExtensions$124reverseRange(E, $this, start, end) {
if ($this == null) dart.nullFailed(I[112], 204, 8, "#this");
if (start == null) dart.nullFailed(I[112], 204, 25, "start");
if (end == null) dart.nullFailed(I[112], 204, 36, "end");
core.RangeError.checkValidRange(start, end, $this[S$.$length]);
while (dart.notNull(start) < (end = dart.notNull(end) - 1)) {
let tmp = $this[S$.$_get](start);
$this[S$.$_set](start, $this[S$.$_get](end));
$this[S$.$_set](end, tmp);
start = dart.notNull(start) + 1;
}
};
list_extensions['ListExtensions|get#reverseRange'] = function ListExtensions$124get$35reverseRange(E, $this) {
if ($this == null) dart.nullFailed(I[112], 204, 8, "#this");
return dart.fn((start, end) => {
if (start == null) dart.nullFailed(I[112], 204, 25, "start");
if (end == null) dart.nullFailed(I[112], 204, 36, "end");
return list_extensions['ListExtensions|reverseRange'](E, $this, start, end);
}, T$.intAndintTovoid());
};
list_extensions['ListExtensions|swap'] = function ListExtensions$124swap(E, $this, index1, index2) {
if ($this == null) dart.nullFailed(I[112], 215, 8, "#this");
if (index1 == null) dart.nullFailed(I[112], 215, 17, "index1");
if (index2 == null) dart.nullFailed(I[112], 215, 29, "index2");
core.RangeError.checkValidIndex(index1, $this, "index1");
core.RangeError.checkValidIndex(index2, $this, "index2");
let tmp = $this[S$.$_get](index1);
$this[S$.$_set](index1, $this[S$.$_get](index2));
$this[S$.$_set](index2, tmp);
};
list_extensions['ListExtensions|get#swap'] = function ListExtensions$124get$35swap(E, $this) {
if ($this == null) dart.nullFailed(I[112], 215, 8, "#this");
return dart.fn((index1, index2) => {
if (index1 == null) dart.nullFailed(I[112], 215, 17, "index1");
if (index2 == null) dart.nullFailed(I[112], 215, 29, "index2");
return list_extensions['ListExtensions|swap'](E, $this, index1, index2);
}, T$.intAndintTovoid());
};
list_extensions['ListExtensions|slice'] = function ListExtensions$124slice(E, $this, start, end = null) {
if ($this == null) dart.nullFailed(I[112], 235, 16, "#this");
if (start == null) dart.nullFailed(I[112], 235, 26, "start");
end = core.RangeError.checkValidRange(start, end, $this[S$.$length]);
let self = $this;
if (list_extensions.ListSlice.is(self)) return list_extensions['ListExtensions|slice'](E, self, start, end);
return new (list_extensions.ListSlice$(E)).new($this, start, end);
};
list_extensions['ListExtensions|get#slice'] = function ListExtensions$124get$35slice(E, $this) {
if ($this == null) dart.nullFailed(I[112], 235, 16, "#this");
return dart.fn((start, end = null) => {
if (start == null) dart.nullFailed(I[112], 235, 26, "start");
return list_extensions['ListExtensions|slice'](E, $this, start, end);
}, dart.fnType(list_extensions.ListSlice$(E), [core.int], [T$.intN()]));
};
list_extensions['ListExtensions|equals'] = function ListExtensions$124equals(E, $this, other, equality = C[176] || CT.C176) {
if ($this == null) dart.nullFailed(I[112], 248, 8, "#this");
if (other == null) dart.nullFailed(I[112], 248, 23, "other");
if (equality == null) dart.nullFailed(I[112], 248, 43, "equality");
if ($this[S$.$length] != other[S$.$length]) return false;
for (let i = 0; i < dart.notNull($this[S$.$length]); i = i + 1) {
if (!dart.test(equality.equals($this[S$.$_get](i), other[S$.$_get](i)))) return false;
}
return true;
};
list_extensions['ListExtensions|get#equals'] = function ListExtensions$124get$35equals(E, $this) {
if ($this == null) dart.nullFailed(I[112], 248, 8, "#this");
return dart.fn((other, equality = C[176] || CT.C176) => {
if (other == null) dart.nullFailed(I[112], 248, 23, "other");
if (equality == null) dart.nullFailed(I[112], 248, 43, "equality");
return list_extensions['ListExtensions|equals'](E, $this, other, equality);
}, dart.fnType(core.bool, [core.List$(E)], [equality$.Equality$(E)]));
};
list_extensions['ListComparableExtensions|binarySearch'] = function ListComparableExtensions$124binarySearch(E, $this, element, compare = null) {
let t166;
if ($this == null) dart.nullFailed(I[112], 267, 7, "#this");
if (element == null) dart.nullFailed(I[112], 267, 22, "element");
return algorithms.binarySearchBy(E, E, $this, dart.gbind(C[174] || CT.C174, E), (t166 = compare, t166 == null ? dart.gbind(C[177] || CT.C177, E) : t166), element);
};
list_extensions['ListComparableExtensions|get#binarySearch'] = function ListComparableExtensions$124get$35binarySearch(E, $this) {
if ($this == null) dart.nullFailed(I[112], 267, 7, "#this");
return dart.fn((element, compare = null) => {
if (element == null) dart.nullFailed(I[112], 267, 22, "element");
return list_extensions['ListComparableExtensions|binarySearch'](E, $this, element, compare);
}, dart.fnType(core.int, [E], [dart.nullable(dart.fnType(core.int, [E, E]))]));
};
list_extensions['ListComparableExtensions|lowerBound'] = function ListComparableExtensions$124lowerBound(E, $this, element, compare = null) {
let t168;
if ($this == null) dart.nullFailed(I[112], 281, 7, "#this");
if (element == null) dart.nullFailed(I[112], 281, 20, "element");
return algorithms.lowerBoundBy(E, E, $this, dart.gbind(C[174] || CT.C174, E), (t168 = compare, t168 == null ? dart.gbind(C[177] || CT.C177, E) : t168), element);
};
list_extensions['ListComparableExtensions|get#lowerBound'] = function ListComparableExtensions$124get$35lowerBound(E, $this) {
if ($this == null) dart.nullFailed(I[112], 281, 7, "#this");
return dart.fn((element, compare = null) => {
if (element == null) dart.nullFailed(I[112], 281, 20, "element");
return list_extensions['ListComparableExtensions|lowerBound'](E, $this, element, compare);
}, dart.fnType(core.int, [E], [dart.nullable(dart.fnType(core.int, [E, E]))]));
};
list_extensions['ListComparableExtensions|sortRange'] = function ListComparableExtensions$124sortRange(E, $this, start, end, compare = null) {
let t170;
if ($this == null) dart.nullFailed(I[112], 289, 8, "#this");
if (start == null) dart.nullFailed(I[112], 289, 22, "start");
if (end == null) dart.nullFailed(I[112], 289, 33, "end");
core.RangeError.checkValidRange(start, end, $this[S$.$length]);
algorithms.quickSortBy(E, E, $this, dart.gbind(C[174] || CT.C174, E), (t170 = compare, t170 == null ? dart.gbind(C[177] || CT.C177, E) : t170), start, end);
};
list_extensions['ListComparableExtensions|get#sortRange'] = function ListComparableExtensions$124get$35sortRange(E, $this) {
if ($this == null) dart.nullFailed(I[112], 289, 8, "#this");
return dart.fn((start, end, compare = null) => {
if (start == null) dart.nullFailed(I[112], 289, 22, "start");
if (end == null) dart.nullFailed(I[112], 289, 33, "end");
return list_extensions['ListComparableExtensions|sortRange'](E, $this, start, end, compare);
}, dart.fnType(dart.void, [core.int, core.int], [dart.nullable(dart.fnType(core.int, [E, E]))]));
};
const _is_PriorityQueue_default = Symbol('_is_PriorityQueue_default');
priority_queue.PriorityQueue$ = dart.generic(E => {
class PriorityQueue extends core.Object {
static ['_#new#tearOff'](E, comparison = null) {
return new (priority_queue.HeapPriorityQueue$(E)).new(comparison);
}
}
(PriorityQueue[dart.mixinNew] = function() {
}).prototype = PriorityQueue.prototype;
dart.addTypeTests(PriorityQueue);
PriorityQueue.prototype[_is_PriorityQueue_default] = true;
dart.addTypeCaches(PriorityQueue);
dart.setStaticMethodSignature(PriorityQueue, () => ['new']);
dart.setLibraryUri(PriorityQueue, I[114]);
dart.setStaticFieldSignature(PriorityQueue, () => ['_redirecting#']);
return PriorityQueue;
});
priority_queue.PriorityQueue = priority_queue.PriorityQueue$();
dart.addTypeTests(priority_queue.PriorityQueue, _is_PriorityQueue_default);
const _is_HeapPriorityQueue_default = Symbol('_is_HeapPriorityQueue_default');
priority_queue.HeapPriorityQueue$ = dart.generic(E => {
var __t$EN = () => (__t$EN = dart.constFn(dart.nullable(E)))();
var __t$ListOfEN = () => (__t$ListOfEN = dart.constFn(core.List$(__t$EN())))();
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$_UnorderedElementsIterableOfE = () => (__t$_UnorderedElementsIterableOfE = dart.constFn(priority_queue._UnorderedElementsIterable$(E)))();
var __t$SplayTreeSetOfE = () => (__t$SplayTreeSetOfE = dart.constFn(collection.SplayTreeSet$(E)))();
var __t$JSArrayOfE = () => (__t$JSArrayOfE = dart.constFn(_interceptors.JSArray$(E)))();
class HeapPriorityQueue extends core.Object {
get comparison() {
return this[S$.comparison];
}
set comparison(value) {
super.comparison = value;
}
static ['_#new#tearOff'](E, comparison = null) {
return new (priority_queue.HeapPriorityQueue$(E)).new(comparison);
}
[S$._elementAt](index) {
let t171;
if (index == null) dart.nullFailed(I[115], 207, 20, "index");
t171 = this[S$._queue$1][S$.$_get](index);
return t171 == null ? E.as(null) : t171;
}
add(element) {
E.as(element);
this[S$._modificationCount] = dart.notNull(this[S$._modificationCount]) + 1;
this[S$._add](element);
}
addAll(elements) {
__t$IterableOfE().as(elements);
if (elements == null) dart.nullFailed(I[115], 216, 27, "elements");
let modified = 0;
for (let element of elements) {
modified = 1;
this[S$._add](element);
}
this[S$._modificationCount] = dart.notNull(this[S$._modificationCount]) + modified;
}
clear() {
this[S$._modificationCount] = dart.notNull(this[S$._modificationCount]) + 1;
this[S$._queue$1] = C[178] || CT.C178;
this[S$._length] = 0;
}
contains(object) {
E.as(object);
return dart.notNull(this[S$._locate](object)) >= 0;
}
get unorderedElements() {
return new (__t$_UnorderedElementsIterableOfE()).new(this);
}
get first() {
if (this[S$._length] === 0) dart.throw(new core.StateError.new("No element"));
return this[S$._elementAt](0);
}
get isEmpty() {
return this[S$._length] === 0;
}
get isNotEmpty() {
return this[S$._length] !== 0;
}
get length() {
return this[S$._length];
}
remove(element) {
let t172, t171;
E.as(element);
let index = this[S$._locate](element);
if (dart.notNull(index) < 0) return false;
this[S$._modificationCount] = dart.notNull(this[S$._modificationCount]) + 1;
let last = this[S$._removeLast]();
if (dart.notNull(index) < dart.notNull(this[S$._length])) {
let comp = (t171 = last, t172 = element, this.comparison(t171, t172));
if (dart.notNull(comp) <= 0) {
this[S$._bubbleUp](last, index);
} else {
this[S$._bubbleDown](last, index);
}
}
return true;
}
removeAll() {
this[S$._modificationCount] = dart.notNull(this[S$._modificationCount]) + 1;
let result = this[S$._queue$1];
let length = this[S$._length];
this[S$._queue$1] = C[178] || CT.C178;
this[S$._length] = 0;
return result[S$.$take](length)[S$.$cast](E);
}
removeFirst() {
if (this[S$._length] === 0) dart.throw(new core.StateError.new("No element"));
this[S$._modificationCount] = dart.notNull(this[S$._modificationCount]) + 1;
let result = this[S$._elementAt](0);
let last = this[S$._removeLast]();
if (dart.notNull(this[S$._length]) > 0) {
this[S$._bubbleDown](last, 0);
}
return result;
}
toList() {
let t171;
t171 = this[S$._toUnorderedList]();
return (() => {
t171[S$.$sort](this.comparison);
return t171;
})();
}
toSet() {
let set = new (__t$SplayTreeSetOfE()).new(this.comparison);
for (let i = 0; i < dart.notNull(this[S$._length]); i = i + 1) {
set.add(this[S$._elementAt](i));
}
return set;
}
toUnorderedList() {
return this[S$._toUnorderedList]();
}
[S$._toUnorderedList]() {
return (() => {
let t171 = __t$JSArrayOfE().of([]);
for (let i = 0; i < dart.notNull(this[S$._length]); i = i + 1)
t171.push(this[S$._elementAt](i));
return t171;
})();
}
toString() {
return dart.toString(this[S$._queue$1][S$.$take](this[S$._length]));
}
[S$._add](element) {
let t172;
if (this[S$._length] == this[S$._queue$1][S$.$length]) this[S$._grow]();
this[S$._bubbleUp](element, (t172 = this[S$._length], this[S$._length] = dart.notNull(t172) + 1, t172));
}
[S$._locate](object) {
let t173, t172;
if (this[S$._length] === 0) return -1;
let position = 1;
do {
let index = position - 1;
let element = this[S$._elementAt](index);
let comp = (t172 = element, t173 = object, this.comparison(t172, t173));
if (dart.notNull(comp) <= 0) {
if (comp === 0 && dart.equals(element, object)) return index;
let leftChildPosition = position * 2;
if (leftChildPosition <= dart.notNull(this[S$._length])) {
position = leftChildPosition;
continue;
}
}
do {
while (position[S$.$isOdd]) {
position = position[S$.$rightShift](1);
}
position = position + 1;
} while (position > dart.notNull(this[S$._length]));
} while (position !== 1);
return -1;
}
[S$._removeLast]() {
let newLength = dart.notNull(this[S$._length]) - 1;
let last = this[S$._elementAt](newLength);
this[S$._queue$1][S$.$_set](newLength, null);
this[S$._length] = newLength;
return last;
}
[S$._bubbleUp](element, index) {
let t173, t172;
if (index == null) dart.nullFailed(I[115], 396, 33, "index");
while (dart.notNull(index) > 0) {
let parentIndex = ((dart.notNull(index) - 1) / 2)[S$.$truncate]();
let parent = this[S$._elementAt](parentIndex);
if (dart.notNull((t172 = element, t173 = parent, this.comparison(t172, t173))) > 0) break;
this[S$._queue$1][S$.$_set](index, parent);
index = parentIndex;
}
this[S$._queue$1][S$.$_set](index, element);
}
[S$._bubbleDown](element, index) {
let t173, t172, t173$, t172$, t173$0, t172$0;
if (index == null) dart.nullFailed(I[115], 412, 35, "index");
let rightChildIndex = dart.notNull(index) * 2 + 2;
while (rightChildIndex < dart.notNull(this[S$._length])) {
let leftChildIndex = rightChildIndex - 1;
let leftChild = this[S$._elementAt](leftChildIndex);
let rightChild = this[S$._elementAt](rightChildIndex);
let comp = (t172 = leftChild, t173 = rightChild, this.comparison(t172, t173));
let minChildIndex = null;
let minChild = null;
if (dart.notNull(comp) < 0) {
minChild = leftChild;
minChildIndex = leftChildIndex;
} else {
minChild = rightChild;
minChildIndex = rightChildIndex;
}
comp = (t172$ = element, t173$ = minChild, this.comparison(t172$, t173$));
if (dart.notNull(comp) <= 0) {
this[S$._queue$1][S$.$_set](index, element);
return;
}
this[S$._queue$1][S$.$_set](index, minChild);
index = minChildIndex;
rightChildIndex = dart.notNull(index) * 2 + 2;
}
let leftChildIndex = rightChildIndex - 1;
if (leftChildIndex < dart.notNull(this[S$._length])) {
let child = this[S$._elementAt](leftChildIndex);
let comp = (t172$0 = element, t173$0 = child, this.comparison(t172$0, t173$0));
if (dart.notNull(comp) > 0) {
this[S$._queue$1][S$.$_set](index, child);
index = leftChildIndex;
}
}
this[S$._queue$1][S$.$_set](index, element);
}
[S$._grow]() {
let newCapacity = dart.notNull(this[S$._queue$1][S$.$length]) * 2 + 1;
if (newCapacity < 7) newCapacity = 7;
let newQueue = __t$ListOfEN().filled(newCapacity, null);
newQueue[S$.$setRange](0, this[S$._length], this[S$._queue$1]);
this[S$._queue$1] = newQueue;
}
}
(HeapPriorityQueue.new = function(comparison = null) {
let t171;
this[S$._queue$1] = __t$ListOfEN().filled(7, null);
this[S$._length] = 0;
this[S$._modificationCount] = 0;
this[S$.comparison] = (t171 = comparison, t171 == null ? C[173] || CT.C173 : t171);
;
}).prototype = HeapPriorityQueue.prototype;
dart.addTypeTests(HeapPriorityQueue);
HeapPriorityQueue.prototype[_is_HeapPriorityQueue_default] = true;
dart.addTypeCaches(HeapPriorityQueue);
HeapPriorityQueue[dart.implements] = () => [priority_queue.PriorityQueue$(E)];
dart.setMethodSignature(HeapPriorityQueue, () => ({
__proto__: dart.getMethods(HeapPriorityQueue.__proto__),
[S$._elementAt]: dart.fnType(E, [core.int]),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
contains: dart.fnType(core.bool, [dart.nullable(core.Object)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeAll: dart.fnType(core.Iterable$(E), []),
removeFirst: dart.fnType(E, []),
toList: dart.fnType(core.List$(E), []),
toSet: dart.fnType(core.Set$(E), []),
toUnorderedList: dart.fnType(core.List$(E), []),
[S$._toUnorderedList]: dart.fnType(core.List$(E), []),
[S$._add]: dart.fnType(dart.void, [E]),
[S$._locate]: dart.fnType(core.int, [E]),
[S$._removeLast]: dart.fnType(E, []),
[S$._bubbleUp]: dart.fnType(dart.void, [E, core.int]),
[S$._bubbleDown]: dart.fnType(dart.void, [E, core.int]),
[S$._grow]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(HeapPriorityQueue, () => ({
__proto__: dart.getGetters(HeapPriorityQueue.__proto__),
unorderedElements: core.Iterable$(E),
first: E,
isEmpty: core.bool,
isNotEmpty: core.bool,
length: core.int
}));
dart.setLibraryUri(HeapPriorityQueue, I[114]);
dart.setFieldSignature(HeapPriorityQueue, () => ({
__proto__: dart.getFields(HeapPriorityQueue.__proto__),
comparison: dart.finalFieldType(dart.fnType(core.int, [E, E])),
[S$._queue$1]: dart.fieldType(core.List$(dart.nullable(E))),
[S$._length]: dart.fieldType(core.int),
[S$._modificationCount]: dart.fieldType(core.int)
}));
dart.setStaticFieldSignature(HeapPriorityQueue, () => ['_INITIAL_CAPACITY']);
dart.defineExtensionMethods(HeapPriorityQueue, ['toString']);
return HeapPriorityQueue;
});
priority_queue.HeapPriorityQueue = priority_queue.HeapPriorityQueue$();
dart.defineLazy(priority_queue.HeapPriorityQueue, {
/*priority_queue.HeapPriorityQueue._INITIAL_CAPACITY*/get _INITIAL_CAPACITY() {
return 7;
}
}, false);
dart.addTypeTests(priority_queue.HeapPriorityQueue, _is_HeapPriorityQueue_default);
const _is__UnorderedElementsIterable_default = Symbol('_is__UnorderedElementsIterable_default');
priority_queue._UnorderedElementsIterable$ = dart.generic(E => {
var __t$_UnorderedElementsIteratorOfE = () => (__t$_UnorderedElementsIteratorOfE = dart.constFn(priority_queue._UnorderedElementsIterator$(E)))();
class _UnorderedElementsIterable extends core.Iterable$(E) {
static ['_#new#tearOff'](E, _queue) {
if (_queue == null) dart.nullFailed(I[115], 464, 35, "_queue");
return new (priority_queue._UnorderedElementsIterable$(E)).new(_queue);
}
get iterator() {
return new (__t$_UnorderedElementsIteratorOfE()).new(this[S$._queue$1]);
}
}
(_UnorderedElementsIterable.new = function(_queue) {
if (_queue == null) dart.nullFailed(I[115], 464, 35, "_queue");
this[S$._queue$1] = _queue;
_UnorderedElementsIterable.__proto__.new.call(this);
;
}).prototype = _UnorderedElementsIterable.prototype;
dart.addTypeTests(_UnorderedElementsIterable);
_UnorderedElementsIterable.prototype[_is__UnorderedElementsIterable_default] = true;
dart.addTypeCaches(_UnorderedElementsIterable);
dart.setGetterSignature(_UnorderedElementsIterable, () => ({
__proto__: dart.getGetters(_UnorderedElementsIterable.__proto__),
iterator: core.Iterator$(E),
[S$.$iterator]: core.Iterator$(E)
}));
dart.setLibraryUri(_UnorderedElementsIterable, I[114]);
dart.setFieldSignature(_UnorderedElementsIterable, () => ({
__proto__: dart.getFields(_UnorderedElementsIterable.__proto__),
[S$._queue$1]: dart.finalFieldType(priority_queue.HeapPriorityQueue$(E))
}));
dart.defineExtensionAccessors(_UnorderedElementsIterable, ['iterator']);
return _UnorderedElementsIterable;
});
priority_queue._UnorderedElementsIterable = priority_queue._UnorderedElementsIterable$();
dart.addTypeTests(priority_queue._UnorderedElementsIterable, _is__UnorderedElementsIterable_default);
const _is__UnorderedElementsIterator_default = Symbol('_is__UnorderedElementsIterator_default');
priority_queue._UnorderedElementsIterator$ = dart.generic(E => {
class _UnorderedElementsIterator extends core.Object {
static ['_#new#tearOff'](E, _queue) {
if (_queue == null) dart.nullFailed(I[115], 475, 35, "_queue");
return new (priority_queue._UnorderedElementsIterator$(E)).new(_queue);
}
moveNext() {
if (this[S$._initialModificationCount] != this[S$._queue$1][S$._modificationCount]) {
dart.throw(new core.ConcurrentModificationError.new(this[S$._queue$1]));
}
let nextIndex = dart.notNull(this[S$._index]) + 1;
if (0 <= nextIndex && nextIndex < dart.notNull(this[S$._queue$1].length)) {
this[S$._current$1] = this[S$._queue$1][S$._queue$1][S$.$_get](nextIndex);
this[S$._index] = nextIndex;
return true;
}
this[S$._current$1] = null;
this[S$._index] = -2;
return false;
}
get current() {
let t172;
return dart.notNull(this[S$._index]) < 0 ? dart.throw(new core.StateError.new("No element")) : (t172 = this[S$._current$1], t172 == null ? E.as(null) : t172);
}
}
(_UnorderedElementsIterator.new = function(_queue) {
if (_queue == null) dart.nullFailed(I[115], 475, 35, "_queue");
this[S$._current$1] = null;
this[S$._index] = -1;
this[S$._queue$1] = _queue;
this[S$._initialModificationCount] = _queue[S$._modificationCount];
;
}).prototype = _UnorderedElementsIterator.prototype;
dart.addTypeTests(_UnorderedElementsIterator);
_UnorderedElementsIterator.prototype[_is__UnorderedElementsIterator_default] = true;
dart.addTypeCaches(_UnorderedElementsIterator);
_UnorderedElementsIterator[dart.implements] = () => [core.Iterator$(E)];
dart.setMethodSignature(_UnorderedElementsIterator, () => ({
__proto__: dart.getMethods(_UnorderedElementsIterator.__proto__),
moveNext: dart.fnType(core.bool, [])
}));
dart.setGetterSignature(_UnorderedElementsIterator, () => ({
__proto__: dart.getGetters(_UnorderedElementsIterator.__proto__),
current: E
}));
dart.setLibraryUri(_UnorderedElementsIterator, I[114]);
dart.setFieldSignature(_UnorderedElementsIterator, () => ({
__proto__: dart.getFields(_UnorderedElementsIterator.__proto__),
[S$._queue$1]: dart.finalFieldType(priority_queue.HeapPriorityQueue$(E)),
[S$._initialModificationCount]: dart.finalFieldType(core.int),
[S$._current$1]: dart.fieldType(dart.nullable(E)),
[S$._index]: dart.fieldType(core.int)
}));
return _UnorderedElementsIterator;
});
priority_queue._UnorderedElementsIterator = priority_queue._UnorderedElementsIterator$();
dart.addTypeTests(priority_queue._UnorderedElementsIterator, _is__UnorderedElementsIterator_default);
const _is_QueueList_default = Symbol('_is_QueueList_default');
queue_list.QueueList$ = dart.generic(E => {
var __t$EN = () => (__t$EN = dart.constFn(dart.nullable(E)))();
var __t$ListOfEN = () => (__t$ListOfEN = dart.constFn(core.List$(__t$EN())))();
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
const Object_ListMixin$36 = class Object_ListMixin extends core.Object {};
(Object_ListMixin$36.new = function() {
}).prototype = Object_ListMixin$36.prototype;
dart.applyMixin(Object_ListMixin$36, collection.ListMixin$(E));
class QueueList extends Object_ListMixin$36 {
get [S$0._head$1]() {
return this[S$._head];
}
set [S$0._head$1](value) {
this[S$._head] = value;
}
get [S$0._tail$1]() {
return this[S$0._tail];
}
set [S$0._tail$1](value) {
this[S$0._tail] = value;
}
static _castFrom(S, T, source) {
if (source == null) dart.nullFailed(I[116], 24, 52, "source");
return new (queue_list._CastQueueList$(S, T)).new(source);
}
static ['_#new#tearOff'](E, initialCapacity = null) {
return new (queue_list.QueueList$(E)).new(initialCapacity);
}
static ['_#_init#tearOff'](E, initialCapacity) {
if (initialCapacity == null) dart.nullFailed(I[116], 42, 23, "initialCapacity");
return new (queue_list.QueueList$(E))._init(initialCapacity);
}
static ['_#_#tearOff'](E, _head, _tail, _table) {
if (_head == null) dart.nullFailed(I[116], 49, 20, "_head");
if (_tail == null) dart.nullFailed(I[116], 49, 32, "_tail");
if (_table == null) dart.nullFailed(I[116], 49, 44, "_table");
return new (queue_list.QueueList$(E)).__(_head, _tail, _table);
}
static from(source) {
let t172;
if (source == null) dart.nullFailed(I[116], 52, 38, "source");
if (core.List.is(source)) {
let length = source[S$.$length];
let queue = new (queue_list.QueueList$(E)).new(dart.notNull(length) + 1);
if (!(dart.notNull(queue[S$0._table][S$.$length]) > dart.notNull(length))) dart.assertFailed(null, I[116], 56, 14, "queue._table.length > length");
let sourceList = source;
queue[S$0._table][S$.$setRange](0, length, sourceList, 0);
queue[S$0._tail$1] = length;
return queue;
} else {
t172 = new (queue_list.QueueList$(E)).new();
return (() => {
t172.addAll(source);
return t172;
})();
}
}
static ['_#from#tearOff'](E, source) {
if (source == null) dart.nullFailed(I[116], 52, 38, "source");
return queue_list.QueueList$(E).from(source);
}
static _computeInitialCapacity(initialCapacity) {
if (initialCapacity == null || dart.notNull(initialCapacity) < 8) {
return 8;
}
initialCapacity = dart.notNull(initialCapacity) + 1;
if (dart.test(queue_list.QueueList._isPowerOf2(initialCapacity))) {
return initialCapacity;
}
return queue_list.QueueList._nextPowerOf2(initialCapacity);
}
add(element) {
E.as(element);
this[S$0._add$1](element);
}
addAll(iterable) {
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[116], 86, 27, "iterable");
if (core.List.is(iterable)) {
let list = iterable;
let addCount = list[S$.$length];
let length = this.length;
if (dart.notNull(length) + dart.notNull(addCount) >= dart.notNull(this[S$0._table][S$.$length])) {
this[S$0._preGrow](dart.notNull(length) + dart.notNull(addCount));
this[S$0._table][S$.$setRange](length, dart.notNull(length) + dart.notNull(addCount), list, 0);
this[S$0._tail$1] = dart.notNull(this[S$0._tail$1]) + dart.notNull(addCount);
} else {
let endSpace = dart.notNull(this[S$0._table][S$.$length]) - dart.notNull(this[S$0._tail$1]);
if (dart.notNull(addCount) < endSpace) {
this[S$0._table][S$.$setRange](this[S$0._tail$1], dart.notNull(this[S$0._tail$1]) + dart.notNull(addCount), list, 0);
this[S$0._tail$1] = dart.notNull(this[S$0._tail$1]) + dart.notNull(addCount);
} else {
let preSpace = dart.notNull(addCount) - endSpace;
this[S$0._table][S$.$setRange](this[S$0._tail$1], dart.notNull(this[S$0._tail$1]) + endSpace, list, 0);
this[S$0._table][S$.$setRange](0, preSpace, list, endSpace);
this[S$0._tail$1] = preSpace;
}
}
} else {
for (let element of iterable) {
this[S$0._add$1](element);
}
}
}
cast(T) {
return queue_list.QueueList._castFrom(E, T, this);
}
retype(T) {
return this.cast(T);
}
toString() {
return collection.IterableBase.iterableToFullString(this, "{", "}");
}
addLast(element) {
E.as(element);
this[S$0._add$1](element);
}
addFirst(element) {
E.as(element);
this[S$0._head$1] = (dart.notNull(this[S$0._head$1]) - 1 & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0;
this[S$0._table][S$.$_set](this[S$0._head$1], element);
if (this[S$0._head$1] == this[S$0._tail$1]) this[S$0._grow$1]();
}
removeFirst() {
if (this[S$0._head$1] == this[S$0._tail$1]) dart.throw(new core.StateError.new("No element"));
let result = E.as(this[S$0._table][S$.$_get](this[S$0._head$1]));
this[S$0._table][S$.$_set](this[S$0._head$1], null);
this[S$0._head$1] = (dart.notNull(this[S$0._head$1]) + 1 & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0;
return result;
}
removeLast() {
if (this[S$0._head$1] == this[S$0._tail$1]) dart.throw(new core.StateError.new("No element"));
this[S$0._tail$1] = (dart.notNull(this[S$0._tail$1]) - 1 & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0;
let result = E.as(this[S$0._table][S$.$_get](this[S$0._tail$1]));
this[S$0._table][S$.$_set](this[S$0._tail$1], null);
return result;
}
get length() {
return (dart.notNull(this[S$0._tail$1]) - dart.notNull(this[S$0._head$1]) & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0;
}
set length(value) {
if (value == null) dart.nullFailed(I[116], 162, 18, "value");
if (dart.notNull(value) < 0) dart.throw(new core.RangeError.new("Length " + dart.str(value) + " may not be negative."));
if (dart.notNull(value) > dart.notNull(this.length) && !E.is(null)) {
dart.throw(new core.UnsupportedError.new("The length can only be increased when the element type is " + "nullable, but the current element type is `" + dart.str(dart.wrapType(E)) + "`."));
}
let delta = dart.notNull(value) - dart.notNull(this.length);
if (delta >= 0) {
if (dart.notNull(this[S$0._table][S$.$length]) <= dart.notNull(value)) {
this[S$0._preGrow](value);
}
this[S$0._tail$1] = (dart.notNull(this[S$0._tail$1]) + delta & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0;
return;
}
let newTail = dart.notNull(this[S$0._tail$1]) + delta;
if (newTail >= 0) {
this[S$0._table][S$0.$fillRange](newTail, this[S$0._tail$1], null);
} else {
newTail = newTail + dart.notNull(this[S$0._table][S$.$length]);
this[S$0._table][S$0.$fillRange](0, this[S$0._tail$1], null);
this[S$0._table][S$0.$fillRange](newTail, this[S$0._table][S$.$length], null);
}
this[S$0._tail$1] = newTail;
}
_get(index) {
if (index == null) dart.nullFailed(I[116], 191, 21, "index");
if (dart.notNull(index) < 0 || dart.notNull(index) >= dart.notNull(this.length)) {
dart.throw(new core.RangeError.new("Index " + dart.str(index) + " must be in the range [0.." + dart.str(this.length) + ")."));
}
return E.as(this[S$0._table][S$.$_get]((dart.notNull(this[S$0._head$1]) + dart.notNull(index) & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0));
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[116], 200, 25, "index");
E.as(value);
if (dart.notNull(index) < 0 || dart.notNull(index) >= dart.notNull(this.length)) {
dart.throw(new core.RangeError.new("Index " + dart.str(index) + " must be in the range [0.." + dart.str(this.length) + ")."));
}
this[S$0._table][S$.$_set]((dart.notNull(this[S$0._head$1]) + dart.notNull(index) & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0, value);
return value$;
}
static _isPowerOf2(number) {
if (number == null) dart.nullFailed(I[116], 213, 31, "number");
return (dart.notNull(number) & dart.notNull(number) - 1) === 0;
}
static _nextPowerOf2(number) {
if (number == null) dart.nullFailed(I[116], 220, 32, "number");
if (!(dart.notNull(number) > 0)) dart.assertFailed(null, I[116], 221, 12, "number > 0");
number = (dart.notNull(number) << 1 >>> 0) - 1;
for (;;) {
let nextNumber = (dart.notNull(number) & dart.notNull(number) - 1) >>> 0;
if (nextNumber === 0) return number;
number = nextNumber;
}
}
[S$0._add$1](element) {
this[S$0._table][S$.$_set](this[S$0._tail$1], element);
this[S$0._tail$1] = (dart.notNull(this[S$0._tail$1]) + 1 & dart.notNull(this[S$0._table][S$.$length]) - 1) >>> 0;
if (this[S$0._head$1] == this[S$0._tail$1]) this[S$0._grow$1]();
}
[S$0._grow$1]() {
let newTable = __t$ListOfEN().filled(dart.notNull(this[S$0._table][S$.$length]) * 2, null);
let split = dart.notNull(this[S$0._table][S$.$length]) - dart.notNull(this[S$0._head$1]);
newTable[S$.$setRange](0, split, this[S$0._table], this[S$0._head$1]);
newTable[S$.$setRange](split, split + dart.notNull(this[S$0._head$1]), this[S$0._table], 0);
this[S$0._head$1] = 0;
this[S$0._tail$1] = this[S$0._table][S$.$length];
this[S$0._table] = newTable;
}
[S$0._writeToList](target) {
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
if (!(dart.notNull(target[S$.$length]) >= dart.notNull(this.length))) dart.assertFailed(null, I[116], 249, 12, "target.length >= length");
if (dart.notNull(this[S$0._head$1]) <= dart.notNull(this[S$0._tail$1])) {
let length = dart.notNull(this[S$0._tail$1]) - dart.notNull(this[S$0._head$1]);
target[S$.$setRange](0, length, this[S$0._table], this[S$0._head$1]);
return length;
} else {
let firstPartSize = dart.notNull(this[S$0._table][S$.$length]) - dart.notNull(this[S$0._head$1]);
target[S$.$setRange](0, firstPartSize, this[S$0._table], this[S$0._head$1]);
target[S$.$setRange](firstPartSize, firstPartSize + dart.notNull(this[S$0._tail$1]), this[S$0._table], 0);
return dart.notNull(this[S$0._tail$1]) + firstPartSize;
}
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
if (!(dart.notNull(newElementCount) >= dart.notNull(this.length))) dart.assertFailed(null, I[116], 264, 12, "newElementCount >= length");
newElementCount = dart.notNull(newElementCount) + newElementCount[S$.$rightShift](1);
let newCapacity = queue_list.QueueList._nextPowerOf2(newElementCount);
let newTable = __t$ListOfEN().filled(newCapacity, null);
this[S$0._tail$1] = this[S$0._writeToList](newTable);
this[S$0._table] = newTable;
this[S$0._head$1] = 0;
}
}
(QueueList.new = function(initialCapacity = null) {
QueueList._init.call(this, queue_list.QueueList._computeInitialCapacity(initialCapacity));
}).prototype = QueueList.prototype;
(QueueList._init = function(initialCapacity) {
if (initialCapacity == null) dart.nullFailed(I[116], 42, 23, "initialCapacity");
if (!dart.test(queue_list.QueueList._isPowerOf2(initialCapacity))) dart.assertFailed(null, I[116], 43, 16, "_isPowerOf2(initialCapacity)");
this[S$0._table] = __t$ListOfEN().filled(initialCapacity, null);
this[S$._head] = 0;
this[S$0._tail] = 0;
;
}).prototype = QueueList.prototype;
(QueueList.__ = function(_head, _tail, _table) {
if (_head == null) dart.nullFailed(I[116], 49, 20, "_head");
if (_tail == null) dart.nullFailed(I[116], 49, 32, "_tail");
if (_table == null) dart.nullFailed(I[116], 49, 44, "_table");
this[S$._head] = _head;
this[S$0._tail] = _tail;
this[S$0._table] = _table;
;
}).prototype = QueueList.prototype;
dart.addTypeTests(QueueList);
QueueList.prototype[_is_QueueList_default] = true;
dart.addTypeCaches(QueueList);
QueueList[dart.implements] = () => [collection.Queue$(E)];
dart.setMethodSignature(QueueList, () => ({
__proto__: dart.getMethods(QueueList.__proto__),
cast: dart.gFnType(T => [queue_list.QueueList$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [queue_list.QueueList$(T), []], T => [dart.nullable(core.Object)]),
retype: dart.gFnType(T => [queue_list.QueueList$(T), []], T => [dart.nullable(core.Object)]),
addLast: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addFirst: dart.fnType(dart.void, [dart.nullable(core.Object)]),
removeFirst: dart.fnType(E, []),
_get: dart.fnType(E, [core.int]),
[S$.$_get]: dart.fnType(E, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [E]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._writeToList]: dart.fnType(core.int, [core.List$(dart.nullable(E))]),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(QueueList, () => ['_castFrom', 'from', '_computeInitialCapacity', '_isPowerOf2', '_nextPowerOf2']);
dart.setGetterSignature(QueueList, () => ({
__proto__: dart.getGetters(QueueList.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setSetterSignature(QueueList, () => ({
__proto__: dart.getSetters(QueueList.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(QueueList, I[117]);
dart.setFieldSignature(QueueList, () => ({
__proto__: dart.getFields(QueueList.__proto__),
[S$0._table]: dart.fieldType(core.List$(dart.nullable(E))),
[S$0._head$1]: dart.fieldType(core.int),
[S$0._tail$1]: dart.fieldType(core.int)
}));
dart.setStaticFieldSignature(QueueList, () => ['_initialCapacity']);
dart.defineExtensionMethods(QueueList, [
'add',
'addAll',
'cast',
'toString',
'removeLast',
'_get',
'_set'
]);
dart.defineExtensionAccessors(QueueList, ['length']);
return QueueList;
});
queue_list.QueueList = queue_list.QueueList$();
dart.defineLazy(queue_list.QueueList, {
/*queue_list.QueueList._initialCapacity*/get _initialCapacity() {
return 8;
}
}, false);
dart.addTypeTests(queue_list.QueueList, _is_QueueList_default);
const _is__CastQueueList_default = Symbol('_is__CastQueueList_default');
queue_list._CastQueueList$ = dart.generic((S, T) => {
class _CastQueueList extends queue_list.QueueList$(T) {
static ['_#new#tearOff'](S, T, _delegate) {
if (_delegate == null) dart.nullFailed(I[116], 282, 23, "_delegate");
return new (queue_list._CastQueueList$(S, T)).new(_delegate);
}
get [S$0._head$1]() {
return this[S$0._delegate][S$0._head$1];
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 288, 17, "value");
return this[S$0._delegate][S$0._head$1] = value;
}
get [S$0._tail$1]() {
return this[S$0._delegate][S$0._tail$1];
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 294, 17, "value");
return this[S$0._delegate][S$0._tail$1] = value;
}
}
(_CastQueueList.new = function(_delegate) {
if (_delegate == null) dart.nullFailed(I[116], 282, 23, "_delegate");
this[S$0._delegate] = _delegate;
_CastQueueList.__proto__.__.call(this, -1, -1, _delegate[S$0._table][S$.$cast](T));
;
}).prototype = _CastQueueList.prototype;
dart.addTypeTests(_CastQueueList);
_CastQueueList.prototype[_is__CastQueueList_default] = true;
dart.addTypeCaches(_CastQueueList);
dart.setGetterSignature(_CastQueueList, () => ({
__proto__: dart.getGetters(_CastQueueList.__proto__),
[S$0._head$1]: core.int,
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(_CastQueueList, () => ({
__proto__: dart.getSetters(_CastQueueList.__proto__),
[S$0._head$1]: core.int,
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(_CastQueueList, I[117]);
dart.setFieldSignature(_CastQueueList, () => ({
__proto__: dart.getFields(_CastQueueList.__proto__),
[S$0._delegate]: dart.finalFieldType(queue_list.QueueList$(S))
}));
return _CastQueueList;
});
queue_list._CastQueueList = queue_list._CastQueueList$();
dart.addTypeTests(queue_list._CastQueueList, _is__CastQueueList_default);
const _is_UnmodifiableSetMixin_default = Symbol('_is_UnmodifiableSetMixin_default');
unmodifiable_wrappers.UnmodifiableSetMixin$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
class UnmodifiableSetMixin extends core.Object {
static _throw() {
dart.throw(new core.UnsupportedError.new("Cannot modify an unmodifiable Set"));
}
add(value) {
E.as(value);
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
addAll(elements) {
__t$IterableOfE().as(elements);
if (elements == null) dart.nullFailed(I[119], 132, 27, "elements");
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
remove(value) {
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeAll(elements) {
if (elements == null) dart.nullFailed(I[119], 142, 27, "elements");
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
retainAll(elements) {
if (elements == null) dart.nullFailed(I[119], 147, 27, "elements");
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[119], 152, 37, "test");
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[119], 157, 37, "test");
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
clear() {
unmodifiable_wrappers.UnmodifiableSetMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
[Symbol.iterator]() {
return new dart.JsIterator(this[S$.$iterator]);
}
}
(UnmodifiableSetMixin.new = function() {
;
}).prototype = UnmodifiableSetMixin.prototype;
dart.addTypeTests(UnmodifiableSetMixin);
UnmodifiableSetMixin.prototype[_is_UnmodifiableSetMixin_default] = true;
dart.addTypeCaches(UnmodifiableSetMixin);
UnmodifiableSetMixin[dart.implements] = () => [core.Set$(E)];
dart.setMethodSignature(UnmodifiableSetMixin, () => ({
__proto__: dart.getMethods(UnmodifiableSetMixin.__proto__),
add: dart.fnType(core.bool, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeAll: dart.fnType(dart.void, [core.Iterable]),
retainAll: dart.fnType(dart.void, [core.Iterable]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
retainWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
clear: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(UnmodifiableSetMixin, () => ['_throw']);
dart.setLibraryUri(UnmodifiableSetMixin, I[120]);
return UnmodifiableSetMixin;
});
unmodifiable_wrappers.UnmodifiableSetMixin = unmodifiable_wrappers.UnmodifiableSetMixin$();
dart.addTypeTests(unmodifiable_wrappers.UnmodifiableSetMixin, _is_UnmodifiableSetMixin_default);
const _is_UnionSet_default = Symbol('_is_UnionSet_default');
union_set.UnionSet$ = dart.generic(E => {
var __t$SetOfE = () => (__t$SetOfE = dart.constFn(core.Set$(E)))();
var __t$intAndSetOfEToint = () => (__t$intAndSetOfEToint = dart.constFn(dart.fnType(core.int, [core.int, __t$SetOfE()])))();
var __t$SetOfEToSetOfE = () => (__t$SetOfEToSetOfE = dart.constFn(dart.fnType(__t$SetOfE(), [__t$SetOfE()])))();
var __t$LinkedHashSetOfE = () => (__t$LinkedHashSetOfE = dart.constFn(collection.LinkedHashSet$(E)))();
var __t$ETobool = () => (__t$ETobool = dart.constFn(dart.fnType(core.bool, [E])))();
var __t$SetOfETobool = () => (__t$SetOfETobool = dart.constFn(dart.fnType(core.bool, [__t$SetOfE()])))();
const SetBase_UnmodifiableSetMixin$36 = class SetBase_UnmodifiableSetMixin extends collection.SetBase$(E) {};
(SetBase_UnmodifiableSetMixin$36.new = function() {
}).prototype = SetBase_UnmodifiableSetMixin$36.prototype;
dart.applyMixin(SetBase_UnmodifiableSetMixin$36, unmodifiable_wrappers.UnmodifiableSetMixin$(E));
class UnionSet extends SetBase_UnmodifiableSetMixin$36 {
static ['_#new#tearOff'](E, sets, opts) {
if (sets == null) dart.nullFailed(I[118], 32, 24, "sets");
let disjoint = opts && 'disjoint' in opts ? opts.disjoint : false;
if (disjoint == null) dart.nullFailed(I[118], 32, 36, "disjoint");
return new (union_set.UnionSet$(E)).new(sets, {disjoint: disjoint});
}
static ['_#from#tearOff'](E, sets, opts) {
if (sets == null) dart.nullFailed(I[118], 46, 34, "sets");
let disjoint = opts && 'disjoint' in opts ? opts.disjoint : false;
if (disjoint == null) dart.nullFailed(I[118], 46, 46, "disjoint");
return new (union_set.UnionSet$(E)).from(sets, {disjoint: disjoint});
}
get length() {
return dart.test(this[S$0._disjoint]) ? this[S$0._sets][S$.$fold](core.int, 0, dart.fn((length, set) => {
if (length == null) dart.nullFailed(I[118], 51, 24, "length");
if (set == null) dart.nullFailed(I[118], 51, 32, "set");
return dart.notNull(length) + dart.notNull(set[S$.$length]);
}, __t$intAndSetOfEToint())) : this[S$0._iterable$2][S$.$length];
}
get iterator() {
return this[S$0._iterable$2][S$.$iterator];
}
get [S$0._iterable$2]() {
let allElements = this[S$0._sets][S$.$expand](E, dart.fn(set => {
if (set == null) dart.nullFailed(I[118], 62, 37, "set");
return set;
}, __t$SetOfEToSetOfE()));
return dart.test(this[S$0._disjoint]) ? allElements : allElements[S$.$where](__t$ETobool().as(dart.bind(__t$LinkedHashSetOfE().new(), 'add')));
}
contains(element) {
return this[S$0._sets][S$.$any](dart.fn(set => {
if (set == null) dart.nullFailed(I[118], 67, 48, "set");
return set.contains(element);
}, __t$SetOfETobool()));
}
lookup(element) {
for (let set of this[S$0._sets]) {
let result = set.lookup(element);
if (result != null || dart.test(set.contains(null))) return result;
}
return null;
}
toSet() {
return (() => {
let t172 = __t$LinkedHashSetOfE().new();
for (let set of this[S$0._sets])
t172.addAll(set);
return t172;
})();
}
}
(UnionSet.new = function(sets, opts) {
if (sets == null) dart.nullFailed(I[118], 32, 24, "sets");
let disjoint = opts && 'disjoint' in opts ? opts.disjoint : false;
if (disjoint == null) dart.nullFailed(I[118], 32, 36, "disjoint");
this[S$0._sets] = sets;
this[S$0._disjoint] = disjoint;
;
}).prototype = UnionSet.prototype;
(UnionSet.from = function(sets, opts) {
if (sets == null) dart.nullFailed(I[118], 46, 34, "sets");
let disjoint = opts && 'disjoint' in opts ? opts.disjoint : false;
if (disjoint == null) dart.nullFailed(I[118], 46, 46, "disjoint");
UnionSet.new.call(this, sets[S$.$toSet](), {disjoint: disjoint});
}).prototype = UnionSet.prototype;
dart.addTypeTests(UnionSet);
UnionSet.prototype[_is_UnionSet_default] = true;
dart.addTypeCaches(UnionSet);
dart.setMethodSignature(UnionSet, () => ({
__proto__: dart.getMethods(UnionSet.__proto__),
contains: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$contains]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
lookup: dart.fnType(dart.nullable(E), [dart.nullable(core.Object)]),
toSet: dart.fnType(core.Set$(E), []),
[S$.$toSet]: dart.fnType(core.Set$(E), [])
}));
dart.setGetterSignature(UnionSet, () => ({
__proto__: dart.getGetters(UnionSet.__proto__),
length: core.int,
[S$.$length]: core.int,
iterator: core.Iterator$(E),
[S$.$iterator]: core.Iterator$(E),
[S$0._iterable$2]: core.Iterable$(E)
}));
dart.setLibraryUri(UnionSet, I[121]);
dart.setFieldSignature(UnionSet, () => ({
__proto__: dart.getFields(UnionSet.__proto__),
[S$0._sets]: dart.finalFieldType(core.Set$(core.Set$(E))),
[S$0._disjoint]: dart.finalFieldType(core.bool)
}));
dart.defineExtensionMethods(UnionSet, ['contains', 'toSet']);
dart.defineExtensionAccessors(UnionSet, ['length', 'iterator']);
return UnionSet;
});
union_set.UnionSet = union_set.UnionSet$();
dart.addTypeTests(union_set.UnionSet, _is_UnionSet_default);
const _is_UnionSetController_default = Symbol('_is_UnionSetController_default');
union_set_controller.UnionSetController$ = dart.generic(E => {
var __t$SetOfE = () => (__t$SetOfE = dart.constFn(core.Set$(E)))();
var __t$LinkedHashSetOfSetOfE = () => (__t$LinkedHashSetOfSetOfE = dart.constFn(collection.LinkedHashSet$(__t$SetOfE())))();
var __t$UnionSetOfE = () => (__t$UnionSetOfE = dart.constFn(union_set.UnionSet$(E)))();
class UnionSetController extends core.Object {
get set() {
return this[S$0.set];
}
set set(value) {
super.set = value;
}
static ['_#new#tearOff'](E, opts) {
let disjoint = opts && 'disjoint' in opts ? opts.disjoint : false;
if (disjoint == null) dart.nullFailed(I[122], 36, 28, "disjoint");
return new (union_set_controller.UnionSetController$(E)).new({disjoint: disjoint});
}
static ['_#_#tearOff'](E, _sets, disjoint) {
if (_sets == null) dart.nullFailed(I[122], 39, 29, "_sets");
if (disjoint == null) dart.nullFailed(I[122], 39, 41, "disjoint");
return new (union_set_controller.UnionSetController$(E)).__(_sets, disjoint);
}
add(component) {
__t$SetOfE().as(component);
if (component == null) dart.nullFailed(I[122], 46, 19, "component");
this[S$0._sets$1].add(component);
}
remove(component) {
__t$SetOfE().as(component);
if (component == null) dart.nullFailed(I[122], 54, 22, "component");
return this[S$0._sets$1].remove(component);
}
}
(UnionSetController.new = function(opts) {
let disjoint = opts && 'disjoint' in opts ? opts.disjoint : false;
if (disjoint == null) dart.nullFailed(I[122], 36, 28, "disjoint");
UnionSetController.__.call(this, __t$LinkedHashSetOfSetOfE().new(), disjoint);
}).prototype = UnionSetController.prototype;
(UnionSetController.__ = function(_sets, disjoint) {
if (_sets == null) dart.nullFailed(I[122], 39, 29, "_sets");
if (disjoint == null) dart.nullFailed(I[122], 39, 41, "disjoint");
this[S$0._sets$1] = _sets;
this[S$0.set] = new (__t$UnionSetOfE()).new(_sets, {disjoint: disjoint});
;
}).prototype = UnionSetController.prototype;
dart.addTypeTests(UnionSetController);
UnionSetController.prototype[_is_UnionSetController_default] = true;
dart.addTypeCaches(UnionSetController);
dart.setMethodSignature(UnionSetController, () => ({
__proto__: dart.getMethods(UnionSetController.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(UnionSetController, I[123]);
dart.setFieldSignature(UnionSetController, () => ({
__proto__: dart.getFields(UnionSetController.__proto__),
set: dart.finalFieldType(union_set.UnionSet$(E)),
[S$0._sets$1]: dart.finalFieldType(core.Set$(core.Set$(E)))
}));
return UnionSetController;
});
union_set_controller.UnionSetController = union_set_controller.UnionSetController$();
dart.addTypeTests(union_set_controller.UnionSetController, _is_UnionSetController_default);
const _is_DelegatingList_default = Symbol('_is_DelegatingList_default');
wrappers.DelegatingList$ = dart.generic(E => {
var __t$ListOfE = () => (__t$ListOfE = dart.constFn(core.List$(E)))();
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$EN = () => (__t$EN = dart.constFn(dart.nullable(E)))();
class DelegatingList extends wrappers._DelegatingIterableBase$(E) {
get [S$._base$4]() {
return this[S$0._base$6];
}
set [S$._base$4](value) {
super[S$._base$4] = value;
}
static ['_#new#tearOff'](E, base) {
if (base == null) dart.nullFailed(I[103], 155, 32, "base");
return new (wrappers.DelegatingList$(E)).new(base);
}
static typed(E, base) {
if (base == null) dart.nullFailed(I[103], 169, 32, "base");
return base[S$.$cast](E);
}
_get(index) {
if (index == null) dart.nullFailed(I[103], 172, 21, "index");
return this[S$._base$4][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[103], 175, 25, "index");
E.as(value);
this[S$._base$4][S$.$_set](index, value);
return value$;
}
['+'](other) {
__t$ListOfE().as(other);
if (other == null) dart.nullFailed(I[103], 180, 30, "other");
return this[S$._base$4][S$0.$plus](other);
}
add(value) {
E.as(value);
this[S$._base$4][S$.$add](value);
}
addAll(iterable) {
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[103], 188, 27, "iterable");
this[S$._base$4][S$.$addAll](iterable);
}
asMap() {
return this[S$._base$4][S$.$asMap]();
}
cast(T) {
return this[S$._base$4][S$.$cast](T);
}
clear() {
this[S$._base$4][S$.$clear]();
}
fillRange(start, end, fillValue = null) {
if (start == null) dart.nullFailed(I[103], 204, 22, "start");
if (end == null) dart.nullFailed(I[103], 204, 33, "end");
__t$EN().as(fillValue);
this[S$._base$4][S$0.$fillRange](start, end, fillValue);
}
set first(value) {
E.as(value);
if (dart.test(this.isEmpty)) dart.throw(new core.IndexError.new(0, this));
this._set(0, value);
}
get first() {
return super.first;
}
getRange(start, end) {
if (start == null) dart.nullFailed(I[103], 215, 28, "start");
if (end == null) dart.nullFailed(I[103], 215, 39, "end");
return this[S$._base$4][S$.$getRange](start, end);
}
indexOf(element, start = 0) {
E.as(element);
if (start == null) dart.nullFailed(I[103], 218, 31, "start");
return this[S$._base$4][S$0.$indexOf](element, start);
}
indexWhere(test, start = 0) {
if (test == null) dart.nullFailed(I[103], 221, 35, "test");
if (start == null) dart.nullFailed(I[103], 221, 46, "start");
return this[S$._base$4][S$0.$indexWhere](test, start);
}
insert(index, element) {
if (index == null) dart.nullFailed(I[103], 225, 19, "index");
E.as(element);
this[S$._base$4][S$.$insert](index, element);
}
insertAll(index, iterable) {
if (index == null) dart.nullFailed(I[103], 230, 22, "index");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[103], 230, 41, "iterable");
this[S$._base$4][S$.$insertAll](index, iterable);
}
set last(value) {
E.as(value);
if (dart.test(this.isEmpty)) dart.throw(new core.IndexError.new(0, this));
this._set(dart.notNull(this.length) - 1, value);
}
get last() {
return super.last;
}
lastIndexOf(element, start = null) {
E.as(element);
return this[S$._base$4][S$0.$lastIndexOf](element, start);
}
lastIndexWhere(test, start = null) {
if (test == null) dart.nullFailed(I[103], 244, 39, "test");
return this[S$._base$4][S$0.$lastIndexWhere](test, start);
}
set length(newLength) {
if (newLength == null) dart.nullFailed(I[103], 248, 18, "newLength");
this[S$._base$4][S$.$length] = newLength;
}
get length() {
return super.length;
}
remove(value) {
return this[S$._base$4][S$.$remove](value);
}
removeAt(index) {
if (index == null) dart.nullFailed(I[103], 256, 18, "index");
return this[S$._base$4][S$.$removeAt](index);
}
removeLast() {
return this[S$._base$4][S$.$removeLast]();
}
removeRange(start, end) {
if (start == null) dart.nullFailed(I[103], 262, 24, "start");
if (end == null) dart.nullFailed(I[103], 262, 35, "end");
this[S$._base$4][S$0.$removeRange](start, end);
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[103], 267, 37, "test");
this[S$._base$4][S$.$removeWhere](test);
}
replaceRange(start, end, iterable) {
if (start == null) dart.nullFailed(I[103], 272, 25, "start");
if (end == null) dart.nullFailed(I[103], 272, 36, "end");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[103], 272, 53, "iterable");
this[S$._base$4][S$0.$replaceRange](start, end, iterable);
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[103], 277, 37, "test");
this[S$._base$4][S$0.$retainWhere](test);
}
retype(T) {
return this.cast(T);
}
get reversed() {
return this[S$._base$4][S$.$reversed];
}
setAll(index, iterable) {
if (index == null) dart.nullFailed(I[103], 289, 19, "index");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[103], 289, 38, "iterable");
this[S$._base$4][S$0.$setAll](index, iterable);
}
setRange(start, end, iterable, skipCount = 0) {
if (start == null) dart.nullFailed(I[103], 294, 21, "start");
if (end == null) dart.nullFailed(I[103], 294, 32, "end");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[103], 294, 49, "iterable");
if (skipCount == null) dart.nullFailed(I[103], 294, 64, "skipCount");
this[S$._base$4][S$.$setRange](start, end, iterable, skipCount);
}
shuffle(random = null) {
this[S$._base$4][S$0.$shuffle](random);
}
sort(compare = null) {
this[S$._base$4][S$.$sort](compare);
}
sublist(start, end = null) {
if (start == null) dart.nullFailed(I[103], 309, 23, "start");
return this[S$._base$4][S$0.$sublist](start, end);
}
}
(DelegatingList.new = function(base) {
if (base == null) dart.nullFailed(I[103], 155, 32, "base");
this[S$0._base$6] = base;
DelegatingList.__proto__.new.call(this);
;
}).prototype = DelegatingList.prototype;
DelegatingList.prototype[dart.isList] = true;
dart.addTypeTests(DelegatingList);
DelegatingList.prototype[_is_DelegatingList_default] = true;
dart.addTypeCaches(DelegatingList);
DelegatingList[dart.implements] = () => [core.List$(E)];
dart.setMethodSignature(DelegatingList, () => ({
__proto__: dart.getMethods(DelegatingList.__proto__),
_get: dart.fnType(E, [core.int]),
[S$.$_get]: dart.fnType(E, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
'+': dart.fnType(core.List$(E), [dart.nullable(core.Object)]),
[S$0.$plus]: dart.fnType(core.List$(E), [dart.nullable(core.Object)]),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$add]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addAll]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
asMap: dart.fnType(core.Map$(core.int, E), []),
[S$.$asMap]: dart.fnType(core.Map$(core.int, E), []),
cast: dart.gFnType(T => [core.List$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [core.List$(T), []], T => [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, []),
fillRange: dart.fnType(dart.void, [core.int, core.int], [dart.nullable(core.Object)]),
[S$0.$fillRange]: dart.fnType(dart.void, [core.int, core.int], [dart.nullable(core.Object)]),
getRange: dart.fnType(core.Iterable$(E), [core.int, core.int]),
[S$.$getRange]: dart.fnType(core.Iterable$(E), [core.int, core.int]),
indexOf: dart.fnType(core.int, [dart.nullable(core.Object)], [core.int]),
[S$0.$indexOf]: dart.fnType(core.int, [dart.nullable(core.Object)], [core.int]),
indexWhere: dart.fnType(core.int, [dart.fnType(core.bool, [E])], [core.int]),
[S$0.$indexWhere]: dart.fnType(core.int, [dart.fnType(core.bool, [E])], [core.int]),
insert: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$insert]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
insertAll: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$insertAll]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
lastIndexOf: dart.fnType(core.int, [dart.nullable(core.Object)], [dart.nullable(core.int)]),
[S$0.$lastIndexOf]: dart.fnType(core.int, [dart.nullable(core.Object)], [dart.nullable(core.int)]),
lastIndexWhere: dart.fnType(core.int, [dart.fnType(core.bool, [E])], [dart.nullable(core.int)]),
[S$0.$lastIndexWhere]: dart.fnType(core.int, [dart.fnType(core.bool, [E])], [dart.nullable(core.int)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeAt: dart.fnType(E, [core.int]),
[S$.$removeAt]: dart.fnType(E, [core.int]),
removeLast: dart.fnType(E, []),
[S$.$removeLast]: dart.fnType(E, []),
removeRange: dart.fnType(dart.void, [core.int, core.int]),
[S$0.$removeRange]: dart.fnType(dart.void, [core.int, core.int]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
[S$.$removeWhere]: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
replaceRange: dart.fnType(dart.void, [core.int, core.int, dart.nullable(core.Object)]),
[S$0.$replaceRange]: dart.fnType(dart.void, [core.int, core.int, dart.nullable(core.Object)]),
retainWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
[S$0.$retainWhere]: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
retype: dart.gFnType(T => [core.List$(T), []], T => [dart.nullable(core.Object)]),
setAll: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$0.$setAll]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
setRange: dart.fnType(dart.void, [core.int, core.int, dart.nullable(core.Object)], [core.int]),
[S$.$setRange]: dart.fnType(dart.void, [core.int, core.int, dart.nullable(core.Object)], [core.int]),
shuffle: dart.fnType(dart.void, [], [dart.nullable(math.Random)]),
[S$0.$shuffle]: dart.fnType(dart.void, [], [dart.nullable(math.Random)]),
sort: dart.fnType(dart.void, [], [dart.nullable(dart.fnType(core.int, [E, E]))]),
[S$.$sort]: dart.fnType(dart.void, [], [dart.nullable(dart.fnType(core.int, [E, E]))]),
sublist: dart.fnType(core.List$(E), [core.int], [dart.nullable(core.int)]),
[S$0.$sublist]: dart.fnType(core.List$(E), [core.int], [dart.nullable(core.int)])
}));
dart.setStaticMethodSignature(DelegatingList, () => ['typed']);
dart.setGetterSignature(DelegatingList, () => ({
__proto__: dart.getGetters(DelegatingList.__proto__),
reversed: core.Iterable$(E),
[S$.$reversed]: core.Iterable$(E)
}));
dart.setSetterSignature(DelegatingList, () => ({
__proto__: dart.getSetters(DelegatingList.__proto__),
first: dart.nullable(core.Object),
[S$.$first]: dart.nullable(core.Object),
last: dart.nullable(core.Object),
[S$.$last]: dart.nullable(core.Object),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(DelegatingList, I[104]);
dart.setFieldSignature(DelegatingList, () => ({
__proto__: dart.getFields(DelegatingList.__proto__),
[S$._base$4]: dart.finalFieldType(core.List$(E))
}));
dart.defineExtensionMethods(DelegatingList, [
'_get',
'_set',
'+',
'add',
'addAll',
'asMap',
'cast',
'clear',
'fillRange',
'getRange',
'indexOf',
'indexWhere',
'insert',
'insertAll',
'lastIndexOf',
'lastIndexWhere',
'remove',
'removeAt',
'removeLast',
'removeRange',
'removeWhere',
'replaceRange',
'retainWhere',
'setAll',
'setRange',
'shuffle',
'sort',
'sublist'
]);
dart.defineExtensionAccessors(DelegatingList, ['first', 'last', 'length', 'reversed']);
return DelegatingList;
});
wrappers.DelegatingList = wrappers.DelegatingList$();
dart.addTypeTests(wrappers.DelegatingList, _is_DelegatingList_default);
const _is_NonGrowableListMixin_default = Symbol('_is_NonGrowableListMixin_default');
unmodifiable_wrappers.NonGrowableListMixin$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
class NonGrowableListMixin extends core.Object {
static _throw() {
dart.throw(new core.UnsupportedError.new("Cannot change the length of a fixed-length list"));
}
set length(newLength) {
if (newLength == null) dart.nullFailed(I[119], 36, 18, "newLength");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
add(value) {
E.as(value);
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
addAll(iterable) {
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[119], 46, 27, "iterable");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
insert(index, element) {
if (index == null) dart.nullFailed(I[119], 51, 19, "index");
E.as(element);
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
insertAll(index, iterable) {
if (index == null) dart.nullFailed(I[119], 56, 22, "index");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[119], 56, 41, "iterable");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
remove(value) {
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeAt(index) {
if (index == null) dart.nullFailed(I[119], 66, 18, "index");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeLast() {
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[119], 76, 37, "test");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[119], 81, 37, "test");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
removeRange(start, end) {
if (start == null) dart.nullFailed(I[119], 86, 24, "start");
if (end == null) dart.nullFailed(I[119], 86, 35, "end");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
replaceRange(start, end, iterable) {
if (start == null) dart.nullFailed(I[119], 91, 25, "start");
if (end == null) dart.nullFailed(I[119], 91, 36, "end");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[119], 91, 53, "iterable");
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
clear() {
unmodifiable_wrappers.NonGrowableListMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
[Symbol.iterator]() {
return new dart.JsIterator(this[S$.$iterator]);
}
}
(NonGrowableListMixin.new = function() {
;
}).prototype = NonGrowableListMixin.prototype;
NonGrowableListMixin.prototype[dart.isList] = true;
dart.addTypeTests(NonGrowableListMixin);
NonGrowableListMixin.prototype[_is_NonGrowableListMixin_default] = true;
dart.addTypeCaches(NonGrowableListMixin);
NonGrowableListMixin[dart.implements] = () => [core.List$(E)];
dart.setMethodSignature(NonGrowableListMixin, () => ({
__proto__: dart.getMethods(NonGrowableListMixin.__proto__),
add: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$add]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addAll]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
insert: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$insert]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
insertAll: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$insertAll]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeAt: dart.fnType(E, [core.int]),
[S$.$removeAt]: dart.fnType(E, [core.int]),
removeLast: dart.fnType(E, []),
[S$.$removeLast]: dart.fnType(E, []),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
[S$.$removeWhere]: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
retainWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
[S$0.$retainWhere]: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
removeRange: dart.fnType(dart.void, [core.int, core.int]),
[S$0.$removeRange]: dart.fnType(dart.void, [core.int, core.int]),
replaceRange: dart.fnType(dart.void, [core.int, core.int, dart.nullable(core.Object)]),
[S$0.$replaceRange]: dart.fnType(dart.void, [core.int, core.int, dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(NonGrowableListMixin, () => ['_throw']);
dart.setSetterSignature(NonGrowableListMixin, () => ({
__proto__: dart.getSetters(NonGrowableListMixin.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(NonGrowableListMixin, I[120]);
dart.defineExtensionMethods(NonGrowableListMixin, [
'add',
'addAll',
'insert',
'insertAll',
'remove',
'removeAt',
'removeLast',
'removeWhere',
'retainWhere',
'removeRange',
'replaceRange',
'clear'
]);
dart.defineExtensionAccessors(NonGrowableListMixin, ['length']);
return NonGrowableListMixin;
});
unmodifiable_wrappers.NonGrowableListMixin = unmodifiable_wrappers.NonGrowableListMixin$();
dart.addTypeTests(unmodifiable_wrappers.NonGrowableListMixin, _is_NonGrowableListMixin_default);
const _is_NonGrowableListView_default = Symbol('_is_NonGrowableListView_default');
unmodifiable_wrappers.NonGrowableListView$ = dart.generic(E => {
const DelegatingList_NonGrowableListMixin$36 = class DelegatingList_NonGrowableListMixin extends wrappers.DelegatingList$(E) {};
(DelegatingList_NonGrowableListMixin$36.new = function(base) {
DelegatingList_NonGrowableListMixin$36.__proto__.new.call(this, base);
}).prototype = DelegatingList_NonGrowableListMixin$36.prototype;
dart.applyMixin(DelegatingList_NonGrowableListMixin$36, unmodifiable_wrappers.NonGrowableListMixin$(E));
class NonGrowableListView extends DelegatingList_NonGrowableListMixin$36 {
static ['_#new#tearOff'](E, listBase) {
if (listBase == null) dart.nullFailed(I[119], 23, 31, "listBase");
return new (unmodifiable_wrappers.NonGrowableListView$(E)).new(listBase);
}
}
(NonGrowableListView.new = function(listBase) {
if (listBase == null) dart.nullFailed(I[119], 23, 31, "listBase");
NonGrowableListView.__proto__.new.call(this, listBase);
;
}).prototype = NonGrowableListView.prototype;
dart.addTypeTests(NonGrowableListView);
NonGrowableListView.prototype[_is_NonGrowableListView_default] = true;
dart.addTypeCaches(NonGrowableListView);
dart.setLibraryUri(NonGrowableListView, I[120]);
return NonGrowableListView;
});
unmodifiable_wrappers.NonGrowableListView = unmodifiable_wrappers.NonGrowableListView$();
dart.addTypeTests(unmodifiable_wrappers.NonGrowableListView, _is_NonGrowableListView_default);
const _is_UnmodifiableSetView_default = Symbol('_is_UnmodifiableSetView_default');
unmodifiable_wrappers.UnmodifiableSetView$ = dart.generic(E => {
const DelegatingSet_UnmodifiableSetMixin$36 = class DelegatingSet_UnmodifiableSetMixin extends wrappers.DelegatingSet$(E) {};
(DelegatingSet_UnmodifiableSetMixin$36.new = function(base) {
DelegatingSet_UnmodifiableSetMixin$36.__proto__.new.call(this, base);
}).prototype = DelegatingSet_UnmodifiableSetMixin$36.prototype;
dart.applyMixin(DelegatingSet_UnmodifiableSetMixin$36, unmodifiable_wrappers.UnmodifiableSetMixin$(E));
class UnmodifiableSetView extends DelegatingSet_UnmodifiableSetMixin$36 {
static ['_#new#tearOff'](E, setBase) {
if (setBase == null) dart.nullFailed(I[119], 108, 30, "setBase");
return new (unmodifiable_wrappers.UnmodifiableSetView$(E)).new(setBase);
}
static ['_#empty#tearOff'](E) {
return new (empty_unmodifiable_set.EmptyUnmodifiableSet$(E)).new();
}
}
(UnmodifiableSetView.new = function(setBase) {
if (setBase == null) dart.nullFailed(I[119], 108, 30, "setBase");
UnmodifiableSetView.__proto__.new.call(this, setBase);
;
}).prototype = UnmodifiableSetView.prototype;
dart.addTypeTests(UnmodifiableSetView);
UnmodifiableSetView.prototype[_is_UnmodifiableSetView_default] = true;
dart.addTypeCaches(UnmodifiableSetView);
dart.setStaticMethodSignature(UnmodifiableSetView, () => ['empty']);
dart.setLibraryUri(UnmodifiableSetView, I[120]);
dart.setStaticFieldSignature(UnmodifiableSetView, () => ['_redirecting#']);
return UnmodifiableSetView;
});
unmodifiable_wrappers.UnmodifiableSetView = unmodifiable_wrappers.UnmodifiableSetView$();
dart.addTypeTests(unmodifiable_wrappers.UnmodifiableSetView, _is_UnmodifiableSetView_default);
const _is_UnmodifiableMapMixin_default = Symbol('_is_UnmodifiableMapMixin_default');
unmodifiable_wrappers.UnmodifiableMapMixin$ = dart.generic((K, V) => {
var __t$MapOfK$V = () => (__t$MapOfK$V = dart.constFn(core.Map$(K, V)))();
var __t$VoidToV = () => (__t$VoidToV = dart.constFn(dart.fnType(V, [])))();
class UnmodifiableMapMixin extends core.Object {
static _throw() {
dart.throw(new core.UnsupportedError.new("Cannot modify an unmodifiable Map"));
}
_set(key, value$) {
let value = value$;
K.as(key);
V.as(value);
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
return value$;
}
putIfAbsent(key, ifAbsent) {
K.as(key);
__t$VoidToV().as(ifAbsent);
if (ifAbsent == null) dart.nullFailed(I[119], 180, 37, "ifAbsent");
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
addAll(other) {
__t$MapOfK$V().as(other);
if (other == null) dart.nullFailed(I[119], 185, 25, "other");
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
remove(key) {
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
clear() {
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
set first(_) {
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
set last(_) {
unmodifiable_wrappers.UnmodifiableMapMixin._throw();
return dart.throw(new _internal.ReachabilityError.new("`null` encountered as the result from expression with type `Never`."));
}
}
(UnmodifiableMapMixin.new = function() {
;
}).prototype = UnmodifiableMapMixin.prototype;
UnmodifiableMapMixin.prototype[dart.isMap] = true;
dart.addTypeTests(UnmodifiableMapMixin);
UnmodifiableMapMixin.prototype[_is_UnmodifiableMapMixin_default] = true;
dart.addTypeCaches(UnmodifiableMapMixin);
UnmodifiableMapMixin[dart.implements] = () => [core.Map$(K, V)];
dart.setMethodSignature(UnmodifiableMapMixin, () => ({
__proto__: dart.getMethods(UnmodifiableMapMixin.__proto__),
_set: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [dart.nullable(core.Object), dart.nullable(core.Object)]),
putIfAbsent: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)]),
[S$.$putIfAbsent]: dart.fnType(V, [dart.nullable(core.Object), dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$.$addAll]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
remove: dart.fnType(V, [dart.nullable(core.Object)]),
[S$.$remove]: dart.fnType(V, [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
[S$.$clear]: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(UnmodifiableMapMixin, () => ['_throw']);
dart.setSetterSignature(UnmodifiableMapMixin, () => ({
__proto__: dart.getSetters(UnmodifiableMapMixin.__proto__),
first: dart.dynamic,
last: dart.dynamic
}));
dart.setLibraryUri(UnmodifiableMapMixin, I[120]);
dart.defineExtensionMethods(UnmodifiableMapMixin, [
'_set',
'putIfAbsent',
'addAll',
'remove',
'clear'
]);
return UnmodifiableMapMixin;
});
unmodifiable_wrappers.UnmodifiableMapMixin = unmodifiable_wrappers.UnmodifiableMapMixin$();
dart.addTypeTests(unmodifiable_wrappers.UnmodifiableMapMixin, _is_UnmodifiableMapMixin_default);
const _is_DelegatingIterable_default = Symbol('_is_DelegatingIterable_default');
wrappers.DelegatingIterable$ = dart.generic(E => {
class DelegatingIterable extends wrappers._DelegatingIterableBase$(E) {
get [S$._base$4]() {
return this[S$0._base$7];
}
set [S$._base$4](value) {
super[S$._base$4] = value;
}
static ['_#new#tearOff'](E, base) {
if (base == null) dart.nullFailed(I[103], 131, 40, "base");
return new (wrappers.DelegatingIterable$(E)).new(base);
}
static typed(E, base) {
if (base == null) dart.nullFailed(I[103], 143, 40, "base");
return base[S$.$cast](E);
}
}
(DelegatingIterable.new = function(base) {
if (base == null) dart.nullFailed(I[103], 131, 40, "base");
this[S$0._base$7] = base;
DelegatingIterable.__proto__.new.call(this);
;
}).prototype = DelegatingIterable.prototype;
dart.addTypeTests(DelegatingIterable);
DelegatingIterable.prototype[_is_DelegatingIterable_default] = true;
dart.addTypeCaches(DelegatingIterable);
dart.setStaticMethodSignature(DelegatingIterable, () => ['typed']);
dart.setLibraryUri(DelegatingIterable, I[104]);
dart.setFieldSignature(DelegatingIterable, () => ({
__proto__: dart.getFields(DelegatingIterable.__proto__),
[S$._base$4]: dart.finalFieldType(core.Iterable$(E))
}));
return DelegatingIterable;
});
wrappers.DelegatingIterable = wrappers.DelegatingIterable$();
dart.addTypeTests(wrappers.DelegatingIterable, _is_DelegatingIterable_default);
const _is_DelegatingQueue_default = Symbol('_is_DelegatingQueue_default');
wrappers.DelegatingQueue$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
class DelegatingQueue extends wrappers._DelegatingIterableBase$(E) {
get [S$._base$4]() {
return this[S$0._base$8];
}
set [S$._base$4](value) {
super[S$._base$4] = value;
}
static ['_#new#tearOff'](E, queue) {
if (queue == null) dart.nullFailed(I[103], 408, 34, "queue");
return new (wrappers.DelegatingQueue$(E)).new(queue);
}
static typed(E, base) {
if (base == null) dart.nullFailed(I[103], 422, 34, "base");
return base.cast(E);
}
add(value) {
E.as(value);
this[S$._base$4].add(value);
}
addAll(iterable) {
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[103], 430, 27, "iterable");
this[S$._base$4].addAll(iterable);
}
addFirst(value) {
E.as(value);
this[S$._base$4].addFirst(value);
}
addLast(value) {
E.as(value);
this[S$._base$4].addLast(value);
}
cast(T) {
return this[S$._base$4].cast(T);
}
clear() {
this[S$._base$4].clear();
}
remove(object) {
return this[S$._base$4].remove(object);
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[103], 456, 37, "test");
this[S$._base$4].removeWhere(test);
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[103], 461, 37, "test");
this[S$._base$4].retainWhere(test);
}
retype(T) {
return this.cast(T);
}
removeFirst() {
return this[S$._base$4].removeFirst();
}
removeLast() {
return this[S$._base$4].removeLast();
}
}
(DelegatingQueue.new = function(queue) {
if (queue == null) dart.nullFailed(I[103], 408, 34, "queue");
this[S$0._base$8] = queue;
DelegatingQueue.__proto__.new.call(this);
;
}).prototype = DelegatingQueue.prototype;
dart.addTypeTests(DelegatingQueue);
DelegatingQueue.prototype[_is_DelegatingQueue_default] = true;
dart.addTypeCaches(DelegatingQueue);
DelegatingQueue[dart.implements] = () => [collection.Queue$(E)];
dart.setMethodSignature(DelegatingQueue, () => ({
__proto__: dart.getMethods(DelegatingQueue.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addFirst: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addLast: dart.fnType(dart.void, [dart.nullable(core.Object)]),
cast: dart.gFnType(T => [collection.Queue$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [collection.Queue$(T), []], T => [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
retainWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [E])]),
retype: dart.gFnType(T => [collection.Queue$(T), []], T => [dart.nullable(core.Object)]),
removeFirst: dart.fnType(E, []),
removeLast: dart.fnType(E, [])
}));
dart.setStaticMethodSignature(DelegatingQueue, () => ['typed']);
dart.setLibraryUri(DelegatingQueue, I[104]);
dart.setFieldSignature(DelegatingQueue, () => ({
__proto__: dart.getFields(DelegatingQueue.__proto__),
[S$._base$4]: dart.finalFieldType(collection.Queue$(E))
}));
dart.defineExtensionMethods(DelegatingQueue, ['cast']);
return DelegatingQueue;
});
wrappers.DelegatingQueue = wrappers.DelegatingQueue$();
dart.addTypeTests(wrappers.DelegatingQueue, _is_DelegatingQueue_default);
const _is_MapKeySet_default = Symbol('_is_MapKeySet_default');
wrappers.MapKeySet$ = dart.generic(E => {
var __t$ETobool = () => (__t$ETobool = dart.constFn(dart.fnType(core.bool, [E])))();
var __t$SetOfE = () => (__t$SetOfE = dart.constFn(core.Set$(E)))();
const _DelegatingIterableBase_UnmodifiableSetMixin$36 = class _DelegatingIterableBase_UnmodifiableSetMixin extends wrappers._DelegatingIterableBase$(E) {};
(_DelegatingIterableBase_UnmodifiableSetMixin$36.new = function() {
_DelegatingIterableBase_UnmodifiableSetMixin$36.__proto__.new.call(this);
}).prototype = _DelegatingIterableBase_UnmodifiableSetMixin$36.prototype;
dart.applyMixin(_DelegatingIterableBase_UnmodifiableSetMixin$36, unmodifiable_wrappers.UnmodifiableSetMixin$(E));
class MapKeySet extends _DelegatingIterableBase_UnmodifiableSetMixin$36 {
static ['_#new#tearOff'](E, _baseMap) {
if (_baseMap == null) dart.nullFailed(I[103], 596, 18, "_baseMap");
return new (wrappers.MapKeySet$(E)).new(_baseMap);
}
get [S$._base$4]() {
return this[S$0._baseMap][S$.$keys];
}
cast(T) {
if (wrappers.MapKeySet$(T).is(this)) {
return wrappers.MapKeySet$(T).as(this);
}
return core.Set.castFrom(E, T, this);
}
contains(element) {
return this[S$0._baseMap][S$.$containsKey](element);
}
get isEmpty() {
return this[S$0._baseMap][S$.$isEmpty];
}
get isNotEmpty() {
return this[S$0._baseMap][S$.$isNotEmpty];
}
get length() {
return this[S$0._baseMap][S$.$length];
}
toString() {
return collection.SetBase.setToString(this);
}
containsAll(other) {
if (other == null) dart.nullFailed(I[103], 625, 38, "other");
return other[S$.$every](dart.bind(this, 'contains'));
}
difference(other) {
if (other == null) dart.nullFailed(I[103], 635, 34, "other");
return this.where(dart.fn(element => !dart.test(other.contains(element)), __t$ETobool()))[S$.$toSet]();
}
intersection(other) {
if (other == null) dart.nullFailed(I[103], 646, 36, "other");
return this.where(dart.bind(other, 'contains'))[S$.$toSet]();
}
lookup(element) {
return dart.throw(new core.UnsupportedError.new("MapKeySet doesn't support lookup()."));
}
retype(T) {
return core.Set.castFrom(E, T, this);
}
union(other) {
let t173;
__t$SetOfE().as(other);
if (other == null) dart.nullFailed(I[103], 666, 23, "other");
t173 = this.toSet();
return (() => {
t173.addAll(other);
return t173;
})();
}
}
(MapKeySet.new = function(_baseMap) {
if (_baseMap == null) dart.nullFailed(I[103], 596, 18, "_baseMap");
this[S$0._baseMap] = _baseMap;
MapKeySet.__proto__.new.call(this);
;
}).prototype = MapKeySet.prototype;
dart.addTypeTests(MapKeySet);
MapKeySet.prototype[_is_MapKeySet_default] = true;
dart.addTypeCaches(MapKeySet);
dart.setMethodSignature(MapKeySet, () => ({
__proto__: dart.getMethods(MapKeySet.__proto__),
cast: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
containsAll: dart.fnType(core.bool, [core.Iterable$(dart.nullable(core.Object))]),
difference: dart.fnType(core.Set$(E), [core.Set$(dart.nullable(core.Object))]),
intersection: dart.fnType(core.Set$(E), [core.Set$(dart.nullable(core.Object))]),
lookup: dart.fnType(E, [dart.nullable(core.Object)]),
retype: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
union: dart.fnType(core.Set$(E), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(MapKeySet, () => ({
__proto__: dart.getGetters(MapKeySet.__proto__),
[S$._base$4]: core.Iterable$(E)
}));
dart.setLibraryUri(MapKeySet, I[104]);
dart.setFieldSignature(MapKeySet, () => ({
__proto__: dart.getFields(MapKeySet.__proto__),
[S$0._baseMap]: dart.finalFieldType(core.Map$(E, dart.dynamic))
}));
dart.defineExtensionMethods(MapKeySet, ['cast', 'contains', 'toString']);
dart.defineExtensionAccessors(MapKeySet, ['isEmpty', 'isNotEmpty', 'length']);
return MapKeySet;
});
wrappers.MapKeySet = wrappers.MapKeySet$();
dart.addTypeTests(wrappers.MapKeySet, _is_MapKeySet_default);
const _is_MapValueSet_default = Symbol('_is_MapValueSet_default');
wrappers.MapValueSet$ = dart.generic((K, V) => {
var __t$KAndVTovoid = () => (__t$KAndVTovoid = dart.constFn(dart.fnType(dart.void, [K, V])))();
var __t$VoidToV = () => (__t$VoidToV = dart.constFn(dart.fnType(V, [])))();
var __t$IterableOfV = () => (__t$IterableOfV = dart.constFn(core.Iterable$(V)))();
var __t$VTobool = () => (__t$VTobool = dart.constFn(dart.fnType(core.bool, [V])))();
var __t$_IdentityHashSetOfV = () => (__t$_IdentityHashSetOfV = dart.constFn(collection._IdentityHashSet$(V)))();
var __t$SetOfV = () => (__t$SetOfV = dart.constFn(core.Set$(V)))();
class MapValueSet extends wrappers._DelegatingIterableBase$(V) {
static ['_#new#tearOff'](K, V, _baseMap, _keyForValue) {
if (_baseMap == null) dart.nullFailed(I[103], 699, 20, "_baseMap");
if (_keyForValue == null) dart.nullFailed(I[103], 699, 35, "_keyForValue");
return new (wrappers.MapValueSet$(K, V)).new(_baseMap, _keyForValue);
}
get [S$._base$4]() {
return this[S$0._baseMap][S$.$values];
}
cast(T) {
if (core.Set$(T).is(this)) {
return core.Set$(T).as(this);
}
return core.Set.castFrom(V, T, this);
}
contains(element) {
let t173;
if (!V.is(element)) return false;
let key = (t173 = element, this[S$0._keyForValue](t173));
return this[S$0._baseMap][S$.$containsKey](key);
}
get isEmpty() {
return this[S$0._baseMap][S$.$isEmpty];
}
get isNotEmpty() {
return this[S$0._baseMap][S$.$isNotEmpty];
}
get length() {
return this[S$0._baseMap][S$.$length];
}
toString() {
return dart.toString(this.toSet());
}
add(value) {
let t173;
V.as(value);
let key = (t173 = value, this[S$0._keyForValue](t173));
let result = false;
this[S$0._baseMap][S$.$putIfAbsent](key, dart.fn(() => {
result = true;
return value;
}, __t$VoidToV()));
return result;
}
addAll(elements) {
__t$IterableOfV().as(elements);
if (elements == null) dart.nullFailed(I[103], 744, 27, "elements");
return elements[S$.$forEach](dart.bind(this, 'add'));
}
clear() {
return this[S$0._baseMap][S$.$clear]();
}
containsAll(other) {
if (other == null) dart.nullFailed(I[103], 750, 38, "other");
return other[S$.$every](dart.bind(this, 'contains'));
}
difference(other) {
if (other == null) dart.nullFailed(I[103], 760, 34, "other");
return this.where(dart.fn(element => !dart.test(other.contains(element)), __t$VTobool()))[S$.$toSet]();
}
intersection(other) {
if (other == null) dart.nullFailed(I[103], 771, 36, "other");
return this.where(dart.bind(other, 'contains'))[S$.$toSet]();
}
lookup(element) {
let t173;
if (!V.is(element)) return null;
let key = (t173 = element, this[S$0._keyForValue](t173));
return this[S$0._baseMap][S$.$_get](key);
}
remove(element) {
let t173;
if (!V.is(element)) return false;
let key = (t173 = element, this[S$0._keyForValue](t173));
if (!dart.test(this[S$0._baseMap][S$.$containsKey](key))) return false;
this[S$0._baseMap][S$.$remove](key);
return true;
}
removeAll(elements) {
if (elements == null) dart.nullFailed(I[103], 792, 36, "elements");
return elements[S$.$forEach](dart.bind(this, 'remove'));
}
removeWhere(test) {
if (test == null) dart.nullFailed(I[103], 795, 37, "test");
let toRemove = [];
this[S$0._baseMap][S$.$forEach](dart.fn((key, value) => {
if (dart.test(test(value))) toRemove[S$.$add](key);
}, __t$KAndVTovoid()));
toRemove[S$.$forEach](dart.bind(this[S$0._baseMap], S$.$remove));
}
retainAll(elements) {
let t173, t173$;
if (elements == null) dart.nullFailed(I[103], 804, 36, "elements");
let valuesToRetain = new (__t$_IdentityHashSetOfV()).new();
for (let element of elements) {
if (!V.is(element)) continue;
let key = (t173 = element, this[S$0._keyForValue](t173));
if (!dart.test(this[S$0._baseMap][S$.$containsKey](key))) continue;
valuesToRetain.add((t173$ = this[S$0._baseMap][S$.$_get](key), t173$ == null ? V.as(null) : t173$));
}
let keysToRemove = [];
this[S$0._baseMap][S$.$forEach](dart.fn((k, v) => {
if (!dart.test(valuesToRetain.contains(v))) keysToRemove[S$.$add](k);
}, __t$KAndVTovoid()));
keysToRemove[S$.$forEach](dart.bind(this[S$0._baseMap], S$.$remove));
}
retainWhere(test) {
if (test == null) dart.nullFailed(I[103], 822, 37, "test");
return this.removeWhere(dart.fn(element => !dart.test(test(element)), __t$VTobool()));
}
retype(T) {
return core.Set.castFrom(V, T, this);
}
union(other) {
let t173;
__t$SetOfV().as(other);
if (other == null) dart.nullFailed(I[103], 837, 23, "other");
t173 = this.toSet();
return (() => {
t173.addAll(other);
return t173;
})();
}
}
(MapValueSet.new = function(_baseMap, _keyForValue) {
if (_baseMap == null) dart.nullFailed(I[103], 699, 20, "_baseMap");
if (_keyForValue == null) dart.nullFailed(I[103], 699, 35, "_keyForValue");
this[S$0._baseMap] = _baseMap;
this[S$0._keyForValue] = _keyForValue;
MapValueSet.__proto__.new.call(this);
;
}).prototype = MapValueSet.prototype;
dart.addTypeTests(MapValueSet);
MapValueSet.prototype[_is_MapValueSet_default] = true;
dart.addTypeCaches(MapValueSet);
MapValueSet[dart.implements] = () => [core.Set$(V)];
dart.setMethodSignature(MapValueSet, () => ({
__proto__: dart.getMethods(MapValueSet.__proto__),
cast: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
add: dart.fnType(core.bool, [dart.nullable(core.Object)]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)]),
clear: dart.fnType(dart.void, []),
containsAll: dart.fnType(core.bool, [core.Iterable$(dart.nullable(core.Object))]),
difference: dart.fnType(core.Set$(V), [core.Set$(dart.nullable(core.Object))]),
intersection: dart.fnType(core.Set$(V), [core.Set$(dart.nullable(core.Object))]),
lookup: dart.fnType(dart.nullable(V), [dart.nullable(core.Object)]),
remove: dart.fnType(core.bool, [dart.nullable(core.Object)]),
removeAll: dart.fnType(dart.void, [core.Iterable$(dart.nullable(core.Object))]),
removeWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [V])]),
retainAll: dart.fnType(dart.void, [core.Iterable$(dart.nullable(core.Object))]),
retainWhere: dart.fnType(dart.void, [dart.fnType(core.bool, [V])]),
retype: dart.gFnType(T => [core.Set$(T), []], T => [dart.nullable(core.Object)]),
union: dart.fnType(core.Set$(V), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(MapValueSet, () => ({
__proto__: dart.getGetters(MapValueSet.__proto__),
[S$._base$4]: core.Iterable$(V)
}));
dart.setLibraryUri(MapValueSet, I[104]);
dart.setFieldSignature(MapValueSet, () => ({
__proto__: dart.getFields(MapValueSet.__proto__),
[S$0._baseMap]: dart.finalFieldType(core.Map$(K, V)),
[S$0._keyForValue]: dart.finalFieldType(dart.fnType(K, [V]))
}));
dart.defineExtensionMethods(MapValueSet, ['cast', 'contains', 'toString']);
dart.defineExtensionAccessors(MapValueSet, ['isEmpty', 'isNotEmpty', 'length']);
return MapValueSet;
});
wrappers.MapValueSet = wrappers.MapValueSet$();
dart.addTypeTests(wrappers.MapValueSet, _is_MapValueSet_default);
EntryPoint.EntryPoint = class EntryPoint extends IResource.IResource {};
(EntryPoint.EntryPoint.new = function() {
EntryPoint.EntryPoint.__proto__.new.call(this);
;
}).prototype = EntryPoint.EntryPoint.prototype;
dart.addTypeTests(EntryPoint.EntryPoint);
dart.addTypeCaches(EntryPoint.EntryPoint);
dart.setLibraryUri(EntryPoint.EntryPoint, I[124]);
utils.defaultCompare = function defaultCompare(value1, value2) {
return T$.ComparableOfObjectN().as(value1)[S$.$compareTo](value2);
};
utils.identity = function identity(T, value) {
return value;
};
utils.compareComparable = function compareComparable(T, a, b) {
if (a == null) dart.nullFailed(I[125], 20, 50, "a");
if (b == null) dart.nullFailed(I[125], 20, 55, "b");
return a[S$.$compareTo](b);
};
const _is_CombinedIterator_default = Symbol('_is_CombinedIterator_default');
combined_iterator.CombinedIterator$ = dart.generic(T => {
class CombinedIterator extends core.Object {
static ['_#new#tearOff'](T, iterators) {
if (iterators == null) dart.nullFailed(I[126], 15, 42, "iterators");
return new (combined_iterator.CombinedIterator$(T)).new(iterators);
}
get current() {
let iterators = this[S$0._iterators$1];
if (iterators != null) return iterators.current.current;
return T.as(null);
}
moveNext() {
let iterators = this[S$0._iterators$1];
if (iterators != null) {
do {
if (dart.test(iterators.current.moveNext())) {
return true;
}
} while (dart.test(iterators.moveNext()));
this[S$0._iterators$1] = null;
}
return false;
}
}
(CombinedIterator.new = function(iterators) {
if (iterators == null) dart.nullFailed(I[126], 15, 42, "iterators");
this[S$0._iterators$1] = iterators;
if (!dart.test(iterators.moveNext())) this[S$0._iterators$1] = null;
}).prototype = CombinedIterator.prototype;
dart.addTypeTests(CombinedIterator);
CombinedIterator.prototype[_is_CombinedIterator_default] = true;
dart.addTypeCaches(CombinedIterator);
CombinedIterator[dart.implements] = () => [core.Iterator$(T)];
dart.setMethodSignature(CombinedIterator, () => ({
__proto__: dart.getMethods(CombinedIterator.__proto__),
moveNext: dart.fnType(core.bool, [])
}));
dart.setGetterSignature(CombinedIterator, () => ({
__proto__: dart.getGetters(CombinedIterator.__proto__),
current: T
}));
dart.setLibraryUri(CombinedIterator, I[127]);
dart.setFieldSignature(CombinedIterator, () => ({
__proto__: dart.getFields(CombinedIterator.__proto__),
[S$0._iterators$1]: dart.fieldType(dart.nullable(core.Iterator$(core.Iterator$(T))))
}));
return CombinedIterator;
});
combined_iterator.CombinedIterator = combined_iterator.CombinedIterator$();
dart.addTypeTests(combined_iterator.CombinedIterator, _is_CombinedIterator_default);
const _is_EmptyUnmodifiableSet_default = Symbol('_is_EmptyUnmodifiableSet_default');
empty_unmodifiable_set.EmptyUnmodifiableSet$ = dart.generic(E => {
var __t$EmptyIterableOfE = () => (__t$EmptyIterableOfE = dart.constFn(_internal.EmptyIterable$(E)))();
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$DelegatingIterableOfE = () => (__t$DelegatingIterableOfE = dart.constFn(wrappers.DelegatingIterable$(E)))();
var __t$VoidToE = () => (__t$VoidToE = dart.constFn(dart.fnType(E, [])))();
var __t$VoidToNE = () => (__t$VoidToNE = dart.constFn(dart.nullable(__t$VoidToE())))();
var __t$LinkedHashSetOfE = () => (__t$LinkedHashSetOfE = dart.constFn(collection.LinkedHashSet$(E)))();
var __t$SetOfE = () => (__t$SetOfE = dart.constFn(core.Set$(E)))();
const IterableBase_UnmodifiableSetMixin$36 = class IterableBase_UnmodifiableSetMixin extends collection.IterableBase$(E) {};
(IterableBase_UnmodifiableSetMixin$36.new = function() {
IterableBase_UnmodifiableSetMixin$36.__proto__.new.call(this);
}).prototype = IterableBase_UnmodifiableSetMixin$36.prototype;
dart.applyMixin(IterableBase_UnmodifiableSetMixin$36, unmodifiable_wrappers.UnmodifiableSetMixin$(E));
class EmptyUnmodifiableSet extends IterableBase_UnmodifiableSetMixin$36 {
static ['_#new#tearOff'](E) {
return new (empty_unmodifiable_set.EmptyUnmodifiableSet$(E)).new();
}
get iterator() {
return new (__t$EmptyIterableOfE()).new()[S$.$iterator];
}
get length() {
return 0;
}
cast(T) {
return new (empty_unmodifiable_set.EmptyUnmodifiableSet$(T)).new();
}
contains(element) {
return false;
}
containsAll(other) {
if (other == null) dart.nullFailed(I[128], 26, 38, "other");
return other[S$.$isEmpty];
}
followedBy(other) {
__t$IterableOfE().as(other);
if (other == null) dart.nullFailed(I[128], 28, 38, "other");
return new (__t$DelegatingIterableOfE()).new(other);
}
lookup(element) {
return null;
}
retype(T) {
return new (empty_unmodifiable_set.EmptyUnmodifiableSet$(T)).new();
}
singleWhere(test, opts) {
if (test == null) dart.nullFailed(I[128], 35, 34, "test");
let orElse = opts && 'orElse' in opts ? opts.orElse : null;
__t$VoidToNE().as(orElse);
return orElse != null ? orElse() : dart.throw(new core.StateError.new("No element"));
}
whereType(T) {
return new (_internal.EmptyIterable$(T)).new();
}
toSet() {
return __t$LinkedHashSetOfE().new();
}
union(other) {
__t$SetOfE().as(other);
if (other == null) dart.nullFailed(I[128], 42, 23, "other");
return __t$LinkedHashSetOfE().of(other);
}
intersection(other) {
if (other == null) dart.nullFailed(I[128], 44, 36, "other");
return __t$LinkedHashSetOfE().new();
}
difference(other) {
if (other == null) dart.nullFailed(I[128], 46, 34, "other");
return __t$LinkedHashSetOfE().new();
}
get [S$._base$4]() {
return __t$SetOfE().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[179] || CT.C179)));
}
}
(EmptyUnmodifiableSet.new = function() {
EmptyUnmodifiableSet.__proto__.new.call(this);
;
}).prototype = EmptyUnmodifiableSet.prototype;
dart.addTypeTests(EmptyUnmodifiableSet);
EmptyUnmodifiableSet.prototype[_is_EmptyUnmodifiableSet_default] = true;
dart.addTypeCaches(EmptyUnmodifiableSet);
EmptyUnmodifiableSet[dart.implements] = () => [unmodifiable_wrappers.UnmodifiableSetView$(E)];
dart.setMethodSignature(EmptyUnmodifiableSet, () => ({
__proto__: dart.getMethods(EmptyUnmodifiableSet.__proto__),
cast: dart.gFnType(T => [empty_unmodifiable_set.EmptyUnmodifiableSet$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [empty_unmodifiable_set.EmptyUnmodifiableSet$(T), []], T => [dart.nullable(core.Object)]),
containsAll: dart.fnType(core.bool, [core.Iterable$(dart.nullable(core.Object))]),
lookup: dart.fnType(dart.nullable(E), [dart.nullable(core.Object)]),
retype: dart.gFnType(T => [empty_unmodifiable_set.EmptyUnmodifiableSet$(T), []], T => [dart.nullable(core.Object)]),
whereType: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)]),
[S$.$whereType]: dart.gFnType(T => [core.Iterable$(T), []], T => [dart.nullable(core.Object)]),
union: dart.fnType(core.Set$(E), [dart.nullable(core.Object)]),
intersection: dart.fnType(core.Set$(E), [core.Set$(dart.nullable(core.Object))]),
difference: dart.fnType(core.Set$(E), [core.Set$(dart.nullable(core.Object))])
}));
dart.setGetterSignature(EmptyUnmodifiableSet, () => ({
__proto__: dart.getGetters(EmptyUnmodifiableSet.__proto__),
iterator: core.Iterator$(E),
[S$.$iterator]: core.Iterator$(E),
[S$._base$4]: core.Set$(E)
}));
dart.setLibraryUri(EmptyUnmodifiableSet, I[129]);
dart.defineExtensionMethods(EmptyUnmodifiableSet, [
'cast',
'contains',
'followedBy',
'singleWhere',
'whereType',
'toSet'
]);
dart.defineExtensionAccessors(EmptyUnmodifiableSet, ['iterator', 'length']);
return EmptyUnmodifiableSet;
});
empty_unmodifiable_set.EmptyUnmodifiableSet = empty_unmodifiable_set.EmptyUnmodifiableSet$();
dart.addTypeTests(empty_unmodifiable_set.EmptyUnmodifiableSet, _is_EmptyUnmodifiableSet_default);
const _is_StreamChannelMixin_default = Symbol('_is_StreamChannelMixin_default');
stream_channel.StreamChannelMixin$ = dart.generic(T => {
var __t$StreamChannelOfT = () => (__t$StreamChannelOfT = dart.constFn(stream_channel.StreamChannel$(T)))();
var __t$StreamTransformerOfT$T = () => (__t$StreamTransformerOfT$T = dart.constFn(async.StreamTransformer$(T, T)))();
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$StreamOfTToStreamOfT = () => (__t$StreamOfTToStreamOfT = dart.constFn(dart.fnType(__t$StreamOfT(), [__t$StreamOfT()])))();
var __t$StreamSinkTransformerOfT$T = () => (__t$StreamSinkTransformerOfT$T = dart.constFn(stream_sink_transformer.StreamSinkTransformer$(T, T)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
var __t$StreamSinkOfTToStreamSinkOfT = () => (__t$StreamSinkOfTToStreamSinkOfT = dart.constFn(dart.fnType(__t$StreamSinkOfT(), [__t$StreamSinkOfT()])))();
class StreamChannelMixin extends core.Object {
pipe(other) {
__t$StreamChannelOfT().as(other);
if (other == null) dart.nullFailed(I[131], 153, 30, "other");
this.stream.pipe(other.sink);
other.stream.pipe(this.sink);
}
transform(S, transformer) {
stream_channel_transformer.StreamChannelTransformer$(S, T).as(transformer);
if (transformer == null) dart.nullFailed(I[131], 159, 64, "transformer");
return transformer.bind(this);
}
transformStream(transformer) {
__t$StreamTransformerOfT$T().as(transformer);
if (transformer == null) dart.nullFailed(I[131], 163, 60, "transformer");
return this.changeStream(__t$StreamOfTToStreamOfT().as(dart.bind(transformer, 'bind')));
}
transformSink(transformer) {
__t$StreamSinkTransformerOfT$T().as(transformer);
if (transformer == null) dart.nullFailed(I[131], 167, 62, "transformer");
return this.changeSink(__t$StreamSinkOfTToStreamSinkOfT().as(dart.bind(transformer, 'bind')));
}
changeStream(change) {
__t$StreamOfTToStreamOfT().as(change);
if (change == null) dart.nullFailed(I[131], 171, 63, "change");
return __t$StreamChannelOfT().withCloseGuarantee(change(this.stream), this.sink);
}
changeSink(change) {
__t$StreamSinkOfTToStreamSinkOfT().as(change);
if (change == null) dart.nullFailed(I[131], 175, 69, "change");
return __t$StreamChannelOfT().withCloseGuarantee(this.stream, change(this.sink));
}
cast(S) {
let t173;
return stream_channel.StreamChannel$(S).new(this.stream.cast(S), (t173 = async.StreamController$(S).new({sync: true}), (() => {
t173.stream.cast(T).pipe(this.sink);
return t173;
})()));
}
}
(StreamChannelMixin.new = function() {
;
}).prototype = StreamChannelMixin.prototype;
dart.addTypeTests(StreamChannelMixin);
StreamChannelMixin.prototype[_is_StreamChannelMixin_default] = true;
dart.addTypeCaches(StreamChannelMixin);
StreamChannelMixin[dart.implements] = () => [stream_channel.StreamChannel$(T)];
dart.setMethodSignature(StreamChannelMixin, () => ({
__proto__: dart.getMethods(StreamChannelMixin.__proto__),
pipe: dart.fnType(dart.void, [dart.nullable(core.Object)]),
transform: dart.gFnType(S => [stream_channel.StreamChannel$(S), [dart.nullable(core.Object)]], S => [dart.nullable(core.Object)]),
transformStream: dart.fnType(stream_channel.StreamChannel$(T), [dart.nullable(core.Object)]),
transformSink: dart.fnType(stream_channel.StreamChannel$(T), [dart.nullable(core.Object)]),
changeStream: dart.fnType(stream_channel.StreamChannel$(T), [dart.nullable(core.Object)]),
changeSink: dart.fnType(stream_channel.StreamChannel$(T), [dart.nullable(core.Object)]),
cast: dart.gFnType(S => [stream_channel.StreamChannel$(S), []], S => [dart.nullable(core.Object)])
}));
dart.setLibraryUri(StreamChannelMixin, I[132]);
return StreamChannelMixin;
});
stream_channel.StreamChannelMixin = stream_channel.StreamChannelMixin$();
dart.addTypeTests(stream_channel.StreamChannelMixin, _is_StreamChannelMixin_default);
channel$.WebSocketChannel = class WebSocketChannel extends stream_channel.StreamChannelMixin {
get protocol() {
return this[S$0._webSocket].protocol;
}
get closeCode() {
return this[S$0._webSocket].closeCode;
}
get closeReason() {
return this[S$0._webSocket].closeReason;
}
get stream() {
return new async.StreamView.new(this[S$0._webSocket]);
}
get sink() {
return new channel$.WebSocketSink.__(this[S$0._webSocket]);
}
static signKey(key) {
if (key == null) dart.nullFailed(I[130], 71, 32, "key");
return convert.base64.encode(sha1.sha1.convert((dart.notNull(key) + dart.notNull(web_socket_impl.webSocketGUID))[S$0.$codeUnits]).bytes);
}
static ['_#new#tearOff'](channel, opts) {
if (channel == null) dart.nullFailed(I[130], 98, 45, "channel");
let protocol = opts && 'protocol' in opts ? opts.protocol : null;
let pingInterval = opts && 'pingInterval' in opts ? opts.pingInterval : null;
let serverSide = opts && 'serverSide' in opts ? opts.serverSide : true;
if (serverSide == null) dart.nullFailed(I[130], 99, 55, "serverSide");
return new channel$.WebSocketChannel.new(channel, {protocol: protocol, pingInterval: pingInterval, serverSide: serverSide});
}
static connect(uri, opts) {
if (uri == null) dart.nullFailed(I[130], 110, 40, "uri");
let protocols = opts && 'protocols' in opts ? opts.protocols : null;
return _connect_html.connect(uri, {protocols: protocols});
}
static ['_#connect#tearOff'](uri, opts) {
if (uri == null) dart.nullFailed(I[130], 110, 40, "uri");
let protocols = opts && 'protocols' in opts ? opts.protocols : null;
return channel$.WebSocketChannel.connect(uri, {protocols: protocols});
}
};
(channel$.WebSocketChannel.new = function(channel, opts) {
let t173;
if (channel == null) dart.nullFailed(I[130], 98, 45, "channel");
let protocol = opts && 'protocol' in opts ? opts.protocol : null;
let pingInterval = opts && 'pingInterval' in opts ? opts.pingInterval : null;
let serverSide = opts && 'serverSide' in opts ? opts.serverSide : true;
if (serverSide == null) dart.nullFailed(I[130], 99, 55, "serverSide");
this[S$0._webSocket] = (t173 = new web_socket_impl.WebSocketImpl.fromSocket(channel.stream, channel.sink, protocol, serverSide), (() => {
t173.pingInterval = pingInterval;
return t173;
})());
;
}).prototype = channel$.WebSocketChannel.prototype;
dart.addTypeTests(channel$.WebSocketChannel);
dart.addTypeCaches(channel$.WebSocketChannel);
dart.setStaticMethodSignature(channel$.WebSocketChannel, () => ['signKey', 'connect']);
dart.setGetterSignature(channel$.WebSocketChannel, () => ({
__proto__: dart.getGetters(channel$.WebSocketChannel.__proto__),
protocol: dart.nullable(core.String),
closeCode: dart.nullable(core.int),
closeReason: dart.nullable(core.String),
stream: async.Stream,
sink: channel$.WebSocketSink
}));
dart.setLibraryUri(channel$.WebSocketChannel, I[133]);
dart.setFieldSignature(channel$.WebSocketChannel, () => ({
__proto__: dart.getFields(channel$.WebSocketChannel.__proto__),
[S$0._webSocket]: dart.finalFieldType(web_socket_impl.WebSocketImpl)
}));
const _is_DelegatingStreamSink_default = Symbol('_is_DelegatingStreamSink_default');
stream_sink.DelegatingStreamSink$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
class DelegatingStreamSink extends core.Object {
get done() {
return this[S$0._sink].done;
}
static ['_#new#tearOff'](T, sink) {
if (sink == null) dart.nullFailed(I[134], 18, 38, "sink");
return new (stream_sink.DelegatingStreamSink$(T)).new(sink);
}
static ['_#_#tearOff'](T, _sink) {
if (_sink == null) dart.nullFailed(I[134], 20, 31, "_sink");
return new (stream_sink.DelegatingStreamSink$(T)).__(_sink);
}
static typed(T, sink) {
if (sink == null) dart.nullFailed(I[134], 30, 44, "sink");
return async.StreamSink$(T).is(sink) ? sink : new (stream_sink.DelegatingStreamSink$(T)).__(sink);
}
add(data) {
T.as(data);
this[S$0._sink].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[134], 39, 17, "error");
this[S$0._sink].addError(error, stackTrace);
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[134], 44, 30, "stream");
return this[S$0._sink].addStream(stream);
}
close() {
return this[S$0._sink].close();
}
}
(DelegatingStreamSink.new = function(sink) {
if (sink == null) dart.nullFailed(I[134], 18, 38, "sink");
this[S$0._sink] = sink;
;
}).prototype = DelegatingStreamSink.prototype;
(DelegatingStreamSink.__ = function(_sink) {
if (_sink == null) dart.nullFailed(I[134], 20, 31, "_sink");
this[S$0._sink] = _sink;
;
}).prototype = DelegatingStreamSink.prototype;
dart.addTypeTests(DelegatingStreamSink);
DelegatingStreamSink.prototype[_is_DelegatingStreamSink_default] = true;
dart.addTypeCaches(DelegatingStreamSink);
DelegatingStreamSink[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(DelegatingStreamSink, () => ({
__proto__: dart.getMethods(DelegatingStreamSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, [])
}));
dart.setStaticMethodSignature(DelegatingStreamSink, () => ['typed']);
dart.setGetterSignature(DelegatingStreamSink, () => ({
__proto__: dart.getGetters(DelegatingStreamSink.__proto__),
done: async.Future
}));
dart.setLibraryUri(DelegatingStreamSink, I[135]);
dart.setFieldSignature(DelegatingStreamSink, () => ({
__proto__: dart.getFields(DelegatingStreamSink.__proto__),
[S$0._sink]: dart.finalFieldType(async.StreamSink)
}));
return DelegatingStreamSink;
});
stream_sink.DelegatingStreamSink = stream_sink.DelegatingStreamSink$();
dart.addTypeTests(stream_sink.DelegatingStreamSink, _is_DelegatingStreamSink_default);
channel$.WebSocketSink = class WebSocketSink extends stream_sink.DelegatingStreamSink {
static ['_#_#tearOff'](webSocket) {
if (webSocket == null) dart.nullFailed(I[130], 121, 33, "webSocket");
return new channel$.WebSocketSink.__(webSocket);
}
close(closeCode = null, closeReason = null) {
return this[S$0._webSocket].close(closeCode, closeReason);
}
};
(channel$.WebSocketSink.__ = function(webSocket) {
if (webSocket == null) dart.nullFailed(I[130], 121, 33, "webSocket");
this[S$0._webSocket] = webSocket;
channel$.WebSocketSink.__proto__.new.call(this, webSocket);
;
}).prototype = channel$.WebSocketSink.prototype;
dart.addTypeTests(channel$.WebSocketSink);
dart.addTypeCaches(channel$.WebSocketSink);
dart.setMethodSignature(channel$.WebSocketSink, () => ({
__proto__: dart.getMethods(channel$.WebSocketSink.__proto__),
close: dart.fnType(async.Future, [], [dart.nullable(core.int), dart.nullable(core.String)])
}));
dart.setLibraryUri(channel$.WebSocketSink, I[133]);
dart.setFieldSignature(channel$.WebSocketSink, () => ({
__proto__: dart.getFields(channel$.WebSocketSink.__proto__),
[S$0._webSocket]: dart.finalFieldType(web_socket_impl.WebSocketImpl)
}));
exception.WebSocketChannelException = class WebSocketChannelException extends core.Object {
get message() {
return this[S$0.message$1];
}
set message(value) {
super.message = value;
}
get inner() {
return this[S$0.inner];
}
set inner(value) {
super.inner = value;
}
static ['_#new#tearOff'](message = null) {
return new exception.WebSocketChannelException.new(message);
}
static ['_#from#tearOff'](inner) {
return new exception.WebSocketChannelException.from(inner);
}
toString() {
return this.message == null ? "WebSocketChannelException" : "WebSocketChannelException: " + dart.str(this.message);
}
};
(exception.WebSocketChannelException.new = function(message = null) {
this[S$0.message$1] = message;
this[S$0.inner] = null;
;
}).prototype = exception.WebSocketChannelException.prototype;
(exception.WebSocketChannelException.from = function(inner) {
this[S$0.inner] = inner;
this[S$0.message$1] = dart.toString(inner);
;
}).prototype = exception.WebSocketChannelException.prototype;
dart.addTypeTests(exception.WebSocketChannelException);
dart.addTypeCaches(exception.WebSocketChannelException);
exception.WebSocketChannelException[dart.implements] = () => [core.Exception];
dart.setLibraryUri(exception.WebSocketChannelException, I[136]);
dart.setFieldSignature(exception.WebSocketChannelException, () => ({
__proto__: dart.getFields(exception.WebSocketChannelException.__proto__),
message: dart.finalFieldType(dart.nullable(core.String)),
inner: dart.finalFieldType(dart.nullable(core.Object))
}));
dart.defineExtensionMethods(exception.WebSocketChannelException, ['toString']);
const _is_StreamChannel_default = Symbol('_is_StreamChannel_default');
stream_channel.StreamChannel$ = dart.generic(T => {
class StreamChannel extends core.Object {
static new(stream, sink) {
if (stream == null) dart.nullFailed(I[131], 73, 35, "stream");
if (sink == null) dart.nullFailed(I[131], 73, 57, "sink");
return new (stream_channel._StreamChannel$(T)).new(stream, sink);
}
static ['_#new#tearOff'](T, stream, sink) {
if (stream == null) dart.nullFailed(I[131], 73, 35, "stream");
if (sink == null) dart.nullFailed(I[131], 73, 57, "sink");
return stream_channel.StreamChannel$(T).new(stream, sink);
}
static withGuarantees(stream, sink, opts) {
if (stream == null) dart.nullFailed(I[131], 86, 50, "stream");
if (sink == null) dart.nullFailed(I[131], 86, 72, "sink");
let allowSinkErrors = opts && 'allowSinkErrors' in opts ? opts.allowSinkErrors : true;
if (allowSinkErrors == null) dart.nullFailed(I[131], 87, 17, "allowSinkErrors");
return new (guarantee_channel.GuaranteeChannel$(T)).new(stream, sink, {allowSinkErrors: allowSinkErrors});
}
static ['_#withGuarantees#tearOff'](T, stream, sink, opts) {
if (stream == null) dart.nullFailed(I[131], 86, 50, "stream");
if (sink == null) dart.nullFailed(I[131], 86, 72, "sink");
let allowSinkErrors = opts && 'allowSinkErrors' in opts ? opts.allowSinkErrors : true;
if (allowSinkErrors == null) dart.nullFailed(I[131], 87, 17, "allowSinkErrors");
return stream_channel.StreamChannel$(T).withGuarantees(stream, sink, {allowSinkErrors: allowSinkErrors});
}
static withCloseGuarantee(stream, sink) {
if (stream == null) dart.nullFailed(I[131], 100, 21, "stream");
if (sink == null) dart.nullFailed(I[131], 100, 43, "sink");
return new (close_guarantee_channel.CloseGuaranteeChannel$(T)).new(stream, sink);
}
static ['_#withCloseGuarantee#tearOff'](T, stream, sink) {
if (stream == null) dart.nullFailed(I[131], 100, 21, "stream");
if (sink == null) dart.nullFailed(I[131], 100, 43, "sink");
return stream_channel.StreamChannel$(T).withCloseGuarantee(stream, sink);
}
}
(StreamChannel[dart.mixinNew] = function() {
}).prototype = StreamChannel.prototype;
dart.addTypeTests(StreamChannel);
StreamChannel.prototype[_is_StreamChannel_default] = true;
dart.addTypeCaches(StreamChannel);
dart.setStaticMethodSignature(StreamChannel, () => ['new', 'withGuarantees', 'withCloseGuarantee']);
dart.setLibraryUri(StreamChannel, I[132]);
return StreamChannel;
});
stream_channel.StreamChannel = stream_channel.StreamChannel$();
dart.addTypeTests(stream_channel.StreamChannel, _is_StreamChannel_default);
const _is__StreamChannel_default = Symbol('_is__StreamChannel_default');
stream_channel._StreamChannel$ = dart.generic(T => {
class _StreamChannel extends stream_channel.StreamChannelMixin$(T) {
static ['_#new#tearOff'](T, stream, sink) {
if (stream == null) dart.nullFailed(I[131], 146, 23, "stream");
if (sink == null) dart.nullFailed(I[131], 146, 36, "sink");
return new (stream_channel._StreamChannel$(T)).new(stream, sink);
}
}
(_StreamChannel.new = function(stream, sink) {
if (stream == null) dart.nullFailed(I[131], 146, 23, "stream");
if (sink == null) dart.nullFailed(I[131], 146, 36, "sink");
this.stream = stream;
this.sink = sink;
;
}).prototype = _StreamChannel.prototype;
dart.addTypeTests(_StreamChannel);
_StreamChannel.prototype[_is__StreamChannel_default] = true;
dart.addTypeCaches(_StreamChannel);
dart.setLibraryUri(_StreamChannel, I[132]);
dart.setFieldSignature(_StreamChannel, () => ({
__proto__: dart.getFields(_StreamChannel.__proto__),
stream: dart.finalFieldType(async.Stream$(T)),
sink: dart.finalFieldType(async.StreamSink$(T))
}));
return _StreamChannel;
});
stream_channel._StreamChannel = stream_channel._StreamChannel$();
dart.addTypeTests(stream_channel._StreamChannel, _is__StreamChannel_default);
_connect_html.connect = function connect(uri, opts) {
if (uri == null) dart.nullFailed(I[137], 15, 30, "uri");
let protocols = opts && 'protocols' in opts ? opts.protocols : null;
return new html$.HtmlWebSocketChannel.connect(uri, {protocols: protocols});
};
web_socket_impl._WebSocketMessageType = class _WebSocketMessageType extends core.Object {
static ['_#new#tearOff']() {
return new web_socket_impl._WebSocketMessageType.new();
}
};
(web_socket_impl._WebSocketMessageType.new = function() {
;
}).prototype = web_socket_impl._WebSocketMessageType.prototype;
dart.addTypeTests(web_socket_impl._WebSocketMessageType);
dart.addTypeCaches(web_socket_impl._WebSocketMessageType);
dart.setLibraryUri(web_socket_impl._WebSocketMessageType, I[138]);
dart.setStaticFieldSignature(web_socket_impl._WebSocketMessageType, () => ['NONE', 'TEXT', 'BINARY']);
dart.defineLazy(web_socket_impl._WebSocketMessageType, {
/*web_socket_impl._WebSocketMessageType.NONE*/get NONE() {
return 0;
},
/*web_socket_impl._WebSocketMessageType.TEXT*/get TEXT() {
return 1;
},
/*web_socket_impl._WebSocketMessageType.BINARY*/get BINARY() {
return 2;
}
}, false);
web_socket_impl._WebSocketOpcode = class _WebSocketOpcode extends core.Object {
static ['_#new#tearOff']() {
return new web_socket_impl._WebSocketOpcode.new();
}
};
(web_socket_impl._WebSocketOpcode.new = function() {
;
}).prototype = web_socket_impl._WebSocketOpcode.prototype;
dart.addTypeTests(web_socket_impl._WebSocketOpcode);
dart.addTypeCaches(web_socket_impl._WebSocketOpcode);
dart.setLibraryUri(web_socket_impl._WebSocketOpcode, I[138]);
dart.setStaticFieldSignature(web_socket_impl._WebSocketOpcode, () => ['CONTINUATION', 'TEXT', 'BINARY', 'RESERVED_3', 'RESERVED_4', 'RESERVED_5', 'RESERVED_6', 'RESERVED_7', 'CLOSE', 'PING', 'PONG', 'RESERVED_B', 'RESERVED_C', 'RESERVED_D', 'RESERVED_E', 'RESERVED_F']);
dart.defineLazy(web_socket_impl._WebSocketOpcode, {
/*web_socket_impl._WebSocketOpcode.CONTINUATION*/get CONTINUATION() {
return 0;
},
/*web_socket_impl._WebSocketOpcode.TEXT*/get TEXT() {
return 1;
},
/*web_socket_impl._WebSocketOpcode.BINARY*/get BINARY() {
return 2;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_3*/get RESERVED_3() {
return 3;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_4*/get RESERVED_4() {
return 4;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_5*/get RESERVED_5() {
return 5;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_6*/get RESERVED_6() {
return 6;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_7*/get RESERVED_7() {
return 7;
},
/*web_socket_impl._WebSocketOpcode.CLOSE*/get CLOSE() {
return 8;
},
/*web_socket_impl._WebSocketOpcode.PING*/get PING() {
return 9;
},
/*web_socket_impl._WebSocketOpcode.PONG*/get PONG() {
return 10;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_B*/get RESERVED_B() {
return 11;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_C*/get RESERVED_C() {
return 12;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_D*/get RESERVED_D() {
return 13;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_E*/get RESERVED_E() {
return 14;
},
/*web_socket_impl._WebSocketOpcode.RESERVED_F*/get RESERVED_F() {
return 15;
}
}, false);
web_socket_impl._WebSocketProtocolTransformer = class _WebSocketProtocolTransformer extends async.StreamTransformerBase$(core.List$(core.int), dart.dynamic) {
static ['_#new#tearOff'](_serverSide = false) {
if (_serverSide == null) dart.nullFailed(I[139], 98, 39, "_serverSide");
return new web_socket_impl._WebSocketProtocolTransformer.new(_serverSide);
}
bind(stream) {
T$.StreamOfListOfint().as(stream);
if (stream == null) dart.nullFailed(I[139], 102, 29, "stream");
return async.Stream.eventTransformed(stream, dart.fn(eventSink => {
if (eventSink == null) dart.nullFailed(I[139], 103, 50, "eventSink");
if (this[S$0._eventSink] != null) {
dart.throw(new core.StateError.new("WebSocket transformer already used."));
}
this[S$0._eventSink] = eventSink;
return this;
}, T$.EventSinkTo_WebSocketProtocolTransformer()));
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[139], 112, 24, "error");
dart.nullCheck(this[S$0._eventSink]).addError(error, stackTrace);
}
close() {
dart.nullCheck(this[S$0._eventSink]).close();
}
add(bytes) {
let t173;
T$.ListOfint().as(bytes);
if (bytes == null) dart.nullFailed(I[139], 123, 22, "bytes");
let buffer = typed_data.Uint8List.is(bytes) ? bytes : _native_typed_data.NativeUint8List.fromList(bytes);
let index = 0;
let lastIndex = buffer[S$.$length];
if (this[S$0._state$3] === 5) {
dart.throw(new exception.WebSocketChannelException.new("Data on closed connection"));
}
if (this[S$0._state$3] === 6) {
dart.throw(new exception.WebSocketChannelException.new("Data on failed connection"));
}
while (index < dart.notNull(lastIndex) && this[S$0._state$3] !== 5 && this[S$0._state$3] !== 6) {
let byte = buffer[S$.$_get](index);
if (dart.notNull(this[S$0._state$3]) <= 2) {
if (this[S$0._state$3] === 0) {
this[S$0._fin] = (dart.notNull(byte) & 128) !== 0;
if ((dart.notNull(byte) & (32 | 16) >>> 0) !== 0) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
this[S$0._opcode] = (dart.notNull(byte) & 15) >>> 0;
if (dart.notNull(this[S$0._opcode]) <= 2) {
if (this[S$0._opcode] === 0) {
if (this[S$0._currentMessageType] === 0) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
} else {
if (!(this[S$0._opcode] === 1 || this[S$0._opcode] === 2)) dart.assertFailed(null, I[139], 152, 22, "_opcode == _WebSocketOpcode.TEXT ||\n _opcode == _WebSocketOpcode.BINARY");
if (this[S$0._currentMessageType] !== 0) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
this[S$0._currentMessageType] = this[S$0._opcode];
}
} else if (dart.notNull(this[S$0._opcode]) >= 8 && dart.notNull(this[S$0._opcode]) <= 10) {
if (!dart.test(this[S$0._fin])) dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
} else {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
this[S$0._state$3] = 1;
} else if (this[S$0._state$3] === 1) {
this[S$0._masked] = (dart.notNull(byte) & 128) !== 0;
this[S$0._len] = dart.notNull(byte) & 127;
if (dart.test(this[S$0._isControlFrame]()) && dart.notNull(this[S$0._len]) > 125) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
if (this[S$0._len] === 126) {
this[S$0._len] = 0;
this[S$0._remainingLenBytes] = 2;
this[S$0._state$3] = 2;
} else if (this[S$0._len] === 127) {
this[S$0._len] = 0;
this[S$0._remainingLenBytes] = 8;
this[S$0._state$3] = 2;
} else {
if (!(dart.notNull(this[S$0._len]) < 126)) dart.assertFailed(null, I[139], 182, 20, "_len < 126");
this[S$0._lengthDone]();
}
} else {
if (!(this[S$0._state$3] === 2)) dart.assertFailed(null, I[139], 186, 18, "_state == LEN_REST");
this[S$0._len] = (dart.notNull(this[S$0._len]) << 8 | dart.notNull(byte)) >>> 0;
this[S$0._remainingLenBytes] = dart.notNull(this[S$0._remainingLenBytes]) - 1;
if (this[S$0._remainingLenBytes] === 0) {
this[S$0._lengthDone]();
}
}
} else {
if (this[S$0._state$3] === 3) {
this[S$0._maskingBytes][S$.$_set](4 - dart.notNull((t173 = this[S$0._remainingMaskingKeyBytes], this[S$0._remainingMaskingKeyBytes] = dart.notNull(t173) - 1, t173)), byte);
if (this[S$0._remainingMaskingKeyBytes] === 0) {
this[S$0._maskDone]();
}
} else {
if (!(this[S$0._state$3] === 4)) dart.assertFailed(null, I[139], 200, 18, "_state == PAYLOAD");
let payloadLength = math.min(core.int, dart.notNull(lastIndex) - index, this[S$0._remainingPayloadBytes]);
this[S$0._remainingPayloadBytes] = dart.notNull(this[S$0._remainingPayloadBytes]) - payloadLength;
if (dart.test(this[S$0._masked])) {
this[S$0._unmask](index, payloadLength, buffer);
}
this[S$0._payload].add(typed_data.Uint8List.view(buffer[S$.$buffer], index, payloadLength));
index = index + payloadLength;
if (dart.test(this[S$0._isControlFrame]())) {
if (this[S$0._remainingPayloadBytes] === 0) this[S$0._controlFrameEnd]();
} else {
if (this[S$0._currentMessageType] !== 1 && this[S$0._currentMessageType] !== 2) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
if (this[S$0._remainingPayloadBytes] === 0) this[S$0._messageFrameEnd]();
}
index = index - 1;
}
}
index = index + 1;
}
}
[S$0._unmask](index, length, buffer) {
let t175, t174, t173, t173$, t175$, t174$, t173$0;
if (index == null) dart.nullFailed(I[139], 231, 20, "index");
if (length == null) dart.nullFailed(I[139], 231, 31, "length");
if (buffer == null) dart.nullFailed(I[139], 231, 49, "buffer");
if (dart.notNull(length) >= 16) {
let startOffset = 16 - (dart.notNull(index) & 15);
let end = dart.notNull(index) + startOffset;
for (let i = index; dart.notNull(i) < end; i = dart.notNull(i) + 1) {
t173 = buffer;
t174 = i;
t173[S$.$_set](t174, (dart.notNull(t173[S$.$_get](t174)) ^ dart.notNull(this[S$0._maskingBytes][S$.$_get](dart.notNull((t175 = this[S$0._unmaskingIndex], this[S$0._unmaskingIndex] = dart.notNull(t175) + 1, t175)) & 3))) >>> 0);
}
index = dart.notNull(index) + startOffset;
length = dart.notNull(length) - startOffset;
let blockCount = (dart.notNull(length) / 16)[S$.$truncate]();
if (blockCount > 0) {
let mask = 0;
for (let i = 3; i >= 0; i = i - 1) {
mask = (mask << 8 | dart.notNull(this[S$0._maskingBytes][S$.$_get](dart.notNull(this[S$0._unmaskingIndex]) + i & 3))) >>> 0;
}
let blockMask = new _native_typed_data.NativeInt32x4.new(mask, mask, mask, mask);
let blockBuffer = typed_data.Int32x4List.view(buffer[S$.$buffer], index, blockCount);
for (let i = 0; i < dart.notNull(blockBuffer[S$.$length]); i = i + 1) {
t173$ = i;
blockBuffer[S$.$_set](t173$, blockBuffer[S$.$_get](t173$)['^'](blockMask));
}
let bytes = blockCount * 16;
index = dart.notNull(index) + bytes;
length = dart.notNull(length) - bytes;
}
}
let end = dart.notNull(index) + dart.notNull(length);
for (let i = index; dart.notNull(i) < end; i = dart.notNull(i) + 1) {
t173$0 = buffer;
t174$ = i;
t173$0[S$.$_set](t174$, (dart.notNull(t173$0[S$.$_get](t174$)) ^ dart.notNull(this[S$0._maskingBytes][S$.$_get](dart.notNull((t175$ = this[S$0._unmaskingIndex], this[S$0._unmaskingIndex] = dart.notNull(t175$) + 1, t175$)) & 3))) >>> 0);
}
}
[S$0._lengthDone]() {
if (dart.test(this[S$0._masked])) {
if (!dart.test(this[S$0._serverSide])) {
dart.throw(new exception.WebSocketChannelException.new("Received masked frame from server"));
}
this[S$0._state$3] = 3;
} else {
if (dart.test(this[S$0._serverSide])) {
dart.throw(new exception.WebSocketChannelException.new("Received unmasked frame from client"));
}
this[S$0._remainingPayloadBytes] = this[S$0._len];
this[S$0._startPayload]();
}
}
[S$0._maskDone]() {
this[S$0._remainingPayloadBytes] = this[S$0._len];
this[S$0._startPayload]();
}
[S$0._startPayload]() {
if (this[S$0._remainingPayloadBytes] === 0) {
if (dart.test(this[S$0._isControlFrame]())) {
switch (this[S$0._opcode]) {
case 8:
{
this[S$0._state$3] = 5;
dart.nullCheck(this[S$0._eventSink]).close();
break;
}
case 9:
{
dart.nullCheck(this[S$0._eventSink]).add(new web_socket_impl._WebSocketPing.new());
break;
}
case 10:
{
dart.nullCheck(this[S$0._eventSink]).add(new web_socket_impl._WebSocketPong.new());
break;
}
}
this[S$0._prepareForNextFrame]();
} else {
this[S$0._messageFrameEnd]();
}
} else {
this[S$0._state$3] = 4;
}
}
[S$0._messageFrameEnd]() {
if (dart.test(this[S$0._fin])) {
let bytes = this[S$0._payload].takeBytes();
switch (this[S$0._currentMessageType]) {
case 1:
{
dart.nullCheck(this[S$0._eventSink]).add(convert.utf8.decode(bytes));
break;
}
case 2:
{
dart.nullCheck(this[S$0._eventSink]).add(bytes);
break;
}
}
this[S$0._currentMessageType] = 0;
}
this[S$0._prepareForNextFrame]();
}
[S$0._controlFrameEnd]() {
switch (this[S$0._opcode]) {
case 8:
{
this.closeCode = 1005;
let payload = this[S$0._payload].takeBytes();
if (dart.test(payload[S$.$isNotEmpty])) {
if (payload[S$.$length] === 1) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
this.closeCode = (dart.notNull(payload[S$.$_get](0)) << 8 | dart.notNull(payload[S$.$_get](1))) >>> 0;
if (this.closeCode === 1005) {
dart.throw(new exception.WebSocketChannelException.new("Protocol error"));
}
if (dart.notNull(payload[S$.$length]) > 2) {
this.closeReason = convert.utf8.decode(payload[S$0.$sublist](2));
}
}
this[S$0._state$3] = 5;
dart.nullCheck(this[S$0._eventSink]).close();
break;
}
case 9:
{
dart.nullCheck(this[S$0._eventSink]).add(new web_socket_impl._WebSocketPing.new(this[S$0._payload].takeBytes()));
break;
}
case 10:
{
dart.nullCheck(this[S$0._eventSink]).add(new web_socket_impl._WebSocketPong.new(this[S$0._payload].takeBytes()));
break;
}
}
this[S$0._prepareForNextFrame]();
}
[S$0._isControlFrame]() {
return this[S$0._opcode] === 8 || this[S$0._opcode] === 9 || this[S$0._opcode] === 10;
}
[S$0._prepareForNextFrame]() {
if (this[S$0._state$3] !== 5 && this[S$0._state$3] !== 6) this[S$0._state$3] = 0;
this[S$0._fin] = false;
this[S$0._opcode] = -1;
this[S$0._len] = -1;
this[S$0._remainingLenBytes] = -1;
this[S$0._remainingMaskingKeyBytes] = 4;
this[S$0._remainingPayloadBytes] = -1;
this[S$0._unmaskingIndex] = 0;
}
};
(web_socket_impl._WebSocketProtocolTransformer.new = function(_serverSide = false) {
if (_serverSide == null) dart.nullFailed(I[139], 98, 39, "_serverSide");
this[S$0._state$3] = 0;
this[S$0._fin] = false;
this[S$0._opcode] = -1;
this[S$0._len] = -1;
this[S$0._masked] = false;
this[S$0._remainingLenBytes] = -1;
this[S$0._remainingMaskingKeyBytes] = 4;
this[S$0._remainingPayloadBytes] = -1;
this[S$0._unmaskingIndex] = 0;
this[S$0._currentMessageType] = 0;
this.closeCode = 1005;
this.closeReason = "";
this[S$0._eventSink] = null;
this[S$0._maskingBytes] = T$.ListOfint().filled(4, 0);
this[S$0._payload] = _internal.BytesBuilder.new({copy: false});
this[S$0._serverSide] = _serverSide;
web_socket_impl._WebSocketProtocolTransformer.__proto__.new.call(this);
;
}).prototype = web_socket_impl._WebSocketProtocolTransformer.prototype;
dart.addTypeTests(web_socket_impl._WebSocketProtocolTransformer);
dart.addTypeCaches(web_socket_impl._WebSocketProtocolTransformer);
web_socket_impl._WebSocketProtocolTransformer[dart.implements] = () => [async.EventSink$(core.List$(core.int))];
dart.setMethodSignature(web_socket_impl._WebSocketProtocolTransformer, () => ({
__proto__: dart.getMethods(web_socket_impl._WebSocketProtocolTransformer.__proto__),
bind: dart.fnType(async.Stream, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
close: dart.fnType(dart.void, []),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._unmask]: dart.fnType(dart.void, [core.int, core.int, typed_data.Uint8List]),
[S$0._lengthDone]: dart.fnType(dart.void, []),
[S$0._maskDone]: dart.fnType(dart.void, []),
[S$0._startPayload]: dart.fnType(dart.void, []),
[S$0._messageFrameEnd]: dart.fnType(dart.void, []),
[S$0._controlFrameEnd]: dart.fnType(dart.void, []),
[S$0._isControlFrame]: dart.fnType(core.bool, []),
[S$0._prepareForNextFrame]: dart.fnType(dart.void, [])
}));
dart.setLibraryUri(web_socket_impl._WebSocketProtocolTransformer, I[138]);
dart.setFieldSignature(web_socket_impl._WebSocketProtocolTransformer, () => ({
__proto__: dart.getFields(web_socket_impl._WebSocketProtocolTransformer.__proto__),
[S$0._state$3]: dart.fieldType(core.int),
[S$0._fin]: dart.fieldType(core.bool),
[S$0._opcode]: dart.fieldType(core.int),
[S$0._len]: dart.fieldType(core.int),
[S$0._masked]: dart.fieldType(core.bool),
[S$0._remainingLenBytes]: dart.fieldType(core.int),
[S$0._remainingMaskingKeyBytes]: dart.fieldType(core.int),
[S$0._remainingPayloadBytes]: dart.fieldType(core.int),
[S$0._unmaskingIndex]: dart.fieldType(core.int),
[S$0._currentMessageType]: dart.fieldType(core.int),
closeCode: dart.fieldType(core.int),
closeReason: dart.fieldType(core.String),
[S$0._eventSink]: dart.fieldType(dart.nullable(async.EventSink)),
[S$0._serverSide]: dart.finalFieldType(core.bool),
[S$0._maskingBytes]: dart.finalFieldType(core.List$(core.int)),
[S$0._payload]: dart.finalFieldType(_internal.BytesBuilder)
}));
dart.setStaticFieldSignature(web_socket_impl._WebSocketProtocolTransformer, () => ['START', 'LEN_FIRST', 'LEN_REST', 'MASK', 'PAYLOAD', 'CLOSED', 'FAILURE', 'FIN', 'RSV1', 'RSV2', 'RSV3', 'OPCODE']);
dart.defineLazy(web_socket_impl._WebSocketProtocolTransformer, {
/*web_socket_impl._WebSocketProtocolTransformer.START*/get START() {
return 0;
},
/*web_socket_impl._WebSocketProtocolTransformer.LEN_FIRST*/get LEN_FIRST() {
return 1;
},
/*web_socket_impl._WebSocketProtocolTransformer.LEN_REST*/get LEN_REST() {
return 2;
},
/*web_socket_impl._WebSocketProtocolTransformer.MASK*/get MASK() {
return 3;
},
/*web_socket_impl._WebSocketProtocolTransformer.PAYLOAD*/get PAYLOAD() {
return 4;
},
/*web_socket_impl._WebSocketProtocolTransformer.CLOSED*/get CLOSED() {
return 5;
},
/*web_socket_impl._WebSocketProtocolTransformer.FAILURE*/get FAILURE() {
return 6;
},
/*web_socket_impl._WebSocketProtocolTransformer.FIN*/get FIN() {
return 128;
},
/*web_socket_impl._WebSocketProtocolTransformer.RSV1*/get RSV1() {
return 64;
},
/*web_socket_impl._WebSocketProtocolTransformer.RSV2*/get RSV2() {
return 32;
},
/*web_socket_impl._WebSocketProtocolTransformer.RSV3*/get RSV3() {
return 16;
},
/*web_socket_impl._WebSocketProtocolTransformer.OPCODE*/get OPCODE() {
return 15;
}
}, false);
web_socket_impl._WebSocketPing = class _WebSocketPing extends core.Object {
static ['_#new#tearOff'](payload = null) {
return new web_socket_impl._WebSocketPing.new(payload);
}
};
(web_socket_impl._WebSocketPing.new = function(payload = null) {
this.payload = payload;
;
}).prototype = web_socket_impl._WebSocketPing.prototype;
dart.addTypeTests(web_socket_impl._WebSocketPing);
dart.addTypeCaches(web_socket_impl._WebSocketPing);
dart.setLibraryUri(web_socket_impl._WebSocketPing, I[138]);
dart.setFieldSignature(web_socket_impl._WebSocketPing, () => ({
__proto__: dart.getFields(web_socket_impl._WebSocketPing.__proto__),
payload: dart.finalFieldType(dart.nullable(core.List$(core.int)))
}));
web_socket_impl._WebSocketPong = class _WebSocketPong extends core.Object {
static ['_#new#tearOff'](payload = null) {
return new web_socket_impl._WebSocketPong.new(payload);
}
};
(web_socket_impl._WebSocketPong.new = function(payload = null) {
this.payload = payload;
;
}).prototype = web_socket_impl._WebSocketPong.prototype;
dart.addTypeTests(web_socket_impl._WebSocketPong);
dart.addTypeCaches(web_socket_impl._WebSocketPong);
dart.setLibraryUri(web_socket_impl._WebSocketPong, I[138]);
dart.setFieldSignature(web_socket_impl._WebSocketPong, () => ({
__proto__: dart.getFields(web_socket_impl._WebSocketPong.__proto__),
payload: dart.finalFieldType(dart.nullable(core.List$(core.int)))
}));
web_socket_impl._WebSocketOutgoingTransformer = class _WebSocketOutgoingTransformer extends async.StreamTransformerBase$(dart.dynamic, core.List$(core.int)) {
static ['_#new#tearOff'](webSocket) {
if (webSocket == null) dart.nullFailed(I[139], 397, 38, "webSocket");
return new web_socket_impl._WebSocketOutgoingTransformer.new(webSocket);
}
bind(stream) {
async.Stream.as(stream);
if (stream == null) dart.nullFailed(I[139], 400, 33, "stream");
return T$.StreamOfListOfint().eventTransformed(stream, dart.fn(eventSink => {
if (eventSink == null) dart.nullFailed(I[139], 402, 33, "eventSink");
if (this[S$0._eventSink] != null) {
dart.throw(new core.StateError.new("WebSocket transformer already used"));
}
this[S$0._eventSink] = eventSink;
return this;
}, T$.EventSinkOfListOfintTo_WebSocketOutgoingTransformer()));
}
add(message) {
if (web_socket_impl._WebSocketPong.is(message)) {
this.addFrame(10, message.payload);
return;
}
if (web_socket_impl._WebSocketPing.is(message)) {
this.addFrame(9, message.payload);
return;
}
let data = null;
let opcode = null;
if (message != null) {
if (typeof message == 'string') {
opcode = 1;
data = convert.utf8.encode(message);
} else if (T$.ListOfint().is(message)) {
opcode = 2;
data = message;
} else {
dart.throw(new core.ArgumentError.new(message));
}
} else {
opcode = 1;
}
this.addFrame(opcode, data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[139], 439, 24, "error");
dart.nullCheck(this[S$0._eventSink]).addError(error, stackTrace);
}
close() {
let code = this.webSocket[S$0._outCloseCode];
let reason = this.webSocket[S$0._outCloseReason];
let data = null;
if (code != null) {
data = T$.JSArrayOfint().of([]);
data[S$.$add](dart.notNull(code) >> 8 & 255);
data[S$.$add](dart.notNull(code) & 255);
if (reason != null) {
data[S$.$addAll](convert.utf8.encode(reason));
}
}
this.addFrame(8, data);
dart.nullCheck(this[S$0._eventSink]).close();
}
addFrame(opcode, data) {
if (opcode == null) dart.nullFailed(I[139], 460, 21, "opcode");
web_socket_impl._WebSocketOutgoingTransformer.createFrame(opcode, data, this.webSocket[S$0._serverSide], false)[S$.$forEach](dart.fn(e => {
if (e == null) dart.nullFailed(I[139], 468, 19, "e");
dart.nullCheck(this[S$0._eventSink]).add(e);
}, T$.ListOfintTovoid()));
}
static createFrame(opcode, data, serverSide, compressed) {
let t173, t173$, t173$0, t173$1, t173$2, t173$3, t174, t173$4;
if (opcode == null) dart.nullFailed(I[139], 474, 11, "opcode");
if (serverSide == null) dart.nullFailed(I[139], 474, 41, "serverSide");
if (compressed == null) dart.nullFailed(I[139], 474, 58, "compressed");
let mask = !dart.test(serverSide);
let dataLength = data == null ? 0 : data[S$.$length];
let headerSize = mask ? 6 : 2;
if (dart.notNull(dataLength) > 65535) {
headerSize = headerSize + 8;
} else if (dart.notNull(dataLength) > 125) {
headerSize = headerSize + 2;
}
let header = _native_typed_data.NativeUint8List.new(headerSize);
let index = 0;
let hoc = (128 | (dart.test(compressed) ? 64 : 0) | (dart.notNull(opcode) & 15) >>> 0) >>> 0;
header[S$.$_set]((t173 = index, index = t173 + 1, t173), hoc);
let lengthBytes = 1;
if (dart.notNull(dataLength) > 65535) {
header[S$.$_set]((t173$ = index, index = t173$ + 1, t173$), 127);
lengthBytes = 8;
} else if (dart.notNull(dataLength) > 125) {
header[S$.$_set]((t173$0 = index, index = t173$0 + 1, t173$0), 126);
lengthBytes = 2;
}
for (let i = 0; i < lengthBytes; i = i + 1) {
header[S$.$_set]((t173$1 = index, index = t173$1 + 1, t173$1), dataLength[S$.$rightShift]((lengthBytes - 1 - i) * 8) & 255);
}
if (mask) {
t173$2 = 1;
header[S$.$_set](t173$2, (dart.notNull(header[S$.$_get](t173$2)) | 1 << 7) >>> 0);
let maskBytes = T$.JSArrayOfint().of([web_socket_impl._random.nextInt(256), web_socket_impl._random.nextInt(256), web_socket_impl._random.nextInt(256), web_socket_impl._random.nextInt(256)]);
header[S$.$setRange](index, index + 4, maskBytes);
index = index + 4;
if (data != null) {
let list = null;
if (opcode === 1 && typed_data.Uint8List.is(data)) {
list = data;
} else {
if (typed_data.Uint8List.is(data)) {
list = _native_typed_data.NativeUint8List.fromList(data);
} else {
list = _native_typed_data.NativeUint8List.new(data[S$.$length]);
for (let i = 0; i < dart.notNull(data[S$.$length]); i = i + 1) {
if (dart.notNull(data[S$.$_get](i)) < 0 || 255 < dart.notNull(data[S$.$_get](i))) {
dart.throw(new core.ArgumentError.new("List element is not a byte value " + "(value " + dart.str(data[S$.$_get](i)) + " at index " + dart.str(i) + ")"));
}
list[S$.$_set](i, data[S$.$_get](i));
}
}
}
let blockCount = (dart.notNull(list[S$.$length]) / 16)[S$.$truncate]();
if (blockCount > 0) {
let mask = 0;
for (let i = 3; i >= 0; i = i - 1) {
mask = (mask << 8 | dart.notNull(maskBytes[S$.$_get](i))) >>> 0;
}
let blockMask = new _native_typed_data.NativeInt32x4.new(mask, mask, mask, mask);
let blockBuffer = typed_data.Int32x4List.view(list[S$.$buffer], 0, blockCount);
for (let i = 0; i < dart.notNull(blockBuffer[S$.$length]); i = i + 1) {
t173$3 = i;
blockBuffer[S$.$_set](t173$3, blockBuffer[S$.$_get](t173$3)['^'](blockMask));
}
}
for (let i = blockCount * 16; i < dart.notNull(list[S$.$length]); i = i + 1) {
t173$4 = list;
t174 = i;
t173$4[S$.$_set](t174, (dart.notNull(t173$4[S$.$_get](t174)) ^ dart.notNull(maskBytes[S$.$_get](i & 3))) >>> 0);
}
data = list;
}
}
if (!(index === headerSize)) dart.assertFailed(null, I[139], 557, 12, "index == headerSize");
if (data == null) {
return T$.JSArrayOfListOfint().of([header]);
} else {
return T$.JSArrayOfListOfint().of([header, data]);
}
}
};
(web_socket_impl._WebSocketOutgoingTransformer.new = function(webSocket) {
if (webSocket == null) dart.nullFailed(I[139], 397, 38, "webSocket");
this[S$0._eventSink] = null;
this.webSocket = webSocket;
web_socket_impl._WebSocketOutgoingTransformer.__proto__.new.call(this);
;
}).prototype = web_socket_impl._WebSocketOutgoingTransformer.prototype;
dart.addTypeTests(web_socket_impl._WebSocketOutgoingTransformer);
dart.addTypeCaches(web_socket_impl._WebSocketOutgoingTransformer);
web_socket_impl._WebSocketOutgoingTransformer[dart.implements] = () => [async.EventSink];
dart.setMethodSignature(web_socket_impl._WebSocketOutgoingTransformer, () => ({
__proto__: dart.getMethods(web_socket_impl._WebSocketOutgoingTransformer.__proto__),
bind: dart.fnType(async.Stream$(core.List$(core.int)), [dart.nullable(core.Object)]),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
close: dart.fnType(dart.void, []),
addFrame: dart.fnType(dart.void, [core.int, dart.nullable(core.List$(core.int))])
}));
dart.setStaticMethodSignature(web_socket_impl._WebSocketOutgoingTransformer, () => ['createFrame']);
dart.setLibraryUri(web_socket_impl._WebSocketOutgoingTransformer, I[138]);
dart.setFieldSignature(web_socket_impl._WebSocketOutgoingTransformer, () => ({
__proto__: dart.getFields(web_socket_impl._WebSocketOutgoingTransformer.__proto__),
webSocket: dart.finalFieldType(web_socket_impl.WebSocketImpl),
[S$0._eventSink]: dart.fieldType(dart.nullable(async.EventSink$(core.List$(core.int))))
}));
web_socket_impl._WebSocketConsumer = class _WebSocketConsumer extends core.Object {
static ['_#new#tearOff'](webSocket, sink) {
if (webSocket == null) dart.nullFailed(I[139], 578, 27, "webSocket");
if (sink == null) dart.nullFailed(I[139], 578, 43, "sink");
return new web_socket_impl._WebSocketConsumer.new(webSocket, sink);
}
[S$0._onListen]() {
if (this[S$0._subscription] != null) {
dart.nullCheck(this[S$0._subscription]).cancel();
}
}
[S$0._onPause]() {
if (this[S$0._subscription] != null) {
dart.nullCheck(this[S$0._subscription]).pause();
} else {
this[S$0._issuedPause] = true;
}
}
[S$0._onResume]() {
if (this[S$0._subscription] != null) {
dart.nullCheck(this[S$0._subscription]).resume();
} else {
this[S$0._issuedPause] = false;
}
}
[S$0._cancel]() {
if (this[S$0._subscription] != null) {
let subscription = this[S$0._subscription];
this[S$0._subscription] = null;
dart.nullCheck(subscription).cancel();
}
}
[S$0._ensureController]() {
if (this[S$0._controller] != null) return;
this[S$0._controller] = async.StreamController.new({sync: true, onPause: dart.bind(this, S$0._onPause), onResume: dart.bind(this, S$0._onResume), onCancel: dart.bind(this, S$0._onListen)});
let stream = new web_socket_impl._WebSocketOutgoingTransformer.new(this.webSocket).bind(dart.nullCheck(this[S$0._controller]).stream);
this.sink.addStream(stream).then(core.Null, dart.fn(_ => {
this[S$0._done]();
this[S$0._closeCompleter].complete(this.webSocket);
}, T$.dynamicToNull()), {onError: dart.fn((error, stackTrace) => {
if (stackTrace == null) dart.nullFailed(I[139], 622, 36, "stackTrace");
this[S$0._closed] = true;
this[S$0._cancel]();
if (core.ArgumentError.is(error)) {
if (!dart.test(this[S$0._done](error, stackTrace))) {
this[S$0._closeCompleter].completeError(error, stackTrace);
}
} else {
this[S$0._done]();
this[S$0._closeCompleter].complete(this.webSocket);
}
}, T$.dynamicAndStackTraceToNull())});
}
[S$0._done](error = null, stackTrace = null) {
if (this[S$0._completer] == null) return false;
if (error != null) {
dart.nullCheck(this[S$0._completer]).completeError(error, stackTrace);
} else {
dart.nullCheck(this[S$0._completer]).complete(this.webSocket);
}
this[S$0._completer] = null;
return true;
}
addStream(stream) {
async.Stream.as(stream);
if (stream == null) dart.nullFailed(I[139], 648, 24, "stream");
if (dart.test(this[S$0._closed])) {
stream.listen(null).cancel();
return async.Future.value(this.webSocket);
}
this[S$0._ensureController]();
this[S$0._completer] = T$.CompleterOfWebSocketImpl().new();
this[S$0._subscription] = stream.listen(dart.fn(data => {
dart.nullCheck(this[S$0._controller]).add(data);
}, T$.dynamicTovoid()), {onDone: dart.bind(this, S$0._done), onError: dart.bind(this, S$0._done), cancelOnError: true});
if (dart.test(this[S$0._issuedPause])) {
dart.nullCheck(this[S$0._subscription]).pause();
this[S$0._issuedPause] = false;
}
return dart.nullCheck(this[S$0._completer]).future;
}
close() {
this[S$0._ensureController]();
const closeSocket = () => {
return this.sink.close().catchError(dart.fn(_ => {
}, T$.dynamicToNull())).then(dart.dynamic, dart.fn(_ => this.webSocket, T$.dynamicToWebSocketImpl()));
};
dart.fn(closeSocket, T$.VoidToFuture());
dart.nullCheck(this[S$0._controller]).close();
return this[S$0._closeCompleter].future.then(dart.dynamic, dart.fn(_ => closeSocket(), T$.dynamicToFuture()));
}
add(data) {
if (dart.test(this[S$0._closed])) return;
this[S$0._ensureController]();
dart.nullCheck(this[S$0._controller]).add(data);
}
closeSocket() {
this[S$0._closed] = true;
this[S$0._cancel]();
this.close();
}
};
(web_socket_impl._WebSocketConsumer.new = function(webSocket, sink) {
if (webSocket == null) dart.nullFailed(I[139], 578, 27, "webSocket");
if (sink == null) dart.nullFailed(I[139], 578, 43, "sink");
this[S$0._controller] = null;
this[S$0._subscription] = null;
this[S$0._issuedPause] = false;
this[S$0._closed] = false;
this[S$0._closeCompleter] = T$.CompleterOfWebSocketImpl().new();
this[S$0._completer] = null;
this.webSocket = webSocket;
this.sink = sink;
;
}).prototype = web_socket_impl._WebSocketConsumer.prototype;
dart.addTypeTests(web_socket_impl._WebSocketConsumer);
dart.addTypeCaches(web_socket_impl._WebSocketConsumer);
web_socket_impl._WebSocketConsumer[dart.implements] = () => [async.StreamConsumer];
dart.setMethodSignature(web_socket_impl._WebSocketConsumer, () => ({
__proto__: dart.getMethods(web_socket_impl._WebSocketConsumer.__proto__),
[S$0._onListen]: dart.fnType(dart.void, []),
[S$0._onPause]: dart.fnType(dart.void, []),
[S$0._onResume]: dart.fnType(dart.void, []),
[S$0._cancel]: dart.fnType(dart.void, []),
[S$0._ensureController]: dart.fnType(dart.void, []),
[S$0._done]: dart.fnType(core.bool, [], [dart.nullable(core.Object), dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, []),
add: dart.fnType(dart.void, [dart.dynamic]),
closeSocket: dart.fnType(dart.void, [])
}));
dart.setLibraryUri(web_socket_impl._WebSocketConsumer, I[138]);
dart.setFieldSignature(web_socket_impl._WebSocketConsumer, () => ({
__proto__: dart.getFields(web_socket_impl._WebSocketConsumer.__proto__),
webSocket: dart.finalFieldType(web_socket_impl.WebSocketImpl),
sink: dart.finalFieldType(async.StreamSink$(core.List$(core.int))),
[S$0._controller]: dart.fieldType(dart.nullable(async.StreamController)),
[S$0._subscription]: dart.fieldType(dart.nullable(async.StreamSubscription)),
[S$0._issuedPause]: dart.fieldType(core.bool),
[S$0._closed]: dart.fieldType(core.bool),
[S$0._closeCompleter]: dart.finalFieldType(async.Completer),
[S$0._completer]: dart.fieldType(dart.nullable(async.Completer$(web_socket_impl.WebSocketImpl)))
}));
web_socket_impl._ServiceObject = class _ServiceObject extends core.Object {
get [S$0.__serviceId$1]() {
return this[S$0.__serviceId];
}
set [S$0.__serviceId$1](value) {
this[S$0.__serviceId] = value;
}
get [S$0._serviceId]() {
let t176;
if (this[S$0.__serviceId$1] === 0) this[S$0.__serviceId$1] = (t176 = web_socket_impl._nextServiceId, web_socket_impl._nextServiceId = dart.notNull(t176) + 1, t176);
return this[S$0.__serviceId$1];
}
};
(web_socket_impl._ServiceObject.new = function() {
this[S$0.__serviceId] = 0;
;
}).prototype = web_socket_impl._ServiceObject.prototype;
dart.addTypeTests(web_socket_impl._ServiceObject);
dart.addTypeCaches(web_socket_impl._ServiceObject);
dart.setGetterSignature(web_socket_impl._ServiceObject, () => ({
__proto__: dart.getGetters(web_socket_impl._ServiceObject.__proto__),
[S$0._serviceId]: core.int
}));
dart.setLibraryUri(web_socket_impl._ServiceObject, I[138]);
dart.setFieldSignature(web_socket_impl._ServiceObject, () => ({
__proto__: dart.getFields(web_socket_impl._ServiceObject.__proto__),
[S$0.__serviceId$1]: dart.fieldType(core.int)
}));
const Stream__ServiceObject$36 = class Stream__ServiceObject extends async.Stream {};
(Stream__ServiceObject$36.new = function() {
web_socket_impl._ServiceObject.new.call(this);
Stream__ServiceObject$36.__proto__.new.call(this);
}).prototype = Stream__ServiceObject$36.prototype;
(Stream__ServiceObject$36._internal = function() {
web_socket_impl._ServiceObject.new.call(this);
Stream__ServiceObject$36.__proto__._internal.call(this);
}).prototype = Stream__ServiceObject$36.prototype;
dart.applyMixin(Stream__ServiceObject$36, web_socket_impl._ServiceObject);
web_socket_impl.WebSocketImpl = class WebSocketImpl extends Stream__ServiceObject$36 {
get protocol() {
return this[S$0.protocol];
}
set protocol(value) {
super.protocol = value;
}
get [S$0._controller]() {
let t173;
return dart.test(this[S$0.__WebSocketImpl__controller_isSet]) ? (t173 = this[S$0.__WebSocketImpl__controller], t173) : dart.throw(new _internal.LateError.fieldNI("_controller"));
}
set [S$0._controller](t173) {
if (t173 == null) dart.nullFailed(I[139], 696, 31, "null");
if (dart.test(this[S$0.__WebSocketImpl__controller_isSet]))
dart.throw(new _internal.LateError.fieldAI("_controller"));
else {
this[S$0.__WebSocketImpl__controller_isSet] = true;
this[S$0.__WebSocketImpl__controller] = t173;
}
}
get [S$0._sink$1]() {
let t174;
return dart.test(this[S$0.__WebSocketImpl__sink_isSet]) ? (t174 = this[S$0.__WebSocketImpl__sink], t174) : dart.throw(new _internal.LateError.fieldNI("_sink"));
}
set [S$0._sink$1](t174) {
if (t174 == null) dart.nullFailed(I[139], 700, 25, "null");
if (dart.test(this[S$0.__WebSocketImpl__sink_isSet]))
dart.throw(new _internal.LateError.fieldAI("_sink"));
else {
this[S$0.__WebSocketImpl__sink_isSet] = true;
this[S$0.__WebSocketImpl__sink] = t174;
}
}
get [S$0._consumer]() {
let t175;
return dart.test(this[S$0.__WebSocketImpl__consumer_isSet]) ? (t175 = this[S$0.__WebSocketImpl__consumer], t175) : dart.throw(new _internal.LateError.fieldNI("_consumer"));
}
set [S$0._consumer](t175) {
if (t175 == null) dart.nullFailed(I[139], 709, 33, "null");
if (dart.test(this[S$0.__WebSocketImpl__consumer_isSet]))
dart.throw(new _internal.LateError.fieldAI("_consumer"));
else {
this[S$0.__WebSocketImpl__consumer_isSet] = true;
this[S$0.__WebSocketImpl__consumer] = t175;
}
}
static ['_#fromSocket#tearOff'](stream, sink, protocol, _serverSide = false) {
if (stream == null) dart.nullFailed(I[139], 716, 25, "stream");
if (sink == null) dart.nullFailed(I[139], 716, 55, "sink");
if (_serverSide == null) dart.nullFailed(I[139], 717, 13, "_serverSide");
return new web_socket_impl.WebSocketImpl.fromSocket(stream, sink, protocol, _serverSide);
}
listen(onData, opts) {
let onError = opts && 'onError' in opts ? opts.onError : null;
let onDone = opts && 'onDone' in opts ? opts.onDone : null;
let cancelOnError = opts && 'cancelOnError' in opts ? opts.cancelOnError : null;
return this[S$0._controller].stream.listen(onData, {onError: onError, onDone: onDone, cancelOnError: cancelOnError});
}
get pingInterval() {
return this[S$0._pingInterval];
}
set pingInterval(interval) {
if (dart.test(this[S$0._writeClosed])) return;
if (this[S$0._pingTimer] != null) dart.nullCheck(this[S$0._pingTimer]).cancel();
this[S$0._pingInterval] = interval;
if (this[S$0._pingInterval] == null) return;
this[S$0._pingTimer] = async.Timer.new(dart.nullCheck(this[S$0._pingInterval]), dart.fn(() => {
if (dart.test(this[S$0._writeClosed])) return;
this[S$0._consumer].add(new web_socket_impl._WebSocketPing.new());
this[S$0._pingTimer] = async.Timer.new(dart.nullCheck(this[S$0._pingInterval]), dart.fn(() => {
this[S$0._close](1001);
}, T$.VoidTovoid()));
}, T$.VoidTovoid()));
}
get readyState() {
return this[S$0._readyState];
}
get extensions() {
return null;
}
get closeCode() {
return this[S$0._closeCode];
}
get closeReason() {
return this[S$0._closeReason];
}
add(data) {
this[S$0._sink$1].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[139], 812, 24, "error");
this[S$0._sink$1].addError(error, stackTrace);
}
addStream(stream) {
async.Stream.as(stream);
if (stream == null) dart.nullFailed(I[139], 817, 27, "stream");
return this[S$0._sink$1].addStream(stream);
}
get done() {
return this[S$0._sink$1].done;
}
close(code = null, reason = null) {
if (dart.test(web_socket_impl.WebSocketImpl._isReservedStatusCode(code))) {
dart.throw(new exception.WebSocketChannelException.new("Reserved status code " + dart.str(code)));
}
if (this[S$0._outCloseCode] == null) {
this[S$0._outCloseCode] = code;
this[S$0._outCloseReason] = reason;
}
if (!dart.test(this[S$0._controller].isClosed)) {
if (!dart.test(this[S$0._controller].hasListener) && this[S$0._subscription] != null) {
this[S$0._controller].stream.drain(dart.dynamic).catchError(dart.fn(_ => new _js_helper.LinkedMap.new(), T$.dynamicToMap()));
}
this[S$0._closeTimer] == null ? this[S$0._closeTimer] = async.Timer.new(C[180] || CT.C180, dart.fn(() => {
this[S$0._closeCode] = this[S$0._outCloseCode];
this[S$0._closeReason] = this[S$0._outCloseReason];
if (this[S$0._subscription] != null) dart.nullCheck(this[S$0._subscription]).cancel();
this[S$0._controller].close();
web_socket_impl.WebSocketImpl._webSockets[S$.$remove](this[S$0._serviceId]);
}, T$.VoidTovoid())) : null;
}
return this[S$0._sink$1].close();
}
[S$0._close](code = null, reason = null) {
if (dart.test(this[S$0._writeClosed])) return;
if (this[S$0._outCloseCode] == null) {
this[S$0._outCloseCode] = code;
this[S$0._outCloseReason] = reason;
}
this[S$0._writeClosed] = true;
this[S$0._consumer].closeSocket();
web_socket_impl.WebSocketImpl._webSockets[S$.$remove](this[S$0._serviceId]);
}
static _isReservedStatusCode(code) {
return code != null && (dart.notNull(code) < 1000 || code === 1004 || code === 1005 || code === 1006 || dart.notNull(code) > 1011 && dart.notNull(code) < 1015 || dart.notNull(code) >= 1015 && dart.notNull(code) < 3000);
}
};
(web_socket_impl.WebSocketImpl.fromSocket = function(stream, sink, protocol, _serverSide = false) {
if (stream == null) dart.nullFailed(I[139], 716, 25, "stream");
if (sink == null) dart.nullFailed(I[139], 716, 55, "sink");
if (_serverSide == null) dart.nullFailed(I[139], 717, 13, "_serverSide");
this[S$0.__WebSocketImpl__controller] = null;
this[S$0.__WebSocketImpl__controller_isSet] = false;
this[S$0._subscription] = null;
this[S$0.__WebSocketImpl__sink] = null;
this[S$0.__WebSocketImpl__sink_isSet] = false;
this[S$0._readyState] = 0;
this[S$0._writeClosed] = false;
this[S$0._closeCode] = null;
this[S$0._closeReason] = null;
this[S$0._pingInterval] = null;
this[S$0._pingTimer] = null;
this[S$0.__WebSocketImpl__consumer] = null;
this[S$0.__WebSocketImpl__consumer_isSet] = false;
this[S$0._outCloseCode] = null;
this[S$0._outCloseReason] = null;
this[S$0._closeTimer] = null;
this[S$0.protocol] = protocol;
this[S$0._serverSide] = _serverSide;
web_socket_impl.WebSocketImpl.__proto__.new.call(this);
this[S$0._consumer] = new web_socket_impl._WebSocketConsumer.new(this, sink);
this[S$0._sink$1] = new io_sink.StreamSinkImpl.new(this[S$0._consumer]);
this[S$0._readyState] = 1;
let transformer = new web_socket_impl._WebSocketProtocolTransformer.new(this[S$0._serverSide]);
this[S$0._subscription] = transformer.bind(stream).listen(dart.fn(data => {
if (web_socket_impl._WebSocketPing.is(data)) {
if (!dart.test(this[S$0._writeClosed])) this[S$0._consumer].add(new web_socket_impl._WebSocketPong.new(data.payload));
} else if (web_socket_impl._WebSocketPong.is(data)) {
this.pingInterval = this[S$0._pingInterval];
} else {
this[S$0._controller].add(data);
}
}, T$.dynamicTovoid()), {onError: dart.fn((error, stackTrace) => {
if (this[S$0._closeTimer] != null) dart.nullCheck(this[S$0._closeTimer]).cancel();
if (core.FormatException.is(error)) {
this[S$0._close](1007);
} else {
this[S$0._close](1002);
}
this[S$0._closeCode] = this[S$0._outCloseCode];
this[S$0._closeReason] = this[S$0._outCloseReason];
this[S$0._controller].close();
}, T$.dynamicAnddynamicToNull()), onDone: dart.fn(() => {
if (this[S$0._closeTimer] != null) dart.nullCheck(this[S$0._closeTimer]).cancel();
if (this[S$0._readyState] === 1) {
this[S$0._readyState] = 2;
if (!dart.test(web_socket_impl.WebSocketImpl._isReservedStatusCode(transformer.closeCode))) {
this[S$0._close](transformer.closeCode, transformer.closeReason);
} else {
this[S$0._close]();
}
this[S$0._readyState] = 3;
}
this[S$0._closeCode] = transformer.closeCode;
this[S$0._closeReason] = transformer.closeReason;
this[S$0._controller].close();
}, T$.VoidTovoid()), cancelOnError: true});
dart.nullCheck(this[S$0._subscription]).pause();
this[S$0._controller] = async.StreamController.new({sync: true, onListen: dart.fn(() => dart.nullCheck(this[S$0._subscription]).resume(), T$.VoidTovoid()), onCancel: dart.fn(() => {
dart.nullCheck(this[S$0._subscription]).cancel();
this[S$0._subscription] = null;
}, T$.VoidToNull()), onPause: dart.bind(dart.nullCheck(this[S$0._subscription]), 'pause'), onResume: dart.bind(dart.nullCheck(this[S$0._subscription]), 'resume')});
web_socket_impl.WebSocketImpl._webSockets[S$.$_set](this[S$0._serviceId], this);
}).prototype = web_socket_impl.WebSocketImpl.prototype;
dart.addTypeTests(web_socket_impl.WebSocketImpl);
dart.addTypeCaches(web_socket_impl.WebSocketImpl);
web_socket_impl.WebSocketImpl[dart.implements] = () => [async.StreamSink];
dart.setMethodSignature(web_socket_impl.WebSocketImpl, () => ({
__proto__: dart.getMethods(web_socket_impl.WebSocketImpl.__proto__),
listen: dart.fnType(async.StreamSubscription, [dart.nullable(dart.fnType(dart.void, [dart.dynamic]))], {cancelOnError: dart.nullable(core.bool), onDone: dart.nullable(dart.fnType(dart.void, [])), onError: dart.nullable(core.Function)}, {}),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, [], [dart.nullable(core.int), dart.nullable(core.String)]),
[S$0._close]: dart.fnType(dart.void, [], [dart.nullable(core.int), dart.nullable(core.String)])
}));
dart.setStaticMethodSignature(web_socket_impl.WebSocketImpl, () => ['_isReservedStatusCode']);
dart.setGetterSignature(web_socket_impl.WebSocketImpl, () => ({
__proto__: dart.getGetters(web_socket_impl.WebSocketImpl.__proto__),
[S$0._controller]: async.StreamController,
[S$0._sink$1]: async.StreamSink,
[S$0._consumer]: web_socket_impl._WebSocketConsumer,
pingInterval: dart.nullable(core.Duration),
readyState: core.int,
extensions: dart.nullable(core.String),
closeCode: dart.nullable(core.int),
closeReason: dart.nullable(core.String),
done: async.Future
}));
dart.setSetterSignature(web_socket_impl.WebSocketImpl, () => ({
__proto__: dart.getSetters(web_socket_impl.WebSocketImpl.__proto__),
[S$0._controller]: async.StreamController,
[S$0._sink$1]: async.StreamSink,
[S$0._consumer]: web_socket_impl._WebSocketConsumer,
pingInterval: dart.nullable(core.Duration)
}));
dart.setLibraryUri(web_socket_impl.WebSocketImpl, I[138]);
dart.setFieldSignature(web_socket_impl.WebSocketImpl, () => ({
__proto__: dart.getFields(web_socket_impl.WebSocketImpl.__proto__),
protocol: dart.finalFieldType(dart.nullable(core.String)),
[S$0.__WebSocketImpl__controller]: dart.fieldType(dart.nullable(async.StreamController)),
[S$0.__WebSocketImpl__controller_isSet]: dart.fieldType(core.bool),
[S$0._subscription]: dart.fieldType(dart.nullable(async.StreamSubscription)),
[S$0.__WebSocketImpl__sink]: dart.fieldType(dart.nullable(async.StreamSink)),
[S$0.__WebSocketImpl__sink_isSet]: dart.fieldType(core.bool),
[S$0._serverSide]: dart.finalFieldType(core.bool),
[S$0._readyState]: dart.fieldType(core.int),
[S$0._writeClosed]: dart.fieldType(core.bool),
[S$0._closeCode]: dart.fieldType(dart.nullable(core.int)),
[S$0._closeReason]: dart.fieldType(dart.nullable(core.String)),
[S$0._pingInterval]: dart.fieldType(dart.nullable(core.Duration)),
[S$0._pingTimer]: dart.fieldType(dart.nullable(async.Timer)),
[S$0.__WebSocketImpl__consumer]: dart.fieldType(dart.nullable(web_socket_impl._WebSocketConsumer)),
[S$0.__WebSocketImpl__consumer_isSet]: dart.fieldType(core.bool),
[S$0._outCloseCode]: dart.fieldType(dart.nullable(core.int)),
[S$0._outCloseReason]: dart.fieldType(dart.nullable(core.String)),
[S$0._closeTimer]: dart.fieldType(dart.nullable(async.Timer))
}));
dart.setStaticFieldSignature(web_socket_impl.WebSocketImpl, () => ['_webSockets', 'DEFAULT_WINDOW_BITS', 'PER_MESSAGE_DEFLATE']);
dart.defineLazy(web_socket_impl.WebSocketImpl, {
/*web_socket_impl.WebSocketImpl._webSockets*/get _webSockets() {
return new (T$.IdentityMapOfint$WebSocketImpl()).new();
},
/*web_socket_impl.WebSocketImpl.DEFAULT_WINDOW_BITS*/get DEFAULT_WINDOW_BITS() {
return 15;
},
/*web_socket_impl.WebSocketImpl.PER_MESSAGE_DEFLATE*/get PER_MESSAGE_DEFLATE() {
return "permessage-deflate";
}
}, false);
dart.defineLazy(web_socket_impl, {
/*web_socket_impl.webSocketGUID*/get webSocketGUID() {
return "258EAFA5-E914-47DA-95CA-C5AB0DC85B11";
},
/*web_socket_impl._random*/get _random() {
return math.Random.new();
},
/*web_socket_impl._nextServiceId*/get _nextServiceId() {
return 1;
},
set _nextServiceId(_) {}
}, false);
const _is_AsyncCache_default = Symbol('_is_AsyncCache_default');
async_cache.AsyncCache$ = dart.generic(T => {
var __t$FutureOfT = () => (__t$FutureOfT = dart.constFn(async.Future$(T)))();
var __t$VoidToFutureOfT = () => (__t$VoidToFutureOfT = dart.constFn(dart.fnType(__t$FutureOfT(), [])))();
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$VoidToStreamOfT = () => (__t$VoidToStreamOfT = dart.constFn(dart.fnType(__t$StreamOfT(), [])))();
var __t$StreamSplitterOfT = () => (__t$StreamSplitterOfT = dart.constFn(stream_splitter.StreamSplitter$(T)))();
var __t$_StreamHandlerTransformerOfT$T = () => (__t$_StreamHandlerTransformerOfT$T = dart.constFn(async._StreamHandlerTransformer$(T, T)))();
var __t$EventSinkOfT = () => (__t$EventSinkOfT = dart.constFn(async.EventSink$(T)))();
var __t$EventSinkOfTTovoid = () => (__t$EventSinkOfTTovoid = dart.constFn(dart.fnType(dart.void, [__t$EventSinkOfT()])))();
class AsyncCache extends core.Object {
static ['_#new#tearOff'](T, _duration) {
if (_duration == null) dart.nullFailed(I[140], 45, 19, "_duration");
return new (async_cache.AsyncCache$(T)).new(_duration);
}
static ephemeral() {
return new (async_cache.AsyncCache$(T)).new(core.Duration.zero);
}
static ['_#ephemeral#tearOff'](T) {
return async_cache.AsyncCache$(T).ephemeral();
}
fetch(callback) {
__t$VoidToFutureOfT().as(callback);
if (callback == null) dart.nullFailed(I[140], 59, 40, "callback");
return async.async(T, (function* fetch() {
let t176;
if (this[S$0._cachedStreamSplitter] != null) {
dart.throw(new core.StateError.new("Previously used to cache via `fetchStream`"));
}
let result = (t176 = this[S$0._cachedValueFuture], t176 == null ? this[S$0._cachedValueFuture] = callback() : t176);
try {
return yield result;
} finally {
this[S$0._startStaleTimer]();
}
}).bind(this));
}
fetchStream(callback) {
let t176;
__t$VoidToStreamOfT().as(callback);
if (callback == null) dart.nullFailed(I[140], 77, 46, "callback");
if (this[S$0._cachedValueFuture] != null) {
dart.throw(new core.StateError.new("Previously used to cache via `fetch`"));
}
let splitter = (t176 = this[S$0._cachedStreamSplitter], t176 == null ? this[S$0._cachedStreamSplitter] = new (__t$StreamSplitterOfT()).new(callback().transform(T, new (__t$_StreamHandlerTransformerOfT$T()).new({handleDone: dart.fn(sink => {
if (sink == null) dart.nullFailed(I[140], 82, 74, "sink");
this[S$0._startStaleTimer]();
sink.close();
}, __t$EventSinkOfTTovoid())}))) : t176);
return splitter.split();
}
invalidate() {
let t176, t176$;
this[S$0._cachedValueFuture] = null;
t176 = this[S$0._cachedStreamSplitter];
t176 == null ? null : t176.close();
this[S$0._cachedStreamSplitter] = null;
t176$ = this[S$0._stale];
t176$ == null ? null : t176$.cancel();
this[S$0._stale] = null;
}
[S$0._startStaleTimer]() {
this[S$0._stale] = async.Timer.new(this[S$0._duration], dart.bind(this, 'invalidate'));
}
}
(AsyncCache.new = function(_duration) {
if (_duration == null) dart.nullFailed(I[140], 45, 19, "_duration");
this[S$0._cachedStreamSplitter] = null;
this[S$0._cachedValueFuture] = null;
this[S$0._stale] = null;
this[S$0._duration] = _duration;
;
}).prototype = AsyncCache.prototype;
dart.addTypeTests(AsyncCache);
AsyncCache.prototype[_is_AsyncCache_default] = true;
dart.addTypeCaches(AsyncCache);
dart.setMethodSignature(AsyncCache, () => ({
__proto__: dart.getMethods(AsyncCache.__proto__),
fetch: dart.fnType(async.Future$(T), [dart.nullable(core.Object)]),
fetchStream: dart.fnType(async.Stream$(T), [dart.nullable(core.Object)]),
invalidate: dart.fnType(dart.void, []),
[S$0._startStaleTimer]: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(AsyncCache, () => ['ephemeral']);
dart.setLibraryUri(AsyncCache, I[141]);
dart.setFieldSignature(AsyncCache, () => ({
__proto__: dart.getFields(AsyncCache.__proto__),
[S$0._duration]: dart.finalFieldType(core.Duration),
[S$0._cachedStreamSplitter]: dart.fieldType(dart.nullable(stream_splitter.StreamSplitter$(T))),
[S$0._cachedValueFuture]: dart.fieldType(dart.nullable(async.Future$(T))),
[S$0._stale]: dart.fieldType(dart.nullable(async.Timer))
}));
return AsyncCache;
});
async_cache.AsyncCache = async_cache.AsyncCache$();
dart.addTypeTests(async_cache.AsyncCache, _is_AsyncCache_default);
const _is_AsyncMemoizer_default = Symbol('_is_AsyncMemoizer_default');
async_memoizer.AsyncMemoizer$ = dart.generic(T => {
var __t$CompleterOfT = () => (__t$CompleterOfT = dart.constFn(async.Completer$(T)))();
var __t$FutureOrOfT = () => (__t$FutureOrOfT = dart.constFn(async.FutureOr$(T)))();
var __t$VoidToFutureOrOfT = () => (__t$VoidToFutureOrOfT = dart.constFn(dart.fnType(__t$FutureOrOfT(), [])))();
var __t$FutureOfT = () => (__t$FutureOfT = dart.constFn(async.Future$(T)))();
class AsyncMemoizer extends core.Object {
get future() {
return this[S$0._completer$1].future;
}
get hasRun() {
return this[S$0._completer$1].isCompleted;
}
runOnce(computation) {
__t$VoidToFutureOrOfT().as(computation);
if (computation == null) dart.nullFailed(I[142], 42, 44, "computation");
if (!dart.test(this.hasRun)) this[S$0._completer$1].complete(__t$FutureOfT().sync(computation));
return this.future;
}
static ['_#new#tearOff'](T) {
return new (async_memoizer.AsyncMemoizer$(T)).new();
}
}
(AsyncMemoizer.new = function() {
this[S$0._completer$1] = __t$CompleterOfT().new();
;
}).prototype = AsyncMemoizer.prototype;
dart.addTypeTests(AsyncMemoizer);
AsyncMemoizer.prototype[_is_AsyncMemoizer_default] = true;
dart.addTypeCaches(AsyncMemoizer);
dart.setMethodSignature(AsyncMemoizer, () => ({
__proto__: dart.getMethods(AsyncMemoizer.__proto__),
runOnce: dart.fnType(async.Future$(T), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(AsyncMemoizer, () => ({
__proto__: dart.getGetters(AsyncMemoizer.__proto__),
future: async.Future$(T),
hasRun: core.bool
}));
dart.setLibraryUri(AsyncMemoizer, I[143]);
dart.setFieldSignature(AsyncMemoizer, () => ({
__proto__: dart.getFields(AsyncMemoizer.__proto__),
[S$0._completer$1]: dart.finalFieldType(async.Completer$(T))
}));
return AsyncMemoizer;
});
async_memoizer.AsyncMemoizer = async_memoizer.AsyncMemoizer$();
dart.addTypeTests(async_memoizer.AsyncMemoizer, _is_AsyncMemoizer_default);
byte_collector.collectBytes = function collectBytes(source) {
if (source == null) dart.nullFailed(I[144], 16, 50, "source");
return byte_collector._collectBytes(T$.FutureOfUint8List(), source, dart.fn((_, result) => {
if (_ == null) dart.nullFailed(I[144], 17, 33, "_");
if (result == null) dart.nullFailed(I[144], 17, 36, "result");
return result;
}, T$.StreamSubscriptionOfListOfintAndFutureOfUint8ListToFutureOfUint8List()));
};
byte_collector.collectBytesCancelable = function collectBytesCancelable(source) {
if (source == null) dart.nullFailed(I[144], 31, 23, "source");
return byte_collector._collectBytes(T$.CancelableOperationOfUint8List(), source, dart.fn((subscription, result) => {
if (subscription == null) dart.nullFailed(I[144], 34, 8, "subscription");
if (result == null) dart.nullFailed(I[144], 34, 22, "result");
return T$.CancelableOperationOfUint8List().fromFuture(result, {onCancel: dart.bind(subscription, 'cancel')});
}, T$.StreamSubscriptionOfListOfintAndFutureOfUint8ListToCancelableOperationOfUint8List()));
};
byte_collector._collectBytes = function _collectBytes(T, source, result) {
if (source == null) dart.nullFailed(I[144], 43, 38, "source");
if (result == null) dart.nullFailed(I[144], 44, 66, "result");
let bytes = _internal.BytesBuilder.new({copy: false});
let completer = T$.CompleterOfUint8List().sync();
let subscription = source.listen(dart.bind(bytes, 'add'), {onError: dart.bind(completer, 'completeError'), onDone: dart.fn(() => {
completer.complete(bytes.takeBytes());
}, T$.VoidTovoid()), cancelOnError: true});
return result(subscription, completer.future);
};
const _is_CancelableOperation_default = Symbol('_is_CancelableOperation_default');
cancelable_operation.CancelableOperation$ = dart.generic(T => {
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$TToNull = () => (__t$TToNull = dart.constFn(dart.fnType(core.Null, [T])))();
var __t$TN = () => (__t$TN = dart.constFn(dart.nullable(T)))();
var __t$CompleterOfTN = () => (__t$CompleterOfTN = dart.constFn(async.Completer$(__t$TN())))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
var __t$TNToNull = () => (__t$TNToNull = dart.constFn(dart.fnType(core.Null, [__t$TN()])))();
class CancelableOperation extends core.Object {
static ['_#_#tearOff'](T, _completer) {
if (_completer == null) dart.nullFailed(I[145], 22, 30, "_completer");
return new (cancelable_operation.CancelableOperation$(T)).__(_completer);
}
static fromFuture(inner, opts) {
if (inner == null) dart.nullFailed(I[145], 35, 52, "inner");
let onCancel = opts && 'onCancel' in opts ? opts.onCancel : null;
let completer = new (cancelable_operation.CancelableCompleter$(T)).new({onCancel: onCancel});
completer.complete(inner);
return completer.operation;
}
static ['_#fromFuture#tearOff'](T, inner, opts) {
if (inner == null) dart.nullFailed(I[145], 35, 52, "inner");
let onCancel = opts && 'onCancel' in opts ? opts.onCancel : null;
return cancelable_operation.CancelableOperation$(T).fromFuture(inner, {onCancel: onCancel});
}
get value() {
return this[S$0._completer$2][S$0._inner$1].future;
}
asStream() {
let controller = __t$StreamControllerOfT().new({sync: true, onCancel: dart.bind(this[S$0._completer$2], S$0._cancel$1)});
this.value.then(core.Null, dart.fn(value => {
controller.add(value);
controller.close();
}, __t$TToNull()), {onError: dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[145], 56, 25, "error");
if (stackTrace == null) dart.nullFailed(I[145], 56, 43, "stackTrace");
controller.addError(error, stackTrace);
controller.close();
}, T$.ObjectAndStackTraceToNull())});
return controller.stream;
}
valueOrCancellation(cancellationValue = null) {
__t$TN().as(cancellationValue);
let completer = __t$CompleterOfTN().sync();
this.value.then(dart.void, dart.fn(result => completer.complete(result), __t$TTovoid()), {onError: dart.bind(completer, 'completeError')});
this[S$0._completer$2][S$0._cancelMemo].future.then(core.Null, dart.fn(_ => {
completer.complete(cancellationValue);
}, T$.dynamicToNull()), {onError: dart.bind(completer, 'completeError')});
return completer.future;
}
then(R, onValue, opts) {
if (onValue == null) dart.nullFailed(I[145], 93, 58, "onValue");
let onError = opts && 'onError' in opts ? opts.onError : null;
let onCancel = opts && 'onCancel' in opts ? opts.onCancel : null;
let propagateCancel = opts && 'propagateCancel' in opts ? opts.propagateCancel : false;
if (propagateCancel == null) dart.nullFailed(I[145], 96, 12, "propagateCancel");
let completer = new (cancelable_operation.CancelableCompleter$(R)).new({onCancel: dart.test(propagateCancel) ? dart.bind(this, 'cancel') : null});
this.valueOrCancellation().then(core.Null, dart.fn(result => {
if (!dart.test(completer.isCanceled)) {
if (dart.test(this.isCompleted) && !dart.test(this.isCanceled)) {
if (!T.is(result)) dart.assertFailed(null, I[145], 103, 18, "result is T");
completer.complete(async.Future$(R).sync(dart.fn(() => onValue(T.as(result)), dart.fnType(async.FutureOr$(R), []))));
} else if (onCancel != null) {
completer.complete(async.Future$(R).sync(onCancel));
} else {
completer[S$0._cancel$1]();
}
}
}, __t$TNToNull()), {onError: dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[145], 111, 25, "error");
if (stackTrace == null) dart.nullFailed(I[145], 111, 43, "stackTrace");
if (!dart.test(completer.isCanceled)) {
if (onError != null) {
completer.complete(async.Future$(R).sync(dart.fn(() => onError(error, stackTrace), dart.fnType(async.FutureOr$(R), []))));
} else {
completer.completeError(error, stackTrace);
}
}
}, T$.ObjectAndStackTraceToNull())});
return completer.operation;
}
cancel() {
return this[S$0._completer$2][S$0._cancel$1]();
}
get isCanceled() {
return this[S$0._completer$2].isCanceled;
}
get isCompleted() {
return this[S$0._completer$2][S$0._inner$1].isCompleted;
}
}
(CancelableOperation.__ = function(_completer) {
if (_completer == null) dart.nullFailed(I[145], 22, 30, "_completer");
this[S$0._completer$2] = _completer;
;
}).prototype = CancelableOperation.prototype;
dart.addTypeTests(CancelableOperation);
CancelableOperation.prototype[_is_CancelableOperation_default] = true;
dart.addTypeCaches(CancelableOperation);
dart.setMethodSignature(CancelableOperation, () => ({
__proto__: dart.getMethods(CancelableOperation.__proto__),
asStream: dart.fnType(async.Stream$(T), []),
valueOrCancellation: dart.fnType(async.Future$(dart.nullable(T)), [], [dart.nullable(core.Object)]),
then: dart.gFnType(R => [cancelable_operation.CancelableOperation$(R), [dart.fnType(async.FutureOr$(R), [T])], {onCancel: dart.nullable(dart.fnType(async.FutureOr$(R), [])), onError: dart.nullable(dart.fnType(async.FutureOr$(R), [core.Object, core.StackTrace])), propagateCancel: core.bool}, {}], R => [dart.nullable(core.Object)]),
cancel: dart.fnType(async.Future, [])
}));
dart.setStaticMethodSignature(CancelableOperation, () => ['fromFuture']);
dart.setGetterSignature(CancelableOperation, () => ({
__proto__: dart.getGetters(CancelableOperation.__proto__),
value: async.Future$(T),
isCanceled: core.bool,
isCompleted: core.bool
}));
dart.setLibraryUri(CancelableOperation, I[146]);
dart.setFieldSignature(CancelableOperation, () => ({
__proto__: dart.getFields(CancelableOperation.__proto__),
[S$0._completer$2]: dart.finalFieldType(cancelable_operation.CancelableCompleter$(T))
}));
return CancelableOperation;
});
cancelable_operation.CancelableOperation = cancelable_operation.CancelableOperation$();
dart.addTypeTests(cancelable_operation.CancelableOperation, _is_CancelableOperation_default);
const _is_CancelableCompleter_default = Symbol('_is_CancelableCompleter_default');
cancelable_operation.CancelableCompleter$ = dart.generic(T => {
var __t$CompleterOfT = () => (__t$CompleterOfT = dart.constFn(async.Completer$(T)))();
var __t$CancelableOperationOfT = () => (__t$CancelableOperationOfT = dart.constFn(cancelable_operation.CancelableOperation$(T)))();
var __t$FutureOrOfT = () => (__t$FutureOrOfT = dart.constFn(async.FutureOr$(T)))();
var __t$FutureOrNOfT = () => (__t$FutureOrNOfT = dart.constFn(dart.nullable(__t$FutureOrOfT())))();
var __t$FutureOfT = () => (__t$FutureOfT = dart.constFn(async.Future$(T)))();
var __t$TToNull = () => (__t$TToNull = dart.constFn(dart.fnType(core.Null, [T])))();
class CancelableCompleter extends core.Object {
static ['_#new#tearOff'](T, opts) {
let onCancel = opts && 'onCancel' in opts ? opts.onCancel : null;
return new (cancelable_operation.CancelableCompleter$(T)).new({onCancel: onCancel});
}
get operation() {
let t177;
if (!dart.test(this[S$0.__CancelableCompleter_operation_isSet])) {
let t176 = new (__t$CancelableOperationOfT()).__(this);
if (dart.test(this[S$0.__CancelableCompleter_operation_isSet])) dart.throw(new _internal.LateError.fieldADI("operation"));
this[S$0.__CancelableCompleter_operation] = t176;
this[S$0.__CancelableCompleter_operation_isSet] = true;
}
t177 = this[S$0.__CancelableCompleter_operation];
return t177;
}
get isCompleted() {
return this[S$0._isCompleted];
}
get isCanceled() {
return this[S$0._isCanceled];
}
complete(value = null) {
__t$FutureOrNOfT().as(value);
if (dart.test(this[S$0._isCompleted])) dart.throw(new core.StateError.new("Operation already completed"));
this[S$0._isCompleted] = true;
if (!async.Future.is(value)) {
if (dart.test(this[S$0._isCanceled])) return;
this[S$0._inner$1].complete(value);
return;
}
let future = __t$FutureOfT().as(value);
if (dart.test(this[S$0._isCanceled])) {
future.catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
return;
}
future.then(core.Null, dart.fn(result => {
if (dart.test(this[S$0._isCanceled])) return;
this[S$0._inner$1].complete(result);
}, __t$TToNull()), {onError: dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[145], 210, 25, "error");
if (stackTrace == null) dart.nullFailed(I[145], 210, 43, "stackTrace");
if (dart.test(this[S$0._isCanceled])) return;
this[S$0._inner$1].completeError(error, stackTrace);
}, T$.ObjectAndStackTraceToNull())});
}
completeError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[145], 221, 29, "error");
if (dart.test(this[S$0._isCompleted])) dart.throw(new core.StateError.new("Operation already completed"));
this[S$0._isCompleted] = true;
if (dart.test(this[S$0._isCanceled])) return;
this[S$0._inner$1].completeError(error, stackTrace);
}
[S$0._cancel$1]() {
if (dart.test(this[S$0._inner$1].isCompleted)) return async.Future.value();
return this[S$0._cancelMemo].runOnce(dart.fn(() => {
this[S$0._isCanceled] = true;
let onCancel = this[S$0._onCancel];
if (onCancel != null) return onCancel();
}, T$.VoidToFutureOr()));
}
}
(CancelableCompleter.new = function(opts) {
let onCancel = opts && 'onCancel' in opts ? opts.onCancel : null;
this[S$0._inner$1] = __t$CompleterOfT().new();
this[S$0.__CancelableCompleter_operation] = null;
this[S$0.__CancelableCompleter_operation_isSet] = false;
this[S$0._isCompleted] = false;
this[S$0._isCanceled] = false;
this[S$0._cancelMemo] = new async_memoizer.AsyncMemoizer.new();
this[S$0._onCancel] = onCancel;
;
}).prototype = CancelableCompleter.prototype;
dart.addTypeTests(CancelableCompleter);
CancelableCompleter.prototype[_is_CancelableCompleter_default] = true;
dart.addTypeCaches(CancelableCompleter);
dart.setMethodSignature(CancelableCompleter, () => ({
__proto__: dart.getMethods(CancelableCompleter.__proto__),
complete: dart.fnType(dart.void, [], [dart.nullable(core.Object)]),
completeError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
[S$0._cancel$1]: dart.fnType(async.Future, [])
}));
dart.setGetterSignature(CancelableCompleter, () => ({
__proto__: dart.getGetters(CancelableCompleter.__proto__),
operation: cancelable_operation.CancelableOperation$(T),
isCompleted: core.bool,
isCanceled: core.bool
}));
dart.setLibraryUri(CancelableCompleter, I[146]);
dart.setFieldSignature(CancelableCompleter, () => ({
__proto__: dart.getFields(CancelableCompleter.__proto__),
[S$0._inner$1]: dart.finalFieldType(async.Completer$(T)),
[S$0._onCancel]: dart.finalFieldType(dart.nullable(dart.fnType(dart.dynamic, []))),
[S$0.__CancelableCompleter_operation]: dart.fieldType(dart.nullable(cancelable_operation.CancelableOperation$(T))),
[S$0.__CancelableCompleter_operation_isSet]: dart.fieldType(core.bool),
[S$0._isCompleted]: dart.fieldType(core.bool),
[S$0._isCanceled]: dart.fieldType(core.bool),
[S$0._cancelMemo]: dart.finalFieldType(async_memoizer.AsyncMemoizer)
}));
return CancelableCompleter;
});
cancelable_operation.CancelableCompleter = cancelable_operation.CancelableCompleter$();
dart.addTypeTests(cancelable_operation.CancelableCompleter, _is_CancelableCompleter_default);
const _is_DelegatingEventSink_default = Symbol('_is_DelegatingEventSink_default');
event_sink.DelegatingEventSink$ = dart.generic(T => {
class DelegatingEventSink extends core.Object {
static ['_#new#tearOff'](T, sink) {
if (sink == null) dart.nullFailed(I[147], 15, 36, "sink");
return new (event_sink.DelegatingEventSink$(T)).new(sink);
}
static ['_#_#tearOff'](T, _sink) {
if (_sink == null) dart.nullFailed(I[147], 17, 30, "_sink");
return new (event_sink.DelegatingEventSink$(T)).__(_sink);
}
static typed(T, sink) {
if (sink == null) dart.nullFailed(I[147], 27, 42, "sink");
return async.EventSink$(T).is(sink) ? sink : new (event_sink.DelegatingEventSink$(T)).__(sink);
}
add(data) {
T.as(data);
this[S$0._sink$2].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[147], 36, 17, "error");
this[S$0._sink$2].addError(error, stackTrace);
}
close() {
this[S$0._sink$2].close();
}
}
(DelegatingEventSink.new = function(sink) {
if (sink == null) dart.nullFailed(I[147], 15, 36, "sink");
this[S$0._sink$2] = sink;
;
}).prototype = DelegatingEventSink.prototype;
(DelegatingEventSink.__ = function(_sink) {
if (_sink == null) dart.nullFailed(I[147], 17, 30, "_sink");
this[S$0._sink$2] = _sink;
;
}).prototype = DelegatingEventSink.prototype;
dart.addTypeTests(DelegatingEventSink);
DelegatingEventSink.prototype[_is_DelegatingEventSink_default] = true;
dart.addTypeCaches(DelegatingEventSink);
DelegatingEventSink[dart.implements] = () => [async.EventSink$(T)];
dart.setMethodSignature(DelegatingEventSink, () => ({
__proto__: dart.getMethods(DelegatingEventSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
close: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(DelegatingEventSink, () => ['typed']);
dart.setLibraryUri(DelegatingEventSink, I[148]);
dart.setFieldSignature(DelegatingEventSink, () => ({
__proto__: dart.getFields(DelegatingEventSink.__proto__),
[S$0._sink$2]: dart.finalFieldType(async.EventSink)
}));
return DelegatingEventSink;
});
event_sink.DelegatingEventSink = event_sink.DelegatingEventSink$();
dart.addTypeTests(event_sink.DelegatingEventSink, _is_DelegatingEventSink_default);
const _is_DelegatingFuture_default = Symbol('_is_DelegatingFuture_default');
future.DelegatingFuture$ = dart.generic(T => {
var __t$FutureOrOfT = () => (__t$FutureOrOfT = dart.constFn(async.FutureOr$(T)))();
var __t$VoidToFutureOrOfT = () => (__t$VoidToFutureOrOfT = dart.constFn(dart.fnType(__t$FutureOrOfT(), [])))();
var __t$VoidToNFutureOrOfT = () => (__t$VoidToNFutureOrOfT = dart.constFn(dart.nullable(__t$VoidToFutureOrOfT())))();
class DelegatingFuture extends core.Object {
static ['_#new#tearOff'](T, _future) {
if (_future == null) dart.nullFailed(I[149], 12, 25, "_future");
return new (future.DelegatingFuture$(T)).new(_future);
}
static typed(T, future) {
if (future == null) dart.nullFailed(I[149], 21, 36, "future");
return async.Future$(T).is(future) ? future : future.then(T, dart.fn(v => T.as(v), dart.fnType(T, [dart.dynamic])));
}
asStream() {
return this[S$0._future].asStream();
}
catchError(onError, opts) {
if (onError == null) dart.nullFailed(I[149], 28, 33, "onError");
let test = opts && 'test' in opts ? opts.test : null;
return this[S$0._future].catchError(onError, {test: test});
}
then(S, onValue, opts) {
if (onValue == null) dart.nullFailed(I[149], 32, 45, "onValue");
let onError = opts && 'onError' in opts ? opts.onError : null;
return this[S$0._future].then(S, onValue, {onError: onError});
}
whenComplete(action) {
if (action == null) dart.nullFailed(I[149], 36, 46, "action");
return this[S$0._future].whenComplete(action);
}
timeout(timeLimit, opts) {
if (timeLimit == null) dart.nullFailed(I[149], 40, 30, "timeLimit");
let onTimeout = opts && 'onTimeout' in opts ? opts.onTimeout : null;
__t$VoidToNFutureOrOfT().as(onTimeout);
return this[S$0._future].timeout(timeLimit, {onTimeout: onTimeout});
}
}
(DelegatingFuture.new = function(_future) {
if (_future == null) dart.nullFailed(I[149], 12, 25, "_future");
this[S$0._future] = _future;
;
}).prototype = DelegatingFuture.prototype;
DelegatingFuture.prototype[dart.isFuture] = true;
dart.addTypeTests(DelegatingFuture);
DelegatingFuture.prototype[_is_DelegatingFuture_default] = true;
dart.addTypeCaches(DelegatingFuture);
DelegatingFuture[dart.implements] = () => [async.Future$(T)];
dart.setMethodSignature(DelegatingFuture, () => ({
__proto__: dart.getMethods(DelegatingFuture.__proto__),
asStream: dart.fnType(async.Stream$(T), []),
catchError: dart.fnType(async.Future$(T), [core.Function], {test: dart.nullable(dart.fnType(core.bool, [core.Object]))}, {}),
then: dart.gFnType(S => [async.Future$(S), [dart.fnType(async.FutureOr$(S), [T])], {onError: dart.nullable(core.Function)}, {}], S => [dart.nullable(core.Object)]),
whenComplete: dart.fnType(async.Future$(T), [dart.fnType(dart.dynamic, [])]),
timeout: dart.fnType(async.Future$(T), [core.Duration], {onTimeout: dart.nullable(core.Object)}, {})
}));
dart.setStaticMethodSignature(DelegatingFuture, () => ['typed']);
dart.setLibraryUri(DelegatingFuture, I[150]);
dart.setFieldSignature(DelegatingFuture, () => ({
__proto__: dart.getFields(DelegatingFuture.__proto__),
[S$0._future]: dart.finalFieldType(async.Future$(T))
}));
return DelegatingFuture;
});
future.DelegatingFuture = future.DelegatingFuture$();
dart.addTypeTests(future.DelegatingFuture, _is_DelegatingFuture_default);
const _is_DelegatingSink_default = Symbol('_is_DelegatingSink_default');
sink$.DelegatingSink$ = dart.generic(T => {
class DelegatingSink extends core.Object {
static ['_#new#tearOff'](T, sink) {
if (sink == null) dart.nullFailed(I[151], 13, 26, "sink");
return new (sink$.DelegatingSink$(T)).new(sink);
}
static ['_#_#tearOff'](T, _sink) {
if (_sink == null) dart.nullFailed(I[151], 15, 25, "_sink");
return new (sink$.DelegatingSink$(T)).__(_sink);
}
static typed(T, sink) {
if (sink == null) dart.nullFailed(I[151], 25, 32, "sink");
return core.Sink$(T).is(sink) ? sink : new (sink$.DelegatingSink$(T)).__(sink);
}
add(data) {
T.as(data);
this[S$0._sink$3].add(data);
}
close() {
this[S$0._sink$3].close();
}
}
(DelegatingSink.new = function(sink) {
if (sink == null) dart.nullFailed(I[151], 13, 26, "sink");
this[S$0._sink$3] = sink;
;
}).prototype = DelegatingSink.prototype;
(DelegatingSink.__ = function(_sink) {
if (_sink == null) dart.nullFailed(I[151], 15, 25, "_sink");
this[S$0._sink$3] = _sink;
;
}).prototype = DelegatingSink.prototype;
dart.addTypeTests(DelegatingSink);
DelegatingSink.prototype[_is_DelegatingSink_default] = true;
dart.addTypeCaches(DelegatingSink);
DelegatingSink[dart.implements] = () => [core.Sink$(T)];
dart.setMethodSignature(DelegatingSink, () => ({
__proto__: dart.getMethods(DelegatingSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
close: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(DelegatingSink, () => ['typed']);
dart.setLibraryUri(DelegatingSink, I[152]);
dart.setFieldSignature(DelegatingSink, () => ({
__proto__: dart.getFields(DelegatingSink.__proto__),
[S$0._sink$3]: dart.finalFieldType(core.Sink)
}));
return DelegatingSink;
});
sink$.DelegatingSink = sink$.DelegatingSink$();
dart.addTypeTests(sink$.DelegatingSink, _is_DelegatingSink_default);
const _is_DelegatingStream_default = Symbol('_is_DelegatingStream_default');
stream$.DelegatingStream$ = dart.generic(T => {
class DelegatingStream extends async.StreamView$(T) {
static ['_#new#tearOff'](T, stream) {
if (stream == null) dart.nullFailed(I[153], 15, 30, "stream");
return new (stream$.DelegatingStream$(T)).new(stream);
}
static typed(T, stream) {
if (stream == null) dart.nullFailed(I[153], 25, 36, "stream");
return stream.cast(T);
}
}
(DelegatingStream.new = function(stream) {
if (stream == null) dart.nullFailed(I[153], 15, 30, "stream");
DelegatingStream.__proto__.new.call(this, stream);
;
}).prototype = DelegatingStream.prototype;
dart.addTypeTests(DelegatingStream);
DelegatingStream.prototype[_is_DelegatingStream_default] = true;
dart.addTypeCaches(DelegatingStream);
dart.setStaticMethodSignature(DelegatingStream, () => ['typed']);
dart.setLibraryUri(DelegatingStream, I[154]);
return DelegatingStream;
});
stream$.DelegatingStream = stream$.DelegatingStream$();
dart.addTypeTests(stream$.DelegatingStream, _is_DelegatingStream_default);
const _is_DelegatingStreamConsumer_default = Symbol('_is_DelegatingStreamConsumer_default');
stream_consumer.DelegatingStreamConsumer$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
class DelegatingStreamConsumer extends core.Object {
static ['_#new#tearOff'](T, consumer) {
if (consumer == null) dart.nullFailed(I[155], 15, 46, "consumer");
return new (stream_consumer.DelegatingStreamConsumer$(T)).new(consumer);
}
static ['_#_#tearOff'](T, _consumer) {
if (_consumer == null) dart.nullFailed(I[155], 17, 35, "_consumer");
return new (stream_consumer.DelegatingStreamConsumer$(T)).__(_consumer);
}
static typed(T, consumer) {
if (consumer == null) dart.nullFailed(I[155], 27, 52, "consumer");
return async.StreamConsumer$(T).is(consumer) ? consumer : new (stream_consumer.DelegatingStreamConsumer$(T)).__(consumer);
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[155], 33, 30, "stream");
return this[S$0._consumer$1].addStream(stream);
}
close() {
return this[S$0._consumer$1].close();
}
}
(DelegatingStreamConsumer.new = function(consumer) {
if (consumer == null) dart.nullFailed(I[155], 15, 46, "consumer");
this[S$0._consumer$1] = consumer;
;
}).prototype = DelegatingStreamConsumer.prototype;
(DelegatingStreamConsumer.__ = function(_consumer) {
if (_consumer == null) dart.nullFailed(I[155], 17, 35, "_consumer");
this[S$0._consumer$1] = _consumer;
;
}).prototype = DelegatingStreamConsumer.prototype;
dart.addTypeTests(DelegatingStreamConsumer);
DelegatingStreamConsumer.prototype[_is_DelegatingStreamConsumer_default] = true;
dart.addTypeCaches(DelegatingStreamConsumer);
DelegatingStreamConsumer[dart.implements] = () => [async.StreamConsumer$(T)];
dart.setMethodSignature(DelegatingStreamConsumer, () => ({
__proto__: dart.getMethods(DelegatingStreamConsumer.__proto__),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, [])
}));
dart.setStaticMethodSignature(DelegatingStreamConsumer, () => ['typed']);
dart.setLibraryUri(DelegatingStreamConsumer, I[156]);
dart.setFieldSignature(DelegatingStreamConsumer, () => ({
__proto__: dart.getFields(DelegatingStreamConsumer.__proto__),
[S$0._consumer$1]: dart.finalFieldType(async.StreamConsumer)
}));
return DelegatingStreamConsumer;
});
stream_consumer.DelegatingStreamConsumer = stream_consumer.DelegatingStreamConsumer$();
dart.addTypeTests(stream_consumer.DelegatingStreamConsumer, _is_DelegatingStreamConsumer_default);
const _is_DelegatingStreamSubscription_default = Symbol('_is_DelegatingStreamSubscription_default');
stream_subscription.DelegatingStreamSubscription$ = dart.generic(T => {
class DelegatingStreamSubscription extends core.Object {
static ['_#new#tearOff'](T, sourceSubscription) {
if (sourceSubscription == null) dart.nullFailed(I[157], 16, 54, "sourceSubscription");
return new (stream_subscription.DelegatingStreamSubscription$(T)).new(sourceSubscription);
}
static typed(T, subscription) {
if (subscription == null) dart.nullFailed(I[157], 28, 60, "subscription");
return async.StreamSubscription$(T).is(subscription) ? subscription : new (stream_subscription$.TypeSafeStreamSubscription$(T)).new(subscription);
}
onData(handleData) {
this[S$0._source$2].onData(handleData);
}
onError(handleError) {
this[S$0._source$2].onError(handleError);
}
onDone(handleDone) {
this[S$0._source$2].onDone(handleDone);
}
pause(resumeFuture = null) {
this[S$0._source$2].pause(resumeFuture);
}
resume() {
this[S$0._source$2].resume();
}
cancel() {
return this[S$0._source$2].cancel();
}
asFuture(E, futureValue = null) {
return this[S$0._source$2].asFuture(E, futureValue);
}
get isPaused() {
return this[S$0._source$2].isPaused;
}
}
(DelegatingStreamSubscription.new = function(sourceSubscription) {
if (sourceSubscription == null) dart.nullFailed(I[157], 16, 54, "sourceSubscription");
this[S$0._source$2] = sourceSubscription;
;
}).prototype = DelegatingStreamSubscription.prototype;
DelegatingStreamSubscription.prototype[dart.isStreamSubscription] = true;
dart.addTypeTests(DelegatingStreamSubscription);
DelegatingStreamSubscription.prototype[_is_DelegatingStreamSubscription_default] = true;
dart.addTypeCaches(DelegatingStreamSubscription);
DelegatingStreamSubscription[dart.implements] = () => [async.StreamSubscription$(T)];
dart.setMethodSignature(DelegatingStreamSubscription, () => ({
__proto__: dart.getMethods(DelegatingStreamSubscription.__proto__),
onData: dart.fnType(dart.void, [dart.nullable(dart.fnType(dart.void, [T]))]),
onError: dart.fnType(dart.void, [dart.nullable(core.Function)]),
onDone: dart.fnType(dart.void, [dart.nullable(dart.fnType(dart.void, []))]),
pause: dart.fnType(dart.void, [], [dart.nullable(async.Future)]),
resume: dart.fnType(dart.void, []),
cancel: dart.fnType(async.Future, []),
asFuture: dart.gFnType(E => [async.Future$(E), [], [dart.nullable(E)]], E => [dart.nullable(core.Object)])
}));
dart.setStaticMethodSignature(DelegatingStreamSubscription, () => ['typed']);
dart.setGetterSignature(DelegatingStreamSubscription, () => ({
__proto__: dart.getGetters(DelegatingStreamSubscription.__proto__),
isPaused: core.bool
}));
dart.setLibraryUri(DelegatingStreamSubscription, I[158]);
dart.setFieldSignature(DelegatingStreamSubscription, () => ({
__proto__: dart.getFields(DelegatingStreamSubscription.__proto__),
[S$0._source$2]: dart.finalFieldType(async.StreamSubscription$(T))
}));
return DelegatingStreamSubscription;
});
stream_subscription.DelegatingStreamSubscription = stream_subscription.DelegatingStreamSubscription$();
dart.addTypeTests(stream_subscription.DelegatingStreamSubscription, _is_DelegatingStreamSubscription_default);
const _is_FutureGroup_default = Symbol('_is_FutureGroup_default');
future_group.FutureGroup$ = dart.generic(T => {
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$CompleterOfListOfT = () => (__t$CompleterOfListOfT = dart.constFn(async.Completer$(__t$ListOfT())))();
var __t$TN = () => (__t$TN = dart.constFn(dart.nullable(T)))();
var __t$JSArrayOfTN = () => (__t$JSArrayOfTN = dart.constFn(_interceptors.JSArray$(__t$TN())))();
var __t$FutureOfT = () => (__t$FutureOfT = dart.constFn(async.Future$(T)))();
var __t$TToNull = () => (__t$TToNull = dart.constFn(dart.fnType(core.Null, [T])))();
class FutureGroup extends core.Object {
get isClosed() {
return this[S$0._closed$1];
}
get future() {
return this[S$0._completer$3].future;
}
get isIdle() {
return this[S$0._pending] === 0;
}
get onIdle() {
let t177;
return (t177 = this[S$0._onIdleController], t177 == null ? this[S$0._onIdleController] = async.StreamController.broadcast({sync: true}) : t177).stream;
}
add(task) {
__t$FutureOfT().as(task);
if (task == null) dart.nullFailed(I[159], 69, 22, "task");
if (dart.test(this[S$0._closed$1])) dart.throw(new core.StateError.new("The FutureGroup is closed."));
let index = this[S$0._values][S$.$length];
this[S$0._values][S$.$add](null);
this[S$0._pending] = dart.notNull(this[S$0._pending]) + 1;
task.then(core.Null, dart.fn(value => {
if (dart.test(this[S$0._completer$3].isCompleted)) return null;
this[S$0._pending] = dart.notNull(this[S$0._pending]) - 1;
this[S$0._values][S$.$_set](index, value);
if (this[S$0._pending] !== 0) return null;
let onIdleController = this[S$0._onIdleController];
if (onIdleController != null) onIdleController.add(null);
if (!dart.test(this[S$0._closed$1])) return null;
if (onIdleController != null) onIdleController.close();
this[S$0._completer$3].complete(this[S$0._values][S$.$whereType](T)[S$.$toList]());
}, __t$TToNull())).catchError(dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[159], 92, 27, "error");
if (stackTrace == null) dart.nullFailed(I[159], 92, 45, "stackTrace");
if (dart.test(this[S$0._completer$3].isCompleted)) return null;
this[S$0._completer$3].completeError(error, stackTrace);
}, T$.ObjectAndStackTraceToNull()));
}
close() {
this[S$0._closed$1] = true;
if (this[S$0._pending] !== 0) return;
if (dart.test(this[S$0._completer$3].isCompleted)) return;
this[S$0._completer$3].complete(this[S$0._values][S$.$whereType](T)[S$.$toList]());
}
static ['_#new#tearOff'](T) {
return new (future_group.FutureGroup$(T)).new();
}
}
(FutureGroup.new = function() {
this[S$0._pending] = 0;
this[S$0._closed$1] = false;
this[S$0._completer$3] = __t$CompleterOfListOfT().new();
this[S$0._onIdleController] = null;
this[S$0._values] = __t$JSArrayOfTN().of([]);
;
}).prototype = FutureGroup.prototype;
dart.addTypeTests(FutureGroup);
FutureGroup.prototype[_is_FutureGroup_default] = true;
dart.addTypeCaches(FutureGroup);
FutureGroup[dart.implements] = () => [core.Sink$(async.Future$(T))];
dart.setMethodSignature(FutureGroup, () => ({
__proto__: dart.getMethods(FutureGroup.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
close: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(FutureGroup, () => ({
__proto__: dart.getGetters(FutureGroup.__proto__),
isClosed: core.bool,
future: async.Future$(core.List$(T)),
isIdle: core.bool,
onIdle: async.Stream
}));
dart.setLibraryUri(FutureGroup, I[160]);
dart.setFieldSignature(FutureGroup, () => ({
__proto__: dart.getFields(FutureGroup.__proto__),
[S$0._pending]: dart.fieldType(core.int),
[S$0._closed$1]: dart.fieldType(core.bool),
[S$0._completer$3]: dart.finalFieldType(async.Completer$(core.List$(T))),
[S$0._onIdleController]: dart.fieldType(dart.nullable(async.StreamController)),
[S$0._values]: dart.finalFieldType(core.List$(dart.nullable(T)))
}));
return FutureGroup;
});
future_group.FutureGroup = future_group.FutureGroup$();
dart.addTypeTests(future_group.FutureGroup, _is_FutureGroup_default);
const _is_LazyStream_default = Symbol('_is_LazyStream_default');
lazy_stream.LazyStream$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$FutureOfStreamOfT = () => (__t$FutureOfStreamOfT = dart.constFn(async.Future$(__t$StreamOfT())))();
class LazyStream extends async.Stream$(T) {
static ['_#new#tearOff'](T, callback) {
if (callback == null) dart.nullFailed(I[161], 22, 45, "callback");
return new (lazy_stream.LazyStream$(T)).new(callback);
}
listen(onData, opts) {
let onError = opts && 'onError' in opts ? opts.onError : null;
let onDone = opts && 'onDone' in opts ? opts.onDone : null;
let cancelOnError = opts && 'cancelOnError' in opts ? opts.cancelOnError : null;
let callback = this[S$0._callback];
if (callback == null) {
dart.throw(new core.StateError.new("Stream has already been listened to."));
}
this[S$0._callback] = null;
let result = callback();
let stream = null;
if (__t$FutureOfStreamOfT().is(result)) {
stream = stream_completer.StreamCompleter.fromFuture(T, result);
} else {
stream = result;
}
return stream.listen(onData, {onError: onError, onDone: onDone, cancelOnError: cancelOnError});
}
}
(LazyStream.new = function(callback) {
if (callback == null) dart.nullFailed(I[161], 22, 45, "callback");
this[S$0._callback] = callback;
LazyStream.__proto__.new.call(this);
if (this[S$0._callback] == null) dart.throw(new core.ArgumentError.notNull("callback"));
}).prototype = LazyStream.prototype;
dart.addTypeTests(LazyStream);
LazyStream.prototype[_is_LazyStream_default] = true;
dart.addTypeCaches(LazyStream);
dart.setMethodSignature(LazyStream, () => ({
__proto__: dart.getMethods(LazyStream.__proto__),
listen: dart.fnType(async.StreamSubscription$(T), [dart.nullable(dart.fnType(dart.void, [T]))], {cancelOnError: dart.nullable(core.bool), onDone: dart.nullable(dart.fnType(dart.void, [])), onError: dart.nullable(core.Function)}, {})
}));
dart.setLibraryUri(LazyStream, I[162]);
dart.setFieldSignature(LazyStream, () => ({
__proto__: dart.getFields(LazyStream.__proto__),
[S$0._callback]: dart.fieldType(dart.nullable(dart.fnType(async.FutureOr$(async.Stream$(T)), [])))
}));
return LazyStream;
});
lazy_stream.LazyStream = lazy_stream.LazyStream$();
dart.addTypeTests(lazy_stream.LazyStream, _is_LazyStream_default);
const _is_NullStreamSink_default = Symbol('_is_NullStreamSink_default');
null_stream_sink.NullStreamSink$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
class NullStreamSink extends core.Object {
get done() {
return this[S$0.done];
}
set done(value) {
super.done = value;
}
static ['_#new#tearOff'](T, opts) {
let done = opts && 'done' in opts ? opts.done : null;
return new (null_stream_sink.NullStreamSink$(T)).new({done: done});
}
static ['_#error#tearOff'](T, error, stackTrace = null) {
if (error == null) dart.nullFailed(I[163], 51, 31, "error");
return new (null_stream_sink.NullStreamSink$(T)).error(error, stackTrace);
}
add(data) {
T.as(data);
this[S$0._checkEventAllowed]();
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[163], 64, 24, "error");
this[S$0._checkEventAllowed]();
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[163], 69, 30, "stream");
this[S$0._checkEventAllowed]();
this[S$0._addingStream] = true;
let future = stream.listen(null).cancel();
return future.whenComplete(dart.fn(() => {
this[S$0._addingStream] = false;
}, T$.VoidToNull()));
}
[S$0._checkEventAllowed]() {
if (dart.test(this[S$0._closed$2])) dart.throw(new core.StateError.new("Cannot add to a closed sink."));
if (dart.test(this[S$0._addingStream])) {
dart.throw(new core.StateError.new("Cannot add to a sink while adding a stream."));
}
}
close() {
this[S$0._closed$2] = true;
return this.done;
}
}
(NullStreamSink.new = function(opts) {
let t177;
let done = opts && 'done' in opts ? opts.done : null;
this[S$0._closed$2] = false;
this[S$0._addingStream] = false;
this[S$0.done] = (t177 = done, t177 == null ? async.Future.value() : t177);
;
}).prototype = NullStreamSink.prototype;
(NullStreamSink.error = function(error, stackTrace = null) {
let t177;
if (error == null) dart.nullFailed(I[163], 51, 31, "error");
this[S$0._closed$2] = false;
this[S$0._addingStream] = false;
this[S$0.done] = (t177 = async.Future.error(error, stackTrace), (() => {
t177.catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
return t177;
})());
;
}).prototype = NullStreamSink.prototype;
dart.addTypeTests(NullStreamSink);
NullStreamSink.prototype[_is_NullStreamSink_default] = true;
dart.addTypeCaches(NullStreamSink);
NullStreamSink[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(NullStreamSink, () => ({
__proto__: dart.getMethods(NullStreamSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
[S$0._checkEventAllowed]: dart.fnType(dart.void, []),
close: dart.fnType(async.Future, [])
}));
dart.setLibraryUri(NullStreamSink, I[164]);
dart.setFieldSignature(NullStreamSink, () => ({
__proto__: dart.getFields(NullStreamSink.__proto__),
done: dart.finalFieldType(async.Future),
[S$0._closed$2]: dart.fieldType(core.bool),
[S$0._addingStream]: dart.fieldType(core.bool)
}));
return NullStreamSink;
});
null_stream_sink.NullStreamSink = null_stream_sink.NullStreamSink$();
dart.addTypeTests(null_stream_sink.NullStreamSink, _is_NullStreamSink_default);
restartable_timer.RestartableTimer = class RestartableTimer extends core.Object {
static ['_#new#tearOff'](_duration, _callback) {
if (_duration == null) dart.nullFailed(I[165], 28, 25, "_duration");
if (_callback == null) dart.nullFailed(I[165], 28, 41, "_callback");
return new restartable_timer.RestartableTimer.new(_duration, _callback);
}
get isActive() {
return this[S$0._timer].isActive;
}
reset() {
this[S$0._timer].cancel();
this[S$0._timer] = async.Timer.new(this[S$0._duration$1], this[S$0._callback$1]);
}
cancel() {
this[S$0._timer].cancel();
}
get tick() {
return this[S$0._timer].tick;
}
};
(restartable_timer.RestartableTimer.new = function(_duration, _callback) {
if (_duration == null) dart.nullFailed(I[165], 28, 25, "_duration");
if (_callback == null) dart.nullFailed(I[165], 28, 41, "_callback");
this[S$0._duration$1] = _duration;
this[S$0._callback$1] = _callback;
this[S$0._timer] = async.Timer.new(_duration, _callback);
;
}).prototype = restartable_timer.RestartableTimer.prototype;
dart.addTypeTests(restartable_timer.RestartableTimer);
dart.addTypeCaches(restartable_timer.RestartableTimer);
restartable_timer.RestartableTimer[dart.implements] = () => [async.Timer];
dart.setMethodSignature(restartable_timer.RestartableTimer, () => ({
__proto__: dart.getMethods(restartable_timer.RestartableTimer.__proto__),
reset: dart.fnType(dart.void, []),
cancel: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(restartable_timer.RestartableTimer, () => ({
__proto__: dart.getGetters(restartable_timer.RestartableTimer.__proto__),
isActive: core.bool,
tick: core.int
}));
dart.setLibraryUri(restartable_timer.RestartableTimer, I[166]);
dart.setFieldSignature(restartable_timer.RestartableTimer, () => ({
__proto__: dart.getFields(restartable_timer.RestartableTimer.__proto__),
[S$0._duration$1]: dart.finalFieldType(core.Duration),
[S$0._callback$1]: dart.finalFieldType(dart.fnType(dart.dynamic, [])),
[S$0._timer]: dart.fieldType(async.Timer)
}));
const _is_Result_default = Symbol('_is_Result_default');
result$.Result$ = dart.generic(T => {
class Result extends core.Object {
static new(computation) {
if (computation == null) dart.nullFailed(I[167], 63, 31, "computation");
try {
return new (value$.ValueResult$(T)).new(computation());
} catch (e$) {
let e = dart.getThrown(e$);
let s = dart.stackTrace(e$);
if (core.Object.is(e)) {
return new error$.ErrorResult.new(e, s);
} else
throw e$;
}
}
static ['_#new#tearOff'](T, computation) {
if (computation == null) dart.nullFailed(I[167], 63, 31, "computation");
return result$.Result$(T).new(computation);
}
static ['_#value#tearOff'](T, value) {
return new (value$.ValueResult$(T)).new(value);
}
static error(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[167], 79, 31, "error");
return new error$.ErrorResult.new(error, stackTrace);
}
static ['_#error#tearOff'](T, error, stackTrace = null) {
if (error == null) dart.nullFailed(I[167], 79, 31, "error");
return result$.Result$(T).error(error, stackTrace);
}
static capture(T, future) {
if (future == null) dart.nullFailed(I[167], 86, 49, "future");
return future.then(result$.Result$(T), dart.fn(value => new (value$.ValueResult$(T)).new(value), dart.fnType(value$.ValueResult$(T), [T])), {onError: dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[167], 88, 26, "error");
if (stackTrace == null) dart.nullFailed(I[167], 88, 44, "stackTrace");
return new error$.ErrorResult.new(error, stackTrace);
}, T$.ObjectAndStackTraceToErrorResult())});
}
static captureAll(T, elements) {
if (elements == null) dart.nullFailed(I[167], 99, 70, "elements");
let results = _interceptors.JSArray$(dart.nullable(result$.Result$(T))).of([]);
let pending = 0;
let completer = null;
let completer$35isSet = false;
function completer$35get() {
return completer$35isSet ? completer : dart.throw(new _internal.LateError.localNI("completer"));
}
dart.fn(completer$35get, dart.fnType(async.Completer$(core.List$(result$.Result$(T))), []));
function completer$35set(t181) {
if (t181 == null) dart.nullFailed(I[167], 102, 37, "null");
completer$35isSet = true;
return completer = t181;
}
dart.fn(completer$35set, dart.fnType(dart.dynamic, [async.Completer$(core.List$(result$.Result$(T)))]));
for (let element of elements) {
if (async.Future$(T).is(element)) {
let i = results[S$.$length];
results[S$.$add](null);
pending = pending + 1;
result$.Result.capture(T, element).then(core.Null, dart.fn(result => {
if (result == null) dart.nullFailed(I[167], 108, 42, "result");
results[S$.$_set](i, result);
if ((pending = pending - 1) === 0) {
completer$35get().complete(core.List$(result$.Result$(T)).from(results));
}
}, dart.fnType(core.Null, [result$.Result$(T)])));
} else {
results[S$.$add](new (value$.ValueResult$(T)).new(element));
}
}
if (pending === 0) {
return async.Future$(core.List$(result$.Result$(T))).value(core.List$(result$.Result$(T)).from(results));
}
completer$35set(async.Completer$(core.List$(result$.Result$(T))).new());
return completer$35get().future;
}
static release(T, future) {
if (future == null) dart.nullFailed(I[167], 132, 49, "future");
return future.then(T, dart.fn(result => {
if (result == null) dart.nullFailed(I[167], 133, 23, "result");
return result.asFuture;
}, dart.fnType(async.Future$(T), [result$.Result$(T)])));
}
static captureStream(T, source) {
if (source == null) dart.nullFailed(I[167], 139, 55, "source");
return source.transform(result$.Result$(T), new (capture_transformer.CaptureStreamTransformer$(T)).new());
}
static releaseStream(T, source) {
if (source == null) dart.nullFailed(I[167], 147, 55, "source");
return source.transform(T, new (release_transformer.ReleaseStreamTransformer$(T)).new());
}
static releaseSink(T, sink) {
if (sink == null) dart.nullFailed(I[167], 155, 59, "sink");
return new (release_sink.ReleaseSink$(T)).new(sink);
}
static captureSink(T, sink) {
if (sink == null) dart.nullFailed(I[167], 165, 59, "sink");
return new (capture_sink.CaptureSink$(T)).new(sink);
}
static flatten(T, result) {
if (result == null) dart.nullFailed(I[167], 174, 49, "result");
if (dart.test(result.isValue)) return dart.nullCheck(result.asValue).value;
return dart.nullCheck(result.asError);
}
static flattenAll(T, results) {
if (results == null) dart.nullFailed(I[167], 183, 60, "results");
let values = _interceptors.JSArray$(T).of([]);
for (let result of results) {
if (dart.test(result.isValue)) {
values[S$.$add](dart.nullCheck(result.asValue).value);
} else {
return dart.nullCheck(result.asError);
}
}
return new (value$.ValueResult$(core.List$(T))).new(values);
}
}
(Result[dart.mixinNew] = function() {
}).prototype = Result.prototype;
dart.addTypeTests(Result);
Result.prototype[_is_Result_default] = true;
dart.addTypeCaches(Result);
dart.setStaticMethodSignature(Result, () => ['new', 'value', 'error', 'capture', 'captureAll', 'release', 'captureStream', 'releaseStream', 'releaseSink', 'captureSink', 'flatten', 'flattenAll']);
dart.setLibraryUri(Result, I[168]);
dart.setStaticFieldSignature(Result, () => ['captureStreamTransformer', 'releaseStreamTransformer', 'captureSinkTransformer', 'releaseSinkTransformer', '_redirecting#']);
return Result;
});
result$.Result = result$.Result$();
dart.defineLazy(result$.Result, {
/*result$.Result.captureStreamTransformer*/get captureStreamTransformer() {
return C[181] || CT.C181;
},
/*result$.Result.releaseStreamTransformer*/get releaseStreamTransformer() {
return C[182] || CT.C182;
},
/*result$.Result.captureSinkTransformer*/get captureSinkTransformer() {
return C[183] || CT.C183;
},
/*result$.Result.releaseSinkTransformer*/get releaseSinkTransformer() {
return C[184] || CT.C184;
}
}, false);
dart.addTypeTests(result$.Result, _is_Result_default);
error$.ErrorResult = class ErrorResult extends core.Object {
get error() {
return this[S$0.error];
}
set error(value) {
super.error = value;
}
get stackTrace() {
return this[S$0.stackTrace];
}
set stackTrace(value) {
super.stackTrace = value;
}
get isValue() {
return false;
}
get isError() {
return true;
}
get asValue() {
return null;
}
get asError() {
return this;
}
static ['_#new#tearOff'](error, stackTrace = null) {
if (error == null) dart.nullFailed(I[169], 27, 20, "error");
return new error$.ErrorResult.new(error, stackTrace);
}
complete(completer) {
async.Completer.as(completer);
if (completer == null) dart.nullFailed(I[169], 31, 27, "completer");
completer.completeError(this.error, this.stackTrace);
}
addTo(sink) {
async.EventSink.as(sink);
if (sink == null) dart.nullFailed(I[169], 36, 24, "sink");
sink.addError(this.error, this.stackTrace);
}
get asFuture() {
return T$.FutureOfNever().error(this.error, this.stackTrace);
}
handle(errorHandler) {
if (errorHandler == null) dart.nullFailed(I[169], 49, 24, "errorHandler");
if (T$.dynamicAnddynamicTodynamic().is(errorHandler)) {
errorHandler(this.error, this.stackTrace);
} else {
dart.dcall(errorHandler, [this.error]);
}
}
get hashCode() {
return (dart.notNull(dart.hashCode(this.error)) ^ dart.notNull(dart.hashCode(this.stackTrace)) ^ 492929599) >>> 0;
}
_equals(other) {
if (other == null) return false;
return error$.ErrorResult.is(other) && dart.equals(this.error, other.error) && dart.equals(this.stackTrace, other.stackTrace);
}
};
(error$.ErrorResult.new = function(error, stackTrace = null) {
let t183;
if (error == null) dart.nullFailed(I[169], 27, 20, "error");
this[S$0.error] = error;
this[S$0.stackTrace] = (t183 = stackTrace, t183 == null ? async.AsyncError.defaultStackTrace(error) : t183);
;
}).prototype = error$.ErrorResult.prototype;
dart.addTypeTests(error$.ErrorResult);
dart.addTypeCaches(error$.ErrorResult);
error$.ErrorResult[dart.implements] = () => [result$.Result$(dart.Never)];
dart.setMethodSignature(error$.ErrorResult, () => ({
__proto__: dart.getMethods(error$.ErrorResult.__proto__),
complete: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addTo: dart.fnType(dart.void, [dart.nullable(core.Object)]),
handle: dart.fnType(dart.void, [core.Function])
}));
dart.setGetterSignature(error$.ErrorResult, () => ({
__proto__: dart.getGetters(error$.ErrorResult.__proto__),
isValue: core.bool,
isError: core.bool,
asValue: dart.nullable(value$.ValueResult$(dart.Never)),
asError: error$.ErrorResult,
asFuture: async.Future$(dart.Never)
}));
dart.setLibraryUri(error$.ErrorResult, I[170]);
dart.setFieldSignature(error$.ErrorResult, () => ({
__proto__: dart.getFields(error$.ErrorResult.__proto__),
error: dart.finalFieldType(core.Object),
stackTrace: dart.finalFieldType(core.StackTrace)
}));
dart.defineExtensionMethods(error$.ErrorResult, ['_equals']);
dart.defineExtensionAccessors(error$.ErrorResult, ['hashCode']);
const _is_ResultFuture_default = Symbol('_is_ResultFuture_default');
future$.ResultFuture$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$ResultOfTToNull = () => (__t$ResultOfTToNull = dart.constFn(dart.fnType(core.Null, [__t$ResultOfT()])))();
class ResultFuture extends future.DelegatingFuture$(T) {
get isComplete() {
return this.result != null;
}
get result() {
return this[S$0._result$1];
}
static ['_#new#tearOff'](T, future) {
if (future == null) dart.nullFailed(I[171], 20, 26, "future");
return new (future$.ResultFuture$(T)).new(future);
}
}
(ResultFuture.new = function(future) {
if (future == null) dart.nullFailed(I[171], 20, 26, "future");
this[S$0._result$1] = null;
ResultFuture.__proto__.new.call(this, future);
result$.Result.capture(T, future).then(core.Null, dart.fn(result => {
if (result == null) dart.nullFailed(I[171], 21, 34, "result");
this[S$0._result$1] = result;
}, __t$ResultOfTToNull()));
}).prototype = ResultFuture.prototype;
dart.addTypeTests(ResultFuture);
ResultFuture.prototype[_is_ResultFuture_default] = true;
dart.addTypeCaches(ResultFuture);
dart.setGetterSignature(ResultFuture, () => ({
__proto__: dart.getGetters(ResultFuture.__proto__),
isComplete: core.bool,
result: dart.nullable(result$.Result$(T))
}));
dart.setLibraryUri(ResultFuture, I[172]);
dart.setFieldSignature(ResultFuture, () => ({
__proto__: dart.getFields(ResultFuture.__proto__),
[S$0._result$1]: dart.fieldType(dart.nullable(result$.Result$(T)))
}));
return ResultFuture;
});
future$.ResultFuture = future$.ResultFuture$();
dart.addTypeTests(future$.ResultFuture, _is_ResultFuture_default);
const _is_ValueResult_default = Symbol('_is_ValueResult_default');
value$.ValueResult$ = dart.generic(T => {
var __t$CompleterOfT = () => (__t$CompleterOfT = dart.constFn(async.Completer$(T)))();
var __t$EventSinkOfT = () => (__t$EventSinkOfT = dart.constFn(async.EventSink$(T)))();
var __t$FutureOfT = () => (__t$FutureOfT = dart.constFn(async.Future$(T)))();
class ValueResult extends core.Object {
get value() {
return this[S$0.value$12];
}
set value(value) {
super.value = value;
}
get isValue() {
return true;
}
get isError() {
return false;
}
get asValue() {
return this;
}
get asError() {
return null;
}
static ['_#new#tearOff'](T, value) {
return new (value$.ValueResult$(T)).new(value);
}
complete(completer) {
__t$CompleterOfT().as(completer);
if (completer == null) dart.nullFailed(I[173], 27, 30, "completer");
completer.complete(this.value);
}
addTo(sink) {
__t$EventSinkOfT().as(sink);
if (sink == null) dart.nullFailed(I[173], 32, 27, "sink");
sink.add(this.value);
}
get asFuture() {
return __t$FutureOfT().value(this.value);
}
get hashCode() {
return (dart.notNull(dart.hashCode(this.value)) ^ 842997089) >>> 0;
}
_equals(other) {
if (other == null) return false;
return value$.ValueResult.is(other) && dart.equals(this.value, other.value);
}
}
(ValueResult.new = function(value) {
this[S$0.value$12] = value;
;
}).prototype = ValueResult.prototype;
dart.addTypeTests(ValueResult);
ValueResult.prototype[_is_ValueResult_default] = true;
dart.addTypeCaches(ValueResult);
ValueResult[dart.implements] = () => [result$.Result$(T)];
dart.setMethodSignature(ValueResult, () => ({
__proto__: dart.getMethods(ValueResult.__proto__),
complete: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addTo: dart.fnType(dart.void, [dart.nullable(core.Object)])
}));
dart.setGetterSignature(ValueResult, () => ({
__proto__: dart.getGetters(ValueResult.__proto__),
isValue: core.bool,
isError: core.bool,
asValue: value$.ValueResult$(T),
asError: dart.nullable(error$.ErrorResult),
asFuture: async.Future$(T)
}));
dart.setLibraryUri(ValueResult, I[174]);
dart.setFieldSignature(ValueResult, () => ({
__proto__: dart.getFields(ValueResult.__proto__),
value: dart.finalFieldType(T)
}));
dart.defineExtensionMethods(ValueResult, ['_equals']);
dart.defineExtensionAccessors(ValueResult, ['hashCode']);
return ValueResult;
});
value$.ValueResult = value$.ValueResult$();
dart.addTypeTests(value$.ValueResult, _is_ValueResult_default);
const _is_SingleSubscriptionTransformer_default = Symbol('_is_SingleSubscriptionTransformer_default');
single_subscription_transformer.SingleSubscriptionTransformer$ = dart.generic((S, T) => {
var __t$StreamOfS = () => (__t$StreamOfS = dart.constFn(async.Stream$(S)))();
var __t$StreamSubscriptionOfS = () => (__t$StreamSubscriptionOfS = dart.constFn(async.StreamSubscription$(S)))();
var __t$VoidToStreamSubscriptionOfS = () => (__t$VoidToStreamSubscriptionOfS = dart.constFn(dart.fnType(__t$StreamSubscriptionOfS(), [])))();
var __t$StreamSubscriptionOfSTodynamic = () => (__t$StreamSubscriptionOfSTodynamic = dart.constFn(dart.fnType(dart.dynamic, [__t$StreamSubscriptionOfS()])))();
var __t$STovoid = () => (__t$STovoid = dart.constFn(dart.fnType(dart.void, [S])))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
class SingleSubscriptionTransformer extends async.StreamTransformerBase$(S, T) {
static ['_#new#tearOff'](S, T) {
return new (single_subscription_transformer.SingleSubscriptionTransformer$(S, T)).new();
}
bind(stream) {
__t$StreamOfS().as(stream);
if (stream == null) dart.nullFailed(I[175], 20, 28, "stream");
let subscription = null;
let subscription$35isSet = false;
function subscription$35get() {
return subscription$35isSet ? subscription : dart.throw(new _internal.LateError.localNI("subscription"));
}
dart.fn(subscription$35get, __t$VoidToStreamSubscriptionOfS());
function subscription$35set(t186) {
if (t186 == null) dart.nullFailed(I[175], 21, 32, "null");
subscription$35isSet = true;
return subscription = t186;
}
dart.fn(subscription$35set, __t$StreamSubscriptionOfSTodynamic());
let controller = __t$StreamControllerOfT().new({sync: true, onCancel: dart.fn(() => subscription$35get().cancel(), T$.VoidToFutureOfvoid())});
subscription$35set(stream.listen(dart.fn(value => {
try {
controller.add(T.as(value));
} catch (e) {
let error = dart.getThrown(e);
let stackTrace = dart.stackTrace(e);
if (core.TypeError.is(error)) {
controller.addError(error, stackTrace);
} else
throw e;
}
}, __t$STovoid()), {onError: dart.bind(controller, 'addError'), onDone: dart.bind(controller, 'close')}));
return controller.stream;
}
}
(SingleSubscriptionTransformer.new = function() {
SingleSubscriptionTransformer.__proto__.new.call(this);
;
}).prototype = SingleSubscriptionTransformer.prototype;
dart.addTypeTests(SingleSubscriptionTransformer);
SingleSubscriptionTransformer.prototype[_is_SingleSubscriptionTransformer_default] = true;
dart.addTypeCaches(SingleSubscriptionTransformer);
dart.setMethodSignature(SingleSubscriptionTransformer, () => ({
__proto__: dart.getMethods(SingleSubscriptionTransformer.__proto__),
bind: dart.fnType(async.Stream$(T), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(SingleSubscriptionTransformer, I[176]);
return SingleSubscriptionTransformer;
});
single_subscription_transformer.SingleSubscriptionTransformer = single_subscription_transformer.SingleSubscriptionTransformer$();
dart.addTypeTests(single_subscription_transformer.SingleSubscriptionTransformer, _is_SingleSubscriptionTransformer_default);
const _is_EventSinkBase_default = Symbol('_is_EventSinkBase_default');
sink_base.EventSinkBase$ = dart.generic(T => {
class EventSinkBase extends core.Object {
get [S$0._closed$3]() {
return this[S$0._closeMemo].hasRun;
}
add(data) {
T.as(data);
this[S$0._checkCanAddEvent]();
this.onAdd(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[177], 32, 24, "error");
this[S$0._checkCanAddEvent]();
this.onError(error, stackTrace);
}
close() {
return this[S$0._closeMemo].runOnce(dart.bind(this, 'onClose'));
}
[S$0._checkCanAddEvent]() {
if (dart.test(this[S$0._closed$3])) dart.throw(new core.StateError.new("Cannot add event after closing"));
}
}
(EventSinkBase.new = function() {
this[S$0._closeMemo] = new (T$.AsyncMemoizerOfvoid()).new();
;
}).prototype = EventSinkBase.prototype;
dart.addTypeTests(EventSinkBase);
EventSinkBase.prototype[_is_EventSinkBase_default] = true;
dart.addTypeCaches(EventSinkBase);
EventSinkBase[dart.implements] = () => [async.EventSink$(T)];
dart.setMethodSignature(EventSinkBase, () => ({
__proto__: dart.getMethods(EventSinkBase.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
close: dart.fnType(async.Future$(dart.void), []),
[S$0._checkCanAddEvent]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(EventSinkBase, () => ({
__proto__: dart.getGetters(EventSinkBase.__proto__),
[S$0._closed$3]: core.bool
}));
dart.setLibraryUri(EventSinkBase, I[178]);
dart.setFieldSignature(EventSinkBase, () => ({
__proto__: dart.getFields(EventSinkBase.__proto__),
[S$0._closeMemo]: dart.finalFieldType(async_memoizer.AsyncMemoizer$(dart.void))
}));
return EventSinkBase;
});
sink_base.EventSinkBase = sink_base.EventSinkBase$();
dart.addTypeTests(sink_base.EventSinkBase, _is_EventSinkBase_default);
const _is_StreamSinkBase_default = Symbol('_is_StreamSinkBase_default');
sink_base.StreamSinkBase$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
class StreamSinkBase extends sink_base.EventSinkBase$(T) {
get done() {
return this[S$0._closeMemo].future;
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[177], 73, 36, "stream");
this[S$0._checkCanAddEvent]();
this[S$0._addingStream$1] = true;
let completer = T$.CompleterOfvoid().sync();
stream.listen(dart.bind(this, 'onAdd'), {onError: dart.bind(this, 'onError'), onDone: dart.fn(() => {
this[S$0._addingStream$1] = false;
completer.complete();
}, T$.VoidTovoid())});
return completer.future;
}
close() {
if (dart.test(this[S$0._addingStream$1])) dart.throw(new core.StateError.new("StreamSink is bound to a stream"));
return super.close();
}
[S$0._checkCanAddEvent]() {
super[S$0._checkCanAddEvent]();
if (dart.test(this[S$0._addingStream$1])) dart.throw(new core.StateError.new("StreamSink is bound to a stream"));
}
}
(StreamSinkBase.new = function() {
this[S$0._addingStream$1] = false;
StreamSinkBase.__proto__.new.call(this);
;
}).prototype = StreamSinkBase.prototype;
dart.addTypeTests(StreamSinkBase);
StreamSinkBase.prototype[_is_StreamSinkBase_default] = true;
dart.addTypeCaches(StreamSinkBase);
StreamSinkBase[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(StreamSinkBase, () => ({
__proto__: dart.getMethods(StreamSinkBase.__proto__),
addStream: dart.fnType(async.Future$(dart.void), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(StreamSinkBase, () => ({
__proto__: dart.getGetters(StreamSinkBase.__proto__),
done: async.Future$(dart.void)
}));
dart.setLibraryUri(StreamSinkBase, I[178]);
dart.setFieldSignature(StreamSinkBase, () => ({
__proto__: dart.getFields(StreamSinkBase.__proto__),
[S$0._addingStream$1]: dart.fieldType(core.bool)
}));
return StreamSinkBase;
});
sink_base.StreamSinkBase = sink_base.StreamSinkBase$();
dart.addTypeTests(sink_base.StreamSinkBase, _is_StreamSinkBase_default);
sink_base.IOSinkBase = class IOSinkBase extends sink_base.StreamSinkBase$(core.List$(core.int)) {
get encoding() {
return this[S$0.encoding];
}
set encoding(value) {
this[S$0.encoding] = value;
}
flush() {
if (dart.test(this[S$0._addingStream$1])) dart.throw(new core.StateError.new("StreamSink is bound to a stream"));
if (dart.test(this[S$0._closed$3])) return T$.FutureOfvoid().value();
this[S$0._addingStream$1] = true;
return this.onFlush().whenComplete(dart.fn(() => {
this[S$0._addingStream$1] = false;
}, T$.VoidToNull()));
}
write(object) {
let string = dart.toString(object);
if (string[S$.$isEmpty]) return;
this.add(this.encoding.encode(string));
}
writeAll(objects, separator = "") {
if (objects == null) dart.nullFailed(I[177], 145, 35, "objects");
if (separator == null) dart.nullFailed(I[177], 145, 52, "separator");
let first = true;
for (let object of objects) {
if (first) {
first = false;
} else {
this.write(separator);
}
this.write(object);
}
}
writeln(object = "") {
this.write(object);
this.write("\n");
}
writeCharCode(charCode) {
if (charCode == null) dart.nullFailed(I[177], 165, 26, "charCode");
this.write(core.String.fromCharCode(charCode));
}
};
(sink_base.IOSinkBase.new = function(encoding = C[185] || CT.C185) {
if (encoding == null) dart.nullFailed(I[177], 111, 20, "encoding");
this[S$0.encoding] = encoding;
sink_base.IOSinkBase.__proto__.new.call(this);
;
}).prototype = sink_base.IOSinkBase.prototype;
dart.addTypeTests(sink_base.IOSinkBase);
dart.addTypeCaches(sink_base.IOSinkBase);
dart.setMethodSignature(sink_base.IOSinkBase, () => ({
__proto__: dart.getMethods(sink_base.IOSinkBase.__proto__),
flush: dart.fnType(async.Future$(dart.void), []),
write: dart.fnType(dart.void, [dart.nullable(core.Object)]),
writeAll: dart.fnType(dart.void, [core.Iterable$(dart.nullable(core.Object))], [core.String]),
writeln: dart.fnType(dart.void, [], [dart.nullable(core.Object)]),
writeCharCode: dart.fnType(dart.void, [core.int])
}));
dart.setLibraryUri(sink_base.IOSinkBase, I[178]);
dart.setFieldSignature(sink_base.IOSinkBase, () => ({
__proto__: dart.getFields(sink_base.IOSinkBase.__proto__),
encoding: dart.fieldType(convert.Encoding)
}));
const _is_StreamCloser_default = Symbol('_is_StreamCloser_default');
stream_closer.StreamCloser$ = dart.generic(T => {
var __t$StreamSubscriptionOfT = () => (__t$StreamSubscriptionOfT = dart.constFn(async.StreamSubscription$(T)))();
var __t$LinkedHashSetOfStreamSubscriptionOfT = () => (__t$LinkedHashSetOfStreamSubscriptionOfT = dart.constFn(collection.LinkedHashSet$(__t$StreamSubscriptionOfT())))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$LinkedHashSetOfStreamControllerOfT = () => (__t$LinkedHashSetOfStreamControllerOfT = dart.constFn(collection.LinkedHashSet$(__t$StreamControllerOfT())))();
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class StreamCloser extends async.StreamTransformerBase$(T, T) {
close() {
let t189;
t189 = this[S$0._closeFuture];
return t189 == null ? this[S$0._closeFuture] = dart.fn(() => {
let futures = (() => {
let t190 = T$0.JSArrayOfFutureOfvoid().of([]);
for (let subscription of this[S$0._subscriptions$1])
t190.push(subscription.cancel());
return t190;
})();
this[S$0._subscriptions$1].clear();
let controllers = this[S$0._controllers][S$.$toList]();
this[S$0._controllers].clear();
async.scheduleMicrotask(dart.fn(() => {
for (let controller of controllers) {
async.scheduleMicrotask(dart.bind(controller, 'close'));
}
}, T$.VoidTovoid()));
return async.Future.wait(dart.void, futures, {eagerError: true});
}, T$0.VoidToFutureOfListOfvoid())() : t189;
}
get isClosed() {
return this[S$0._closeFuture] != null;
}
bind(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[179], 61, 28, "stream");
let controller = dart.test(stream.isBroadcast) ? __t$StreamControllerOfT().broadcast({sync: true}) : __t$StreamControllerOfT().new({sync: true});
controller.onListen = dart.fn(() => {
if (dart.test(this.isClosed)) {
stream.listen(null).cancel().catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
return;
}
let subscription = stream.listen(__t$TTovoid().as(dart.bind(controller, 'add')), {onError: dart.bind(controller, 'addError')});
subscription.onDone(dart.fn(() => {
this[S$0._subscriptions$1].remove(subscription);
this[S$0._controllers].remove(controller);
controller.close();
}, T$.VoidTovoid()));
this[S$0._subscriptions$1].add(subscription);
if (!dart.test(stream.isBroadcast)) {
controller.onPause = dart.bind(subscription, 'pause');
controller.onResume = dart.bind(subscription, 'resume');
}
controller.onCancel = dart.fn(() => {
this[S$0._controllers].remove(controller);
if (dart.test(this[S$0._subscriptions$1].remove(subscription))) return subscription.cancel();
return null;
}, T$0.VoidToFutureNOfvoid());
}, T$.VoidTovoid());
if (dart.test(this.isClosed)) {
controller.close();
} else {
this[S$0._controllers].add(controller);
}
return controller.stream;
}
static ['_#new#tearOff'](T) {
return new (stream_closer.StreamCloser$(T)).new();
}
}
(StreamCloser.new = function() {
this[S$0._subscriptions$1] = __t$LinkedHashSetOfStreamSubscriptionOfT().new();
this[S$0._controllers] = __t$LinkedHashSetOfStreamControllerOfT().new();
this[S$0._closeFuture] = null;
StreamCloser.__proto__.new.call(this);
;
}).prototype = StreamCloser.prototype;
dart.addTypeTests(StreamCloser);
StreamCloser.prototype[_is_StreamCloser_default] = true;
dart.addTypeCaches(StreamCloser);
dart.setMethodSignature(StreamCloser, () => ({
__proto__: dart.getMethods(StreamCloser.__proto__),
close: dart.fnType(async.Future$(dart.void), []),
bind: dart.fnType(async.Stream$(T), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(StreamCloser, () => ({
__proto__: dart.getGetters(StreamCloser.__proto__),
isClosed: core.bool
}));
dart.setLibraryUri(StreamCloser, I[180]);
dart.setFieldSignature(StreamCloser, () => ({
__proto__: dart.getFields(StreamCloser.__proto__),
[S$0._subscriptions$1]: dart.finalFieldType(core.Set$(async.StreamSubscription$(T))),
[S$0._controllers]: dart.finalFieldType(core.Set$(async.StreamController$(T))),
[S$0._closeFuture]: dart.fieldType(dart.nullable(async.Future$(dart.void)))
}));
return StreamCloser;
});
stream_closer.StreamCloser = stream_closer.StreamCloser$();
dart.addTypeTests(stream_closer.StreamCloser, _is_StreamCloser_default);
const _is_StreamCompleter_default = Symbol('_is_StreamCompleter_default');
stream_completer.StreamCompleter$ = dart.generic(T => {
var __t$_CompleterStreamOfT = () => (__t$_CompleterStreamOfT = dart.constFn(stream_completer._CompleterStream$(T)))();
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$FutureOfT = () => (__t$FutureOfT = dart.constFn(async.Future$(T)))();
class StreamCompleter extends core.Object {
static fromFuture(T, streamFuture) {
if (streamFuture == null) dart.nullFailed(I[181], 37, 52, "streamFuture");
let completer = new (stream_completer.StreamCompleter$(T)).new();
streamFuture.then(dart.void, dart.fnType(dart.void, [async.Stream$(T)]).as(dart.bind(completer, 'setSourceStream')), {onError: dart.bind(completer, 'setError')});
return completer.stream;
}
get stream() {
return this[S$0._stream];
}
setSourceStream(sourceStream) {
__t$StreamOfT().as(sourceStream);
if (sourceStream == null) dart.nullFailed(I[181], 76, 34, "sourceStream");
if (dart.test(this[S$0._stream][S$0._isSourceStreamSet])) {
dart.throw(new core.StateError.new("Source stream already set"));
}
this[S$0._stream][S$0._setSourceStream](sourceStream);
}
setEmpty() {
if (dart.test(this[S$0._stream][S$0._isSourceStreamSet])) {
dart.throw(new core.StateError.new("Source stream already set"));
}
this[S$0._stream][S$0._setEmpty]();
}
setError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[181], 100, 24, "error");
this.setSourceStream(__t$StreamOfT().fromFuture(__t$FutureOfT().error(error, stackTrace)));
}
static ['_#new#tearOff'](T) {
return new (stream_completer.StreamCompleter$(T)).new();
}
}
(StreamCompleter.new = function() {
this[S$0._stream] = new (__t$_CompleterStreamOfT()).new();
;
}).prototype = StreamCompleter.prototype;
dart.addTypeTests(StreamCompleter);
StreamCompleter.prototype[_is_StreamCompleter_default] = true;
dart.addTypeCaches(StreamCompleter);
dart.setMethodSignature(StreamCompleter, () => ({
__proto__: dart.getMethods(StreamCompleter.__proto__),
setSourceStream: dart.fnType(dart.void, [dart.nullable(core.Object)]),
setEmpty: dart.fnType(dart.void, []),
setError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)])
}));
dart.setStaticMethodSignature(StreamCompleter, () => ['fromFuture']);
dart.setGetterSignature(StreamCompleter, () => ({
__proto__: dart.getGetters(StreamCompleter.__proto__),
stream: async.Stream$(T)
}));
dart.setLibraryUri(StreamCompleter, I[182]);
dart.setFieldSignature(StreamCompleter, () => ({
__proto__: dart.getFields(StreamCompleter.__proto__),
[S$0._stream]: dart.finalFieldType(stream_completer._CompleterStream$(T))
}));
return StreamCompleter;
});
stream_completer.StreamCompleter = stream_completer.StreamCompleter$();
dart.addTypeTests(stream_completer.StreamCompleter, _is_StreamCompleter_default);
const _is__CompleterStream_default = Symbol('_is__CompleterStream_default');
stream_completer._CompleterStream$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
class _CompleterStream extends async.Stream$(T) {
listen(onData, opts) {
let onError = opts && 'onError' in opts ? opts.onError : null;
let onDone = opts && 'onDone' in opts ? opts.onDone : null;
let cancelOnError = opts && 'cancelOnError' in opts ? opts.cancelOnError : null;
if (this[S$0._controller$1] == null) {
let sourceStream = this[S$0._sourceStream];
if (sourceStream != null && !dart.test(sourceStream.isBroadcast)) {
return sourceStream.listen(onData, {onError: onError, onDone: onDone, cancelOnError: cancelOnError});
}
this[S$0._ensureController$1]();
if (this[S$0._sourceStream] != null) {
this[S$0._linkStreamToController]();
}
}
return dart.nullCheck(this[S$0._controller$1]).stream.listen(onData, {onError: onError, onDone: onDone, cancelOnError: cancelOnError});
}
get [S$0._isSourceStreamSet]() {
return this[S$0._sourceStream] != null;
}
[S$0._setSourceStream](sourceStream) {
__t$StreamOfT().as(sourceStream);
if (sourceStream == null) dart.nullFailed(I[181], 150, 35, "sourceStream");
if (!(this[S$0._sourceStream] == null)) dart.assertFailed(null, I[181], 151, 12, "_sourceStream == null");
this[S$0._sourceStream] = sourceStream;
if (this[S$0._controller$1] != null) {
this[S$0._linkStreamToController]();
}
}
[S$0._linkStreamToController]() {
let controller = dart.nullCheck(this[S$0._controller$1]);
controller.addStream(dart.nullCheck(this[S$0._sourceStream]), {cancelOnError: false}).whenComplete(dart.bind(controller, 'close'));
}
[S$0._setEmpty]() {
if (!(this[S$0._sourceStream] == null)) dart.assertFailed(null, I[181], 172, 12, "_sourceStream == null");
let controller = this[S$0._ensureController$1]();
this[S$0._sourceStream] = controller.stream;
controller.close();
}
[S$0._ensureController$1]() {
let t190;
t190 = this[S$0._controller$1];
return t190 == null ? this[S$0._controller$1] = __t$StreamControllerOfT().new({sync: true}) : t190;
}
static ['_#new#tearOff'](T) {
return new (stream_completer._CompleterStream$(T)).new();
}
}
(_CompleterStream.new = function() {
this[S$0._controller$1] = null;
this[S$0._sourceStream] = null;
_CompleterStream.__proto__.new.call(this);
;
}).prototype = _CompleterStream.prototype;
dart.addTypeTests(_CompleterStream);
_CompleterStream.prototype[_is__CompleterStream_default] = true;
dart.addTypeCaches(_CompleterStream);
dart.setMethodSignature(_CompleterStream, () => ({
__proto__: dart.getMethods(_CompleterStream.__proto__),
listen: dart.fnType(async.StreamSubscription$(T), [dart.nullable(dart.fnType(dart.void, [T]))], {cancelOnError: dart.nullable(core.bool), onDone: dart.nullable(dart.fnType(dart.void, [])), onError: dart.nullable(core.Function)}, {}),
[S$0._setSourceStream]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._linkStreamToController]: dart.fnType(dart.void, []),
[S$0._setEmpty]: dart.fnType(dart.void, []),
[S$0._ensureController$1]: dart.fnType(async.StreamController$(T), [])
}));
dart.setGetterSignature(_CompleterStream, () => ({
__proto__: dart.getGetters(_CompleterStream.__proto__),
[S$0._isSourceStreamSet]: core.bool
}));
dart.setLibraryUri(_CompleterStream, I[182]);
dart.setFieldSignature(_CompleterStream, () => ({
__proto__: dart.getFields(_CompleterStream.__proto__),
[S$0._controller$1]: dart.fieldType(dart.nullable(async.StreamController$(T))),
[S$0._sourceStream]: dart.fieldType(dart.nullable(async.Stream$(T)))
}));
return _CompleterStream;
});
stream_completer._CompleterStream = stream_completer._CompleterStream$();
dart.addTypeTests(stream_completer._CompleterStream, _is__CompleterStream_default);
stream_extensions['StreamExtensions|slices'] = function StreamExtensions$124slices(T, $this, length) {
if ($this == null) dart.nullFailed(I[183], 21, 19, "#this");
if (length == null) dart.nullFailed(I[183], 21, 30, "length");
if (dart.notNull(length) < 1) dart.throw(new core.RangeError.range(length, 1, null, "length"));
let slice = _interceptors.JSArray$(T).of([]);
return $this.transform(core.List$(T), new (async._StreamHandlerTransformer$(T, core.List$(T))).new({handleData: dart.fn((data, sink) => {
if (sink == null) dart.nullFailed(I[183], 25, 72, "sink");
slice[S$.$add](data);
if (slice[S$.$length] == length) {
sink.add(slice);
slice = _interceptors.JSArray$(T).of([]);
}
}, dart.fnType(dart.void, [T, async.EventSink$(core.List$(T))])), handleDone: dart.fn(sink => {
if (sink == null) dart.nullFailed(I[183], 31, 21, "sink");
if (dart.test(slice[S$.$isNotEmpty])) sink.add(slice);
sink.close();
}, dart.fnType(dart.void, [async.EventSink$(core.List$(T))]))}));
};
stream_extensions['StreamExtensions|get#slices'] = function StreamExtensions$124get$35slices(T, $this) {
if ($this == null) dart.nullFailed(I[183], 21, 19, "#this");
return dart.fn(length => {
if (length == null) dart.nullFailed(I[183], 21, 30, "length");
return stream_extensions['StreamExtensions|slices'](T, $this, length);
}, dart.fnType(async.Stream$(core.List$(T)), [core.int]));
};
const _is_StreamGroup_default = Symbol('_is_StreamGroup_default');
stream_group.StreamGroup$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$StreamSubscriptionOfT = () => (__t$StreamSubscriptionOfT = dart.constFn(async.StreamSubscription$(T)))();
var __t$StreamSubscriptionNOfT = () => (__t$StreamSubscriptionNOfT = dart.constFn(dart.nullable(__t$StreamSubscriptionOfT())))();
var __t$LinkedMapOfStreamOfT$StreamSubscriptionNOfT = () => (__t$LinkedMapOfStreamOfT$StreamSubscriptionNOfT = dart.constFn(_js_helper.LinkedMap$(__t$StreamOfT(), __t$StreamSubscriptionNOfT())))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$VoidToStreamSubscriptionOfT = () => (__t$VoidToStreamSubscriptionOfT = dart.constFn(dart.fnType(__t$StreamSubscriptionOfT(), [])))();
var __t$MapEntryOfStreamOfT$StreamSubscriptionNOfT = () => (__t$MapEntryOfStreamOfT$StreamSubscriptionNOfT = dart.constFn(core.MapEntry$(__t$StreamOfT(), __t$StreamSubscriptionNOfT())))();
var __t$ListOfMapEntryOfStreamOfT$StreamSubscriptionNOfT = () => (__t$ListOfMapEntryOfStreamOfT$StreamSubscriptionNOfT = dart.constFn(core.List$(__t$MapEntryOfStreamOfT$StreamSubscriptionNOfT())))();
var __t$MapEntryOfStreamOfT$StreamSubscriptionNOfTToFutureNOfvoid = () => (__t$MapEntryOfStreamOfT$StreamSubscriptionNOfTToFutureNOfvoid = dart.constFn(dart.fnType(T$0.FutureNOfvoid(), [__t$MapEntryOfStreamOfT$StreamSubscriptionNOfT()])))();
var __t$StreamOfTAndStreamSubscriptionNOfTTovoid = () => (__t$StreamOfTAndStreamSubscriptionNOfTTovoid = dart.constFn(dart.fnType(dart.void, [__t$StreamOfT(), __t$StreamSubscriptionNOfT()])))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class StreamGroup extends core.Object {
get stream() {
return this[S$0._controller$2].stream;
}
get [S$0._controller$2]() {
let t192;
return dart.test(this[S$0.__StreamGroup__controller_isSet]) ? (t192 = this[S$0.__StreamGroup__controller], t192) : dart.throw(new _internal.LateError.fieldNI("_controller"));
}
set [S$0._controller$2](t192) {
if (t192 == null) dart.nullFailed(I[184], 34, 28, "null");
this[S$0.__StreamGroup__controller_isSet] = true;
this[S$0.__StreamGroup__controller] = t192;
}
get isClosed() {
return this[S$0._closed$4];
}
get isIdle() {
return this[S$0._subscriptions$2][S$.$isEmpty];
}
get onIdle() {
let t193;
return (t193 = this[S$0._onIdleController$1], t193 == null ? this[S$0._onIdleController$1] = T$0.StreamControllerOfNull().broadcast() : t193).stream;
}
static merge(T, streams) {
if (streams == null) dart.nullFailed(I[184], 93, 49, "streams");
let group = new (stream_group.StreamGroup$(T)).new();
streams[S$.$forEach](dart.fnType(T$0.FutureN(), [async.Stream$(T)]).as(dart.bind(group, 'add')));
group.close();
return group.stream;
}
static mergeBroadcast(T, streams) {
if (streams == null) dart.nullFailed(I[184], 104, 58, "streams");
let group = new (stream_group.StreamGroup$(T)).broadcast();
streams[S$.$forEach](dart.fnType(T$0.FutureN(), [async.Stream$(T)]).as(dart.bind(group, 'add')));
group.close();
return group.stream;
}
static ['_#new#tearOff'](T) {
return new (stream_group.StreamGroup$(T)).new();
}
static ['_#broadcast#tearOff'](T) {
return new (stream_group.StreamGroup$(T)).broadcast();
}
add(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[184], 140, 25, "stream");
if (dart.test(this[S$0._closed$4])) {
dart.throw(new core.StateError.new("Can't add a Stream to a closed StreamGroup."));
}
if (dart.equals(this[S$0._state$4], stream_group._StreamGroupState.dormant)) {
this[S$0._subscriptions$2][S$.$putIfAbsent](stream, dart.fn(() => null, T$.VoidToNull()));
} else if (dart.equals(this[S$0._state$4], stream_group._StreamGroupState.canceled)) {
return stream.listen(null).cancel();
} else {
this[S$0._subscriptions$2][S$.$putIfAbsent](stream, dart.fn(() => this[S$0._listenToStream](stream), __t$VoidToStreamSubscriptionOfT()));
}
return null;
}
remove(stream) {
let t193, t193$;
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[184], 170, 28, "stream");
let subscription = this[S$0._subscriptions$2][S$.$remove](stream);
let future = subscription == null ? null : subscription.cancel();
if (dart.test(this[S$0._subscriptions$2][S$.$isEmpty])) {
t193 = this[S$0._onIdleController$1];
t193 == null ? null : t193.add(null);
if (dart.test(this[S$0._closed$4])) {
t193$ = this[S$0._onIdleController$1];
t193$ == null ? null : t193$.close();
async.scheduleMicrotask(dart.bind(this[S$0._controller$2], 'close'));
}
}
return future;
}
[S$0._onListen$1]() {
let t195;
this[S$0._state$4] = stream_group._StreamGroupState.listening;
for (let entry of (() => {
let t193 = __t$ListOfMapEntryOfStreamOfT$StreamSubscriptionNOfT().of(this[S$0._subscriptions$2][S$.$entries]);
return t193;
})()) {
if (entry.value != null) continue;
let stream = entry.key;
try {
this[S$0._subscriptions$2][S$.$_set](stream, this[S$0._listenToStream](stream));
} catch (e) {
let error = dart.getThrown(e);
if (core.Object.is(error)) {
t195 = this[S$0._onCancel$1]();
t195 == null ? null : t195.catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
dart.rethrow(e);
} else
throw e;
}
}
}
[S$0._onPause$1]() {
this[S$0._state$4] = stream_group._StreamGroupState.paused;
for (let subscription of this[S$0._subscriptions$2][S$.$values]) {
dart.nullCheck(subscription).pause();
}
}
[S$0._onResume$1]() {
this[S$0._state$4] = stream_group._StreamGroupState.listening;
for (let subscription of this[S$0._subscriptions$2][S$.$values]) {
dart.nullCheck(subscription).resume();
}
}
[S$0._onCancel$1]() {
this[S$0._state$4] = stream_group._StreamGroupState.canceled;
let futures = iterable_extensions['IterableNullableExtension|whereNotNull'](T$.FutureOfvoid(), this[S$0._subscriptions$2][S$.$entries][S$.$map](T$0.FutureNOfvoid(), dart.fn(entry => {
if (entry == null) dart.nullFailed(I[184], 233, 15, "entry");
let subscription = entry.value;
try {
if (subscription != null) return subscription.cancel();
return entry.key.listen(null).cancel();
} catch (e) {
let _ = dart.getThrown(e);
if (core.Object.is(_)) {
return null;
} else
throw e;
}
}, __t$MapEntryOfStreamOfT$StreamSubscriptionNOfTToFutureNOfvoid())))[S$.$toList]();
this[S$0._subscriptions$2][S$.$clear]();
let onIdleController = this[S$0._onIdleController$1];
if (onIdleController != null && !dart.test(onIdleController.isClosed)) {
onIdleController.add(null);
onIdleController.close();
}
return dart.test(futures[S$.$isEmpty]) ? null : async.Future.wait(dart.void, futures);
}
[S$0._onCancelBroadcast]() {
this[S$0._state$4] = stream_group._StreamGroupState.dormant;
this[S$0._subscriptions$2][S$.$forEach](dart.fn((stream, subscription) => {
if (stream == null) dart.nullFailed(I[184], 262, 29, "stream");
if (!dart.test(stream.isBroadcast)) return;
dart.nullCheck(subscription).cancel();
this[S$0._subscriptions$2][S$.$_set](stream, null);
}, __t$StreamOfTAndStreamSubscriptionNOfTTovoid()));
}
[S$0._listenToStream](stream) {
if (stream == null) dart.nullFailed(I[184], 276, 51, "stream");
let subscription = stream.listen(__t$TTovoid().as(dart.bind(this[S$0._controller$2], 'add')), {onError: dart.bind(this[S$0._controller$2], 'addError'), onDone: dart.fn(() => this.remove(stream), T$.VoidTovoid())});
if (dart.equals(this[S$0._state$4], stream_group._StreamGroupState.paused)) subscription.pause();
return subscription;
}
close() {
if (dart.test(this[S$0._closed$4])) return this[S$0._controller$2].done;
this[S$0._closed$4] = true;
if (dart.test(this[S$0._subscriptions$2][S$.$isEmpty])) this[S$0._controller$2].close();
return this[S$0._controller$2].done;
}
}
(StreamGroup.new = function() {
this[S$0.__StreamGroup__controller] = null;
this[S$0.__StreamGroup__controller_isSet] = false;
this[S$0._closed$4] = false;
this[S$0._state$4] = stream_group._StreamGroupState.dormant;
this[S$0._onIdleController$1] = null;
this[S$0._subscriptions$2] = new (__t$LinkedMapOfStreamOfT$StreamSubscriptionNOfT()).new();
this[S$0._controller$2] = __t$StreamControllerOfT().new({onListen: dart.bind(this, S$0._onListen$1), onPause: dart.bind(this, S$0._onPause$1), onResume: dart.bind(this, S$0._onResume$1), onCancel: dart.bind(this, S$0._onCancel$1), sync: true});
}).prototype = StreamGroup.prototype;
(StreamGroup.broadcast = function() {
this[S$0.__StreamGroup__controller] = null;
this[S$0.__StreamGroup__controller_isSet] = false;
this[S$0._closed$4] = false;
this[S$0._state$4] = stream_group._StreamGroupState.dormant;
this[S$0._onIdleController$1] = null;
this[S$0._subscriptions$2] = new (__t$LinkedMapOfStreamOfT$StreamSubscriptionNOfT()).new();
this[S$0._controller$2] = __t$StreamControllerOfT().broadcast({onListen: dart.bind(this, S$0._onListen$1), onCancel: dart.bind(this, S$0._onCancelBroadcast), sync: true});
}).prototype = StreamGroup.prototype;
dart.addTypeTests(StreamGroup);
StreamGroup.prototype[_is_StreamGroup_default] = true;
dart.addTypeCaches(StreamGroup);
StreamGroup[dart.implements] = () => [core.Sink$(async.Stream$(T))];
dart.setMethodSignature(StreamGroup, () => ({
__proto__: dart.getMethods(StreamGroup.__proto__),
add: dart.fnType(dart.nullable(async.Future), [dart.nullable(core.Object)]),
remove: dart.fnType(dart.nullable(async.Future), [dart.nullable(core.Object)]),
[S$0._onListen$1]: dart.fnType(dart.void, []),
[S$0._onPause$1]: dart.fnType(dart.void, []),
[S$0._onResume$1]: dart.fnType(dart.void, []),
[S$0._onCancel$1]: dart.fnType(dart.nullable(async.Future), []),
[S$0._onCancelBroadcast]: dart.fnType(dart.void, []),
[S$0._listenToStream]: dart.fnType(async.StreamSubscription$(T), [async.Stream$(T)]),
close: dart.fnType(async.Future, [])
}));
dart.setStaticMethodSignature(StreamGroup, () => ['merge', 'mergeBroadcast']);
dart.setGetterSignature(StreamGroup, () => ({
__proto__: dart.getGetters(StreamGroup.__proto__),
stream: async.Stream$(T),
[S$0._controller$2]: async.StreamController$(T),
isClosed: core.bool,
isIdle: core.bool,
onIdle: async.Stream$(dart.void)
}));
dart.setSetterSignature(StreamGroup, () => ({
__proto__: dart.getSetters(StreamGroup.__proto__),
[S$0._controller$2]: async.StreamController$(T)
}));
dart.setLibraryUri(StreamGroup, I[185]);
dart.setFieldSignature(StreamGroup, () => ({
__proto__: dart.getFields(StreamGroup.__proto__),
[S$0.__StreamGroup__controller]: dart.fieldType(dart.nullable(async.StreamController$(T))),
[S$0.__StreamGroup__controller_isSet]: dart.fieldType(core.bool),
[S$0._closed$4]: dart.fieldType(core.bool),
[S$0._state$4]: dart.fieldType(stream_group._StreamGroupState),
[S$0._onIdleController$1]: dart.fieldType(dart.nullable(async.StreamController$(core.Null))),
[S$0._subscriptions$2]: dart.finalFieldType(core.Map$(async.Stream$(T), dart.nullable(async.StreamSubscription$(T))))
}));
return StreamGroup;
});
stream_group.StreamGroup = stream_group.StreamGroup$();
dart.addTypeTests(stream_group.StreamGroup, _is_StreamGroup_default);
stream_group._StreamGroupState = class _StreamGroupState extends core.Object {
get name() {
return this[S$0.name$8];
}
set name(value) {
super.name = value;
}
static ['_#new#tearOff'](name) {
if (name == null) dart.nullFailed(I[184], 334, 32, "name");
return new stream_group._StreamGroupState.new(name);
}
toString() {
return this.name;
}
};
(stream_group._StreamGroupState.new = function(name) {
if (name == null) dart.nullFailed(I[184], 334, 32, "name");
this[S$0.name$8] = name;
;
}).prototype = stream_group._StreamGroupState.prototype;
dart.addTypeTests(stream_group._StreamGroupState);
dart.addTypeCaches(stream_group._StreamGroupState);
dart.setLibraryUri(stream_group._StreamGroupState, I[185]);
dart.setFieldSignature(stream_group._StreamGroupState, () => ({
__proto__: dart.getFields(stream_group._StreamGroupState.__proto__),
name: dart.finalFieldType(core.String)
}));
dart.setStaticFieldSignature(stream_group._StreamGroupState, () => ['dormant', 'listening', 'paused', 'canceled']);
dart.defineExtensionMethods(stream_group._StreamGroupState, ['toString']);
dart.defineLazy(stream_group._StreamGroupState, {
/*stream_group._StreamGroupState.dormant*/get dormant() {
return C[186] || CT.C186;
},
/*stream_group._StreamGroupState.listening*/get listening() {
return C[187] || CT.C187;
},
/*stream_group._StreamGroupState.paused*/get paused() {
return C[188] || CT.C188;
},
/*stream_group._StreamGroupState.canceled*/get canceled() {
return C[189] || CT.C189;
}
}, false);
const _is_StreamQueue_default = Symbol('_is_StreamQueue_default');
stream_queue.StreamQueue$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
var __t$_HasNextRequestOfT = () => (__t$_HasNextRequestOfT = dart.constFn(stream_queue._HasNextRequest$(T)))();
var __t$_LookAheadRequestOfT = () => (__t$_LookAheadRequestOfT = dart.constFn(stream_queue._LookAheadRequest$(T)))();
var __t$_NextRequestOfT = () => (__t$_NextRequestOfT = dart.constFn(stream_queue._NextRequest$(T)))();
var __t$_PeekRequestOfT = () => (__t$_PeekRequestOfT = dart.constFn(stream_queue._PeekRequest$(T)))();
var __t$_RestRequestOfT = () => (__t$_RestRequestOfT = dart.constFn(stream_queue._RestRequest$(T)))();
var __t$_SkipRequestOfT = () => (__t$_SkipRequestOfT = dart.constFn(stream_queue._SkipRequest$(T)))();
var __t$_TakeRequestOfT = () => (__t$_TakeRequestOfT = dart.constFn(stream_queue._TakeRequest$(T)))();
var __t$_TransactionRequestOfT = () => (__t$_TransactionRequestOfT = dart.constFn(stream_queue._TransactionRequest$(T)))();
var __t$_CancelRequestOfT = () => (__t$_CancelRequestOfT = dart.constFn(stream_queue._CancelRequest$(T)))();
var __t$_EmptyStreamOfT = () => (__t$_EmptyStreamOfT = dart.constFn(async._EmptyStream$(T)))();
var __t$SubscriptionStreamOfT = () => (__t$SubscriptionStreamOfT = dart.constFn(subscription_stream.SubscriptionStream$(T)))();
var __t$ValueResultOfT = () => (__t$ValueResultOfT = dart.constFn(value$.ValueResult$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class StreamQueue extends core.Object {
get eventsDispatched() {
return dart.notNull(this[S$0._eventsReceived]) - dart.notNull(this[S$0._eventQueue].length);
}
static new(source) {
if (source == null) dart.nullFailed(I[186], 118, 33, "source");
return new (stream_queue.StreamQueue$(T)).__(source);
}
static ['_#new#tearOff'](T, source) {
if (source == null) dart.nullFailed(I[186], 118, 33, "source");
return stream_queue.StreamQueue$(T).new(source);
}
static ['_#_#tearOff'](T, _source) {
if (_source == null) dart.nullFailed(I[186], 121, 22, "_source");
return new (stream_queue.StreamQueue$(T)).__(_source);
}
get hasNext() {
this[S$0._checkNotClosed]();
let hasNextRequest = new (__t$_HasNextRequestOfT()).new();
this[S$0._addRequest](hasNextRequest);
return hasNextRequest.future;
}
lookAhead(count) {
if (count == null) dart.nullFailed(I[186], 152, 33, "count");
core.RangeError.checkNotNegative(count, "count");
this[S$0._checkNotClosed]();
let request = new (__t$_LookAheadRequestOfT()).new(count);
this[S$0._addRequest](request);
return request.future;
}
get next() {
this[S$0._checkNotClosed]();
let nextRequest = new (__t$_NextRequestOfT()).new();
this[S$0._addRequest](nextRequest);
return nextRequest.future;
}
get peek() {
this[S$0._checkNotClosed]();
let nextRequest = new (__t$_PeekRequestOfT()).new();
this[S$0._addRequest](nextRequest);
return nextRequest.future;
}
get rest() {
this[S$0._checkNotClosed]();
let request = new (__t$_RestRequestOfT()).new(this);
this[S$0._isClosed] = true;
this[S$0._addRequest](request);
return request.stream;
}
skip(count) {
if (count == null) dart.nullFailed(I[186], 224, 24, "count");
core.RangeError.checkNotNegative(count, "count");
this[S$0._checkNotClosed]();
let request = new (__t$_SkipRequestOfT()).new(count);
this[S$0._addRequest](request);
return request.future;
}
take(count) {
if (count == null) dart.nullFailed(I[186], 247, 28, "count");
core.RangeError.checkNotNegative(count, "count");
this[S$0._checkNotClosed]();
let request = new (__t$_TakeRequestOfT()).new(count);
this[S$0._addRequest](request);
return request.future;
}
startTransaction() {
this[S$0._checkNotClosed]();
let request = new (__t$_TransactionRequestOfT()).new(this);
this[S$0._addRequest](request);
return request.transaction;
}
withTransaction(callback) {
if (callback == null) dart.nullFailed(I[186], 320, 45, "callback");
return async.async(core.bool, (function* withTransaction() {
let transaction = this.startTransaction();
let queue = transaction.newQueue();
let result = null;
try {
result = (yield callback(queue));
} catch (e) {
let _ = dart.getThrown(e);
if (core.Object.is(_)) {
transaction.commit(queue);
dart.rethrow(e);
} else
throw e;
}
if (dart.test(result)) {
transaction.commit(queue);
} else {
transaction.reject();
}
return result;
}).bind(this));
}
cancelable(S, callback) {
if (callback == null) dart.nullFailed(I[186], 359, 42, "callback");
let transaction = this.startTransaction();
let completer = new (cancelable_operation.CancelableCompleter$(S)).new({onCancel: dart.fn(() => {
transaction.reject();
}, T$.VoidToNull())});
let queue = transaction.newQueue();
completer.complete(callback(queue).whenComplete(dart.fn(() => {
if (!dart.test(completer.isCanceled)) transaction.commit(queue);
}, T$.VoidToNull())));
return completer.operation;
}
cancel(opts) {
let immediate = opts && 'immediate' in opts ? opts.immediate : false;
if (immediate == null) dart.nullFailed(I[186], 389, 24, "immediate");
this[S$0._checkNotClosed]();
this[S$0._isClosed] = true;
if (!dart.test(immediate)) {
let request = new (__t$_CancelRequestOfT()).new(this);
this[S$0._addRequest](request);
return request.future;
}
if (dart.test(this[S$0._isDone]) && dart.test(this[S$0._eventQueue].isEmpty)) return async.Future.value();
return this[S$0._cancel$2]();
}
[S$0._updateRequests]() {
while (dart.test(this[S$0._requestQueue][S$.$isNotEmpty])) {
if (dart.test(this[S$0._requestQueue][S$.$first].update(this[S$0._eventQueue], this[S$0._isDone]))) {
this[S$0._requestQueue].removeFirst();
} else {
return;
}
}
if (!dart.test(this[S$0._isDone])) {
this[S$0._pause]();
}
}
[S$0._extractStream]() {
if (!dart.test(this[S$0._isClosed])) dart.assertFailed(null, I[186], 438, 12, "_isClosed");
if (dart.test(this[S$0._isDone])) {
return new (__t$_EmptyStreamOfT()).new();
}
this[S$0._isDone] = true;
let subscription = this[S$0._subscription$1];
if (subscription == null) {
return this[S$0._source$3];
}
this[S$0._subscription$1] = null;
let wasPaused = subscription.isPaused;
let result = new (__t$SubscriptionStreamOfT()).new(subscription);
if (dart.test(wasPaused)) subscription.resume();
return result;
}
[S$0._pause]() {
dart.nullCheck(this[S$0._subscription$1]).pause();
}
[S$0._ensureListening]() {
if (dart.test(this[S$0._isDone])) return;
if (this[S$0._subscription$1] == null) {
this[S$0._subscription$1] = this[S$0._source$3].listen(dart.fn(data => {
this[S$0._addResult](new (__t$ValueResultOfT()).new(data));
}, __t$TTovoid()), {onError: dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[186], 477, 27, "error");
if (stackTrace == null) dart.nullFailed(I[186], 477, 45, "stackTrace");
this[S$0._addResult](__t$ResultOfT().error(error, stackTrace));
}, T$.ObjectAndStackTraceToNull()), onDone: dart.fn(() => {
this[S$0._subscription$1] = null;
this[S$0._close$1]();
}, T$.VoidTovoid())});
} else {
dart.nullCheck(this[S$0._subscription$1]).resume();
}
}
[S$0._cancel$2]() {
if (dart.test(this[S$0._isDone])) return null;
this[S$0._subscription$1] == null ? this[S$0._subscription$1] = this[S$0._source$3].listen(null) : null;
let future = dart.nullCheck(this[S$0._subscription$1]).cancel();
this[S$0._close$1]();
return future;
}
[S$0._addResult](result) {
if (result == null) dart.nullFailed(I[186], 503, 29, "result");
this[S$0._eventsReceived] = dart.notNull(this[S$0._eventsReceived]) + 1;
this[S$0._eventQueue].add(result);
this[S$0._updateRequests]();
}
[S$0._close$1]() {
this[S$0._isDone] = true;
this[S$0._updateRequests]();
}
[S$0._checkNotClosed]() {
if (dart.test(this[S$0._isClosed])) dart.throw(new core.StateError.new("Already cancelled"));
}
[S$0._addRequest](request) {
if (request == null) dart.nullFailed(I[186], 528, 37, "request");
if (dart.test(this[S$0._requestQueue][S$.$isEmpty])) {
if (dart.test(request.update(this[S$0._eventQueue], this[S$0._isDone]))) return;
this[S$0._ensureListening]();
}
this[S$0._requestQueue].add(request);
}
}
(StreamQueue.__ = function(_source) {
if (_source == null) dart.nullFailed(I[186], 121, 22, "_source");
this[S$0._subscription$1] = null;
this[S$0._isDone] = false;
this[S$0._isClosed] = false;
this[S$0._eventsReceived] = 0;
this[S$0._eventQueue] = new (__t$QueueListOfResultOfT()).new();
this[S$0._requestQueue] = new (T$0.ListQueueOf_EventRequest()).new();
this[S$0._source$3] = _source;
if (dart.test(this[S$0._source$3].isBroadcast)) {
this[S$0._ensureListening]();
this[S$0._pause]();
}
}).prototype = StreamQueue.prototype;
dart.addTypeTests(StreamQueue);
StreamQueue.prototype[_is_StreamQueue_default] = true;
dart.addTypeCaches(StreamQueue);
dart.setMethodSignature(StreamQueue, () => ({
__proto__: dart.getMethods(StreamQueue.__proto__),
lookAhead: dart.fnType(async.Future$(core.List$(T)), [core.int]),
skip: dart.fnType(async.Future$(core.int), [core.int]),
take: dart.fnType(async.Future$(core.List$(T)), [core.int]),
startTransaction: dart.fnType(stream_queue.StreamQueueTransaction$(T), []),
withTransaction: dart.fnType(async.Future$(core.bool), [dart.fnType(async.Future$(core.bool), [stream_queue.StreamQueue$(T)])]),
cancelable: dart.gFnType(S => [cancelable_operation.CancelableOperation$(S), [dart.fnType(async.Future$(S), [stream_queue.StreamQueue$(T)])]], S => [dart.nullable(core.Object)]),
cancel: dart.fnType(dart.nullable(async.Future), [], {immediate: core.bool}, {}),
[S$0._updateRequests]: dart.fnType(dart.void, []),
[S$0._extractStream]: dart.fnType(async.Stream$(T), []),
[S$0._pause]: dart.fnType(dart.void, []),
[S$0._ensureListening]: dart.fnType(dart.void, []),
[S$0._cancel$2]: dart.fnType(dart.nullable(async.Future), []),
[S$0._addResult]: dart.fnType(dart.void, [result$.Result$(T)]),
[S$0._close$1]: dart.fnType(dart.void, []),
[S$0._checkNotClosed]: dart.fnType(dart.void, []),
[S$0._addRequest]: dart.fnType(dart.void, [stream_queue._EventRequest$(T)])
}));
dart.setStaticMethodSignature(StreamQueue, () => ['new']);
dart.setGetterSignature(StreamQueue, () => ({
__proto__: dart.getGetters(StreamQueue.__proto__),
eventsDispatched: core.int,
hasNext: async.Future$(core.bool),
next: async.Future$(T),
peek: async.Future$(T),
rest: async.Stream$(T)
}));
dart.setLibraryUri(StreamQueue, I[187]);
dart.setFieldSignature(StreamQueue, () => ({
__proto__: dart.getFields(StreamQueue.__proto__),
[S$0._source$3]: dart.finalFieldType(async.Stream$(T)),
[S$0._subscription$1]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._isDone]: dart.fieldType(core.bool),
[S$0._isClosed]: dart.fieldType(core.bool),
[S$0._eventsReceived]: dart.fieldType(core.int),
[S$0._eventQueue]: dart.finalFieldType(queue_list.QueueList$(result$.Result$(T))),
[S$0._requestQueue]: dart.finalFieldType(collection.Queue$(stream_queue._EventRequest))
}));
return StreamQueue;
});
stream_queue.StreamQueue = stream_queue.StreamQueue$();
dart.addTypeTests(stream_queue.StreamQueue, _is_StreamQueue_default);
const _is_StreamQueueTransaction_default = Symbol('_is_StreamQueueTransaction_default');
stream_queue.StreamQueueTransaction$ = dart.generic(T => {
var __t$StreamSplitterOfT = () => (__t$StreamSplitterOfT = dart.constFn(stream_splitter.StreamSplitter$(T)))();
var __t$StreamQueueOfT = () => (__t$StreamQueueOfT = dart.constFn(stream_queue.StreamQueue$(T)))();
class StreamQueueTransaction extends core.Object {
static ['_#_#tearOff'](T, _parent, source) {
if (_parent == null) dart.nullFailed(I[186], 558, 33, "_parent");
if (source == null) dart.nullFailed(I[186], 558, 52, "source");
return new (stream_queue.StreamQueueTransaction$(T)).__(_parent, source);
}
newQueue() {
let queue = __t$StreamQueueOfT().new(this[S$0._splitter].split());
this[S$0._queues].add(queue);
return queue;
}
commit(queue) {
__t$StreamQueueOfT().as(queue);
if (queue == null) dart.nullFailed(I[186], 581, 30, "queue");
this[S$0._assertActive]();
if (!dart.test(this[S$0._queues].contains(queue))) {
dart.throw(new core.ArgumentError.new("Queue doesn't belong to this transaction."));
} else if (dart.test(queue[S$0._requestQueue][S$.$isNotEmpty])) {
dart.throw(new core.StateError.new("A queue with pending requests can't be committed."));
}
this[S$0._committed] = true;
for (let j = 0; j < dart.notNull(queue.eventsDispatched); j = j + 1) {
this[S$0._parent][S$0._eventQueue].removeFirst();
}
this[S$0._done$1]();
}
reject() {
this[S$0._assertActive]();
this[S$0._rejected] = true;
this[S$0._done$1]();
}
[S$0._done$1]() {
this[S$0._splitter].close();
for (let queue of this[S$0._queues]) {
queue[S$0._cancel$2]();
}
let currentRequest = this[S$0._parent][S$0._requestQueue][S$.$first];
if (stream_queue._TransactionRequest.is(currentRequest) && dart.equals(currentRequest.transaction, this)) {
this[S$0._parent][S$0._requestQueue].removeFirst();
this[S$0._parent][S$0._updateRequests]();
}
}
[S$0._assertActive]() {
if (dart.test(this[S$0._committed])) {
dart.throw(new core.StateError.new("This transaction has already been accepted."));
} else if (dart.test(this[S$0._rejected])) {
dart.throw(new core.StateError.new("This transaction has already been rejected."));
}
}
}
(StreamQueueTransaction.__ = function(_parent, source) {
if (_parent == null) dart.nullFailed(I[186], 558, 33, "_parent");
if (source == null) dart.nullFailed(I[186], 558, 52, "source");
this[S$0._queues] = T$0.LinkedHashSetOfStreamQueue().new();
this[S$0._committed] = false;
this[S$0._rejected] = false;
this[S$0._parent] = _parent;
this[S$0._splitter] = new (__t$StreamSplitterOfT()).new(source);
;
}).prototype = StreamQueueTransaction.prototype;
dart.addTypeTests(StreamQueueTransaction);
StreamQueueTransaction.prototype[_is_StreamQueueTransaction_default] = true;
dart.addTypeCaches(StreamQueueTransaction);
dart.setMethodSignature(StreamQueueTransaction, () => ({
__proto__: dart.getMethods(StreamQueueTransaction.__proto__),
newQueue: dart.fnType(stream_queue.StreamQueue$(T), []),
commit: dart.fnType(dart.void, [dart.nullable(core.Object)]),
reject: dart.fnType(dart.void, []),
[S$0._done$1]: dart.fnType(dart.void, []),
[S$0._assertActive]: dart.fnType(dart.void, [])
}));
dart.setLibraryUri(StreamQueueTransaction, I[187]);
dart.setFieldSignature(StreamQueueTransaction, () => ({
__proto__: dart.getFields(StreamQueueTransaction.__proto__),
[S$0._parent]: dart.finalFieldType(stream_queue.StreamQueue$(T)),
[S$0._splitter]: dart.finalFieldType(stream_splitter.StreamSplitter$(T)),
[S$0._queues]: dart.finalFieldType(core.Set$(stream_queue.StreamQueue)),
[S$0._committed]: dart.fieldType(core.bool),
[S$0._rejected]: dart.fieldType(core.bool)
}));
return StreamQueueTransaction;
});
stream_queue.StreamQueueTransaction = stream_queue.StreamQueueTransaction$();
dart.addTypeTests(stream_queue.StreamQueueTransaction, _is_StreamQueueTransaction_default);
const _is__EventRequest_default = Symbol('_is__EventRequest_default');
stream_queue._EventRequest$ = dart.generic(T => {
class _EventRequest extends core.Object {}
(_EventRequest.new = function() {
;
}).prototype = _EventRequest.prototype;
dart.addTypeTests(_EventRequest);
_EventRequest.prototype[_is__EventRequest_default] = true;
dart.addTypeCaches(_EventRequest);
dart.setLibraryUri(_EventRequest, I[187]);
return _EventRequest;
});
stream_queue._EventRequest = stream_queue._EventRequest$();
dart.addTypeTests(stream_queue._EventRequest, _is__EventRequest_default);
const _is__NextRequest_default = Symbol('_is__NextRequest_default');
stream_queue._NextRequest$ = dart.generic(T => {
var __t$CompleterOfT = () => (__t$CompleterOfT = dart.constFn(async.Completer$(T)))();
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _NextRequest extends core.Object {
static ['_#new#tearOff'](T) {
return new (stream_queue._NextRequest$(T)).new();
}
get future() {
return this[S$0._completer$4].future;
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 689, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 689, 49, "isDone");
if (dart.test(events.isNotEmpty)) {
events.removeFirst().complete(this[S$0._completer$4]);
return true;
}
if (dart.test(isDone)) {
this[S$0._completer$4].completeError(new core.StateError.new("No elements"), core.StackTrace.current);
return true;
}
return false;
}
}
(_NextRequest.new = function() {
this[S$0._completer$4] = __t$CompleterOfT().new();
;
}).prototype = _NextRequest.prototype;
dart.addTypeTests(_NextRequest);
_NextRequest.prototype[_is__NextRequest_default] = true;
dart.addTypeCaches(_NextRequest);
_NextRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_NextRequest, () => ({
__proto__: dart.getMethods(_NextRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_NextRequest, () => ({
__proto__: dart.getGetters(_NextRequest.__proto__),
future: async.Future$(T)
}));
dart.setLibraryUri(_NextRequest, I[187]);
dart.setFieldSignature(_NextRequest, () => ({
__proto__: dart.getFields(_NextRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(async.Completer$(T))
}));
return _NextRequest;
});
stream_queue._NextRequest = stream_queue._NextRequest$();
dart.addTypeTests(stream_queue._NextRequest, _is__NextRequest_default);
const _is__PeekRequest_default = Symbol('_is__PeekRequest_default');
stream_queue._PeekRequest$ = dart.generic(T => {
var __t$CompleterOfT = () => (__t$CompleterOfT = dart.constFn(async.Completer$(T)))();
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _PeekRequest extends core.Object {
static ['_#new#tearOff'](T) {
return new (stream_queue._PeekRequest$(T)).new();
}
get future() {
return this[S$0._completer$4].future;
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 715, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 715, 49, "isDone");
if (dart.test(events.isNotEmpty)) {
events.first.complete(this[S$0._completer$4]);
return true;
}
if (dart.test(isDone)) {
this[S$0._completer$4].completeError(new core.StateError.new("No elements"), core.StackTrace.current);
return true;
}
return false;
}
}
(_PeekRequest.new = function() {
this[S$0._completer$4] = __t$CompleterOfT().new();
;
}).prototype = _PeekRequest.prototype;
dart.addTypeTests(_PeekRequest);
_PeekRequest.prototype[_is__PeekRequest_default] = true;
dart.addTypeCaches(_PeekRequest);
_PeekRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_PeekRequest, () => ({
__proto__: dart.getMethods(_PeekRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_PeekRequest, () => ({
__proto__: dart.getGetters(_PeekRequest.__proto__),
future: async.Future$(T)
}));
dart.setLibraryUri(_PeekRequest, I[187]);
dart.setFieldSignature(_PeekRequest, () => ({
__proto__: dart.getFields(_PeekRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(async.Completer$(T))
}));
return _PeekRequest;
});
stream_queue._PeekRequest = stream_queue._PeekRequest$();
dart.addTypeTests(stream_queue._PeekRequest, _is__PeekRequest_default);
const _is__SkipRequest_default = Symbol('_is__SkipRequest_default');
stream_queue._SkipRequest$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _SkipRequest extends core.Object {
static ['_#new#tearOff'](T, _eventsToSkip) {
if (_eventsToSkip == null) dart.nullFailed(I[186], 741, 21, "_eventsToSkip");
return new (stream_queue._SkipRequest$(T)).new(_eventsToSkip);
}
get future() {
return this[S$0._completer$4].future;
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 747, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 747, 49, "isDone");
while (dart.notNull(this[S$0._eventsToSkip]) > 0) {
if (dart.test(events.isEmpty)) {
if (dart.test(isDone)) break;
return false;
}
this[S$0._eventsToSkip] = dart.notNull(this[S$0._eventsToSkip]) - 1;
let event = events.removeFirst();
if (dart.test(event.isError)) {
this[S$0._completer$4].completeError(dart.nullCheck(event.asError).error, dart.nullCheck(event.asError).stackTrace);
return true;
}
}
this[S$0._completer$4].complete(this[S$0._eventsToSkip]);
return true;
}
}
(_SkipRequest.new = function(_eventsToSkip) {
if (_eventsToSkip == null) dart.nullFailed(I[186], 741, 21, "_eventsToSkip");
this[S$0._completer$4] = T$0.CompleterOfint().new();
this[S$0._eventsToSkip] = _eventsToSkip;
;
}).prototype = _SkipRequest.prototype;
dart.addTypeTests(_SkipRequest);
_SkipRequest.prototype[_is__SkipRequest_default] = true;
dart.addTypeCaches(_SkipRequest);
_SkipRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_SkipRequest, () => ({
__proto__: dart.getMethods(_SkipRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_SkipRequest, () => ({
__proto__: dart.getGetters(_SkipRequest.__proto__),
future: async.Future$(core.int)
}));
dart.setLibraryUri(_SkipRequest, I[187]);
dart.setFieldSignature(_SkipRequest, () => ({
__proto__: dart.getFields(_SkipRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(async.Completer$(core.int)),
[S$0._eventsToSkip]: dart.fieldType(core.int)
}));
return _SkipRequest;
});
stream_queue._SkipRequest = stream_queue._SkipRequest$();
dart.addTypeTests(stream_queue._SkipRequest, _is__SkipRequest_default);
const _is__ListRequest_default = Symbol('_is__ListRequest_default');
stream_queue._ListRequest$ = dart.generic(T => {
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$CompleterOfListOfT = () => (__t$CompleterOfListOfT = dart.constFn(async.Completer$(__t$ListOfT())))();
var __t$JSArrayOfT = () => (__t$JSArrayOfT = dart.constFn(_interceptors.JSArray$(T)))();
class _ListRequest extends core.Object {
get future() {
return this[S$0._completer$4].future;
}
}
(_ListRequest.new = function(_eventsToTake) {
if (_eventsToTake == null) dart.nullFailed(I[186], 781, 21, "_eventsToTake");
this[S$0._completer$4] = __t$CompleterOfListOfT().new();
this[S$0._list$5] = __t$JSArrayOfT().of([]);
this[S$0._eventsToTake] = _eventsToTake;
;
}).prototype = _ListRequest.prototype;
dart.addTypeTests(_ListRequest);
_ListRequest.prototype[_is__ListRequest_default] = true;
dart.addTypeCaches(_ListRequest);
_ListRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setGetterSignature(_ListRequest, () => ({
__proto__: dart.getGetters(_ListRequest.__proto__),
future: async.Future$(core.List$(T))
}));
dart.setLibraryUri(_ListRequest, I[187]);
dart.setFieldSignature(_ListRequest, () => ({
__proto__: dart.getFields(_ListRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(async.Completer$(core.List$(T))),
[S$0._list$5]: dart.finalFieldType(core.List$(T)),
[S$0._eventsToTake]: dart.finalFieldType(core.int)
}));
return _ListRequest;
});
stream_queue._ListRequest = stream_queue._ListRequest$();
dart.addTypeTests(stream_queue._ListRequest, _is__ListRequest_default);
const _is__TakeRequest_default = Symbol('_is__TakeRequest_default');
stream_queue._TakeRequest$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _TakeRequest extends stream_queue._ListRequest$(T) {
static ['_#new#tearOff'](T, eventsToTake) {
if (eventsToTake == null) dart.nullFailed(I[186], 789, 20, "eventsToTake");
return new (stream_queue._TakeRequest$(T)).new(eventsToTake);
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 792, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 792, 49, "isDone");
while (dart.notNull(this[S$0._list$5][S$.$length]) < dart.notNull(this[S$0._eventsToTake])) {
if (dart.test(events.isEmpty)) {
if (dart.test(isDone)) break;
return false;
}
let event = events.removeFirst();
if (dart.test(event.isError)) {
dart.nullCheck(event.asError).complete(this[S$0._completer$4]);
return true;
}
this[S$0._list$5][S$.$add](dart.nullCheck(event.asValue).value);
}
this[S$0._completer$4].complete(this[S$0._list$5]);
return true;
}
}
(_TakeRequest.new = function(eventsToTake) {
if (eventsToTake == null) dart.nullFailed(I[186], 789, 20, "eventsToTake");
_TakeRequest.__proto__.new.call(this, eventsToTake);
;
}).prototype = _TakeRequest.prototype;
dart.addTypeTests(_TakeRequest);
_TakeRequest.prototype[_is__TakeRequest_default] = true;
dart.addTypeCaches(_TakeRequest);
dart.setMethodSignature(_TakeRequest, () => ({
__proto__: dart.getMethods(_TakeRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setLibraryUri(_TakeRequest, I[187]);
return _TakeRequest;
});
stream_queue._TakeRequest = stream_queue._TakeRequest$();
dart.addTypeTests(stream_queue._TakeRequest, _is__TakeRequest_default);
const _is__LookAheadRequest_default = Symbol('_is__LookAheadRequest_default');
stream_queue._LookAheadRequest$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _LookAheadRequest extends stream_queue._ListRequest$(T) {
static ['_#new#tearOff'](T, eventsToTake) {
if (eventsToTake == null) dart.nullFailed(I[186], 813, 25, "eventsToTake");
return new (stream_queue._LookAheadRequest$(T)).new(eventsToTake);
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 816, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 816, 49, "isDone");
while (dart.notNull(this[S$0._list$5][S$.$length]) < dart.notNull(this[S$0._eventsToTake])) {
if (events.length == this[S$0._list$5][S$.$length]) {
if (dart.test(isDone)) break;
return false;
}
let event = events.elementAt(this[S$0._list$5][S$.$length]);
if (dart.test(event.isError)) {
dart.nullCheck(event.asError).complete(this[S$0._completer$4]);
return true;
}
this[S$0._list$5][S$.$add](dart.nullCheck(event.asValue).value);
}
this[S$0._completer$4].complete(this[S$0._list$5]);
return true;
}
}
(_LookAheadRequest.new = function(eventsToTake) {
if (eventsToTake == null) dart.nullFailed(I[186], 813, 25, "eventsToTake");
_LookAheadRequest.__proto__.new.call(this, eventsToTake);
;
}).prototype = _LookAheadRequest.prototype;
dart.addTypeTests(_LookAheadRequest);
_LookAheadRequest.prototype[_is__LookAheadRequest_default] = true;
dart.addTypeCaches(_LookAheadRequest);
dart.setMethodSignature(_LookAheadRequest, () => ({
__proto__: dart.getMethods(_LookAheadRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setLibraryUri(_LookAheadRequest, I[187]);
return _LookAheadRequest;
});
stream_queue._LookAheadRequest = stream_queue._LookAheadRequest$();
dart.addTypeTests(stream_queue._LookAheadRequest, _is__LookAheadRequest_default);
const _is__CancelRequest_default = Symbol('_is__CancelRequest_default');
stream_queue._CancelRequest$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _CancelRequest extends core.Object {
static ['_#new#tearOff'](T, _streamQueue) {
if (_streamQueue == null) dart.nullFailed(I[186], 847, 23, "_streamQueue");
return new (stream_queue._CancelRequest$(T)).new(_streamQueue);
}
get future() {
return this[S$0._completer$4].future;
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 853, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 853, 49, "isDone");
if (dart.test(this[S$0._streamQueue][S$0._isDone])) {
this[S$0._completer$4].complete();
} else {
this[S$0._streamQueue][S$0._ensureListening]();
this[S$0._completer$4].complete(this[S$0._streamQueue][S$0._extractStream]().listen(null).cancel());
}
return true;
}
}
(_CancelRequest.new = function(_streamQueue) {
if (_streamQueue == null) dart.nullFailed(I[186], 847, 23, "_streamQueue");
this[S$0._completer$4] = T$.CompleterOfvoid().new();
this[S$0._streamQueue] = _streamQueue;
;
}).prototype = _CancelRequest.prototype;
dart.addTypeTests(_CancelRequest);
_CancelRequest.prototype[_is__CancelRequest_default] = true;
dart.addTypeCaches(_CancelRequest);
_CancelRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_CancelRequest, () => ({
__proto__: dart.getMethods(_CancelRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_CancelRequest, () => ({
__proto__: dart.getGetters(_CancelRequest.__proto__),
future: async.Future
}));
dart.setLibraryUri(_CancelRequest, I[187]);
dart.setFieldSignature(_CancelRequest, () => ({
__proto__: dart.getFields(_CancelRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(async.Completer$(dart.void)),
[S$0._streamQueue]: dart.finalFieldType(stream_queue.StreamQueue)
}));
return _CancelRequest;
});
stream_queue._CancelRequest = stream_queue._CancelRequest$();
dart.addTypeTests(stream_queue._CancelRequest, _is__CancelRequest_default);
const _is__RestRequest_default = Symbol('_is__RestRequest_default');
stream_queue._RestRequest$ = dart.generic(T => {
var __t$StreamCompleterOfT = () => (__t$StreamCompleterOfT = dart.constFn(stream_completer.StreamCompleter$(T)))();
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
class _RestRequest extends core.Object {
static ['_#new#tearOff'](T, _streamQueue) {
if (_streamQueue == null) dart.nullFailed(I[186], 879, 21, "_streamQueue");
return new (stream_queue._RestRequest$(T)).new(_streamQueue);
}
get stream() {
return this[S$0._completer$4].stream;
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 885, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 885, 49, "isDone");
if (dart.test(events.isEmpty)) {
if (dart.test(this[S$0._streamQueue][S$0._isDone])) {
this[S$0._completer$4].setEmpty();
} else {
this[S$0._completer$4].setSourceStream(this[S$0._streamQueue][S$0._extractStream]());
}
} else {
let controller = __t$StreamControllerOfT().new();
for (let event of events) {
event.addTo(controller);
}
controller.addStream(this[S$0._streamQueue][S$0._extractStream](), {cancelOnError: false}).whenComplete(dart.bind(controller, 'close'));
this[S$0._completer$4].setSourceStream(controller.stream);
}
return true;
}
}
(_RestRequest.new = function(_streamQueue) {
if (_streamQueue == null) dart.nullFailed(I[186], 879, 21, "_streamQueue");
this[S$0._completer$4] = new (__t$StreamCompleterOfT()).new();
this[S$0._streamQueue] = _streamQueue;
;
}).prototype = _RestRequest.prototype;
dart.addTypeTests(_RestRequest);
_RestRequest.prototype[_is__RestRequest_default] = true;
dart.addTypeCaches(_RestRequest);
_RestRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_RestRequest, () => ({
__proto__: dart.getMethods(_RestRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_RestRequest, () => ({
__proto__: dart.getGetters(_RestRequest.__proto__),
stream: async.Stream$(T)
}));
dart.setLibraryUri(_RestRequest, I[187]);
dart.setFieldSignature(_RestRequest, () => ({
__proto__: dart.getFields(_RestRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(stream_completer.StreamCompleter$(T)),
[S$0._streamQueue]: dart.finalFieldType(stream_queue.StreamQueue$(T))
}));
return _RestRequest;
});
stream_queue._RestRequest = stream_queue._RestRequest$();
dart.addTypeTests(stream_queue._RestRequest, _is__RestRequest_default);
const _is__HasNextRequest_default = Symbol('_is__HasNextRequest_default');
stream_queue._HasNextRequest$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _HasNextRequest extends core.Object {
get future() {
return this[S$0._completer$4].future;
}
update(events, isDone) {
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 920, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 920, 49, "isDone");
if (dart.test(events.isNotEmpty)) {
this[S$0._completer$4].complete(true);
return true;
}
if (dart.test(isDone)) {
this[S$0._completer$4].complete(false);
return true;
}
return false;
}
static ['_#new#tearOff'](T) {
return new (stream_queue._HasNextRequest$(T)).new();
}
}
(_HasNextRequest.new = function() {
this[S$0._completer$4] = T$0.CompleterOfbool().new();
;
}).prototype = _HasNextRequest.prototype;
dart.addTypeTests(_HasNextRequest);
_HasNextRequest.prototype[_is__HasNextRequest_default] = true;
dart.addTypeCaches(_HasNextRequest);
_HasNextRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_HasNextRequest, () => ({
__proto__: dart.getMethods(_HasNextRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_HasNextRequest, () => ({
__proto__: dart.getGetters(_HasNextRequest.__proto__),
future: async.Future$(core.bool)
}));
dart.setLibraryUri(_HasNextRequest, I[187]);
dart.setFieldSignature(_HasNextRequest, () => ({
__proto__: dart.getFields(_HasNextRequest.__proto__),
[S$0._completer$4]: dart.finalFieldType(async.Completer$(core.bool))
}));
return _HasNextRequest;
});
stream_queue._HasNextRequest = stream_queue._HasNextRequest$();
dart.addTypeTests(stream_queue._HasNextRequest, _is__HasNextRequest_default);
const _is__TransactionRequest_default = Symbol('_is__TransactionRequest_default');
stream_queue._TransactionRequest$ = dart.generic(T => {
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$StreamQueueTransactionOfT = () => (__t$StreamQueueTransactionOfT = dart.constFn(stream_queue.StreamQueueTransaction$(T)))();
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$QueueListOfResultOfT = () => (__t$QueueListOfResultOfT = dart.constFn(queue_list.QueueList$(__t$ResultOfT())))();
class _TransactionRequest extends core.Object {
get transaction() {
let t197;
return dart.test(this[S$0.___TransactionRequest_transaction_isSet]) ? (t197 = this[S$0.___TransactionRequest_transaction], t197) : dart.throw(new _internal.LateError.fieldNI("transaction"));
}
set transaction(t197) {
if (t197 == null) dart.nullFailed(I[186], 941, 40, "null");
if (dart.test(this[S$0.___TransactionRequest_transaction_isSet]))
dart.throw(new _internal.LateError.fieldAI("transaction"));
else {
this[S$0.___TransactionRequest_transaction_isSet] = true;
this[S$0.___TransactionRequest_transaction] = t197;
}
}
static ['_#new#tearOff'](T, parent) {
if (parent == null) dart.nullFailed(I[186], 949, 38, "parent");
return new (stream_queue._TransactionRequest$(T)).new(parent);
}
update(events, isDone) {
let t198;
__t$QueueListOfResultOfT().as(events);
if (events == null) dart.nullFailed(I[186], 954, 36, "events");
if (isDone == null) dart.nullFailed(I[186], 954, 49, "isDone");
while (dart.notNull(this[S$0._eventsSent]) < dart.notNull(events.length)) {
events._get((t198 = this[S$0._eventsSent], this[S$0._eventsSent] = dart.notNull(t198) + 1, t198)).addTo(this[S$0._controller$3]);
}
if (dart.test(isDone) && !dart.test(this[S$0._controller$3].isClosed)) this[S$0._controller$3].close();
return dart.test(this.transaction[S$0._committed]) || dart.test(this.transaction[S$0._rejected]);
}
}
(_TransactionRequest.new = function(parent) {
if (parent == null) dart.nullFailed(I[186], 949, 38, "parent");
this[S$0.___TransactionRequest_transaction] = null;
this[S$0.___TransactionRequest_transaction_isSet] = false;
this[S$0._controller$3] = __t$StreamControllerOfT().new({sync: true});
this[S$0._eventsSent] = 0;
this.transaction = new (__t$StreamQueueTransactionOfT()).__(parent, this[S$0._controller$3].stream);
}).prototype = _TransactionRequest.prototype;
dart.addTypeTests(_TransactionRequest);
_TransactionRequest.prototype[_is__TransactionRequest_default] = true;
dart.addTypeCaches(_TransactionRequest);
_TransactionRequest[dart.implements] = () => [stream_queue._EventRequest$(T)];
dart.setMethodSignature(_TransactionRequest, () => ({
__proto__: dart.getMethods(_TransactionRequest.__proto__),
update: dart.fnType(core.bool, [dart.nullable(core.Object), core.bool])
}));
dart.setGetterSignature(_TransactionRequest, () => ({
__proto__: dart.getGetters(_TransactionRequest.__proto__),
transaction: stream_queue.StreamQueueTransaction$(T)
}));
dart.setSetterSignature(_TransactionRequest, () => ({
__proto__: dart.getSetters(_TransactionRequest.__proto__),
transaction: stream_queue.StreamQueueTransaction$(T)
}));
dart.setLibraryUri(_TransactionRequest, I[187]);
dart.setFieldSignature(_TransactionRequest, () => ({
__proto__: dart.getFields(_TransactionRequest.__proto__),
[S$0.___TransactionRequest_transaction]: dart.fieldType(dart.nullable(stream_queue.StreamQueueTransaction$(T))),
[S$0.___TransactionRequest_transaction_isSet]: dart.fieldType(core.bool),
[S$0._controller$3]: dart.finalFieldType(async.StreamController$(T)),
[S$0._eventsSent]: dart.fieldType(core.int)
}));
return _TransactionRequest;
});
stream_queue._TransactionRequest = stream_queue._TransactionRequest$();
dart.addTypeTests(stream_queue._TransactionRequest, _is__TransactionRequest_default);
const _is_StreamSinkCompleter_default = Symbol('_is_StreamSinkCompleter_default');
stream_sink_completer.StreamSinkCompleter$ = dart.generic(T => {
var __t$_CompleterSinkOfT = () => (__t$_CompleterSinkOfT = dart.constFn(stream_sink_completer._CompleterSink$(T)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
var __t$NullStreamSinkOfT = () => (__t$NullStreamSinkOfT = dart.constFn(null_stream_sink.NullStreamSink$(T)))();
class StreamSinkCompleter extends core.Object {
get sink() {
return this[S$0.sink];
}
set sink(value) {
super.sink = value;
}
get [S$0._sink$4]() {
return __t$_CompleterSinkOfT().as(this.sink);
}
static fromFuture(T, sinkFuture) {
if (sinkFuture == null) dart.nullFailed(I[188], 39, 60, "sinkFuture");
let completer = new (stream_sink_completer.StreamSinkCompleter$(T)).new();
sinkFuture.then(dart.void, dart.fnType(dart.void, [async.StreamSink$(T)]).as(dart.bind(completer, 'setDestinationSink')), {onError: dart.bind(completer, 'setError')});
return completer.sink;
}
setDestinationSink(destinationSink) {
__t$StreamSinkOfT().as(destinationSink);
if (destinationSink == null) dart.nullFailed(I[188], 60, 41, "destinationSink");
if (this[S$0._sink$4][S$0._destinationSink] != null) {
dart.throw(new core.StateError.new("Destination sink already set"));
}
this[S$0._sink$4][S$0._setDestinationSink](destinationSink);
}
setError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[188], 73, 24, "error");
this.setDestinationSink(new (__t$NullStreamSinkOfT()).error(error, stackTrace));
}
static ['_#new#tearOff'](T) {
return new (stream_sink_completer.StreamSinkCompleter$(T)).new();
}
}
(StreamSinkCompleter.new = function() {
this[S$0.sink] = new (__t$_CompleterSinkOfT()).new();
;
}).prototype = StreamSinkCompleter.prototype;
dart.addTypeTests(StreamSinkCompleter);
StreamSinkCompleter.prototype[_is_StreamSinkCompleter_default] = true;
dart.addTypeCaches(StreamSinkCompleter);
dart.setMethodSignature(StreamSinkCompleter, () => ({
__proto__: dart.getMethods(StreamSinkCompleter.__proto__),
setDestinationSink: dart.fnType(dart.void, [dart.nullable(core.Object)]),
setError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)])
}));
dart.setStaticMethodSignature(StreamSinkCompleter, () => ['fromFuture']);
dart.setGetterSignature(StreamSinkCompleter, () => ({
__proto__: dart.getGetters(StreamSinkCompleter.__proto__),
[S$0._sink$4]: stream_sink_completer._CompleterSink$(T)
}));
dart.setLibraryUri(StreamSinkCompleter, I[189]);
dart.setFieldSignature(StreamSinkCompleter, () => ({
__proto__: dart.getFields(StreamSinkCompleter.__proto__),
sink: dart.finalFieldType(async.StreamSink$(T))
}));
return StreamSinkCompleter;
});
stream_sink_completer.StreamSinkCompleter = stream_sink_completer.StreamSinkCompleter$();
dart.addTypeTests(stream_sink_completer.StreamSinkCompleter, _is_StreamSinkCompleter_default);
const _is__CompleterSink_default = Symbol('_is__CompleterSink_default');
stream_sink_completer._CompleterSink$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
class _CompleterSink extends core.Object {
get [S$0._canSendDirectly]() {
return this[S$0._controller$4] == null && this[S$0._destinationSink] != null;
}
get done() {
if (this[S$0._doneCompleter] != null) return dart.nullCheck(this[S$0._doneCompleter]).future;
if (this[S$0._destinationSink] == null) {
this[S$0._doneCompleter] = async.Completer.sync();
return dart.nullCheck(this[S$0._doneCompleter]).future;
}
return dart.nullCheck(this[S$0._destinationSink]).done;
}
add(event) {
T.as(event);
if (dart.test(this[S$0._canSendDirectly])) {
dart.nullCheck(this[S$0._destinationSink]).add(event);
} else {
this[S$0._ensureController$2]().add(event);
}
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[188], 121, 17, "error");
if (dart.test(this[S$0._canSendDirectly])) {
dart.nullCheck(this[S$0._destinationSink]).addError(error, stackTrace);
} else {
this[S$0._ensureController$2]().addError(error, stackTrace);
}
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[188], 130, 30, "stream");
if (dart.test(this[S$0._canSendDirectly])) return dart.nullCheck(this[S$0._destinationSink]).addStream(stream);
return this[S$0._ensureController$2]().addStream(stream, {cancelOnError: false});
}
close() {
if (dart.test(this[S$0._canSendDirectly])) {
dart.nullCheck(this[S$0._destinationSink]).close();
} else {
this[S$0._ensureController$2]().close();
}
return this.done;
}
[S$0._ensureController$2]() {
let t198;
t198 = this[S$0._controller$4];
return t198 == null ? this[S$0._controller$4] = __t$StreamControllerOfT().new({sync: true}) : t198;
}
[S$0._setDestinationSink](sink) {
__t$StreamSinkOfT().as(sink);
if (sink == null) dart.nullFailed(I[188], 157, 42, "sink");
if (!(this[S$0._destinationSink] == null)) dart.assertFailed(null, I[188], 158, 12, "_destinationSink == null");
this[S$0._destinationSink] = sink;
if (this[S$0._controller$4] != null) {
sink.addStream(dart.nullCheck(this[S$0._controller$4]).stream).whenComplete(dart.bind(sink, 'close')).catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
}
if (this[S$0._doneCompleter] != null) {
dart.nullCheck(this[S$0._doneCompleter]).complete(sink.done);
}
}
static ['_#new#tearOff'](T) {
return new (stream_sink_completer._CompleterSink$(T)).new();
}
}
(_CompleterSink.new = function() {
this[S$0._controller$4] = null;
this[S$0._doneCompleter] = null;
this[S$0._destinationSink] = null;
;
}).prototype = _CompleterSink.prototype;
dart.addTypeTests(_CompleterSink);
_CompleterSink.prototype[_is__CompleterSink_default] = true;
dart.addTypeCaches(_CompleterSink);
_CompleterSink[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(_CompleterSink, () => ({
__proto__: dart.getMethods(_CompleterSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, []),
[S$0._ensureController$2]: dart.fnType(async.StreamController$(T), []),
[S$0._setDestinationSink]: dart.fnType(dart.void, [dart.nullable(core.Object)])
}));
dart.setGetterSignature(_CompleterSink, () => ({
__proto__: dart.getGetters(_CompleterSink.__proto__),
[S$0._canSendDirectly]: core.bool,
done: async.Future
}));
dart.setLibraryUri(_CompleterSink, I[189]);
dart.setFieldSignature(_CompleterSink, () => ({
__proto__: dart.getFields(_CompleterSink.__proto__),
[S$0._controller$4]: dart.fieldType(dart.nullable(async.StreamController$(T))),
[S$0._doneCompleter]: dart.fieldType(dart.nullable(async.Completer)),
[S$0._destinationSink]: dart.fieldType(dart.nullable(async.StreamSink$(T)))
}));
return _CompleterSink;
});
stream_sink_completer._CompleterSink = stream_sink_completer._CompleterSink$();
dart.addTypeTests(stream_sink_completer._CompleterSink, _is__CompleterSink_default);
stream_sink_extensions['StreamSinkExtensions|transform'] = function StreamSinkExtensions$124transform(T, S, $this, transformer) {
if ($this == null) dart.nullFailed(I[190], 13, 17, "#this");
if (transformer == null) dart.nullFailed(I[190], 13, 58, "transformer");
return transformer.bind($this);
};
stream_sink_extensions['StreamSinkExtensions|get#transform'] = function StreamSinkExtensions$124get$35transform(T, $this) {
if ($this == null) dart.nullFailed(I[190], 13, 17, "#this");
return dart.fn((S, transformer) => {
if (transformer == null) dart.nullFailed(I[190], 13, 58, "transformer");
return stream_sink_extensions['StreamSinkExtensions|transform'](T, S, $this, transformer);
}, dart.gFnType(S => {
var __t$StreamSinkOfS = () => (__t$StreamSinkOfS = dart.constFn(async.StreamSink$(S)))();
return [__t$StreamSinkOfS(), [stream_sink_transformer.StreamSinkTransformer$(S, T)]];
}, S => {
var __t$StreamSinkOfS = () => (__t$StreamSinkOfS = dart.constFn(async.StreamSink$(S)))();
return [T$.ObjectN()];
}));
};
stream_sink_extensions['StreamSinkExtensions|rejectErrors'] = function StreamSinkExtensions$124rejectErrors(T, $this) {
if ($this == null) dart.nullFailed(I[190], 21, 17, "#this");
return new (reject_errors.RejectErrorsSink$(T)).new($this);
};
stream_sink_extensions['StreamSinkExtensions|get#rejectErrors'] = function StreamSinkExtensions$124get$35rejectErrors(T, $this) {
if ($this == null) dart.nullFailed(I[190], 21, 17, "#this");
return dart.fn(() => stream_sink_extensions['StreamSinkExtensions|rejectErrors'](T, $this), dart.fnType(async.StreamSink$(T), []));
};
const _is_StreamSinkTransformer_default = Symbol('_is_StreamSinkTransformer_default');
stream_sink_transformer.StreamSinkTransformer$ = dart.generic((S, T) => {
class StreamSinkTransformer extends core.Object {
static ['_#fromStreamTransformer#tearOff'](S, T, transformer) {
if (transformer == null) dart.nullFailed(I[191], 27, 31, "transformer");
return new (stream_transformer_wrapper.StreamTransformerWrapper$(S, T)).new(transformer);
}
static fromHandlers(opts) {
let handleData = opts && 'handleData' in opts ? opts.handleData : null;
let handleError = opts && 'handleError' in opts ? opts.handleError : null;
let handleDone = opts && 'handleDone' in opts ? opts.handleDone : null;
return new (handler_transformer.HandlerTransformer$(S, T)).new(handleData, handleError, handleDone);
}
static ['_#fromHandlers#tearOff'](S, T, opts) {
let handleData = opts && 'handleData' in opts ? opts.handleData : null;
let handleError = opts && 'handleError' in opts ? opts.handleError : null;
let handleDone = opts && 'handleDone' in opts ? opts.handleDone : null;
return stream_sink_transformer.StreamSinkTransformer$(S, T).fromHandlers({handleData: handleData, handleError: handleError, handleDone: handleDone});
}
static typed(S, T, transformer) {
if (transformer == null) dart.nullFailed(I[191], 59, 33, "transformer");
return stream_sink_transformer.StreamSinkTransformer$(S, T).is(transformer) ? transformer : new (typed.TypeSafeStreamSinkTransformer$(S, T)).new(transformer);
}
}
(StreamSinkTransformer[dart.mixinNew] = function() {
}).prototype = StreamSinkTransformer.prototype;
dart.addTypeTests(StreamSinkTransformer);
StreamSinkTransformer.prototype[_is_StreamSinkTransformer_default] = true;
dart.addTypeCaches(StreamSinkTransformer);
dart.setStaticMethodSignature(StreamSinkTransformer, () => ['fromStreamTransformer', 'fromHandlers', 'typed']);
dart.setLibraryUri(StreamSinkTransformer, I[192]);
dart.setStaticFieldSignature(StreamSinkTransformer, () => ['_redirecting#']);
return StreamSinkTransformer;
});
stream_sink_transformer.StreamSinkTransformer = stream_sink_transformer.StreamSinkTransformer$();
dart.addTypeTests(stream_sink_transformer.StreamSinkTransformer, _is_StreamSinkTransformer_default);
const _is_StreamSplitter_default = Symbol('_is_StreamSplitter_default');
stream_splitter.StreamSplitter$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$JSArrayOfResultOfT = () => (__t$JSArrayOfResultOfT = dart.constFn(_interceptors.JSArray$(__t$ResultOfT())))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$LinkedHashSetOfStreamControllerOfT = () => (__t$LinkedHashSetOfStreamControllerOfT = dart.constFn(collection.LinkedHashSet$(__t$StreamControllerOfT())))();
var __t$StreamControllerOfTTobool = () => (__t$StreamControllerOfTTobool = dart.constFn(dart.fnType(core.bool, [__t$StreamControllerOfT()])))();
var __t$ValueResultOfT = () => (__t$ValueResultOfT = dart.constFn(value$.ValueResult$(T)))();
class StreamSplitter extends core.Object {
static splitFrom(T, stream, count = null) {
if (stream == null) dart.nullFailed(I[193], 60, 49, "stream");
count == null ? count = 2 : null;
let splitter = new (stream_splitter.StreamSplitter$(T)).new(stream);
let streams = core.List$(async.Stream$(T)).generate(count, dart.fn(_ => {
if (_ == null) dart.nullFailed(I[193], 63, 52, "_");
return splitter.split();
}, dart.fnType(async.Stream$(T), [core.int])));
splitter.close();
return streams;
}
static ['_#new#tearOff'](T, _stream) {
if (_stream == null) dart.nullFailed(I[193], 68, 23, "_stream");
return new (stream_splitter.StreamSplitter$(T)).new(_stream);
}
split() {
if (dart.test(this[S$0._isClosed$1])) {
dart.throw(new core.StateError.new("Can't call split() on a closed StreamSplitter."));
}
let controller = __t$StreamControllerOfT().new({onListen: dart.bind(this, S$0._onListen$2), onPause: dart.bind(this, S$0._onPause$2), onResume: dart.bind(this, S$0._onResume$2)});
controller.onCancel = dart.fn(() => this[S$0._onCancel$2](controller), T$.VoidTovoid());
for (let result of this[S$0._buffer]) {
result.addTo(controller);
}
if (dart.test(this[S$0._isDone$1])) {
this[S$0._closeGroup].add(controller.close());
} else {
this[S$0._controllers$1].add(controller);
}
return controller.stream;
}
close() {
if (dart.test(this[S$0._isClosed$1])) return this[S$0._closeGroup].future;
this[S$0._isClosed$1] = true;
this[S$0._buffer][S$.$clear]();
if (dart.test(this[S$0._controllers$1][S$.$isEmpty])) this[S$0._cancelSubscription]();
return this[S$0._closeGroup].future;
}
[S$0._cancelSubscription]() {
if (!dart.test(this[S$0._controllers$1][S$.$isEmpty])) dart.assertFailed(null, I[193], 125, 12, "_controllers.isEmpty");
if (!dart.test(this[S$0._isClosed$1])) dart.assertFailed(null, I[193], 126, 12, "_isClosed");
let future = null;
if (this[S$0._subscription$2] != null) future = dart.nullCheck(this[S$0._subscription$2]).cancel();
if (future != null) this[S$0._closeGroup].add(future);
this[S$0._closeGroup].close();
}
[S$0._onListen$2]() {
if (dart.test(this[S$0._isDone$1])) return;
if (this[S$0._subscription$2] != null) {
dart.nullCheck(this[S$0._subscription$2]).resume();
} else {
this[S$0._subscription$2] = this[S$0._stream$1].listen(dart.bind(this, S$0._onData), {onError: dart.bind(this, S$0._onError), onDone: dart.bind(this, S$0._onDone)});
}
}
[S$0._onPause$2]() {
if (!dart.test(this[S$0._controllers$1][S$.$every](dart.fn(controller => {
if (controller == null) dart.nullFailed(I[193], 154, 30, "controller");
return controller.isPaused;
}, __t$StreamControllerOfTTobool())))) return;
dart.nullCheck(this[S$0._subscription$2]).pause();
}
[S$0._onResume$2]() {
dart.nullCheck(this[S$0._subscription$2]).resume();
}
[S$0._onCancel$2](controller) {
if (controller == null) dart.nullFailed(I[193], 171, 35, "controller");
this[S$0._controllers$1].remove(controller);
if (dart.test(this[S$0._controllers$1][S$.$isNotEmpty])) return;
if (dart.test(this[S$0._isClosed$1])) {
this[S$0._cancelSubscription]();
} else {
dart.nullCheck(this[S$0._subscription$2]).pause();
}
}
[S$0._onData](data) {
T.as(data);
if (!dart.test(this[S$0._isClosed$1])) this[S$0._buffer][S$.$add](new (__t$ValueResultOfT()).new(data));
for (let controller of this[S$0._controllers$1]) {
controller.add(data);
}
}
[S$0._onError](error, stackTrace) {
if (error == null) dart.nullFailed(I[193], 193, 24, "error");
if (stackTrace == null) dart.nullFailed(I[193], 193, 42, "stackTrace");
if (!dart.test(this[S$0._isClosed$1])) this[S$0._buffer][S$.$add](__t$ResultOfT().error(error, stackTrace));
for (let controller of this[S$0._controllers$1]) {
controller.addError(error, stackTrace);
}
}
[S$0._onDone]() {
this[S$0._isDone$1] = true;
for (let controller of this[S$0._controllers$1]) {
this[S$0._closeGroup].add(controller.close());
}
}
}
(StreamSplitter.new = function(_stream) {
if (_stream == null) dart.nullFailed(I[193], 68, 23, "_stream");
this[S$0._subscription$2] = null;
this[S$0._buffer] = __t$JSArrayOfResultOfT().of([]);
this[S$0._controllers$1] = __t$LinkedHashSetOfStreamControllerOfT().new();
this[S$0._closeGroup] = new future_group.FutureGroup.new();
this[S$0._isDone$1] = false;
this[S$0._isClosed$1] = false;
this[S$0._stream$1] = _stream;
;
}).prototype = StreamSplitter.prototype;
dart.addTypeTests(StreamSplitter);
StreamSplitter.prototype[_is_StreamSplitter_default] = true;
dart.addTypeCaches(StreamSplitter);
dart.setMethodSignature(StreamSplitter, () => ({
__proto__: dart.getMethods(StreamSplitter.__proto__),
split: dart.fnType(async.Stream$(T), []),
close: dart.fnType(async.Future, []),
[S$0._cancelSubscription]: dart.fnType(dart.void, []),
[S$0._onListen$2]: dart.fnType(dart.void, []),
[S$0._onPause$2]: dart.fnType(dart.void, []),
[S$0._onResume$2]: dart.fnType(dart.void, []),
[S$0._onCancel$2]: dart.fnType(dart.void, [async.StreamController]),
[S$0._onData]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._onError]: dart.fnType(dart.void, [core.Object, core.StackTrace]),
[S$0._onDone]: dart.fnType(dart.void, [])
}));
dart.setStaticMethodSignature(StreamSplitter, () => ['splitFrom']);
dart.setLibraryUri(StreamSplitter, I[194]);
dart.setFieldSignature(StreamSplitter, () => ({
__proto__: dart.getFields(StreamSplitter.__proto__),
[S$0._stream$1]: dart.finalFieldType(async.Stream$(T)),
[S$0._subscription$2]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._buffer]: dart.finalFieldType(core.List$(result$.Result$(T))),
[S$0._controllers$1]: dart.finalFieldType(core.Set$(async.StreamController$(T))),
[S$0._closeGroup]: dart.finalFieldType(future_group.FutureGroup),
[S$0._isDone$1]: dart.fieldType(core.bool),
[S$0._isClosed$1]: dart.fieldType(core.bool)
}));
return StreamSplitter;
});
stream_splitter.StreamSplitter = stream_splitter.StreamSplitter$();
dart.addTypeTests(stream_splitter.StreamSplitter, _is_StreamSplitter_default);
const _is__TransformedSubscription_default = Symbol('_is__TransformedSubscription_default');
stream_subscription_transformer._TransformedSubscription$ = dart.generic(T => {
class _TransformedSubscription extends core.Object {
get isPaused() {
let t202, t202$;
t202$ = (t202 = this[S$0._inner$2], t202 == null ? null : t202.isPaused);
return t202$ == null ? false : t202$;
}
static ['_#new#tearOff'](T, _inner, _handleCancel, _handlePause, _handleResume) {
if (_handleCancel == null) dart.nullFailed(I[195], 68, 25, "_handleCancel");
if (_handlePause == null) dart.nullFailed(I[195], 68, 45, "_handlePause");
if (_handleResume == null) dart.nullFailed(I[195], 68, 64, "_handleResume");
return new (stream_subscription_transformer._TransformedSubscription$(T)).new(_inner, _handleCancel, _handlePause, _handleResume);
}
onData(handleData) {
let t202;
t202 = this[S$0._inner$2];
t202 == null ? null : t202.onData(handleData);
}
onError(handleError) {
let t202;
t202 = this[S$0._inner$2];
t202 == null ? null : t202.onError(handleError);
}
onDone(handleDone) {
let t202;
t202 = this[S$0._inner$2];
t202 == null ? null : t202.onDone(handleDone);
}
cancel() {
return this[S$0._cancelMemoizer].runOnce(dart.fn(() => {
let t202;
let inner = dart.nullCheck(this[S$0._inner$2]);
inner.onData(null);
inner.onDone(null);
inner.onError(dart.fn((_, __) => {
}, T$.dynamicAnddynamicToNull()));
this[S$0._inner$2] = null;
t202 = inner;
return this[S$0._handleCancel](t202);
}, T$.VoidToFuture()));
}
pause(resumeFuture = null) {
let t202;
if (dart.test(this[S$0._cancelMemoizer].hasRun)) return;
if (resumeFuture != null) resumeFuture.whenComplete(dart.bind(this, 'resume'));
t202 = dart.nullCheck(this[S$0._inner$2]);
this[S$0._handlePause](t202);
}
resume() {
let t202;
if (dart.test(this[S$0._cancelMemoizer].hasRun)) return;
t202 = dart.nullCheck(this[S$0._inner$2]);
this[S$0._handleResume](t202);
}
asFuture(E, futureValue = null) {
let t202, t202$;
t202$ = (t202 = this[S$0._inner$2], t202 == null ? null : t202.asFuture(E, futureValue));
return t202$ == null ? async.Completer$(E).new().future : t202$;
}
}
(_TransformedSubscription.new = function(_inner, _handleCancel, _handlePause, _handleResume) {
if (_handleCancel == null) dart.nullFailed(I[195], 68, 25, "_handleCancel");
if (_handlePause == null) dart.nullFailed(I[195], 68, 45, "_handlePause");
if (_handleResume == null) dart.nullFailed(I[195], 68, 64, "_handleResume");
this[S$0._cancelMemoizer] = new async_memoizer.AsyncMemoizer.new();
this[S$0._inner$2] = _inner;
this[S$0._handleCancel] = _handleCancel;
this[S$0._handlePause] = _handlePause;
this[S$0._handleResume] = _handleResume;
;
}).prototype = _TransformedSubscription.prototype;
_TransformedSubscription.prototype[dart.isStreamSubscription] = true;
dart.addTypeTests(_TransformedSubscription);
_TransformedSubscription.prototype[_is__TransformedSubscription_default] = true;
dart.addTypeCaches(_TransformedSubscription);
_TransformedSubscription[dart.implements] = () => [async.StreamSubscription$(T)];
dart.setMethodSignature(_TransformedSubscription, () => ({
__proto__: dart.getMethods(_TransformedSubscription.__proto__),
onData: dart.fnType(dart.void, [dart.nullable(dart.fnType(dart.void, [T]))]),
onError: dart.fnType(dart.void, [dart.nullable(core.Function)]),
onDone: dart.fnType(dart.void, [dart.nullable(dart.fnType(dart.void, []))]),
cancel: dart.fnType(async.Future, []),
pause: dart.fnType(dart.void, [], [dart.nullable(async.Future)]),
resume: dart.fnType(dart.void, []),
asFuture: dart.gFnType(E => [async.Future$(E), [], [dart.nullable(E)]], E => [dart.nullable(core.Object)])
}));
dart.setGetterSignature(_TransformedSubscription, () => ({
__proto__: dart.getGetters(_TransformedSubscription.__proto__),
isPaused: core.bool
}));
dart.setLibraryUri(_TransformedSubscription, I[196]);
dart.setFieldSignature(_TransformedSubscription, () => ({
__proto__: dart.getFields(_TransformedSubscription.__proto__),
[S$0._inner$2]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._handleCancel]: dart.finalFieldType(dart.fnType(async.Future, [async.StreamSubscription$(T)])),
[S$0._handlePause]: dart.finalFieldType(dart.fnType(dart.void, [async.StreamSubscription$(T)])),
[S$0._handleResume]: dart.finalFieldType(dart.fnType(dart.void, [async.StreamSubscription$(T)])),
[S$0._cancelMemoizer]: dart.finalFieldType(async_memoizer.AsyncMemoizer)
}));
return _TransformedSubscription;
});
stream_subscription_transformer._TransformedSubscription = stream_subscription_transformer._TransformedSubscription$();
dart.addTypeTests(stream_subscription_transformer._TransformedSubscription, _is__TransformedSubscription_default);
stream_subscription_transformer.subscriptionTransformer = function subscriptionTransformer(T, opts) {
let handleCancel = opts && 'handleCancel' in opts ? opts.handleCancel : null;
let handlePause = opts && 'handlePause' in opts ? opts.handlePause : null;
let handleResume = opts && 'handleResume' in opts ? opts.handleResume : null;
return new (async._StreamSubscriptionTransformer$(T, T)).new(dart.fn((stream, cancelOnError) => {
let t202, t202$, t202$0;
if (stream == null) dart.nullFailed(I[195], 34, 29, "stream");
if (cancelOnError == null) dart.nullFailed(I[195], 34, 37, "cancelOnError");
return new (stream_subscription_transformer._TransformedSubscription$(T)).new(stream.listen(null, {cancelOnError: cancelOnError}), (t202 = handleCancel, t202 == null ? dart.fn(inner => {
if (inner == null) dart.nullFailed(I[195], 37, 26, "inner");
return inner.cancel();
}, dart.fnType(T$.FutureOfvoid(), [async.StreamSubscription$(T)])) : t202), (t202$ = handlePause, t202$ == null ? dart.fn(inner => {
if (inner == null) dart.nullFailed(I[195], 39, 14, "inner");
inner.pause();
}, dart.fnType(dart.void, [async.StreamSubscription$(T)])) : t202$), (t202$0 = handleResume, t202$0 == null ? dart.fn(inner => {
if (inner == null) dart.nullFailed(I[195], 43, 14, "inner");
inner.resume();
}, dart.fnType(dart.void, [async.StreamSubscription$(T)])) : t202$0));
}, dart.fnType(stream_subscription_transformer._TransformedSubscription$(T), [async.Stream$(T), core.bool])));
};
const _is_StreamZip_default = Symbol('_is_StreamZip_default');
stream_zip.StreamZip$ = dart.generic(T => {
var __t$StreamSubscriptionOfT = () => (__t$StreamSubscriptionOfT = dart.constFn(async.StreamSubscription$(T)))();
var __t$JSArrayOfStreamSubscriptionOfT = () => (__t$JSArrayOfStreamSubscriptionOfT = dart.constFn(_interceptors.JSArray$(__t$StreamSubscriptionOfT())))();
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$StreamControllerOfListOfT = () => (__t$StreamControllerOfListOfT = dart.constFn(async.StreamController$(__t$ListOfT())))();
var __t$VoidToStreamControllerOfListOfT = () => (__t$VoidToStreamControllerOfListOfT = dart.constFn(dart.fnType(__t$StreamControllerOfListOfT(), [])))();
var __t$StreamControllerOfListOfTTodynamic = () => (__t$StreamControllerOfListOfTTodynamic = dart.constFn(dart.fnType(dart.dynamic, [__t$StreamControllerOfListOfT()])))();
var __t$TN = () => (__t$TN = dart.constFn(dart.nullable(T)))();
var __t$ListOfTN = () => (__t$ListOfTN = dart.constFn(core.List$(__t$TN())))();
var __t$VoidToListOfTN = () => (__t$VoidToListOfTN = dart.constFn(dart.fnType(__t$ListOfTN(), [])))();
var __t$ListOfTNTodynamic = () => (__t$ListOfTNTodynamic = dart.constFn(dart.fnType(dart.dynamic, [__t$ListOfTN()])))();
var __t$intAndTTovoid = () => (__t$intAndTTovoid = dart.constFn(dart.fnType(dart.void, [core.int, T])))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class StreamZip extends async.Stream$(core.List$(T)) {
static ['_#new#tearOff'](T, streams) {
if (streams == null) dart.nullFailed(I[197], 18, 33, "streams");
return new (stream_zip.StreamZip$(T)).new(streams);
}
listen(onData, opts) {
let onError = opts && 'onError' in opts ? opts.onError : null;
let onDone = opts && 'onDone' in opts ? opts.onDone : null;
let cancelOnError = opts && 'cancelOnError' in opts ? opts.cancelOnError : null;
cancelOnError = true === cancelOnError;
let subscriptions = __t$JSArrayOfStreamSubscriptionOfT().of([]);
let controller = null;
let controller$35isSet = false;
function controller$35get() {
return controller$35isSet ? controller : dart.throw(new _internal.LateError.localNI("controller"));
}
dart.fn(controller$35get, __t$VoidToStreamControllerOfListOfT());
function controller$35set(t205) {
if (t205 == null) dart.nullFailed(I[197], 25, 36, "null");
controller$35isSet = true;
return controller = t205;
}
dart.fn(controller$35set, __t$StreamControllerOfListOfTTodynamic());
let current = null;
let current$35isSet = false;
function current$35get() {
return current$35isSet ? current : dart.throw(new _internal.LateError.localNI("current"));
}
dart.fn(current$35get, __t$VoidToListOfTN());
function current$35set(t210) {
if (t210 == null) dart.nullFailed(I[197], 26, 19, "null");
current$35isSet = true;
return current = t210;
}
dart.fn(current$35set, __t$ListOfTNTodynamic());
let dataCount = 0;
function handleData(index, data) {
if (index == null) dart.nullFailed(I[197], 30, 25, "index");
current$35get()[S$.$_set](index, data);
dataCount = dataCount + 1;
if (dataCount === subscriptions[S$.$length]) {
let data = __t$ListOfT().from(current$35get());
current$35set(__t$ListOfTN().filled(subscriptions[S$.$length], null));
dataCount = 0;
for (let i = 0; i < dart.notNull(subscriptions[S$.$length]); i = i + 1) {
if (i !== index) subscriptions[S$.$_get](i).resume();
}
controller$35get().add(data);
} else {
subscriptions[S$.$_get](index).pause();
}
}
dart.fn(handleData, __t$intAndTTovoid());
function handleError(error, stackTrace) {
if (error == null) dart.nullFailed(I[197], 49, 29, "error");
if (stackTrace == null) dart.nullFailed(I[197], 49, 47, "stackTrace");
controller$35get().addError(error, stackTrace);
}
dart.fn(handleError, T$0.ObjectAndStackTraceTovoid());
function handleErrorCancel(error, stackTrace) {
if (error == null) dart.nullFailed(I[197], 57, 35, "error");
if (stackTrace == null) dart.nullFailed(I[197], 57, 53, "stackTrace");
for (let i = 0; i < dart.notNull(subscriptions[S$.$length]); i = i + 1) {
subscriptions[S$.$_get](i).cancel();
}
controller$35get().addError(error, stackTrace);
}
dart.fn(handleErrorCancel, T$0.ObjectAndStackTraceTovoid());
function handleDone() {
for (let i = 0; i < dart.notNull(subscriptions[S$.$length]); i = i + 1) {
subscriptions[S$.$_get](i).cancel();
}
controller$35get().close();
}
dart.fn(handleDone, T$.VoidTovoid());
try {
for (let stream of this[S$0._streams]) {
let index = subscriptions[S$.$length];
subscriptions[S$.$add](stream.listen(dart.fn(data => {
handleData(index, data);
}, __t$TTovoid()), {onError: dart.test(cancelOnError) ? handleError : handleErrorCancel, onDone: handleDone, cancelOnError: cancelOnError}));
}
} catch (e$) {
let e = dart.getThrown(e$);
if (core.Object.is(e)) {
for (let i = dart.notNull(subscriptions[S$.$length]) - 1; i >= 0; i = i - 1) {
subscriptions[S$.$_get](i).cancel();
}
dart.rethrow(e$);
} else
throw e$;
}
current$35set(__t$ListOfTN().filled(subscriptions[S$.$length], null));
controller$35set(__t$StreamControllerOfListOfT().new({onPause: dart.fn(() => {
for (let i = 0; i < dart.notNull(subscriptions[S$.$length]); i = i + 1) {
subscriptions[S$.$_get](i).pause();
}
}, T$.VoidTovoid()), onResume: dart.fn(() => {
for (let i = 0; i < dart.notNull(subscriptions[S$.$length]); i = i + 1) {
subscriptions[S$.$_get](i).resume();
}
}, T$.VoidTovoid()), onCancel: dart.fn(() => {
for (let i = 0; i < dart.notNull(subscriptions[S$.$length]); i = i + 1) {
subscriptions[S$.$_get](i).cancel();
}
}, T$.VoidToNull())}));
if (dart.test(subscriptions[S$.$isEmpty])) {
controller$35get().close();
}
return controller$35get().stream.listen(onData, {onError: onError, onDone: onDone, cancelOnError: cancelOnError});
}
}
(StreamZip.new = function(streams) {
if (streams == null) dart.nullFailed(I[197], 18, 33, "streams");
this[S$0._streams] = streams;
StreamZip.__proto__.new.call(this);
;
}).prototype = StreamZip.prototype;
dart.addTypeTests(StreamZip);
StreamZip.prototype[_is_StreamZip_default] = true;
dart.addTypeCaches(StreamZip);
dart.setMethodSignature(StreamZip, () => ({
__proto__: dart.getMethods(StreamZip.__proto__),
listen: dart.fnType(async.StreamSubscription$(core.List$(T)), [dart.nullable(dart.fnType(dart.void, [core.List$(T)]))], {cancelOnError: dart.nullable(core.bool), onDone: dart.nullable(dart.fnType(dart.void, [])), onError: dart.nullable(core.Function)}, {})
}));
dart.setLibraryUri(StreamZip, I[198]);
dart.setFieldSignature(StreamZip, () => ({
__proto__: dart.getFields(StreamZip.__proto__),
[S$0._streams]: dart.finalFieldType(core.Iterable$(async.Stream$(T)))
}));
return StreamZip;
});
stream_zip.StreamZip = stream_zip.StreamZip$();
dart.addTypeTests(stream_zip.StreamZip, _is_StreamZip_default);
const _is_SubscriptionStream_default = Symbol('_is_SubscriptionStream_default');
subscription_stream.SubscriptionStream$ = dart.generic(T => {
var __t$_CancelOnErrorSubscriptionWrapperOfT = () => (__t$_CancelOnErrorSubscriptionWrapperOfT = dart.constFn(subscription_stream._CancelOnErrorSubscriptionWrapper$(T)))();
class SubscriptionStream extends async.Stream$(T) {
static ['_#new#tearOff'](T, subscription) {
if (subscription == null) dart.nullFailed(I[199], 32, 44, "subscription");
return new (subscription_stream.SubscriptionStream$(T)).new(subscription);
}
listen(onData, opts) {
let onError = opts && 'onError' in opts ? opts.onError : null;
let onDone = opts && 'onDone' in opts ? opts.onDone : null;
let cancelOnError = opts && 'cancelOnError' in opts ? opts.cancelOnError : null;
let subscription = this[S$0._source$4];
if (subscription == null) {
dart.throw(new core.StateError.new("Stream has already been listened to."));
}
cancelOnError = true === cancelOnError;
this[S$0._source$4] = null;
let result = dart.test(cancelOnError) ? new (__t$_CancelOnErrorSubscriptionWrapperOfT()).new(subscription) : subscription;
result.onData(onData);
result.onError(onError);
result.onDone(onDone);
subscription.resume();
return result;
}
}
(SubscriptionStream.new = function(subscription) {
if (subscription == null) dart.nullFailed(I[199], 32, 44, "subscription");
this[S$0._source$4] = subscription;
SubscriptionStream.__proto__.new.call(this);
let source = dart.nullCheck(this[S$0._source$4]);
source.pause();
source.onData(null);
source.onError(null);
source.onDone(null);
}).prototype = SubscriptionStream.prototype;
dart.addTypeTests(SubscriptionStream);
SubscriptionStream.prototype[_is_SubscriptionStream_default] = true;
dart.addTypeCaches(SubscriptionStream);
dart.setMethodSignature(SubscriptionStream, () => ({
__proto__: dart.getMethods(SubscriptionStream.__proto__),
listen: dart.fnType(async.StreamSubscription$(T), [dart.nullable(dart.fnType(dart.void, [T]))], {cancelOnError: dart.nullable(core.bool), onDone: dart.nullable(dart.fnType(dart.void, [])), onError: dart.nullable(core.Function)}, {})
}));
dart.setLibraryUri(SubscriptionStream, I[200]);
dart.setFieldSignature(SubscriptionStream, () => ({
__proto__: dart.getFields(SubscriptionStream.__proto__),
[S$0._source$4]: dart.fieldType(dart.nullable(async.StreamSubscription$(T)))
}));
return SubscriptionStream;
});
subscription_stream.SubscriptionStream = subscription_stream.SubscriptionStream$();
dart.addTypeTests(subscription_stream.SubscriptionStream, _is_SubscriptionStream_default);
const _is__CancelOnErrorSubscriptionWrapper_default = Symbol('_is__CancelOnErrorSubscriptionWrapper_default');
subscription_stream._CancelOnErrorSubscriptionWrapper$ = dart.generic(T => {
class _CancelOnErrorSubscriptionWrapper extends stream_subscription.DelegatingStreamSubscription$(T) {
static ['_#new#tearOff'](T, subscription) {
if (subscription == null) dart.nullFailed(I[199], 71, 59, "subscription");
return new (subscription_stream._CancelOnErrorSubscriptionWrapper$(T)).new(subscription);
}
onError(handleError) {
super.onError(dart.fn((error, stackTrace) => {
if (stackTrace == null) dart.nullFailed(I[199], 77, 38, "stackTrace");
super.cancel().whenComplete(dart.fn(() => {
if (T$.dynamicAnddynamicTodynamic().is(handleError)) {
handleError(error, stackTrace);
} else if (handleError != null) {
dart.dcall(handleError, [error]);
}
}, T$.VoidToNull()));
}, T$.dynamicAndStackTraceToNull()));
}
}
(_CancelOnErrorSubscriptionWrapper.new = function(subscription) {
if (subscription == null) dart.nullFailed(I[199], 71, 59, "subscription");
_CancelOnErrorSubscriptionWrapper.__proto__.new.call(this, subscription);
;
}).prototype = _CancelOnErrorSubscriptionWrapper.prototype;
dart.addTypeTests(_CancelOnErrorSubscriptionWrapper);
_CancelOnErrorSubscriptionWrapper.prototype[_is__CancelOnErrorSubscriptionWrapper_default] = true;
dart.addTypeCaches(_CancelOnErrorSubscriptionWrapper);
dart.setLibraryUri(_CancelOnErrorSubscriptionWrapper, I[200]);
return _CancelOnErrorSubscriptionWrapper;
});
subscription_stream._CancelOnErrorSubscriptionWrapper = subscription_stream._CancelOnErrorSubscriptionWrapper$();
dart.addTypeTests(subscription_stream._CancelOnErrorSubscriptionWrapper, _is__CancelOnErrorSubscriptionWrapper_default);
const _is__TypeSafeStreamTransformer_default = Symbol('_is__TypeSafeStreamTransformer_default');
typed_stream_transformer._TypeSafeStreamTransformer$ = dart.generic((S, T) => {
var __t$StreamOfS = () => (__t$StreamOfS = dart.constFn(async.Stream$(S)))();
class _TypeSafeStreamTransformer extends async.StreamTransformerBase$(S, T) {
static ['_#new#tearOff'](S, T, _inner) {
if (_inner == null) dart.nullFailed(I[201], 25, 35, "_inner");
return new (typed_stream_transformer._TypeSafeStreamTransformer$(S, T)).new(_inner);
}
bind(stream) {
__t$StreamOfS().as(stream);
if (stream == null) dart.nullFailed(I[201], 28, 28, "stream");
return this[S$0._inner$3].bind(stream).cast(T);
}
}
(_TypeSafeStreamTransformer.new = function(_inner) {
if (_inner == null) dart.nullFailed(I[201], 25, 35, "_inner");
this[S$0._inner$3] = _inner;
_TypeSafeStreamTransformer.__proto__.new.call(this);
;
}).prototype = _TypeSafeStreamTransformer.prototype;
dart.addTypeTests(_TypeSafeStreamTransformer);
_TypeSafeStreamTransformer.prototype[_is__TypeSafeStreamTransformer_default] = true;
dart.addTypeCaches(_TypeSafeStreamTransformer);
dart.setMethodSignature(_TypeSafeStreamTransformer, () => ({
__proto__: dart.getMethods(_TypeSafeStreamTransformer.__proto__),
bind: dart.fnType(async.Stream$(T), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(_TypeSafeStreamTransformer, I[202]);
dart.setFieldSignature(_TypeSafeStreamTransformer, () => ({
__proto__: dart.getFields(_TypeSafeStreamTransformer.__proto__),
[S$0._inner$3]: dart.finalFieldType(async.StreamTransformer)
}));
return _TypeSafeStreamTransformer;
});
typed_stream_transformer._TypeSafeStreamTransformer = typed_stream_transformer._TypeSafeStreamTransformer$();
dart.addTypeTests(typed_stream_transformer._TypeSafeStreamTransformer, _is__TypeSafeStreamTransformer_default);
typed_stream_transformer.typedStreamTransformer = function typedStreamTransformer(S, T, transformer) {
if (transformer == null) dart.nullFailed(I[201], 15, 27, "transformer");
return async.StreamTransformer$(S, T).is(transformer) ? transformer : new (typed_stream_transformer._TypeSafeStreamTransformer$(S, T)).new(transformer);
};
const _is_ChunkedStreamReader_default = Symbol('_is_ChunkedStreamReader_default');
chunked_stream_reader.ChunkedStreamReader$ = dart.generic(T => {
var __t$JSArrayOfT = () => (__t$JSArrayOfT = dart.constFn(_interceptors.JSArray$(T)))();
var __t$ListOfT = () => (__t$ListOfT = dart.constFn(core.List$(T)))();
var __t$_AsyncStarImplOfListOfT = () => (__t$_AsyncStarImplOfListOfT = dart.constFn(async._AsyncStarImpl$(__t$ListOfT())))();
var __t$StreamOfListOfT = () => (__t$StreamOfListOfT = dart.constFn(async.Stream$(__t$ListOfT())))();
var __t$VoidToStreamOfListOfT = () => (__t$VoidToStreamOfListOfT = dart.constFn(dart.fnType(__t$StreamOfListOfT(), [])))();
var __t$StreamControllerOfListOfT = () => (__t$StreamControllerOfListOfT = dart.constFn(async.StreamController$(__t$ListOfT())))();
class ChunkedStreamReader extends core.Object {
static new(stream) {
if (stream == null) dart.nullFailed(I[203], 71, 47, "stream");
return new (chunked_stream_reader.ChunkedStreamReader$(T)).__(async.StreamIterator$(core.List$(T)).new(stream));
}
static ['_#new#tearOff'](T, stream) {
if (stream == null) dart.nullFailed(I[203], 71, 47, "stream");
return chunked_stream_reader.ChunkedStreamReader$(T).new(stream);
}
static ['_#_#tearOff'](T, _input) {
if (_input == null) dart.nullFailed(I[203], 74, 30, "_input");
return new (chunked_stream_reader.ChunkedStreamReader$(T)).__(_input);
}
readChunk(size) {
if (size == null) dart.nullFailed(I[203], 90, 33, "size");
return async.async(__t$ListOfT(), (function* readChunk() {
let result = __t$JSArrayOfT().of([]);
let iter = async.StreamIterator.new(this.readStream(size));
try {
while (yield iter.moveNext()) {
let chunk = iter.current;
{
result[S$.$addAll](chunk);
}
}
} finally {
yield iter.cancel();
}
return result;
}).bind(this));
}
readStream(size) {
if (size == null) dart.nullFailed(I[203], 114, 34, "size");
core.RangeError.checkNotNegative(size, "size");
if (dart.test(this[S$0._reading])) {
dart.throw(new core.StateError.new("Concurrent read operations are not allowed!"));
}
this[S$0._reading] = true;
let substream = dart.fn(() => new (__t$_AsyncStarImplOfListOfT()).new((function*(stream) {
while (dart.notNull(size) > 0) {
if (!(dart.notNull(this[S$0._offset]) <= dart.notNull(this[S$0._buffer$1][S$.$length]))) dart.assertFailed(null, I[203], 125, 16, "_offset <= _buffer.length");
if (this[S$0._offset] == this[S$0._buffer$1][S$.$length]) {
if (!dart.test(yield this[S$0._input].moveNext())) {
size = 0;
this[S$0._reading] = false;
break;
}
this[S$0._buffer$1] = this[S$0._input].current;
this[S$0._offset] = 0;
}
let remainingBuffer = dart.notNull(this[S$0._buffer$1][S$.$length]) - dart.notNull(this[S$0._offset]);
if (remainingBuffer > 0) {
if (remainingBuffer >= dart.notNull(size)) {
let output = null;
if (typed_data.Uint8List.is(this[S$0._buffer$1])) {
output = __t$ListOfT().as(typed_data.Uint8List.sublistView(typed_data.Uint8List.as(this[S$0._buffer$1]), this[S$0._offset], dart.notNull(this[S$0._offset]) + dart.notNull(size)));
} else {
output = this[S$0._buffer$1][S$0.$sublist](this[S$0._offset], dart.notNull(this[S$0._offset]) + dart.notNull(size));
}
this[S$0._offset] = dart.notNull(this[S$0._offset]) + dart.notNull(size);
size = 0;
if (stream.add(output)) return;
yield;
this[S$0._reading] = false;
break;
}
let output = this[S$0._offset] === 0 ? this[S$0._buffer$1] : this[S$0._buffer$1][S$0.$sublist](this[S$0._offset]);
size = dart.notNull(size) - remainingBuffer;
this[S$0._buffer$1] = this[S$0._emptyList];
this[S$0._offset] = 0;
if (stream.add(output)) return;
yield;
}
}
}).bind(this)).stream, __t$VoidToStreamOfListOfT());
let c = __t$StreamControllerOfListOfT().new();
c.onListen = dart.fn(() => c.addStream(substream()).whenComplete(dart.bind(c, 'close')), T$.VoidTovoid());
c.onCancel = dart.fn(() => async.async(dart.void, (function*() {
while (dart.notNull(size) > 0) {
if (!(dart.notNull(this[S$0._offset]) <= dart.notNull(this[S$0._buffer$1][S$.$length]))) dart.assertFailed(null, I[203], 167, 16, "_offset <= _buffer.length");
if (this[S$0._buffer$1][S$.$length] == this[S$0._offset]) {
if (!dart.test(yield this[S$0._input].moveNext())) {
size = 0;
break;
}
this[S$0._buffer$1] = this[S$0._input].current;
this[S$0._offset] = 0;
}
let remainingBuffer = dart.notNull(this[S$0._buffer$1][S$.$length]) - dart.notNull(this[S$0._offset]);
if (remainingBuffer >= dart.notNull(size)) {
this[S$0._offset] = dart.notNull(this[S$0._offset]) + dart.notNull(size);
size = 0;
break;
}
size = dart.notNull(size) - remainingBuffer;
this[S$0._buffer$1] = this[S$0._emptyList];
this[S$0._offset] = 0;
}
this[S$0._reading] = false;
}).bind(this)), T$.VoidToFutureOfvoid());
return c.stream;
}
cancel() {
return async.async(dart.void, (function* cancel() {
return yield this[S$0._input].cancel();
}).bind(this));
}
}
(ChunkedStreamReader.__ = function(_input) {
if (_input == null) dart.nullFailed(I[203], 74, 30, "_input");
this[S$0._emptyList] = C[190] || CT.C190;
this[S$0._buffer$1] = __t$JSArrayOfT().of([]);
this[S$0._offset] = 0;
this[S$0._reading] = false;
this[S$0._input] = _input;
;
}).prototype = ChunkedStreamReader.prototype;
dart.addTypeTests(ChunkedStreamReader);
ChunkedStreamReader.prototype[_is_ChunkedStreamReader_default] = true;
dart.addTypeCaches(ChunkedStreamReader);
dart.setMethodSignature(ChunkedStreamReader, () => ({
__proto__: dart.getMethods(ChunkedStreamReader.__proto__),
readChunk: dart.fnType(async.Future$(core.List$(T)), [core.int]),
readStream: dart.fnType(async.Stream$(core.List$(T)), [core.int]),
cancel: dart.fnType(async.Future$(dart.void), [])
}));
dart.setStaticMethodSignature(ChunkedStreamReader, () => ['new']);
dart.setLibraryUri(ChunkedStreamReader, I[204]);
dart.setFieldSignature(ChunkedStreamReader, () => ({
__proto__: dart.getFields(ChunkedStreamReader.__proto__),
[S$0._input]: dart.finalFieldType(async.StreamIterator$(core.List$(T))),
[S$0._emptyList]: dart.finalFieldType(core.List$(T)),
[S$0._buffer$1]: dart.fieldType(core.List$(T)),
[S$0._offset]: dart.fieldType(core.int),
[S$0._reading]: dart.fieldType(core.bool)
}));
return ChunkedStreamReader;
});
chunked_stream_reader.ChunkedStreamReader = chunked_stream_reader.ChunkedStreamReader$();
dart.addTypeTests(chunked_stream_reader.ChunkedStreamReader, _is_ChunkedStreamReader_default);
chunked_stream_reader['ChunkedStreamReaderByteStreamExt|readBytes'] = function ChunkedStreamReaderByteStreamExt$124readBytes($this, size) {
if ($this == null) dart.nullFailed(I[203], 214, 21, "#this");
if (size == null) dart.nullFailed(I[203], 214, 35, "size");
return async.async(typed_data.Uint8List, function* ChunkedStreamReaderByteStreamExt$124readBytes() {
return yield byte_collector.collectBytes($this.readStream(size));
});
};
chunked_stream_reader['ChunkedStreamReaderByteStreamExt|get#readBytes'] = function ChunkedStreamReaderByteStreamExt$124get$35readBytes($this) {
if ($this == null) dart.nullFailed(I[203], 214, 21, "#this");
return dart.fn(size => {
if (size == null) dart.nullFailed(I[203], 214, 35, "size");
return chunked_stream_reader['ChunkedStreamReaderByteStreamExt|readBytes']($this, size);
}, T$0.intToFutureOfUint8List());
};
digest.Digest = class Digest extends core.Object {
get bytes() {
return this[S$0.bytes];
}
set bytes(value) {
super.bytes = value;
}
static ['_#new#tearOff'](bytes) {
if (bytes == null) dart.nullFailed(I[205], 14, 15, "bytes");
return new digest.Digest.new(bytes);
}
_equals(other) {
if (other == null) return false;
if (digest.Digest.is(other)) {
let a = this.bytes;
let b = other.bytes;
let n = a[S$.$length];
if (n != b[S$.$length]) {
return false;
}
let mismatch = 0;
for (let i = 0; i < dart.notNull(n); i = i + 1) {
mismatch = (mismatch | (dart.notNull(a[S$.$_get](i)) ^ dart.notNull(b[S$.$_get](i))) >>> 0) >>> 0;
}
return mismatch === 0;
}
return false;
}
get hashCode() {
return (C[191] || CT.C191).hash(this.bytes);
}
toString() {
return digest._hexEncode(this.bytes);
}
};
(digest.Digest.new = function(bytes) {
if (bytes == null) dart.nullFailed(I[205], 14, 15, "bytes");
this[S$0.bytes] = bytes;
;
}).prototype = digest.Digest.prototype;
dart.addTypeTests(digest.Digest);
dart.addTypeCaches(digest.Digest);
dart.setLibraryUri(digest.Digest, I[206]);
dart.setFieldSignature(digest.Digest, () => ({
__proto__: dart.getFields(digest.Digest.__proto__),
bytes: dart.finalFieldType(core.List$(core.int))
}));
dart.defineExtensionMethods(digest.Digest, ['_equals', 'toString']);
dart.defineExtensionAccessors(digest.Digest, ['hashCode']);
digest._hexEncode = function _hexEncode(bytes) {
let t215, t215$;
if (bytes == null) dart.nullFailed(I[205], 46, 29, "bytes");
let charCodes = _native_typed_data.NativeUint8List.new(dart.notNull(bytes[S$.$length]) * 2);
for (let i = 0, j = 0; i < dart.notNull(bytes[S$.$length]); i = i + 1) {
let byte = bytes[S$.$_get](i);
charCodes[S$.$_set]((t215 = j, j = t215 + 1, t215), "0123456789abcdef"[S$.$codeUnitAt](dart.notNull(byte) >> 4 & 15));
charCodes[S$.$_set]((t215$ = j, j = t215$ + 1, t215$), "0123456789abcdef"[S$.$codeUnitAt](dart.notNull(byte) & 15));
}
return core.String.fromCharCodes(charCodes);
};
hash.Hash = class Hash extends convert.Converter$(core.List$(core.int), digest.Digest) {
convert(data) {
T$.ListOfint().as(data);
if (data == null) dart.nullFailed(I[207], 25, 28, "data");
let innerSink = new digest_sink.DigestSink.new();
let outerSink = this.startChunkedConversion(innerSink);
outerSink.add(data);
outerSink.close();
return innerSink.value;
}
};
(hash.Hash.new = function() {
hash.Hash.__proto__.new.call(this);
;
}).prototype = hash.Hash.prototype;
dart.addTypeTests(hash.Hash);
dart.addTypeCaches(hash.Hash);
dart.setMethodSignature(hash.Hash, () => ({
__proto__: dart.getMethods(hash.Hash.__proto__),
convert: dart.fnType(digest.Digest, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(hash.Hash, I[208]);
hmac.Hmac = class Hmac extends convert.Converter$(core.List$(core.int), digest.Digest) {
static ['_#new#tearOff'](hash, key) {
if (hash == null) dart.nullFailed(I[209], 29, 13, "hash");
if (key == null) dart.nullFailed(I[209], 29, 29, "key");
return new hmac.Hmac.new(hash, key);
}
convert(data) {
T$.ListOfint().as(data);
if (data == null) dart.nullFailed(I[209], 41, 28, "data");
let innerSink = new digest_sink.DigestSink.new();
let outerSink = this.startChunkedConversion(innerSink);
outerSink.add(data);
outerSink.close();
return innerSink.value;
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[209], 50, 58, "sink");
return new hmac._HmacSink.new(sink, this[S$0._hash], this[S$0._key]);
}
};
(hmac.Hmac.new = function(hash, key) {
if (hash == null) dart.nullFailed(I[209], 29, 13, "hash");
if (key == null) dart.nullFailed(I[209], 29, 29, "key");
this[S$0._hash] = hash;
this[S$0._key] = _native_typed_data.NativeUint8List.new(hash.blockSize);
hmac.Hmac.__proto__.new.call(this);
if (dart.notNull(key[S$.$length]) > dart.notNull(this[S$0._hash].blockSize)) key = this[S$0._hash].convert(key).bytes;
this[S$0._key][S$.$setRange](0, key[S$.$length], key);
}).prototype = hmac.Hmac.prototype;
dart.addTypeTests(hmac.Hmac);
dart.addTypeCaches(hmac.Hmac);
dart.setMethodSignature(hmac.Hmac, () => ({
__proto__: dart.getMethods(hmac.Hmac.__proto__),
convert: dart.fnType(digest.Digest, [dart.nullable(core.Object)]),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(hmac.Hmac, I[210]);
dart.setFieldSignature(hmac.Hmac, () => ({
__proto__: dart.getFields(hmac.Hmac.__proto__),
[S$0._hash]: dart.finalFieldType(hash.Hash),
[S$0._key]: dart.finalFieldType(typed_data.Uint8List)
}));
hmac._HmacSink = class _HmacSink extends convert.ByteConversionSink {
get [S$0._innerSink]() {
let t215;
return dart.test(this[S$0.___HmacSink__innerSink_isSet]) ? (t215 = this[S$0.___HmacSink__innerSink], t215) : dart.throw(new _internal.LateError.fieldNI("_innerSink"));
}
set [S$0._innerSink](t215) {
if (t215 == null) dart.nullFailed(I[209], 63, 33, "null");
if (dart.test(this[S$0.___HmacSink__innerSink_isSet]))
dart.throw(new _internal.LateError.fieldAI("_innerSink"));
else {
this[S$0.___HmacSink__innerSink_isSet] = true;
this[S$0.___HmacSink__innerSink] = t215;
}
}
static ['_#new#tearOff'](sink, hash, key) {
if (sink == null) dart.nullFailed(I[209], 68, 26, "sink");
if (hash == null) dart.nullFailed(I[209], 68, 37, "hash");
if (key == null) dart.nullFailed(I[209], 68, 53, "key");
return new hmac._HmacSink.new(sink, hash, key);
}
add(data) {
T$.ListOfint().as(data);
if (data == null) dart.nullFailed(I[209], 87, 22, "data");
if (dart.test(this[S$0._isClosed$2])) dart.throw(new core.StateError.new("HMAC is closed"));
this[S$0._innerSink].add(data);
}
addSlice(data, start, end, isLast) {
if (data == null) dart.nullFailed(I[209], 93, 27, "data");
if (start == null) dart.nullFailed(I[209], 93, 37, "start");
if (end == null) dart.nullFailed(I[209], 93, 48, "end");
if (isLast == null) dart.nullFailed(I[209], 93, 58, "isLast");
if (dart.test(this[S$0._isClosed$2])) dart.throw(new core.StateError.new("HMAC is closed"));
this[S$0._innerSink].addSlice(data, start, end, isLast);
}
close() {
if (dart.test(this[S$0._isClosed$2])) return;
this[S$0._isClosed$2] = true;
this[S$0._innerSink].close();
this[S$0._outerSink].add(this[S$0._innerResultSink].value.bytes);
this[S$0._outerSink].close();
}
};
(hmac._HmacSink.new = function(sink, hash, key) {
if (sink == null) dart.nullFailed(I[209], 68, 26, "sink");
if (hash == null) dart.nullFailed(I[209], 68, 37, "hash");
if (key == null) dart.nullFailed(I[209], 68, 53, "key");
this[S$0._innerResultSink] = new digest_sink.DigestSink.new();
this[S$0.___HmacSink__innerSink] = null;
this[S$0.___HmacSink__innerSink_isSet] = false;
this[S$0._isClosed$2] = false;
this[S$0._outerSink] = hash.startChunkedConversion(sink);
hmac._HmacSink.__proto__.new.call(this);
this[S$0._innerSink] = hash.startChunkedConversion(this[S$0._innerResultSink]);
let padding = _native_typed_data.NativeUint8List.new(key[S$.$length]);
for (let i = 0; i < dart.notNull(padding[S$.$length]); i = i + 1) {
padding[S$.$_set](i, (92 ^ dart.notNull(key[S$.$_get](i))) >>> 0);
}
this[S$0._outerSink].add(padding);
for (let i = 0; i < dart.notNull(padding[S$.$length]); i = i + 1) {
padding[S$.$_set](i, (54 ^ dart.notNull(key[S$.$_get](i))) >>> 0);
}
this[S$0._innerSink].add(padding);
}).prototype = hmac._HmacSink.prototype;
dart.addTypeTests(hmac._HmacSink);
dart.addTypeCaches(hmac._HmacSink);
dart.setMethodSignature(hmac._HmacSink, () => ({
__proto__: dart.getMethods(hmac._HmacSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addSlice: dart.fnType(dart.void, [core.List$(core.int), core.int, core.int, core.bool]),
close: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(hmac._HmacSink, () => ({
__proto__: dart.getGetters(hmac._HmacSink.__proto__),
[S$0._innerSink]: convert.ByteConversionSink
}));
dart.setSetterSignature(hmac._HmacSink, () => ({
__proto__: dart.getSetters(hmac._HmacSink.__proto__),
[S$0._innerSink]: convert.ByteConversionSink
}));
dart.setLibraryUri(hmac._HmacSink, I[210]);
dart.setFieldSignature(hmac._HmacSink, () => ({
__proto__: dart.getFields(hmac._HmacSink.__proto__),
[S$0._outerSink]: dart.finalFieldType(convert.ByteConversionSink),
[S$0._innerResultSink]: dart.finalFieldType(digest_sink.DigestSink),
[S$0.___HmacSink__innerSink]: dart.fieldType(dart.nullable(convert.ByteConversionSink)),
[S$0.___HmacSink__innerSink_isSet]: dart.fieldType(core.bool),
[S$0._isClosed$2]: dart.fieldType(core.bool)
}));
md5._MD5 = class _MD5 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#_#tearOff']() {
return new md5._MD5.__();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[211], 36, 58, "sink");
return new convert._ByteAdapterSink.new(new md5._MD5Sink.new(sink));
}
};
(md5._MD5.__ = function() {
this[S$0.blockSize] = 16 * 4;
md5._MD5.__proto__.new.call(this);
;
}).prototype = md5._MD5.prototype;
dart.addTypeTests(md5._MD5);
dart.addTypeCaches(md5._MD5);
dart.setMethodSignature(md5._MD5, () => ({
__proto__: dart.getMethods(md5._MD5.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(md5._MD5, I[212]);
dart.setFieldSignature(md5._MD5, () => ({
__proto__: dart.getFields(md5._MD5.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
hash_sink.HashSink = class HashSink extends core.Object {
add(data) {
T$.ListOfint().as(data);
if (data == null) dart.nullFailed(I[213], 76, 22, "data");
if (dart.test(this[S$0._isClosed$3])) dart.throw(new core.StateError.new("Hash.add() called after close()."));
this[S$0._lengthInBytes] = dart.notNull(this[S$0._lengthInBytes]) + dart.notNull(data[S$.$length]);
this[S$0._pendingData].addAll(data);
this[S$0._iterate]();
}
close() {
if (dart.test(this[S$0._isClosed$3])) return;
this[S$0._isClosed$3] = true;
this[S$0._finalizeData]();
this[S$0._iterate]();
if (!dart.test(this[S$0._pendingData][S$.$isEmpty])) dart.assertFailed(null, I[213], 90, 12, "_pendingData.isEmpty");
this[S$0._sink$5].add(new digest.Digest.new(this[S$0._byteDigest]()));
this[S$0._sink$5].close();
}
[S$0._byteDigest]() {
if (dart.equals(this[S$0._endian], typed_data.Endian.host)) return this.digest[S$.$buffer][S$.$asUint8List]();
let cachedDigest = this.digest;
let byteDigest = _native_typed_data.NativeUint8List.new(cachedDigest[S$0.$lengthInBytes]);
let byteData = byteDigest[S$.$buffer][S$0.$asByteData]();
for (let i = 0; i < dart.notNull(cachedDigest[S$.$length]); i = i + 1) {
byteData[S$.$setUint32](i * 4, cachedDigest[S$.$_get](i));
}
return byteDigest;
}
[S$0._iterate]() {
let pendingDataBytes = this[S$0._pendingData].buffer[S$0.$asByteData]();
let pendingDataChunks = (dart.notNull(this[S$0._pendingData].length) / dart.notNull(this[S$0._currentChunk][S$0.$lengthInBytes]))[S$.$truncate]();
for (let i = 0; i < pendingDataChunks; i = i + 1) {
for (let j = 0; j < dart.notNull(this[S$0._currentChunk][S$.$length]); j = j + 1) {
this[S$0._currentChunk][S$.$_set](j, pendingDataBytes[S$.$getUint32](i * dart.notNull(this[S$0._currentChunk][S$0.$lengthInBytes]) + j * 4, this[S$0._endian]));
}
this.updateHash(this[S$0._currentChunk]);
}
this[S$0._pendingData][S$0.$removeRange](0, pendingDataChunks * dart.notNull(this[S$0._currentChunk][S$0.$lengthInBytes]));
}
[S$0._finalizeData]() {
this[S$0._pendingData].add(128);
let contentsLength = dart.notNull(this[S$0._lengthInBytes]) + 1 + dart.notNull(this[S$0._signatureBytes]);
let finalizedLength = this[S$0._roundUp](contentsLength, this[S$0._currentChunk][S$0.$lengthInBytes]);
for (let i = 0; i < dart.notNull(finalizedLength) - contentsLength; i = i + 1) {
this[S$0._pendingData].add(0);
}
if (dart.notNull(this[S$0._lengthInBytes]) > 1125899906842623.0) {
dart.throw(new core.UnsupportedError.new("Hashing is unsupported for messages with more than 2^53 bits."));
}
let lengthInBits = dart.notNull(this[S$0._lengthInBytes]) * 8;
let offset = dart.notNull(this[S$0._pendingData].length) + (dart.notNull(this[S$0._signatureBytes]) - 8);
this[S$0._pendingData].addAll(_native_typed_data.NativeUint8List.new(this[S$0._signatureBytes]));
let byteData = this[S$0._pendingData].buffer[S$0.$asByteData]();
let highBits = lengthInBits[S$.$rightShift](32);
let lowBits = (lengthInBits & 4294967295.0) >>> 0;
if (dart.equals(this[S$0._endian], typed_data.Endian.big)) {
byteData[S$.$setUint32](offset, highBits, this[S$0._endian]);
byteData[S$.$setUint32](offset + 4, lowBits, this[S$0._endian]);
} else {
byteData[S$.$setUint32](offset, lowBits, this[S$0._endian]);
byteData[S$.$setUint32](offset + 4, highBits, this[S$0._endian]);
}
}
[S$0._roundUp](val, n) {
if (val == null) dart.nullFailed(I[213], 177, 20, "val");
if (n == null) dart.nullFailed(I[213], 177, 29, "n");
return (dart.notNull(val) + dart.notNull(n) - 1 & -dart.notNull(n)) >>> 0;
}
};
(hash_sink.HashSink.new = function(_sink, chunkSizeInWords, opts) {
if (_sink == null) dart.nullFailed(I[213], 61, 17, "_sink");
if (chunkSizeInWords == null) dart.nullFailed(I[213], 61, 28, "chunkSizeInWords");
let endian = opts && 'endian' in opts ? opts.endian : C[192] || CT.C192;
if (endian == null) dart.nullFailed(I[213], 62, 15, "endian");
let signatureBytes = opts && 'signatureBytes' in opts ? opts.signatureBytes : 8;
if (signatureBytes == null) dart.nullFailed(I[213], 62, 40, "signatureBytes");
this[S$0._lengthInBytes] = 0;
this[S$0._pendingData] = new typed_buffer.Uint8Buffer.new();
this[S$0._isClosed$3] = false;
this[S$0._sink$5] = _sink;
this[S$0._endian] = endian;
if (!(dart.notNull(signatureBytes) >= 8)) dart.assertFailed(null, I[213], 64, 16, "signatureBytes >= 8");
this[S$0._signatureBytes] = signatureBytes;
this[S$0._currentChunk] = _native_typed_data.NativeUint32List.new(chunkSizeInWords);
;
}).prototype = hash_sink.HashSink.prototype;
dart.addTypeTests(hash_sink.HashSink);
dart.addTypeCaches(hash_sink.HashSink);
hash_sink.HashSink[dart.implements] = () => [core.Sink$(core.List$(core.int))];
dart.setMethodSignature(hash_sink.HashSink, () => ({
__proto__: dart.getMethods(hash_sink.HashSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
close: dart.fnType(dart.void, []),
[S$0._byteDigest]: dart.fnType(typed_data.Uint8List, []),
[S$0._iterate]: dart.fnType(dart.void, []),
[S$0._finalizeData]: dart.fnType(dart.void, []),
[S$0._roundUp]: dart.fnType(core.int, [core.int, core.int])
}));
dart.setLibraryUri(hash_sink.HashSink, I[214]);
dart.setFieldSignature(hash_sink.HashSink, () => ({
__proto__: dart.getFields(hash_sink.HashSink.__proto__),
[S$0._sink$5]: dart.finalFieldType(core.Sink$(digest.Digest)),
[S$0._endian]: dart.finalFieldType(typed_data.Endian),
[S$0._currentChunk]: dart.finalFieldType(typed_data.Uint32List),
[S$0._lengthInBytes]: dart.fieldType(core.int),
[S$0._pendingData]: dart.finalFieldType(typed_buffer.Uint8Buffer),
[S$0._isClosed$3]: dart.fieldType(core.bool),
[S$0._signatureBytes]: dart.finalFieldType(core.int)
}));
dart.setStaticFieldSignature(hash_sink.HashSink, () => ['_maxMessageLengthInBytes']);
dart.defineLazy(hash_sink.HashSink, {
/*hash_sink.HashSink._maxMessageLengthInBytes*/get _maxMessageLengthInBytes() {
return 1125899906842623.0;
}
}, false);
md5._MD5Sink = class _MD5Sink extends hash_sink.HashSink {
get digest() {
return this[S$0.digest];
}
set digest(value) {
super.digest = value;
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[211], 72, 25, "sink");
return new md5._MD5Sink.new(sink);
}
updateHash(chunk) {
if (chunk == null) dart.nullFailed(I[211], 80, 30, "chunk");
if (!(chunk[S$.$length] === 16)) dart.assertFailed(null, I[211], 81, 12, "chunk.length == 16");
let a = this.digest[S$.$_get](0);
let b = this.digest[S$.$_get](1);
let c = this.digest[S$.$_get](2);
let d = this.digest[S$.$_get](3);
let e = null;
let f = null;
for (let i = 0; i < 64; i = i + 1) {
if (i < 16) {
e = (dart.notNull(b) & dart.notNull(c) | (~dart.notNull(b) & 4294967295.0 & dart.notNull(d)) >>> 0) >>> 0;
f = i;
} else if (i < 32) {
e = (dart.notNull(d) & dart.notNull(b) | (~dart.notNull(d) & 4294967295.0 & dart.notNull(c)) >>> 0) >>> 0;
f = (5 * i + 1)[S$.$modulo](16);
} else if (i < 48) {
e = (dart.notNull(b) ^ dart.notNull(c) ^ dart.notNull(d)) >>> 0;
f = (3 * i + 5)[S$.$modulo](16);
} else {
e = (dart.notNull(c) ^ (dart.notNull(b) | (~dart.notNull(d) & 4294967295.0) >>> 0) >>> 0) >>> 0;
f = (7 * i)[S$.$modulo](16);
}
let temp = d;
d = c;
c = b;
b = utils$0.add32(b, utils$0.rotl32(utils$0.add32(utils$0.add32(a, e), utils$0.add32(md5._noise[S$.$_get](i), chunk[S$.$_get](f))), md5._shiftAmounts[S$.$_get](i)));
a = temp;
}
this.digest[S$.$_set](0, utils$0.add32(a, this.digest[S$.$_get](0)));
this.digest[S$.$_set](1, utils$0.add32(b, this.digest[S$.$_get](1)));
this.digest[S$.$_set](2, utils$0.add32(c, this.digest[S$.$_get](2)));
this.digest[S$.$_set](3, utils$0.add32(d, this.digest[S$.$_get](3)));
}
};
(md5._MD5Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[211], 72, 25, "sink");
this[S$0.digest] = _native_typed_data.NativeUint32List.new(4);
md5._MD5Sink.__proto__.new.call(this, sink, 16, {endian: typed_data.Endian.little});
this.digest[S$.$_set](0, 1732584193);
this.digest[S$.$_set](1, 4023233417);
this.digest[S$.$_set](2, 2562383102);
this.digest[S$.$_set](3, 271733878);
}).prototype = md5._MD5Sink.prototype;
dart.addTypeTests(md5._MD5Sink);
dart.addTypeCaches(md5._MD5Sink);
dart.setMethodSignature(md5._MD5Sink, () => ({
__proto__: dart.getMethods(md5._MD5Sink.__proto__),
updateHash: dart.fnType(dart.void, [typed_data.Uint32List])
}));
dart.setLibraryUri(md5._MD5Sink, I[212]);
dart.setFieldSignature(md5._MD5Sink, () => ({
__proto__: dart.getFields(md5._MD5Sink.__proto__),
digest: dart.finalFieldType(typed_data.Uint32List)
}));
dart.defineLazy(md5, {
/*md5.md5*/get md5() {
return C[193] || CT.C193;
},
/*md5._noise*/get _noise() {
return C[194] || CT.C194;
},
/*md5._shiftAmounts*/get _shiftAmounts() {
return C[195] || CT.C195;
}
}, false);
sha1._Sha1 = class _Sha1 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$1];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#_#tearOff']() {
return new sha1._Sha1.__();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[215], 28, 58, "sink");
return new convert._ByteAdapterSink.new(new sha1._Sha1Sink.new(sink));
}
};
(sha1._Sha1.__ = function() {
this[S$0.blockSize$1] = 16 * 4;
sha1._Sha1.__proto__.new.call(this);
;
}).prototype = sha1._Sha1.prototype;
dart.addTypeTests(sha1._Sha1);
dart.addTypeCaches(sha1._Sha1);
dart.setMethodSignature(sha1._Sha1, () => ({
__proto__: dart.getMethods(sha1._Sha1.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha1._Sha1, I[216]);
dart.setFieldSignature(sha1._Sha1, () => ({
__proto__: dart.getFields(sha1._Sha1.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
sha1._Sha1Sink = class _Sha1Sink extends hash_sink.HashSink {
get digest() {
return this[S$0.digest$1];
}
set digest(value) {
super.digest = value;
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[215], 46, 26, "sink");
return new sha1._Sha1Sink.new(sink);
}
updateHash(chunk) {
if (chunk == null) dart.nullFailed(I[215], 57, 30, "chunk");
if (!(chunk[S$.$length] === 16)) dart.assertFailed(null, I[215], 58, 12, "chunk.length == 16");
let a = this.digest[S$.$_get](0);
let b = this.digest[S$.$_get](1);
let c = this.digest[S$.$_get](2);
let d = this.digest[S$.$_get](3);
let e = this.digest[S$.$_get](4);
for (let i = 0; i < 80; i = i + 1) {
if (i < 16) {
this[S$0._extended][S$.$_set](i, chunk[S$.$_get](i));
} else {
this[S$0._extended][S$.$_set](i, utils$0.rotl32((dart.notNull(this[S$0._extended][S$.$_get](i - 3)) ^ dart.notNull(this[S$0._extended][S$.$_get](i - 8)) ^ dart.notNull(this[S$0._extended][S$.$_get](i - 14)) ^ dart.notNull(this[S$0._extended][S$.$_get](i - 16))) >>> 0, 1));
}
let newA = utils$0.add32(utils$0.add32(utils$0.rotl32(a, 5), e), this[S$0._extended][S$.$_get](i));
if (i < 20) {
newA = utils$0.add32(utils$0.add32(newA, (dart.notNull(b) & dart.notNull(c) | (~dart.notNull(b) & dart.notNull(d)) >>> 0) >>> 0), 1518500249);
} else if (i < 40) {
newA = utils$0.add32(utils$0.add32(newA, (dart.notNull(b) ^ dart.notNull(c) ^ dart.notNull(d)) >>> 0), 1859775393);
} else if (i < 60) {
newA = utils$0.add32(utils$0.add32(newA, (dart.notNull(b) & dart.notNull(c) | (dart.notNull(b) & dart.notNull(d)) >>> 0 | (dart.notNull(c) & dart.notNull(d)) >>> 0) >>> 0), 2400959708);
} else {
newA = utils$0.add32(utils$0.add32(newA, (dart.notNull(b) ^ dart.notNull(c) ^ dart.notNull(d)) >>> 0), 3395469782);
}
e = d;
d = c;
c = utils$0.rotl32(b, 30);
b = a;
a = (dart.notNull(newA) & 4294967295.0) >>> 0;
}
this.digest[S$.$_set](0, utils$0.add32(a, this.digest[S$.$_get](0)));
this.digest[S$.$_set](1, utils$0.add32(b, this.digest[S$.$_get](1)));
this.digest[S$.$_set](2, utils$0.add32(c, this.digest[S$.$_get](2)));
this.digest[S$.$_set](3, utils$0.add32(d, this.digest[S$.$_get](3)));
this.digest[S$.$_set](4, utils$0.add32(e, this.digest[S$.$_get](4)));
}
};
(sha1._Sha1Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[215], 46, 26, "sink");
this[S$0.digest$1] = _native_typed_data.NativeUint32List.new(5);
this[S$0._extended] = _native_typed_data.NativeUint32List.new(80);
sha1._Sha1Sink.__proto__.new.call(this, sink, 16);
this.digest[S$.$_set](0, 1732584193);
this.digest[S$.$_set](1, 4023233417);
this.digest[S$.$_set](2, 2562383102);
this.digest[S$.$_set](3, 271733878);
this.digest[S$.$_set](4, 3285377520);
}).prototype = sha1._Sha1Sink.prototype;
dart.addTypeTests(sha1._Sha1Sink);
dart.addTypeCaches(sha1._Sha1Sink);
dart.setMethodSignature(sha1._Sha1Sink, () => ({
__proto__: dart.getMethods(sha1._Sha1Sink.__proto__),
updateHash: dart.fnType(dart.void, [typed_data.Uint32List])
}));
dart.setLibraryUri(sha1._Sha1Sink, I[216]);
dart.setFieldSignature(sha1._Sha1Sink, () => ({
__proto__: dart.getFields(sha1._Sha1Sink.__proto__),
digest: dart.finalFieldType(typed_data.Uint32List),
[S$0._extended]: dart.finalFieldType(typed_data.Uint32List)
}));
dart.defineLazy(sha1, {
/*sha1.sha1*/get sha1() {
return C[196] || CT.C196;
}
}, false);
sha256._Sha256 = class _Sha256 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$2];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#_#tearOff']() {
return new sha256._Sha256.__();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[217], 35, 58, "sink");
return new convert._ByteAdapterSink.new(new sha256._Sha256Sink.new(sink));
}
};
(sha256._Sha256.__ = function() {
this[S$0.blockSize$2] = 16 * 4;
sha256._Sha256.__proto__.new.call(this);
;
}).prototype = sha256._Sha256.prototype;
dart.addTypeTests(sha256._Sha256);
dart.addTypeCaches(sha256._Sha256);
dart.setMethodSignature(sha256._Sha256, () => ({
__proto__: dart.getMethods(sha256._Sha256.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha256._Sha256, I[218]);
dart.setFieldSignature(sha256._Sha256, () => ({
__proto__: dart.getFields(sha256._Sha256.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
sha256._Sha224 = class _Sha224 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$3];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#_#tearOff']() {
return new sha256._Sha224.__();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[217], 52, 58, "sink");
return new convert._ByteAdapterSink.new(new sha256._Sha224Sink.new(sink));
}
};
(sha256._Sha224.__ = function() {
this[S$0.blockSize$3] = 16 * 4;
sha256._Sha224.__proto__.new.call(this);
;
}).prototype = sha256._Sha224.prototype;
dart.addTypeTests(sha256._Sha224);
dart.addTypeCaches(sha256._Sha224);
dart.setMethodSignature(sha256._Sha224, () => ({
__proto__: dart.getMethods(sha256._Sha224.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha256._Sha224, I[218]);
dart.setFieldSignature(sha256._Sha224, () => ({
__proto__: dart.getFields(sha256._Sha224.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
sha256._Sha32BitSink = class _Sha32BitSink extends hash_sink.HashSink {
[S$0._rotr32](n, x) {
if (n == null) dart.nullFailed(I[217], 85, 19, "n");
if (x == null) dart.nullFailed(I[217], 85, 26, "x");
return (x[S$.$rightShift](n) | (x[S$.$leftShift](32 - dart.notNull(n)) & 4294967295.0) >>> 0) >>> 0;
}
[S$0._ch](x, y, z) {
if (x == null) dart.nullFailed(I[217], 86, 15, "x");
if (y == null) dart.nullFailed(I[217], 86, 22, "y");
if (z == null) dart.nullFailed(I[217], 86, 29, "z");
return (dart.notNull(x) & dart.notNull(y) ^ (~dart.notNull(x) & 4294967295.0 & dart.notNull(z)) >>> 0) >>> 0;
}
[S$0._maj](x, y, z) {
if (x == null) dart.nullFailed(I[217], 87, 16, "x");
if (y == null) dart.nullFailed(I[217], 87, 23, "y");
if (z == null) dart.nullFailed(I[217], 87, 30, "z");
return (dart.notNull(x) & dart.notNull(y) ^ (dart.notNull(x) & dart.notNull(z)) >>> 0 ^ (dart.notNull(y) & dart.notNull(z)) >>> 0) >>> 0;
}
[S$0._bsig0](x) {
if (x == null) dart.nullFailed(I[217], 88, 18, "x");
return (dart.notNull(this[S$0._rotr32](2, x)) ^ dart.notNull(this[S$0._rotr32](13, x)) ^ dart.notNull(this[S$0._rotr32](22, x))) >>> 0;
}
[S$0._bsig1](x) {
if (x == null) dart.nullFailed(I[217], 89, 18, "x");
return (dart.notNull(this[S$0._rotr32](6, x)) ^ dart.notNull(this[S$0._rotr32](11, x)) ^ dart.notNull(this[S$0._rotr32](25, x))) >>> 0;
}
[S$0._ssig0](x) {
if (x == null) dart.nullFailed(I[217], 90, 18, "x");
return (dart.notNull(this[S$0._rotr32](7, x)) ^ dart.notNull(this[S$0._rotr32](18, x)) ^ x[S$.$rightShift](3)) >>> 0;
}
[S$0._ssig1](x) {
if (x == null) dart.nullFailed(I[217], 91, 18, "x");
return (dart.notNull(this[S$0._rotr32](17, x)) ^ dart.notNull(this[S$0._rotr32](19, x)) ^ x[S$.$rightShift](10)) >>> 0;
}
updateHash(chunk) {
if (chunk == null) dart.nullFailed(I[217], 94, 30, "chunk");
if (!(chunk[S$.$length] === 16)) dart.assertFailed(null, I[217], 95, 12, "chunk.length == 16");
for (let i = 0; i < 16; i = i + 1) {
this[S$0._extended$1][S$.$_set](i, chunk[S$.$_get](i));
}
for (let i = 16; i < 64; i = i + 1) {
this[S$0._extended$1][S$.$_set](i, utils$0.add32(utils$0.add32(this[S$0._ssig1](this[S$0._extended$1][S$.$_get](i - 2)), this[S$0._extended$1][S$.$_get](i - 7)), utils$0.add32(this[S$0._ssig0](this[S$0._extended$1][S$.$_get](i - 15)), this[S$0._extended$1][S$.$_get](i - 16))));
}
let a = this[S$0._digest][S$.$_get](0);
let b = this[S$0._digest][S$.$_get](1);
let c = this[S$0._digest][S$.$_get](2);
let d = this[S$0._digest][S$.$_get](3);
let e = this[S$0._digest][S$.$_get](4);
let f = this[S$0._digest][S$.$_get](5);
let g = this[S$0._digest][S$.$_get](6);
let h = this[S$0._digest][S$.$_get](7);
for (let i = 0; i < 64; i = i + 1) {
let temp1 = utils$0.add32(utils$0.add32(h, this[S$0._bsig1](e)), utils$0.add32(this[S$0._ch](e, f, g), utils$0.add32(sha256._noise[S$.$_get](i), this[S$0._extended$1][S$.$_get](i))));
let temp2 = utils$0.add32(this[S$0._bsig0](a), this[S$0._maj](a, b, c));
h = g;
g = f;
f = e;
e = utils$0.add32(d, temp1);
d = c;
c = b;
b = a;
a = utils$0.add32(temp1, temp2);
}
this[S$0._digest][S$.$_set](0, utils$0.add32(a, this[S$0._digest][S$.$_get](0)));
this[S$0._digest][S$.$_set](1, utils$0.add32(b, this[S$0._digest][S$.$_get](1)));
this[S$0._digest][S$.$_set](2, utils$0.add32(c, this[S$0._digest][S$.$_get](2)));
this[S$0._digest][S$.$_set](3, utils$0.add32(d, this[S$0._digest][S$.$_get](3)));
this[S$0._digest][S$.$_set](4, utils$0.add32(e, this[S$0._digest][S$.$_get](4)));
this[S$0._digest][S$.$_set](5, utils$0.add32(f, this[S$0._digest][S$.$_get](5)));
this[S$0._digest][S$.$_set](6, utils$0.add32(g, this[S$0._digest][S$.$_get](6)));
this[S$0._digest][S$.$_set](7, utils$0.add32(h, this[S$0._digest][S$.$_get](7)));
}
};
(sha256._Sha32BitSink.new = function(sink, _digest) {
if (sink == null) dart.nullFailed(I[217], 80, 30, "sink");
if (_digest == null) dart.nullFailed(I[217], 80, 41, "_digest");
this[S$0._extended$1] = _native_typed_data.NativeUint32List.new(64);
this[S$0._digest] = _digest;
sha256._Sha32BitSink.__proto__.new.call(this, sink, 16);
;
}).prototype = sha256._Sha32BitSink.prototype;
dart.addTypeTests(sha256._Sha32BitSink);
dart.addTypeCaches(sha256._Sha32BitSink);
dart.setMethodSignature(sha256._Sha32BitSink, () => ({
__proto__: dart.getMethods(sha256._Sha32BitSink.__proto__),
[S$0._rotr32]: dart.fnType(core.int, [core.int, core.int]),
[S$0._ch]: dart.fnType(core.int, [core.int, core.int, core.int]),
[S$0._maj]: dart.fnType(core.int, [core.int, core.int, core.int]),
[S$0._bsig0]: dart.fnType(core.int, [core.int]),
[S$0._bsig1]: dart.fnType(core.int, [core.int]),
[S$0._ssig0]: dart.fnType(core.int, [core.int]),
[S$0._ssig1]: dart.fnType(core.int, [core.int]),
updateHash: dart.fnType(dart.void, [typed_data.Uint32List])
}));
dart.setLibraryUri(sha256._Sha32BitSink, I[218]);
dart.setFieldSignature(sha256._Sha32BitSink, () => ({
__proto__: dart.getFields(sha256._Sha32BitSink.__proto__),
[S$0._digest]: dart.finalFieldType(typed_data.Uint32List),
[S$0._extended$1]: dart.finalFieldType(typed_data.Uint32List)
}));
sha256._Sha256Sink = class _Sha256Sink extends sha256._Sha32BitSink {
get digest() {
return this[S$0._digest];
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[217], 152, 28, "sink");
return new sha256._Sha256Sink.new(sink);
}
};
(sha256._Sha256Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[217], 152, 28, "sink");
sha256._Sha256Sink.__proto__.new.call(this, sink, _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([1779033703, 3144134277, 1013904242, 2773480762, 1359893119, 2600822924, 528734635, 1541459225])));
;
}).prototype = sha256._Sha256Sink.prototype;
dart.addTypeTests(sha256._Sha256Sink);
dart.addTypeCaches(sha256._Sha256Sink);
dart.setGetterSignature(sha256._Sha256Sink, () => ({
__proto__: dart.getGetters(sha256._Sha256Sink.__proto__),
digest: typed_data.Uint32List
}));
dart.setLibraryUri(sha256._Sha256Sink, I[218]);
sha256._Sha224Sink = class _Sha224Sink extends sha256._Sha32BitSink {
get digest() {
return this[S$0._digest][S$.$buffer][S$.$asUint32List](0, 7);
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[217], 175, 28, "sink");
return new sha256._Sha224Sink.new(sink);
}
};
(sha256._Sha224Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[217], 175, 28, "sink");
sha256._Sha224Sink.__proto__.new.call(this, sink, _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([3238371032, 914150663, 812702999, 4144912697, 4290775857, 1750603025, 1694076839, 3204075428])));
;
}).prototype = sha256._Sha224Sink.prototype;
dart.addTypeTests(sha256._Sha224Sink);
dart.addTypeCaches(sha256._Sha224Sink);
dart.setGetterSignature(sha256._Sha224Sink, () => ({
__proto__: dart.getGetters(sha256._Sha224Sink.__proto__),
digest: typed_data.Uint32List
}));
dart.setLibraryUri(sha256._Sha224Sink, I[218]);
dart.defineLazy(sha256, {
/*sha256.sha256*/get sha256() {
return C[197] || CT.C197;
},
/*sha256.sha224*/get sha224() {
return C[198] || CT.C198;
},
/*sha256._noise*/get _noise() {
return C[199] || CT.C199;
}
}, false);
sha512._Sha384 = class _Sha384 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$4];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#_#tearOff']() {
return new sha512._Sha384.__();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[219], 45, 58, "sink");
return new convert._ByteAdapterSink.new(new sha512_slowsinks.Sha384Sink.new(sink));
}
};
(sha512._Sha384.__ = function() {
this[S$0.blockSize$4] = 32 * 4;
sha512._Sha384.__proto__.new.call(this);
;
}).prototype = sha512._Sha384.prototype;
dart.addTypeTests(sha512._Sha384);
dart.addTypeCaches(sha512._Sha384);
dart.setMethodSignature(sha512._Sha384, () => ({
__proto__: dart.getMethods(sha512._Sha384.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha512._Sha384, I[220]);
dart.setFieldSignature(sha512._Sha384, () => ({
__proto__: dart.getFields(sha512._Sha384.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
sha512._Sha512 = class _Sha512 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$5];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#_#tearOff']() {
return new sha512._Sha512.__();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[219], 61, 58, "sink");
return new convert._ByteAdapterSink.new(new sha512_slowsinks.Sha512Sink.new(sink));
}
};
(sha512._Sha512.__ = function() {
this[S$0.blockSize$5] = 32 * 4;
sha512._Sha512.__proto__.new.call(this);
;
}).prototype = sha512._Sha512.prototype;
dart.addTypeTests(sha512._Sha512);
dart.addTypeCaches(sha512._Sha512);
dart.setMethodSignature(sha512._Sha512, () => ({
__proto__: dart.getMethods(sha512._Sha512.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha512._Sha512, I[220]);
dart.setFieldSignature(sha512._Sha512, () => ({
__proto__: dart.getFields(sha512._Sha512.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
sha512._Sha512224 = class _Sha512224 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$6];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#new#tearOff']() {
return new sha512._Sha512224.new();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[219], 77, 58, "sink");
return new convert._ByteAdapterSink.new(new sha512_slowsinks.Sha512224Sink.new(sink));
}
};
(sha512._Sha512224.new = function() {
this[S$0.blockSize$6] = 32 * 4;
sha512._Sha512224.__proto__.new.call(this);
;
}).prototype = sha512._Sha512224.prototype;
dart.addTypeTests(sha512._Sha512224);
dart.addTypeCaches(sha512._Sha512224);
dart.setMethodSignature(sha512._Sha512224, () => ({
__proto__: dart.getMethods(sha512._Sha512224.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha512._Sha512224, I[220]);
dart.setFieldSignature(sha512._Sha512224, () => ({
__proto__: dart.getFields(sha512._Sha512224.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
sha512._Sha512256 = class _Sha512256 extends hash.Hash {
get blockSize() {
return this[S$0.blockSize$7];
}
set blockSize(value) {
super.blockSize = value;
}
static ['_#new#tearOff']() {
return new sha512._Sha512256.new();
}
startChunkedConversion(sink) {
T$0.SinkOfDigest().as(sink);
if (sink == null) dart.nullFailed(I[219], 93, 58, "sink");
return new convert._ByteAdapterSink.new(new sha512_slowsinks.Sha512256Sink.new(sink));
}
};
(sha512._Sha512256.new = function() {
this[S$0.blockSize$7] = 32 * 4;
sha512._Sha512256.__proto__.new.call(this);
;
}).prototype = sha512._Sha512256.prototype;
dart.addTypeTests(sha512._Sha512256);
dart.addTypeCaches(sha512._Sha512256);
dart.setMethodSignature(sha512._Sha512256, () => ({
__proto__: dart.getMethods(sha512._Sha512256.__proto__),
startChunkedConversion: dart.fnType(convert.ByteConversionSink, [dart.nullable(core.Object)])
}));
dart.setLibraryUri(sha512._Sha512256, I[220]);
dart.setFieldSignature(sha512._Sha512256, () => ({
__proto__: dart.getFields(sha512._Sha512256.__proto__),
blockSize: dart.finalFieldType(core.int)
}));
dart.defineLazy(sha512, {
/*sha512.sha384*/get sha384() {
return C[200] || CT.C200;
},
/*sha512.sha512*/get sha512() {
return C[201] || CT.C201;
},
/*sha512.sha512224*/get sha512224() {
return C[202] || CT.C202;
},
/*sha512.sha512256*/get sha512256() {
return C[203] || CT.C203;
}
}, false);
const _is_GuaranteeChannel_default = Symbol('_is_GuaranteeChannel_default');
guarantee_channel.GuaranteeChannel$ = dart.generic(T => {
var __t$_GuaranteeSinkOfT = () => (__t$_GuaranteeSinkOfT = dart.constFn(guarantee_channel._GuaranteeSink$(T)))();
var __t$SingleSubscriptionTransformerOfT$T = () => (__t$SingleSubscriptionTransformerOfT$T = dart.constFn(single_subscription_transformer.SingleSubscriptionTransformer$(T, T)))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class GuaranteeChannel extends stream_channel.StreamChannelMixin$(T) {
get stream() {
return this[S$0._streamController].stream;
}
get sink() {
return this[S$0._sink$6];
}
get [S$0._sink$6]() {
let t216;
return dart.test(this[S$0.__GuaranteeChannel__sink_isSet]) ? (t216 = this[S$0.__GuaranteeChannel__sink], t216) : dart.throw(new _internal.LateError.fieldNI("_sink"));
}
set [S$0._sink$6](t216) {
if (t216 == null) dart.nullFailed(I[221], 20, 32, "null");
if (dart.test(this[S$0.__GuaranteeChannel__sink_isSet]))
dart.throw(new _internal.LateError.fieldAI("_sink"));
else {
this[S$0.__GuaranteeChannel__sink_isSet] = true;
this[S$0.__GuaranteeChannel__sink] = t216;
}
}
get [S$0._streamController]() {
let t217;
return dart.test(this[S$0.__GuaranteeChannel__streamController_isSet]) ? (t217 = this[S$0.__GuaranteeChannel__streamController], t217) : dart.throw(new _internal.LateError.fieldNI("_streamController"));
}
set [S$0._streamController](t217) {
if (t217 == null) dart.nullFailed(I[221], 27, 34, "null");
if (dart.test(this[S$0.__GuaranteeChannel__streamController_isSet]))
dart.throw(new _internal.LateError.fieldAI("_streamController"));
else {
this[S$0.__GuaranteeChannel__streamController_isSet] = true;
this[S$0.__GuaranteeChannel__streamController] = t217;
}
}
static ['_#new#tearOff'](T, innerStream, innerSink, opts) {
if (innerStream == null) dart.nullFailed(I[221], 35, 30, "innerStream");
if (innerSink == null) dart.nullFailed(I[221], 35, 57, "innerSink");
let allowSinkErrors = opts && 'allowSinkErrors' in opts ? opts.allowSinkErrors : true;
if (allowSinkErrors == null) dart.nullFailed(I[221], 36, 13, "allowSinkErrors");
return new (guarantee_channel.GuaranteeChannel$(T)).new(innerStream, innerSink, {allowSinkErrors: allowSinkErrors});
}
[S$0._onSinkDisconnected]() {
this[S$0._disconnected] = true;
let subscription = this[S$0._subscription$3];
if (subscription != null) subscription.cancel();
this[S$0._streamController].close();
}
}
(GuaranteeChannel.new = function(innerStream, innerSink, opts) {
if (innerStream == null) dart.nullFailed(I[221], 35, 30, "innerStream");
if (innerSink == null) dart.nullFailed(I[221], 35, 57, "innerSink");
let allowSinkErrors = opts && 'allowSinkErrors' in opts ? opts.allowSinkErrors : true;
if (allowSinkErrors == null) dart.nullFailed(I[221], 36, 13, "allowSinkErrors");
this[S$0.__GuaranteeChannel__sink] = null;
this[S$0.__GuaranteeChannel__sink_isSet] = false;
this[S$0.__GuaranteeChannel__streamController] = null;
this[S$0.__GuaranteeChannel__streamController_isSet] = false;
this[S$0._subscription$3] = null;
this[S$0._disconnected] = false;
this[S$0._sink$6] = new (__t$_GuaranteeSinkOfT()).new(innerSink, this, {allowErrors: allowSinkErrors});
if (dart.test(innerStream.isBroadcast)) {
innerStream = innerStream.transform(T, new (__t$SingleSubscriptionTransformerOfT$T()).new());
}
this[S$0._streamController] = __t$StreamControllerOfT().new({onListen: dart.fn(() => {
if (dart.test(this[S$0._disconnected])) return;
this[S$0._subscription$3] = innerStream.listen(__t$TTovoid().as(dart.bind(this[S$0._streamController], 'add')), {onError: dart.bind(this[S$0._streamController], 'addError'), onDone: dart.fn(() => {
this[S$0._sink$6][S$0._onStreamDisconnected]();
this[S$0._streamController].close();
}, T$.VoidTovoid())});
}, T$.VoidTovoid()), sync: true});
}).prototype = GuaranteeChannel.prototype;
dart.addTypeTests(GuaranteeChannel);
GuaranteeChannel.prototype[_is_GuaranteeChannel_default] = true;
dart.addTypeCaches(GuaranteeChannel);
dart.setMethodSignature(GuaranteeChannel, () => ({
__proto__: dart.getMethods(GuaranteeChannel.__proto__),
[S$0._onSinkDisconnected]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(GuaranteeChannel, () => ({
__proto__: dart.getGetters(GuaranteeChannel.__proto__),
stream: async.Stream$(T),
sink: async.StreamSink$(T),
[S$0._sink$6]: guarantee_channel._GuaranteeSink$(T),
[S$0._streamController]: async.StreamController$(T)
}));
dart.setSetterSignature(GuaranteeChannel, () => ({
__proto__: dart.getSetters(GuaranteeChannel.__proto__),
[S$0._sink$6]: guarantee_channel._GuaranteeSink$(T),
[S$0._streamController]: async.StreamController$(T)
}));
dart.setLibraryUri(GuaranteeChannel, I[222]);
dart.setFieldSignature(GuaranteeChannel, () => ({
__proto__: dart.getFields(GuaranteeChannel.__proto__),
[S$0.__GuaranteeChannel__sink]: dart.fieldType(dart.nullable(guarantee_channel._GuaranteeSink$(T))),
[S$0.__GuaranteeChannel__sink_isSet]: dart.fieldType(core.bool),
[S$0.__GuaranteeChannel__streamController]: dart.fieldType(dart.nullable(async.StreamController$(T))),
[S$0.__GuaranteeChannel__streamController_isSet]: dart.fieldType(core.bool),
[S$0._subscription$3]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._disconnected]: dart.fieldType(core.bool)
}));
return GuaranteeChannel;
});
guarantee_channel.GuaranteeChannel = guarantee_channel.GuaranteeChannel$();
dart.addTypeTests(guarantee_channel.GuaranteeChannel, _is_GuaranteeChannel_default);
const _is__GuaranteeSink_default = Symbol('_is__GuaranteeSink_default');
guarantee_channel._GuaranteeSink$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class _GuaranteeSink extends core.Object {
get done() {
return this[S$0._doneCompleter$1].future;
}
get [S$0._inAddStream]() {
return this[S$0._addStreamSubscription] != null;
}
static ['_#new#tearOff'](T, _inner, _channel, opts) {
if (_inner == null) dart.nullFailed(I[221], 114, 23, "_inner");
if (_channel == null) dart.nullFailed(I[221], 114, 36, "_channel");
let allowErrors = opts && 'allowErrors' in opts ? opts.allowErrors : true;
if (allowErrors == null) dart.nullFailed(I[221], 114, 52, "allowErrors");
return new (guarantee_channel._GuaranteeSink$(T)).new(_inner, _channel, {allowErrors: allowErrors});
}
add(data) {
T.as(data);
if (dart.test(this[S$0._closed$5])) dart.throw(new core.StateError.new("Cannot add event after closing."));
if (dart.test(this[S$0._inAddStream])) {
dart.throw(new core.StateError.new("Cannot add event while adding stream."));
}
if (dart.test(this[S$0._disconnected])) return;
this[S$0._inner$4].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[221], 129, 17, "error");
if (dart.test(this[S$0._closed$5])) dart.throw(new core.StateError.new("Cannot add event after closing."));
if (dart.test(this[S$0._inAddStream])) {
dart.throw(new core.StateError.new("Cannot add event while adding stream."));
}
if (dart.test(this[S$0._disconnected])) return;
this[S$0._addError](error, stackTrace);
}
[S$0._addError](error, stackTrace = null) {
if (error == null) dart.nullFailed(I[221], 143, 25, "error");
if (dart.test(this[S$0._allowErrors])) {
this[S$0._inner$4].addError(error, stackTrace);
return;
}
this[S$0._doneCompleter$1].completeError(error, stackTrace);
this[S$0._onStreamDisconnected]();
this[S$0._channel$1][S$0._onSinkDisconnected]();
this[S$0._inner$4].close().catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[221], 161, 36, "stream");
if (dart.test(this[S$0._closed$5])) dart.throw(new core.StateError.new("Cannot add stream after closing."));
if (dart.test(this[S$0._inAddStream])) {
dart.throw(new core.StateError.new("Cannot add stream while adding stream."));
}
if (dart.test(this[S$0._disconnected])) return T$.FutureOfvoid().value();
this[S$0._addStreamCompleter] = async.Completer.sync();
this[S$0._addStreamSubscription] = stream.listen(__t$TTovoid().as(dart.bind(this[S$0._inner$4], 'add')), {onError: dart.bind(this, S$0._addError), onDone: T$0.FutureOrNTovoid().as(dart.bind(dart.nullCheck(this[S$0._addStreamCompleter]), 'complete'))});
return dart.nullCheck(this[S$0._addStreamCompleter]).future.then(dart.void, dart.fn(_ => {
this[S$0._addStreamCompleter] = null;
this[S$0._addStreamSubscription] = null;
}, T$.dynamicToNull()));
}
close() {
if (dart.test(this[S$0._inAddStream])) {
dart.throw(new core.StateError.new("Cannot close sink while adding stream."));
}
if (dart.test(this[S$0._closed$5])) return this.done;
this[S$0._closed$5] = true;
if (!dart.test(this[S$0._disconnected])) {
this[S$0._channel$1][S$0._onSinkDisconnected]();
this[S$0._doneCompleter$1].complete(this[S$0._inner$4].close());
}
return this.done;
}
[S$0._onStreamDisconnected]() {
this[S$0._disconnected] = true;
if (!dart.test(this[S$0._doneCompleter$1].isCompleted)) this[S$0._doneCompleter$1].complete();
if (!dart.test(this[S$0._inAddStream])) return;
dart.nullCheck(this[S$0._addStreamCompleter]).complete(dart.nullCheck(this[S$0._addStreamSubscription]).cancel());
this[S$0._addStreamCompleter] = null;
this[S$0._addStreamSubscription] = null;
}
}
(_GuaranteeSink.new = function(_inner, _channel, opts) {
if (_inner == null) dart.nullFailed(I[221], 114, 23, "_inner");
if (_channel == null) dart.nullFailed(I[221], 114, 36, "_channel");
let allowErrors = opts && 'allowErrors' in opts ? opts.allowErrors : true;
if (allowErrors == null) dart.nullFailed(I[221], 114, 52, "allowErrors");
this[S$0._doneCompleter$1] = async.Completer.new();
this[S$0._disconnected] = false;
this[S$0._closed$5] = false;
this[S$0._addStreamSubscription] = null;
this[S$0._addStreamCompleter] = null;
this[S$0._inner$4] = _inner;
this[S$0._channel$1] = _channel;
this[S$0._allowErrors] = allowErrors;
;
}).prototype = _GuaranteeSink.prototype;
dart.addTypeTests(_GuaranteeSink);
_GuaranteeSink.prototype[_is__GuaranteeSink_default] = true;
dart.addTypeCaches(_GuaranteeSink);
_GuaranteeSink[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(_GuaranteeSink, () => ({
__proto__: dart.getMethods(_GuaranteeSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
[S$0._addError]: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future$(dart.void), [dart.nullable(core.Object)]),
close: dart.fnType(async.Future$(dart.void), []),
[S$0._onStreamDisconnected]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(_GuaranteeSink, () => ({
__proto__: dart.getGetters(_GuaranteeSink.__proto__),
done: async.Future$(dart.void),
[S$0._inAddStream]: core.bool
}));
dart.setLibraryUri(_GuaranteeSink, I[222]);
dart.setFieldSignature(_GuaranteeSink, () => ({
__proto__: dart.getFields(_GuaranteeSink.__proto__),
[S$0._inner$4]: dart.finalFieldType(async.StreamSink$(T)),
[S$0._channel$1]: dart.finalFieldType(guarantee_channel.GuaranteeChannel$(T)),
[S$0._doneCompleter$1]: dart.finalFieldType(async.Completer),
[S$0._disconnected]: dart.fieldType(core.bool),
[S$0._closed$5]: dart.fieldType(core.bool),
[S$0._addStreamSubscription]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._addStreamCompleter]: dart.fieldType(dart.nullable(async.Completer)),
[S$0._allowErrors]: dart.finalFieldType(core.bool)
}));
return _GuaranteeSink;
});
guarantee_channel._GuaranteeSink = guarantee_channel._GuaranteeSink$();
dart.addTypeTests(guarantee_channel._GuaranteeSink, _is__GuaranteeSink_default);
const _is_CloseGuaranteeChannel_default = Symbol('_is_CloseGuaranteeChannel_default');
close_guarantee_channel.CloseGuaranteeChannel$ = dart.generic(T => {
var __t$_CloseGuaranteeSinkOfT = () => (__t$_CloseGuaranteeSinkOfT = dart.constFn(close_guarantee_channel._CloseGuaranteeSink$(T)))();
var __t$_CloseGuaranteeStreamOfT = () => (__t$_CloseGuaranteeStreamOfT = dart.constFn(close_guarantee_channel._CloseGuaranteeStream$(T)))();
var __t$StreamSubscriptionOfT = () => (__t$StreamSubscriptionOfT = dart.constFn(async.StreamSubscription$(T)))();
var __t$StreamSubscriptionNOfT = () => (__t$StreamSubscriptionNOfT = dart.constFn(dart.nullable(__t$StreamSubscriptionOfT())))();
class CloseGuaranteeChannel extends stream_channel.StreamChannelMixin$(T) {
get [S$0._subscription$5]() {
return this[S$0._subscription$4];
}
set [S$0._subscription$5](value) {
this[S$0._subscription$4] = __t$StreamSubscriptionNOfT().as(value);
}
get stream() {
return this[S$0._stream$2];
}
get [S$0._stream$2]() {
let t218;
return dart.test(this[S$0.__CloseGuaranteeChannel__stream_isSet]) ? (t218 = this[S$0.__CloseGuaranteeChannel__stream], t218) : dart.throw(new _internal.LateError.fieldNI("_stream"));
}
set [S$0._stream$2](t218) {
if (t218 == null) dart.nullFailed(I[223], 19, 39, "null");
if (dart.test(this[S$0.__CloseGuaranteeChannel__stream_isSet]))
dart.throw(new _internal.LateError.fieldAI("_stream"));
else {
this[S$0.__CloseGuaranteeChannel__stream_isSet] = true;
this[S$0.__CloseGuaranteeChannel__stream] = t218;
}
}
get sink() {
return this[S$0._sink$7];
}
get [S$0._sink$7]() {
let t219;
return dart.test(this[S$0.__CloseGuaranteeChannel__sink_isSet]) ? (t219 = this[S$0.__CloseGuaranteeChannel__sink], t219) : dart.throw(new _internal.LateError.fieldNI("_sink"));
}
set [S$0._sink$7](t219) {
if (t219 == null) dart.nullFailed(I[223], 23, 37, "null");
if (dart.test(this[S$0.__CloseGuaranteeChannel__sink_isSet]))
dart.throw(new _internal.LateError.fieldAI("_sink"));
else {
this[S$0.__CloseGuaranteeChannel__sink_isSet] = true;
this[S$0.__CloseGuaranteeChannel__sink] = t219;
}
}
static ['_#new#tearOff'](T, innerStream, innerSink) {
if (innerStream == null) dart.nullFailed(I[223], 31, 35, "innerStream");
if (innerSink == null) dart.nullFailed(I[223], 31, 62, "innerSink");
return new (close_guarantee_channel.CloseGuaranteeChannel$(T)).new(innerStream, innerSink);
}
}
(CloseGuaranteeChannel.new = function(innerStream, innerSink) {
if (innerStream == null) dart.nullFailed(I[223], 31, 35, "innerStream");
if (innerSink == null) dart.nullFailed(I[223], 31, 62, "innerSink");
this[S$0.__CloseGuaranteeChannel__stream] = null;
this[S$0.__CloseGuaranteeChannel__stream_isSet] = false;
this[S$0.__CloseGuaranteeChannel__sink] = null;
this[S$0.__CloseGuaranteeChannel__sink_isSet] = false;
this[S$0._subscription$4] = null;
this[S$0._disconnected$1] = false;
this[S$0._sink$7] = new (__t$_CloseGuaranteeSinkOfT()).new(innerSink, this);
this[S$0._stream$2] = new (__t$_CloseGuaranteeStreamOfT()).new(innerStream, this);
}).prototype = CloseGuaranteeChannel.prototype;
dart.addTypeTests(CloseGuaranteeChannel);
CloseGuaranteeChannel.prototype[_is_CloseGuaranteeChannel_default] = true;
dart.addTypeCaches(CloseGuaranteeChannel);
dart.setGetterSignature(CloseGuaranteeChannel, () => ({
__proto__: dart.getGetters(CloseGuaranteeChannel.__proto__),
stream: async.Stream$(T),
[S$0._stream$2]: close_guarantee_channel._CloseGuaranteeStream$(T),
sink: async.StreamSink$(T),
[S$0._sink$7]: close_guarantee_channel._CloseGuaranteeSink$(T)
}));
dart.setSetterSignature(CloseGuaranteeChannel, () => ({
__proto__: dart.getSetters(CloseGuaranteeChannel.__proto__),
[S$0._stream$2]: close_guarantee_channel._CloseGuaranteeStream$(T),
[S$0._sink$7]: close_guarantee_channel._CloseGuaranteeSink$(T)
}));
dart.setLibraryUri(CloseGuaranteeChannel, I[224]);
dart.setFieldSignature(CloseGuaranteeChannel, () => ({
__proto__: dart.getFields(CloseGuaranteeChannel.__proto__),
[S$0.__CloseGuaranteeChannel__stream]: dart.fieldType(dart.nullable(close_guarantee_channel._CloseGuaranteeStream$(T))),
[S$0.__CloseGuaranteeChannel__stream_isSet]: dart.fieldType(core.bool),
[S$0.__CloseGuaranteeChannel__sink]: dart.fieldType(dart.nullable(close_guarantee_channel._CloseGuaranteeSink$(T))),
[S$0.__CloseGuaranteeChannel__sink_isSet]: dart.fieldType(core.bool),
[S$0._subscription$5]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._disconnected$1]: dart.fieldType(core.bool)
}));
return CloseGuaranteeChannel;
});
close_guarantee_channel.CloseGuaranteeChannel = close_guarantee_channel.CloseGuaranteeChannel$();
dart.addTypeTests(close_guarantee_channel.CloseGuaranteeChannel, _is_CloseGuaranteeChannel_default);
const _is__CloseGuaranteeStream_default = Symbol('_is__CloseGuaranteeStream_default');
close_guarantee_channel._CloseGuaranteeStream$ = dart.generic(T => {
class _CloseGuaranteeStream extends async.Stream$(T) {
static ['_#new#tearOff'](T, _inner, _channel) {
if (_inner == null) dart.nullFailed(I[223], 48, 30, "_inner");
if (_channel == null) dart.nullFailed(I[223], 48, 43, "_channel");
return new (close_guarantee_channel._CloseGuaranteeStream$(T)).new(_inner, _channel);
}
listen(onData, opts) {
let onError = opts && 'onError' in opts ? opts.onError : null;
let onDone = opts && 'onDone' in opts ? opts.onDone : null;
let cancelOnError = opts && 'cancelOnError' in opts ? opts.cancelOnError : null;
if (dart.test(this[S$0._channel$2][S$0._disconnected$1])) {
onData = null;
onError = null;
}
let subscription = this[S$0._inner$5].listen(onData, {onError: onError, onDone: onDone, cancelOnError: cancelOnError});
if (!dart.test(this[S$0._channel$2][S$0._disconnected$1])) {
this[S$0._channel$2][S$0._subscription$5] = subscription;
}
return subscription;
}
}
(_CloseGuaranteeStream.new = function(_inner, _channel) {
if (_inner == null) dart.nullFailed(I[223], 48, 30, "_inner");
if (_channel == null) dart.nullFailed(I[223], 48, 43, "_channel");
this[S$0._inner$5] = _inner;
this[S$0._channel$2] = _channel;
_CloseGuaranteeStream.__proto__.new.call(this);
;
}).prototype = _CloseGuaranteeStream.prototype;
dart.addTypeTests(_CloseGuaranteeStream);
_CloseGuaranteeStream.prototype[_is__CloseGuaranteeStream_default] = true;
dart.addTypeCaches(_CloseGuaranteeStream);
dart.setMethodSignature(_CloseGuaranteeStream, () => ({
__proto__: dart.getMethods(_CloseGuaranteeStream.__proto__),
listen: dart.fnType(async.StreamSubscription$(T), [dart.nullable(dart.fnType(dart.void, [T]))], {cancelOnError: dart.nullable(core.bool), onDone: dart.nullable(dart.fnType(dart.void, [])), onError: dart.nullable(core.Function)}, {})
}));
dart.setLibraryUri(_CloseGuaranteeStream, I[224]);
dart.setFieldSignature(_CloseGuaranteeStream, () => ({
__proto__: dart.getFields(_CloseGuaranteeStream.__proto__),
[S$0._inner$5]: dart.finalFieldType(async.Stream$(T)),
[S$0._channel$2]: dart.finalFieldType(close_guarantee_channel.CloseGuaranteeChannel$(T))
}));
return _CloseGuaranteeStream;
});
close_guarantee_channel._CloseGuaranteeStream = close_guarantee_channel._CloseGuaranteeStream$();
dart.addTypeTests(close_guarantee_channel._CloseGuaranteeStream, _is__CloseGuaranteeStream_default);
const _is__CloseGuaranteeSink_default = Symbol('_is__CloseGuaranteeSink_default');
close_guarantee_channel._CloseGuaranteeSink$ = dart.generic(T => {
class _CloseGuaranteeSink extends stream_sink.DelegatingStreamSink$(T) {
static ['_#new#tearOff'](T, inner, _channel) {
if (inner == null) dart.nullFailed(I[223], 77, 37, "inner");
if (_channel == null) dart.nullFailed(I[223], 77, 49, "_channel");
return new (close_guarantee_channel._CloseGuaranteeSink$(T)).new(inner, _channel);
}
close() {
let done = super.close();
this[S$0._channel$2][S$0._disconnected$1] = true;
let subscription = this[S$0._channel$2][S$0._subscription$5];
if (subscription != null) {
subscription.onData(null);
subscription.onError(null);
}
return done;
}
}
(_CloseGuaranteeSink.new = function(inner, _channel) {
if (inner == null) dart.nullFailed(I[223], 77, 37, "inner");
if (_channel == null) dart.nullFailed(I[223], 77, 49, "_channel");
this[S$0._channel$2] = _channel;
_CloseGuaranteeSink.__proto__.new.call(this, inner);
;
}).prototype = _CloseGuaranteeSink.prototype;
dart.addTypeTests(_CloseGuaranteeSink);
_CloseGuaranteeSink.prototype[_is__CloseGuaranteeSink_default] = true;
dart.addTypeCaches(_CloseGuaranteeSink);
dart.setMethodSignature(_CloseGuaranteeSink, () => ({
__proto__: dart.getMethods(_CloseGuaranteeSink.__proto__),
close: dart.fnType(async.Future$(dart.void), [])
}));
dart.setLibraryUri(_CloseGuaranteeSink, I[224]);
dart.setFieldSignature(_CloseGuaranteeSink, () => ({
__proto__: dart.getFields(_CloseGuaranteeSink.__proto__),
[S$0._channel$2]: dart.finalFieldType(close_guarantee_channel.CloseGuaranteeChannel$(T))
}));
return _CloseGuaranteeSink;
});
close_guarantee_channel._CloseGuaranteeSink = close_guarantee_channel._CloseGuaranteeSink$();
dart.addTypeTests(close_guarantee_channel._CloseGuaranteeSink, _is__CloseGuaranteeSink_default);
const _is_StreamChannelTransformer_default = Symbol('_is_StreamChannelTransformer_default');
stream_channel_transformer.StreamChannelTransformer$ = dart.generic((S, T) => {
var __t$StreamTransformerWrapperOfS$T = () => (__t$StreamTransformerWrapperOfS$T = dart.constFn(stream_transformer_wrapper.StreamTransformerWrapper$(S, T)))();
var __t$StreamChannelOfS = () => (__t$StreamChannelOfS = dart.constFn(stream_channel.StreamChannel$(S)))();
var __t$StreamChannelOfT = () => (__t$StreamChannelOfT = dart.constFn(stream_channel.StreamChannel$(T)))();
class StreamChannelTransformer extends core.Object {
get [S$0._streamTransformer$1]() {
return this[S$0._streamTransformer];
}
set [S$0._streamTransformer$1](value) {
super[S$0._streamTransformer$1] = value;
}
get [S$0._sinkTransformer$1]() {
return this[S$0._sinkTransformer];
}
set [S$0._sinkTransformer$1](value) {
super[S$0._sinkTransformer$1] = value;
}
static ['_#new#tearOff'](S, T, _streamTransformer, _sinkTransformer) {
if (_streamTransformer == null) dart.nullFailed(I[225], 37, 12, "_streamTransformer");
if (_sinkTransformer == null) dart.nullFailed(I[225], 37, 37, "_sinkTransformer");
return new (stream_channel_transformer.StreamChannelTransformer$(S, T)).new(_streamTransformer, _sinkTransformer);
}
static ['_#fromCodec#tearOff'](S, T, codec) {
if (codec == null) dart.nullFailed(I[225], 43, 50, "codec");
return new (stream_channel_transformer.StreamChannelTransformer$(S, T)).fromCodec(codec);
}
bind(channel) {
__t$StreamChannelOfT().as(channel);
if (channel == null) dart.nullFailed(I[225], 54, 42, "channel");
return __t$StreamChannelOfS().withCloseGuarantee(channel.stream.transform(S, this[S$0._streamTransformer$1]), this[S$0._sinkTransformer$1].bind(channel.sink));
}
}
(StreamChannelTransformer.new = function(_streamTransformer, _sinkTransformer) {
if (_streamTransformer == null) dart.nullFailed(I[225], 37, 12, "_streamTransformer");
if (_sinkTransformer == null) dart.nullFailed(I[225], 37, 37, "_sinkTransformer");
this[S$0._streamTransformer] = _streamTransformer;
this[S$0._sinkTransformer] = _sinkTransformer;
;
}).prototype = StreamChannelTransformer.prototype;
(StreamChannelTransformer.fromCodec = function(codec) {
if (codec == null) dart.nullFailed(I[225], 43, 50, "codec");
StreamChannelTransformer.new.call(this, codec.decoder, new (__t$StreamTransformerWrapperOfS$T()).new(codec.encoder));
}).prototype = StreamChannelTransformer.prototype;
dart.addTypeTests(StreamChannelTransformer);
StreamChannelTransformer.prototype[_is_StreamChannelTransformer_default] = true;
dart.addTypeCaches(StreamChannelTransformer);
dart.setMethodSignature(StreamChannelTransformer, () => ({
__proto__: dart.getMethods(StreamChannelTransformer.__proto__),
bind: dart.fnType(stream_channel.StreamChannel$(S), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(StreamChannelTransformer, I[226]);
dart.setFieldSignature(StreamChannelTransformer, () => ({
__proto__: dart.getFields(StreamChannelTransformer.__proto__),
[S$0._streamTransformer$1]: dart.finalFieldType(async.StreamTransformer$(T, S)),
[S$0._sinkTransformer$1]: dart.finalFieldType(stream_sink_transformer.StreamSinkTransformer$(S, T))
}));
return StreamChannelTransformer;
});
stream_channel_transformer.StreamChannelTransformer = stream_channel_transformer.StreamChannelTransformer$();
dart.addTypeTests(stream_channel_transformer.StreamChannelTransformer, _is_StreamChannelTransformer_default);
const _is_DelegatingStreamChannel_default = Symbol('_is_DelegatingStreamChannel_default');
delegating_stream_channel.DelegatingStreamChannel$ = dart.generic(T => {
class DelegatingStreamChannel extends stream_channel.StreamChannelMixin$(T) {
get stream() {
return this[S$0._inner$6].stream;
}
get sink() {
return this[S$0._inner$6].sink;
}
static ['_#new#tearOff'](T, _inner) {
if (_inner == null) dart.nullFailed(I[227], 22, 32, "_inner");
return new (delegating_stream_channel.DelegatingStreamChannel$(T)).new(_inner);
}
}
(DelegatingStreamChannel.new = function(_inner) {
if (_inner == null) dart.nullFailed(I[227], 22, 32, "_inner");
this[S$0._inner$6] = _inner;
;
}).prototype = DelegatingStreamChannel.prototype;
dart.addTypeTests(DelegatingStreamChannel);
DelegatingStreamChannel.prototype[_is_DelegatingStreamChannel_default] = true;
dart.addTypeCaches(DelegatingStreamChannel);
dart.setGetterSignature(DelegatingStreamChannel, () => ({
__proto__: dart.getGetters(DelegatingStreamChannel.__proto__),
stream: async.Stream$(T),
sink: async.StreamSink$(T)
}));
dart.setLibraryUri(DelegatingStreamChannel, I[228]);
dart.setFieldSignature(DelegatingStreamChannel, () => ({
__proto__: dart.getFields(DelegatingStreamChannel.__proto__),
[S$0._inner$6]: dart.finalFieldType(stream_channel.StreamChannel$(T))
}));
return DelegatingStreamChannel;
});
delegating_stream_channel.DelegatingStreamChannel = delegating_stream_channel.DelegatingStreamChannel$();
dart.addTypeTests(delegating_stream_channel.DelegatingStreamChannel, _is_DelegatingStreamChannel_default);
const _is_Disconnector_default = Symbol('_is_Disconnector_default');
disconnector.Disconnector$ = dart.generic(T => {
var __t$_DisconnectorSinkOfT = () => (__t$_DisconnectorSinkOfT = dart.constFn(disconnector._DisconnectorSink$(T)))();
var __t$JSArrayOf_DisconnectorSinkOfT = () => (__t$JSArrayOf_DisconnectorSinkOfT = dart.constFn(_interceptors.JSArray$(__t$_DisconnectorSinkOfT())))();
var __t$_DisconnectorSinkOfTToFutureOfvoid = () => (__t$_DisconnectorSinkOfTToFutureOfvoid = dart.constFn(dart.fnType(T$.FutureOfvoid(), [__t$_DisconnectorSinkOfT()])))();
var __t$StreamChannelOfT = () => (__t$StreamChannelOfT = dart.constFn(stream_channel.StreamChannel$(T)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
var __t$StreamSinkOfTTo_DisconnectorSinkOfT = () => (__t$StreamSinkOfTTo_DisconnectorSinkOfT = dart.constFn(dart.fnType(__t$_DisconnectorSinkOfT(), [__t$StreamSinkOfT()])))();
var __t$StreamSinkTransformerOfT$T = () => (__t$StreamSinkTransformerOfT$T = dart.constFn(stream_sink_transformer.StreamSinkTransformer$(T, T)))();
var __t$StreamTransformerOfT$T = () => (__t$StreamTransformerOfT$T = dart.constFn(async.StreamTransformer$(T, T)))();
class Disconnector extends core.Object {
get isDisconnected() {
return this[S$0._disconnectMemo].hasRun;
}
disconnect() {
return this[S$0._disconnectMemo].runOnce(dart.fn(() => {
let futures = this[S$0._sinks][S$.$map](T$.FutureOfvoid(), dart.fn(sink => {
if (sink == null) dart.nullFailed(I[229], 37, 35, "sink");
return sink[S$0._disconnect]();
}, __t$_DisconnectorSinkOfTToFutureOfvoid()))[S$.$toList]();
this[S$0._sinks][S$.$clear]();
return async.Future.wait(dart.void, futures, {eagerError: true});
}, T$0.VoidToFutureOfListOfvoid()));
}
bind(channel) {
__t$StreamChannelOfT().as(channel);
if (channel == null) dart.nullFailed(I[229], 44, 42, "channel");
return channel.changeSink(dart.fn(innerSink => {
if (innerSink == null) dart.nullFailed(I[229], 45, 32, "innerSink");
let sink = new (__t$_DisconnectorSinkOfT()).new(innerSink);
if (dart.test(this.isDisconnected)) {
sink[S$0._disconnect]().catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
} else {
this[S$0._sinks][S$.$add](sink);
}
return sink;
}, __t$StreamSinkOfTTo_DisconnectorSinkOfT()));
}
static ['_#new#tearOff'](T) {
return new (disconnector.Disconnector$(T)).new();
}
get [S$0._sinkTransformer$1]() {
return __t$StreamSinkTransformerOfT$T().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[204] || CT.C204)));
}
get [S$0._streamTransformer$1]() {
return __t$StreamTransformerOfT$T().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[205] || CT.C205)));
}
}
(Disconnector.new = function() {
this[S$0._sinks] = __t$JSArrayOf_DisconnectorSinkOfT().of([]);
this[S$0._disconnectMemo] = new async_memoizer.AsyncMemoizer.new();
;
}).prototype = Disconnector.prototype;
dart.addTypeTests(Disconnector);
Disconnector.prototype[_is_Disconnector_default] = true;
dart.addTypeCaches(Disconnector);
Disconnector[dart.implements] = () => [stream_channel_transformer.StreamChannelTransformer$(T, T)];
dart.setMethodSignature(Disconnector, () => ({
__proto__: dart.getMethods(Disconnector.__proto__),
disconnect: dart.fnType(async.Future$(dart.void), []),
bind: dart.fnType(stream_channel.StreamChannel$(T), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(Disconnector, () => ({
__proto__: dart.getGetters(Disconnector.__proto__),
isDisconnected: core.bool,
[S$0._sinkTransformer$1]: stream_sink_transformer.StreamSinkTransformer$(T, T),
[S$0._streamTransformer$1]: async.StreamTransformer$(T, T)
}));
dart.setLibraryUri(Disconnector, I[230]);
dart.setFieldSignature(Disconnector, () => ({
__proto__: dart.getFields(Disconnector.__proto__),
[S$0._sinks]: dart.finalFieldType(core.List$(disconnector._DisconnectorSink$(T))),
[S$0._disconnectMemo]: dart.finalFieldType(async_memoizer.AsyncMemoizer)
}));
return Disconnector;
});
disconnector.Disconnector = disconnector.Disconnector$();
dart.addTypeTests(disconnector.Disconnector, _is_Disconnector_default);
const _is__DisconnectorSink_default = Symbol('_is__DisconnectorSink_default');
disconnector._DisconnectorSink$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class _DisconnectorSink extends core.Object {
get done() {
return this[S$0._inner$7].done;
}
get [S$0._inAddStream$1]() {
return this[S$0._addStreamSubscription$1] != null;
}
static ['_#new#tearOff'](T, _inner) {
if (_inner == null) dart.nullFailed(I[229], 86, 26, "_inner");
return new (disconnector._DisconnectorSink$(T)).new(_inner);
}
add(data) {
T.as(data);
if (dart.test(this[S$0._closed$6])) dart.throw(new core.StateError.new("Cannot add event after closing."));
if (dart.test(this[S$0._inAddStream$1])) {
dart.throw(new core.StateError.new("Cannot add event while adding stream."));
}
if (dart.test(this[S$0._isDisconnected])) return;
this[S$0._inner$7].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[229], 100, 17, "error");
if (dart.test(this[S$0._closed$6])) dart.throw(new core.StateError.new("Cannot add event after closing."));
if (dart.test(this[S$0._inAddStream$1])) {
dart.throw(new core.StateError.new("Cannot add event while adding stream."));
}
if (dart.test(this[S$0._isDisconnected])) return;
this[S$0._inner$7].addError(error, stackTrace);
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[229], 111, 36, "stream");
if (dart.test(this[S$0._closed$6])) dart.throw(new core.StateError.new("Cannot add stream after closing."));
if (dart.test(this[S$0._inAddStream$1])) {
dart.throw(new core.StateError.new("Cannot add stream while adding stream."));
}
if (dart.test(this[S$0._isDisconnected])) return T$.FutureOfvoid().value();
this[S$0._addStreamCompleter$1] = async.Completer.sync();
this[S$0._addStreamSubscription$1] = stream.listen(__t$TTovoid().as(dart.bind(this[S$0._inner$7], 'add')), {onError: dart.bind(this[S$0._inner$7], 'addError'), onDone: T$0.FutureOrNTovoid().as(dart.bind(dart.nullCheck(this[S$0._addStreamCompleter$1]), 'complete'))});
return dart.nullCheck(this[S$0._addStreamCompleter$1]).future.then(dart.void, dart.fn(_ => {
this[S$0._addStreamCompleter$1] = null;
this[S$0._addStreamSubscription$1] = null;
}, T$.dynamicToNull()));
}
close() {
if (dart.test(this[S$0._inAddStream$1])) {
dart.throw(new core.StateError.new("Cannot close sink while adding stream."));
}
this[S$0._closed$6] = true;
return this[S$0._inner$7].close();
}
[S$0._disconnect]() {
this[S$0._isDisconnected] = true;
let future = this[S$0._inner$7].close();
if (dart.test(this[S$0._inAddStream$1])) {
dart.nullCheck(this[S$0._addStreamCompleter$1]).complete(dart.nullCheck(this[S$0._addStreamSubscription$1]).cancel());
this[S$0._addStreamCompleter$1] = null;
this[S$0._addStreamSubscription$1] = null;
}
return future;
}
}
(_DisconnectorSink.new = function(_inner) {
if (_inner == null) dart.nullFailed(I[229], 86, 26, "_inner");
this[S$0._isDisconnected] = false;
this[S$0._closed$6] = false;
this[S$0._addStreamSubscription$1] = null;
this[S$0._addStreamCompleter$1] = null;
this[S$0._inner$7] = _inner;
;
}).prototype = _DisconnectorSink.prototype;
dart.addTypeTests(_DisconnectorSink);
_DisconnectorSink.prototype[_is__DisconnectorSink_default] = true;
dart.addTypeCaches(_DisconnectorSink);
_DisconnectorSink[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(_DisconnectorSink, () => ({
__proto__: dart.getMethods(_DisconnectorSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future$(dart.void), [dart.nullable(core.Object)]),
close: dart.fnType(async.Future$(dart.void), []),
[S$0._disconnect]: dart.fnType(async.Future$(dart.void), [])
}));
dart.setGetterSignature(_DisconnectorSink, () => ({
__proto__: dart.getGetters(_DisconnectorSink.__proto__),
done: async.Future$(dart.void),
[S$0._inAddStream$1]: core.bool
}));
dart.setLibraryUri(_DisconnectorSink, I[230]);
dart.setFieldSignature(_DisconnectorSink, () => ({
__proto__: dart.getFields(_DisconnectorSink.__proto__),
[S$0._inner$7]: dart.finalFieldType(async.StreamSink$(T)),
[S$0._isDisconnected]: dart.fieldType(core.bool),
[S$0._closed$6]: dart.fieldType(core.bool),
[S$0._addStreamSubscription$1]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._addStreamCompleter$1]: dart.fieldType(dart.nullable(async.Completer))
}));
return _DisconnectorSink;
});
disconnector._DisconnectorSink = disconnector._DisconnectorSink$();
dart.addTypeTests(disconnector._DisconnectorSink, _is__DisconnectorSink_default);
json_document_transformer._JsonDocument = class _JsonDocument extends core.Object {
static ['_#new#tearOff']() {
return new json_document_transformer._JsonDocument.new();
}
bind(channel) {
T$0.StreamChannelOfString().as(channel);
if (channel == null) dart.nullFailed(I[231], 28, 53, "channel");
let stream = channel.stream.map(dart.dynamic, C[206] || CT.C206);
let sink = T$0.StreamSinkTransformerOfObject$String().fromHandlers({handleData: dart.fn((data, sink) => {
if (data == null) dart.nullFailed(I[231], 31, 22, "data");
if (sink == null) dart.nullFailed(I[231], 31, 28, "sink");
sink.add(convert.jsonEncode(data));
}, T$0.ObjectAndEventSinkOfStringTovoid())}).bind(channel.sink);
return T$0.StreamChannelOfObjectN().withCloseGuarantee(stream, sink);
}
get [S$0._sinkTransformer$1]() {
return T$0.StreamSinkTransformerOfObjectN$String().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[207] || CT.C207)));
}
get [S$0._streamTransformer$1]() {
return T$0.StreamTransformerOfString$ObjectN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[208] || CT.C208)));
}
};
(json_document_transformer._JsonDocument.new = function() {
;
}).prototype = json_document_transformer._JsonDocument.prototype;
dart.addTypeTests(json_document_transformer._JsonDocument);
dart.addTypeCaches(json_document_transformer._JsonDocument);
json_document_transformer._JsonDocument[dart.implements] = () => [stream_channel_transformer.StreamChannelTransformer$(dart.nullable(core.Object), core.String)];
dart.setMethodSignature(json_document_transformer._JsonDocument, () => ({
__proto__: dart.getMethods(json_document_transformer._JsonDocument.__proto__),
bind: dart.fnType(stream_channel.StreamChannel$(dart.nullable(core.Object)), [dart.nullable(core.Object)])
}));
dart.setGetterSignature(json_document_transformer._JsonDocument, () => ({
__proto__: dart.getGetters(json_document_transformer._JsonDocument.__proto__),
[S$0._sinkTransformer$1]: stream_sink_transformer.StreamSinkTransformer$(dart.nullable(core.Object), core.String),
[S$0._streamTransformer$1]: async.StreamTransformer$(core.String, dart.nullable(core.Object))
}));
dart.setLibraryUri(json_document_transformer._JsonDocument, I[232]);
dart.defineLazy(json_document_transformer, {
/*json_document_transformer.jsonDocument*/get jsonDocument() {
return C[209] || CT.C209;
}
}, false);
const _is_MultiChannel_default = Symbol('_is_MultiChannel_default');
multi_channel.MultiChannel$ = dart.generic(T => {
class MultiChannel extends core.Object {
static new(inner) {
if (inner == null) dart.nullFailed(I[233], 63, 47, "inner");
return new (multi_channel._MultiChannel$(T)).new(inner);
}
static ['_#new#tearOff'](T, inner) {
if (inner == null) dart.nullFailed(I[233], 63, 47, "inner");
return multi_channel.MultiChannel$(T).new(inner);
}
}
(MultiChannel[dart.mixinNew] = function() {
}).prototype = MultiChannel.prototype;
dart.addTypeTests(MultiChannel);
MultiChannel.prototype[_is_MultiChannel_default] = true;
dart.addTypeCaches(MultiChannel);
MultiChannel[dart.implements] = () => [stream_channel.StreamChannel$(T)];
dart.setStaticMethodSignature(MultiChannel, () => ['new']);
dart.setLibraryUri(MultiChannel, I[234]);
return MultiChannel;
});
multi_channel.MultiChannel = multi_channel.MultiChannel$();
dart.addTypeTests(multi_channel.MultiChannel, _is_MultiChannel_default);
const _is__MultiChannel_default = Symbol('_is__MultiChannel_default');
multi_channel._MultiChannel$ = dart.generic(T => {
var __t$StreamChannelControllerOfT = () => (__t$StreamChannelControllerOfT = dart.constFn(stream_channel_controller.StreamChannelController$(T)))();
var __t$IdentityMapOfint$StreamChannelControllerOfT = () => (__t$IdentityMapOfint$StreamChannelControllerOfT = dart.constFn(_js_helper.IdentityMap$(core.int, __t$StreamChannelControllerOfT())))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
var __t$VoidToStreamChannelControllerOfT = () => (__t$VoidToStreamChannelControllerOfT = dart.constFn(dart.fnType(__t$StreamChannelControllerOfT(), [])))();
var __t$VirtualChannelOfT = () => (__t$VirtualChannelOfT = dart.constFn(multi_channel.VirtualChannel$(T)))();
var __t$_EmptyStreamOfT = () => (__t$_EmptyStreamOfT = dart.constFn(async._EmptyStream$(T)))();
var __t$NullStreamSinkOfT = () => (__t$NullStreamSinkOfT = dart.constFn(null_stream_sink.NullStreamSink$(T)))();
var __t$StreamChannelControllerOfTTodynamic = () => (__t$StreamChannelControllerOfTTodynamic = dart.constFn(dart.fnType(dart.dynamic, [__t$StreamChannelControllerOfT()])))();
class _MultiChannel extends stream_channel.StreamChannelMixin$(T) {
get stream() {
return this[S$0._mainController].foreign.stream;
}
get sink() {
return this[S$0._mainController].foreign.sink;
}
static ['_#new#tearOff'](T, inner) {
if (inner == null) dart.nullFailed(I[233], 135, 40, "inner");
return new (multi_channel._MultiChannel$(T)).new(inner);
}
virtualChannel(id = null) {
let inputId = null;
let outputId = null;
if (id != null) {
inputId = id;
outputId = dart.notNull(id) + 1;
} else {
inputId = dart.notNull(this[S$0._nextId]) + 1;
outputId = this[S$0._nextId];
this[S$0._nextId] = dart.notNull(this[S$0._nextId]) + 2;
}
if (this[S$0._inner$8] == null) {
return new (__t$VirtualChannelOfT()).__(this, inputId, new (__t$_EmptyStreamOfT()).new(), new (__t$NullStreamSinkOfT()).new());
}
let controller = null;
let controller$35isSet = false;
function controller$35get() {
return controller$35isSet ? controller : dart.throw(new _internal.LateError.localNI("controller"));
}
dart.fn(controller$35get, __t$VoidToStreamChannelControllerOfT());
function controller$35set(t223) {
if (t223 == null) dart.nullFailed(I[233], 197, 37, "null");
controller$35isSet = true;
return controller = t223;
}
dart.fn(controller$35set, __t$StreamChannelControllerOfTTodynamic());
if (dart.test(this[S$0._pendingIds].remove(inputId))) {
controller$35set(dart.nullCheck(this[S$0._controllers$2][S$.$_get](inputId)));
} else if (dart.test(this[S$0._controllers$2][S$.$containsKey](inputId)) || dart.test(this[S$0._closedIds].contains(inputId))) {
dart.throw(new core.ArgumentError.new("A virtual channel with id " + dart.str(id) + " already exists."));
} else {
controller$35set(new (__t$StreamChannelControllerOfT()).new({sync: true}));
this[S$0._controllers$2][S$.$_set](inputId, controller$35get());
}
controller$35get().local.stream.listen(dart.fn(message => dart.nullCheck(this[S$0._inner$8]).sink.add(T$0.JSArrayOfObjectN().of([outputId, message])), __t$TTovoid()), {onDone: dart.fn(() => this[S$0._closeChannel](inputId, outputId), T$.VoidTovoid())});
return new (__t$VirtualChannelOfT()).__(this, outputId, controller$35get().foreign.stream, controller$35get().foreign.sink);
}
[S$0._closeChannel](inputId, outputId) {
if (inputId == null) dart.nullFailed(I[233], 219, 26, "inputId");
if (outputId == null) dart.nullFailed(I[233], 219, 39, "outputId");
this[S$0._closedIds].add(inputId);
let controller = dart.nullCheck(this[S$0._controllers$2][S$.$remove](inputId));
controller.local.sink.close();
if (this[S$0._inner$8] == null) return;
dart.nullCheck(this[S$0._inner$8]).sink.add(T$.JSArrayOfint().of([outputId]));
if (dart.test(this[S$0._controllers$2][S$.$isEmpty])) this[S$0._closeInnerChannel]();
}
[S$0._closeInnerChannel]() {
dart.nullCheck(this[S$0._inner$8]).sink.close();
dart.nullCheck(this[S$0._innerStreamSubscription]).cancel();
this[S$0._inner$8] = null;
for (let controller of core.List.from(this[S$0._controllers$2][S$.$values])) {
dart.dsend(dart.dload(dart.dload(controller, 'local'), 'sink'), 'close', []);
}
this[S$0._controllers$2][S$.$clear]();
}
}
(_MultiChannel.new = function(inner) {
if (inner == null) dart.nullFailed(I[233], 135, 40, "inner");
this[S$0._innerStreamSubscription] = null;
this[S$0._mainController] = new (__t$StreamChannelControllerOfT()).new({sync: true});
this[S$0._controllers$2] = new (__t$IdentityMapOfint$StreamChannelControllerOfT()).new();
this[S$0._pendingIds] = T$0.LinkedHashSetOfint().new();
this[S$0._closedIds] = T$0.LinkedHashSetOfint().new();
this[S$0._nextId] = 1;
this[S$0._inner$8] = inner;
this[S$0._controllers$2][S$.$_set](0, this[S$0._mainController]);
this[S$0._mainController].local.stream.listen(dart.fn(message => dart.nullCheck(this[S$0._inner$8]).sink.add(T$0.JSArrayOfObjectN().of([0, message])), __t$TTovoid()), {onDone: dart.fn(() => this[S$0._closeChannel](0, 0), T$.VoidTovoid())});
this[S$0._innerStreamSubscription] = dart.nullCheck(this[S$0._inner$8]).stream.cast(core.List).listen(dart.fn(message => {
if (message == null) dart.nullFailed(I[233], 143, 68, "message");
let id = core.int.as(message[S$.$_get](0));
if (dart.test(this[S$0._closedIds].contains(id))) return;
let controller = this[S$0._controllers$2][S$.$putIfAbsent](id, dart.fn(() => {
this[S$0._pendingIds].add(id);
return new (__t$StreamChannelControllerOfT()).new({sync: true});
}, __t$VoidToStreamChannelControllerOfT()));
if (dart.notNull(message[S$.$length]) > 1) {
controller.local.sink.add(T.as(message[S$.$_get](1)));
} else {
controller.local.sink.close();
}
}, T$0.ListTovoid()), {onDone: dart.bind(this, S$0._closeInnerChannel), onError: dart.bind(this[S$0._mainController].local.sink, 'addError')});
}).prototype = _MultiChannel.prototype;
dart.addTypeTests(_MultiChannel);
_MultiChannel.prototype[_is__MultiChannel_default] = true;
dart.addTypeCaches(_MultiChannel);
_MultiChannel[dart.implements] = () => [multi_channel.MultiChannel$(T)];
dart.setMethodSignature(_MultiChannel, () => ({
__proto__: dart.getMethods(_MultiChannel.__proto__),
virtualChannel: dart.fnType(multi_channel.VirtualChannel$(T), [], [dart.nullable(core.int)]),
[S$0._closeChannel]: dart.fnType(dart.void, [core.int, core.int]),
[S$0._closeInnerChannel]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(_MultiChannel, () => ({
__proto__: dart.getGetters(_MultiChannel.__proto__),
stream: async.Stream$(T),
sink: async.StreamSink$(T)
}));
dart.setLibraryUri(_MultiChannel, I[234]);
dart.setFieldSignature(_MultiChannel, () => ({
__proto__: dart.getFields(_MultiChannel.__proto__),
[S$0._inner$8]: dart.fieldType(dart.nullable(stream_channel.StreamChannel)),
[S$0._innerStreamSubscription]: dart.fieldType(dart.nullable(async.StreamSubscription)),
[S$0._mainController]: dart.finalFieldType(stream_channel_controller.StreamChannelController$(T)),
[S$0._controllers$2]: dart.finalFieldType(core.Map$(core.int, stream_channel_controller.StreamChannelController$(T))),
[S$0._pendingIds]: dart.finalFieldType(core.Set$(core.int)),
[S$0._closedIds]: dart.finalFieldType(core.Set$(core.int)),
[S$0._nextId]: dart.fieldType(core.int)
}));
return _MultiChannel;
});
multi_channel._MultiChannel = multi_channel._MultiChannel$();
dart.addTypeTests(multi_channel._MultiChannel, _is__MultiChannel_default);
const _is_VirtualChannel_default = Symbol('_is_VirtualChannel_default');
multi_channel.VirtualChannel$ = dart.generic(T => {
class VirtualChannel extends stream_channel.StreamChannelMixin$(T) {
get id() {
return this[S$0.id$2];
}
set id(value) {
super.id = value;
}
get stream() {
return this[S$0.stream];
}
set stream(value) {
super.stream = value;
}
get sink() {
return this[S$0.sink$1];
}
set sink(value) {
super.sink = value;
}
static ['_#_#tearOff'](T, _parent, id, stream, sink) {
if (_parent == null) dart.nullFailed(I[233], 269, 25, "_parent");
if (id == null) dart.nullFailed(I[233], 269, 39, "id");
if (stream == null) dart.nullFailed(I[233], 269, 48, "stream");
if (sink == null) dart.nullFailed(I[233], 269, 61, "sink");
return new (multi_channel.VirtualChannel$(T)).__(_parent, id, stream, sink);
}
virtualChannel(id = null) {
return this[S$0._parent$1].virtualChannel(id);
}
}
(VirtualChannel.__ = function(_parent, id, stream, sink) {
if (_parent == null) dart.nullFailed(I[233], 269, 25, "_parent");
if (id == null) dart.nullFailed(I[233], 269, 39, "id");
if (stream == null) dart.nullFailed(I[233], 269, 48, "stream");
if (sink == null) dart.nullFailed(I[233], 269, 61, "sink");
this[S$0._parent$1] = _parent;
this[S$0.id$2] = id;
this[S$0.stream] = stream;
this[S$0.sink$1] = sink;
;
}).prototype = VirtualChannel.prototype;
dart.addTypeTests(VirtualChannel);
VirtualChannel.prototype[_is_VirtualChannel_default] = true;
dart.addTypeCaches(VirtualChannel);
VirtualChannel[dart.implements] = () => [multi_channel.MultiChannel$(T)];
dart.setMethodSignature(VirtualChannel, () => ({
__proto__: dart.getMethods(VirtualChannel.__proto__),
virtualChannel: dart.fnType(multi_channel.VirtualChannel$(T), [], [dart.nullable(core.int)])
}));
dart.setLibraryUri(VirtualChannel, I[234]);
dart.setFieldSignature(VirtualChannel, () => ({
__proto__: dart.getFields(VirtualChannel.__proto__),
[S$0._parent$1]: dart.finalFieldType(multi_channel.MultiChannel$(T)),
id: dart.finalFieldType(core.int),
stream: dart.finalFieldType(async.Stream$(T)),
sink: dart.finalFieldType(async.StreamSink$(T))
}));
return VirtualChannel;
});
multi_channel.VirtualChannel = multi_channel.VirtualChannel$();
dart.addTypeTests(multi_channel.VirtualChannel, _is_VirtualChannel_default);
const _is_StreamChannelCompleter_default = Symbol('_is_StreamChannelCompleter_default');
stream_channel_completer.StreamChannelCompleter$ = dart.generic(T => {
var __t$StreamCompleterOfT = () => (__t$StreamCompleterOfT = dart.constFn(stream_completer.StreamCompleter$(T)))();
var __t$StreamSinkCompleterOfT = () => (__t$StreamSinkCompleterOfT = dart.constFn(stream_sink_completer.StreamSinkCompleter$(T)))();
var __t$StreamChannelOfT = () => (__t$StreamChannelOfT = dart.constFn(stream_channel.StreamChannel$(T)))();
var __t$NullStreamSinkOfT = () => (__t$NullStreamSinkOfT = dart.constFn(null_stream_sink.NullStreamSink$(T)))();
class StreamChannelCompleter extends core.Object {
get channel() {
return this[S$0._channel$3];
}
get [S$0._channel$3]() {
let t225;
return dart.test(this[S$0.__StreamChannelCompleter__channel_isSet]) ? (t225 = this[S$0.__StreamChannelCompleter__channel], t225) : dart.throw(new _internal.LateError.fieldNI("_channel"));
}
set [S$0._channel$3](t225) {
if (t225 == null) dart.nullFailed(I[235], 23, 31, "null");
if (dart.test(this[S$0.__StreamChannelCompleter__channel_isSet]))
dart.throw(new _internal.LateError.fieldAI("_channel"));
else {
this[S$0.__StreamChannelCompleter__channel_isSet] = true;
this[S$0.__StreamChannelCompleter__channel] = t225;
}
}
static fromFuture(channelFuture) {
if (channelFuture == null) dart.nullFailed(I[235], 36, 57, "channelFuture");
let completer = new stream_channel_completer.StreamChannelCompleter.new();
channelFuture.then(dart.void, T$0.StreamChannelTovoid().as(dart.bind(completer, 'setChannel')), {onError: dart.bind(completer, 'setError')});
return completer.channel;
}
static ['_#new#tearOff'](T) {
return new (stream_channel_completer.StreamChannelCompleter$(T)).new();
}
setChannel(channel) {
__t$StreamChannelOfT().as(channel);
if (channel == null) dart.nullFailed(I[235], 52, 36, "channel");
if (dart.test(this[S$0._set])) dart.throw(new core.StateError.new("The channel has already been set."));
this[S$0._set] = true;
this[S$0._streamCompleter].setSourceStream(channel.stream);
this[S$0._sinkCompleter].setDestinationSink(channel.sink);
}
setError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[235], 67, 24, "error");
if (dart.test(this[S$0._set])) dart.throw(new core.StateError.new("The channel has already been set."));
this[S$0._set] = true;
this[S$0._streamCompleter].setError(error, stackTrace);
this[S$0._sinkCompleter].setDestinationSink(new (__t$NullStreamSinkOfT()).new());
}
}
(StreamChannelCompleter.new = function() {
this[S$0._streamCompleter] = new (__t$StreamCompleterOfT()).new();
this[S$0._sinkCompleter] = new (__t$StreamSinkCompleterOfT()).new();
this[S$0.__StreamChannelCompleter__channel] = null;
this[S$0.__StreamChannelCompleter__channel_isSet] = false;
this[S$0._set] = false;
this[S$0._channel$3] = __t$StreamChannelOfT().new(this[S$0._streamCompleter].stream, this[S$0._sinkCompleter].sink);
}).prototype = StreamChannelCompleter.prototype;
dart.addTypeTests(StreamChannelCompleter);
StreamChannelCompleter.prototype[_is_StreamChannelCompleter_default] = true;
dart.addTypeCaches(StreamChannelCompleter);
dart.setMethodSignature(StreamChannelCompleter, () => ({
__proto__: dart.getMethods(StreamChannelCompleter.__proto__),
setChannel: dart.fnType(dart.void, [dart.nullable(core.Object)]),
setError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)])
}));
dart.setStaticMethodSignature(StreamChannelCompleter, () => ['fromFuture']);
dart.setGetterSignature(StreamChannelCompleter, () => ({
__proto__: dart.getGetters(StreamChannelCompleter.__proto__),
channel: stream_channel.StreamChannel$(T),
[S$0._channel$3]: stream_channel.StreamChannel$(T)
}));
dart.setSetterSignature(StreamChannelCompleter, () => ({
__proto__: dart.getSetters(StreamChannelCompleter.__proto__),
[S$0._channel$3]: stream_channel.StreamChannel$(T)
}));
dart.setLibraryUri(StreamChannelCompleter, I[236]);
dart.setFieldSignature(StreamChannelCompleter, () => ({
__proto__: dart.getFields(StreamChannelCompleter.__proto__),
[S$0._streamCompleter]: dart.finalFieldType(stream_completer.StreamCompleter$(T)),
[S$0._sinkCompleter]: dart.finalFieldType(stream_sink_completer.StreamSinkCompleter$(T)),
[S$0.__StreamChannelCompleter__channel]: dart.fieldType(dart.nullable(stream_channel.StreamChannel$(T))),
[S$0.__StreamChannelCompleter__channel_isSet]: dart.fieldType(core.bool),
[S$0._set]: dart.fieldType(core.bool)
}));
return StreamChannelCompleter;
});
stream_channel_completer.StreamChannelCompleter = stream_channel_completer.StreamChannelCompleter$();
dart.addTypeTests(stream_channel_completer.StreamChannelCompleter, _is_StreamChannelCompleter_default);
const _is_StreamChannelController_default = Symbol('_is_StreamChannelController_default');
stream_channel_controller.StreamChannelController$ = dart.generic(T => {
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
var __t$StreamChannelOfT = () => (__t$StreamChannelOfT = dart.constFn(stream_channel.StreamChannel$(T)))();
class StreamChannelController extends core.Object {
get local() {
return this[S$0._local];
}
get [S$0._local]() {
let t226;
return dart.test(this[S$0.__StreamChannelController__local_isSet]) ? (t226 = this[S$0.__StreamChannelController__local], t226) : dart.throw(new _internal.LateError.fieldNI("_local"));
}
set [S$0._local](t226) {
if (t226 == null) dart.nullFailed(I[237], 36, 31, "null");
if (dart.test(this[S$0.__StreamChannelController__local_isSet]))
dart.throw(new _internal.LateError.fieldAI("_local"));
else {
this[S$0.__StreamChannelController__local_isSet] = true;
this[S$0.__StreamChannelController__local] = t226;
}
}
get foreign() {
return this[S$0._foreign];
}
get [S$0._foreign]() {
let t227;
return dart.test(this[S$0.__StreamChannelController__foreign_isSet]) ? (t227 = this[S$0.__StreamChannelController__foreign], t227) : dart.throw(new _internal.LateError.fieldNI("_foreign"));
}
set [S$0._foreign](t227) {
if (t227 == null) dart.nullFailed(I[237], 43, 31, "null");
if (dart.test(this[S$0.__StreamChannelController__foreign_isSet]))
dart.throw(new _internal.LateError.fieldAI("_foreign"));
else {
this[S$0.__StreamChannelController__foreign_isSet] = true;
this[S$0.__StreamChannelController__foreign] = t227;
}
}
static ['_#new#tearOff'](T, opts) {
let allowForeignErrors = opts && 'allowForeignErrors' in opts ? opts.allowForeignErrors : true;
if (allowForeignErrors == null) dart.nullFailed(I[237], 55, 33, "allowForeignErrors");
let sync = opts && 'sync' in opts ? opts.sync : false;
if (sync == null) dart.nullFailed(I[237], 55, 65, "sync");
return new (stream_channel_controller.StreamChannelController$(T)).new({allowForeignErrors: allowForeignErrors, sync: sync});
}
}
(StreamChannelController.new = function(opts) {
let allowForeignErrors = opts && 'allowForeignErrors' in opts ? opts.allowForeignErrors : true;
if (allowForeignErrors == null) dart.nullFailed(I[237], 55, 33, "allowForeignErrors");
let sync = opts && 'sync' in opts ? opts.sync : false;
if (sync == null) dart.nullFailed(I[237], 55, 65, "sync");
this[S$0.__StreamChannelController__local] = null;
this[S$0.__StreamChannelController__local_isSet] = false;
this[S$0.__StreamChannelController__foreign] = null;
this[S$0.__StreamChannelController__foreign_isSet] = false;
let localToForeignController = __t$StreamControllerOfT().new({sync: sync});
let foreignToLocalController = __t$StreamControllerOfT().new({sync: sync});
this[S$0._local] = __t$StreamChannelOfT().withGuarantees(foreignToLocalController.stream, localToForeignController.sink);
this[S$0._foreign] = __t$StreamChannelOfT().withGuarantees(localToForeignController.stream, foreignToLocalController.sink, {allowSinkErrors: allowForeignErrors});
}).prototype = StreamChannelController.prototype;
dart.addTypeTests(StreamChannelController);
StreamChannelController.prototype[_is_StreamChannelController_default] = true;
dart.addTypeCaches(StreamChannelController);
dart.setGetterSignature(StreamChannelController, () => ({
__proto__: dart.getGetters(StreamChannelController.__proto__),
local: stream_channel.StreamChannel$(T),
[S$0._local]: stream_channel.StreamChannel$(T),
foreign: stream_channel.StreamChannel$(T),
[S$0._foreign]: stream_channel.StreamChannel$(T)
}));
dart.setSetterSignature(StreamChannelController, () => ({
__proto__: dart.getSetters(StreamChannelController.__proto__),
[S$0._local]: stream_channel.StreamChannel$(T),
[S$0._foreign]: stream_channel.StreamChannel$(T)
}));
dart.setLibraryUri(StreamChannelController, I[238]);
dart.setFieldSignature(StreamChannelController, () => ({
__proto__: dart.getFields(StreamChannelController.__proto__),
[S$0.__StreamChannelController__local]: dart.fieldType(dart.nullable(stream_channel.StreamChannel$(T))),
[S$0.__StreamChannelController__local_isSet]: dart.fieldType(core.bool),
[S$0.__StreamChannelController__foreign]: dart.fieldType(dart.nullable(stream_channel.StreamChannel$(T))),
[S$0.__StreamChannelController__foreign_isSet]: dart.fieldType(core.bool)
}));
return StreamChannelController;
});
stream_channel_controller.StreamChannelController = stream_channel_controller.StreamChannelController$();
dart.addTypeTests(stream_channel_controller.StreamChannelController, _is_StreamChannelController_default);
html$.HtmlWebSocketChannel = class HtmlWebSocketChannel extends stream_channel.StreamChannelMixin {
get [S$0._webSocket$2]() {
return this[S$0._webSocket$1];
}
set [S$0._webSocket$2](value) {
super[S$0._webSocket$2] = value;
}
get protocol() {
return this[S$0._webSocket$2].protocol;
}
get closeCode() {
return this[S$0._closeCode$1];
}
get closeReason() {
return this[S$0._closeReason$1];
}
get bufferedAmount() {
return this[S$0._webSocket$2].bufferedAmount;
}
get stream() {
return this[S$0._controller$5].foreign.stream;
}
get sink() {
let t229;
if (!dart.test(this[S$0.__HtmlWebSocketChannel_sink_isSet])) {
let t228 = new html$._HtmlWebSocketSink.new(this);
if (dart.test(this[S$0.__HtmlWebSocketChannel_sink_isSet])) dart.throw(new _internal.LateError.fieldADI("sink"));
this[S$0.__HtmlWebSocketChannel_sink] = t228;
this[S$0.__HtmlWebSocketChannel_sink_isSet] = true;
}
t229 = this[S$0.__HtmlWebSocketChannel_sink];
return t229;
}
static ['_#connect#tearOff'](url, opts) {
let protocols = opts && 'protocols' in opts ? opts.protocols : null;
let binaryType = opts && 'binaryType' in opts ? opts.binaryType : null;
return new html$.HtmlWebSocketChannel.connect(url, {protocols: protocols, binaryType: binaryType});
}
static ['_#new#tearOff'](_webSocket) {
if (_webSocket == null) dart.nullFailed(I[239], 73, 29, "_webSocket");
return new html$.HtmlWebSocketChannel.new(_webSocket);
}
[S$0._listen]() {
this[S$0._controller$5].local.stream.listen(dart.bind(this[S$0._webSocket$2], 'send'), {onDone: dart.fn(() => {
if (this[S$0._localCloseCode] != null && this[S$0._localCloseReason] != null) {
this[S$0._webSocket$2].close(this[S$0._localCloseCode], this[S$0._localCloseReason]);
} else if (this[S$0._localCloseCode] != null) {
this[S$0._webSocket$2].close(this[S$0._localCloseCode]);
} else {
this[S$0._webSocket$2].close();
}
}, T$.VoidTovoid())});
}
get [S$0._webSocket]() {
return web_socket_impl.WebSocketImpl.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[210] || CT.C210)));
}
};
(html$.HtmlWebSocketChannel.connect = function(url, opts) {
let t229, t228;
let protocols = opts && 'protocols' in opts ? opts.protocols : null;
let binaryType = opts && 'binaryType' in opts ? opts.binaryType : null;
html$.HtmlWebSocketChannel.new.call(this, (t228 = html.WebSocket.new(dart.toString(url), protocols), (() => {
t228.binaryType = (t229 = binaryType, t229 == null ? html$.BinaryType.list : t229).value;
return t228;
})()));
}).prototype = html$.HtmlWebSocketChannel.prototype;
(html$.HtmlWebSocketChannel.new = function(_webSocket) {
if (_webSocket == null) dart.nullFailed(I[239], 73, 29, "_webSocket");
this[S$0._closeCode$1] = null;
this[S$0._closeReason$1] = null;
this[S$0._localCloseCode] = null;
this[S$0._localCloseReason] = null;
this[S$0._controller$5] = new stream_channel_controller.StreamChannelController.new({sync: true, allowForeignErrors: false});
this[S$0.__HtmlWebSocketChannel_sink] = null;
this[S$0.__HtmlWebSocketChannel_sink_isSet] = false;
this[S$0._webSocket$1] = _webSocket;
if (this[S$0._webSocket$2].readyState === 1) {
this[S$0._listen]();
} else {
this[S$0._webSocket$2][S$0.$onOpen].first.then(core.Null, dart.fn(_ => {
if (_ == null) dart.nullFailed(I[239], 79, 37, "_");
this[S$0._listen]();
}, T$0.EventToNull()));
}
this[S$0._webSocket$2][S$0.$onError].first.then(core.Null, dart.fn(_ => {
if (_ == null) dart.nullFailed(I[239], 86, 36, "_");
this[S$0._controller$5].local.sink.addError(new exception.WebSocketChannelException.new("WebSocket connection failed."));
this[S$0._controller$5].local.sink.close();
}, T$0.EventToNull()));
this[S$0._webSocket$2][S$0.$onMessage].listen(dart.fn(event => {
if (event == null) dart.nullFailed(I[239], 92, 34, "event");
let data = event[S$0.$data];
if (typed_data.ByteBuffer.is(data)) data = data[S$.$asUint8List]();
this[S$0._controller$5].local.sink.add(data);
}, T$0.MessageEventTovoid()));
this[S$0._webSocket$2][S$0.$onClose].first.then(core.Null, dart.fn(event => {
if (event == null) dart.nullFailed(I[239], 100, 36, "event");
this[S$0._closeCode$1] = event.code;
this[S$0._closeReason$1] = event.reason;
this[S$0._controller$5].local.sink.close();
}, T$0.CloseEventToNull()));
}).prototype = html$.HtmlWebSocketChannel.prototype;
dart.addTypeTests(html$.HtmlWebSocketChannel);
dart.addTypeCaches(html$.HtmlWebSocketChannel);
html$.HtmlWebSocketChannel[dart.implements] = () => [channel$.WebSocketChannel];
dart.setMethodSignature(html$.HtmlWebSocketChannel, () => ({
__proto__: dart.getMethods(html$.HtmlWebSocketChannel.__proto__),
[S$0._listen]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(html$.HtmlWebSocketChannel, () => ({
__proto__: dart.getGetters(html$.HtmlWebSocketChannel.__proto__),
protocol: dart.nullable(core.String),
closeCode: dart.nullable(core.int),
closeReason: dart.nullable(core.String),
bufferedAmount: dart.nullable(core.int),
stream: async.Stream,
sink: channel$.WebSocketSink,
[S$0._webSocket]: web_socket_impl.WebSocketImpl
}));
dart.setLibraryUri(html$.HtmlWebSocketChannel, I[240]);
dart.setFieldSignature(html$.HtmlWebSocketChannel, () => ({
__proto__: dart.getFields(html$.HtmlWebSocketChannel.__proto__),
[S$0._webSocket$2]: dart.finalFieldType(html.WebSocket),
[S$0._closeCode$1]: dart.fieldType(dart.nullable(core.int)),
[S$0._closeReason$1]: dart.fieldType(dart.nullable(core.String)),
[S$0._localCloseCode]: dart.fieldType(dart.nullable(core.int)),
[S$0._localCloseReason]: dart.fieldType(dart.nullable(core.String)),
[S$0._controller$5]: dart.finalFieldType(stream_channel_controller.StreamChannelController),
[S$0.__HtmlWebSocketChannel_sink]: dart.fieldType(dart.nullable(channel$.WebSocketSink)),
[S$0.__HtmlWebSocketChannel_sink_isSet]: dart.fieldType(core.bool)
}));
html$._HtmlWebSocketSink = class _HtmlWebSocketSink extends stream_sink.DelegatingStreamSink {
static ['_#new#tearOff'](channel) {
if (channel == null) dart.nullFailed(I[239], 129, 43, "channel");
return new html$._HtmlWebSocketSink.new(channel);
}
close(closeCode = null, closeReason = null) {
this[S$0._channel$4][S$0._localCloseCode] = closeCode;
this[S$0._channel$4][S$0._localCloseReason] = closeReason;
return super.close();
}
get [S$0._webSocket]() {
return web_socket_impl.WebSocketImpl.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[210] || CT.C210)));
}
};
(html$._HtmlWebSocketSink.new = function(channel) {
if (channel == null) dart.nullFailed(I[239], 129, 43, "channel");
this[S$0._channel$4] = channel;
html$._HtmlWebSocketSink.__proto__.new.call(this, channel[S$0._controller$5].foreign.sink);
;
}).prototype = html$._HtmlWebSocketSink.prototype;
dart.addTypeTests(html$._HtmlWebSocketSink);
dart.addTypeCaches(html$._HtmlWebSocketSink);
html$._HtmlWebSocketSink[dart.implements] = () => [channel$.WebSocketSink];
dart.setMethodSignature(html$._HtmlWebSocketSink, () => ({
__proto__: dart.getMethods(html$._HtmlWebSocketSink.__proto__),
close: dart.fnType(async.Future, [], [dart.nullable(core.int), dart.nullable(core.String)])
}));
dart.setGetterSignature(html$._HtmlWebSocketSink, () => ({
__proto__: dart.getGetters(html$._HtmlWebSocketSink.__proto__),
[S$0._webSocket]: web_socket_impl.WebSocketImpl
}));
dart.setLibraryUri(html$._HtmlWebSocketSink, I[240]);
dart.setFieldSignature(html$._HtmlWebSocketSink, () => ({
__proto__: dart.getFields(html$._HtmlWebSocketSink.__proto__),
[S$0._channel$4]: dart.finalFieldType(html$.HtmlWebSocketChannel)
}));
html$.BinaryType = class BinaryType extends core.Object {
get name() {
return this[S$0.name$9];
}
set name(value) {
super.name = value;
}
get value() {
return this[S$0.value$13];
}
set value(value) {
super.value = value;
}
static ['_#_#tearOff'](name, value) {
if (name == null) dart.nullFailed(I[239], 156, 27, "name");
if (value == null) dart.nullFailed(I[239], 156, 38, "value");
return new html$.BinaryType.__(name, value);
}
toString() {
return this.name;
}
};
(html$.BinaryType.__ = function(name, value) {
if (name == null) dart.nullFailed(I[239], 156, 27, "name");
if (value == null) dart.nullFailed(I[239], 156, 38, "value");
this[S$0.name$9] = name;
this[S$0.value$13] = value;
;
}).prototype = html$.BinaryType.prototype;
dart.addTypeTests(html$.BinaryType);
dart.addTypeCaches(html$.BinaryType);
dart.setLibraryUri(html$.BinaryType, I[240]);
dart.setFieldSignature(html$.BinaryType, () => ({
__proto__: dart.getFields(html$.BinaryType.__proto__),
name: dart.finalFieldType(core.String),
value: dart.finalFieldType(core.String)
}));
dart.setStaticFieldSignature(html$.BinaryType, () => ['blob', 'list']);
dart.defineExtensionMethods(html$.BinaryType, ['toString']);
dart.defineLazy(html$.BinaryType, {
/*html$.BinaryType.blob*/get blob() {
return C[211] || CT.C211;
},
/*html$.BinaryType.list*/get list() {
return C[212] || CT.C212;
}
}, false);
const _is_StreamSinkImpl_default = Symbol('_is_StreamSinkImpl_default');
io_sink.StreamSinkImpl$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$StreamControllerOfT = () => (__t$StreamControllerOfT = dart.constFn(async.StreamController$(T)))();
class StreamSinkImpl extends core.Object {
static ['_#new#tearOff'](T, _target) {
if (_target == null) dart.nullFailed(I[241], 25, 23, "_target");
return new (io_sink.StreamSinkImpl$(T)).new(_target);
}
add(data) {
T.as(data);
if (dart.test(this[S$0._isClosed$4])) {
return;
}
this[S$0._controller$6].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[241], 39, 17, "error");
if (dart.test(this[S$0._isClosed$4])) {
return;
}
this[S$0._controller$6].addError(error, stackTrace);
}
addStream(stream) {
let t229;
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[241], 47, 30, "stream");
if (dart.test(this[S$0._isBound])) {
dart.throw(new core.StateError.new("StreamSink is already bound to a stream"));
}
if (dart.test(this[S$0._hasError])) return this.done;
this[S$0._isBound] = true;
let future = this[S$0._controllerCompleter] == null ? this[S$0._target].addStream(stream) : dart.nullCheck(this[S$0._controllerCompleter]).future.then(dart.dynamic, dart.fn(_ => this[S$0._target].addStream(stream), T$.dynamicToFuture()));
t229 = this[S$0._controllerInstance];
t229 == null ? null : t229.close();
return future.whenComplete(dart.fn(() => {
this[S$0._isBound] = false;
}, T$.VoidToNull()));
}
flush() {
if (dart.test(this[S$0._isBound])) {
dart.throw(new core.StateError.new("StreamSink is bound to a stream"));
}
if (this[S$0._controllerInstance] == null) return async.Future.value(this);
this[S$0._isBound] = true;
let future = dart.nullCheck(this[S$0._controllerCompleter]).future;
dart.nullCheck(this[S$0._controllerInstance]).close();
return future.whenComplete(dart.fn(() => {
this[S$0._isBound] = false;
}, T$.VoidToNull()));
}
close() {
if (dart.test(this[S$0._isBound])) {
dart.throw(new core.StateError.new("StreamSink is bound to a stream"));
}
if (!dart.test(this[S$0._isClosed$4])) {
this[S$0._isClosed$4] = true;
if (this[S$0._controllerInstance] != null) {
dart.nullCheck(this[S$0._controllerInstance]).close();
} else {
this[S$0._closeTarget]();
}
}
return this.done;
}
[S$0._closeTarget]() {
this[S$0._target].close().then(dart.void, dart.bind(this, S$0._completeDoneValue), {onError: dart.bind(this, S$0._completeDoneError)});
}
get done() {
return this[S$0._doneCompleter$2].future;
}
[S$0._completeDoneValue](value) {
if (!dart.test(this[S$0._doneCompleter$2].isCompleted)) {
this[S$0._doneCompleter$2].complete(value);
}
}
[S$0._completeDoneError](error, stackTrace) {
if (error == null) dart.nullFailed(I[241], 110, 34, "error");
if (stackTrace == null) dart.nullFailed(I[241], 110, 52, "stackTrace");
if (!dart.test(this[S$0._doneCompleter$2].isCompleted)) {
this[S$0._hasError] = true;
this[S$0._doneCompleter$2].completeError(error, stackTrace);
}
}
get [S$0._controller$6]() {
if (dart.test(this[S$0._isBound])) {
dart.throw(new core.StateError.new("StreamSink is bound to a stream"));
}
if (dart.test(this[S$0._isClosed$4])) {
dart.throw(new core.StateError.new("StreamSink is closed"));
}
if (this[S$0._controllerInstance] == null) {
this[S$0._controllerInstance] = __t$StreamControllerOfT().new({sync: true});
this[S$0._controllerCompleter] = async.Completer.new();
this[S$0._target].addStream(this[S$0._controller$6].stream).then(core.Null, dart.fn(_ => {
if (dart.test(this[S$0._isBound])) {
dart.nullCheck(this[S$0._controllerCompleter]).complete(this);
this[S$0._controllerCompleter] = null;
this[S$0._controllerInstance] = null;
} else {
this[S$0._closeTarget]();
}
}, T$.dynamicToNull()), {onError: dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[241], 137, 27, "error");
if (stackTrace == null) dart.nullFailed(I[241], 137, 45, "stackTrace");
if (dart.test(this[S$0._isBound])) {
dart.nullCheck(this[S$0._controllerCompleter]).completeError(error, stackTrace);
this[S$0._controllerCompleter] = null;
this[S$0._controllerInstance] = null;
} else {
this[S$0._completeDoneError](error, stackTrace);
}
}, T$.ObjectAndStackTraceToNull())});
}
return dart.nullCheck(this[S$0._controllerInstance]);
}
}
(StreamSinkImpl.new = function(_target) {
if (_target == null) dart.nullFailed(I[241], 25, 23, "_target");
this[S$0._doneCompleter$2] = async.Completer.new();
this[S$0._controllerInstance] = null;
this[S$0._controllerCompleter] = null;
this[S$0._isClosed$4] = false;
this[S$0._isBound] = false;
this[S$0._hasError] = false;
this[S$0._target] = _target;
;
}).prototype = StreamSinkImpl.prototype;
dart.addTypeTests(StreamSinkImpl);
StreamSinkImpl.prototype[_is_StreamSinkImpl_default] = true;
dart.addTypeCaches(StreamSinkImpl);
StreamSinkImpl[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(StreamSinkImpl, () => ({
__proto__: dart.getMethods(StreamSinkImpl.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
flush: dart.fnType(async.Future, []),
close: dart.fnType(async.Future, []),
[S$0._closeTarget]: dart.fnType(dart.void, []),
[S$0._completeDoneValue]: dart.fnType(dart.void, [dart.dynamic]),
[S$0._completeDoneError]: dart.fnType(dart.void, [core.Object, core.StackTrace])
}));
dart.setGetterSignature(StreamSinkImpl, () => ({
__proto__: dart.getGetters(StreamSinkImpl.__proto__),
done: async.Future,
[S$0._controller$6]: async.StreamController$(T)
}));
dart.setLibraryUri(StreamSinkImpl, I[242]);
dart.setFieldSignature(StreamSinkImpl, () => ({
__proto__: dart.getFields(StreamSinkImpl.__proto__),
[S$0._target]: dart.finalFieldType(async.StreamConsumer$(T)),
[S$0._doneCompleter$2]: dart.finalFieldType(async.Completer),
[S$0._controllerInstance]: dart.fieldType(dart.nullable(async.StreamController$(T))),
[S$0._controllerCompleter]: dart.fieldType(dart.nullable(async.Completer)),
[S$0._isClosed$4]: dart.fieldType(core.bool),
[S$0._isBound]: dart.fieldType(core.bool),
[S$0._hasError]: dart.fieldType(core.bool)
}));
return StreamSinkImpl;
});
io_sink.StreamSinkImpl = io_sink.StreamSinkImpl$();
dart.addTypeTests(io_sink.StreamSinkImpl, _is_StreamSinkImpl_default);
web_socket.WebSocketStatus = class WebSocketStatus extends core.Object {};
(web_socket.WebSocketStatus.new = function() {
;
}).prototype = web_socket.WebSocketStatus.prototype;
dart.addTypeTests(web_socket.WebSocketStatus);
dart.addTypeCaches(web_socket.WebSocketStatus);
dart.setLibraryUri(web_socket.WebSocketStatus, I[243]);
dart.setStaticFieldSignature(web_socket.WebSocketStatus, () => ['NORMAL_CLOSURE', 'GOING_AWAY', 'PROTOCOL_ERROR', 'UNSUPPORTED_DATA', 'RESERVED_1004', 'NO_STATUS_RECEIVED', 'ABNORMAL_CLOSURE', 'INVALID_FRAME_PAYLOAD_DATA', 'POLICY_VIOLATION', 'MESSAGE_TOO_BIG', 'MISSING_MANDATORY_EXTENSION', 'INTERNAL_SERVER_ERROR', 'RESERVED_1015']);
dart.defineLazy(web_socket.WebSocketStatus, {
/*web_socket.WebSocketStatus.NORMAL_CLOSURE*/get NORMAL_CLOSURE() {
return 1000;
},
/*web_socket.WebSocketStatus.GOING_AWAY*/get GOING_AWAY() {
return 1001;
},
/*web_socket.WebSocketStatus.PROTOCOL_ERROR*/get PROTOCOL_ERROR() {
return 1002;
},
/*web_socket.WebSocketStatus.UNSUPPORTED_DATA*/get UNSUPPORTED_DATA() {
return 1003;
},
/*web_socket.WebSocketStatus.RESERVED_1004*/get RESERVED_1004() {
return 1004;
},
/*web_socket.WebSocketStatus.NO_STATUS_RECEIVED*/get NO_STATUS_RECEIVED() {
return 1005;
},
/*web_socket.WebSocketStatus.ABNORMAL_CLOSURE*/get ABNORMAL_CLOSURE() {
return 1006;
},
/*web_socket.WebSocketStatus.INVALID_FRAME_PAYLOAD_DATA*/get INVALID_FRAME_PAYLOAD_DATA() {
return 1007;
},
/*web_socket.WebSocketStatus.POLICY_VIOLATION*/get POLICY_VIOLATION() {
return 1008;
},
/*web_socket.WebSocketStatus.MESSAGE_TOO_BIG*/get MESSAGE_TOO_BIG() {
return 1009;
},
/*web_socket.WebSocketStatus.MISSING_MANDATORY_EXTENSION*/get MISSING_MANDATORY_EXTENSION() {
return 1010;
},
/*web_socket.WebSocketStatus.INTERNAL_SERVER_ERROR*/get INTERNAL_SERVER_ERROR() {
return 1011;
},
/*web_socket.WebSocketStatus.RESERVED_1015*/get RESERVED_1015() {
return 1015;
}
}, false);
web_socket.WebSocket = class WebSocket extends core.Object {};
(web_socket.WebSocket.new = function() {
;
}).prototype = web_socket.WebSocket.prototype;
dart.addTypeTests(web_socket.WebSocket);
dart.addTypeCaches(web_socket.WebSocket);
dart.setLibraryUri(web_socket.WebSocket, I[243]);
dart.setStaticFieldSignature(web_socket.WebSocket, () => ['CONNECTING', 'OPEN', 'CLOSING', 'CLOSED']);
dart.defineLazy(web_socket.WebSocket, {
/*web_socket.WebSocket.CONNECTING*/get CONNECTING() {
return 0;
},
/*web_socket.WebSocket.OPEN*/get OPEN() {
return 1;
},
/*web_socket.WebSocket.CLOSING*/get CLOSING() {
return 2;
},
/*web_socket.WebSocket.CLOSED*/get CLOSED() {
return 3;
}
}, false);
const _is_TypeSafeStreamSubscription_default = Symbol('_is_TypeSafeStreamSubscription_default');
stream_subscription$.TypeSafeStreamSubscription$ = dart.generic(T => {
class TypeSafeStreamSubscription extends core.Object {
get isPaused() {
return this[S$0._subscription$6].isPaused;
}
static ['_#new#tearOff'](T, _subscription) {
if (_subscription == null) dart.nullFailed(I[244], 13, 35, "_subscription");
return new (stream_subscription$.TypeSafeStreamSubscription$(T)).new(_subscription);
}
onData(handleData) {
if (handleData == null) return this[S$0._subscription$6].onData(null);
this[S$0._subscription$6].onData(dart.fn(data => handleData(T.as(data)), T$.dynamicTovoid()));
}
onError(handleError) {
this[S$0._subscription$6].onError(handleError);
}
onDone(handleDone) {
this[S$0._subscription$6].onDone(handleDone);
}
pause(resumeFuture = null) {
this[S$0._subscription$6].pause(resumeFuture);
}
resume() {
this[S$0._subscription$6].resume();
}
cancel() {
return this[S$0._subscription$6].cancel();
}
asFuture(E, futureValue = null) {
return this[S$0._subscription$6].asFuture(E, futureValue);
}
}
(TypeSafeStreamSubscription.new = function(_subscription) {
if (_subscription == null) dart.nullFailed(I[244], 13, 35, "_subscription");
this[S$0._subscription$6] = _subscription;
;
}).prototype = TypeSafeStreamSubscription.prototype;
TypeSafeStreamSubscription.prototype[dart.isStreamSubscription] = true;
dart.addTypeTests(TypeSafeStreamSubscription);
TypeSafeStreamSubscription.prototype[_is_TypeSafeStreamSubscription_default] = true;
dart.addTypeCaches(TypeSafeStreamSubscription);
TypeSafeStreamSubscription[dart.implements] = () => [async.StreamSubscription$(T)];
dart.setMethodSignature(TypeSafeStreamSubscription, () => ({
__proto__: dart.getMethods(TypeSafeStreamSubscription.__proto__),
onData: dart.fnType(dart.void, [dart.nullable(dart.fnType(dart.void, [T]))]),
onError: dart.fnType(dart.void, [dart.nullable(core.Function)]),
onDone: dart.fnType(dart.void, [dart.nullable(dart.fnType(dart.void, []))]),
pause: dart.fnType(dart.void, [], [dart.nullable(async.Future)]),
resume: dart.fnType(dart.void, []),
cancel: dart.fnType(async.Future, []),
asFuture: dart.gFnType(E => [async.Future$(E), [], [dart.nullable(E)]], E => [dart.nullable(core.Object)])
}));
dart.setGetterSignature(TypeSafeStreamSubscription, () => ({
__proto__: dart.getGetters(TypeSafeStreamSubscription.__proto__),
isPaused: core.bool
}));
dart.setLibraryUri(TypeSafeStreamSubscription, I[245]);
dart.setFieldSignature(TypeSafeStreamSubscription, () => ({
__proto__: dart.getFields(TypeSafeStreamSubscription.__proto__),
[S$0._subscription$6]: dart.finalFieldType(async.StreamSubscription)
}));
return TypeSafeStreamSubscription;
});
stream_subscription$.TypeSafeStreamSubscription = stream_subscription$.TypeSafeStreamSubscription$();
dart.addTypeTests(stream_subscription$.TypeSafeStreamSubscription, _is_TypeSafeStreamSubscription_default);
const _is_CaptureSink_default = Symbol('_is_CaptureSink_default');
capture_sink.CaptureSink$ = dart.generic(T => {
var __t$ValueResultOfT = () => (__t$ValueResultOfT = dart.constFn(value$.ValueResult$(T)))();
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
class CaptureSink extends core.Object {
static ['_#new#tearOff'](T, sink) {
if (sink == null) dart.nullFailed(I[246], 13, 36, "sink");
return new (capture_sink.CaptureSink$(T)).new(sink);
}
add(value) {
T.as(value);
this[S$0._sink$8].add(new (__t$ValueResultOfT()).new(value));
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[246], 21, 24, "error");
this[S$0._sink$8].add(__t$ResultOfT().error(error, stackTrace));
}
close() {
this[S$0._sink$8].close();
}
}
(CaptureSink.new = function(sink) {
if (sink == null) dart.nullFailed(I[246], 13, 36, "sink");
this[S$0._sink$8] = sink;
;
}).prototype = CaptureSink.prototype;
dart.addTypeTests(CaptureSink);
CaptureSink.prototype[_is_CaptureSink_default] = true;
dart.addTypeCaches(CaptureSink);
CaptureSink[dart.implements] = () => [async.EventSink$(T)];
dart.setMethodSignature(CaptureSink, () => ({
__proto__: dart.getMethods(CaptureSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
close: dart.fnType(dart.void, [])
}));
dart.setLibraryUri(CaptureSink, I[247]);
dart.setFieldSignature(CaptureSink, () => ({
__proto__: dart.getFields(CaptureSink.__proto__),
[S$0._sink$8]: dart.finalFieldType(async.EventSink$(result$.Result$(T)))
}));
return CaptureSink;
});
capture_sink.CaptureSink = capture_sink.CaptureSink$();
dart.addTypeTests(capture_sink.CaptureSink, _is_CaptureSink_default);
const _is_CaptureStreamTransformer_default = Symbol('_is_CaptureStreamTransformer_default');
capture_transformer.CaptureStreamTransformer$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$StreamOfResultOfT = () => (__t$StreamOfResultOfT = dart.constFn(async.Stream$(__t$ResultOfT())))();
var __t$CaptureSinkOfT = () => (__t$CaptureSinkOfT = dart.constFn(capture_sink.CaptureSink$(T)))();
var __t$EventSinkOfResultOfT = () => (__t$EventSinkOfResultOfT = dart.constFn(async.EventSink$(__t$ResultOfT())))();
var __t$EventSinkOfResultOfTToCaptureSinkOfT = () => (__t$EventSinkOfResultOfTToCaptureSinkOfT = dart.constFn(dart.fnType(__t$CaptureSinkOfT(), [__t$EventSinkOfResultOfT()])))();
class CaptureStreamTransformer extends async.StreamTransformerBase$(T, result$.Result$(T)) {
static ['_#new#tearOff'](T) {
return new (capture_transformer.CaptureStreamTransformer$(T)).new();
}
bind(source) {
__t$StreamOfT().as(source);
if (source == null) dart.nullFailed(I[248], 18, 36, "source");
return __t$StreamOfResultOfT().eventTransformed(source, dart.fn(sink => {
if (sink == null) dart.nullFailed(I[248], 20, 20, "sink");
return new (__t$CaptureSinkOfT()).new(sink);
}, __t$EventSinkOfResultOfTToCaptureSinkOfT()));
}
}
(CaptureStreamTransformer.new = function() {
CaptureStreamTransformer.__proto__.new.call(this);
;
}).prototype = CaptureStreamTransformer.prototype;
dart.addTypeTests(CaptureStreamTransformer);
CaptureStreamTransformer.prototype[_is_CaptureStreamTransformer_default] = true;
dart.addTypeCaches(CaptureStreamTransformer);
dart.setMethodSignature(CaptureStreamTransformer, () => ({
__proto__: dart.getMethods(CaptureStreamTransformer.__proto__),
bind: dart.fnType(async.Stream$(result$.Result$(T)), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(CaptureStreamTransformer, I[249]);
return CaptureStreamTransformer;
});
capture_transformer.CaptureStreamTransformer = capture_transformer.CaptureStreamTransformer$();
dart.addTypeTests(capture_transformer.CaptureStreamTransformer, _is_CaptureStreamTransformer_default);
const _is_ReleaseSink_default = Symbol('_is_ReleaseSink_default');
release_sink.ReleaseSink$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
class ReleaseSink extends core.Object {
static ['_#new#tearOff'](T, _sink) {
if (_sink == null) dart.nullFailed(I[250], 13, 20, "_sink");
return new (release_sink.ReleaseSink$(T)).new(_sink);
}
add(result) {
__t$ResultOfT().as(result);
if (result == null) dart.nullFailed(I[250], 16, 22, "result");
result.addTo(this[S$0._sink$9]);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[250], 21, 24, "error");
this[S$0._sink$9].addError(error, stackTrace);
}
close() {
this[S$0._sink$9].close();
}
}
(ReleaseSink.new = function(_sink) {
if (_sink == null) dart.nullFailed(I[250], 13, 20, "_sink");
this[S$0._sink$9] = _sink;
;
}).prototype = ReleaseSink.prototype;
dart.addTypeTests(ReleaseSink);
ReleaseSink.prototype[_is_ReleaseSink_default] = true;
dart.addTypeCaches(ReleaseSink);
ReleaseSink[dart.implements] = () => [async.EventSink$(result$.Result$(T))];
dart.setMethodSignature(ReleaseSink, () => ({
__proto__: dart.getMethods(ReleaseSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
close: dart.fnType(dart.void, [])
}));
dart.setLibraryUri(ReleaseSink, I[251]);
dart.setFieldSignature(ReleaseSink, () => ({
__proto__: dart.getFields(ReleaseSink.__proto__),
[S$0._sink$9]: dart.finalFieldType(async.EventSink$(T))
}));
return ReleaseSink;
});
release_sink.ReleaseSink = release_sink.ReleaseSink$();
dart.addTypeTests(release_sink.ReleaseSink, _is_ReleaseSink_default);
const _is_ReleaseStreamTransformer_default = Symbol('_is_ReleaseStreamTransformer_default');
release_transformer.ReleaseStreamTransformer$ = dart.generic(T => {
var __t$ResultOfT = () => (__t$ResultOfT = dart.constFn(result$.Result$(T)))();
var __t$StreamOfResultOfT = () => (__t$StreamOfResultOfT = dart.constFn(async.Stream$(__t$ResultOfT())))();
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
class ReleaseStreamTransformer extends async.StreamTransformerBase$(result$.Result$(T), T) {
static ['_#new#tearOff'](T) {
return new (release_transformer.ReleaseStreamTransformer$(T)).new();
}
bind(source) {
__t$StreamOfResultOfT().as(source);
if (source == null) dart.nullFailed(I[252], 15, 36, "source");
return __t$StreamOfT().eventTransformed(source, C[213] || CT.C213);
}
static _createSink(sink) {
if (sink == null) dart.nullFailed(I[252], 20, 50, "sink");
return new release_sink.ReleaseSink.new(sink);
}
}
(ReleaseStreamTransformer.new = function() {
ReleaseStreamTransformer.__proto__.new.call(this);
;
}).prototype = ReleaseStreamTransformer.prototype;
dart.addTypeTests(ReleaseStreamTransformer);
ReleaseStreamTransformer.prototype[_is_ReleaseStreamTransformer_default] = true;
dart.addTypeCaches(ReleaseStreamTransformer);
dart.setMethodSignature(ReleaseStreamTransformer, () => ({
__proto__: dart.getMethods(ReleaseStreamTransformer.__proto__),
bind: dart.fnType(async.Stream$(T), [dart.nullable(core.Object)])
}));
dart.setStaticMethodSignature(ReleaseStreamTransformer, () => ['_createSink']);
dart.setLibraryUri(ReleaseStreamTransformer, I[253]);
return ReleaseStreamTransformer;
});
release_transformer.ReleaseStreamTransformer = release_transformer.ReleaseStreamTransformer$();
dart.addTypeTests(release_transformer.ReleaseStreamTransformer, _is_ReleaseStreamTransformer_default);
meta.Immutable = class Immutable extends core.Object {
get reason() {
return this[S$0.reason];
}
set reason(value) {
super.reason = value;
}
static ['_#new#tearOff'](reason = "") {
if (reason == null) dart.nullFailed(I[254], 328, 25, "reason");
return new meta.Immutable.new(reason);
}
};
(meta.Immutable.new = function(reason = "") {
if (reason == null) dart.nullFailed(I[254], 328, 25, "reason");
this[S$0.reason] = reason;
;
}).prototype = meta.Immutable.prototype;
dart.addTypeTests(meta.Immutable);
dart.addTypeCaches(meta.Immutable);
dart.setLibraryUri(meta.Immutable, I[255]);
dart.setFieldSignature(meta.Immutable, () => ({
__proto__: dart.getFields(meta.Immutable.__proto__),
reason: dart.finalFieldType(core.String)
}));
meta.Required = class Required extends core.Object {
get reason() {
return this[S$0.reason$1];
}
set reason(value) {
super.reason = value;
}
static ['_#new#tearOff'](reason = "") {
if (reason == null) dart.nullFailed(I[254], 347, 24, "reason");
return new meta.Required.new(reason);
}
};
(meta.Required.new = function(reason = "") {
if (reason == null) dart.nullFailed(I[254], 347, 24, "reason");
this[S$0.reason$1] = reason;
;
}).prototype = meta.Required.prototype;
dart.addTypeTests(meta.Required);
dart.addTypeCaches(meta.Required);
dart.setLibraryUri(meta.Required, I[255]);
dart.setFieldSignature(meta.Required, () => ({
__proto__: dart.getFields(meta.Required.__proto__),
reason: dart.finalFieldType(core.String)
}));
meta.UseResult = class UseResult extends core.Object {
get reason() {
return this[S$0.reason$2];
}
set reason(value) {
super.reason = value;
}
static ['_#new#tearOff'](reason = "") {
if (reason == null) dart.nullFailed(I[254], 364, 25, "reason");
return new meta.UseResult.new(reason);
}
};
(meta.UseResult.new = function(reason = "") {
if (reason == null) dart.nullFailed(I[254], 364, 25, "reason");
this[S$0.reason$2] = reason;
;
}).prototype = meta.UseResult.prototype;
dart.addTypeTests(meta.UseResult);
dart.addTypeCaches(meta.UseResult);
dart.setLibraryUri(meta.UseResult, I[255]);
dart.setFieldSignature(meta.UseResult, () => ({
__proto__: dart.getFields(meta.UseResult.__proto__),
reason: dart.finalFieldType(core.String)
}));
meta._AlwaysThrows = class _AlwaysThrows extends core.Object {
static ['_#new#tearOff']() {
return new meta._AlwaysThrows.new();
}
};
(meta._AlwaysThrows.new = function() {
;
}).prototype = meta._AlwaysThrows.prototype;
dart.addTypeTests(meta._AlwaysThrows);
dart.addTypeCaches(meta._AlwaysThrows);
dart.setLibraryUri(meta._AlwaysThrows, I[255]);
meta._Checked = class _Checked extends core.Object {
static ['_#new#tearOff']() {
return new meta._Checked.new();
}
};
(meta._Checked.new = function() {
;
}).prototype = meta._Checked.prototype;
dart.addTypeTests(meta._Checked);
dart.addTypeCaches(meta._Checked);
dart.setLibraryUri(meta._Checked, I[255]);
meta._DoNotStore = class _DoNotStore extends core.Object {
static ['_#new#tearOff']() {
return new meta._DoNotStore.new();
}
};
(meta._DoNotStore.new = function() {
;
}).prototype = meta._DoNotStore.prototype;
dart.addTypeTests(meta._DoNotStore);
dart.addTypeCaches(meta._DoNotStore);
dart.setLibraryUri(meta._DoNotStore, I[255]);
meta._Experimental = class _Experimental extends core.Object {
static ['_#new#tearOff']() {
return new meta._Experimental.new();
}
};
(meta._Experimental.new = function() {
;
}).prototype = meta._Experimental.prototype;
dart.addTypeTests(meta._Experimental);
dart.addTypeCaches(meta._Experimental);
dart.setLibraryUri(meta._Experimental, I[255]);
meta._Factory = class _Factory extends core.Object {
static ['_#new#tearOff']() {
return new meta._Factory.new();
}
};
(meta._Factory.new = function() {
;
}).prototype = meta._Factory.prototype;
dart.addTypeTests(meta._Factory);
dart.addTypeCaches(meta._Factory);
dart.setLibraryUri(meta._Factory, I[255]);
meta._Internal = class _Internal extends core.Object {
static ['_#new#tearOff']() {
return new meta._Internal.new();
}
};
(meta._Internal.new = function() {
;
}).prototype = meta._Internal.prototype;
dart.addTypeTests(meta._Internal);
dart.addTypeCaches(meta._Internal);
dart.setLibraryUri(meta._Internal, I[255]);
meta._IsTest = class _IsTest extends core.Object {
static ['_#new#tearOff']() {
return new meta._IsTest.new();
}
};
(meta._IsTest.new = function() {
;
}).prototype = meta._IsTest.prototype;
dart.addTypeTests(meta._IsTest);
dart.addTypeCaches(meta._IsTest);
dart.setLibraryUri(meta._IsTest, I[255]);
meta._IsTestGroup = class _IsTestGroup extends core.Object {
static ['_#new#tearOff']() {
return new meta._IsTestGroup.new();
}
};
(meta._IsTestGroup.new = function() {
;
}).prototype = meta._IsTestGroup.prototype;
dart.addTypeTests(meta._IsTestGroup);
dart.addTypeCaches(meta._IsTestGroup);
dart.setLibraryUri(meta._IsTestGroup, I[255]);
meta._Literal = class _Literal extends core.Object {
static ['_#new#tearOff']() {
return new meta._Literal.new();
}
};
(meta._Literal.new = function() {
;
}).prototype = meta._Literal.prototype;
dart.addTypeTests(meta._Literal);
dart.addTypeCaches(meta._Literal);
dart.setLibraryUri(meta._Literal, I[255]);
meta._MustCallSuper = class _MustCallSuper extends core.Object {
static ['_#new#tearOff']() {
return new meta._MustCallSuper.new();
}
};
(meta._MustCallSuper.new = function() {
;
}).prototype = meta._MustCallSuper.prototype;
dart.addTypeTests(meta._MustCallSuper);
dart.addTypeCaches(meta._MustCallSuper);
dart.setLibraryUri(meta._MustCallSuper, I[255]);
meta._NonVirtual = class _NonVirtual extends core.Object {
static ['_#new#tearOff']() {
return new meta._NonVirtual.new();
}
};
(meta._NonVirtual.new = function() {
;
}).prototype = meta._NonVirtual.prototype;
dart.addTypeTests(meta._NonVirtual);
dart.addTypeCaches(meta._NonVirtual);
dart.setLibraryUri(meta._NonVirtual, I[255]);
meta._OptionalTypeArgs = class _OptionalTypeArgs extends core.Object {
static ['_#new#tearOff']() {
return new meta._OptionalTypeArgs.new();
}
};
(meta._OptionalTypeArgs.new = function() {
;
}).prototype = meta._OptionalTypeArgs.prototype;
dart.addTypeTests(meta._OptionalTypeArgs);
dart.addTypeCaches(meta._OptionalTypeArgs);
dart.setLibraryUri(meta._OptionalTypeArgs, I[255]);
meta._Protected = class _Protected extends core.Object {
static ['_#new#tearOff']() {
return new meta._Protected.new();
}
};
(meta._Protected.new = function() {
;
}).prototype = meta._Protected.prototype;
dart.addTypeTests(meta._Protected);
dart.addTypeCaches(meta._Protected);
dart.setLibraryUri(meta._Protected, I[255]);
meta._Sealed = class _Sealed extends core.Object {
static ['_#new#tearOff']() {
return new meta._Sealed.new();
}
};
(meta._Sealed.new = function() {
;
}).prototype = meta._Sealed.prototype;
dart.addTypeTests(meta._Sealed);
dart.addTypeCaches(meta._Sealed);
dart.setLibraryUri(meta._Sealed, I[255]);
meta._Virtual = class _Virtual extends core.Object {
static ['_#new#tearOff']() {
return new meta._Virtual.new();
}
};
(meta._Virtual.new = function() {
;
}).prototype = meta._Virtual.prototype;
dart.addTypeTests(meta._Virtual);
dart.addTypeCaches(meta._Virtual);
dart.setLibraryUri(meta._Virtual, I[255]);
meta._VisibleForOverriding = class _VisibleForOverriding extends core.Object {
static ['_#new#tearOff']() {
return new meta._VisibleForOverriding.new();
}
};
(meta._VisibleForOverriding.new = function() {
;
}).prototype = meta._VisibleForOverriding.prototype;
dart.addTypeTests(meta._VisibleForOverriding);
dart.addTypeCaches(meta._VisibleForOverriding);
dart.setLibraryUri(meta._VisibleForOverriding, I[255]);
meta._VisibleForTesting = class _VisibleForTesting extends core.Object {
static ['_#new#tearOff']() {
return new meta._VisibleForTesting.new();
}
};
(meta._VisibleForTesting.new = function() {
;
}).prototype = meta._VisibleForTesting.prototype;
dart.addTypeTests(meta._VisibleForTesting);
dart.addTypeCaches(meta._VisibleForTesting);
dart.setLibraryUri(meta._VisibleForTesting, I[255]);
dart.defineLazy(meta, {
/*meta.alwaysThrows*/get alwaysThrows() {
return C[214] || CT.C214;
},
/*meta.checked*/get checked() {
return C[215] || CT.C215;
},
/*meta.doNotStore*/get doNotStore() {
return C[216] || CT.C216;
},
/*meta.experimental*/get experimental() {
return C[217] || CT.C217;
},
/*meta.factory*/get factory() {
return C[218] || CT.C218;
},
/*meta.immutable*/get immutable() {
return C[219] || CT.C219;
},
/*meta.internal*/get internal() {
return C[220] || CT.C220;
},
/*meta.isTest*/get isTest() {
return C[221] || CT.C221;
},
/*meta.isTestGroup*/get isTestGroup() {
return C[222] || CT.C222;
},
/*meta.literal*/get literal() {
return C[223] || CT.C223;
},
/*meta.mustCallSuper*/get mustCallSuper() {
return C[224] || CT.C224;
},
/*meta.nonVirtual*/get nonVirtual() {
return C[225] || CT.C225;
},
/*meta.optionalTypeArgs*/get optionalTypeArgs() {
return C[226] || CT.C226;
},
/*meta.protected*/get protected() {
return C[227] || CT.C227;
},
/*meta.required*/get required() {
return C[228] || CT.C228;
},
/*meta.sealed*/get sealed() {
return C[229] || CT.C229;
},
/*meta.useResult*/get useResult() {
return C[230] || CT.C230;
},
/*meta.virtual*/get virtual() {
return C[231] || CT.C231;
},
/*meta.visibleForOverriding*/get visibleForOverriding() {
return C[232] || CT.C232;
},
/*meta.visibleForTesting*/get visibleForTesting() {
return C[233] || CT.C233;
}
}, false);
const _is_RejectErrorsSink_default = Symbol('_is_RejectErrorsSink_default');
reject_errors.RejectErrorsSink$ = dart.generic(T => {
var __t$StreamOfT = () => (__t$StreamOfT = dart.constFn(async.Stream$(T)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class RejectErrorsSink extends core.Object {
get done() {
return this[S$0._doneCompleter$3].future;
}
get [S$0._inAddStream$2]() {
return this[S$0._addStreamSubscription$2] != null;
}
static ['_#new#tearOff'](T, _inner) {
if (_inner == null) dart.nullFailed(I[256], 33, 25, "_inner");
return new (reject_errors.RejectErrorsSink$(T)).new(_inner);
}
get [S$0._canceled]() {
return this[S$0._doneCompleter$3].isCompleted;
}
add(data) {
T.as(data);
if (dart.test(this[S$0._closed$7])) dart.throw(new core.StateError.new("Cannot add event after closing."));
if (dart.test(this[S$0._inAddStream$2])) {
dart.throw(new core.StateError.new("Cannot add event while adding stream."));
}
if (dart.test(this[S$0._canceled])) return;
this[S$0._inner$9].add(data);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[256], 66, 17, "error");
if (dart.test(this[S$0._closed$7])) dart.throw(new core.StateError.new("Cannot add event after closing."));
if (dart.test(this[S$0._inAddStream$2])) {
dart.throw(new core.StateError.new("Cannot add event while adding stream."));
}
if (dart.test(this[S$0._canceled])) return;
this[S$0._addError$1](error, stackTrace);
}
[S$0._addError$1](error, stackTrace = null) {
if (error == null) dart.nullFailed(I[256], 80, 25, "error");
this[S$0._cancelAddStream]();
this[S$0._doneCompleter$3].completeError(error, stackTrace);
this[S$0._inner$9].close().catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
}
addStream(stream) {
__t$StreamOfT().as(stream);
if (stream == null) dart.nullFailed(I[256], 90, 36, "stream");
if (dart.test(this[S$0._closed$7])) dart.throw(new core.StateError.new("Cannot add stream after closing."));
if (dart.test(this[S$0._inAddStream$2])) {
dart.throw(new core.StateError.new("Cannot add stream while adding stream."));
}
if (dart.test(this[S$0._canceled])) return T$.FutureOfvoid().value();
let addStreamCompleter = this[S$0._addStreamCompleter$2] = T$.CompleterOfvoid().sync();
this[S$0._addStreamSubscription$2] = stream.listen(__t$TTovoid().as(dart.bind(this[S$0._inner$9], 'add')), {onError: dart.bind(this, S$0._addError$1), onDone: T$0.FutureOrNOfvoidTovoid().as(dart.bind(addStreamCompleter, 'complete'))});
return addStreamCompleter.future.then(dart.void, dart.fn(_ => {
this[S$0._addStreamCompleter$2] = null;
this[S$0._addStreamSubscription$2] = null;
}, T$0.voidToNull()));
}
close() {
if (dart.test(this[S$0._inAddStream$2])) {
dart.throw(new core.StateError.new("Cannot close sink while adding stream."));
}
if (dart.test(this[S$0._closed$7])) return this.done;
this[S$0._closed$7] = true;
if (!dart.test(this[S$0._canceled])) this[S$0._doneCompleter$3].complete(this[S$0._inner$9].close());
return this.done;
}
[S$0._cancelAddStream]() {
if (!dart.test(this[S$0._inAddStream$2])) return;
dart.nullCheck(this[S$0._addStreamCompleter$2]).complete(dart.nullCheck(this[S$0._addStreamSubscription$2]).cancel());
this[S$0._addStreamCompleter$2] = null;
this[S$0._addStreamSubscription$2] = null;
}
}
(RejectErrorsSink.new = function(_inner) {
if (_inner == null) dart.nullFailed(I[256], 33, 25, "_inner");
this[S$0._doneCompleter$3] = T$.CompleterOfvoid().new();
this[S$0._closed$7] = false;
this[S$0._addStreamSubscription$2] = null;
this[S$0._addStreamCompleter$2] = null;
this[S$0._inner$9] = _inner;
async['FutureExtensions|onError'](core.Null, core.Object, this[S$0._inner$9].done.then(core.Null, dart.fn(value => {
this[S$0._cancelAddStream]();
if (!dart.test(this[S$0._canceled])) this[S$0._doneCompleter$3].complete(value);
}, T$.dynamicToNull())), dart.fn((error, stackTrace) => {
if (error == null) dart.nullFailed(I[256], 37, 25, "error");
if (stackTrace == null) dart.nullFailed(I[256], 37, 32, "stackTrace");
this[S$0._cancelAddStream]();
if (!dart.test(this[S$0._canceled])) this[S$0._doneCompleter$3].completeError(error, stackTrace);
}, T$.ObjectAndStackTraceToNull()));
}).prototype = RejectErrorsSink.prototype;
dart.addTypeTests(RejectErrorsSink);
RejectErrorsSink.prototype[_is_RejectErrorsSink_default] = true;
dart.addTypeCaches(RejectErrorsSink);
RejectErrorsSink[dart.implements] = () => [async.StreamSink$(T)];
dart.setMethodSignature(RejectErrorsSink, () => ({
__proto__: dart.getMethods(RejectErrorsSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
[S$0._addError$1]: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future$(dart.void), [dart.nullable(core.Object)]),
close: dart.fnType(async.Future$(dart.void), []),
[S$0._cancelAddStream]: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(RejectErrorsSink, () => ({
__proto__: dart.getGetters(RejectErrorsSink.__proto__),
done: async.Future$(dart.void),
[S$0._inAddStream$2]: core.bool,
[S$0._canceled]: core.bool
}));
dart.setLibraryUri(RejectErrorsSink, I[257]);
dart.setFieldSignature(RejectErrorsSink, () => ({
__proto__: dart.getFields(RejectErrorsSink.__proto__),
[S$0._inner$9]: dart.finalFieldType(async.StreamSink$(T)),
[S$0._doneCompleter$3]: dart.finalFieldType(async.Completer$(dart.void)),
[S$0._closed$7]: dart.fieldType(core.bool),
[S$0._addStreamSubscription$2]: dart.fieldType(dart.nullable(async.StreamSubscription$(T))),
[S$0._addStreamCompleter$2]: dart.fieldType(dart.nullable(async.Completer$(dart.void)))
}));
return RejectErrorsSink;
});
reject_errors.RejectErrorsSink = reject_errors.RejectErrorsSink$();
dart.addTypeTests(reject_errors.RejectErrorsSink, _is_RejectErrorsSink_default);
const _is_HandlerTransformer_default = Symbol('_is_HandlerTransformer_default');
handler_transformer.HandlerTransformer$ = dart.generic((S, T) => {
var __t$_HandlerSinkOfS$T = () => (__t$_HandlerSinkOfS$T = dart.constFn(handler_transformer._HandlerSink$(S, T)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
class HandlerTransformer extends core.Object {
static ['_#new#tearOff'](S, T, _handleData, _handleError, _handleDone) {
return new (handler_transformer.HandlerTransformer$(S, T)).new(_handleData, _handleError, _handleDone);
}
bind(sink) {
__t$StreamSinkOfT().as(sink);
if (sink == null) dart.nullFailed(I[258], 33, 36, "sink");
return new (__t$_HandlerSinkOfS$T()).new(this, sink);
}
}
(HandlerTransformer.new = function(_handleData, _handleError, _handleDone) {
this[S$0._handleData] = _handleData;
this[S$0._handleError] = _handleError;
this[S$0._handleDone] = _handleDone;
;
}).prototype = HandlerTransformer.prototype;
dart.addTypeTests(HandlerTransformer);
HandlerTransformer.prototype[_is_HandlerTransformer_default] = true;
dart.addTypeCaches(HandlerTransformer);
HandlerTransformer[dart.implements] = () => [stream_sink_transformer.StreamSinkTransformer$(S, T)];
dart.setMethodSignature(HandlerTransformer, () => ({
__proto__: dart.getMethods(HandlerTransformer.__proto__),
bind: dart.fnType(async.StreamSink$(S), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(HandlerTransformer, I[259]);
dart.setFieldSignature(HandlerTransformer, () => ({
__proto__: dart.getFields(HandlerTransformer.__proto__),
[S$0._handleData]: dart.finalFieldType(dart.nullable(dart.fnType(dart.void, [S, async.EventSink$(T)]))),
[S$0._handleError]: dart.finalFieldType(dart.nullable(dart.fnType(dart.void, [core.Object, core.StackTrace, async.EventSink$(T)]))),
[S$0._handleDone]: dart.finalFieldType(dart.nullable(dart.fnType(dart.void, [async.EventSink$(T)])))
}));
return HandlerTransformer;
});
handler_transformer.HandlerTransformer = handler_transformer.HandlerTransformer$();
dart.addTypeTests(handler_transformer.HandlerTransformer, _is_HandlerTransformer_default);
const _is__HandlerSink_default = Symbol('_is__HandlerSink_default');
handler_transformer._HandlerSink$ = dart.generic((S, T) => {
var __t$SAndEventSinkOfTTovoid = () => (__t$SAndEventSinkOfTTovoid = dart.constFn(dart.fnType(dart.void, [S, __t$EventSinkOfT()])))();
var __t$SAndEventSinkOfTToNvoid = () => (__t$SAndEventSinkOfTToNvoid = dart.constFn(dart.nullable(__t$SAndEventSinkOfTTovoid())))();
var __t$StreamOfS = () => (__t$StreamOfS = dart.constFn(async.Stream$(S)))();
var __t$_StreamHandlerTransformerOfS$T = () => (__t$_StreamHandlerTransformerOfS$T = dart.constFn(async._StreamHandlerTransformer$(S, T)))();
var __t$_SafeCloseSinkOfT = () => (__t$_SafeCloseSinkOfT = dart.constFn(handler_transformer._SafeCloseSink$(T)))();
var __t$EventSinkOfT = () => (__t$EventSinkOfT = dart.constFn(async.EventSink$(T)))();
var __t$ObjectAndStackTraceAndEventSinkOfTTovoid = () => (__t$ObjectAndStackTraceAndEventSinkOfTTovoid = dart.constFn(dart.fnType(dart.void, [core.Object, core.StackTrace, __t$EventSinkOfT()])))();
var __t$ObjectAndStackTraceAndEventSinkOfTToNvoid = () => (__t$ObjectAndStackTraceAndEventSinkOfTToNvoid = dart.constFn(dart.nullable(__t$ObjectAndStackTraceAndEventSinkOfTTovoid())))();
var __t$EventSinkOfTTovoid = () => (__t$EventSinkOfTTovoid = dart.constFn(dart.fnType(dart.void, [__t$EventSinkOfT()])))();
var __t$EventSinkOfTToNvoid = () => (__t$EventSinkOfTToNvoid = dart.constFn(dart.nullable(__t$EventSinkOfTTovoid())))();
class _HandlerSink extends core.Object {
get done() {
return this[S$0._inner$10].done;
}
static ['_#new#tearOff'](S, T, _transformer, inner) {
if (_transformer == null) dart.nullFailed(I[258], 51, 21, "_transformer");
if (inner == null) dart.nullFailed(I[258], 51, 49, "inner");
return new (handler_transformer._HandlerSink$(S, T)).new(_transformer, inner);
}
add(event) {
S.as(event);
let handleData = __t$SAndEventSinkOfTToNvoid().as(this[S$0._transformer][S$0._handleData]);
if (handleData == null) {
this[S$0._inner$10].add(T.as(event));
} else {
handleData(event, this[S$0._safeCloseInner]);
}
}
addError(error, stackTrace = null) {
let t229;
if (error == null) dart.nullFailed(I[258], 66, 17, "error");
let handleError = __t$ObjectAndStackTraceAndEventSinkOfTToNvoid().as(this[S$0._transformer][S$0._handleError]);
if (handleError == null) {
this[S$0._inner$10].addError(error, stackTrace);
} else {
handleError(error, (t229 = stackTrace, t229 == null ? async.AsyncError.defaultStackTrace(error) : t229), this[S$0._safeCloseInner]);
}
}
addStream(stream) {
__t$StreamOfS().as(stream);
if (stream == null) dart.nullFailed(I[258], 77, 30, "stream");
return this[S$0._inner$10].addStream(stream.transform(T, new (__t$_StreamHandlerTransformerOfS$T()).new({handleData: __t$SAndEventSinkOfTToNvoid().as(this[S$0._transformer][S$0._handleData]), handleError: __t$ObjectAndStackTraceAndEventSinkOfTToNvoid().as(this[S$0._transformer][S$0._handleError]), handleDone: C[234] || CT.C234})));
}
close() {
let handleDone = __t$EventSinkOfTToNvoid().as(this[S$0._transformer][S$0._handleDone]);
if (handleDone == null) return this[S$0._inner$10].close();
handleDone(this[S$0._safeCloseInner]);
return this[S$0._inner$10].done;
}
}
(_HandlerSink.new = function(_transformer, inner) {
if (_transformer == null) dart.nullFailed(I[258], 51, 21, "_transformer");
if (inner == null) dart.nullFailed(I[258], 51, 49, "inner");
this[S$0._transformer] = _transformer;
this[S$0._inner$10] = inner;
this[S$0._safeCloseInner] = new (__t$_SafeCloseSinkOfT()).new(inner);
;
}).prototype = _HandlerSink.prototype;
dart.addTypeTests(_HandlerSink);
_HandlerSink.prototype[_is__HandlerSink_default] = true;
dart.addTypeCaches(_HandlerSink);
_HandlerSink[dart.implements] = () => [async.StreamSink$(S)];
dart.setMethodSignature(_HandlerSink, () => ({
__proto__: dart.getMethods(_HandlerSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, [])
}));
dart.setGetterSignature(_HandlerSink, () => ({
__proto__: dart.getGetters(_HandlerSink.__proto__),
done: async.Future
}));
dart.setLibraryUri(_HandlerSink, I[259]);
dart.setFieldSignature(_HandlerSink, () => ({
__proto__: dart.getFields(_HandlerSink.__proto__),
[S$0._transformer]: dart.finalFieldType(handler_transformer.HandlerTransformer$(S, T)),
[S$0._inner$10]: dart.finalFieldType(async.StreamSink$(T)),
[S$0._safeCloseInner]: dart.finalFieldType(async.StreamSink$(T))
}));
return _HandlerSink;
});
handler_transformer._HandlerSink = handler_transformer._HandlerSink$();
dart.addTypeTests(handler_transformer._HandlerSink, _is__HandlerSink_default);
const _is__SafeCloseSink_default = Symbol('_is__SafeCloseSink_default');
handler_transformer._SafeCloseSink$ = dart.generic(T => {
class _SafeCloseSink extends stream_sink.DelegatingStreamSink$(T) {
static ['_#new#tearOff'](T, inner) {
if (inner == null) dart.nullFailed(I[258], 101, 32, "inner");
return new (handler_transformer._SafeCloseSink$(T)).new(inner);
}
close() {
return super.close().catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
}
}
(_SafeCloseSink.new = function(inner) {
if (inner == null) dart.nullFailed(I[258], 101, 32, "inner");
_SafeCloseSink.__proto__.new.call(this, inner);
;
}).prototype = _SafeCloseSink.prototype;
dart.addTypeTests(_SafeCloseSink);
_SafeCloseSink.prototype[_is__SafeCloseSink_default] = true;
dart.addTypeCaches(_SafeCloseSink);
dart.setLibraryUri(_SafeCloseSink, I[259]);
return _SafeCloseSink;
});
handler_transformer._SafeCloseSink = handler_transformer._SafeCloseSink$();
dart.addTypeTests(handler_transformer._SafeCloseSink, _is__SafeCloseSink_default);
handler_transformer._closeSink = function _closeSink(sink) {
if (sink == null) dart.nullFailed(I[258], 108, 27, "sink");
sink.close();
};
const _is_StreamTransformerWrapper_default = Symbol('_is_StreamTransformerWrapper_default');
stream_transformer_wrapper.StreamTransformerWrapper$ = dart.generic((S, T) => {
var __t$_StreamTransformerWrapperSinkOfS$T = () => (__t$_StreamTransformerWrapperSinkOfS$T = dart.constFn(stream_transformer_wrapper._StreamTransformerWrapperSink$(S, T)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
class StreamTransformerWrapper extends core.Object {
get [S$0._transformer$2]() {
return this[S$0._transformer$1];
}
set [S$0._transformer$2](value) {
super[S$0._transformer$2] = value;
}
static ['_#new#tearOff'](S, T, _transformer) {
if (_transformer == null) dart.nullFailed(I[260], 14, 39, "_transformer");
return new (stream_transformer_wrapper.StreamTransformerWrapper$(S, T)).new(_transformer);
}
bind(sink) {
__t$StreamSinkOfT().as(sink);
if (sink == null) dart.nullFailed(I[260], 17, 36, "sink");
return new (__t$_StreamTransformerWrapperSinkOfS$T()).new(this[S$0._transformer$2], sink);
}
}
(StreamTransformerWrapper.new = function(_transformer) {
if (_transformer == null) dart.nullFailed(I[260], 14, 39, "_transformer");
this[S$0._transformer$1] = _transformer;
;
}).prototype = StreamTransformerWrapper.prototype;
dart.addTypeTests(StreamTransformerWrapper);
StreamTransformerWrapper.prototype[_is_StreamTransformerWrapper_default] = true;
dart.addTypeCaches(StreamTransformerWrapper);
StreamTransformerWrapper[dart.implements] = () => [stream_sink_transformer.StreamSinkTransformer$(S, T)];
dart.setMethodSignature(StreamTransformerWrapper, () => ({
__proto__: dart.getMethods(StreamTransformerWrapper.__proto__),
bind: dart.fnType(async.StreamSink$(S), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(StreamTransformerWrapper, I[261]);
dart.setFieldSignature(StreamTransformerWrapper, () => ({
__proto__: dart.getFields(StreamTransformerWrapper.__proto__),
[S$0._transformer$2]: dart.finalFieldType(async.StreamTransformer$(S, T))
}));
return StreamTransformerWrapper;
});
stream_transformer_wrapper.StreamTransformerWrapper = stream_transformer_wrapper.StreamTransformerWrapper$();
dart.addTypeTests(stream_transformer_wrapper.StreamTransformerWrapper, _is_StreamTransformerWrapper_default);
const _is__StreamTransformerWrapperSink_default = Symbol('_is__StreamTransformerWrapperSink_default');
stream_transformer_wrapper._StreamTransformerWrapperSink$ = dart.generic((S, T) => {
var __t$StreamControllerOfS = () => (__t$StreamControllerOfS = dart.constFn(async.StreamController$(S)))();
var __t$StreamOfS = () => (__t$StreamOfS = dart.constFn(async.Stream$(S)))();
var __t$TTovoid = () => (__t$TTovoid = dart.constFn(dart.fnType(dart.void, [T])))();
class _StreamTransformerWrapperSink extends core.Object {
get done() {
return this[S$0._inner$11].done;
}
static ['_#new#tearOff'](S, T, transformer, _inner) {
if (transformer == null) dart.nullFailed(I[260], 36, 31, "transformer");
if (_inner == null) dart.nullFailed(I[260], 36, 49, "_inner");
return new (stream_transformer_wrapper._StreamTransformerWrapperSink$(S, T)).new(transformer, _inner);
}
add(event) {
S.as(event);
this[S$0._controller$7].add(event);
}
addError(error, stackTrace = null) {
if (error == null) dart.nullFailed(I[260], 53, 17, "error");
this[S$0._controller$7].addError(error, stackTrace);
}
addStream(stream) {
__t$StreamOfS().as(stream);
if (stream == null) dart.nullFailed(I[260], 58, 30, "stream");
return this[S$0._controller$7].addStream(stream);
}
close() {
this[S$0._controller$7].close();
return this[S$0._inner$11].done;
}
}
(_StreamTransformerWrapperSink.new = function(transformer, _inner) {
if (transformer == null) dart.nullFailed(I[260], 36, 31, "transformer");
if (_inner == null) dart.nullFailed(I[260], 36, 49, "_inner");
this[S$0._controller$7] = __t$StreamControllerOfS().new({sync: true});
this[S$0._inner$11] = _inner;
this[S$0._controller$7].stream.transform(T, transformer).listen(__t$TTovoid().as(dart.bind(this[S$0._inner$11], 'add')), {onError: dart.bind(this[S$0._inner$11], 'addError'), onDone: dart.fn(() => {
this[S$0._inner$11].close().catchError(dart.fn(_ => {
}, T$.dynamicToNull()));
}, T$.VoidTovoid())});
}).prototype = _StreamTransformerWrapperSink.prototype;
dart.addTypeTests(_StreamTransformerWrapperSink);
_StreamTransformerWrapperSink.prototype[_is__StreamTransformerWrapperSink_default] = true;
dart.addTypeCaches(_StreamTransformerWrapperSink);
_StreamTransformerWrapperSink[dart.implements] = () => [async.StreamSink$(S)];
dart.setMethodSignature(_StreamTransformerWrapperSink, () => ({
__proto__: dart.getMethods(_StreamTransformerWrapperSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addError: dart.fnType(dart.void, [core.Object], [dart.nullable(core.StackTrace)]),
addStream: dart.fnType(async.Future, [dart.nullable(core.Object)]),
close: dart.fnType(async.Future, [])
}));
dart.setGetterSignature(_StreamTransformerWrapperSink, () => ({
__proto__: dart.getGetters(_StreamTransformerWrapperSink.__proto__),
done: async.Future
}));
dart.setLibraryUri(_StreamTransformerWrapperSink, I[261]);
dart.setFieldSignature(_StreamTransformerWrapperSink, () => ({
__proto__: dart.getFields(_StreamTransformerWrapperSink.__proto__),
[S$0._controller$7]: dart.finalFieldType(async.StreamController$(S)),
[S$0._inner$11]: dart.finalFieldType(async.StreamSink$(T))
}));
return _StreamTransformerWrapperSink;
});
stream_transformer_wrapper._StreamTransformerWrapperSink = stream_transformer_wrapper._StreamTransformerWrapperSink$();
dart.addTypeTests(stream_transformer_wrapper._StreamTransformerWrapperSink, _is__StreamTransformerWrapperSink_default);
const _is_TypeSafeStreamSinkTransformer_default = Symbol('_is_TypeSafeStreamSinkTransformer_default');
typed.TypeSafeStreamSinkTransformer$ = dart.generic((S, T) => {
var __t$StreamControllerOfS = () => (__t$StreamControllerOfS = dart.constFn(async.StreamController$(S)))();
var __t$StreamSinkOfT = () => (__t$StreamSinkOfT = dart.constFn(async.StreamSink$(T)))();
class TypeSafeStreamSinkTransformer extends core.Object {
static ['_#new#tearOff'](S, T, _inner) {
if (_inner == null) dart.nullFailed(I[262], 15, 38, "_inner");
return new (typed.TypeSafeStreamSinkTransformer$(S, T)).new(_inner);
}
bind(sink) {
let t229;
__t$StreamSinkOfT().as(sink);
if (sink == null) dart.nullFailed(I[262], 18, 36, "sink");
t229 = __t$StreamControllerOfS().new({sync: true});
return (() => {
t229.stream.cast(dart.dynamic).pipe(this[S$0._inner$12].bind(sink));
return t229;
})();
}
}
(TypeSafeStreamSinkTransformer.new = function(_inner) {
if (_inner == null) dart.nullFailed(I[262], 15, 38, "_inner");
this[S$0._inner$12] = _inner;
;
}).prototype = TypeSafeStreamSinkTransformer.prototype;
dart.addTypeTests(TypeSafeStreamSinkTransformer);
TypeSafeStreamSinkTransformer.prototype[_is_TypeSafeStreamSinkTransformer_default] = true;
dart.addTypeCaches(TypeSafeStreamSinkTransformer);
TypeSafeStreamSinkTransformer[dart.implements] = () => [stream_sink_transformer.StreamSinkTransformer$(S, T)];
dart.setMethodSignature(TypeSafeStreamSinkTransformer, () => ({
__proto__: dart.getMethods(TypeSafeStreamSinkTransformer.__proto__),
bind: dart.fnType(async.StreamSink$(S), [dart.nullable(core.Object)])
}));
dart.setLibraryUri(TypeSafeStreamSinkTransformer, I[263]);
dart.setFieldSignature(TypeSafeStreamSinkTransformer, () => ({
__proto__: dart.getFields(TypeSafeStreamSinkTransformer.__proto__),
[S$0._inner$12]: dart.finalFieldType(stream_sink_transformer.StreamSinkTransformer)
}));
return TypeSafeStreamSinkTransformer;
});
typed.TypeSafeStreamSinkTransformer = typed.TypeSafeStreamSinkTransformer$();
dart.addTypeTests(typed.TypeSafeStreamSinkTransformer, _is_TypeSafeStreamSinkTransformer_default);
digest_sink.DigestSink = class DigestSink extends core.Sink$(digest.Digest) {
get value() {
return dart.nullCheck(this[S$0._value$1]);
}
add(value) {
digest.Digest.as(value);
if (value == null) dart.nullFailed(I[264], 20, 19, "value");
if (this[S$0._value$1] != null) dart.throw(new core.StateError.new("add may only be called once."));
this[S$0._value$1] = value;
}
close() {
if (this[S$0._value$1] == null) dart.throw(new core.StateError.new("add must be called once."));
}
static ['_#new#tearOff']() {
return new digest_sink.DigestSink.new();
}
};
(digest_sink.DigestSink.new = function() {
this[S$0._value$1] = null;
;
}).prototype = digest_sink.DigestSink.prototype;
dart.addTypeTests(digest_sink.DigestSink);
dart.addTypeCaches(digest_sink.DigestSink);
dart.setMethodSignature(digest_sink.DigestSink, () => ({
__proto__: dart.getMethods(digest_sink.DigestSink.__proto__),
add: dart.fnType(dart.void, [dart.nullable(core.Object)]),
close: dart.fnType(dart.void, [])
}));
dart.setGetterSignature(digest_sink.DigestSink, () => ({
__proto__: dart.getGetters(digest_sink.DigestSink.__proto__),
value: digest.Digest
}));
dart.setLibraryUri(digest_sink.DigestSink, I[265]);
dart.setFieldSignature(digest_sink.DigestSink, () => ({
__proto__: dart.getFields(digest_sink.DigestSink.__proto__),
[S$0._value$1]: dart.fieldType(dart.nullable(digest.Digest))
}));
utils$0.add32 = function add32(x, y) {
if (x == null) dart.nullFailed(I[266], 15, 15, "x");
if (y == null) dart.nullFailed(I[266], 15, 22, "y");
return (dart.notNull(x) + dart.notNull(y) & 4294967295.0) >>> 0;
};
utils$0.rotl32 = function rotl32(val, shift) {
if (val == null) dart.nullFailed(I[266], 19, 16, "val");
if (shift == null) dart.nullFailed(I[266], 19, 25, "shift");
let modShift = dart.notNull(shift) & 31;
return (val[S$.$leftShift](modShift) & 4294967295.0 | ((dart.notNull(val) & 4294967295.0) >>> 0)[S$.$rightShift](32 - modShift)) >>> 0;
};
dart.defineLazy(utils$0, {
/*utils$0.mask32*/get mask32() {
return 4294967295.0;
},
/*utils$0.bitsPerByte*/get bitsPerByte() {
return 8;
},
/*utils$0.bytesPerWord*/get bytesPerWord() {
return 4;
}
}, false);
sha512_slowsinks._Sha64BitSink = class _Sha64BitSink extends hash_sink.HashSink {
get digest() {
return typed_data.Uint32List.view(this[S$0._digest$1][S$.$buffer], 0, this.digestBytes);
}
[S$0._shr](bits, word, offset, ret, offsetR) {
if (bits == null) dart.nullFailed(I[267], 80, 11, "bits");
if (word == null) dart.nullFailed(I[267], 80, 28, "word");
if (offset == null) dart.nullFailed(I[267], 80, 38, "offset");
if (ret == null) dart.nullFailed(I[267], 80, 57, "ret");
if (offsetR == null) dart.nullFailed(I[267], 80, 66, "offsetR");
ret[S$.$_set](0 + dart.notNull(offsetR), dart.notNull(bits) < 32 && dart.notNull(bits) >= 0 ? word[S$.$_get](0 + dart.notNull(offset))[S$.$rightShift](bits) : 0);
ret[S$.$_set](1 + dart.notNull(offsetR), dart.notNull(bits) > 32 ? word[S$.$_get](0 + dart.notNull(offset))[S$.$rightShift](dart.notNull(bits) - 32) : bits === 32 ? word[S$.$_get](0 + dart.notNull(offset)) : dart.notNull(bits) >= 0 ? (word[S$.$_get](0 + dart.notNull(offset))[S$.$leftShift](32 - dart.notNull(bits)) | word[S$.$_get](1 + dart.notNull(offset))[S$.$rightShift](bits)) >>> 0 : 0);
}
[S$0._shl](bits, word, offset, ret, offsetR) {
if (bits == null) dart.nullFailed(I[267], 94, 11, "bits");
if (word == null) dart.nullFailed(I[267], 94, 28, "word");
if (offset == null) dart.nullFailed(I[267], 94, 38, "offset");
if (ret == null) dart.nullFailed(I[267], 94, 57, "ret");
if (offsetR == null) dart.nullFailed(I[267], 94, 66, "offsetR");
ret[S$.$_set](0 + dart.notNull(offsetR), dart.notNull(bits) > 32 ? word[S$.$_get](1 + dart.notNull(offset))[S$.$leftShift](dart.notNull(bits) - 32) : bits === 32 ? word[S$.$_get](1 + dart.notNull(offset)) : dart.notNull(bits) >= 0 ? (word[S$.$_get](0 + dart.notNull(offset))[S$.$leftShift](bits) | word[S$.$_get](1 + dart.notNull(offset))[S$.$rightShift](32 - dart.notNull(bits))) >>> 0 : 0);
ret[S$.$_set](1 + dart.notNull(offsetR), dart.notNull(bits) < 32 && dart.notNull(bits) >= 0 ? word[S$.$_get](1 + dart.notNull(offset))[S$.$leftShift](bits) : 0);
}
[S$0._or](word1, offset1, word2, offset2, ret, offsetR) {
if (word1 == null) dart.nullFailed(I[267], 107, 23, "word1");
if (offset1 == null) dart.nullFailed(I[267], 107, 34, "offset1");
if (word2 == null) dart.nullFailed(I[267], 107, 54, "word2");
if (offset2 == null) dart.nullFailed(I[267], 107, 65, "offset2");
if (ret == null) dart.nullFailed(I[267], 108, 18, "ret");
if (offsetR == null) dart.nullFailed(I[267], 108, 27, "offsetR");
ret[S$.$_set](0 + dart.notNull(offsetR), (dart.notNull(word1[S$.$_get](0 + dart.notNull(offset1))) | dart.notNull(word2[S$.$_get](0 + dart.notNull(offset2)))) >>> 0);
ret[S$.$_set](1 + dart.notNull(offsetR), (dart.notNull(word1[S$.$_get](1 + dart.notNull(offset1))) | dart.notNull(word2[S$.$_get](1 + dart.notNull(offset2)))) >>> 0);
}
[S$0._xor](word1, offset1, word2, offset2, ret, offsetR) {
if (word1 == null) dart.nullFailed(I[267], 113, 24, "word1");
if (offset1 == null) dart.nullFailed(I[267], 113, 35, "offset1");
if (word2 == null) dart.nullFailed(I[267], 113, 55, "word2");
if (offset2 == null) dart.nullFailed(I[267], 113, 66, "offset2");
if (ret == null) dart.nullFailed(I[267], 114, 18, "ret");
if (offsetR == null) dart.nullFailed(I[267], 114, 27, "offsetR");
ret[S$.$_set](0 + dart.notNull(offsetR), (dart.notNull(word1[S$.$_get](0 + dart.notNull(offset1))) ^ dart.notNull(word2[S$.$_get](0 + dart.notNull(offset2)))) >>> 0);
ret[S$.$_set](1 + dart.notNull(offsetR), (dart.notNull(word1[S$.$_get](1 + dart.notNull(offset1))) ^ dart.notNull(word2[S$.$_get](1 + dart.notNull(offset2)))) >>> 0);
}
[S$0._add$2](word1, offset1, word2, offset2, ret, offsetR) {
if (word1 == null) dart.nullFailed(I[267], 119, 24, "word1");
if (offset1 == null) dart.nullFailed(I[267], 119, 35, "offset1");
if (word2 == null) dart.nullFailed(I[267], 119, 55, "word2");
if (offset2 == null) dart.nullFailed(I[267], 119, 66, "offset2");
if (ret == null) dart.nullFailed(I[267], 120, 18, "ret");
if (offsetR == null) dart.nullFailed(I[267], 120, 27, "offsetR");
ret[S$.$_set](1 + dart.notNull(offsetR), dart.notNull(word1[S$.$_get](1 + dart.notNull(offset1))) + dart.notNull(word2[S$.$_get](1 + dart.notNull(offset2))));
ret[S$.$_set](0 + dart.notNull(offsetR), dart.notNull(word1[S$.$_get](0 + dart.notNull(offset1))) + dart.notNull(word2[S$.$_get](0 + dart.notNull(offset2))) + (dart.notNull(ret[S$.$_get](1 + dart.notNull(offsetR))) < dart.notNull(word1[S$.$_get](1 + dart.notNull(offset1))) ? 1 : 0));
}
[S$0._addTo2](word1, offset1, word2, offset2) {
let t230, t229, t230$, t229$;
if (word1 == null) dart.nullFailed(I[267], 127, 27, "word1");
if (offset1 == null) dart.nullFailed(I[267], 127, 38, "offset1");
if (word2 == null) dart.nullFailed(I[267], 127, 58, "word2");
if (offset2 == null) dart.nullFailed(I[267], 127, 69, "offset2");
let _addTemp = null;
_addTemp = word1[S$.$_get](1 + dart.notNull(offset1));
t229 = word1;
t230 = 1 + dart.notNull(offset1);
t229[S$.$_set](t230, dart.notNull(t229[S$.$_get](t230)) + dart.notNull(word2[S$.$_get](1 + dart.notNull(offset2))));
t229$ = word1;
t230$ = 0 + dart.notNull(offset1);
t229$[S$.$_set](t230$, dart.notNull(t229$[S$.$_get](t230$)) + (dart.notNull(word2[S$.$_get](0 + dart.notNull(offset2))) + (dart.notNull(word1[S$.$_get](1 + dart.notNull(offset1))) < dart.notNull(_addTemp) ? 1 : 0)));
}
[S$0._rotr](bits, word, offset, ret, offsetR) {
if (bits == null) dart.nullFailed(I[267], 158, 11, "bits");
if (word == null) dart.nullFailed(I[267], 158, 28, "word");
if (offset == null) dart.nullFailed(I[267], 158, 38, "offset");
if (ret == null) dart.nullFailed(I[267], 158, 57, "ret");
if (offsetR == null) dart.nullFailed(I[267], 158, 66, "offsetR");
this[S$0._shr](bits, word, offset, this[S$0._nums], 0);
this[S$0._shl](64 - dart.notNull(bits), word, offset, this[S$0._nums], 2);
this[S$0._or](this[S$0._nums], 0, this[S$0._nums], 2, ret, offsetR);
}
[S$0._bsig0$1](word, offset, ret, offsetR) {
if (word == null) dart.nullFailed(I[267], 164, 26, "word");
if (offset == null) dart.nullFailed(I[267], 164, 36, "offset");
if (ret == null) dart.nullFailed(I[267], 164, 55, "ret");
if (offsetR == null) dart.nullFailed(I[267], 164, 64, "offsetR");
this[S$0._rotr](28, word, offset, this[S$0._nums], 4);
this[S$0._rotr](34, word, offset, this[S$0._nums], 6);
this[S$0._rotr](39, word, offset, this[S$0._nums], 8);
this[S$0._xor](this[S$0._nums], 6, this[S$0._nums], 8, this[S$0._nums], 10);
this[S$0._xor](this[S$0._nums], 4, this[S$0._nums], 10, ret, offsetR);
}
[S$0._bsig1$1](word, offset, ret, offsetR) {
if (word == null) dart.nullFailed(I[267], 172, 26, "word");
if (offset == null) dart.nullFailed(I[267], 172, 36, "offset");
if (ret == null) dart.nullFailed(I[267], 172, 55, "ret");
if (offsetR == null) dart.nullFailed(I[267], 172, 64, "offsetR");
this[S$0._rotr](14, word, offset, this[S$0._nums], 4);
this[S$0._rotr](18, word, offset, this[S$0._nums], 6);
this[S$0._rotr](41, word, offset, this[S$0._nums], 8);
this[S$0._xor](this[S$0._nums], 6, this[S$0._nums], 8, this[S$0._nums], 10);
this[S$0._xor](this[S$0._nums], 4, this[S$0._nums], 10, ret, offsetR);
}
[S$0._ssig0$1](word, offset, ret, offsetR) {
if (word == null) dart.nullFailed(I[267], 180, 26, "word");
if (offset == null) dart.nullFailed(I[267], 180, 36, "offset");
if (ret == null) dart.nullFailed(I[267], 180, 55, "ret");
if (offsetR == null) dart.nullFailed(I[267], 180, 64, "offsetR");
this[S$0._rotr](1, word, offset, this[S$0._nums], 4);
this[S$0._rotr](8, word, offset, this[S$0._nums], 6);
this[S$0._shr](7, word, offset, this[S$0._nums], 8);
this[S$0._xor](this[S$0._nums], 6, this[S$0._nums], 8, this[S$0._nums], 10);
this[S$0._xor](this[S$0._nums], 4, this[S$0._nums], 10, ret, offsetR);
}
[S$0._ssig1$1](word, offset, ret, offsetR) {
if (word == null) dart.nullFailed(I[267], 188, 26, "word");
if (offset == null) dart.nullFailed(I[267], 188, 36, "offset");
if (ret == null) dart.nullFailed(I[267], 188, 55, "ret");
if (offsetR == null) dart.nullFailed(I[267], 188, 64, "offsetR");
this[S$0._rotr](19, word, offset, this[S$0._nums], 4);
this[S$0._rotr](61, word, offset, this[S$0._nums], 6);
this[S$0._shr](6, word, offset, this[S$0._nums], 8);
this[S$0._xor](this[S$0._nums], 6, this[S$0._nums], 8, this[S$0._nums], 10);
this[S$0._xor](this[S$0._nums], 4, this[S$0._nums], 10, ret, offsetR);
}
[S$0._ch$1](x, offsetX, y, offsetY, z, offsetZ, ret, offsetR) {
if (x == null) dart.nullFailed(I[267], 196, 23, "x");
if (offsetX == null) dart.nullFailed(I[267], 196, 30, "offsetX");
if (y == null) dart.nullFailed(I[267], 196, 50, "y");
if (offsetY == null) dart.nullFailed(I[267], 196, 57, "offsetY");
if (z == null) dart.nullFailed(I[267], 196, 77, "z");
if (offsetZ == null) dart.nullFailed(I[267], 197, 11, "offsetZ");
if (ret == null) dart.nullFailed(I[267], 197, 31, "ret");
if (offsetR == null) dart.nullFailed(I[267], 197, 40, "offsetR");
ret[S$.$_set](0 + dart.notNull(offsetR), (dart.notNull(x[S$.$_get](0 + dart.notNull(offsetX))) & (dart.notNull(y[S$.$_get](0 + dart.notNull(offsetY))) ^ dart.notNull(z[S$.$_get](0 + dart.notNull(offsetZ)))) >>> 0 ^ dart.notNull(z[S$.$_get](0 + dart.notNull(offsetZ)))) >>> 0);
ret[S$.$_set](1 + dart.notNull(offsetR), (dart.notNull(x[S$.$_get](1 + dart.notNull(offsetX))) & (dart.notNull(y[S$.$_get](1 + dart.notNull(offsetY))) ^ dart.notNull(z[S$.$_get](1 + dart.notNull(offsetZ)))) >>> 0 ^ dart.notNull(z[S$.$_get](1 + dart.notNull(offsetZ)))) >>> 0);
}
[S$0._maj$1](x, offsetX, y, offsetY, z, offsetZ, ret, offsetR) {
if (x == null) dart.nullFailed(I[267], 204, 24, "x");
if (offsetX == null) dart.nullFailed(I[267], 204, 31, "offsetX");
if (y == null) dart.nullFailed(I[267], 204, 51, "y");
if (offsetY == null) dart.nullFailed(I[267], 204, 58, "offsetY");
if (z == null) dart.nullFailed(I[267], 204, 78, "z");
if (offsetZ == null) dart.nullFailed(I[267], 205, 11, "offsetZ");
if (ret == null) dart.nullFailed(I[267], 205, 31, "ret");
if (offsetR == null) dart.nullFailed(I[267], 205, 40, "offsetR");
ret[S$.$_set](0 + dart.notNull(offsetR), (dart.notNull(x[S$.$_get](0 + dart.notNull(offsetX))) & (dart.notNull(y[S$.$_get](0 + dart.notNull(offsetY))) | dart.notNull(z[S$.$_get](0 + dart.notNull(offsetZ)))) >>> 0 | (dart.notNull(y[S$.$_get](0 + dart.notNull(offsetY))) & dart.notNull(z[S$.$_get](0 + dart.notNull(offsetZ)))) >>> 0) >>> 0);
ret[S$.$_set](1 + dart.notNull(offsetR), (dart.notNull(x[S$.$_get](1 + dart.notNull(offsetX))) & (dart.notNull(y[S$.$_get](1 + dart.notNull(offsetY))) | dart.notNull(z[S$.$_get](1 + dart.notNull(offsetZ)))) >>> 0 | (dart.notNull(y[S$.$_get](1 + dart.notNull(offsetY))) & dart.notNull(z[S$.$_get](1 + dart.notNull(offsetZ)))) >>> 0) >>> 0);
}
updateHash(chunk) {
if (chunk == null) dart.nullFailed(I[267], 213, 30, "chunk");
if (!(chunk[S$.$length] === 32)) dart.assertFailed(null, I[267], 214, 12, "chunk.length == 32");
for (let i = 0; i < 32; i = i + 1) {
this[S$0._extended$2][S$.$_set](i, chunk[S$.$_get](i));
}
for (let i = 32; i < 160; i = i + 2) {
this[S$0._ssig1$1](this[S$0._extended$2], i - 2 * 2, this[S$0._nums], 28);
this[S$0._add$2](this[S$0._nums], 28, this[S$0._extended$2], i - 7 * 2, this[S$0._nums], 30);
this[S$0._ssig0$1](this[S$0._extended$2], i - 15 * 2, this[S$0._nums], 28);
this[S$0._add$2](this[S$0._nums], 28, this[S$0._extended$2], i - 16 * 2, this[S$0._nums], 32);
this[S$0._add$2](this[S$0._nums], 30, this[S$0._nums], 32, this[S$0._extended$2], i);
}
this[S$0._nums][S$.$setRange](12, 26 + 2, this[S$0._digest$1]);
for (let i = 0; i < 160; i = i + 2) {
this[S$0._bsig1$1](this[S$0._nums], 20, this[S$0._nums], 28);
this[S$0._add$2](this[S$0._nums], 26, this[S$0._nums], 28, this[S$0._nums], 30);
this[S$0._ch$1](this[S$0._nums], 20, this[S$0._nums], 22, this[S$0._nums], 24, this[S$0._nums], 32);
this[S$0._add$2](this[S$0._nums], 30, this[S$0._nums], 32, this[S$0._nums], 34);
this[S$0._add$2](sha512_slowsinks._noise32, i, this[S$0._extended$2], i, this[S$0._nums], 36);
this[S$0._add$2](this[S$0._nums], 34, this[S$0._nums], 36, this[S$0._nums], 28);
this[S$0._bsig0$1](this[S$0._nums], 12, this[S$0._nums], 32);
this[S$0._maj$1](this[S$0._nums], 12, this[S$0._nums], 14, this[S$0._nums], 16, this[S$0._nums], 34);
this[S$0._add$2](this[S$0._nums], 32, this[S$0._nums], 34, this[S$0._nums], 30);
this[S$0._nums][S$.$_set](26, this[S$0._nums][S$.$_get](24));
this[S$0._nums][S$.$_set](26 + 1, this[S$0._nums][S$.$_get](24 + 1));
this[S$0._nums][S$.$_set](24, this[S$0._nums][S$.$_get](22));
this[S$0._nums][S$.$_set](24 + 1, this[S$0._nums][S$.$_get](22 + 1));
this[S$0._nums][S$.$_set](22, this[S$0._nums][S$.$_get](20));
this[S$0._nums][S$.$_set](22 + 1, this[S$0._nums][S$.$_get](20 + 1));
this[S$0._add$2](this[S$0._nums], 18, this[S$0._nums], 28, this[S$0._nums], 20);
this[S$0._nums][S$.$_set](18, this[S$0._nums][S$.$_get](16));
this[S$0._nums][S$.$_set](18 + 1, this[S$0._nums][S$.$_get](16 + 1));
this[S$0._nums][S$.$_set](16, this[S$0._nums][S$.$_get](14));
this[S$0._nums][S$.$_set](16 + 1, this[S$0._nums][S$.$_get](14 + 1));
this[S$0._nums][S$.$_set](14, this[S$0._nums][S$.$_get](12));
this[S$0._nums][S$.$_set](14 + 1, this[S$0._nums][S$.$_get](12 + 1));
this[S$0._add$2](this[S$0._nums], 28, this[S$0._nums], 30, this[S$0._nums], 12);
}
this[S$0._addTo2](this[S$0._digest$1], 0, this[S$0._nums], 12);
this[S$0._addTo2](this[S$0._digest$1], 2, this[S$0._nums], 14);
this[S$0._addTo2](this[S$0._digest$1], 4, this[S$0._nums], 16);
this[S$0._addTo2](this[S$0._digest$1], 6, this[S$0._nums], 18);
this[S$0._addTo2](this[S$0._digest$1], 8, this[S$0._nums], 20);
this[S$0._addTo2](this[S$0._digest$1], 10, this[S$0._nums], 22);
this[S$0._addTo2](this[S$0._digest$1], 12, this[S$0._nums], 24);
this[S$0._addTo2](this[S$0._digest$1], 14, this[S$0._nums], 26);
}
};
(sha512_slowsinks._Sha64BitSink.new = function(sink, _digest) {
if (sink == null) dart.nullFailed(I[267], 74, 30, "sink");
if (_digest == null) dart.nullFailed(I[267], 74, 41, "_digest");
this[S$0._extended$2] = _native_typed_data.NativeUint32List.new(160);
this[S$0._nums] = _native_typed_data.NativeUint32List.new(12 + 16 + 10);
this[S$0._digest$1] = _digest;
sha512_slowsinks._Sha64BitSink.__proto__.new.call(this, sink, 32, {signatureBytes: 16});
;
}).prototype = sha512_slowsinks._Sha64BitSink.prototype;
dart.addTypeTests(sha512_slowsinks._Sha64BitSink);
dart.addTypeCaches(sha512_slowsinks._Sha64BitSink);
dart.setMethodSignature(sha512_slowsinks._Sha64BitSink, () => ({
__proto__: dart.getMethods(sha512_slowsinks._Sha64BitSink.__proto__),
[S$0._shr]: dart.fnType(dart.void, [core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._shl]: dart.fnType(dart.void, [core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._or]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._xor]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._add$2]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._addTo2]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._rotr]: dart.fnType(dart.void, [core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._bsig0$1]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._bsig1$1]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._ssig0$1]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._ssig1$1]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._ch$1]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
[S$0._maj$1]: dart.fnType(dart.void, [typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int, typed_data.Uint32List, core.int]),
updateHash: dart.fnType(dart.void, [typed_data.Uint32List])
}));
dart.setGetterSignature(sha512_slowsinks._Sha64BitSink, () => ({
__proto__: dart.getGetters(sha512_slowsinks._Sha64BitSink.__proto__),
digest: typed_data.Uint32List
}));
dart.setLibraryUri(sha512_slowsinks._Sha64BitSink, I[268]);
dart.setFieldSignature(sha512_slowsinks._Sha64BitSink, () => ({
__proto__: dart.getFields(sha512_slowsinks._Sha64BitSink.__proto__),
[S$0._digest$1]: dart.finalFieldType(typed_data.Uint32List),
[S$0._extended$2]: dart.finalFieldType(typed_data.Uint32List),
[S$0._nums]: dart.finalFieldType(typed_data.Uint32List)
}));
dart.setStaticFieldSignature(sha512_slowsinks._Sha64BitSink, () => ['_rotrIndex1', '_rotrIndex2', '_sigIndex1', '_sigIndex2', '_sigIndex3', '_sigIndex4', '_aIndex', '_bIndex', '_cIndex', '_dIndex', '_eIndex', '_fIndex', '_gIndex', '_hIndex', '_tmp1', '_tmp2', '_tmp3', '_tmp4', '_tmp5']);
dart.defineLazy(sha512_slowsinks._Sha64BitSink, {
/*sha512_slowsinks._Sha64BitSink._rotrIndex1*/get _rotrIndex1() {
return 0;
},
/*sha512_slowsinks._Sha64BitSink._rotrIndex2*/get _rotrIndex2() {
return 2;
},
/*sha512_slowsinks._Sha64BitSink._sigIndex1*/get _sigIndex1() {
return 4;
},
/*sha512_slowsinks._Sha64BitSink._sigIndex2*/get _sigIndex2() {
return 6;
},
/*sha512_slowsinks._Sha64BitSink._sigIndex3*/get _sigIndex3() {
return 8;
},
/*sha512_slowsinks._Sha64BitSink._sigIndex4*/get _sigIndex4() {
return 10;
},
/*sha512_slowsinks._Sha64BitSink._aIndex*/get _aIndex() {
return 12;
},
/*sha512_slowsinks._Sha64BitSink._bIndex*/get _bIndex() {
return 14;
},
/*sha512_slowsinks._Sha64BitSink._cIndex*/get _cIndex() {
return 16;
},
/*sha512_slowsinks._Sha64BitSink._dIndex*/get _dIndex() {
return 18;
},
/*sha512_slowsinks._Sha64BitSink._eIndex*/get _eIndex() {
return 20;
},
/*sha512_slowsinks._Sha64BitSink._fIndex*/get _fIndex() {
return 22;
},
/*sha512_slowsinks._Sha64BitSink._gIndex*/get _gIndex() {
return 24;
},
/*sha512_slowsinks._Sha64BitSink._hIndex*/get _hIndex() {
return 26;
},
/*sha512_slowsinks._Sha64BitSink._tmp1*/get _tmp1() {
return 28;
},
/*sha512_slowsinks._Sha64BitSink._tmp2*/get _tmp2() {
return 30;
},
/*sha512_slowsinks._Sha64BitSink._tmp3*/get _tmp3() {
return 32;
},
/*sha512_slowsinks._Sha64BitSink._tmp4*/get _tmp4() {
return 34;
},
/*sha512_slowsinks._Sha64BitSink._tmp5*/get _tmp5() {
return 36;
}
}, false);
sha512_slowsinks.Sha384Sink = class Sha384Sink extends sha512_slowsinks._Sha64BitSink {
get digestBytes() {
return this[S$0.digestBytes];
}
set digestBytes(value) {
super.digestBytes = value;
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[267], 283, 27, "sink");
return new sha512_slowsinks.Sha384Sink.new(sink);
}
};
(sha512_slowsinks.Sha384Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[267], 283, 27, "sink");
this[S$0.digestBytes] = 12;
sha512_slowsinks.Sha384Sink.__proto__.new.call(this, sink, _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([3418070365, 3238371032, 1654270250, 914150663, 2438529370, 812702999, 355462360, 4144912697, 1731405415, 4290775857, 2394180231, 1750603025, 3675008525, 1694076839, 1203062813, 3204075428])));
;
}).prototype = sha512_slowsinks.Sha384Sink.prototype;
dart.addTypeTests(sha512_slowsinks.Sha384Sink);
dart.addTypeCaches(sha512_slowsinks.Sha384Sink);
dart.setLibraryUri(sha512_slowsinks.Sha384Sink, I[268]);
dart.setFieldSignature(sha512_slowsinks.Sha384Sink, () => ({
__proto__: dart.getFields(sha512_slowsinks.Sha384Sink.__proto__),
digestBytes: dart.finalFieldType(core.int)
}));
sha512_slowsinks.Sha512Sink = class Sha512Sink extends sha512_slowsinks._Sha64BitSink {
get digestBytes() {
return this[S$0.digestBytes$1];
}
set digestBytes(value) {
super.digestBytes = value;
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[267], 314, 27, "sink");
return new sha512_slowsinks.Sha512Sink.new(sink);
}
};
(sha512_slowsinks.Sha512Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[267], 314, 27, "sink");
this[S$0.digestBytes$1] = 16;
sha512_slowsinks.Sha512Sink.__proto__.new.call(this, sink, _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([1779033703, 4089235720, 3144134277, 2227873595, 1013904242, 4271175723, 2773480762, 1595750129, 1359893119, 2917565137, 2600822924, 725511199, 528734635, 4215389547, 1541459225, 327033209])));
;
}).prototype = sha512_slowsinks.Sha512Sink.prototype;
dart.addTypeTests(sha512_slowsinks.Sha512Sink);
dart.addTypeCaches(sha512_slowsinks.Sha512Sink);
dart.setLibraryUri(sha512_slowsinks.Sha512Sink, I[268]);
dart.setFieldSignature(sha512_slowsinks.Sha512Sink, () => ({
__proto__: dart.getFields(sha512_slowsinks.Sha512Sink.__proto__),
digestBytes: dart.finalFieldType(core.int)
}));
sha512_slowsinks.Sha512224Sink = class Sha512224Sink extends sha512_slowsinks._Sha64BitSink {
get digestBytes() {
return this[S$0.digestBytes$2];
}
set digestBytes(value) {
super.digestBytes = value;
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[267], 339, 30, "sink");
return new sha512_slowsinks.Sha512224Sink.new(sink);
}
};
(sha512_slowsinks.Sha512224Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[267], 339, 30, "sink");
this[S$0.digestBytes$2] = 7;
sha512_slowsinks.Sha512224Sink.__proto__.new.call(this, sink, _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([2352822216, 424955298, 1944164710, 2312950998, 502970286, 855612546, 1738396948, 1479516111, 258812777, 2077511080, 2011393907, 79989058, 1067287976, 1780299464, 286451373, 2446758561])));
;
}).prototype = sha512_slowsinks.Sha512224Sink.prototype;
dart.addTypeTests(sha512_slowsinks.Sha512224Sink);
dart.addTypeCaches(sha512_slowsinks.Sha512224Sink);
dart.setLibraryUri(sha512_slowsinks.Sha512224Sink, I[268]);
dart.setFieldSignature(sha512_slowsinks.Sha512224Sink, () => ({
__proto__: dart.getFields(sha512_slowsinks.Sha512224Sink.__proto__),
digestBytes: dart.finalFieldType(core.int)
}));
sha512_slowsinks.Sha512256Sink = class Sha512256Sink extends sha512_slowsinks._Sha64BitSink {
get digestBytes() {
return this[S$0.digestBytes$3];
}
set digestBytes(value) {
super.digestBytes = value;
}
static ['_#new#tearOff'](sink) {
if (sink == null) dart.nullFailed(I[267], 363, 30, "sink");
return new sha512_slowsinks.Sha512256Sink.new(sink);
}
};
(sha512_slowsinks.Sha512256Sink.new = function(sink) {
if (sink == null) dart.nullFailed(I[267], 363, 30, "sink");
this[S$0.digestBytes$3] = 8;
sha512_slowsinks.Sha512256Sink.__proto__.new.call(this, sink, _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([573645204, 4230739756, 2673172387, 3360449730, 596883563, 1867755857, 2520282905, 1497426621, 2519219938, 2827943907, 3193839141, 1401305490, 721525244, 746961066, 246885852, 2177182882])));
;
}).prototype = sha512_slowsinks.Sha512256Sink.prototype;
dart.addTypeTests(sha512_slowsinks.Sha512256Sink);
dart.addTypeCaches(sha512_slowsinks.Sha512256Sink);
dart.setLibraryUri(sha512_slowsinks.Sha512256Sink, I[268]);
dart.setFieldSignature(sha512_slowsinks.Sha512256Sink, () => ({
__proto__: dart.getFields(sha512_slowsinks.Sha512256Sink.__proto__),
digestBytes: dart.finalFieldType(core.int)
}));
dart.defineLazy(sha512_slowsinks, {
/*sha512_slowsinks._noise32*/get _noise32() {
return _native_typed_data.NativeUint32List.fromList(T$.JSArrayOfint().of([1116352408, 3609767458, 1899447441, 602891725, 3049323471, 3964484399, 3921009573, 2173295548, 961987163, 4081628472, 1508970993, 3053834265, 2453635748, 2937671579, 2870763221, 3664609560, 3624381080, 2734883394, 310598401, 1164996542, 607225278, 1323610764, 1426881987, 3590304994, 1925078388, 4068182383, 2162078206, 991336113, 2614888103, 633803317, 3248222580, 3479774868, 3835390401, 2666613458, 4022224774, 944711139, 264347078, 2341262773, 604807628, 2007800933, 770255983, 1495990901, 1249150122, 1856431235, 1555081692, 3175218132, 1996064986, 2198950837, 2554220882, 3999719339, 2821834349, 766784016, 2952996808, 2566594879, 3210313671, 3203337956, 3336571891, 1034457026, 3584528711, 2466948901, 113926993, 3758326383, 338241895, 168717936, 666307205, 1188179964, 773529912, 1546045734, 1294757372, 1522805485, 1396182291, 2643833823, 1695183700, 2343527390, 1986661051, 1014477480, 2177026350, 1206759142, 2456956037, 344077627, 2730485921, 1290863460, 2820302411, 3158454273, 3259730800, 3505952657, 3345764771, 106217008, 3516065817, 3606008344, 3600352804, 1432725776, 4094571909, 1467031594, 275423344, 851169720, 430227734, 3100823752, 506948616, 1363258195, 659060556, 3750685593, 883997877, 3785050280, 958139571, 3318307427, 1322822218, 3812723403, 1537002063, 2003034995, 1747873779, 3602036899, 1955562222, 1575990012, 2024104815, 1125592928, 2227730452, 2716904306, 2361852424, 442776044, 2428436474, 593698344, 2756734187, 3733110249, 3204031479, 2999351573, 3329325298, 3815920427, 3391569614, 3928383900, 3515267271, 566280711, 3940187606, 3454069534, 4118630271, 4000239992, 116418474, 1914138554, 174292421, 2731055270, 289380356, 3203993006, 460393269, 320620315, 685471733, 587496836, 852142971, 1086792851, 1017036298, 365543100, 1126000580, 2618297676, 1288033470, 3409855158, 1501505948, 4234509866, 1607167915, 987167468, 1816402316, 1246189591]));
}
}, false);
meta_meta.Target = class Target extends core.Object {
get kinds() {
return this[S$0.kinds];
}
set kinds(value) {
super.kinds = value;
}
static ['_#new#tearOff'](kinds) {
if (kinds == null) dart.nullFailed(I[269], 27, 21, "kinds");
return new meta_meta.Target.new(kinds);
}
};
(meta_meta.Target.new = function(kinds) {
if (kinds == null) dart.nullFailed(I[269], 27, 21, "kinds");
this[S$0.kinds] = kinds;
;
}).prototype = meta_meta.Target.prototype;
dart.addTypeTests(meta_meta.Target);
dart.addTypeCaches(meta_meta.Target);
dart.setLibraryUri(meta_meta.Target, I[270]);
dart.setFieldSignature(meta_meta.Target, () => ({
__proto__: dart.getFields(meta_meta.Target.__proto__),
kinds: dart.finalFieldType(core.Set$(meta_meta.TargetKind))
}));
meta_meta.TargetKind = class TargetKind extends core._Enum {
toString() {
return "TargetKind." + dart.str(this[S$._name$1]);
}
};
(meta_meta.TargetKind.new = function(index, name) {
if (index == null) dart.nullFailed(I[269], 32, 6, "index");
if (name == null) dart.nullFailed(I[269], 32, 6, "name");
meta_meta.TargetKind.__proto__.new.call(this, index, name);
;
}).prototype = meta_meta.TargetKind.prototype;
dart.addTypeTests(meta_meta.TargetKind);
dart.addTypeCaches(meta_meta.TargetKind);
dart.setLibraryUri(meta_meta.TargetKind, I[270]);
dart.setStaticFieldSignature(meta_meta.TargetKind, () => ['values', 'classType', 'enumType', 'extension', 'field', 'function', 'library', 'getter', 'method', 'mixinType', 'parameter', 'setter', 'topLevelVariable', 'type', 'typedefType']);
dart.defineExtensionMethods(meta_meta.TargetKind, ['toString']);
meta_meta.TargetKind.classType = C[235] || CT.C235;
meta_meta.TargetKind.enumType = C[236] || CT.C236;
meta_meta.TargetKind.extension = C[237] || CT.C237;
meta_meta.TargetKind.field = C[238] || CT.C238;
meta_meta.TargetKind.function = C[239] || CT.C239;
meta_meta.TargetKind.library = C[240] || CT.C240;
meta_meta.TargetKind.getter = C[241] || CT.C241;
meta_meta.TargetKind.method = C[242] || CT.C242;
meta_meta.TargetKind.mixinType = C[243] || CT.C243;
meta_meta.TargetKind.parameter = C[244] || CT.C244;
meta_meta.TargetKind.setter = C[245] || CT.C245;
meta_meta.TargetKind.topLevelVariable = C[246] || CT.C246;
meta_meta.TargetKind.type = C[247] || CT.C247;
meta_meta.TargetKind.typedefType = C[248] || CT.C248;
meta_meta.TargetKind.values = C[249] || CT.C249;
meta_meta['TargetKindExtension|get#displayString'] = function TargetKindExtension$124get$35displayString($this) {
if ($this == null) dart.nullFailed(I[269], 91, 14, "#this");
switch ($this) {
case C[235] || CT.C235:
{
return "classes";
}
case C[236] || CT.C236:
{
return "enums";
}
case C[237] || CT.C237:
{
return "extensions";
}
case C[238] || CT.C238:
{
return "fields";
}
case C[239] || CT.C239:
{
return "top-level functions";
}
case C[240] || CT.C240:
{
return "libraries";
}
case C[241] || CT.C241:
{
return "getters";
}
case C[242] || CT.C242:
{
return "methods";
}
case C[243] || CT.C243:
{
return "mixins";
}
case C[244] || CT.C244:
{
return "parameters";
}
case C[245] || CT.C245:
{
return "setters";
}
case C[246] || CT.C246:
{
return "top-level variables";
}
case C[247] || CT.C247:
{
return "types (classes, enums, mixins, or typedefs)";
}
case C[248] || CT.C248:
{
return "typedefs";
}
default:
{
dart.throw(new _internal.ReachabilityError.new("`null` encountered as case in a switch expression with a non-nullable enum type."));
}
}
};
const _is__TypedQueue_default = Symbol('_is__TypedQueue_default');
typed_queue._TypedQueue$ = dart.generic((E, L) => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$ListOfE = () => (__t$ListOfE = dart.constFn(core.List$(E)))();
var __t$EN = () => (__t$EN = dart.constFn(dart.nullable(E)))();
const Object_ListMixin$36 = class Object_ListMixin extends core.Object {};
(Object_ListMixin$36.new = function() {
}).prototype = Object_ListMixin$36.prototype;
dart.applyMixin(Object_ListMixin$36, collection.ListMixin$(E));
class _TypedQueue extends Object_ListMixin$36 {
get [S$0._table$2]() {
return this[S$0._table$1];
}
set [S$0._table$2](value) {
this[S$0._table$1] = value;
}
get [S$0._head$3]() {
return this[S$0._head$2];
}
set [S$0._head$3](value) {
this[S$0._head$2] = value;
}
get [S$0._tail$3]() {
return this[S$0._tail$2];
}
set [S$0._tail$3](value) {
this[S$0._tail$2] = value;
}
get length() {
return (dart.notNull(this[S$0._tail$3]) - dart.notNull(this[S$0._head$3]) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
}
toList(opts) {
let growable = opts && 'growable' in opts ? opts.growable : true;
if (growable == null) dart.nullFailed(I[271], 33, 24, "growable");
let list = dart.test(growable) ? this[S$0._createBuffer](this.length) : this[S$0._createList](this.length);
this[S$0._writeToList$1](list);
return list;
}
cast(T) {
if (queue_list.QueueList$(T).is(this)) return queue_list.QueueList$(T).as(this);
dart.throw(new core.UnsupportedError.new(dart.str(this) + " cannot be cast to the desired type."));
}
retype(T) {
return this.cast(T);
}
addLast(value) {
E.as(value);
this[S$0._table$2][S$.$_set](this[S$0._tail$3], value);
this[S$0._tail$3] = (dart.notNull(this[S$0._tail$3]) + 1 & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
if (this[S$0._head$3] == this[S$0._tail$3]) this[S$0._growAtCapacity]();
}
addFirst(value) {
E.as(value);
this[S$0._head$3] = (dart.notNull(this[S$0._head$3]) - 1 & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
this[S$0._table$2][S$.$_set](this[S$0._head$3], value);
if (this[S$0._head$3] == this[S$0._tail$3]) this[S$0._growAtCapacity]();
}
removeFirst() {
if (this[S$0._head$3] == this[S$0._tail$3]) dart.throw(new core.StateError.new("No element"));
let result = this[S$0._table$2][S$.$_get](this[S$0._head$3]);
this[S$0._head$3] = (dart.notNull(this[S$0._head$3]) + 1 & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
return result;
}
removeLast() {
if (this[S$0._head$3] == this[S$0._tail$3]) dart.throw(new core.StateError.new("No element"));
this[S$0._tail$3] = (dart.notNull(this[S$0._tail$3]) - 1 & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
return this[S$0._table$2][S$.$_get](this[S$0._tail$3]);
}
add(value) {
E.as(value);
return this.addLast(value);
}
set length(value) {
if (value == null) dart.nullFailed(I[271], 78, 18, "value");
core.RangeError.checkNotNegative(value, "length");
let delta = dart.notNull(value) - dart.notNull(this.length);
if (delta >= 0) {
let needsToGrow = dart.notNull(this[S$0._table$2][S$.$length]) <= dart.notNull(value);
if (needsToGrow) this[S$0._growTo](value);
this[S$0._tail$3] = (dart.notNull(this[S$0._tail$3]) + delta & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
if (!needsToGrow) this.fillRange(dart.notNull(value) - delta, value, this[S$0._defaultValue]);
} else {
this.removeRange(value, this.length);
}
}
_get(index) {
if (index == null) dart.nullFailed(I[271], 96, 21, "index");
core.RangeError.checkValidIndex(index, this, null, this.length);
return this[S$0._table$2][S$.$_get]((dart.notNull(this[S$0._head$3]) + dart.notNull(index) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0);
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[271], 101, 25, "index");
E.as(value);
core.RangeError.checkValidIndex(index, this);
this[S$0._table$2][S$.$_set]((dart.notNull(this[S$0._head$3]) + dart.notNull(index) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0, value);
return value$;
}
removeRange(start, end) {
if (start == null) dart.nullFailed(I[271], 106, 24, "start");
if (end == null) dart.nullFailed(I[271], 106, 35, "end");
let length = this.length;
core.RangeError.checkValidRange(start, end, length);
if (start === 0) {
this[S$0._head$3] = (dart.notNull(this[S$0._head$3]) + dart.notNull(end) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
return;
}
let elementsAfter = dart.notNull(length) - dart.notNull(end);
if (elementsAfter === 0) {
this[S$0._tail$3] = (dart.notNull(this[S$0._head$3]) + dart.notNull(start) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
return;
}
let removedElements = dart.notNull(end) - dart.notNull(start);
if (dart.notNull(start) < elementsAfter) {
this.setRange(removedElements, end, this);
this[S$0._head$3] = (dart.notNull(this[S$0._head$3]) + removedElements & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
} else {
this.setRange(start, dart.notNull(length) - removedElements, this, end);
this[S$0._tail$3] = (dart.notNull(this[S$0._tail$3]) - removedElements & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
}
}
setRange(start, end, iterable, skipCount = 0) {
if (start == null) dart.nullFailed(I[271], 135, 21, "start");
if (end == null) dart.nullFailed(I[271], 135, 32, "end");
__t$IterableOfE().as(iterable);
if (iterable == null) dart.nullFailed(I[271], 135, 49, "iterable");
if (skipCount == null) dart.nullFailed(I[271], 135, 64, "skipCount");
core.RangeError.checkValidRange(start, end, this.length);
if (start == end) return;
let targetStart = (dart.notNull(this[S$0._head$3]) + dart.notNull(start) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
let targetEnd = (dart.notNull(this[S$0._head$3]) + dart.notNull(end) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
let targetIsContiguous = targetStart < targetEnd;
if (iterable === this) {
let sourceStart = (dart.notNull(this[S$0._head$3]) + dart.notNull(skipCount) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
let sourceEnd = (sourceStart + (dart.notNull(end) - dart.notNull(start)) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
if (sourceStart === targetStart) return;
let sourceIsContiguous = sourceStart < sourceEnd;
if (targetIsContiguous && sourceIsContiguous) {
this[S$0._table$2][S$.$setRange](targetStart, targetEnd, this[S$0._table$2], sourceStart);
} else if (!targetIsContiguous && !sourceIsContiguous) {
if (sourceStart > targetStart) {
let startGap = sourceStart - targetStart;
let firstEnd = dart.notNull(this[S$0._table$2][S$.$length]) - startGap;
this[S$0._table$2][S$.$setRange](targetStart, firstEnd, this[S$0._table$2], sourceStart);
this[S$0._table$2][S$.$setRange](firstEnd, this[S$0._table$2][S$.$length], this[S$0._table$2]);
this[S$0._table$2][S$.$setRange](0, targetEnd, this[S$0._table$2], startGap);
} else if (sourceEnd < targetEnd) {
let firstStart = targetEnd - sourceEnd;
this[S$0._table$2][S$.$setRange](firstStart, targetEnd, this[S$0._table$2]);
this[S$0._table$2][S$.$setRange](0, firstStart, this[S$0._table$2], dart.notNull(this[S$0._table$2][S$.$length]) - firstStart);
this[S$0._table$2][S$.$setRange](targetStart, this[S$0._table$2][S$.$length], this[S$0._table$2], sourceStart);
}
} else if (sourceStart < targetEnd) {
if (sourceIsContiguous) {
this[S$0._table$2][S$.$setRange](targetStart, this[S$0._table$2][S$.$length], this[S$0._table$2], sourceStart);
this[S$0._table$2][S$.$setRange](0, targetEnd, this[S$0._table$2], sourceStart + (dart.notNull(this[S$0._table$2][S$.$length]) - targetStart));
} else {
let firstEnd = dart.notNull(this[S$0._table$2][S$.$length]) - sourceStart;
this[S$0._table$2][S$.$setRange](targetStart, firstEnd, this[S$0._table$2], sourceStart);
this[S$0._table$2][S$.$setRange](firstEnd, targetEnd, this[S$0._table$2]);
}
} else {
if (sourceIsContiguous) {
this[S$0._table$2][S$.$setRange](0, targetEnd, this[S$0._table$2], sourceStart + (dart.notNull(this[S$0._table$2][S$.$length]) - targetStart));
this[S$0._table$2][S$.$setRange](targetStart, this[S$0._table$2][S$.$length], this[S$0._table$2], sourceStart);
} else {
let firstStart = targetEnd - sourceEnd;
this[S$0._table$2][S$.$setRange](firstStart, targetEnd, this[S$0._table$2]);
this[S$0._table$2][S$.$setRange](targetStart, firstStart, this[S$0._table$2], sourceStart);
}
}
} else if (targetIsContiguous) {
this[S$0._table$2][S$.$setRange](targetStart, targetEnd, iterable, skipCount);
} else if (__t$ListOfE().is(iterable)) {
this[S$0._table$2][S$.$setRange](targetStart, this[S$0._table$2][S$.$length], iterable, skipCount);
this[S$0._table$2][S$.$setRange](0, targetEnd, iterable, dart.notNull(skipCount) + (dart.notNull(this[S$0._table$2][S$.$length]) - targetStart));
} else {
super.setRange(start, end, iterable, skipCount);
}
}
fillRange(start, end, value = null) {
if (start == null) dart.nullFailed(I[271], 234, 22, "start");
if (end == null) dart.nullFailed(I[271], 234, 33, "end");
__t$EN().as(value);
let startInTable = (dart.notNull(this[S$0._head$3]) + dart.notNull(start) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
let endInTable = (dart.notNull(this[S$0._head$3]) + dart.notNull(end) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
if (startInTable <= endInTable) {
this[S$0._table$2][S$0.$fillRange](startInTable, endInTable, value);
} else {
this[S$0._table$2][S$0.$fillRange](startInTable, this[S$0._table$2][S$.$length], value);
this[S$0._table$2][S$0.$fillRange](0, endInTable, value);
}
}
sublist(start, end = null) {
if (start == null) dart.nullFailed(I[271], 245, 17, "start");
let length = this.length;
let nonNullEnd = core.RangeError.checkValidRange(start, end, length);
let list = this[S$0._createList](dart.notNull(nonNullEnd) - dart.notNull(start));
this[S$0._writeToList$1](list, start, nonNullEnd);
return list;
}
[S$0._writeToList$1](target, start = null, end = null) {
if (target == null) dart.nullFailed(I[271], 263, 28, "target");
start == null ? start = 0 : null;
end == null ? end = this.length : null;
if (!(dart.notNull(target[S$.$length]) >= dart.notNull(end) - dart.notNull(start))) dart.assertFailed(null, I[271], 266, 12, "target.length >= end - start");
if (!(dart.notNull(start) <= dart.notNull(end))) dart.assertFailed(null, I[271], 267, 12, "start <= end");
let elementsToWrite = dart.notNull(end) - dart.notNull(start);
let startInTable = (dart.notNull(this[S$0._head$3]) + dart.notNull(start) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
let endInTable = (dart.notNull(this[S$0._head$3]) + dart.notNull(end) & dart.notNull(this[S$0._table$2][S$.$length]) - 1) >>> 0;
if (startInTable <= endInTable) {
target[S$.$setRange](0, elementsToWrite, this[S$0._table$2], startInTable);
} else {
let firstPartSize = dart.notNull(this[S$0._table$2][S$.$length]) - startInTable;
target[S$.$setRange](0, firstPartSize, this[S$0._table$2], startInTable);
target[S$.$setRange](firstPartSize, firstPartSize + endInTable, this[S$0._table$2], 0);
}
return elementsToWrite;
}
[S$0._growAtCapacity]() {
if (!(this[S$0._head$3] == this[S$0._tail$3])) dart.assertFailed(null, I[271], 285, 12, "_head == _tail");
let newTable = this[S$0._createList](dart.notNull(this[S$0._table$2][S$.$length]) * 2);
let partitionPoint = dart.notNull(this[S$0._table$2][S$.$length]) - dart.notNull(this[S$0._head$3]);
newTable[S$.$setRange](0, partitionPoint, this[S$0._table$2], this[S$0._head$3]);
if (partitionPoint !== this[S$0._table$2][S$.$length]) {
newTable[S$.$setRange](partitionPoint, this[S$0._table$2][S$.$length], this[S$0._table$2]);
}
this[S$0._head$3] = 0;
this[S$0._tail$3] = this[S$0._table$2][S$.$length];
this[S$0._table$2] = newTable;
}
[S$0._growTo](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[271], 303, 20, "newElementCount");
if (!(dart.notNull(newElementCount) >= dart.notNull(this.length))) dart.assertFailed(null, I[271], 304, 12, "newElementCount >= length");
newElementCount = dart.notNull(newElementCount) + newElementCount[S$.$rightShift](1);
let newTable = this[S$0._createList](typed_queue._nextPowerOf2(newElementCount));
this[S$0._tail$3] = this[S$0._writeToList$1](newTable);
this[S$0._table$2] = newTable;
this[S$0._head$3] = 0;
}
}
(_TypedQueue.new = function(table) {
if (table == null) dart.nullFailed(I[271], 24, 23, "table");
this[S$0._table$1] = L.as(table);
this[S$0._head$2] = 0;
this[S$0._tail$2] = 0;
;
}).prototype = _TypedQueue.prototype;
dart.addTypeTests(_TypedQueue);
_TypedQueue.prototype[_is__TypedQueue_default] = true;
dart.addTypeCaches(_TypedQueue);
dart.setMethodSignature(_TypedQueue, () => ({
__proto__: dart.getMethods(_TypedQueue.__proto__),
cast: dart.gFnType(T => [queue_list.QueueList$(T), []], T => [dart.nullable(core.Object)]),
[S$.$cast]: dart.gFnType(T => [queue_list.QueueList$(T), []], T => [dart.nullable(core.Object)]),
retype: dart.gFnType(T => [queue_list.QueueList$(T), []], T => [dart.nullable(core.Object)]),
addLast: dart.fnType(dart.void, [dart.nullable(core.Object)]),
addFirst: dart.fnType(dart.void, [dart.nullable(core.Object)]),
removeFirst: dart.fnType(E, []),
_get: dart.fnType(E, [core.int]),
[S$.$_get]: dart.fnType(E, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
sublist: dart.fnType(L, [core.int], [dart.nullable(core.int)]),
[S$0.$sublist]: dart.fnType(L, [core.int], [dart.nullable(core.int)]),
[S$0._writeToList$1]: dart.fnType(core.int, [core.List$(E)], [dart.nullable(core.int), dart.nullable(core.int)]),
[S$0._growAtCapacity]: dart.fnType(dart.void, []),
[S$0._growTo]: dart.fnType(dart.void, [core.int])
}));
dart.setGetterSignature(_TypedQueue, () => ({
__proto__: dart.getGetters(_TypedQueue.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setSetterSignature(_TypedQueue, () => ({
__proto__: dart.getSetters(_TypedQueue.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(_TypedQueue, I[272]);
dart.setFieldSignature(_TypedQueue, () => ({
__proto__: dart.getFields(_TypedQueue.__proto__),
[S$0._table$2]: dart.fieldType(L),
[S$0._head$3]: dart.fieldType(core.int),
[S$0._tail$3]: dart.fieldType(core.int)
}));
dart.defineExtensionMethods(_TypedQueue, [
'toList',
'cast',
'removeLast',
'add',
'_get',
'_set',
'removeRange',
'setRange',
'fillRange',
'sublist'
]);
dart.defineExtensionAccessors(_TypedQueue, ['length']);
return _TypedQueue;
});
typed_queue._TypedQueue = typed_queue._TypedQueue$();
dart.addTypeTests(typed_queue._TypedQueue, _is__TypedQueue_default);
const _is__IntQueue_default = Symbol('_is__IntQueue_default');
typed_queue._IntQueue$ = dart.generic(L => {
class _IntQueue extends typed_queue._TypedQueue$(core.int, L) {
get [S$0._defaultValue]() {
return 0;
}
}
(_IntQueue.new = function(queue) {
if (queue == null) dart.nullFailed(I[271], 328, 15, "queue");
_IntQueue.__proto__.new.call(this, queue);
;
}).prototype = _IntQueue.prototype;
dart.addTypeTests(_IntQueue);
_IntQueue.prototype[_is__IntQueue_default] = true;
dart.addTypeCaches(_IntQueue);
dart.setGetterSignature(_IntQueue, () => ({
__proto__: dart.getGetters(_IntQueue.__proto__),
[S$0._defaultValue]: core.int
}));
dart.setLibraryUri(_IntQueue, I[272]);
return _IntQueue;
});
typed_queue._IntQueue = typed_queue._IntQueue$();
dart.addTypeTests(typed_queue._IntQueue, _is__IntQueue_default);
const _is__FloatQueue_default = Symbol('_is__FloatQueue_default');
typed_queue._FloatQueue$ = dart.generic(L => {
class _FloatQueue extends typed_queue._TypedQueue$(core.double, L) {
get [S$0._defaultValue]() {
return 0.0;
}
}
(_FloatQueue.new = function(queue) {
if (queue == null) dart.nullFailed(I[271], 335, 17, "queue");
_FloatQueue.__proto__.new.call(this, queue);
;
}).prototype = _FloatQueue.prototype;
dart.addTypeTests(_FloatQueue);
_FloatQueue.prototype[_is__FloatQueue_default] = true;
dart.addTypeCaches(_FloatQueue);
dart.setGetterSignature(_FloatQueue, () => ({
__proto__: dart.getGetters(_FloatQueue.__proto__),
[S$0._defaultValue]: core.double
}));
dart.setLibraryUri(_FloatQueue, I[272]);
return _FloatQueue;
});
typed_queue._FloatQueue = typed_queue._FloatQueue$();
dart.addTypeTests(typed_queue._FloatQueue, _is__FloatQueue_default);
typed_queue.Uint8Queue = class Uint8Queue extends typed_queue._IntQueue$(typed_data.Uint8List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Uint8Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 354, 41, "elements");
t230 = new typed_queue.Uint8Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 354, 41, "elements");
return typed_queue.Uint8Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 357, 29, "size");
return _native_typed_data.NativeUint8List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 358, 33, "size");
return new typed_buffer.Uint8Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Uint8Queue.new = function(initialCapacity = null) {
typed_queue.Uint8Queue.__proto__.new.call(this, _native_typed_data.NativeUint8List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Uint8Queue.prototype;
dart.addTypeTests(typed_queue.Uint8Queue);
dart.addTypeCaches(typed_queue.Uint8Queue);
typed_queue.Uint8Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Uint8Queue, () => ({
__proto__: dart.getMethods(typed_queue.Uint8Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Uint8List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Uint8Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Uint8Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Uint8Queue, () => ({
__proto__: dart.getGetters(typed_queue.Uint8Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Uint8Queue, () => ({
__proto__: dart.getSetters(typed_queue.Uint8Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Uint8Queue, I[272]);
typed_queue.Int8Queue = class Int8Queue extends typed_queue._IntQueue$(typed_data.Int8List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Int8Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 376, 40, "elements");
t230 = new typed_queue.Int8Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 376, 40, "elements");
return typed_queue.Int8Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 379, 28, "size");
return _native_typed_data.NativeInt8List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 380, 32, "size");
return new typed_buffer.Int8Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Int8Queue.new = function(initialCapacity = null) {
typed_queue.Int8Queue.__proto__.new.call(this, _native_typed_data.NativeInt8List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Int8Queue.prototype;
dart.addTypeTests(typed_queue.Int8Queue);
dart.addTypeCaches(typed_queue.Int8Queue);
typed_queue.Int8Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Int8Queue, () => ({
__proto__: dart.getMethods(typed_queue.Int8Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Int8List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Int8Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Int8Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Int8Queue, () => ({
__proto__: dart.getGetters(typed_queue.Int8Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Int8Queue, () => ({
__proto__: dart.getSetters(typed_queue.Int8Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Int8Queue, I[272]);
typed_queue.Uint8ClampedQueue = class Uint8ClampedQueue extends typed_queue._IntQueue$(typed_data.Uint8ClampedList) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Uint8ClampedQueue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 400, 48, "elements");
t230 = new typed_queue.Uint8ClampedQueue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 400, 48, "elements");
return typed_queue.Uint8ClampedQueue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 403, 36, "size");
return _native_typed_data.NativeUint8ClampedList.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 404, 40, "size");
return new typed_buffer.Uint8ClampedBuffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Uint8ClampedQueue.new = function(initialCapacity = null) {
typed_queue.Uint8ClampedQueue.__proto__.new.call(this, _native_typed_data.NativeUint8ClampedList.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Uint8ClampedQueue.prototype;
dart.addTypeTests(typed_queue.Uint8ClampedQueue);
dart.addTypeCaches(typed_queue.Uint8ClampedQueue);
typed_queue.Uint8ClampedQueue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Uint8ClampedQueue, () => ({
__proto__: dart.getMethods(typed_queue.Uint8ClampedQueue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Uint8ClampedList, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Uint8ClampedBuffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Uint8ClampedQueue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Uint8ClampedQueue, () => ({
__proto__: dart.getGetters(typed_queue.Uint8ClampedQueue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Uint8ClampedQueue, () => ({
__proto__: dart.getSetters(typed_queue.Uint8ClampedQueue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Uint8ClampedQueue, I[272]);
typed_queue.Uint16Queue = class Uint16Queue extends typed_queue._IntQueue$(typed_data.Uint16List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Uint16Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 421, 42, "elements");
t230 = new typed_queue.Uint16Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 421, 42, "elements");
return typed_queue.Uint16Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 424, 30, "size");
return _native_typed_data.NativeUint16List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 425, 34, "size");
return new typed_buffer.Uint16Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Uint16Queue.new = function(initialCapacity = null) {
typed_queue.Uint16Queue.__proto__.new.call(this, _native_typed_data.NativeUint16List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Uint16Queue.prototype;
dart.addTypeTests(typed_queue.Uint16Queue);
dart.addTypeCaches(typed_queue.Uint16Queue);
typed_queue.Uint16Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Uint16Queue, () => ({
__proto__: dart.getMethods(typed_queue.Uint16Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Uint16List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Uint16Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Uint16Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Uint16Queue, () => ({
__proto__: dart.getGetters(typed_queue.Uint16Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Uint16Queue, () => ({
__proto__: dart.getSetters(typed_queue.Uint16Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Uint16Queue, I[272]);
typed_queue.Int16Queue = class Int16Queue extends typed_queue._IntQueue$(typed_data.Int16List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Int16Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 443, 41, "elements");
t230 = new typed_queue.Int16Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 443, 41, "elements");
return typed_queue.Int16Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 446, 29, "size");
return _native_typed_data.NativeInt16List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 447, 33, "size");
return new typed_buffer.Int16Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Int16Queue.new = function(initialCapacity = null) {
typed_queue.Int16Queue.__proto__.new.call(this, _native_typed_data.NativeInt16List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Int16Queue.prototype;
dart.addTypeTests(typed_queue.Int16Queue);
dart.addTypeCaches(typed_queue.Int16Queue);
typed_queue.Int16Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Int16Queue, () => ({
__proto__: dart.getMethods(typed_queue.Int16Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Int16List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Int16Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Int16Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Int16Queue, () => ({
__proto__: dart.getGetters(typed_queue.Int16Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Int16Queue, () => ({
__proto__: dart.getSetters(typed_queue.Int16Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Int16Queue, I[272]);
typed_queue.Uint32Queue = class Uint32Queue extends typed_queue._IntQueue$(typed_data.Uint32List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Uint32Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 464, 42, "elements");
t230 = new typed_queue.Uint32Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 464, 42, "elements");
return typed_queue.Uint32Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 467, 30, "size");
return _native_typed_data.NativeUint32List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 468, 34, "size");
return new typed_buffer.Uint32Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Uint32Queue.new = function(initialCapacity = null) {
typed_queue.Uint32Queue.__proto__.new.call(this, _native_typed_data.NativeUint32List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Uint32Queue.prototype;
dart.addTypeTests(typed_queue.Uint32Queue);
dart.addTypeCaches(typed_queue.Uint32Queue);
typed_queue.Uint32Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Uint32Queue, () => ({
__proto__: dart.getMethods(typed_queue.Uint32Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Uint32List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Uint32Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Uint32Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Uint32Queue, () => ({
__proto__: dart.getGetters(typed_queue.Uint32Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Uint32Queue, () => ({
__proto__: dart.getSetters(typed_queue.Uint32Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Uint32Queue, I[272]);
typed_queue.Int32Queue = class Int32Queue extends typed_queue._IntQueue$(typed_data.Int32List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Int32Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 486, 41, "elements");
t230 = new typed_queue.Int32Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 486, 41, "elements");
return typed_queue.Int32Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 489, 29, "size");
return _native_typed_data.NativeInt32List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 490, 33, "size");
return new typed_buffer.Int32Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Int32Queue.new = function(initialCapacity = null) {
typed_queue.Int32Queue.__proto__.new.call(this, _native_typed_data.NativeInt32List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Int32Queue.prototype;
dart.addTypeTests(typed_queue.Int32Queue);
dart.addTypeCaches(typed_queue.Int32Queue);
typed_queue.Int32Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Int32Queue, () => ({
__proto__: dart.getMethods(typed_queue.Int32Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Int32List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Int32Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Int32Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Int32Queue, () => ({
__proto__: dart.getGetters(typed_queue.Int32Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Int32Queue, () => ({
__proto__: dart.getSetters(typed_queue.Int32Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Int32Queue, I[272]);
typed_queue.Uint64Queue = class Uint64Queue extends typed_queue._IntQueue$(typed_data.Uint64List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Uint64Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 508, 42, "elements");
t230 = new typed_queue.Uint64Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 508, 42, "elements");
return typed_queue.Uint64Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 511, 30, "size");
return typed_data.Uint64List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 512, 34, "size");
return new typed_buffer.Uint64Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Uint64Queue.new = function(initialCapacity = null) {
typed_queue.Uint64Queue.__proto__.new.call(this, typed_data.Uint64List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Uint64Queue.prototype;
dart.addTypeTests(typed_queue.Uint64Queue);
dart.addTypeCaches(typed_queue.Uint64Queue);
typed_queue.Uint64Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Uint64Queue, () => ({
__proto__: dart.getMethods(typed_queue.Uint64Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Uint64List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Uint64Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Uint64Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Uint64Queue, () => ({
__proto__: dart.getGetters(typed_queue.Uint64Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Uint64Queue, () => ({
__proto__: dart.getSetters(typed_queue.Uint64Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Uint64Queue, I[272]);
typed_queue.Int64Queue = class Int64Queue extends typed_queue._IntQueue$(typed_data.Int64List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Int64Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 530, 41, "elements");
t230 = new typed_queue.Int64Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 530, 41, "elements");
return typed_queue.Int64Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 533, 29, "size");
return typed_data.Int64List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 534, 33, "size");
return new typed_buffer.Int64Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfintN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.int.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfintN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfintN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Int64Queue.new = function(initialCapacity = null) {
typed_queue.Int64Queue.__proto__.new.call(this, typed_data.Int64List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Int64Queue.prototype;
dart.addTypeTests(typed_queue.Int64Queue);
dart.addTypeCaches(typed_queue.Int64Queue);
typed_queue.Int64Queue[dart.implements] = () => [queue_list.QueueList$(core.int)];
dart.setMethodSignature(typed_queue.Int64Queue, () => ({
__proto__: dart.getMethods(typed_queue.Int64Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Int64List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Int64Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Int64Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Int64Queue, () => ({
__proto__: dart.getGetters(typed_queue.Int64Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.int)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Int64Queue, () => ({
__proto__: dart.getSetters(typed_queue.Int64Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Int64Queue, I[272]);
typed_queue.Float32Queue = class Float32Queue extends typed_queue._FloatQueue$(typed_data.Float32List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Float32Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 553, 46, "elements");
t230 = new typed_queue.Float32Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 553, 46, "elements");
return typed_queue.Float32Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 556, 31, "size");
return _native_typed_data.NativeFloat32List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 557, 35, "size");
return new typed_buffer.Float32Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfdoubleN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.double.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfdoubleN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfdoubleN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Float32Queue.new = function(initialCapacity = null) {
typed_queue.Float32Queue.__proto__.new.call(this, _native_typed_data.NativeFloat32List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Float32Queue.prototype;
dart.addTypeTests(typed_queue.Float32Queue);
dart.addTypeCaches(typed_queue.Float32Queue);
typed_queue.Float32Queue[dart.implements] = () => [queue_list.QueueList$(core.double)];
dart.setMethodSignature(typed_queue.Float32Queue, () => ({
__proto__: dart.getMethods(typed_queue.Float32Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Float32List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Float32Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Float32Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Float32Queue, () => ({
__proto__: dart.getGetters(typed_queue.Float32Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.double)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Float32Queue, () => ({
__proto__: dart.getSetters(typed_queue.Float32Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Float32Queue, I[272]);
typed_queue.Float64Queue = class Float64Queue extends typed_queue._FloatQueue$(typed_data.Float64List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Float64Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 573, 46, "elements");
t230 = new typed_queue.Float64Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 573, 46, "elements");
return typed_queue.Float64Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 576, 31, "size");
return _native_typed_data.NativeFloat64List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 577, 35, "size");
return new typed_buffer.Float64Buffer.new(size);
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfdoubleN().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
core.double.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfdoubleN().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfdoubleN().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Float64Queue.new = function(initialCapacity = null) {
typed_queue.Float64Queue.__proto__.new.call(this, _native_typed_data.NativeFloat64List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Float64Queue.prototype;
dart.addTypeTests(typed_queue.Float64Queue);
dart.addTypeCaches(typed_queue.Float64Queue);
typed_queue.Float64Queue[dart.implements] = () => [queue_list.QueueList$(core.double)];
dart.setMethodSignature(typed_queue.Float64Queue, () => ({
__proto__: dart.getMethods(typed_queue.Float64Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Float64List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Float64Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Float64Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Float64Queue, () => ({
__proto__: dart.getGetters(typed_queue.Float64Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(core.double)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Float64Queue, () => ({
__proto__: dart.getSetters(typed_queue.Float64Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Float64Queue, I[272]);
typed_queue.Int32x4Queue = class Int32x4Queue extends typed_queue._TypedQueue$(typed_data.Int32x4, typed_data.Int32x4List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Int32x4Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 594, 47, "elements");
t230 = new typed_queue.Int32x4Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 594, 47, "elements");
return typed_queue.Int32x4Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 597, 31, "size");
return new _native_typed_data.NativeInt32x4List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 598, 35, "size");
return new typed_buffer.Int32x4Buffer.new(size);
}
get [S$0._defaultValue]() {
return typed_queue.Int32x4Queue._zero;
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfInt32x4N().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
typed_data.Int32x4.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfInt32x4N().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfInt32x4N().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Int32x4Queue.new = function(initialCapacity = null) {
typed_queue.Int32x4Queue.__proto__.new.call(this, new _native_typed_data.NativeInt32x4List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Int32x4Queue.prototype;
dart.addTypeTests(typed_queue.Int32x4Queue);
dart.addTypeCaches(typed_queue.Int32x4Queue);
typed_queue.Int32x4Queue[dart.implements] = () => [queue_list.QueueList$(typed_data.Int32x4)];
dart.setMethodSignature(typed_queue.Int32x4Queue, () => ({
__proto__: dart.getMethods(typed_queue.Int32x4Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Int32x4List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Int32x4Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Int32x4Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Int32x4Queue, () => ({
__proto__: dart.getGetters(typed_queue.Int32x4Queue.__proto__),
[S$0._defaultValue]: typed_data.Int32x4,
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(typed_data.Int32x4)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Int32x4Queue, () => ({
__proto__: dart.getSetters(typed_queue.Int32x4Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Int32x4Queue, I[272]);
dart.setStaticFieldSignature(typed_queue.Int32x4Queue, () => ['_zero']);
dart.defineLazy(typed_queue.Int32x4Queue, {
/*typed_queue.Int32x4Queue._zero*/get _zero() {
return new _native_typed_data.NativeInt32x4.new(0, 0, 0, 0);
}
}, false);
typed_queue.Float32x4Queue = class Float32x4Queue extends typed_queue._TypedQueue$(typed_data.Float32x4, typed_data.Float32x4List) {
static ['_#new#tearOff'](initialCapacity = null) {
return new typed_queue.Float32x4Queue.new(initialCapacity);
}
static fromList(elements) {
let t230;
if (elements == null) dart.nullFailed(I[271], 614, 51, "elements");
t230 = new typed_queue.Float32x4Queue.new(elements[S$.$length]);
return (() => {
t230.addAll(elements);
return t230;
})();
}
static ['_#fromList#tearOff'](elements) {
if (elements == null) dart.nullFailed(I[271], 614, 51, "elements");
return typed_queue.Float32x4Queue.fromList(elements);
}
[S$0._createList](size) {
if (size == null) dart.nullFailed(I[271], 617, 33, "size");
return new _native_typed_data.NativeFloat32x4List.new(size);
}
[S$0._createBuffer](size) {
if (size == null) dart.nullFailed(I[271], 618, 37, "size");
return new typed_buffer.Float32x4Buffer.new(size);
}
get [S$0._defaultValue]() {
return new _native_typed_data.NativeFloat32x4.zero();
}
get [S$0._head$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[250] || CT.C250)));
}
[S$0._writeToList](target) {
T$0.ListOfFloat32x4N().as(target);
if (target == null) dart.nullFailed(I[116], 248, 29, "target");
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.method(C[251] || CT.C251, null, [target])));
}
[S$0._add$1](element) {
typed_data.Float32x4.as(element);
if (element == null) dart.nullFailed(I[116], 231, 15, "element");
return this[S$.$noSuchMethod](new core._Invocation.method(C[252] || CT.C252, null, [element]));
}
[S$0._grow$1]() {
return this[S$.$noSuchMethod](new core._Invocation.method(C[253] || CT.C253, null, []));
}
get [S$0._table]() {
return T$0.ListOfFloat32x4N().as(this[S$.$noSuchMethod](new core._Invocation.getter(C[254] || CT.C254)));
}
get [S$0._tail$1]() {
return core.int.as(this[S$.$noSuchMethod](new core._Invocation.getter(C[255] || CT.C255)));
}
[S$0._preGrow](newElementCount) {
if (newElementCount == null) dart.nullFailed(I[116], 263, 21, "newElementCount");
return this[S$.$noSuchMethod](new core._Invocation.method(C[256] || CT.C256, null, [newElementCount]));
}
set [S$0._head$1](value) {
if (value == null) dart.nullFailed(I[116], 31, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[257] || CT.C257, value));
}
set [S$0._table](value) {
T$0.ListOfFloat32x4N().as(value);
if (value == null) dart.nullFailed(I[116], 30, 12, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[258] || CT.C258, value));
}
set [S$0._tail$1](value) {
if (value == null) dart.nullFailed(I[116], 32, 7, "value");
return this[S$.$noSuchMethod](new core._Invocation.setter(C[259] || CT.C259, value));
}
};
(typed_queue.Float32x4Queue.new = function(initialCapacity = null) {
typed_queue.Float32x4Queue.__proto__.new.call(this, new _native_typed_data.NativeFloat32x4List.new(typed_queue._chooseRealInitialCapacity(initialCapacity)));
;
}).prototype = typed_queue.Float32x4Queue.prototype;
dart.addTypeTests(typed_queue.Float32x4Queue);
dart.addTypeCaches(typed_queue.Float32x4Queue);
typed_queue.Float32x4Queue[dart.implements] = () => [queue_list.QueueList$(typed_data.Float32x4)];
dart.setMethodSignature(typed_queue.Float32x4Queue, () => ({
__proto__: dart.getMethods(typed_queue.Float32x4Queue.__proto__),
[S$0._createList]: dart.fnType(typed_data.Float32x4List, [core.int]),
[S$0._createBuffer]: dart.fnType(typed_buffer.Float32x4Buffer, [core.int]),
[S$0._writeToList]: dart.fnType(core.int, [dart.nullable(core.Object)]),
[S$0._add$1]: dart.fnType(dart.void, [dart.nullable(core.Object)]),
[S$0._grow$1]: dart.fnType(dart.void, []),
[S$0._preGrow]: dart.fnType(dart.void, [core.int])
}));
dart.setStaticMethodSignature(typed_queue.Float32x4Queue, () => ['fromList']);
dart.setGetterSignature(typed_queue.Float32x4Queue, () => ({
__proto__: dart.getGetters(typed_queue.Float32x4Queue.__proto__),
[S$0._defaultValue]: typed_data.Float32x4,
[S$0._head$1]: core.int,
[S$0._table]: core.List$(dart.nullable(typed_data.Float32x4)),
[S$0._tail$1]: core.int
}));
dart.setSetterSignature(typed_queue.Float32x4Queue, () => ({
__proto__: dart.getSetters(typed_queue.Float32x4Queue.__proto__),
[S$0._head$1]: core.int,
[S$0._table]: dart.nullable(core.Object),
[S$0._tail$1]: core.int
}));
dart.setLibraryUri(typed_queue.Float32x4Queue, I[272]);
typed_queue._chooseRealInitialCapacity = function _chooseRealInitialCapacity(initialCapacity) {
if (initialCapacity == null || dart.notNull(initialCapacity) < 16) {
return 16;
} else if (!dart.test(typed_queue._isPowerOf2(initialCapacity))) {
return typed_queue._nextPowerOf2(initialCapacity);
} else {
return initialCapacity;
}
};
typed_queue._isPowerOf2 = function _isPowerOf2(number) {
if (number == null) dart.nullFailed(I[271], 640, 22, "number");
return (dart.notNull(number) & dart.notNull(number) - 1) === 0;
};
typed_queue._nextPowerOf2 = function _nextPowerOf2(number) {
if (number == null) dart.nullFailed(I[271], 647, 23, "number");
if (!(dart.notNull(number) > 0)) dart.assertFailed(null, I[271], 648, 10, "number > 0");
number = (dart.notNull(number) << 1 >>> 0) - 1;
for (;;) {
let nextNumber = (dart.notNull(number) & dart.notNull(number) - 1) >>> 0;
if (nextNumber === 0) return number;
number = nextNumber;
}
};
dart.defineLazy(typed_queue, {
/*typed_queue._defaultInitialCapacity*/get _defaultInitialCapacity() {
return 16;
}
}, false);
const _is_TypedDataBuffer_default = Symbol('_is_TypedDataBuffer_default');
typed_buffer.TypedDataBuffer$ = dart.generic(E => {
var __t$IterableOfE = () => (__t$IterableOfE = dart.constFn(core.Iterable$(E)))();
var __t$TypedDataBufferOfE = () => (__t$TypedDataBufferOfE = dart.constFn(typed_buffer.TypedDataBuffer$(E)))();
class TypedDataBuffer extends collection.ListBase$(E) {
get [S$0._typedBuffer]() {
return typed_data.TypedData.as(this[S$0._buffer$2]);
}
get length() {
return this[S$0._length$1];
}
_get(index) {
if (index == null) dart.nullFailed(I[273], 31, 21, "index");
if (dart.notNull(index) >= dart.notNull(this.length)) dart.throw(new core.IndexError.new(index, this));
return this[S$0._buffer$2][S$.$_get](index);
}
_set(index, value$) {
let value = value$;
if (index == null) dart.nullFailed(I[273], 37, 25, "index");
E.as(value);
if (dart.notNull(index) >= dart.notNull(this.length)) dart.throw(new core.IndexError.new(index, this));
this[S$0._buffer$2][S$.$_set](index, value);
return value$;
}
set length(newLength) {
if (newLength == null) dart.nullFailed(I[273], 43, 18, "newLength");
if (dart.notNull(newLength) < dart.notNull(this[S$0._length$1])) {
let defaultValue = this[S$0._defaultValue$1];
for (let i = newLength; dart.notNull(i) < dart.notNull(this[S$0._length$1]); i = dart.notNull(i) + 1) {
this[S$0._buffer$2][S$.$_set](i, defaultValue);
}
} else if (dart.notNull(newLength) > dart.notNull(this[S$0._buffer$2][S$.$length])) {
let newBuffer = null;
if (dart.test(this[S$0._buffer$2][S$.$isEmpty])) {
newBuffer = this[S$0._createBuffer$1](newLength);
} else {
newBuffer = this[S$0._createBiggerBuffer](newLength);
}
newBuffer[S$.$setRange](0, this[S$0._length$1], this[S$0._buffer$2]);
this[S$0._buffer$2] = newBuffer;
}
this[S$0._length$1] = newLength;
}
[S$0._add$4](value) {
let t230;
if (this[S$0._length$1] == this[S$0._buffer$2][S$.$length]) this[S$0._grow$3](this[S$0._length$1]);
this[S$0._buffer$2][S$.$_set]((t230 = this[S$0._length$1], this[S$0._length$1] = dart.notNull(t230) + 1, t230), value);
}
add(value) {
E.as(value);
this[S$0._add$4](value);
}
addAll(values, start = 0, end = null) {
__t$IterableOfE().as(values);
if (values == null) dart.nullFailed(I[273], 85, 27, "values");
if (start == null) dart.nullFailed(I[273], 85, 40, "start");
core.RangeError.checkNotNegative(start, "start");
if (end != null && dart.notNull(start) > dart.notNull(end)) {
dart.throw(new core.RangeError.range(end, start, null, "end"));
}
this[S$0._addAll](values, start, end);
}
insertAll(index, values, start = 0, end = null) {
let t230;
if (index == null) dart.nullFailed(I[273], 104, 22, "index");
__t$IterableOfE().as(values);
if (values == null) dart.nullFailed(I[273], 104, 41, "values");
if (start == null) dart.nullFailed(I[273], 104, 54, "start");
core.RangeError.checkValidIndex(index, this, "index", dart.notNull(this[S$0._length$1]) + 1);
core.RangeError.checkNotNegative(start, "start");
if (end != null) {
if (dart.notNull(start) > dart.notNull(end)) {
dart.throw(new core.RangeError.range(end, start, null, "end"));
}
if (start == end) return;
}
if (index == this[S$0._length$1]) {
this[S$0._addAll](values, start, end);
return;
}
if (end == null && core.List.is(values)) {
end = values[S$.$length];
}
if (end != null) {
this[S$0._insertKnownLength](index, values, start, end);
return;
}
let writeIndex = this[S$0._length$1];
let skipCount = start;
for (let value of values) {
if (dart.notNull(skipCount) > 0) {
skipCount = dart.notNull(skipCount) - 1;
continue;
}
if (writeIndex == this[S$0._buffer$2][S$.$length]) {
this[S$0._grow$3](writeIndex);
}
this[S$0._buffer$2][S$.$_set]((t230 = writeIndex, writeIndex = dart.notNull(t230) + 1, t230), value);
}
if (dart.notNull(skipCount) > 0) {
dart.throw(new core.StateError.new("Too few elements"));
}
if (end != null && dart.notNull(writeIndex) < dart.notNull(end)) {
dart.throw(new core.RangeError.range(end, start, writeIndex, "end"));
}
typed_buffer.TypedDataBuffer._reverse(this[S$0._buffer$2], index, this[S$0._length$1]);
typed_buffer.TypedDataBuffer._reverse(this[S$0._buffer$2], this[S$0._length$1], writeIndex);
typed_buffer.TypedDataBuffer._reverse(this[S$0._buffer$2], index, writeIndex);
this[S$0._length$1] = writeIndex;
return;
}
static _reverse(buffer, start, end) {
if (buffer == null) dart.nullFailed(I[273], 162, 29, "buffer");
if (start == null) dart.nullFailed(I[273], 162, 41, "start");
if (end == null) dart.nullFailed(I[273], 162, 52, "end");
end = dart.notNull(end) - 1;
while (dart.notNull(start) < dart.notNull(end)) {
let first = buffer[S$.$_get](start);
let last = buffer[S$.$_get](end);
buffer[S$.$_set](end, first);
buffer[S$.$_set](start, last);
start = dart.notNull(start) + 1;
end = dart.notNull(end) - 1;
}
}
[S$0._addAll](values, start = 0, end = null) {
if (values == null) dart.nullFailed(I[273], 179, 28, "values");
if (start == null) dart.nullFailed(I[273], 179, 41, "start");
if (core.List.is(values)) end == null ? end = values[S$.$length] : null;
if (end != null) {
this[S$0._insertKnownLength](this[S$0._length$1], values, start, end);
return;
}
let i = 0;
for (let value of values) {
if (i >= dart.notNull(start)) this.add(value);
i = i + 1;
}
if (i < dart.notNull(start)) dart.throw(new core.StateError.new("Too few elements"));
}
[S$0._insertKnownLength](index, values, start, end) {
if (index == null) dart.nullFailed(I[273], 200, 31, "index");
if (values == null) dart.nullFailed(I[273], 200, 50, "values");
if (start == null) dart.nullFailed(I[273], 200, 62, "start");
if (end == null) dart.nullFailed(I[273], 200, 73, "end");
if (core.List.is(values)) {
if (dart.notNull(start) > dart.notNull(values[S$.$length]) || dart.notNull(end) > dart.notNull(values[S$.$length])) {
dart.throw(new core.StateError.new("Too few elements"));
}
}
let valuesLength = dart.notNull(end) - dart.notNull(start);
let newLength = dart.notNull(this[S$0._length$1]) + valuesLength;
this[S$0._ensureCapacity](newLength);
this[S$0._buffer$2][S$.$setRange](dart.notNull(index) + valuesLength, dart.notNull(this[S$0._length$1]) + valuesLength, this[S$0._buffer$2], index);
this[S$0._buffer$2][S$.$setRange](index, dart.notNull(index) + valuesLength, values, start);
this[S$0._length$1] = newLength;
}
insert(index, element) {
if (index == null) dart.nullFailed(I[273], 218, 19, "index");
E.as(element);
if (dart.notNull(index) < 0 || dart.notNull(index) > dart.notNull(this[S$0._length$1])) {
dart.throw(new core.RangeError.range(index, 0, this[S$0._length$1]));
}
if (dart.notNull(this[S$0._length$1]) < dart.notNull(this[S$0._buffer$2][S$.$length])) {
this[S$0._buffer$2][S$.$setRange](dart.notNull(index) + 1, dart.notNull(this[S$0._length$1]) + 1, this[S$0._buffer$2], index);
this[S$0._buffer$2][S$.$_set](index, element);
this[S$0._length$1] = dart.notNull(this[S$0._length$1]) + 1;
return;
}
let newBuffer = this[S$0._createBiggerBuffer](null);
newBuffer[S$.$setRange](0, index, this[S$0._buffer$2]);
newBuffer[S$.$setRange](dart.notNull(index) + 1, dart.notNull(this[S$0._length$1]) + 1, this[S$0._buffer$2], index);
newBuffer[S$.$_set](index, element);
this[S$0._length$1] = dart.notNull(this[S$0._length$1]) + 1;
this[S$0._buffer$2] = newBuffer;
}
[S$0._ensureCapacity](requiredCapacity) {
if (requiredCapacity == null) dart.nullFailed(I[273], 239, 28, "requiredCapacity");
if (dart.notNull(requiredCapacity) <= dart.notNull(this[S$0._buffer$2][S$.$length])) return;
let newBuffer = this[S$0._createBiggerBuffer](requiredCapacity);
newBuffer[S$.$setRange](0, this[S$0._length$1], this[S$0._buffer$2]);
this[S$0._buffer$2] = newBuffer;
}
[S$0._createBiggerBuffer](requiredCapacity) {
let newLength = dart.notNull(this[S$0._buffer$2][S$.$length]) * 2;
if (requiredCapacity != null && dart.notNull(newLength) < dart.notNull(requiredCapacity)) {
newLength = requiredCapacity;
} else if (dart.notNull(newLength) < 8) {
newLength = 8;
}
return this[S$0._createBuffer$1](newLength);
}
[S$0._grow$3](length) {
let t230;
if (length == null) dart.nullFailed(I[273], 265, 18, "length");
this[S$0._buffer$2] = (t230 = this[S$0._createBiggerBuffer](null), (() => {
t230[S$.$setRange](0, length, this[S$0._buffer$2]);
return t230;
})());
}
setRange(start, end, source, skipCount = 0) {
if (start == null) dart.nullFailed(I[273], 270, 21, "start");
if (end == null) dart.nullFailed(I[273], 270, 32, "end");
__t$IterableOfE().as(source);
if (source == null) dart.nullFailed(I[273], 270, 49, "source");
if (skipCount == null) dart.nullFailed(I[273], 270, 62, "skipCount");
if (dart.notNull(end) > dart.notNull(this[S$0._length$1])) dart.throw(new core.RangeError.range(end, 0, this[S$0._length$1]));
this[S$0._setRange](start, end, source, skipCount);
}
[S$0._setRange](start, end, source, skipCount) {
if (start == null) dart.nullFailed(I[273], 276, 22, "start");
if (end == null) dart.nullFailed(I[273], 276, 33, "end");
if (source == null) dart.nullFailed(I[273], 276, 50, "source");
if (skipCount == null) dart.nullFailed(I[273], 276, 62, "skipCount");
if (__t$TypedDataBufferOfE().is(source)) {
this[S$0._buffer$2][S$.$setRange](start, end, source[S$0._buffer$2], skipCount);
} else {
this[S$0._buffer$2][S$.$setRange](start, end, source, skipCount);
}
}
get elementSizeInBytes() {
return this[S$0._typedBuffer][S$0.$elementSizeInBytes];
}
get lengthInBytes() {
return dart.notNull(this[S$0._length$1]) * dart.notNull(this[S$0._typedBuffer][S$0.$elementSizeInBytes]);
}
get offsetInBytes() {
return this[S$0._typedBuffer][S$0.$offsetInBytes];
}
get buffer() {
return this[S$0._typedBuffer][S$.$buffer];
}
}
(TypedDataBuffer.new = function(buffer) {
if (buffer == null) dart.nullFailed(I[273], 23, 27, "buffer");
this[S$0._buffer$2] = buffer;
this[S$0._length$1] = buffer[S$.$length];
;
}).prototype = TypedDataBuffer.prototype;
dart.addTypeTests(TypedDataBuffer);
TypedDataBuffer.prototype[_is_TypedDataBuffer_default] = true;
dart.addTypeCaches(TypedDataBuffer);
dart.setMethodSignature(TypedDataBuffer, () => ({
__proto__: dart.getMethods(TypedDataBuffer.__proto__),
_get: dart.fnType(E, [core.int]),
[S$.$_get]: dart.fnType(E, [core.int]),
_set: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$.$_set]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)]),
[S$0._add$4]: dart.fnType(dart.void, [E]),
addAll: dart.fnType(dart.void, [dart.nullable(core.Object)], [core.int, dart.nullable(core.int)]),
[S$.$addAll]: dart.fnType(dart.void, [dart.nullable(core.Object)], [core.int, dart.nullable(core.int)]),
insertAll: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)], [core.int, dart.nullable(core.int)]),
[S$.$insertAll]: dart.fnType(dart.void, [core.int, dart.nullable(core.Object)], [core.int, dart.nullable(core.int)]),
[S$0._addAll]: dart.fnType(dart.void, [core.Iterable$(E)], [core.int, dart.nullable(core.int)]),
[S$0._insertKnownLength]: dart.fnType(dart.void, [core.int, core.Iterable$(E), core.int, core.int]),
[S$0._ensureCapacity]: dart.fnType(dart.void, [core.int]),
[S$0._createBiggerBuffer]: dart.fnType(core.List$(E), [dart.nullable(core.int)]),
[S$0._grow$3]: dart.fnType(dart.void, [core.int]),
[S$0._setRange]: dart.fnType(dart.void, [core.int, core.int, core.Iterable$(E), core.int])
}));
dart.setStaticMethodSignature(TypedDataBuffer, () => ['_reverse']);
dart.setGetterSignature(TypedDataBuffer, () => ({
__proto__: dart.getGetters(TypedDataBuffer.__proto__),
[S$0._typedBuffer]: typed_data.TypedData,
length: core.int,
[S$.$length]: core.int,
elementSizeInBytes: core.int,
lengthInBytes: core.int,
offsetInBytes: core.int,
buffer: typed_data.ByteBuffer
}));
dart.setSetterSignature(TypedDataBuffer, () => ({
__proto__: dart.getSetters(TypedDataBuffer.__proto__),
length: core.int,
[S$.$length]: core.int
}));
dart.setLibraryUri(TypedDataBuffer, I[274]);
dart.setFieldSignature(TypedDataBuffer, () => ({
__proto__: dart.getFields(TypedDataBuffer.__proto__),
[S$0._buffer$2]: dart.fieldType(core.List$(E)),
[S$0._length$1]: dart.fieldType(core.int)
}));
dart.setStaticFieldSignature(TypedDataBuffer, () => ['_initialLength']);
dart.defineExtensionMethods(TypedDataBuffer, [
'_get',
'_set',
'add',
'addAll',
'insertAll',
'insert',
'setRange'
]);
dart.defineExtensionAccessors(TypedDataBuffer, ['length']);
return TypedDataBuffer;
});
typed_buffer.TypedDataBuffer = typed_buffer.TypedDataBuffer$();
dart.defineLazy(typed_buffer.TypedDataBuffer, {
/*typed_buffer.TypedDataBuffer._initialLength*/get _initialLength() {
return 8;
}
}, false);
dart.addTypeTests(typed_buffer.TypedDataBuffer, _is_TypedDataBuffer_default);
typed_buffer._IntBuffer = class _IntBuffer extends typed_buffer.TypedDataBuffer$(core.int) {
get [S$0._defaultValue$1]() {
return 0;
}
};
(typed_buffer._IntBuffer.new = function(buffer) {
if (buffer == null) dart.nullFailed(I[273], 311, 24, "buffer");
typed_buffer._IntBuffer.__proto__.new.call(this, buffer);
;
}).prototype = typed_buffer._IntBuffer.prototype;
dart.addTypeTests(typed_buffer._IntBuffer);
dart.addTypeCaches(typed_buffer._IntBuffer);
dart.setGetterSignature(typed_buffer._IntBuffer, () => ({
__proto__: dart.getGetters(typed_buffer._IntBuffer.__proto__),
[S$0._defaultValue$1]: core.int
}));
dart.setLibraryUri(typed_buffer._IntBuffer, I[274]);
typed_buffer._FloatBuffer = class _FloatBuffer extends typed_buffer.TypedDataBuffer$(core.double) {
get [S$0._defaultValue$1]() {
return 0.0;
}
};
(typed_buffer._FloatBuffer.new = function(buffer) {
if (buffer == null) dart.nullFailed(I[273], 318, 29, "buffer");
typed_buffer._FloatBuffer.__proto__.new.call(this, buffer);
;
}).prototype = typed_buffer._FloatBuffer.prototype;
dart.addTypeTests(typed_buffer._FloatBuffer);
dart.addTypeCaches(typed_buffer._FloatBuffer);
dart.setGetterSignature(typed_buffer._FloatBuffer, () => ({
__proto__: dart.getGetters(typed_buffer._FloatBuffer.__proto__),
[S$0._defaultValue$1]: core.double
}));
dart.setLibraryUri(typed_buffer._FloatBuffer, I[274]);
typed_buffer.Uint8Buffer = class Uint8Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 325, 20, "initialLength");
return new typed_buffer.Uint8Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 328, 31, "size");
return _native_typed_data.NativeUint8List.new(size);
}
};
(typed_buffer.Uint8Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 325, 20, "initialLength");
typed_buffer.Uint8Buffer.__proto__.new.call(this, _native_typed_data.NativeUint8List.new(initialLength));
;
}).prototype = typed_buffer.Uint8Buffer.prototype;
dart.addTypeTests(typed_buffer.Uint8Buffer);
dart.addTypeCaches(typed_buffer.Uint8Buffer);
dart.setMethodSignature(typed_buffer.Uint8Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Uint8Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Uint8List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Uint8Buffer, I[274]);
typed_buffer.Int8Buffer = class Int8Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 332, 19, "initialLength");
return new typed_buffer.Int8Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 335, 30, "size");
return _native_typed_data.NativeInt8List.new(size);
}
};
(typed_buffer.Int8Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 332, 19, "initialLength");
typed_buffer.Int8Buffer.__proto__.new.call(this, _native_typed_data.NativeInt8List.new(initialLength));
;
}).prototype = typed_buffer.Int8Buffer.prototype;
dart.addTypeTests(typed_buffer.Int8Buffer);
dart.addTypeCaches(typed_buffer.Int8Buffer);
dart.setMethodSignature(typed_buffer.Int8Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Int8Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Int8List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Int8Buffer, I[274]);
typed_buffer.Uint8ClampedBuffer = class Uint8ClampedBuffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 339, 27, "initialLength");
return new typed_buffer.Uint8ClampedBuffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 343, 38, "size");
return _native_typed_data.NativeUint8ClampedList.new(size);
}
};
(typed_buffer.Uint8ClampedBuffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 339, 27, "initialLength");
typed_buffer.Uint8ClampedBuffer.__proto__.new.call(this, _native_typed_data.NativeUint8ClampedList.new(initialLength));
;
}).prototype = typed_buffer.Uint8ClampedBuffer.prototype;
dart.addTypeTests(typed_buffer.Uint8ClampedBuffer);
dart.addTypeCaches(typed_buffer.Uint8ClampedBuffer);
dart.setMethodSignature(typed_buffer.Uint8ClampedBuffer, () => ({
__proto__: dart.getMethods(typed_buffer.Uint8ClampedBuffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Uint8ClampedList, [core.int])
}));
dart.setLibraryUri(typed_buffer.Uint8ClampedBuffer, I[274]);
typed_buffer.Uint16Buffer = class Uint16Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 347, 21, "initialLength");
return new typed_buffer.Uint16Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 350, 32, "size");
return _native_typed_data.NativeUint16List.new(size);
}
};
(typed_buffer.Uint16Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 347, 21, "initialLength");
typed_buffer.Uint16Buffer.__proto__.new.call(this, _native_typed_data.NativeUint16List.new(initialLength));
;
}).prototype = typed_buffer.Uint16Buffer.prototype;
dart.addTypeTests(typed_buffer.Uint16Buffer);
dart.addTypeCaches(typed_buffer.Uint16Buffer);
dart.setMethodSignature(typed_buffer.Uint16Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Uint16Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Uint16List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Uint16Buffer, I[274]);
typed_buffer.Int16Buffer = class Int16Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 354, 20, "initialLength");
return new typed_buffer.Int16Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 357, 31, "size");
return _native_typed_data.NativeInt16List.new(size);
}
};
(typed_buffer.Int16Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 354, 20, "initialLength");
typed_buffer.Int16Buffer.__proto__.new.call(this, _native_typed_data.NativeInt16List.new(initialLength));
;
}).prototype = typed_buffer.Int16Buffer.prototype;
dart.addTypeTests(typed_buffer.Int16Buffer);
dart.addTypeCaches(typed_buffer.Int16Buffer);
dart.setMethodSignature(typed_buffer.Int16Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Int16Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Int16List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Int16Buffer, I[274]);
typed_buffer.Uint32Buffer = class Uint32Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 361, 21, "initialLength");
return new typed_buffer.Uint32Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 364, 32, "size");
return _native_typed_data.NativeUint32List.new(size);
}
};
(typed_buffer.Uint32Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 361, 21, "initialLength");
typed_buffer.Uint32Buffer.__proto__.new.call(this, _native_typed_data.NativeUint32List.new(initialLength));
;
}).prototype = typed_buffer.Uint32Buffer.prototype;
dart.addTypeTests(typed_buffer.Uint32Buffer);
dart.addTypeCaches(typed_buffer.Uint32Buffer);
dart.setMethodSignature(typed_buffer.Uint32Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Uint32Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Uint32List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Uint32Buffer, I[274]);
typed_buffer.Int32Buffer = class Int32Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 368, 20, "initialLength");
return new typed_buffer.Int32Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 371, 31, "size");
return _native_typed_data.NativeInt32List.new(size);
}
};
(typed_buffer.Int32Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 368, 20, "initialLength");
typed_buffer.Int32Buffer.__proto__.new.call(this, _native_typed_data.NativeInt32List.new(initialLength));
;
}).prototype = typed_buffer.Int32Buffer.prototype;
dart.addTypeTests(typed_buffer.Int32Buffer);
dart.addTypeCaches(typed_buffer.Int32Buffer);
dart.setMethodSignature(typed_buffer.Int32Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Int32Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Int32List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Int32Buffer, I[274]);
typed_buffer.Uint64Buffer = class Uint64Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 375, 21, "initialLength");
return new typed_buffer.Uint64Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 378, 32, "size");
return typed_data.Uint64List.new(size);
}
};
(typed_buffer.Uint64Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 375, 21, "initialLength");
typed_buffer.Uint64Buffer.__proto__.new.call(this, typed_data.Uint64List.new(initialLength));
;
}).prototype = typed_buffer.Uint64Buffer.prototype;
dart.addTypeTests(typed_buffer.Uint64Buffer);
dart.addTypeCaches(typed_buffer.Uint64Buffer);
dart.setMethodSignature(typed_buffer.Uint64Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Uint64Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Uint64List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Uint64Buffer, I[274]);
typed_buffer.Int64Buffer = class Int64Buffer extends typed_buffer._IntBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 382, 20, "initialLength");
return new typed_buffer.Int64Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 385, 31, "size");
return typed_data.Int64List.new(size);
}
};
(typed_buffer.Int64Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 382, 20, "initialLength");
typed_buffer.Int64Buffer.__proto__.new.call(this, typed_data.Int64List.new(initialLength));
;
}).prototype = typed_buffer.Int64Buffer.prototype;
dart.addTypeTests(typed_buffer.Int64Buffer);
dart.addTypeCaches(typed_buffer.Int64Buffer);
dart.setMethodSignature(typed_buffer.Int64Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Int64Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Int64List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Int64Buffer, I[274]);
typed_buffer.Float32Buffer = class Float32Buffer extends typed_buffer._FloatBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 389, 22, "initialLength");
return new typed_buffer.Float32Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 392, 33, "size");
return _native_typed_data.NativeFloat32List.new(size);
}
};
(typed_buffer.Float32Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 389, 22, "initialLength");
typed_buffer.Float32Buffer.__proto__.new.call(this, _native_typed_data.NativeFloat32List.new(initialLength));
;
}).prototype = typed_buffer.Float32Buffer.prototype;
dart.addTypeTests(typed_buffer.Float32Buffer);
dart.addTypeCaches(typed_buffer.Float32Buffer);
dart.setMethodSignature(typed_buffer.Float32Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Float32Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Float32List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Float32Buffer, I[274]);
typed_buffer.Float64Buffer = class Float64Buffer extends typed_buffer._FloatBuffer {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 396, 22, "initialLength");
return new typed_buffer.Float64Buffer.new(initialLength);
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 399, 33, "size");
return _native_typed_data.NativeFloat64List.new(size);
}
};
(typed_buffer.Float64Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 396, 22, "initialLength");
typed_buffer.Float64Buffer.__proto__.new.call(this, _native_typed_data.NativeFloat64List.new(initialLength));
;
}).prototype = typed_buffer.Float64Buffer.prototype;
dart.addTypeTests(typed_buffer.Float64Buffer);
dart.addTypeCaches(typed_buffer.Float64Buffer);
dart.setMethodSignature(typed_buffer.Float64Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Float64Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Float64List, [core.int])
}));
dart.setLibraryUri(typed_buffer.Float64Buffer, I[274]);
typed_buffer.Int32x4Buffer = class Int32x4Buffer extends typed_buffer.TypedDataBuffer$(typed_data.Int32x4) {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 405, 22, "initialLength");
return new typed_buffer.Int32x4Buffer.new(initialLength);
}
get [S$0._defaultValue$1]() {
return typed_buffer.Int32x4Buffer._zero;
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 411, 33, "size");
return new _native_typed_data.NativeInt32x4List.new(size);
}
};
(typed_buffer.Int32x4Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 405, 22, "initialLength");
typed_buffer.Int32x4Buffer.__proto__.new.call(this, new _native_typed_data.NativeInt32x4List.new(initialLength));
;
}).prototype = typed_buffer.Int32x4Buffer.prototype;
dart.addTypeTests(typed_buffer.Int32x4Buffer);
dart.addTypeCaches(typed_buffer.Int32x4Buffer);
dart.setMethodSignature(typed_buffer.Int32x4Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Int32x4Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Int32x4List, [core.int])
}));
dart.setGetterSignature(typed_buffer.Int32x4Buffer, () => ({
__proto__: dart.getGetters(typed_buffer.Int32x4Buffer.__proto__),
[S$0._defaultValue$1]: typed_data.Int32x4
}));
dart.setLibraryUri(typed_buffer.Int32x4Buffer, I[274]);
dart.setStaticFieldSignature(typed_buffer.Int32x4Buffer, () => ['_zero']);
dart.defineLazy(typed_buffer.Int32x4Buffer, {
/*typed_buffer.Int32x4Buffer._zero*/get _zero() {
return new _native_typed_data.NativeInt32x4.new(0, 0, 0, 0);
}
}, false);
typed_buffer.Float32x4Buffer = class Float32x4Buffer extends typed_buffer.TypedDataBuffer$(typed_data.Float32x4) {
static ['_#new#tearOff'](initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 415, 24, "initialLength");
return new typed_buffer.Float32x4Buffer.new(initialLength);
}
get [S$0._defaultValue$1]() {
return new _native_typed_data.NativeFloat32x4.zero();
}
[S$0._createBuffer$1](size) {
if (size == null) dart.nullFailed(I[273], 422, 35, "size");
return new _native_typed_data.NativeFloat32x4List.new(size);
}
};
(typed_buffer.Float32x4Buffer.new = function(initialLength = 0) {
if (initialLength == null) dart.nullFailed(I[273], 415, 24, "initialLength");
typed_buffer.Float32x4Buffer.__proto__.new.call(this, new _native_typed_data.NativeFloat32x4List.new(initialLength));
;
}).prototype = typed_buffer.Float32x4Buffer.prototype;
dart.addTypeTests(typed_buffer.Float32x4Buffer);
dart.addTypeCaches(typed_buffer.Float32x4Buffer);
dart.setMethodSignature(typed_buffer.Float32x4Buffer, () => ({
__proto__: dart.getMethods(typed_buffer.Float32x4Buffer.__proto__),
[S$0._createBuffer$1]: dart.fnType(typed_data.Float32x4List, [core.int])
}));
dart.setGetterSignature(typed_buffer.Float32x4Buffer, () => ({
__proto__: dart.getGetters(typed_buffer.Float32x4Buffer.__proto__),
[S$0._defaultValue$1]: typed_data.Float32x4
}));
dart.setLibraryUri(typed_buffer.Float32x4Buffer, I[274]);
dart.trackLibraries("esiur", {
"org-dartlang-app:/esiur-js.dart": esiur_js,
"org-dartlang-app:/esiur.dart": esiur,
"org-dartlang-app:/src/Resource/Warehouse.dart": Warehouse,
"org-dartlang-app:/src/Resource/Instance.dart": Instance,
"org-dartlang-app:/src/Resource/IResource.dart": IResource,
"org-dartlang-app:/src/Resource/IStore.dart": IStore,
"org-dartlang-app:/src/Resource/ResourceTrigger.dart": ResourceTrigger,
"org-dartlang-app:/src/Resource/StorageMode.dart": StorageMode,
"org-dartlang-app:/src/Resource/Template/EventTemplate.dart": EventTemplate,
"org-dartlang-app:/src/Resource/Template/FunctionTemplate.dart": FunctionTemplate,
"org-dartlang-app:/src/Resource/Template/MemberTemplate.dart": MemberTemplate,
"org-dartlang-app:/src/Resource/Template/MemberType.dart": MemberType,
"org-dartlang-app:/src/Resource/Template/PropertyPermission.dart": PropertyPermission,
"org-dartlang-app:/src/Resource/Template/PropertyTemplate.dart": PropertyTemplate,
"org-dartlang-app:/src/Resource/Template/TypeTemplate.dart": TypeTemplate,
"org-dartlang-app:/src/Resource/Template/TemplateDescriber.dart": TemplateDescriber,
"org-dartlang-app:/src/Proxy/TemplateGenerator.dart": TemplateGenerator,
"org-dartlang-app:/src/Core/ProgressType.dart": ProgressType,
"org-dartlang-app:/src/Core/AsyncBag.dart": AsyncBag$,
"org-dartlang-app:/src/Core/AsyncException.dart": AsyncException,
"org-dartlang-app:/src/Core/AsyncQueue.dart": AsyncQueue$,
"org-dartlang-app:/src/Core/AsyncReply.dart": AsyncReply$,
"org-dartlang-app:/src/Core/ErrorType.dart": ErrorType,
"org-dartlang-app:/src/Core/ExceptionCode.dart": ExceptionCode,
"org-dartlang-app:/src/Core/IDestructible.dart": IDestructible,
"org-dartlang-app:/src/Core/IEventHandler.dart": IEventHandler,
"org-dartlang-app:/src/Core/Tuple.dart": Tuple,
"org-dartlang-app:/src/Data/AutoList.dart": AutoList$,
"org-dartlang-app:/src/Data/BinaryList.dart": BinaryList,
"org-dartlang-app:/src/Data/Codec.dart": Codec,
"org-dartlang-app:/src/Data/RepresentationType.dart": RepresentationType,
"org-dartlang-app:/src/Data/DC.dart": DC,
"org-dartlang-app:/src/Data/Guid.dart": Guid,
"org-dartlang-app:/src/Data/KeyList.dart": KeyList$,
"org-dartlang-app:/src/Data/NotModified.dart": NotModified,
"org-dartlang-app:/src/Data/PropertyValue.dart": PropertyValue,
"org-dartlang-app:/src/Data/SizeObject.dart": SizeObject,
"org-dartlang-app:/src/Data/ValueObject.dart": ValueObject,
"org-dartlang-app:/src/Data/IRecord.dart": IRecord,
"org-dartlang-app:/src/Data/Record.dart": Record,
"org-dartlang-app:/src/Data/IEnum.dart": IEnum,
"org-dartlang-app:/src/Data/IntType.dart": IntType,
"org-dartlang-app:/src/Net/NetworkBuffer.dart": NetworkBuffer,
"org-dartlang-app:/src/Net/NetworkConnection.dart": NetworkConnection,
"org-dartlang-app:/src/Net/SendList.dart": SendList,
"org-dartlang-app:/src/Net/IIP/DistributedConnection.dart": DistributedConnection,
"org-dartlang-app:/src/Net/IIP/DistributedPropertyContext.dart": DistributedPropertyContext,
"org-dartlang-app:/src/Net/IIP/DistributedResource.dart": DistributedResource,
"org-dartlang-app:/src/Net/IIP/DistributedResourceQueueItem.dart": DistributedResourceQueueItem,
"org-dartlang-app:/src/Net/IIP/DistributedResourceQueueItemType.dart": DistributedResourceQueueItemType,
"org-dartlang-app:/src/Net/Packets/IIPAuthPacket.dart": IIPAuthPacket,
"org-dartlang-app:/src/Net/Packets/IIPAuthPacketAction.dart": IIPAuthPacketAction,
"org-dartlang-app:/src/Net/Packets/IIPAuthPacketCommand.dart": IIPAuthPacketCommand,
"org-dartlang-app:/src/Net/Packets/IIPPacket.dart": IIPPacket,
"org-dartlang-app:/src/Net/Packets/IIPPacketAction.dart": IIPPacketAction,
"org-dartlang-app:/src/Net/Packets/IIPPacketCommand.dart": IIPPacketCommand,
"org-dartlang-app:/src/Net/Packets/IIPPacketEvent.dart": IIPPacketEvent,
"org-dartlang-app:/src/Net/Packets/IIPPacketReport.dart": IIPPacketReport,
"org-dartlang-app:/src/Net/Sockets/IPEndPoint.dart": IPEndPoint,
"org-dartlang-app:/src/Net/Sockets/ISocket.dart": ISocket,
"org-dartlang-app:/src/Net/Sockets/SocketState.dart": SocketState,
"org-dartlang-app:/src/Net/Sockets/TCPSocket.dart": TCPSocket,
"org-dartlang-app:/src/Security/Authority/Authentication.dart": Authentication,
"org-dartlang-app:/src/Security/Authority/AuthenticationState.dart": AuthenticationState,
"org-dartlang-app:/src/Security/Authority/AuthenticationType.dart": AuthenticationType,
"org-dartlang-app:/src/Security/Authority/AuthenticationMethod.dart": AuthenticationMethod,
"org-dartlang-app:/src/Security/Authority/ClientAuthentication.dart": ClientAuthentication,
"org-dartlang-app:/src/Security/Authority/CoHostAuthentication.dart": CoHostAuthentication,
"org-dartlang-app:/src/Security/Authority/HostAuthentication.dart": HostAuthentication,
"org-dartlang-app:/src/Security/Authority/Session.dart": Session,
"org-dartlang-app:/src/Security/Authority/Source.dart": Source,
"org-dartlang-app:/src/Security/Authority/SourceAttributeType.dart": SourceAttributeType,
"org-dartlang-app:/src/Security/Integrity/SHA256.dart": SHA256,
"org-dartlang-app:/src/Security/Permissions/ActionType.dart": ActionType,
"org-dartlang-app:/src/Security/Permissions/IPermissionsManager.dart": IPermissionsManager,
"org-dartlang-app:/src/Security/Permissions/Ruling.dart": Ruling,
"org-dartlang-app:/src/Data/TransmissionType.dart": TransmissionType,
"org-dartlang-app:/src/Resource/FactoryEntry.dart": FactoryEntry$,
"org-dartlang-app:/src/Resource/Template/TemplateType.dart": TemplateType,
"org-dartlang-app:/src/Resource/EventOccurredInfo.dart": EventOccurredInfo,
"org-dartlang-app:/src/Core/PropertyModificationInfo.dart": PropertyModificationInfo,
"org-dartlang-app:/src/Resource/Template/ArgumentTemplate.dart": ArgumentTemplate,
"org-dartlang-app:/src/Resource/Template/ConstantTemplate.dart": ConstantTemplate,
"package:collection/collection.dart": collection$,
"org-dartlang-app:/src/Data/DataDeserializer.dart": DataDeserializer,
"org-dartlang-app:/src/Data/DataSerializer.dart": DataSerializer,
"org-dartlang-app:/src/Data/ResourceArrayType.dart": ResourceArrayType,
"org-dartlang-app:/src/Net/INetworkReceiver.dart": INetworkReceiver$,
"org-dartlang-app:/src/Resource/PropertyModificationInfo.dart": PropertyModificationInfo$,
"org-dartlang-app:/src/Net/Sockets/WSocket.dart": WSocket,
"org-dartlang-app:/src/Net/IIP/DistributedServer.dart": DistributedServer,
"org-dartlang-app:/src/Data/KeyValuePair.dart": KeyValuePair$,
"org-dartlang-app:/src/Data/ParseResult.dart": ParseResult$,
"package:collection/src/algorithms.dart": algorithms,
"package:collection/src/canonicalized_map.dart": canonicalized_map,
"package:collection/src/combined_wrappers/combined_iterable.dart": combined_iterable,
"package:collection/src/combined_wrappers/combined_list.dart": combined_list,
"package:collection/src/combined_wrappers/combined_map.dart": combined_map,
"package:collection/src/comparators.dart": comparators,
"package:collection/src/equality.dart": equality$,
"package:collection/src/equality_map.dart": equality_map,
"package:collection/src/equality_set.dart": equality_set,
"package:collection/src/functions.dart": functions,
"package:collection/src/iterable_extensions.dart": iterable_extensions,
"package:collection/src/iterable_zip.dart": iterable_zip,
"package:collection/src/list_extensions.dart": list_extensions,
"package:collection/src/priority_queue.dart": priority_queue,
"package:collection/src/queue_list.dart": queue_list,
"package:collection/src/union_set.dart": union_set,
"package:collection/src/union_set_controller.dart": union_set_controller,
"package:collection/src/unmodifiable_wrappers.dart": unmodifiable_wrappers,
"package:collection/src/wrappers.dart": wrappers,
"package:web_socket_channel/web_socket_channel.dart": web_socket_channel,
"org-dartlang-app:/src/Net/IIP/EntryPoint.dart": EntryPoint,
"package:collection/src/utils.dart": utils,
"package:collection/src/combined_wrappers/combined_iterator.dart": combined_iterator,
"package:collection/src/empty_unmodifiable_set.dart": empty_unmodifiable_set,
"package:web_socket_channel/src/channel.dart": channel$,
"package:web_socket_channel/src/exception.dart": exception,
"package:async/async.dart": async$,
"package:crypto/crypto.dart": crypto,
"package:stream_channel/stream_channel.dart": stream_channel,
"package:web_socket_channel/src/_connect_html.dart": _connect_html,
"package:web_socket_channel/src/copy/web_socket_impl.dart": web_socket_impl,
"package:async/src/async_cache.dart": async_cache,
"package:async/src/async_memoizer.dart": async_memoizer,
"package:async/src/byte_collector.dart": byte_collector,
"package:async/src/cancelable_operation.dart": cancelable_operation,
"package:async/src/delegate/event_sink.dart": event_sink,
"package:async/src/delegate/future.dart": future,
"package:async/src/delegate/sink.dart": sink$,
"package:async/src/delegate/stream.dart": stream$,
"package:async/src/delegate/stream_consumer.dart": stream_consumer,
"package:async/src/delegate/stream_sink.dart": stream_sink,
"package:async/src/delegate/stream_subscription.dart": stream_subscription,
"package:async/src/future_group.dart": future_group,
"package:async/src/lazy_stream.dart": lazy_stream,
"package:async/src/null_stream_sink.dart": null_stream_sink,
"package:async/src/restartable_timer.dart": restartable_timer,
"package:async/src/result/result.dart": result$,
"package:async/src/result/error.dart": error$,
"package:async/src/result/future.dart": future$,
"package:async/src/result/value.dart": value$,
"package:async/src/single_subscription_transformer.dart": single_subscription_transformer,
"package:async/src/sink_base.dart": sink_base,
"package:async/src/stream_closer.dart": stream_closer,
"package:async/src/stream_completer.dart": stream_completer,
"package:async/src/stream_extensions.dart": stream_extensions,
"package:async/src/stream_group.dart": stream_group,
"package:async/src/stream_queue.dart": stream_queue,
"package:async/src/stream_sink_completer.dart": stream_sink_completer,
"package:async/src/stream_sink_extensions.dart": stream_sink_extensions,
"package:async/src/stream_sink_transformer.dart": stream_sink_transformer,
"package:async/src/stream_splitter.dart": stream_splitter,
"package:async/src/stream_subscription_transformer.dart": stream_subscription_transformer,
"package:async/src/stream_zip.dart": stream_zip,
"package:async/src/subscription_stream.dart": subscription_stream,
"package:async/src/typed_stream_transformer.dart": typed_stream_transformer,
"package:async/src/chunked_stream_reader.dart": chunked_stream_reader,
"package:crypto/src/digest.dart": digest,
"package:crypto/src/hash.dart": hash,
"package:crypto/src/hmac.dart": hmac,
"package:crypto/src/md5.dart": md5,
"package:crypto/src/sha1.dart": sha1,
"package:crypto/src/sha256.dart": sha256,
"package:crypto/src/sha512.dart": sha512,
"package:stream_channel/src/guarantee_channel.dart": guarantee_channel,
"package:stream_channel/src/close_guarantee_channel.dart": close_guarantee_channel,
"package:stream_channel/src/stream_channel_transformer.dart": stream_channel_transformer,
"package:stream_channel/src/delegating_stream_channel.dart": delegating_stream_channel,
"package:stream_channel/src/disconnector.dart": disconnector,
"package:stream_channel/src/json_document_transformer.dart": json_document_transformer,
"package:stream_channel/src/multi_channel.dart": multi_channel,
"package:stream_channel/src/stream_channel_completer.dart": stream_channel_completer,
"package:stream_channel/src/stream_channel_controller.dart": stream_channel_controller,
"package:web_socket_channel/html.dart": html$,
"package:web_socket_channel/src/copy/io_sink.dart": io_sink,
"package:web_socket_channel/src/copy/web_socket.dart": web_socket,
"package:async/src/utils.dart": utils$,
"package:async/src/typed/stream_subscription.dart": stream_subscription$,
"package:async/src/result/capture_sink.dart": capture_sink,
"package:async/src/result/capture_transformer.dart": capture_transformer,
"package:async/src/result/release_sink.dart": release_sink,
"package:async/src/result/release_transformer.dart": release_transformer,
"package:meta/meta.dart": meta,
"package:async/src/stream_sink_transformer/reject_errors.dart": reject_errors,
"package:async/src/stream_sink_transformer/handler_transformer.dart": handler_transformer,
"package:async/src/stream_sink_transformer/stream_transformer_wrapper.dart": stream_transformer_wrapper,
"package:async/src/stream_sink_transformer/typed.dart": typed,
"package:crypto/src/digest_sink.dart": digest_sink,
"package:crypto/src/hash_sink.dart": hash_sink,
"package:crypto/src/utils.dart": utils$0,
"package:crypto/src/sha512_slowsinks.dart": sha512_slowsinks,
"package:meta/meta_meta.dart": meta_meta,
"package:typed_data/typed_data.dart": typed_data$,
"package:typed_data/src/typed_queue.dart": typed_queue,
"package:typed_data/typed_buffers.dart": typed_buffers,
"package:typed_data/src/typed_buffer.dart": typed_buffer
}, {
}, null);
// Exports:
return {
esiur_js: esiur_js,
esiur: esiur,
src__Resource__Warehouse: Warehouse,
src__Resource__Instance: Instance,
src__Resource__IResource: IResource,
src__Resource__IStore: IStore,
src__Resource__ResourceTrigger: ResourceTrigger,
src__Resource__StorageMode: StorageMode,
src__Resource__Template__EventTemplate: EventTemplate,
src__Resource__Template__FunctionTemplate: FunctionTemplate,
src__Resource__Template__MemberTemplate: MemberTemplate,
src__Resource__Template__MemberType: MemberType,
src__Resource__Template__PropertyPermission: PropertyPermission,
src__Resource__Template__PropertyTemplate: PropertyTemplate,
src__Resource__Template__TypeTemplate: TypeTemplate,
src__Resource__Template__TemplateDescriber: TemplateDescriber,
src__Proxy__TemplateGenerator: TemplateGenerator,
src__Core__ProgressType: ProgressType,
src__Core__AsyncBag: AsyncBag$,
src__Core__AsyncException: AsyncException,
src__Core__AsyncQueue: AsyncQueue$,
src__Core__AsyncReply: AsyncReply$,
src__Core__ErrorType: ErrorType,
src__Core__ExceptionCode: ExceptionCode,
src__Core__IDestructible: IDestructible,
src__Core__IEventHandler: IEventHandler,
src__Core__Tuple: Tuple,
src__Data__AutoList: AutoList$,
src__Data__BinaryList: BinaryList,
src__Data__Codec: Codec,
src__Data__RepresentationType: RepresentationType,
src__Data__DC: DC,
src__Data__Guid: Guid,
src__Data__KeyList: KeyList$,
src__Data__NotModified: NotModified,
src__Data__PropertyValue: PropertyValue,
src__Data__SizeObject: SizeObject,
src__Data__ValueObject: ValueObject,
src__Data__IRecord: IRecord,
src__Data__Record: Record,
src__Data__IEnum: IEnum,
src__Data__IntType: IntType,
src__Net__NetworkBuffer: NetworkBuffer,
src__Net__NetworkConnection: NetworkConnection,
src__Net__SendList: SendList,
src__Net__IIP__DistributedConnection: DistributedConnection,
src__Net__IIP__DistributedPropertyContext: DistributedPropertyContext,
src__Net__IIP__DistributedResource: DistributedResource,
src__Net__IIP__DistributedResourceQueueItem: DistributedResourceQueueItem,
src__Net__IIP__DistributedResourceQueueItemType: DistributedResourceQueueItemType,
src__Net__Packets__IIPAuthPacket: IIPAuthPacket,
src__Net__Packets__IIPAuthPacketAction: IIPAuthPacketAction,
src__Net__Packets__IIPAuthPacketCommand: IIPAuthPacketCommand,
src__Net__Packets__IIPPacket: IIPPacket,
src__Net__Packets__IIPPacketAction: IIPPacketAction,
src__Net__Packets__IIPPacketCommand: IIPPacketCommand,
src__Net__Packets__IIPPacketEvent: IIPPacketEvent,
src__Net__Packets__IIPPacketReport: IIPPacketReport,
src__Net__Sockets__IPEndPoint: IPEndPoint,
src__Net__Sockets__ISocket: ISocket,
src__Net__Sockets__SocketState: SocketState,
src__Net__Sockets__TCPSocket: TCPSocket,
src__Security__Authority__Authentication: Authentication,
src__Security__Authority__AuthenticationState: AuthenticationState,
src__Security__Authority__AuthenticationType: AuthenticationType,
src__Security__Authority__AuthenticationMethod: AuthenticationMethod,
src__Security__Authority__ClientAuthentication: ClientAuthentication,
src__Security__Authority__CoHostAuthentication: CoHostAuthentication,
src__Security__Authority__HostAuthentication: HostAuthentication,
src__Security__Authority__Session: Session,
src__Security__Authority__Source: Source,
src__Security__Authority__SourceAttributeType: SourceAttributeType,
src__Security__Integrity__SHA256: SHA256,
src__Security__Permissions__ActionType: ActionType,
src__Security__Permissions__IPermissionsManager: IPermissionsManager,
src__Security__Permissions__Ruling: Ruling,
src__Data__TransmissionType: TransmissionType,
src__Resource__FactoryEntry: FactoryEntry$,
src__Resource__Template__TemplateType: TemplateType,
src__Resource__EventOccurredInfo: EventOccurredInfo,
src__Core__PropertyModificationInfo: PropertyModificationInfo,
src__Resource__Template__ArgumentTemplate: ArgumentTemplate,
src__Resource__Template__ConstantTemplate: ConstantTemplate,
collection: collection$,
src__Data__DataDeserializer: DataDeserializer,
src__Data__DataSerializer: DataSerializer,
src__Data__ResourceArrayType: ResourceArrayType,
src__Net__INetworkReceiver: INetworkReceiver$,
src__Resource__PropertyModificationInfo: PropertyModificationInfo$,
src__Net__Sockets__WSocket: WSocket,
src__Net__IIP__DistributedServer: DistributedServer,
src__Data__KeyValuePair: KeyValuePair$,
src__Data__ParseResult: ParseResult$,
src__algorithms: algorithms,
src__canonicalized_map: canonicalized_map,
src__combined_wrappers__combined_iterable: combined_iterable,
src__combined_wrappers__combined_list: combined_list,
src__combined_wrappers__combined_map: combined_map,
src__comparators: comparators,
src__equality: equality$,
src__equality_map: equality_map,
src__equality_set: equality_set,
src__functions: functions,
src__iterable_extensions: iterable_extensions,
src__iterable_zip: iterable_zip,
src__list_extensions: list_extensions,
src__priority_queue: priority_queue,
src__queue_list: queue_list,
src__union_set: union_set,
src__union_set_controller: union_set_controller,
src__unmodifiable_wrappers: unmodifiable_wrappers,
src__wrappers: wrappers,
web_socket_channel: web_socket_channel,
src__Net__IIP__EntryPoint: EntryPoint,
src__utils: utils,
src__combined_wrappers__combined_iterator: combined_iterator,
src__empty_unmodifiable_set: empty_unmodifiable_set,
src__channel: channel$,
src__exception: exception,
async: async$,
crypto: crypto,
stream_channel: stream_channel,
src___connect_html: _connect_html,
src__copy__web_socket_impl: web_socket_impl,
src__async_cache: async_cache,
src__async_memoizer: async_memoizer,
src__byte_collector: byte_collector,
src__cancelable_operation: cancelable_operation,
src__delegate__event_sink: event_sink,
src__delegate__future: future,
src__delegate__sink: sink$,
src__delegate__stream: stream$,
src__delegate__stream_consumer: stream_consumer,
src__delegate__stream_sink: stream_sink,
src__delegate__stream_subscription: stream_subscription,
src__future_group: future_group,
src__lazy_stream: lazy_stream,
src__null_stream_sink: null_stream_sink,
src__restartable_timer: restartable_timer,
src__result__result: result$,
src__result__error: error$,
src__result__future: future$,
src__result__value: value$,
src__single_subscription_transformer: single_subscription_transformer,
src__sink_base: sink_base,
src__stream_closer: stream_closer,
src__stream_completer: stream_completer,
src__stream_extensions: stream_extensions,
src__stream_group: stream_group,
src__stream_queue: stream_queue,
src__stream_sink_completer: stream_sink_completer,
src__stream_sink_extensions: stream_sink_extensions,
src__stream_sink_transformer: stream_sink_transformer,
src__stream_splitter: stream_splitter,
src__stream_subscription_transformer: stream_subscription_transformer,
src__stream_zip: stream_zip,
src__subscription_stream: subscription_stream,
src__typed_stream_transformer: typed_stream_transformer,
src__chunked_stream_reader: chunked_stream_reader,
src__digest: digest,
src__hash: hash,
src__hmac: hmac,
src__md5: md5,
src__sha1: sha1,
src__sha256: sha256,
src__sha512: sha512,
src__guarantee_channel: guarantee_channel,
src__close_guarantee_channel: close_guarantee_channel,
src__stream_channel_transformer: stream_channel_transformer,
src__delegating_stream_channel: delegating_stream_channel,
src__disconnector: disconnector,
src__json_document_transformer: json_document_transformer,
src__multi_channel: multi_channel,
src__stream_channel_completer: stream_channel_completer,
src__stream_channel_controller: stream_channel_controller,
html: html$,
src__copy__io_sink: io_sink,
src__copy__web_socket: web_socket,
src__utils: utils$,
src__typed__stream_subscription: stream_subscription$,
src__result__capture_sink: capture_sink,
src__result__capture_transformer: capture_transformer,
src__result__release_sink: release_sink,
src__result__release_transformer: release_transformer,
meta: meta,
src__stream_sink_transformer__reject_errors: reject_errors,
src__stream_sink_transformer__handler_transformer: handler_transformer,
src__stream_sink_transformer__stream_transformer_wrapper: stream_transformer_wrapper,
src__stream_sink_transformer__typed: typed,
src__digest_sink: digest_sink,
src__hash_sink: hash_sink,
src__utils: utils$0,
src__sha512_slowsinks: sha512_slowsinks,
meta_meta: meta_meta,
typed_data: typed_data$,
src__typed_queue: typed_queue,
typed_buffers: typed_buffers,
src__typed_buffer: typed_buffer
};
}));
//# sourceMappingURL=esiur.js.map