// Generated by dart2js (, csp, intern-composite-values), the Dart to JavaScript compiler version: 3.10.3.
// The code supports the following hooks:
// dartPrint(message):
//    if this function is defined it is called instead of the Dart [print]
//    method.
//
// dartMainRunner(main, args):
//    if this function is defined, the Dart [main] method will not be invoked
//    directly. Instead, a closure that will invoke [main], and its arguments
//    [args] is passed to [dartMainRunner].
//
// dartDeferredLibraryLoader(uri, successCallback, errorCallback, loadId, loadPriority):
//    if this function is defined, it will be called when a deferred library
//    is loaded. It should load and eval the javascript of `uri`, and call
//    successCallback. If it fails to do so, it should call errorCallback with
//    an error. The loadId argument is the deferred import that resulted in
//    this uri being loaded. The loadPriority argument is an arbitrary argument
//    string forwarded from the 'dart2js:load-priority' pragma option.
// dartDeferredLibraryMultiLoader(uris, successCallback, errorCallback, loadId, loadPriority):
//    if this function is defined, it will be called when a deferred library
//    is loaded. It should load and eval the javascript of every URI in `uris`,
//    and call successCallback. If it fails to do so, it should call
//    errorCallback with an error. The loadId argument is the deferred import
//    that resulted in this uri being loaded. The loadPriority argument is an
//    arbitrary argument string forwarded from the 'dart2js:load-priority'
//    pragma option.
//
// dartCallInstrumentation(id, qualifiedName):
//    if this function is defined, it will be called at each entry of a
//    method or constructor. Used only when compiling programs with
//    --experiment-call-instrumentation.
(function dartProgram() {
  function copyProperties(from, to) {
    var keys = Object.keys(from);
    for (var i = 0; i < keys.length; i++) {
      var key = keys[i];
      to[key] = from[key];
    }
  }
  function mixinPropertiesHard(from, to) {
    var keys = Object.keys(from);
    for (var i = 0; i < keys.length; i++) {
      var key = keys[i];
      if (!to.hasOwnProperty(key)) {
        to[key] = from[key];
      }
    }
  }
  function mixinPropertiesEasy(from, to) {
    Object.assign(to, from);
  }
  var supportsDirectProtoAccess = function() {
    var cls = function() {
    };
    cls.prototype = {p: {}};
    var object = new cls();
    if (!(Object.getPrototypeOf(object) && Object.getPrototypeOf(object).p === cls.prototype.p))
      return false;
    try {
      if (typeof navigator != "undefined" && typeof navigator.userAgent == "string" && navigator.userAgent.indexOf("Chrome/") >= 0)
        return true;
      if (typeof version == "function" && version.length == 0) {
        var v = version();
        if (/^\d+\.\d+\.\d+\.\d+$/.test(v))
          return true;
      }
    } catch (_) {
    }
    return false;
  }();
  function inherit(cls, sup) {
    cls.prototype.constructor = cls;
    cls.prototype["$is" + cls.name] = cls;
    if (sup != null) {
      if (supportsDirectProtoAccess) {
        Object.setPrototypeOf(cls.prototype, sup.prototype);
        return;
      }
      var clsPrototype = Object.create(sup.prototype);
      copyProperties(cls.prototype, clsPrototype);
      cls.prototype = clsPrototype;
    }
  }
  function inheritMany(sup, classes) {
    for (var i = 0; i < classes.length; i++) {
      inherit(classes[i], sup);
    }
  }
  function mixinEasy(cls, mixin) {
    mixinPropertiesEasy(mixin.prototype, cls.prototype);
    cls.prototype.constructor = cls;
  }
  function mixinHard(cls, mixin) {
    mixinPropertiesHard(mixin.prototype, cls.prototype);
    cls.prototype.constructor = cls;
  }
  function lazy(holder, name, getterName, initializer) {
    var uninitializedSentinel = holder;
    holder[name] = uninitializedSentinel;
    holder[getterName] = function() {
      if (holder[name] === uninitializedSentinel) {
        holder[name] = initializer();
      }
      holder[getterName] = function() {
        return this[name];
      };
      return holder[name];
    };
  }
  function lazyFinal(holder, name, getterName, initializer) {
    var uninitializedSentinel = holder;
    holder[name] = uninitializedSentinel;
    holder[getterName] = function() {
      if (holder[name] === uninitializedSentinel) {
        var value = initializer();
        if (holder[name] !== uninitializedSentinel) {
          A.throwLateFieldADI(name);
        }
        holder[name] = value;
      }
      var finalValue = holder[name];
      holder[getterName] = function() {
        return finalValue;
      };
      return finalValue;
    };
  }
  function makeConstList(list, rti) {
    if (rti != null)
      A._setArrayType(list, rti);
    list.$flags = 7;
    return list;
  }
  function convertToFastObject(properties) {
    function t() {
    }
    t.prototype = properties;
    new t();
    return properties;
  }
  function convertAllToFastObject(arrayOfObjects) {
    for (var i = 0; i < arrayOfObjects.length; ++i) {
      convertToFastObject(arrayOfObjects[i]);
    }
  }
  var functionCounter = 0;
  function instanceTearOffGetter(isIntercepted, parameters) {
    var cache = null;
    return isIntercepted ? function(receiver) {
      if (cache === null)
        cache = A.closureFromTearOff(parameters);
      return new cache(receiver, this);
    } : function() {
      if (cache === null)
        cache = A.closureFromTearOff(parameters);
      return new cache(this, null);
    };
  }
  function staticTearOffGetter(parameters) {
    var cache = null;
    return function() {
      if (cache === null)
        cache = A.closureFromTearOff(parameters).prototype;
      return cache;
    };
  }
  var typesOffset = 0;
  function tearOffParameters(container, isStatic, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex, needsDirectAccess) {
    if (typeof funType == "number") {
      funType += typesOffset;
    }
    return {co: container, iS: isStatic, iI: isIntercepted, rC: requiredParameterCount, dV: optionalParameterDefaultValues, cs: callNames, fs: funsOrNames, fT: funType, aI: applyIndex || 0, nDA: needsDirectAccess};
  }
  function installStaticTearOff(holder, getterName, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) {
    var parameters = tearOffParameters(holder, true, false, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex, false);
    var getterFunction = staticTearOffGetter(parameters);
    holder[getterName] = getterFunction;
  }
  function installInstanceTearOff(prototype, getterName, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex, needsDirectAccess) {
    isIntercepted = !!isIntercepted;
    var parameters = tearOffParameters(prototype, false, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex, !!needsDirectAccess);
    var getterFunction = instanceTearOffGetter(isIntercepted, parameters);
    prototype[getterName] = getterFunction;
  }
  function setOrUpdateInterceptorsByTag(newTags) {
    var tags = init.interceptorsByTag;
    if (!tags) {
      init.interceptorsByTag = newTags;
      return;
    }
    copyProperties(newTags, tags);
  }
  function setOrUpdateLeafTags(newTags) {
    var tags = init.leafTags;
    if (!tags) {
      init.leafTags = newTags;
      return;
    }
    copyProperties(newTags, tags);
  }
  function updateTypes(newTypes) {
    var types = init.types;
    var length = types.length;
    types.push.apply(types, newTypes);
    return length;
  }
  function updateHolder(holder, newHolder) {
    copyProperties(newHolder, holder);
    return holder;
  }
  var hunkHelpers = function() {
    var mkInstance = function(isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, applyIndex) {
        return function(container, getterName, name, funType) {
          return installInstanceTearOff(container, getterName, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, [name], funType, applyIndex, false);
        };
      },
      mkStatic = function(requiredParameterCount, optionalParameterDefaultValues, callNames, applyIndex) {
        return function(container, getterName, name, funType) {
          return installStaticTearOff(container, getterName, requiredParameterCount, optionalParameterDefaultValues, callNames, [name], funType, applyIndex);
        };
      };
    return {inherit: inherit, inheritMany: inheritMany, mixin: mixinEasy, mixinHard: mixinHard, installStaticTearOff: installStaticTearOff, installInstanceTearOff: installInstanceTearOff, _instance_0u: mkInstance(0, 0, null, ["call$0"], 0), _instance_1u: mkInstance(0, 1, null, ["call$1"], 0), _instance_2u: mkInstance(0, 2, null, ["call$2"], 0), _instance_0i: mkInstance(1, 0, null, ["call$0"], 0), _instance_1i: mkInstance(1, 1, null, ["call$1"], 0), _instance_2i: mkInstance(1, 2, null, ["call$2"], 0), _static_0: mkStatic(0, null, ["call$0"], 0), _static_1: mkStatic(1, null, ["call$1"], 0), _static_2: mkStatic(2, null, ["call$2"], 0), makeConstList: makeConstList, lazy: lazy, lazyFinal: lazyFinal, updateHolder: updateHolder, convertToFastObject: convertToFastObject, updateTypes: updateTypes, setOrUpdateInterceptorsByTag: setOrUpdateInterceptorsByTag, setOrUpdateLeafTags: setOrUpdateLeafTags};
  }();
  function initializeDeferredHunk(hunk) {
    typesOffset = init.types.length;
    hunk(hunkHelpers, init, holders, $);
  }
  var J = {
    makeDispatchRecord(interceptor, proto, extension, indexability) {
      return {i: interceptor, p: proto, e: extension, x: indexability};
    },
    getNativeInterceptor(object) {
      var proto, objectProto, $constructor, interceptor, t1,
        record = object[init.dispatchPropertyName];
      if (record == null)
        if ($.initNativeDispatchFlag == null) {
          A.initNativeDispatch();
          record = object[init.dispatchPropertyName];
        }
      if (record != null) {
        proto = record.p;
        if (false === proto)
          return record.i;
        if (true === proto)
          return object;
        objectProto = Object.getPrototypeOf(object);
        if (proto === objectProto)
          return record.i;
        if (record.e === objectProto)
          throw A.wrapException(A.UnimplementedError$("Return interceptor for " + A.S(proto(object, record))));
      }
      $constructor = object.constructor;
      if ($constructor == null)
        interceptor = null;
      else {
        t1 = $._JS_INTEROP_INTERCEPTOR_TAG;
        if (t1 == null)
          t1 = $._JS_INTEROP_INTERCEPTOR_TAG = init.getIsolateTag("_$dart_js");
        interceptor = $constructor[t1];
      }
      if (interceptor != null)
        return interceptor;
      interceptor = A.lookupAndCacheInterceptor(object);
      if (interceptor != null)
        return interceptor;
      if (typeof object == "function")
        return B.JavaScriptFunction_methods;
      proto = Object.getPrototypeOf(object);
      if (proto == null)
        return B.PlainJavaScriptObject_methods;
      if (proto === Object.prototype)
        return B.PlainJavaScriptObject_methods;
      if (typeof $constructor == "function") {
        t1 = $._JS_INTEROP_INTERCEPTOR_TAG;
        if (t1 == null)
          t1 = $._JS_INTEROP_INTERCEPTOR_TAG = init.getIsolateTag("_$dart_js");
        Object.defineProperty($constructor, t1, {value: B.UnknownJavaScriptObject_methods, enumerable: false, writable: true, configurable: true});
        return B.UnknownJavaScriptObject_methods;
      }
      return B.UnknownJavaScriptObject_methods;
    },
    JSArray_JSArray$fixed($length, $E) {
      if ($length < 0 || $length > 4294967295)
        throw A.wrapException(A.RangeError$range($length, 0, 4294967295, "length", null));
      return J.JSArray_JSArray$markFixed(new Array($length), $E);
    },
    JSArray_JSArray$allocateGrowable($length, $E) {
      return A._setArrayType(new Array($length), $E._eval$1("JSArray<0>"));
    },
    JSArray_JSArray$markFixed(allocation, $E) {
      var t1 = A._setArrayType(allocation, $E._eval$1("JSArray<0>"));
      t1.$flags = 1;
      return t1;
    },
    getInterceptor$(receiver) {
      if (typeof receiver == "number") {
        if (Math.floor(receiver) == receiver)
          return J.JSInt.prototype;
        return J.JSNumNotInt.prototype;
      }
      if (typeof receiver == "string")
        return J.JSString.prototype;
      if (receiver == null)
        return J.JSNull.prototype;
      if (typeof receiver == "boolean")
        return J.JSBool.prototype;
      if (Array.isArray(receiver))
        return J.JSArray.prototype;
      if (typeof receiver != "object") {
        if (typeof receiver == "function")
          return J.JavaScriptFunction.prototype;
        if (typeof receiver == "symbol")
          return J.JavaScriptSymbol.prototype;
        if (typeof receiver == "bigint")
          return J.JavaScriptBigInt.prototype;
        return receiver;
      }
      if (receiver instanceof A.Object)
        return receiver;
      return J.getNativeInterceptor(receiver);
    },
    getInterceptor$asx(receiver) {
      if (typeof receiver == "string")
        return J.JSString.prototype;
      if (receiver == null)
        return receiver;
      if (Array.isArray(receiver))
        return J.JSArray.prototype;
      if (typeof receiver != "object") {
        if (typeof receiver == "function")
          return J.JavaScriptFunction.prototype;
        if (typeof receiver == "symbol")
          return J.JavaScriptSymbol.prototype;
        if (typeof receiver == "bigint")
          return J.JavaScriptBigInt.prototype;
        return receiver;
      }
      if (receiver instanceof A.Object)
        return receiver;
      return J.getNativeInterceptor(receiver);
    },
    getInterceptor$ax(receiver) {
      if (receiver == null)
        return receiver;
      if (Array.isArray(receiver))
        return J.JSArray.prototype;
      if (typeof receiver != "object") {
        if (typeof receiver == "function")
          return J.JavaScriptFunction.prototype;
        if (typeof receiver == "symbol")
          return J.JavaScriptSymbol.prototype;
        if (typeof receiver == "bigint")
          return J.JavaScriptBigInt.prototype;
        return receiver;
      }
      if (receiver instanceof A.Object)
        return receiver;
      return J.getNativeInterceptor(receiver);
    },
    getInterceptor$x(receiver) {
      if (receiver == null)
        return receiver;
      if (typeof receiver != "object") {
        if (typeof receiver == "function")
          return J.JavaScriptFunction.prototype;
        if (typeof receiver == "symbol")
          return J.JavaScriptSymbol.prototype;
        if (typeof receiver == "bigint")
          return J.JavaScriptBigInt.prototype;
        return receiver;
      }
      if (receiver instanceof A.Object)
        return receiver;
      return J.getNativeInterceptor(receiver);
    },
    get$hashCode$(receiver) {
      return J.getInterceptor$(receiver).get$hashCode(receiver);
    },
    get$iterator$ax(receiver) {
      return J.getInterceptor$ax(receiver).get$iterator(receiver);
    },
    get$length$asx(receiver) {
      return J.getInterceptor$asx(receiver).get$length(receiver);
    },
    get$lengthInBytes$x(receiver) {
      return J.getInterceptor$x(receiver).get$lengthInBytes(receiver);
    },
    get$runtimeType$(receiver) {
      return J.getInterceptor$(receiver).get$runtimeType(receiver);
    },
    $eq$(receiver, a0) {
      if (receiver == null)
        return a0 == null;
      if (typeof receiver != "object")
        return a0 != null && receiver === a0;
      return J.getInterceptor$(receiver).$eq(receiver, a0);
    },
    asFloat32List$2$x(receiver, a0, a1) {
      return J.getInterceptor$x(receiver).asFloat32List$2(receiver, a0, a1);
    },
    asUint16List$2$x(receiver, a0, a1) {
      return J.getInterceptor$x(receiver).asUint16List$2(receiver, a0, a1);
    },
    asUint32List$2$x(receiver, a0, a1) {
      return J.getInterceptor$x(receiver).asUint32List$2(receiver, a0, a1);
    },
    asUint8List$0$x(receiver) {
      return J.getInterceptor$x(receiver).asUint8List$0(receiver);
    },
    asUint8List$2$x(receiver, a0, a1) {
      return J.getInterceptor$x(receiver).asUint8List$2(receiver, a0, a1);
    },
    elementAt$1$ax(receiver, a0) {
      return J.getInterceptor$ax(receiver).elementAt$1(receiver, a0);
    },
    map$1$1$ax(receiver, a0, $T1) {
      return J.getInterceptor$ax(receiver).map$1$1(receiver, a0, $T1);
    },
    toString$0$(receiver) {
      return J.getInterceptor$(receiver).toString$0(receiver);
    },
    Interceptor: function Interceptor() {
    },
    JSBool: function JSBool() {
    },
    JSNull: function JSNull() {
    },
    JavaScriptObject: function JavaScriptObject() {
    },
    LegacyJavaScriptObject: function LegacyJavaScriptObject() {
    },
    PlainJavaScriptObject: function PlainJavaScriptObject() {
    },
    UnknownJavaScriptObject: function UnknownJavaScriptObject() {
    },
    JavaScriptFunction: function JavaScriptFunction() {
    },
    JavaScriptBigInt: function JavaScriptBigInt() {
    },
    JavaScriptSymbol: function JavaScriptSymbol() {
    },
    JSArray: function JSArray(t0) {
      this.$ti = t0;
    },
    JSArraySafeToStringHook: function JSArraySafeToStringHook() {
    },
    JSUnmodifiableArray: function JSUnmodifiableArray(t0) {
      this.$ti = t0;
    },
    ArrayIterator: function ArrayIterator(t0, t1, t2) {
      var _ = this;
      _._iterable = t0;
      _._length = t1;
      _._index = 0;
      _._current = null;
      _.$ti = t2;
    },
    JSNumber: function JSNumber() {
    },
    JSInt: function JSInt() {
    },
    JSNumNotInt: function JSNumNotInt() {
    },
    JSString: function JSString() {
    }
  },
  A = {JS_CONST: function JS_CONST() {
    },
    LateError$fieldNI(fieldName) {
      return new A.LateError("Field '" + fieldName + "' has not been initialized.");
    },
    SystemHash_combine(hash, value) {
      hash = hash + value & 536870911;
      hash = hash + ((hash & 524287) << 10) & 536870911;
      return hash ^ hash >>> 6;
    },
    SystemHash_finish(hash) {
      hash = hash + ((hash & 67108863) << 3) & 536870911;
      hash ^= hash >>> 11;
      return hash + ((hash & 16383) << 15) & 536870911;
    },
    checkNotNullable(value, $name, $T) {
      return value;
    },
    isToStringVisiting(object) {
      var t1, i;
      for (t1 = $.toStringVisiting.length, i = 0; i < t1; ++i)
        if (object === $.toStringVisiting[i])
          return true;
      return false;
    },
    MappedIterable_MappedIterable(iterable, $function, $S, $T) {
      if (type$.EfficientLengthIterable_dynamic._is(iterable))
        return new A.EfficientLengthMappedIterable(iterable, $function, $S._eval$1("@<0>")._bind$1($T)._eval$1("EfficientLengthMappedIterable<1,2>"));
      return new A.MappedIterable(iterable, $function, $S._eval$1("@<0>")._bind$1($T)._eval$1("MappedIterable<1,2>"));
    },
    IterableElementError_noElement() {
      return new A.StateError("No element");
    },
    LateError: function LateError(t0) {
      this.__internal$_message = t0;
    },
    CodeUnits: function CodeUnits(t0) {
      this._string = t0;
    },
    SentinelValue: function SentinelValue() {
    },
    EfficientLengthIterable: function EfficientLengthIterable() {
    },
    ListIterable: function ListIterable() {
    },
    ListIterator: function ListIterator(t0, t1, t2) {
      var _ = this;
      _.__internal$_iterable = t0;
      _.__internal$_length = t1;
      _.__internal$_index = 0;
      _.__internal$_current = null;
      _.$ti = t2;
    },
    MappedIterable: function MappedIterable(t0, t1, t2) {
      this.__internal$_iterable = t0;
      this._f = t1;
      this.$ti = t2;
    },
    EfficientLengthMappedIterable: function EfficientLengthMappedIterable(t0, t1, t2) {
      this.__internal$_iterable = t0;
      this._f = t1;
      this.$ti = t2;
    },
    MappedIterator: function MappedIterator(t0, t1, t2) {
      var _ = this;
      _.__internal$_current = null;
      _._iterator = t0;
      _._f = t1;
      _.$ti = t2;
    },
    MappedListIterable: function MappedListIterable(t0, t1, t2) {
      this._source = t0;
      this._f = t1;
      this.$ti = t2;
    },
    FixedLengthListMixin: function FixedLengthListMixin() {
    },
    UnmodifiableListMixin: function UnmodifiableListMixin() {
    },
    UnmodifiableListBase: function UnmodifiableListBase() {
    },
    unminifyOrTag(rawClassName) {
      var preserved = init.mangledGlobalNames[rawClassName];
      if (preserved != null)
        return preserved;
      return rawClassName;
    },
    isJsIndexable(object, record) {
      var result;
      if (record != null) {
        result = record.x;
        if (result != null)
          return result;
      }
      return type$.JavaScriptIndexingBehavior_dynamic._is(object);
    },
    S(value) {
      var result;
      if (typeof value == "string")
        return value;
      if (typeof value == "number") {
        if (value !== 0)
          return "" + value;
      } else if (true === value)
        return "true";
      else if (false === value)
        return "false";
      else if (value == null)
        return "null";
      result = J.toString$0$(value);
      return result;
    },
    Primitives_objectHashCode(object) {
      var hash,
        property = $.Primitives__identityHashCodeProperty;
      if (property == null)
        property = $.Primitives__identityHashCodeProperty = Symbol("identityHashCode");
      hash = object[property];
      if (hash == null) {
        hash = Math.random() * 0x3fffffff | 0;
        object[property] = hash;
      }
      return hash;
    },
    Primitives_objectTypeName(object) {
      var interceptor, dispatchName, $constructor, constructorName;
      if (object instanceof A.Object)
        return A._rtiToString(A.instanceType(object), null);
      interceptor = J.getInterceptor$(object);
      if (interceptor === B.Interceptor_methods || interceptor === B.JavaScriptObject_methods || type$.UnknownJavaScriptObject._is(object)) {
        dispatchName = B.C_JS_CONST(object);
        if (dispatchName !== "Object" && dispatchName !== "")
          return dispatchName;
        $constructor = object.constructor;
        if (typeof $constructor == "function") {
          constructorName = $constructor.name;
          if (typeof constructorName == "string" && constructorName !== "Object" && constructorName !== "")
            return constructorName;
        }
      }
      return A._rtiToString(A.instanceType(object), null);
    },
    Primitives_safeToString(object) {
      var hooks, i, hookResult;
      if (typeof object == "number" || A._isBool(object))
        return J.toString$0$(object);
      if (typeof object == "string")
        return JSON.stringify(object);
      if (object instanceof A.Closure)
        return object.toString$0(0);
      hooks = $.$get$_safeToStringHooks();
      for (i = 0; i < 1; ++i) {
        hookResult = hooks[i].tryFormat$1(object);
        if (hookResult != null)
          return hookResult;
      }
      return "Instance of '" + A.Primitives_objectTypeName(object) + "'";
    },
    Primitives_lazyAsJsDate(receiver) {
      if (receiver.date === void 0)
        receiver.date = new Date(receiver._core$_value);
      return receiver.date;
    },
    Primitives_getYear(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCFullYear() + 0;
      return t1;
    },
    Primitives_getMonth(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCMonth() + 1;
      return t1;
    },
    Primitives_getDay(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCDate() + 0;
      return t1;
    },
    Primitives_getHours(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCHours() + 0;
      return t1;
    },
    Primitives_getMinutes(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCMinutes() + 0;
      return t1;
    },
    Primitives_getSeconds(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCSeconds() + 0;
      return t1;
    },
    Primitives_getMilliseconds(receiver) {
      var t1 = A.Primitives_lazyAsJsDate(receiver).getUTCMilliseconds() + 0;
      return t1;
    },
    Primitives_extractStackTrace(error) {
      var jsError = error.$thrownJsError;
      if (jsError == null)
        return null;
      return A.getTraceFromException(jsError);
    },
    Primitives_trySetStackTrace(error, stackTrace) {
      var jsError;
      if (error.$thrownJsError == null) {
        jsError = new Error();
        A.initializeExceptionWrapper(error, jsError);
        error.$thrownJsError = jsError;
        jsError.stack = stackTrace.toString$0(0);
      }
    },
    ioore(receiver, index) {
      if (receiver == null)
        J.get$length$asx(receiver);
      throw A.wrapException(A.diagnoseIndexError(receiver, index));
    },
    diagnoseIndexError(indexable, index) {
      var $length, _s5_ = "index";
      if (!A._isInt(index))
        return new A.ArgumentError(true, index, _s5_, null);
      $length = J.get$length$asx(indexable);
      if (index < 0 || index >= $length)
        return A.IndexError$withLength(index, $length, indexable, _s5_);
      return new A.RangeError(null, null, true, index, _s5_, "Value not in range");
    },
    argumentErrorValue(object) {
      return new A.ArgumentError(true, object, null, null);
    },
    wrapException(ex) {
      return A.initializeExceptionWrapper(ex, new Error());
    },
    initializeExceptionWrapper(ex, wrapper) {
      var t1;
      if (ex == null)
        ex = new A.TypeError();
      wrapper.dartException = ex;
      t1 = A.toStringWrapper;
      if ("defineProperty" in Object) {
        Object.defineProperty(wrapper, "message", {get: t1});
        wrapper.name = "";
      } else
        wrapper.toString = t1;
      return wrapper;
    },
    toStringWrapper() {
      return J.toString$0$(this.dartException);
    },
    throwExpression(ex, wrapper) {
      throw A.initializeExceptionWrapper(ex, wrapper == null ? new Error() : wrapper);
    },
    throwUnsupportedOperation(o, operation, verb) {
      var wrapper;
      if (operation == null)
        operation = 0;
      if (verb == null)
        verb = 0;
      wrapper = Error();
      A.throwExpression(A._diagnoseUnsupportedOperation(o, operation, verb), wrapper);
    },
    _diagnoseUnsupportedOperation(o, encodedOperation, encodedVerb) {
      var operation, table, tableLength, index, verb, object, flags, article, adjective;
      if (typeof encodedOperation == "string")
        operation = encodedOperation;
      else {
        table = "[]=;add;removeWhere;retainWhere;removeRange;setRange;setInt8;setInt16;setInt32;setUint8;setUint16;setUint32;setFloat32;setFloat64".split(";");
        tableLength = table.length;
        index = encodedOperation;
        if (index > tableLength) {
          encodedVerb = index / tableLength | 0;
          index %= tableLength;
        }
        operation = table[index];
      }
      verb = typeof encodedVerb == "string" ? encodedVerb : "modify;remove from;add to".split(";")[encodedVerb];
      object = type$.List_dynamic._is(o) ? "list" : "ByteData";
      flags = o.$flags | 0;
      article = "a ";
      if ((flags & 4) !== 0)
        adjective = "constant ";
      else if ((flags & 2) !== 0) {
        adjective = "unmodifiable ";
        article = "an ";
      } else
        adjective = (flags & 1) !== 0 ? "fixed-length " : "";
      return new A.UnsupportedError("'" + operation + "': Cannot " + verb + " " + article + adjective + object);
    },
    throwConcurrentModificationError(collection) {
      throw A.wrapException(A.ConcurrentModificationError$(collection));
    },
    TypeErrorDecoder_extractPattern(message) {
      var match, $arguments, argumentsExpr, expr, method, receiver;
      message = A.quoteStringForRegExp(message.replace(String({}), "$receiver$"));
      match = message.match(/\\\$[a-zA-Z]+\\\$/g);
      if (match == null)
        match = A._setArrayType([], type$.JSArray_String);
      $arguments = match.indexOf("\\$arguments\\$");
      argumentsExpr = match.indexOf("\\$argumentsExpr\\$");
      expr = match.indexOf("\\$expr\\$");
      method = match.indexOf("\\$method\\$");
      receiver = match.indexOf("\\$receiver\\$");
      return new A.TypeErrorDecoder(message.replace(new RegExp("\\\\\\$arguments\\\\\\$", "g"), "((?:x|[^x])*)").replace(new RegExp("\\\\\\$argumentsExpr\\\\\\$", "g"), "((?:x|[^x])*)").replace(new RegExp("\\\\\\$expr\\\\\\$", "g"), "((?:x|[^x])*)").replace(new RegExp("\\\\\\$method\\\\\\$", "g"), "((?:x|[^x])*)").replace(new RegExp("\\\\\\$receiver\\\\\\$", "g"), "((?:x|[^x])*)"), $arguments, argumentsExpr, expr, method, receiver);
    },
    TypeErrorDecoder_provokeCallErrorOn(expression) {
      return function($expr$) {
        var $argumentsExpr$ = "$arguments$";
        try {
          $expr$.$method$($argumentsExpr$);
        } catch (e) {
          return e.message;
        }
      }(expression);
    },
    TypeErrorDecoder_provokePropertyErrorOn(expression) {
      return function($expr$) {
        try {
          $expr$.$method$;
        } catch (e) {
          return e.message;
        }
      }(expression);
    },
    JsNoSuchMethodError$(_message, match) {
      var t1 = match == null,
        t2 = t1 ? null : match.method;
      return new A.JsNoSuchMethodError(_message, t2, t1 ? null : match.receiver);
    },
    unwrapException(ex) {
      var t1;
      if (ex == null)
        return new A.NullThrownFromJavaScriptException(ex);
      if (ex instanceof A.ExceptionAndStackTrace) {
        t1 = ex.dartException;
        return A.saveStackTrace(ex, t1 == null ? A._asObject(t1) : t1);
      }
      if (typeof ex !== "object")
        return ex;
      if ("dartException" in ex)
        return A.saveStackTrace(ex, ex.dartException);
      return A._unwrapNonDartException(ex);
    },
    saveStackTrace(ex, error) {
      if (type$.Error._is(error))
        if (error.$thrownJsError == null)
          error.$thrownJsError = ex;
      return error;
    },
    _unwrapNonDartException(ex) {
      var message, number, ieErrorCode, nsme, notClosure, nullCall, nullLiteralCall, undefCall, undefLiteralCall, nullProperty, undefProperty, undefLiteralProperty, match;
      if (!("message" in ex))
        return ex;
      message = ex.message;
      if ("number" in ex && typeof ex.number == "number") {
        number = ex.number;
        ieErrorCode = number & 65535;
        if ((B.JSInt_methods._shrOtherPositive$1(number, 16) & 8191) === 10)
          switch (ieErrorCode) {
            case 438:
              return A.saveStackTrace(ex, A.JsNoSuchMethodError$(A.S(message) + " (Error " + ieErrorCode + ")", null));
            case 445:
            case 5007:
              A.S(message);
              return A.saveStackTrace(ex, new A.NullError());
          }
      }
      if (ex instanceof TypeError) {
        nsme = $.$get$TypeErrorDecoder_noSuchMethodPattern();
        notClosure = $.$get$TypeErrorDecoder_notClosurePattern();
        nullCall = $.$get$TypeErrorDecoder_nullCallPattern();
        nullLiteralCall = $.$get$TypeErrorDecoder_nullLiteralCallPattern();
        undefCall = $.$get$TypeErrorDecoder_undefinedCallPattern();
        undefLiteralCall = $.$get$TypeErrorDecoder_undefinedLiteralCallPattern();
        nullProperty = $.$get$TypeErrorDecoder_nullPropertyPattern();
        $.$get$TypeErrorDecoder_nullLiteralPropertyPattern();
        undefProperty = $.$get$TypeErrorDecoder_undefinedPropertyPattern();
        undefLiteralProperty = $.$get$TypeErrorDecoder_undefinedLiteralPropertyPattern();
        match = nsme.matchTypeError$1(message);
        if (match != null)
          return A.saveStackTrace(ex, A.JsNoSuchMethodError$(A._asString(message), match));
        else {
          match = notClosure.matchTypeError$1(message);
          if (match != null) {
            match.method = "call";
            return A.saveStackTrace(ex, A.JsNoSuchMethodError$(A._asString(message), match));
          } else if (nullCall.matchTypeError$1(message) != null || nullLiteralCall.matchTypeError$1(message) != null || undefCall.matchTypeError$1(message) != null || undefLiteralCall.matchTypeError$1(message) != null || nullProperty.matchTypeError$1(message) != null || nullLiteralCall.matchTypeError$1(message) != null || undefProperty.matchTypeError$1(message) != null || undefLiteralProperty.matchTypeError$1(message) != null) {
            A._asString(message);
            return A.saveStackTrace(ex, new A.NullError());
          }
        }
        return A.saveStackTrace(ex, new A.UnknownJsTypeError(typeof message == "string" ? message : ""));
      }
      if (ex instanceof RangeError) {
        if (typeof message == "string" && message.indexOf("call stack") !== -1)
          return new A.StackOverflowError();
        message = function(ex) {
          try {
            return String(ex);
          } catch (e) {
          }
          return null;
        }(ex);
        return A.saveStackTrace(ex, new A.ArgumentError(false, null, null, typeof message == "string" ? message.replace(/^RangeError:\s*/, "") : message));
      }
      if (typeof InternalError == "function" && ex instanceof InternalError)
        if (typeof message == "string" && message === "too much recursion")
          return new A.StackOverflowError();
      return ex;
    },
    getTraceFromException(exception) {
      var trace;
      if (exception instanceof A.ExceptionAndStackTrace)
        return exception.stackTrace;
      if (exception == null)
        return new A._StackTrace(exception);
      trace = exception.$cachedTrace;
      if (trace != null)
        return trace;
      trace = new A._StackTrace(exception);
      if (typeof exception === "object")
        exception.$cachedTrace = trace;
      return trace;
    },
    objectHashCode(object) {
      if (object == null)
        return J.get$hashCode$(object);
      if (typeof object == "object")
        return A.Primitives_objectHashCode(object);
      return J.get$hashCode$(object);
    },
    constantHashCode(key) {
      if (typeof key == "number")
        return B.JSNumber_methods.get$hashCode(key);
      if (key instanceof A._Type)
        return A.Primitives_objectHashCode(key);
      return A.objectHashCode(key);
    },
    fillLiteralMap(keyValuePairs, result) {
      var index, index0, index1,
        $length = keyValuePairs.length;
      for (index = 0; index < $length; index = index1) {
        index0 = index + 1;
        index1 = index0 + 1;
        result.$indexSet(0, keyValuePairs[index], keyValuePairs[index0]);
      }
      return result;
    },
    _invokeClosure(closure, numberOfArguments, arg1, arg2, arg3, arg4) {
      type$.Function._as(closure);
      switch (A._asInt(numberOfArguments)) {
        case 0:
          return closure.call$0();
        case 1:
          return closure.call$1(arg1);
        case 2:
          return closure.call$2(arg1, arg2);
        case 3:
          return closure.call$3(arg1, arg2, arg3);
        case 4:
          return closure.call$4(arg1, arg2, arg3, arg4);
      }
      throw A.wrapException(A.Exception_Exception("Unsupported number of arguments for wrapped closure"));
    },
    convertDartClosureToJS(closure, arity) {
      var $function = closure.$identity;
      if (!!$function)
        return $function;
      $function = A.convertDartClosureToJSUncached(closure, arity);
      closure.$identity = $function;
      return $function;
    },
    convertDartClosureToJSUncached(closure, arity) {
      var entry;
      switch (arity) {
        case 0:
          entry = closure.call$0;
          break;
        case 1:
          entry = closure.call$1;
          break;
        case 2:
          entry = closure.call$2;
          break;
        case 3:
          entry = closure.call$3;
          break;
        case 4:
          entry = closure.call$4;
          break;
        default:
          entry = null;
      }
      if (entry != null)
        return entry.bind(closure);
      return function(closure, arity, invoke) {
        return function(a1, a2, a3, a4) {
          return invoke(closure, arity, a1, a2, a3, a4);
        };
      }(closure, arity, A._invokeClosure);
    },
    Closure_fromTearOff(parameters) {
      var $prototype, $constructor, t2, trampoline, applyTrampoline, i, stub, stub0, stubName, stubCallName,
        container = parameters.co,
        isStatic = parameters.iS,
        isIntercepted = parameters.iI,
        needsDirectAccess = parameters.nDA,
        applyTrampolineIndex = parameters.aI,
        funsOrNames = parameters.fs,
        callNames = parameters.cs,
        $name = funsOrNames[0],
        callName = callNames[0],
        $function = container[$name],
        t1 = parameters.fT;
      t1.toString;
      $prototype = isStatic ? Object.create(new A.StaticClosure().constructor.prototype) : Object.create(new A.BoundClosure(null, null).constructor.prototype);
      $prototype.$initialize = $prototype.constructor;
      $constructor = isStatic ? function static_tear_off() {
        this.$initialize();
      } : function tear_off(a, b) {
        this.$initialize(a, b);
      };
      $prototype.constructor = $constructor;
      $constructor.prototype = $prototype;
      $prototype.$_name = $name;
      $prototype.$_target = $function;
      t2 = !isStatic;
      if (t2)
        trampoline = A.Closure_forwardCallTo($name, $function, isIntercepted, needsDirectAccess);
      else {
        $prototype.$static_name = $name;
        trampoline = $function;
      }
      $prototype.$signature = A.Closure__computeSignatureFunction(t1, isStatic, isIntercepted);
      $prototype[callName] = trampoline;
      for (applyTrampoline = trampoline, i = 1; i < funsOrNames.length; ++i) {
        stub = funsOrNames[i];
        if (typeof stub == "string") {
          stub0 = container[stub];
          stubName = stub;
          stub = stub0;
        } else
          stubName = "";
        stubCallName = callNames[i];
        if (stubCallName != null) {
          if (t2)
            stub = A.Closure_forwardCallTo(stubName, stub, isIntercepted, needsDirectAccess);
          $prototype[stubCallName] = stub;
        }
        if (i === applyTrampolineIndex)
          applyTrampoline = stub;
      }
      $prototype["call*"] = applyTrampoline;
      $prototype.$requiredArgCount = parameters.rC;
      $prototype.$defaultValues = parameters.dV;
      return $constructor;
    },
    Closure__computeSignatureFunction(functionType, isStatic, isIntercepted) {
      if (typeof functionType == "number")
        return functionType;
      if (typeof functionType == "string") {
        if (isStatic)
          throw A.wrapException("Cannot compute signature for static tearoff.");
        return function(recipe, evalOnReceiver) {
          return function() {
            return evalOnReceiver(this, recipe);
          };
        }(functionType, A.BoundClosure_evalRecipe);
      }
      throw A.wrapException("Error in functionType of tearoff");
    },
    Closure_cspForwardCall(arity, needsDirectAccess, stubName, $function) {
      var getReceiver = A.BoundClosure_receiverOf;
      switch (needsDirectAccess ? -1 : arity) {
        case 0:
          return function(entry, receiverOf) {
            return function() {
              return receiverOf(this)[entry]();
            };
          }(stubName, getReceiver);
        case 1:
          return function(entry, receiverOf) {
            return function(a) {
              return receiverOf(this)[entry](a);
            };
          }(stubName, getReceiver);
        case 2:
          return function(entry, receiverOf) {
            return function(a, b) {
              return receiverOf(this)[entry](a, b);
            };
          }(stubName, getReceiver);
        case 3:
          return function(entry, receiverOf) {
            return function(a, b, c) {
              return receiverOf(this)[entry](a, b, c);
            };
          }(stubName, getReceiver);
        case 4:
          return function(entry, receiverOf) {
            return function(a, b, c, d) {
              return receiverOf(this)[entry](a, b, c, d);
            };
          }(stubName, getReceiver);
        case 5:
          return function(entry, receiverOf) {
            return function(a, b, c, d, e) {
              return receiverOf(this)[entry](a, b, c, d, e);
            };
          }(stubName, getReceiver);
        default:
          return function(f, receiverOf) {
            return function() {
              return f.apply(receiverOf(this), arguments);
            };
          }($function, getReceiver);
      }
    },
    Closure_forwardCallTo(stubName, $function, isIntercepted, needsDirectAccess) {
      if (isIntercepted)
        return A.Closure_forwardInterceptedCallTo(stubName, $function, needsDirectAccess);
      return A.Closure_cspForwardCall($function.length, needsDirectAccess, stubName, $function);
    },
    Closure_cspForwardInterceptedCall(arity, needsDirectAccess, stubName, $function) {
      var getReceiver = A.BoundClosure_receiverOf,
        getInterceptor = A.BoundClosure_interceptorOf;
      switch (needsDirectAccess ? -1 : arity) {
        case 0:
          throw A.wrapException(new A.RuntimeError("Intercepted function with no arguments."));
        case 1:
          return function(entry, interceptorOf, receiverOf) {
            return function() {
              return interceptorOf(this)[entry](receiverOf(this));
            };
          }(stubName, getInterceptor, getReceiver);
        case 2:
          return function(entry, interceptorOf, receiverOf) {
            return function(a) {
              return interceptorOf(this)[entry](receiverOf(this), a);
            };
          }(stubName, getInterceptor, getReceiver);
        case 3:
          return function(entry, interceptorOf, receiverOf) {
            return function(a, b) {
              return interceptorOf(this)[entry](receiverOf(this), a, b);
            };
          }(stubName, getInterceptor, getReceiver);
        case 4:
          return function(entry, interceptorOf, receiverOf) {
            return function(a, b, c) {
              return interceptorOf(this)[entry](receiverOf(this), a, b, c);
            };
          }(stubName, getInterceptor, getReceiver);
        case 5:
          return function(entry, interceptorOf, receiverOf) {
            return function(a, b, c, d) {
              return interceptorOf(this)[entry](receiverOf(this), a, b, c, d);
            };
          }(stubName, getInterceptor, getReceiver);
        case 6:
          return function(entry, interceptorOf, receiverOf) {
            return function(a, b, c, d, e) {
              return interceptorOf(this)[entry](receiverOf(this), a, b, c, d, e);
            };
          }(stubName, getInterceptor, getReceiver);
        default:
          return function(f, interceptorOf, receiverOf) {
            return function() {
              var a = [receiverOf(this)];
              Array.prototype.push.apply(a, arguments);
              return f.apply(interceptorOf(this), a);
            };
          }($function, getInterceptor, getReceiver);
      }
    },
    Closure_forwardInterceptedCallTo(stubName, $function, needsDirectAccess) {
      var arity, t1;
      if ($.BoundClosure__interceptorFieldNameCache == null)
        $.BoundClosure__interceptorFieldNameCache = A.BoundClosure__computeFieldNamed("interceptor");
      if ($.BoundClosure__receiverFieldNameCache == null)
        $.BoundClosure__receiverFieldNameCache = A.BoundClosure__computeFieldNamed("receiver");
      arity = $function.length;
      t1 = A.Closure_cspForwardInterceptedCall(arity, needsDirectAccess, stubName, $function);
      return t1;
    },
    closureFromTearOff(parameters) {
      return A.Closure_fromTearOff(parameters);
    },
    BoundClosure_evalRecipe(closure, recipe) {
      return A._Universe_evalInEnvironment(init.typeUniverse, A.instanceType(closure._receiver), recipe);
    },
    BoundClosure_receiverOf(closure) {
      return closure._receiver;
    },
    BoundClosure_interceptorOf(closure) {
      return closure._interceptor;
    },
    BoundClosure__computeFieldNamed(fieldName) {
      var names, i, $name,
        template = new A.BoundClosure("receiver", "interceptor"),
        t1 = Object.getOwnPropertyNames(template);
      t1.$flags = 1;
      names = t1;
      for (t1 = names.length, i = 0; i < t1; ++i) {
        $name = names[i];
        if (template[$name] === fieldName)
          return $name;
      }
      throw A.wrapException(A.ArgumentError$("Field name " + fieldName + " not found.", null));
    },
    getIsolateAffinityTag($name) {
      return init.getIsolateTag($name);
    },
    defineProperty(obj, property, value) {
      Object.defineProperty(obj, property, {value: value, enumerable: false, writable: true, configurable: true});
    },
    lookupAndCacheInterceptor(obj) {
      var interceptor, interceptorClass, altTag, mark, t1,
        tag = A._asString($.getTagFunction.call$1(obj)),
        record = $.dispatchRecordsForInstanceTags[tag];
      if (record != null) {
        Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
        return record.i;
      }
      interceptor = $.interceptorsForUncacheableTags[tag];
      if (interceptor != null)
        return interceptor;
      interceptorClass = init.interceptorsByTag[tag];
      if (interceptorClass == null) {
        altTag = A._asStringQ($.alternateTagFunction.call$2(obj, tag));
        if (altTag != null) {
          record = $.dispatchRecordsForInstanceTags[altTag];
          if (record != null) {
            Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
            return record.i;
          }
          interceptor = $.interceptorsForUncacheableTags[altTag];
          if (interceptor != null)
            return interceptor;
          interceptorClass = init.interceptorsByTag[altTag];
          tag = altTag;
        }
      }
      if (interceptorClass == null)
        return null;
      interceptor = interceptorClass.prototype;
      mark = tag[0];
      if (mark === "!") {
        record = A.makeLeafDispatchRecord(interceptor);
        $.dispatchRecordsForInstanceTags[tag] = record;
        Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
        return record.i;
      }
      if (mark === "~") {
        $.interceptorsForUncacheableTags[tag] = interceptor;
        return interceptor;
      }
      if (mark === "-") {
        t1 = A.makeLeafDispatchRecord(interceptor);
        Object.defineProperty(Object.getPrototypeOf(obj), init.dispatchPropertyName, {value: t1, enumerable: false, writable: true, configurable: true});
        return t1.i;
      }
      if (mark === "+")
        return A.patchInteriorProto(obj, interceptor);
      if (mark === "*")
        throw A.wrapException(A.UnimplementedError$(tag));
      if (init.leafTags[tag] === true) {
        t1 = A.makeLeafDispatchRecord(interceptor);
        Object.defineProperty(Object.getPrototypeOf(obj), init.dispatchPropertyName, {value: t1, enumerable: false, writable: true, configurable: true});
        return t1.i;
      } else
        return A.patchInteriorProto(obj, interceptor);
    },
    patchInteriorProto(obj, interceptor) {
      var proto = Object.getPrototypeOf(obj);
      Object.defineProperty(proto, init.dispatchPropertyName, {value: J.makeDispatchRecord(interceptor, proto, null, null), enumerable: false, writable: true, configurable: true});
      return interceptor;
    },
    makeLeafDispatchRecord(interceptor) {
      return J.makeDispatchRecord(interceptor, false, null, !!interceptor.$isJavaScriptIndexingBehavior);
    },
    makeDefaultDispatchRecord(tag, interceptorClass, proto) {
      var interceptor = interceptorClass.prototype;
      if (init.leafTags[tag] === true)
        return A.makeLeafDispatchRecord(interceptor);
      else
        return J.makeDispatchRecord(interceptor, proto, null, null);
    },
    initNativeDispatch() {
      if (true === $.initNativeDispatchFlag)
        return;
      $.initNativeDispatchFlag = true;
      A.initNativeDispatchContinue();
    },
    initNativeDispatchContinue() {
      var map, tags, fun, i, tag, proto, record, interceptorClass;
      $.dispatchRecordsForInstanceTags = Object.create(null);
      $.interceptorsForUncacheableTags = Object.create(null);
      A.initHooks();
      map = init.interceptorsByTag;
      tags = Object.getOwnPropertyNames(map);
      if (typeof window != "undefined") {
        window;
        fun = function() {
        };
        for (i = 0; i < tags.length; ++i) {
          tag = tags[i];
          proto = $.prototypeForTagFunction.call$1(tag);
          if (proto != null) {
            record = A.makeDefaultDispatchRecord(tag, map[tag], proto);
            if (record != null) {
              Object.defineProperty(proto, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
              fun.prototype = proto;
            }
          }
        }
      }
      for (i = 0; i < tags.length; ++i) {
        tag = tags[i];
        if (/^[A-Za-z_]/.test(tag)) {
          interceptorClass = map[tag];
          map["!" + tag] = interceptorClass;
          map["~" + tag] = interceptorClass;
          map["-" + tag] = interceptorClass;
          map["+" + tag] = interceptorClass;
          map["*" + tag] = interceptorClass;
        }
      }
    },
    initHooks() {
      var transformers, i, transformer, getTag, getUnknownTag, prototypeForTag,
        hooks = B.C_JS_CONST0();
      hooks = A.applyHooksTransformer(B.C_JS_CONST1, A.applyHooksTransformer(B.C_JS_CONST2, A.applyHooksTransformer(B.C_JS_CONST3, A.applyHooksTransformer(B.C_JS_CONST3, A.applyHooksTransformer(B.C_JS_CONST4, A.applyHooksTransformer(B.C_JS_CONST5, A.applyHooksTransformer(B.C_JS_CONST6(B.C_JS_CONST), hooks)))))));
      if (typeof dartNativeDispatchHooksTransformer != "undefined") {
        transformers = dartNativeDispatchHooksTransformer;
        if (typeof transformers == "function")
          transformers = [transformers];
        if (Array.isArray(transformers))
          for (i = 0; i < transformers.length; ++i) {
            transformer = transformers[i];
            if (typeof transformer == "function")
              hooks = transformer(hooks) || hooks;
          }
      }
      getTag = hooks.getTag;
      getUnknownTag = hooks.getUnknownTag;
      prototypeForTag = hooks.prototypeForTag;
      $.getTagFunction = new A.initHooks_closure(getTag);
      $.alternateTagFunction = new A.initHooks_closure0(getUnknownTag);
      $.prototypeForTagFunction = new A.initHooks_closure1(prototypeForTag);
    },
    applyHooksTransformer(transformer, hooks) {
      return transformer(hooks) || hooks;
    },
    createRecordTypePredicate(shape, fieldRtis) {
      var $length = fieldRtis.length,
        $function = init.rttc["" + $length + ";" + shape];
      if ($function == null)
        return null;
      if ($length === 0)
        return $function;
      if ($length === $function.length)
        return $function.apply(null, fieldRtis);
      return $function(fieldRtis);
    },
    quoteStringForRegExp(string) {
      if (/[[\]{}()*+?.\\^$|]/.test(string))
        return string.replace(/[[\]{}()*+?.\\^$|]/g, "\\$&");
      return string;
    },
    ConstantMap: function ConstantMap() {
    },
    ConstantMap_map_closure: function ConstantMap_map_closure(t0, t1, t2) {
      this.$this = t0;
      this.transform = t1;
      this.result = t2;
    },
    ConstantStringMap: function ConstantStringMap(t0, t1, t2) {
      this._jsIndex = t0;
      this._values = t1;
      this.$ti = t2;
    },
    _KeysOrValues: function _KeysOrValues(t0, t1) {
      this._elements = t0;
      this.$ti = t1;
    },
    _KeysOrValuesOrElementsIterator: function _KeysOrValuesOrElementsIterator(t0, t1, t2) {
      var _ = this;
      _._elements = t0;
      _.__js_helper$_length = t1;
      _.__js_helper$_index = 0;
      _.__js_helper$_current = null;
      _.$ti = t2;
    },
    GeneralConstantMap: function GeneralConstantMap(t0, t1) {
      this._jsData = t0;
      this.$ti = t1;
    },
    SafeToStringHook: function SafeToStringHook() {
    },
    TypeErrorDecoder: function TypeErrorDecoder(t0, t1, t2, t3, t4, t5) {
      var _ = this;
      _._pattern = t0;
      _._arguments = t1;
      _._argumentsExpr = t2;
      _._expr = t3;
      _._method = t4;
      _._receiver = t5;
    },
    NullError: function NullError() {
    },
    JsNoSuchMethodError: function JsNoSuchMethodError(t0, t1, t2) {
      this.__js_helper$_message = t0;
      this._method = t1;
      this._receiver = t2;
    },
    UnknownJsTypeError: function UnknownJsTypeError(t0) {
      this.__js_helper$_message = t0;
    },
    NullThrownFromJavaScriptException: function NullThrownFromJavaScriptException(t0) {
      this._irritant = t0;
    },
    ExceptionAndStackTrace: function ExceptionAndStackTrace(t0, t1) {
      this.dartException = t0;
      this.stackTrace = t1;
    },
    _StackTrace: function _StackTrace(t0) {
      this._exception = t0;
      this._trace = null;
    },
    Closure: function Closure() {
    },
    Closure0Args: function Closure0Args() {
    },
    Closure2Args: function Closure2Args() {
    },
    TearOffClosure: function TearOffClosure() {
    },
    StaticClosure: function StaticClosure() {
    },
    BoundClosure: function BoundClosure(t0, t1) {
      this._receiver = t0;
      this._interceptor = t1;
    },
    RuntimeError: function RuntimeError(t0) {
      this.message = t0;
    },
    JsLinkedHashMap: function JsLinkedHashMap(t0) {
      var _ = this;
      _.__js_helper$_length = 0;
      _._last = _._first = _.__js_helper$_rest = _.__js_helper$_nums = _.__js_helper$_strings = null;
      _._modifications = 0;
      _.$ti = t0;
    },
    LinkedHashMapCell: function LinkedHashMapCell(t0, t1) {
      var _ = this;
      _.hashMapCellKey = t0;
      _.hashMapCellValue = t1;
      _._previous = _._next = null;
    },
    LinkedHashMapKeysIterable: function LinkedHashMapKeysIterable(t0, t1) {
      this.__js_helper$_map = t0;
      this.$ti = t1;
    },
    LinkedHashMapKeyIterator: function LinkedHashMapKeyIterator(t0, t1, t2, t3) {
      var _ = this;
      _.__js_helper$_map = t0;
      _._modifications = t1;
      _._cell = t2;
      _.__js_helper$_current = null;
      _.$ti = t3;
    },
    LinkedHashMapValuesIterable: function LinkedHashMapValuesIterable(t0, t1) {
      this.__js_helper$_map = t0;
      this.$ti = t1;
    },
    LinkedHashMapValueIterator: function LinkedHashMapValueIterator(t0, t1, t2, t3) {
      var _ = this;
      _.__js_helper$_map = t0;
      _._modifications = t1;
      _._cell = t2;
      _.__js_helper$_current = null;
      _.$ti = t3;
    },
    JsConstantLinkedHashMap: function JsConstantLinkedHashMap(t0) {
      var _ = this;
      _.__js_helper$_length = 0;
      _._last = _._first = _.__js_helper$_rest = _.__js_helper$_nums = _.__js_helper$_strings = null;
      _._modifications = 0;
      _.$ti = t0;
    },
    initHooks_closure: function initHooks_closure(t0) {
      this.getTag = t0;
    },
    initHooks_closure0: function initHooks_closure0(t0) {
      this.getUnknownTag = t0;
    },
    initHooks_closure1: function initHooks_closure1(t0) {
      this.prototypeForTag = t0;
    },
    throwLateFieldNI(fieldName) {
      throw A.initializeExceptionWrapper(A.LateError$fieldNI(fieldName), new Error());
    },
    throwLateFieldADI(fieldName) {
      throw A.initializeExceptionWrapper(new A.LateError("Field '" + fieldName + "' has been assigned during initialization."), new Error());
    },
    _Cell$named(_name) {
      var t1 = new A._Cell(_name);
      return t1._value = t1;
    },
    _Cell: function _Cell(t0) {
      this.__late_helper$_name = t0;
      this._value = null;
    },
    _checkViewArguments(buffer, offsetInBytes, $length) {
    },
    _ensureNativeList(list) {
      return list;
    },
    NativeFloat32List_NativeFloat32List($length) {
      return new Float32Array($length);
    },
    NativeFloat32List_NativeFloat32List$view(buffer, offsetInBytes, $length) {
      A._checkViewArguments(buffer, offsetInBytes, $length);
      $length = B.JSInt_methods._tdivFast$1(buffer.byteLength - offsetInBytes, 4);
      return new Float32Array(buffer, offsetInBytes, $length);
    },
    NativeInt32List_NativeInt32List($length) {
      return new Int32Array($length);
    },
    NativeUint16List_NativeUint16List$view(buffer, offsetInBytes, $length) {
      A._checkViewArguments(buffer, offsetInBytes, $length);
      $length = B.JSInt_methods._tdivFast$1(buffer.byteLength - offsetInBytes, 2);
      return new Uint16Array(buffer, offsetInBytes, $length);
    },
    NativeUint32List_NativeUint32List$view(buffer, offsetInBytes, $length) {
      A._checkViewArguments(buffer, offsetInBytes, $length);
      $length = B.JSInt_methods._tdivFast$1(buffer.byteLength - offsetInBytes, 4);
      return new Uint32Array(buffer, offsetInBytes, $length);
    },
    NativeUint8List_NativeUint8List$view(buffer, offsetInBytes, $length) {
      A._checkViewArguments(buffer, offsetInBytes, $length);
      return $length == null ? new Uint8Array(buffer, offsetInBytes) : new Uint8Array(buffer, offsetInBytes, $length);
    },
    _checkValidIndex(index, list, $length) {
      if (index >>> 0 !== index || index >= $length)
        throw A.wrapException(A.diagnoseIndexError(list, index));
    },
    NativeByteBuffer: function NativeByteBuffer() {
    },
    NativeArrayBuffer: function NativeArrayBuffer() {
    },
    NativeTypedData: function NativeTypedData() {
    },
    _UnmodifiableNativeByteBufferView: function _UnmodifiableNativeByteBufferView(t0) {
      this._data = t0;
    },
    NativeByteData: function NativeByteData() {
    },
    NativeTypedArray: function NativeTypedArray() {
    },
    NativeTypedArrayOfDouble: function NativeTypedArrayOfDouble() {
    },
    NativeTypedArrayOfInt: function NativeTypedArrayOfInt() {
    },
    NativeFloat32List: function NativeFloat32List() {
    },
    NativeFloat64List: function NativeFloat64List() {
    },
    NativeInt16List: function NativeInt16List() {
    },
    NativeInt32List: function NativeInt32List() {
    },
    NativeInt8List: function NativeInt8List() {
    },
    NativeUint16List: function NativeUint16List() {
    },
    NativeUint32List: function NativeUint32List() {
    },
    NativeUint8ClampedList: function NativeUint8ClampedList() {
    },
    NativeUint8List: function NativeUint8List() {
    },
    _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin: function _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin() {
    },
    _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin: function _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin() {
    },
    _NativeTypedArrayOfInt_NativeTypedArray_ListMixin: function _NativeTypedArrayOfInt_NativeTypedArray_ListMixin() {
    },
    _NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin: function _NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin() {
    },
    Rti__getFutureFromFutureOr(universe, rti) {
      var future = rti._precomputed1;
      return future == null ? rti._precomputed1 = A._Universe__lookupInterfaceRti(universe, "Future", [rti._primary]) : future;
    },
    Rti__isUnionOfFunctionType(rti) {
      var kind = rti._kind;
      if (kind === 6 || kind === 7)
        return A.Rti__isUnionOfFunctionType(rti._primary);
      return kind === 11 || kind === 12;
    },
    Rti__getCanonicalRecipe(rti) {
      return rti._canonicalRecipe;
    },
    findType(recipe) {
      return A._Universe_eval(init.typeUniverse, recipe, false);
    },
    _substitute(universe, rti, typeArguments, depth) {
      var baseType, substitutedBaseType, interfaceTypeArguments, substitutedInterfaceTypeArguments, base, substitutedBase, $arguments, substitutedArguments, t1, fields, substitutedFields, returnType, substitutedReturnType, functionParameters, substitutedFunctionParameters, bounds, substitutedBounds, index, argument,
        kind = rti._kind;
      switch (kind) {
        case 5:
        case 1:
        case 2:
        case 3:
        case 4:
          return rti;
        case 6:
          baseType = rti._primary;
          substitutedBaseType = A._substitute(universe, baseType, typeArguments, depth);
          if (substitutedBaseType === baseType)
            return rti;
          return A._Universe__lookupQuestionRti(universe, substitutedBaseType, true);
        case 7:
          baseType = rti._primary;
          substitutedBaseType = A._substitute(universe, baseType, typeArguments, depth);
          if (substitutedBaseType === baseType)
            return rti;
          return A._Universe__lookupFutureOrRti(universe, substitutedBaseType, true);
        case 8:
          interfaceTypeArguments = rti._rest;
          substitutedInterfaceTypeArguments = A._substituteArray(universe, interfaceTypeArguments, typeArguments, depth);
          if (substitutedInterfaceTypeArguments === interfaceTypeArguments)
            return rti;
          return A._Universe__lookupInterfaceRti(universe, rti._primary, substitutedInterfaceTypeArguments);
        case 9:
          base = rti._primary;
          substitutedBase = A._substitute(universe, base, typeArguments, depth);
          $arguments = rti._rest;
          substitutedArguments = A._substituteArray(universe, $arguments, typeArguments, depth);
          if (substitutedBase === base && substitutedArguments === $arguments)
            return rti;
          return A._Universe__lookupBindingRti(universe, substitutedBase, substitutedArguments);
        case 10:
          t1 = rti._primary;
          fields = rti._rest;
          substitutedFields = A._substituteArray(universe, fields, typeArguments, depth);
          if (substitutedFields === fields)
            return rti;
          return A._Universe__lookupRecordRti(universe, t1, substitutedFields);
        case 11:
          returnType = rti._primary;
          substitutedReturnType = A._substitute(universe, returnType, typeArguments, depth);
          functionParameters = rti._rest;
          substitutedFunctionParameters = A._substituteFunctionParameters(universe, functionParameters, typeArguments, depth);
          if (substitutedReturnType === returnType && substitutedFunctionParameters === functionParameters)
            return rti;
          return A._Universe__lookupFunctionRti(universe, substitutedReturnType, substitutedFunctionParameters);
        case 12:
          bounds = rti._rest;
          depth += bounds.length;
          substitutedBounds = A._substituteArray(universe, bounds, typeArguments, depth);
          base = rti._primary;
          substitutedBase = A._substitute(universe, base, typeArguments, depth);
          if (substitutedBounds === bounds && substitutedBase === base)
            return rti;
          return A._Universe__lookupGenericFunctionRti(universe, substitutedBase, substitutedBounds, true);
        case 13:
          index = rti._primary;
          if (index < depth)
            return rti;
          argument = typeArguments[index - depth];
          if (argument == null)
            return rti;
          return argument;
        default:
          throw A.wrapException(A.AssertionError$("Attempted to substitute unexpected RTI kind " + kind));
      }
    },
    _substituteArray(universe, rtiArray, typeArguments, depth) {
      var changed, i, rti, substitutedRti,
        $length = rtiArray.length,
        result = A._Utils_newArrayOrEmpty($length);
      for (changed = false, i = 0; i < $length; ++i) {
        rti = rtiArray[i];
        substitutedRti = A._substitute(universe, rti, typeArguments, depth);
        if (substitutedRti !== rti)
          changed = true;
        result[i] = substitutedRti;
      }
      return changed ? result : rtiArray;
    },
    _substituteNamed(universe, namedArray, typeArguments, depth) {
      var changed, i, t1, t2, rti, substitutedRti,
        $length = namedArray.length,
        result = A._Utils_newArrayOrEmpty($length);
      for (changed = false, i = 0; i < $length; i += 3) {
        t1 = namedArray[i];
        t2 = namedArray[i + 1];
        rti = namedArray[i + 2];
        substitutedRti = A._substitute(universe, rti, typeArguments, depth);
        if (substitutedRti !== rti)
          changed = true;
        result.splice(i, 3, t1, t2, substitutedRti);
      }
      return changed ? result : namedArray;
    },
    _substituteFunctionParameters(universe, functionParameters, typeArguments, depth) {
      var result,
        requiredPositional = functionParameters._requiredPositional,
        substitutedRequiredPositional = A._substituteArray(universe, requiredPositional, typeArguments, depth),
        optionalPositional = functionParameters._optionalPositional,
        substitutedOptionalPositional = A._substituteArray(universe, optionalPositional, typeArguments, depth),
        named = functionParameters._named,
        substitutedNamed = A._substituteNamed(universe, named, typeArguments, depth);
      if (substitutedRequiredPositional === requiredPositional && substitutedOptionalPositional === optionalPositional && substitutedNamed === named)
        return functionParameters;
      result = new A._FunctionParameters();
      result._requiredPositional = substitutedRequiredPositional;
      result._optionalPositional = substitutedOptionalPositional;
      result._named = substitutedNamed;
      return result;
    },
    _setArrayType(target, rti) {
      target[init.arrayRti] = rti;
      return target;
    },
    closureFunctionType(closure) {
      var signature = closure.$signature;
      if (signature != null) {
        if (typeof signature == "number")
          return A.getTypeFromTypesTable(signature);
        return closure.$signature();
      }
      return null;
    },
    instanceOrFunctionType(object, testRti) {
      var rti;
      if (A.Rti__isUnionOfFunctionType(testRti))
        if (object instanceof A.Closure) {
          rti = A.closureFunctionType(object);
          if (rti != null)
            return rti;
        }
      return A.instanceType(object);
    },
    instanceType(object) {
      if (object instanceof A.Object)
        return A._instanceType(object);
      if (Array.isArray(object))
        return A._arrayInstanceType(object);
      return A._instanceTypeFromConstructor(J.getInterceptor$(object));
    },
    _arrayInstanceType(object) {
      var rti = object[init.arrayRti],
        defaultRti = type$.JSArray_dynamic;
      if (rti == null)
        return defaultRti;
      if (rti.constructor !== defaultRti.constructor)
        return defaultRti;
      return rti;
    },
    _instanceType(object) {
      var rti = object.$ti;
      return rti != null ? rti : A._instanceTypeFromConstructor(object);
    },
    _instanceTypeFromConstructor(instance) {
      var $constructor = instance.constructor,
        probe = $constructor.$ccache;
      if (probe != null)
        return probe;
      return A._instanceTypeFromConstructorMiss(instance, $constructor);
    },
    _instanceTypeFromConstructorMiss(instance, $constructor) {
      var effectiveConstructor = instance instanceof A.Closure ? Object.getPrototypeOf(Object.getPrototypeOf(instance)).constructor : $constructor,
        rti = A._Universe_findErasedType(init.typeUniverse, effectiveConstructor.name);
      $constructor.$ccache = rti;
      return rti;
    },
    getTypeFromTypesTable(index) {
      var rti,
        table = init.types,
        type = table[index];
      if (typeof type == "string") {
        rti = A._Universe_eval(init.typeUniverse, type, false);
        table[index] = rti;
        return rti;
      }
      return type;
    },
    getRuntimeTypeOfDartObject(object) {
      return A.createRuntimeType(A._instanceType(object));
    },
    _structuralTypeOf(object) {
      var functionRti = object instanceof A.Closure ? A.closureFunctionType(object) : null;
      if (functionRti != null)
        return functionRti;
      if (type$.TrustedGetRuntimeType._is(object))
        return J.get$runtimeType$(object)._rti;
      if (Array.isArray(object))
        return A._arrayInstanceType(object);
      return A.instanceType(object);
    },
    createRuntimeType(rti) {
      var t1 = rti._cachedRuntimeType;
      return t1 == null ? rti._cachedRuntimeType = new A._Type(rti) : t1;
    },
    typeLiteral(recipe) {
      return A.createRuntimeType(A._Universe_eval(init.typeUniverse, recipe, false));
    },
    _installSpecializedIsTest(object) {
      var testRti = this;
      testRti._is = A._specializedIsTest(testRti);
      return testRti._is(object);
    },
    _specializedIsTest(testRti) {
      var kind, simpleIsFn, $name, predicate, t1;
      if (testRti === type$.Object)
        return A._isObject;
      if (A.isTopType(testRti))
        return A._isTop;
      kind = testRti._kind;
      if (kind === 6)
        return A._generalNullableIsTestImplementation;
      if (kind === 1)
        return A._isNever;
      if (kind === 7)
        return A._isFutureOr;
      simpleIsFn = A._simpleSpecializedIsTest(testRti);
      if (simpleIsFn != null)
        return simpleIsFn;
      if (kind === 8) {
        $name = testRti._primary;
        if (testRti._rest.every(A.isTopType)) {
          testRti._specializedTestResource = "$is" + $name;
          if ($name === "List")
            return A._isListTestViaProperty;
          if (testRti === type$.JSObject)
            return A._isJSObject;
          return A._isTestViaProperty;
        }
      } else if (kind === 10) {
        predicate = A.createRecordTypePredicate(testRti._primary, testRti._rest);
        t1 = predicate == null ? A._isNever : predicate;
        return t1 == null ? A._asObject(t1) : t1;
      }
      return A._generalIsTestImplementation;
    },
    _simpleSpecializedIsTest(testRti) {
      if (testRti._kind === 8) {
        if (testRti === type$.int)
          return A._isInt;
        if (testRti === type$.double || testRti === type$.num)
          return A._isNum;
        if (testRti === type$.String)
          return A._isString;
        if (testRti === type$.bool)
          return A._isBool;
      }
      return null;
    },
    _installSpecializedAsCheck(object) {
      var testRti = this,
        asFn = A._generalAsCheckImplementation;
      if (A.isTopType(testRti))
        asFn = A._asTop;
      else if (testRti === type$.Object)
        asFn = A._asObject;
      else if (A.isNullable(testRti)) {
        asFn = A._generalNullableAsCheckImplementation;
        if (testRti === type$.nullable_int)
          asFn = A._asIntQ;
        else if (testRti === type$.nullable_String)
          asFn = A._asStringQ;
        else if (testRti === type$.nullable_bool)
          asFn = A._asBoolQ;
        else if (testRti === type$.nullable_num)
          asFn = A._asNumQ;
        else if (testRti === type$.nullable_double)
          asFn = A._asDoubleQ;
        else if (testRti === type$.nullable_JSObject)
          asFn = A._asJSObjectQ;
      } else if (testRti === type$.int)
        asFn = A._asInt;
      else if (testRti === type$.String)
        asFn = A._asString;
      else if (testRti === type$.bool)
        asFn = A._asBool;
      else if (testRti === type$.num)
        asFn = A._asNum;
      else if (testRti === type$.double)
        asFn = A._asDouble;
      else if (testRti === type$.JSObject)
        asFn = A._asJSObject;
      testRti._as = asFn;
      return testRti._as(object);
    },
    _generalIsTestImplementation(object) {
      var testRti = this;
      if (object == null)
        return A.isNullable(testRti);
      return A.isSubtype(init.typeUniverse, A.instanceOrFunctionType(object, testRti), testRti);
    },
    _generalNullableIsTestImplementation(object) {
      if (object == null)
        return true;
      return this._primary._is(object);
    },
    _isTestViaProperty(object) {
      var tag, testRti = this;
      if (object == null)
        return A.isNullable(testRti);
      tag = testRti._specializedTestResource;
      if (object instanceof A.Object)
        return !!object[tag];
      return !!J.getInterceptor$(object)[tag];
    },
    _isListTestViaProperty(object) {
      var tag, testRti = this;
      if (object == null)
        return A.isNullable(testRti);
      if (typeof object != "object")
        return false;
      if (Array.isArray(object))
        return true;
      tag = testRti._specializedTestResource;
      if (object instanceof A.Object)
        return !!object[tag];
      return !!J.getInterceptor$(object)[tag];
    },
    _isJSObject(object) {
      var t1 = this;
      if (object == null)
        return false;
      if (typeof object == "object") {
        if (object instanceof A.Object)
          return !!object[t1._specializedTestResource];
        return true;
      }
      if (typeof object == "function")
        return true;
      return false;
    },
    _isJSObjectStandalone(object) {
      if (typeof object == "object") {
        if (object instanceof A.Object)
          return type$.JSObject._is(object);
        return true;
      }
      if (typeof object == "function")
        return true;
      return false;
    },
    _generalAsCheckImplementation(object) {
      var testRti = this;
      if (object == null) {
        if (A.isNullable(testRti))
          return object;
      } else if (testRti._is(object))
        return object;
      throw A.initializeExceptionWrapper(A._errorForAsCheck(object, testRti), new Error());
    },
    _generalNullableAsCheckImplementation(object) {
      var testRti = this;
      if (object == null || testRti._is(object))
        return object;
      throw A.initializeExceptionWrapper(A._errorForAsCheck(object, testRti), new Error());
    },
    _errorForAsCheck(object, testRti) {
      return new A._TypeError("TypeError: " + A._Error_compose(object, A._rtiToString(testRti, null)));
    },
    _Error_compose(object, checkedTypeDescription) {
      return A.Error_safeToString(object) + ": type '" + A._rtiToString(A._structuralTypeOf(object), null) + "' is not a subtype of type '" + checkedTypeDescription + "'";
    },
    _TypeError__TypeError$forType(object, type) {
      return new A._TypeError("TypeError: " + A._Error_compose(object, type));
    },
    _isFutureOr(object) {
      var testRti = this;
      return testRti._primary._is(object) || A.Rti__getFutureFromFutureOr(init.typeUniverse, testRti)._is(object);
    },
    _isObject(object) {
      return object != null;
    },
    _asObject(object) {
      if (object != null)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "Object"), new Error());
    },
    _isTop(object) {
      return true;
    },
    _asTop(object) {
      return object;
    },
    _isNever(object) {
      return false;
    },
    _isBool(object) {
      return true === object || false === object;
    },
    _asBool(object) {
      if (true === object)
        return true;
      if (false === object)
        return false;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "bool"), new Error());
    },
    _asBoolQ(object) {
      if (true === object)
        return true;
      if (false === object)
        return false;
      if (object == null)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "bool?"), new Error());
    },
    _asDouble(object) {
      if (typeof object == "number")
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "double"), new Error());
    },
    _asDoubleQ(object) {
      if (typeof object == "number")
        return object;
      if (object == null)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "double?"), new Error());
    },
    _isInt(object) {
      return typeof object == "number" && Math.floor(object) === object;
    },
    _asInt(object) {
      if (typeof object == "number" && Math.floor(object) === object)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "int"), new Error());
    },
    _asIntQ(object) {
      if (typeof object == "number" && Math.floor(object) === object)
        return object;
      if (object == null)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "int?"), new Error());
    },
    _isNum(object) {
      return typeof object == "number";
    },
    _asNum(object) {
      if (typeof object == "number")
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "num"), new Error());
    },
    _asNumQ(object) {
      if (typeof object == "number")
        return object;
      if (object == null)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "num?"), new Error());
    },
    _isString(object) {
      return typeof object == "string";
    },
    _asString(object) {
      if (typeof object == "string")
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "String"), new Error());
    },
    _asStringQ(object) {
      if (typeof object == "string")
        return object;
      if (object == null)
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "String?"), new Error());
    },
    _asJSObject(object) {
      if (A._isJSObjectStandalone(object))
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "JSObject"), new Error());
    },
    _asJSObjectQ(object) {
      if (object == null)
        return object;
      if (A._isJSObjectStandalone(object))
        return object;
      throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "JSObject?"), new Error());
    },
    _rtiArrayToString(array, genericContext) {
      var s, sep, i;
      for (s = "", sep = "", i = 0; i < array.length; ++i, sep = ", ")
        s += sep + A._rtiToString(array[i], genericContext);
      return s;
    },
    _recordRtiToString(recordType, genericContext) {
      var fieldCount, names, namesIndex, s, comma, i,
        partialShape = recordType._primary,
        fields = recordType._rest;
      if ("" === partialShape)
        return "(" + A._rtiArrayToString(fields, genericContext) + ")";
      fieldCount = fields.length;
      names = partialShape.split(",");
      namesIndex = names.length - fieldCount;
      for (s = "(", comma = "", i = 0; i < fieldCount; ++i, comma = ", ") {
        s += comma;
        if (namesIndex === 0)
          s += "{";
        s += A._rtiToString(fields[i], genericContext);
        if (namesIndex >= 0)
          s += " " + names[namesIndex];
        ++namesIndex;
      }
      return s + "})";
    },
    _functionRtiToString(functionType, genericContext, bounds) {
      var boundsLength, offset, i, t1, typeParametersText, typeSep, t2, t3, boundRti, kind, parameters, requiredPositional, requiredPositionalLength, optionalPositional, optionalPositionalLength, named, namedLength, returnTypeText, argumentsText, sep, _s2_ = ", ", outerContextLength = null;
      if (bounds != null) {
        boundsLength = bounds.length;
        if (genericContext == null)
          genericContext = A._setArrayType([], type$.JSArray_String);
        else
          outerContextLength = genericContext.length;
        offset = genericContext.length;
        for (i = boundsLength; i > 0; --i)
          B.JSArray_methods.add$1(genericContext, "T" + (offset + i));
        for (t1 = type$.nullable_Object, typeParametersText = "<", typeSep = "", i = 0; i < boundsLength; ++i, typeSep = _s2_) {
          t2 = genericContext.length;
          t3 = t2 - 1 - i;
          if (!(t3 >= 0))
            return A.ioore(genericContext, t3);
          typeParametersText = typeParametersText + typeSep + genericContext[t3];
          boundRti = bounds[i];
          kind = boundRti._kind;
          if (!(kind === 2 || kind === 3 || kind === 4 || kind === 5 || boundRti === t1))
            typeParametersText += " extends " + A._rtiToString(boundRti, genericContext);
        }
        typeParametersText += ">";
      } else
        typeParametersText = "";
      t1 = functionType._primary;
      parameters = functionType._rest;
      requiredPositional = parameters._requiredPositional;
      requiredPositionalLength = requiredPositional.length;
      optionalPositional = parameters._optionalPositional;
      optionalPositionalLength = optionalPositional.length;
      named = parameters._named;
      namedLength = named.length;
      returnTypeText = A._rtiToString(t1, genericContext);
      for (argumentsText = "", sep = "", i = 0; i < requiredPositionalLength; ++i, sep = _s2_)
        argumentsText += sep + A._rtiToString(requiredPositional[i], genericContext);
      if (optionalPositionalLength > 0) {
        argumentsText += sep + "[";
        for (sep = "", i = 0; i < optionalPositionalLength; ++i, sep = _s2_)
          argumentsText += sep + A._rtiToString(optionalPositional[i], genericContext);
        argumentsText += "]";
      }
      if (namedLength > 0) {
        argumentsText += sep + "{";
        for (sep = "", i = 0; i < namedLength; i += 3, sep = _s2_) {
          argumentsText += sep;
          if (named[i + 1])
            argumentsText += "required ";
          argumentsText += A._rtiToString(named[i + 2], genericContext) + " " + named[i];
        }
        argumentsText += "}";
      }
      if (outerContextLength != null) {
        genericContext.toString;
        genericContext.length = outerContextLength;
      }
      return typeParametersText + "(" + argumentsText + ") => " + returnTypeText;
    },
    _rtiToString(rti, genericContext) {
      var questionArgument, s, argumentKind, $name, $arguments, t1, t2,
        kind = rti._kind;
      if (kind === 5)
        return "erased";
      if (kind === 2)
        return "dynamic";
      if (kind === 3)
        return "void";
      if (kind === 1)
        return "Never";
      if (kind === 4)
        return "any";
      if (kind === 6) {
        questionArgument = rti._primary;
        s = A._rtiToString(questionArgument, genericContext);
        argumentKind = questionArgument._kind;
        return (argumentKind === 11 || argumentKind === 12 ? "(" + s + ")" : s) + "?";
      }
      if (kind === 7)
        return "FutureOr<" + A._rtiToString(rti._primary, genericContext) + ">";
      if (kind === 8) {
        $name = A._unminifyOrTag(rti._primary);
        $arguments = rti._rest;
        return $arguments.length > 0 ? $name + ("<" + A._rtiArrayToString($arguments, genericContext) + ">") : $name;
      }
      if (kind === 10)
        return A._recordRtiToString(rti, genericContext);
      if (kind === 11)
        return A._functionRtiToString(rti, genericContext, null);
      if (kind === 12)
        return A._functionRtiToString(rti._primary, genericContext, rti._rest);
      if (kind === 13) {
        t1 = rti._primary;
        t2 = genericContext.length;
        t1 = t2 - 1 - t1;
        if (!(t1 >= 0 && t1 < t2))
          return A.ioore(genericContext, t1);
        return genericContext[t1];
      }
      return "?";
    },
    _unminifyOrTag(rawClassName) {
      var preserved = init.mangledGlobalNames[rawClassName];
      if (preserved != null)
        return preserved;
      return rawClassName;
    },
    _Universe_findRule(universe, targetType) {
      var rule = universe.tR[targetType];
      while (typeof rule == "string")
        rule = universe.tR[rule];
      return rule;
    },
    _Universe_findErasedType(universe, cls) {
      var $length, erased, $arguments, i, $interface,
        metadata = universe.eT,
        probe = metadata[cls];
      if (probe == null)
        return A._Universe_eval(universe, cls, false);
      else if (typeof probe == "number") {
        $length = probe;
        erased = A._Universe__lookupTerminalRti(universe, 5, "#");
        $arguments = A._Utils_newArrayOrEmpty($length);
        for (i = 0; i < $length; ++i)
          $arguments[i] = erased;
        $interface = A._Universe__lookupInterfaceRti(universe, cls, $arguments);
        metadata[cls] = $interface;
        return $interface;
      } else
        return probe;
    },
    _Universe_addRules(universe, rules) {
      return A._Utils_objectAssign(universe.tR, rules);
    },
    _Universe_addErasedTypes(universe, types) {
      return A._Utils_objectAssign(universe.eT, types);
    },
    _Universe_eval(universe, recipe, normalize) {
      var rti,
        cache = universe.eC,
        probe = cache.get(recipe);
      if (probe != null)
        return probe;
      rti = A._Parser_parse(A._Parser_create(universe, null, recipe, false));
      cache.set(recipe, rti);
      return rti;
    },
    _Universe_evalInEnvironment(universe, environment, recipe) {
      var probe, rti,
        cache = environment._evalCache;
      if (cache == null)
        cache = environment._evalCache = new Map();
      probe = cache.get(recipe);
      if (probe != null)
        return probe;
      rti = A._Parser_parse(A._Parser_create(universe, environment, recipe, true));
      cache.set(recipe, rti);
      return rti;
    },
    _Universe_bind(universe, environment, argumentsRti) {
      var argumentsRecipe, probe, rti,
        cache = environment._bindCache;
      if (cache == null)
        cache = environment._bindCache = new Map();
      argumentsRecipe = argumentsRti._canonicalRecipe;
      probe = cache.get(argumentsRecipe);
      if (probe != null)
        return probe;
      rti = A._Universe__lookupBindingRti(universe, environment, argumentsRti._kind === 9 ? argumentsRti._rest : [argumentsRti]);
      cache.set(argumentsRecipe, rti);
      return rti;
    },
    _Universe__installTypeTests(universe, rti) {
      rti._as = A._installSpecializedAsCheck;
      rti._is = A._installSpecializedIsTest;
      return rti;
    },
    _Universe__lookupTerminalRti(universe, kind, key) {
      var rti, t1,
        probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      rti = new A.Rti(null, null);
      rti._kind = kind;
      rti._canonicalRecipe = key;
      t1 = A._Universe__installTypeTests(universe, rti);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__lookupQuestionRti(universe, baseType, normalize) {
      var t1,
        key = baseType._canonicalRecipe + "?",
        probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      t1 = A._Universe__createQuestionRti(universe, baseType, key, normalize);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__createQuestionRti(universe, baseType, key, normalize) {
      var baseKind, t1, rti;
      if (normalize) {
        baseKind = baseType._kind;
        t1 = true;
        if (!A.isTopType(baseType))
          if (!(baseType === type$.Null || baseType === type$.JSNull))
            if (baseKind !== 6)
              t1 = baseKind === 7 && A.isNullable(baseType._primary);
        if (t1)
          return baseType;
        else if (baseKind === 1)
          return type$.Null;
      }
      rti = new A.Rti(null, null);
      rti._kind = 6;
      rti._primary = baseType;
      rti._canonicalRecipe = key;
      return A._Universe__installTypeTests(universe, rti);
    },
    _Universe__lookupFutureOrRti(universe, baseType, normalize) {
      var t1,
        key = baseType._canonicalRecipe + "/",
        probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      t1 = A._Universe__createFutureOrRti(universe, baseType, key, normalize);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__createFutureOrRti(universe, baseType, key, normalize) {
      var t1, rti;
      if (normalize) {
        t1 = baseType._kind;
        if (A.isTopType(baseType) || baseType === type$.Object)
          return baseType;
        else if (t1 === 1)
          return A._Universe__lookupInterfaceRti(universe, "Future", [baseType]);
        else if (baseType === type$.Null || baseType === type$.JSNull)
          return type$.nullable_Future_Null;
      }
      rti = new A.Rti(null, null);
      rti._kind = 7;
      rti._primary = baseType;
      rti._canonicalRecipe = key;
      return A._Universe__installTypeTests(universe, rti);
    },
    _Universe__lookupGenericFunctionParameterRti(universe, index) {
      var rti, t1,
        key = "" + index + "^",
        probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      rti = new A.Rti(null, null);
      rti._kind = 13;
      rti._primary = index;
      rti._canonicalRecipe = key;
      t1 = A._Universe__installTypeTests(universe, rti);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__canonicalRecipeJoin($arguments) {
      var s, sep, i,
        $length = $arguments.length;
      for (s = "", sep = "", i = 0; i < $length; ++i, sep = ",")
        s += sep + $arguments[i]._canonicalRecipe;
      return s;
    },
    _Universe__canonicalRecipeJoinNamed($arguments) {
      var s, sep, i, t1, nameSep,
        $length = $arguments.length;
      for (s = "", sep = "", i = 0; i < $length; i += 3, sep = ",") {
        t1 = $arguments[i];
        nameSep = $arguments[i + 1] ? "!" : ":";
        s += sep + t1 + nameSep + $arguments[i + 2]._canonicalRecipe;
      }
      return s;
    },
    _Universe__lookupInterfaceRti(universe, $name, $arguments) {
      var probe, rti, t1,
        s = $name;
      if ($arguments.length > 0)
        s += "<" + A._Universe__canonicalRecipeJoin($arguments) + ">";
      probe = universe.eC.get(s);
      if (probe != null)
        return probe;
      rti = new A.Rti(null, null);
      rti._kind = 8;
      rti._primary = $name;
      rti._rest = $arguments;
      if ($arguments.length > 0)
        rti._precomputed1 = $arguments[0];
      rti._canonicalRecipe = s;
      t1 = A._Universe__installTypeTests(universe, rti);
      universe.eC.set(s, t1);
      return t1;
    },
    _Universe__lookupBindingRti(universe, base, $arguments) {
      var newBase, newArguments, key, probe, rti, t1;
      if (base._kind === 9) {
        newBase = base._primary;
        newArguments = base._rest.concat($arguments);
      } else {
        newArguments = $arguments;
        newBase = base;
      }
      key = newBase._canonicalRecipe + (";<" + A._Universe__canonicalRecipeJoin(newArguments) + ">");
      probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      rti = new A.Rti(null, null);
      rti._kind = 9;
      rti._primary = newBase;
      rti._rest = newArguments;
      rti._canonicalRecipe = key;
      t1 = A._Universe__installTypeTests(universe, rti);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__lookupRecordRti(universe, partialShapeTag, fields) {
      var rti, t1,
        key = "+" + (partialShapeTag + "(" + A._Universe__canonicalRecipeJoin(fields) + ")"),
        probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      rti = new A.Rti(null, null);
      rti._kind = 10;
      rti._primary = partialShapeTag;
      rti._rest = fields;
      rti._canonicalRecipe = key;
      t1 = A._Universe__installTypeTests(universe, rti);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__lookupFunctionRti(universe, returnType, parameters) {
      var sep, key, probe, rti, t1,
        s = returnType._canonicalRecipe,
        requiredPositional = parameters._requiredPositional,
        requiredPositionalLength = requiredPositional.length,
        optionalPositional = parameters._optionalPositional,
        optionalPositionalLength = optionalPositional.length,
        named = parameters._named,
        namedLength = named.length,
        recipe = "(" + A._Universe__canonicalRecipeJoin(requiredPositional);
      if (optionalPositionalLength > 0) {
        sep = requiredPositionalLength > 0 ? "," : "";
        recipe += sep + "[" + A._Universe__canonicalRecipeJoin(optionalPositional) + "]";
      }
      if (namedLength > 0) {
        sep = requiredPositionalLength > 0 ? "," : "";
        recipe += sep + "{" + A._Universe__canonicalRecipeJoinNamed(named) + "}";
      }
      key = s + (recipe + ")");
      probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      rti = new A.Rti(null, null);
      rti._kind = 11;
      rti._primary = returnType;
      rti._rest = parameters;
      rti._canonicalRecipe = key;
      t1 = A._Universe__installTypeTests(universe, rti);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__lookupGenericFunctionRti(universe, baseFunctionType, bounds, normalize) {
      var t1,
        key = baseFunctionType._canonicalRecipe + ("<" + A._Universe__canonicalRecipeJoin(bounds) + ">"),
        probe = universe.eC.get(key);
      if (probe != null)
        return probe;
      t1 = A._Universe__createGenericFunctionRti(universe, baseFunctionType, bounds, key, normalize);
      universe.eC.set(key, t1);
      return t1;
    },
    _Universe__createGenericFunctionRti(universe, baseFunctionType, bounds, key, normalize) {
      var $length, typeArguments, count, i, bound, substitutedBase, substitutedBounds, rti;
      if (normalize) {
        $length = bounds.length;
        typeArguments = A._Utils_newArrayOrEmpty($length);
        for (count = 0, i = 0; i < $length; ++i) {
          bound = bounds[i];
          if (bound._kind === 1) {
            typeArguments[i] = bound;
            ++count;
          }
        }
        if (count > 0) {
          substitutedBase = A._substitute(universe, baseFunctionType, typeArguments, 0);
          substitutedBounds = A._substituteArray(universe, bounds, typeArguments, 0);
          return A._Universe__lookupGenericFunctionRti(universe, substitutedBase, substitutedBounds, bounds !== substitutedBounds);
        }
      }
      rti = new A.Rti(null, null);
      rti._kind = 12;
      rti._primary = baseFunctionType;
      rti._rest = bounds;
      rti._canonicalRecipe = key;
      return A._Universe__installTypeTests(universe, rti);
    },
    _Parser_create(universe, environment, recipe, normalize) {
      return {u: universe, e: environment, r: recipe, s: [], p: 0, n: normalize};
    },
    _Parser_parse(parser) {
      var t1, i, ch, u, array, end, item,
        source = parser.r,
        stack = parser.s;
      for (t1 = source.length, i = 0; i < t1;) {
        ch = source.charCodeAt(i);
        if (ch >= 48 && ch <= 57)
          i = A._Parser_handleDigit(i + 1, ch, source, stack);
        else if ((((ch | 32) >>> 0) - 97 & 65535) < 26 || ch === 95 || ch === 36 || ch === 124)
          i = A._Parser_handleIdentifier(parser, i, source, stack, false);
        else if (ch === 46)
          i = A._Parser_handleIdentifier(parser, i, source, stack, true);
        else {
          ++i;
          switch (ch) {
            case 44:
              break;
            case 58:
              stack.push(false);
              break;
            case 33:
              stack.push(true);
              break;
            case 59:
              stack.push(A._Parser_toType(parser.u, parser.e, stack.pop()));
              break;
            case 94:
              stack.push(A._Universe__lookupGenericFunctionParameterRti(parser.u, stack.pop()));
              break;
            case 35:
              stack.push(A._Universe__lookupTerminalRti(parser.u, 5, "#"));
              break;
            case 64:
              stack.push(A._Universe__lookupTerminalRti(parser.u, 2, "@"));
              break;
            case 126:
              stack.push(A._Universe__lookupTerminalRti(parser.u, 3, "~"));
              break;
            case 60:
              stack.push(parser.p);
              parser.p = stack.length;
              break;
            case 62:
              A._Parser_handleTypeArguments(parser, stack);
              break;
            case 38:
              A._Parser_handleExtendedOperations(parser, stack);
              break;
            case 63:
              u = parser.u;
              stack.push(A._Universe__lookupQuestionRti(u, A._Parser_toType(u, parser.e, stack.pop()), parser.n));
              break;
            case 47:
              u = parser.u;
              stack.push(A._Universe__lookupFutureOrRti(u, A._Parser_toType(u, parser.e, stack.pop()), parser.n));
              break;
            case 40:
              stack.push(-3);
              stack.push(parser.p);
              parser.p = stack.length;
              break;
            case 41:
              A._Parser_handleArguments(parser, stack);
              break;
            case 91:
              stack.push(parser.p);
              parser.p = stack.length;
              break;
            case 93:
              array = stack.splice(parser.p);
              A._Parser_toTypes(parser.u, parser.e, array);
              parser.p = stack.pop();
              stack.push(array);
              stack.push(-1);
              break;
            case 123:
              stack.push(parser.p);
              parser.p = stack.length;
              break;
            case 125:
              array = stack.splice(parser.p);
              A._Parser_toTypesNamed(parser.u, parser.e, array);
              parser.p = stack.pop();
              stack.push(array);
              stack.push(-2);
              break;
            case 43:
              end = source.indexOf("(", i);
              stack.push(source.substring(i, end));
              stack.push(-4);
              stack.push(parser.p);
              parser.p = stack.length;
              i = end + 1;
              break;
            default:
              throw "Bad character " + ch;
          }
        }
      }
      item = stack.pop();
      return A._Parser_toType(parser.u, parser.e, item);
    },
    _Parser_handleDigit(i, digit, source, stack) {
      var t1, ch,
        value = digit - 48;
      for (t1 = source.length; i < t1; ++i) {
        ch = source.charCodeAt(i);
        if (!(ch >= 48 && ch <= 57))
          break;
        value = value * 10 + (ch - 48);
      }
      stack.push(value);
      return i;
    },
    _Parser_handleIdentifier(parser, start, source, stack, hasPeriod) {
      var t1, ch, t2, string, environment, recipe,
        i = start + 1;
      for (t1 = source.length; i < t1; ++i) {
        ch = source.charCodeAt(i);
        if (ch === 46) {
          if (hasPeriod)
            break;
          hasPeriod = true;
        } else {
          if (!((((ch | 32) >>> 0) - 97 & 65535) < 26 || ch === 95 || ch === 36 || ch === 124))
            t2 = ch >= 48 && ch <= 57;
          else
            t2 = true;
          if (!t2)
            break;
        }
      }
      string = source.substring(start, i);
      if (hasPeriod) {
        t1 = parser.u;
        environment = parser.e;
        if (environment._kind === 9)
          environment = environment._primary;
        recipe = A._Universe_findRule(t1, environment._primary)[string];
        if (recipe == null)
          A.throwExpression('No "' + string + '" in "' + A.Rti__getCanonicalRecipe(environment) + '"');
        stack.push(A._Universe_evalInEnvironment(t1, environment, recipe));
      } else
        stack.push(string);
      return i;
    },
    _Parser_handleTypeArguments(parser, stack) {
      var base,
        universe = parser.u,
        $arguments = A._Parser_collectArray(parser, stack),
        head = stack.pop();
      if (typeof head == "string")
        stack.push(A._Universe__lookupInterfaceRti(universe, head, $arguments));
      else {
        base = A._Parser_toType(universe, parser.e, head);
        switch (base._kind) {
          case 11:
            stack.push(A._Universe__lookupGenericFunctionRti(universe, base, $arguments, parser.n));
            break;
          default:
            stack.push(A._Universe__lookupBindingRti(universe, base, $arguments));
            break;
        }
      }
    },
    _Parser_handleArguments(parser, stack) {
      var requiredPositional, returnType, parameters,
        universe = parser.u,
        head = stack.pop(),
        optionalPositional = null, named = null;
      if (typeof head == "number")
        switch (head) {
          case -1:
            optionalPositional = stack.pop();
            break;
          case -2:
            named = stack.pop();
            break;
          default:
            stack.push(head);
            break;
        }
      else
        stack.push(head);
      requiredPositional = A._Parser_collectArray(parser, stack);
      head = stack.pop();
      switch (head) {
        case -3:
          head = stack.pop();
          if (optionalPositional == null)
            optionalPositional = universe.sEA;
          if (named == null)
            named = universe.sEA;
          returnType = A._Parser_toType(universe, parser.e, head);
          parameters = new A._FunctionParameters();
          parameters._requiredPositional = requiredPositional;
          parameters._optionalPositional = optionalPositional;
          parameters._named = named;
          stack.push(A._Universe__lookupFunctionRti(universe, returnType, parameters));
          return;
        case -4:
          stack.push(A._Universe__lookupRecordRti(universe, stack.pop(), requiredPositional));
          return;
        default:
          throw A.wrapException(A.AssertionError$("Unexpected state under `()`: " + A.S(head)));
      }
    },
    _Parser_handleExtendedOperations(parser, stack) {
      var $top = stack.pop();
      if (0 === $top) {
        stack.push(A._Universe__lookupTerminalRti(parser.u, 1, "0&"));
        return;
      }
      if (1 === $top) {
        stack.push(A._Universe__lookupTerminalRti(parser.u, 4, "1&"));
        return;
      }
      throw A.wrapException(A.AssertionError$("Unexpected extended operation " + A.S($top)));
    },
    _Parser_collectArray(parser, stack) {
      var array = stack.splice(parser.p);
      A._Parser_toTypes(parser.u, parser.e, array);
      parser.p = stack.pop();
      return array;
    },
    _Parser_toType(universe, environment, item) {
      if (typeof item == "string")
        return A._Universe__lookupInterfaceRti(universe, item, universe.sEA);
      else if (typeof item == "number") {
        environment.toString;
        return A._Parser_indexToType(universe, environment, item);
      } else
        return item;
    },
    _Parser_toTypes(universe, environment, items) {
      var i,
        $length = items.length;
      for (i = 0; i < $length; ++i)
        items[i] = A._Parser_toType(universe, environment, items[i]);
    },
    _Parser_toTypesNamed(universe, environment, items) {
      var i,
        $length = items.length;
      for (i = 2; i < $length; i += 3)
        items[i] = A._Parser_toType(universe, environment, items[i]);
    },
    _Parser_indexToType(universe, environment, index) {
      var typeArguments, len,
        kind = environment._kind;
      if (kind === 9) {
        if (index === 0)
          return environment._primary;
        typeArguments = environment._rest;
        len = typeArguments.length;
        if (index <= len)
          return typeArguments[index - 1];
        index -= len;
        environment = environment._primary;
        kind = environment._kind;
      } else if (index === 0)
        return environment;
      if (kind !== 8)
        throw A.wrapException(A.AssertionError$("Indexed base must be an interface type"));
      typeArguments = environment._rest;
      if (index <= typeArguments.length)
        return typeArguments[index - 1];
      throw A.wrapException(A.AssertionError$("Bad index " + index + " for " + environment.toString$0(0)));
    },
    isSubtype(universe, s, t) {
      var result,
        sCache = s._isSubtypeCache;
      if (sCache == null)
        sCache = s._isSubtypeCache = new Map();
      result = sCache.get(t);
      if (result == null) {
        result = A._isSubtype(universe, s, null, t, null);
        sCache.set(t, result);
      }
      return result;
    },
    _isSubtype(universe, s, sEnv, t, tEnv) {
      var sKind, leftTypeVariable, tKind, t1, t2, sBounds, tBounds, sLength, i, sBound, tBound;
      if (s === t)
        return true;
      if (A.isTopType(t))
        return true;
      sKind = s._kind;
      if (sKind === 4)
        return true;
      if (A.isTopType(s))
        return false;
      if (s._kind === 1)
        return true;
      leftTypeVariable = sKind === 13;
      if (leftTypeVariable)
        if (A._isSubtype(universe, sEnv[s._primary], sEnv, t, tEnv))
          return true;
      tKind = t._kind;
      t1 = type$.Null;
      if (s === t1 || s === type$.JSNull) {
        if (tKind === 7)
          return A._isSubtype(universe, s, sEnv, t._primary, tEnv);
        return t === t1 || t === type$.JSNull || tKind === 6;
      }
      if (t === type$.Object) {
        if (sKind === 7)
          return A._isSubtype(universe, s._primary, sEnv, t, tEnv);
        return sKind !== 6;
      }
      if (sKind === 7) {
        if (!A._isSubtype(universe, s._primary, sEnv, t, tEnv))
          return false;
        return A._isSubtype(universe, A.Rti__getFutureFromFutureOr(universe, s), sEnv, t, tEnv);
      }
      if (sKind === 6)
        return A._isSubtype(universe, t1, sEnv, t, tEnv) && A._isSubtype(universe, s._primary, sEnv, t, tEnv);
      if (tKind === 7) {
        if (A._isSubtype(universe, s, sEnv, t._primary, tEnv))
          return true;
        return A._isSubtype(universe, s, sEnv, A.Rti__getFutureFromFutureOr(universe, t), tEnv);
      }
      if (tKind === 6)
        return A._isSubtype(universe, s, sEnv, t1, tEnv) || A._isSubtype(universe, s, sEnv, t._primary, tEnv);
      if (leftTypeVariable)
        return false;
      t1 = sKind !== 11;
      if ((!t1 || sKind === 12) && t === type$.Function)
        return true;
      t2 = sKind === 10;
      if (t2 && t === type$.Record)
        return true;
      if (tKind === 12) {
        if (s === type$.JavaScriptFunction)
          return true;
        if (sKind !== 12)
          return false;
        sBounds = s._rest;
        tBounds = t._rest;
        sLength = sBounds.length;
        if (sLength !== tBounds.length)
          return false;
        sEnv = sEnv == null ? sBounds : sBounds.concat(sEnv);
        tEnv = tEnv == null ? tBounds : tBounds.concat(tEnv);
        for (i = 0; i < sLength; ++i) {
          sBound = sBounds[i];
          tBound = tBounds[i];
          if (!A._isSubtype(universe, sBound, sEnv, tBound, tEnv) || !A._isSubtype(universe, tBound, tEnv, sBound, sEnv))
            return false;
        }
        return A._isFunctionSubtype(universe, s._primary, sEnv, t._primary, tEnv);
      }
      if (tKind === 11) {
        if (s === type$.JavaScriptFunction)
          return true;
        if (t1)
          return false;
        return A._isFunctionSubtype(universe, s, sEnv, t, tEnv);
      }
      if (sKind === 8) {
        if (tKind !== 8)
          return false;
        return A._isInterfaceSubtype(universe, s, sEnv, t, tEnv);
      }
      if (t2 && tKind === 10)
        return A._isRecordSubtype(universe, s, sEnv, t, tEnv);
      return false;
    },
    _isFunctionSubtype(universe, s, sEnv, t, tEnv) {
      var sParameters, tParameters, sRequiredPositional, tRequiredPositional, sRequiredPositionalLength, tRequiredPositionalLength, requiredPositionalDelta, sOptionalPositional, tOptionalPositional, sOptionalPositionalLength, tOptionalPositionalLength, i, t1, sNamed, tNamed, sNamedLength, tNamedLength, sIndex, tIndex, tName, sName, sIsRequired;
      if (!A._isSubtype(universe, s._primary, sEnv, t._primary, tEnv))
        return false;
      sParameters = s._rest;
      tParameters = t._rest;
      sRequiredPositional = sParameters._requiredPositional;
      tRequiredPositional = tParameters._requiredPositional;
      sRequiredPositionalLength = sRequiredPositional.length;
      tRequiredPositionalLength = tRequiredPositional.length;
      if (sRequiredPositionalLength > tRequiredPositionalLength)
        return false;
      requiredPositionalDelta = tRequiredPositionalLength - sRequiredPositionalLength;
      sOptionalPositional = sParameters._optionalPositional;
      tOptionalPositional = tParameters._optionalPositional;
      sOptionalPositionalLength = sOptionalPositional.length;
      tOptionalPositionalLength = tOptionalPositional.length;
      if (sRequiredPositionalLength + sOptionalPositionalLength < tRequiredPositionalLength + tOptionalPositionalLength)
        return false;
      for (i = 0; i < sRequiredPositionalLength; ++i) {
        t1 = sRequiredPositional[i];
        if (!A._isSubtype(universe, tRequiredPositional[i], tEnv, t1, sEnv))
          return false;
      }
      for (i = 0; i < requiredPositionalDelta; ++i) {
        t1 = sOptionalPositional[i];
        if (!A._isSubtype(universe, tRequiredPositional[sRequiredPositionalLength + i], tEnv, t1, sEnv))
          return false;
      }
      for (i = 0; i < tOptionalPositionalLength; ++i) {
        t1 = sOptionalPositional[requiredPositionalDelta + i];
        if (!A._isSubtype(universe, tOptionalPositional[i], tEnv, t1, sEnv))
          return false;
      }
      sNamed = sParameters._named;
      tNamed = tParameters._named;
      sNamedLength = sNamed.length;
      tNamedLength = tNamed.length;
      for (sIndex = 0, tIndex = 0; tIndex < tNamedLength; tIndex += 3) {
        tName = tNamed[tIndex];
        for (;;) {
          if (sIndex >= sNamedLength)
            return false;
          sName = sNamed[sIndex];
          sIndex += 3;
          if (tName < sName)
            return false;
          sIsRequired = sNamed[sIndex - 2];
          if (sName < tName) {
            if (sIsRequired)
              return false;
            continue;
          }
          t1 = tNamed[tIndex + 1];
          if (sIsRequired && !t1)
            return false;
          t1 = sNamed[sIndex - 1];
          if (!A._isSubtype(universe, tNamed[tIndex + 2], tEnv, t1, sEnv))
            return false;
          break;
        }
      }
      while (sIndex < sNamedLength) {
        if (sNamed[sIndex + 1])
          return false;
        sIndex += 3;
      }
      return true;
    },
    _isInterfaceSubtype(universe, s, sEnv, t, tEnv) {
      var rule, recipes, $length, supertypeArgs, i,
        sName = s._primary,
        tName = t._primary;
      while (sName !== tName) {
        rule = universe.tR[sName];
        if (rule == null)
          return false;
        if (typeof rule == "string") {
          sName = rule;
          continue;
        }
        recipes = rule[tName];
        if (recipes == null)
          return false;
        $length = recipes.length;
        supertypeArgs = $length > 0 ? new Array($length) : init.typeUniverse.sEA;
        for (i = 0; i < $length; ++i)
          supertypeArgs[i] = A._Universe_evalInEnvironment(universe, s, recipes[i]);
        return A._areArgumentsSubtypes(universe, supertypeArgs, null, sEnv, t._rest, tEnv);
      }
      return A._areArgumentsSubtypes(universe, s._rest, null, sEnv, t._rest, tEnv);
    },
    _areArgumentsSubtypes(universe, sArgs, sVariances, sEnv, tArgs, tEnv) {
      var i,
        $length = sArgs.length;
      for (i = 0; i < $length; ++i)
        if (!A._isSubtype(universe, sArgs[i], sEnv, tArgs[i], tEnv))
          return false;
      return true;
    },
    _isRecordSubtype(universe, s, sEnv, t, tEnv) {
      var i,
        sFields = s._rest,
        tFields = t._rest,
        sCount = sFields.length;
      if (sCount !== tFields.length)
        return false;
      if (s._primary !== t._primary)
        return false;
      for (i = 0; i < sCount; ++i)
        if (!A._isSubtype(universe, sFields[i], sEnv, tFields[i], tEnv))
          return false;
      return true;
    },
    isNullable(t) {
      var kind = t._kind,
        t1 = true;
      if (!(t === type$.Null || t === type$.JSNull))
        if (!A.isTopType(t))
          if (kind !== 6)
            t1 = kind === 7 && A.isNullable(t._primary);
      return t1;
    },
    isTopType(t) {
      var kind = t._kind;
      return kind === 2 || kind === 3 || kind === 4 || kind === 5 || t === type$.nullable_Object;
    },
    _Utils_objectAssign(o, other) {
      var i, key,
        keys = Object.keys(other),
        $length = keys.length;
      for (i = 0; i < $length; ++i) {
        key = keys[i];
        o[key] = other[key];
      }
    },
    _Utils_newArrayOrEmpty($length) {
      return $length > 0 ? new Array($length) : init.typeUniverse.sEA;
    },
    Rti: function Rti(t0, t1) {
      var _ = this;
      _._as = t0;
      _._is = t1;
      _._cachedRuntimeType = _._specializedTestResource = _._isSubtypeCache = _._precomputed1 = null;
      _._kind = 0;
      _._canonicalRecipe = _._bindCache = _._evalCache = _._rest = _._primary = null;
    },
    _FunctionParameters: function _FunctionParameters() {
      this._named = this._optionalPositional = this._requiredPositional = null;
    },
    _Type: function _Type(t0) {
      this._rti = t0;
    },
    _Error: function _Error() {
    },
    _TypeError: function _TypeError(t0) {
      this._message = t0;
    },
    _AsyncRun__initializeScheduleImmediate() {
      var t1, div, span;
      if (self.scheduleImmediate != null)
        return A.async__AsyncRun__scheduleImmediateJsOverride$closure();
      if (self.MutationObserver != null && self.document != null) {
        t1 = {};
        div = self.document.createElement("div");
        span = self.document.createElement("span");
        t1.storedCallback = null;
        new self.MutationObserver(A.convertDartClosureToJS(new A._AsyncRun__initializeScheduleImmediate_internalCallback(t1), 1)).observe(div, {childList: true});
        return new A._AsyncRun__initializeScheduleImmediate_closure(t1, div, span);
      } else if (self.setImmediate != null)
        return A.async__AsyncRun__scheduleImmediateWithSetImmediate$closure();
      return A.async__AsyncRun__scheduleImmediateWithTimer$closure();
    },
    _AsyncRun__scheduleImmediateJsOverride(callback) {
      self.scheduleImmediate(A.convertDartClosureToJS(new A._AsyncRun__scheduleImmediateJsOverride_internalCallback(type$.void_Function._as(callback)), 0));
    },
    _AsyncRun__scheduleImmediateWithSetImmediate(callback) {
      self.setImmediate(A.convertDartClosureToJS(new A._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback(type$.void_Function._as(callback)), 0));
    },
    _AsyncRun__scheduleImmediateWithTimer(callback) {
      A.Timer__createTimer(B.Duration_0, type$.void_Function._as(callback));
    },
    Timer__createTimer(duration, callback) {
      return A._TimerImpl$(duration._duration / 1000 | 0, callback);
    },
    _TimerImpl$(milliseconds, callback) {
      var t1 = new A._TimerImpl();
      t1._TimerImpl$2(milliseconds, callback);
      return t1;
    },
    _makeAsyncAwaitCompleter($T) {
      return new A._AsyncAwaitCompleter(new A._Future($.Zone__current, $T._eval$1("_Future<0>")), $T._eval$1("_AsyncAwaitCompleter<0>"));
    },
    _asyncStartSync(bodyFunction, completer) {
      bodyFunction.call$2(0, null);
      completer.isSync = true;
      return completer._future;
    },
    _asyncAwait(object, bodyFunction) {
      A._awaitOnObject(object, bodyFunction);
    },
    _asyncReturn(object, completer) {
      completer.complete$1(object);
    },
    _asyncRethrow(object, completer) {
      completer.completeError$2(A.unwrapException(object), A.getTraceFromException(object));
    },
    _awaitOnObject(object, bodyFunction) {
      var t1, future,
        thenCallback = new A._awaitOnObject_closure(bodyFunction),
        errorCallback = new A._awaitOnObject_closure0(bodyFunction);
      if (object instanceof A._Future)
        object._thenAwait$1$2(thenCallback, errorCallback, type$.dynamic);
      else {
        t1 = type$.dynamic;
        if (object instanceof A._Future)
          object.then$1$2$onError(thenCallback, errorCallback, t1);
        else {
          future = new A._Future($.Zone__current, type$._Future_dynamic);
          future._state = 8;
          future._resultOrListeners = object;
          future._thenAwait$1$2(thenCallback, errorCallback, t1);
        }
      }
    },
    _wrapJsFunctionForAsync($function) {
      var $protected = function(fn, ERROR) {
        return function(errorCode, result) {
          while (true) {
            try {
              fn(errorCode, result);
              break;
            } catch (error) {
              result = error;
              errorCode = ERROR;
            }
          }
        };
      }($function, 1);
      return $.Zone__current.registerBinaryCallback$3$1(new A._wrapJsFunctionForAsync_closure($protected), type$.void, type$.int, type$.dynamic);
    },
    AsyncError_defaultStackTrace(error) {
      var stackTrace;
      if (type$.Error._is(error)) {
        stackTrace = error.get$stackTrace();
        if (stackTrace != null)
          return stackTrace;
      }
      return B.C__StringStackTrace;
    },
    Future_Future$delayed(duration, $T) {
      var result;
      if (!$T._is(null))
        throw A.wrapException(A.ArgumentError$value(null, "computation", "The type parameter is not nullable"));
      result = new A._Future($.Zone__current, $T._eval$1("_Future<0>"));
      A.Timer_Timer(duration, new A.Future_Future$delayed_closure(null, result, $T));
      return result;
    },
    _interceptError(error, stackTrace) {
      if ($.Zone__current === B.C__RootZone)
        return null;
      return null;
    },
    _interceptUserError(error, stackTrace) {
      if ($.Zone__current !== B.C__RootZone)
        A._interceptError(error, stackTrace);
      if (stackTrace == null)
        if (type$.Error._is(error)) {
          stackTrace = error.get$stackTrace();
          if (stackTrace == null) {
            A.Primitives_trySetStackTrace(error, B.C__StringStackTrace);
            stackTrace = B.C__StringStackTrace;
          }
        } else
          stackTrace = B.C__StringStackTrace;
      else if (type$.Error._is(error))
        A.Primitives_trySetStackTrace(error, stackTrace);
      return new A.AsyncError(error, stackTrace);
    },
    _Future__chainCoreFuture(source, target, sync) {
      var t2, t3, ignoreError, listeners, _box_0 = {},
        t1 = _box_0.source = source;
      for (t2 = type$._Future_dynamic; t3 = t1._state, (t3 & 4) !== 0; t1 = source) {
        source = t2._as(t1._resultOrListeners);
        _box_0.source = source;
      }
      if (t1 === target) {
        t2 = A.StackTrace_current();
        target._asyncCompleteErrorObject$1(new A.AsyncError(new A.ArgumentError(true, t1, null, "Cannot complete a future with itself"), t2));
        return;
      }
      ignoreError = target._state & 1;
      t2 = t1._state = t3 | ignoreError;
      if ((t2 & 24) === 0) {
        listeners = type$.nullable__FutureListener_dynamic_dynamic._as(target._resultOrListeners);
        target._state = target._state & 1 | 4;
        target._resultOrListeners = t1;
        t1._prependListeners$1(listeners);
        return;
      }
      if (!sync)
        if (target._resultOrListeners == null)
          t1 = (t2 & 16) === 0 || ignoreError !== 0;
        else
          t1 = false;
      else
        t1 = true;
      if (t1) {
        listeners = target._removeListeners$0();
        target._cloneResult$1(_box_0.source);
        A._Future__propagateToListeners(target, listeners);
        return;
      }
      target._state ^= 2;
      A._rootScheduleMicrotask(null, null, target._zone, type$.void_Function._as(new A._Future__chainCoreFuture_closure(_box_0, target)));
    },
    _Future__propagateToListeners(source, listeners) {
      var t2, t3, _box_0, t4, t5, hasError, asyncError, nextListener, nextListener0, sourceResult, t6, zone, oldZone, result, current, _box_1 = {},
        t1 = _box_1.source = source;
      for (t2 = type$.AsyncError, t3 = type$.nullable__FutureListener_dynamic_dynamic;;) {
        _box_0 = {};
        t4 = t1._state;
        t5 = (t4 & 16) === 0;
        hasError = !t5;
        if (listeners == null) {
          if (hasError && (t4 & 1) === 0) {
            asyncError = t2._as(t1._resultOrListeners);
            A._rootHandleError(asyncError.error, asyncError.stackTrace);
          }
          return;
        }
        _box_0.listener = listeners;
        nextListener = listeners._nextListener;
        for (t1 = listeners; nextListener != null; t1 = nextListener, nextListener = nextListener0) {
          t1._nextListener = null;
          A._Future__propagateToListeners(_box_1.source, t1);
          _box_0.listener = nextListener;
          nextListener0 = nextListener._nextListener;
        }
        t4 = _box_1.source;
        sourceResult = t4._resultOrListeners;
        _box_0.listenerHasError = hasError;
        _box_0.listenerValueOrError = sourceResult;
        if (t5) {
          t6 = t1.state;
          t6 = (t6 & 1) !== 0 || (t6 & 15) === 8;
        } else
          t6 = true;
        if (t6) {
          zone = t1.result._zone;
          if (hasError) {
            t4 = t4._zone === zone;
            t4 = !(t4 || t4);
          } else
            t4 = false;
          if (t4) {
            t2._as(sourceResult);
            A._rootHandleError(sourceResult.error, sourceResult.stackTrace);
            return;
          }
          oldZone = $.Zone__current;
          if (oldZone !== zone)
            $.Zone__current = zone;
          else
            oldZone = null;
          t1 = t1.state;
          if ((t1 & 15) === 8)
            new A._Future__propagateToListeners_handleWhenCompleteCallback(_box_0, _box_1, hasError).call$0();
          else if (t5) {
            if ((t1 & 1) !== 0)
              new A._Future__propagateToListeners_handleValueCallback(_box_0, sourceResult).call$0();
          } else if ((t1 & 2) !== 0)
            new A._Future__propagateToListeners_handleError(_box_1, _box_0).call$0();
          if (oldZone != null)
            $.Zone__current = oldZone;
          t1 = _box_0.listenerValueOrError;
          if (t1 instanceof A._Future) {
            t4 = _box_0.listener.$ti;
            t4 = t4._eval$1("Future<2>")._is(t1) || !t4._rest[1]._is(t1);
          } else
            t4 = false;
          if (t4) {
            result = _box_0.listener.result;
            if ((t1._state & 24) !== 0) {
              current = t3._as(result._resultOrListeners);
              result._resultOrListeners = null;
              listeners = result._reverseListeners$1(current);
              result._state = t1._state & 30 | result._state & 1;
              result._resultOrListeners = t1._resultOrListeners;
              _box_1.source = t1;
              continue;
            } else
              A._Future__chainCoreFuture(t1, result, true);
            return;
          }
        }
        result = _box_0.listener.result;
        current = t3._as(result._resultOrListeners);
        result._resultOrListeners = null;
        listeners = result._reverseListeners$1(current);
        t1 = _box_0.listenerHasError;
        t4 = _box_0.listenerValueOrError;
        if (!t1) {
          result.$ti._precomputed1._as(t4);
          result._state = 8;
          result._resultOrListeners = t4;
        } else {
          t2._as(t4);
          result._state = result._state & 1 | 16;
          result._resultOrListeners = t4;
        }
        _box_1.source = result;
        t1 = result;
      }
    },
    _registerErrorHandler(errorHandler, zone) {
      var t1;
      if (type$.dynamic_Function_Object_StackTrace._is(errorHandler))
        return zone.registerBinaryCallback$3$1(errorHandler, type$.dynamic, type$.Object, type$.StackTrace);
      t1 = type$.dynamic_Function_Object;
      if (t1._is(errorHandler))
        return t1._as(errorHandler);
      throw A.wrapException(A.ArgumentError$value(errorHandler, "onError", string$.Error_));
    },
    _microtaskLoop() {
      var entry, next;
      for (entry = $._nextCallback; entry != null; entry = $._nextCallback) {
        $._lastPriorityCallback = null;
        next = entry.next;
        $._nextCallback = next;
        if (next == null)
          $._lastCallback = null;
        entry.callback.call$0();
      }
    },
    _startMicrotaskLoop() {
      $._isInCallbackLoop = true;
      try {
        A._microtaskLoop();
      } finally {
        $._lastPriorityCallback = null;
        $._isInCallbackLoop = false;
        if ($._nextCallback != null)
          $.$get$_AsyncRun__scheduleImmediateClosure().call$1(A.async___startMicrotaskLoop$closure());
      }
    },
    _scheduleAsyncCallback(callback) {
      var newEntry = new A._AsyncCallbackEntry(callback),
        lastCallback = $._lastCallback;
      if (lastCallback == null) {
        $._nextCallback = $._lastCallback = newEntry;
        if (!$._isInCallbackLoop)
          $.$get$_AsyncRun__scheduleImmediateClosure().call$1(A.async___startMicrotaskLoop$closure());
      } else
        $._lastCallback = lastCallback.next = newEntry;
    },
    _schedulePriorityAsyncCallback(callback) {
      var entry, lastPriorityCallback, next,
        t1 = $._nextCallback;
      if (t1 == null) {
        A._scheduleAsyncCallback(callback);
        $._lastPriorityCallback = $._lastCallback;
        return;
      }
      entry = new A._AsyncCallbackEntry(callback);
      lastPriorityCallback = $._lastPriorityCallback;
      if (lastPriorityCallback == null) {
        entry.next = t1;
        $._nextCallback = $._lastPriorityCallback = entry;
      } else {
        next = lastPriorityCallback.next;
        entry.next = next;
        $._lastPriorityCallback = lastPriorityCallback.next = entry;
        if (next == null)
          $._lastCallback = entry;
      }
    },
    StreamIterator_StreamIterator(stream, $T) {
      A.checkNotNullable(stream, "stream", type$.Object);
      return new A._StreamIterator($T._eval$1("_StreamIterator<0>"));
    },
    Timer_Timer(duration, callback) {
      var t1 = $.Zone__current;
      if (t1 === B.C__RootZone)
        return A.Timer__createTimer(duration, type$.void_Function._as(callback));
      return A.Timer__createTimer(duration, type$.void_Function._as(t1.bindCallbackGuarded$1(callback)));
    },
    _rootHandleError(error, stackTrace) {
      A._schedulePriorityAsyncCallback(new A._rootHandleError_closure(error, stackTrace));
    },
    _rootRun($self, $parent, zone, f, $R) {
      var old,
        t1 = $.Zone__current;
      if (t1 === zone)
        return f.call$0();
      $.Zone__current = zone;
      old = t1;
      try {
        t1 = f.call$0();
        return t1;
      } finally {
        $.Zone__current = old;
      }
    },
    _rootRunUnary($self, $parent, zone, f, arg, $R, $T) {
      var old,
        t1 = $.Zone__current;
      if (t1 === zone)
        return f.call$1(arg);
      $.Zone__current = zone;
      old = t1;
      try {
        t1 = f.call$1(arg);
        return t1;
      } finally {
        $.Zone__current = old;
      }
    },
    _rootRunBinary($self, $parent, zone, f, arg1, arg2, $R, $T1, $T2) {
      var old,
        t1 = $.Zone__current;
      if (t1 === zone)
        return f.call$2(arg1, arg2);
      $.Zone__current = zone;
      old = t1;
      try {
        t1 = f.call$2(arg1, arg2);
        return t1;
      } finally {
        $.Zone__current = old;
      }
    },
    _rootScheduleMicrotask($self, $parent, zone, f) {
      type$.void_Function._as(f);
      if (B.C__RootZone !== zone) {
        f = zone.bindCallbackGuarded$1(f);
        f = f;
      }
      A._scheduleAsyncCallback(f);
    },
    _AsyncRun__initializeScheduleImmediate_internalCallback: function _AsyncRun__initializeScheduleImmediate_internalCallback(t0) {
      this._box_0 = t0;
    },
    _AsyncRun__initializeScheduleImmediate_closure: function _AsyncRun__initializeScheduleImmediate_closure(t0, t1, t2) {
      this._box_0 = t0;
      this.div = t1;
      this.span = t2;
    },
    _AsyncRun__scheduleImmediateJsOverride_internalCallback: function _AsyncRun__scheduleImmediateJsOverride_internalCallback(t0) {
      this.callback = t0;
    },
    _AsyncRun__scheduleImmediateWithSetImmediate_internalCallback: function _AsyncRun__scheduleImmediateWithSetImmediate_internalCallback(t0) {
      this.callback = t0;
    },
    _TimerImpl: function _TimerImpl() {
    },
    _TimerImpl_internalCallback: function _TimerImpl_internalCallback(t0, t1) {
      this.$this = t0;
      this.callback = t1;
    },
    _AsyncAwaitCompleter: function _AsyncAwaitCompleter(t0, t1) {
      this._future = t0;
      this.isSync = false;
      this.$ti = t1;
    },
    _awaitOnObject_closure: function _awaitOnObject_closure(t0) {
      this.bodyFunction = t0;
    },
    _awaitOnObject_closure0: function _awaitOnObject_closure0(t0) {
      this.bodyFunction = t0;
    },
    _wrapJsFunctionForAsync_closure: function _wrapJsFunctionForAsync_closure(t0) {
      this.$protected = t0;
    },
    AsyncError: function AsyncError(t0, t1) {
      this.error = t0;
      this.stackTrace = t1;
    },
    Future_Future$delayed_closure: function Future_Future$delayed_closure(t0, t1, t2) {
      this.computation = t0;
      this.result = t1;
      this.T = t2;
    },
    _Completer: function _Completer() {
    },
    _AsyncCompleter: function _AsyncCompleter(t0, t1) {
      this.future = t0;
      this.$ti = t1;
    },
    _FutureListener: function _FutureListener(t0, t1, t2, t3, t4) {
      var _ = this;
      _._nextListener = null;
      _.result = t0;
      _.state = t1;
      _.callback = t2;
      _.errorCallback = t3;
      _.$ti = t4;
    },
    _Future: function _Future(t0, t1) {
      var _ = this;
      _._state = 0;
      _._zone = t0;
      _._resultOrListeners = null;
      _.$ti = t1;
    },
    _Future__addListener_closure: function _Future__addListener_closure(t0, t1) {
      this.$this = t0;
      this.listener = t1;
    },
    _Future__prependListeners_closure: function _Future__prependListeners_closure(t0, t1) {
      this._box_0 = t0;
      this.$this = t1;
    },
    _Future__chainCoreFuture_closure: function _Future__chainCoreFuture_closure(t0, t1) {
      this._box_0 = t0;
      this.target = t1;
    },
    _Future__asyncCompleteWithValue_closure: function _Future__asyncCompleteWithValue_closure(t0, t1) {
      this.$this = t0;
      this.value = t1;
    },
    _Future__asyncCompleteErrorObject_closure: function _Future__asyncCompleteErrorObject_closure(t0, t1) {
      this.$this = t0;
      this.error = t1;
    },
    _Future__propagateToListeners_handleWhenCompleteCallback: function _Future__propagateToListeners_handleWhenCompleteCallback(t0, t1, t2) {
      this._box_0 = t0;
      this._box_1 = t1;
      this.hasError = t2;
    },
    _Future__propagateToListeners_handleWhenCompleteCallback_closure: function _Future__propagateToListeners_handleWhenCompleteCallback_closure(t0, t1) {
      this.joinedResult = t0;
      this.originalSource = t1;
    },
    _Future__propagateToListeners_handleWhenCompleteCallback_closure0: function _Future__propagateToListeners_handleWhenCompleteCallback_closure0(t0) {
      this.joinedResult = t0;
    },
    _Future__propagateToListeners_handleValueCallback: function _Future__propagateToListeners_handleValueCallback(t0, t1) {
      this._box_0 = t0;
      this.sourceResult = t1;
    },
    _Future__propagateToListeners_handleError: function _Future__propagateToListeners_handleError(t0, t1) {
      this._box_1 = t0;
      this._box_0 = t1;
    },
    _AsyncCallbackEntry: function _AsyncCallbackEntry(t0) {
      this.callback = t0;
      this.next = null;
    },
    _StreamIterator: function _StreamIterator(t0) {
      this.$ti = t0;
    },
    _Zone: function _Zone() {
    },
    _rootHandleError_closure: function _rootHandleError_closure(t0, t1) {
      this.error = t0;
      this.stackTrace = t1;
    },
    _RootZone: function _RootZone() {
    },
    _RootZone_bindCallbackGuarded_closure: function _RootZone_bindCallbackGuarded_closure(t0, t1) {
      this.$this = t0;
      this.f = t1;
    },
    _HashMap__getTableEntry(table, key) {
      var entry = table[key];
      return entry === table ? null : entry;
    },
    _HashMap__setTableEntry(table, key, value) {
      if (value == null)
        table[key] = table;
      else
        table[key] = value;
    },
    _HashMap__newHashTable() {
      var table = Object.create(null);
      A._HashMap__setTableEntry(table, "<non-identifier-key>", table);
      delete table["<non-identifier-key>"];
      return table;
    },
    LinkedHashMap_LinkedHashMap($K, $V) {
      return new A.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>"));
    },
    LinkedHashMap_LinkedHashMap$_literal(keyValuePairs, $K, $V) {
      return $K._eval$1("@<0>")._bind$1($V)._eval$1("LinkedHashMap<1,2>")._as(A.fillLiteralMap(keyValuePairs, new A.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>"))));
    },
    LinkedHashMap_LinkedHashMap$_empty($K, $V) {
      return new A.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>"));
    },
    LinkedHashMap_LinkedHashMap$from(other, $K, $V) {
      var result = A.LinkedHashMap_LinkedHashMap($K, $V);
      other.forEach$1(0, new A.LinkedHashMap_LinkedHashMap$from_closure(result, $K, $V));
      return result;
    },
    MapBase_mapToString(m) {
      var result, t1;
      if (A.isToStringVisiting(m))
        return "{...}";
      result = new A.StringBuffer("");
      try {
        t1 = {};
        B.JSArray_methods.add$1($.toStringVisiting, m);
        result._contents += "{";
        t1.first = true;
        m.forEach$1(0, new A.MapBase_mapToString_closure(t1, result));
        result._contents += "}";
      } finally {
        if (0 >= $.toStringVisiting.length)
          return A.ioore($.toStringVisiting, -1);
        $.toStringVisiting.pop();
      }
      t1 = result._contents;
      return t1.charCodeAt(0) == 0 ? t1 : t1;
    },
    _HashMap: function _HashMap() {
    },
    _IdentityHashMap: function _IdentityHashMap(t0) {
      var _ = this;
      _._collection$_length = 0;
      _._keys = _._collection$_rest = _._nums = _._strings = null;
      _.$ti = t0;
    },
    _HashMapKeyIterable: function _HashMapKeyIterable(t0, t1) {
      this._map = t0;
      this.$ti = t1;
    },
    _HashMapKeyIterator: function _HashMapKeyIterator(t0, t1, t2) {
      var _ = this;
      _._map = t0;
      _._keys = t1;
      _._offset = 0;
      _._collection$_current = null;
      _.$ti = t2;
    },
    LinkedHashMap_LinkedHashMap$from_closure: function LinkedHashMap_LinkedHashMap$from_closure(t0, t1, t2) {
      this.result = t0;
      this.K = t1;
      this.V = t2;
    },
    ListBase: function ListBase() {
    },
    MapBase: function MapBase() {
    },
    MapBase_mapToString_closure: function MapBase_mapToString_closure(t0, t1) {
      this._box_0 = t0;
      this.result = t1;
    },
    _UnicodeSubsetEncoder: function _UnicodeSubsetEncoder() {
    },
    Converter: function Converter() {
    },
    Latin1Encoder: function Latin1Encoder() {
    },
    Error__throw(error, stackTrace) {
      error = A.initializeExceptionWrapper(error, new Error());
      if (error == null)
        error = A._asObject(error);
      error.stack = stackTrace.toString$0(0);
      throw error;
    },
    List_List$filled($length, fill, growable, $E) {
      var i,
        result = J.JSArray_JSArray$fixed($length, $E);
      if ($length !== 0 && fill != null)
        for (i = 0; i < $length; ++i)
          result[i] = fill;
      return result;
    },
    List_List$from(elements, $E) {
      var t1, _i,
        list = A._setArrayType([], $E._eval$1("JSArray<0>"));
      for (t1 = elements.length, _i = 0; _i < elements.length; elements.length === t1 || (0, A.throwConcurrentModificationError)(elements), ++_i)
        B.JSArray_methods.add$1(list, $E._as(elements[_i]));
      return list;
    },
    List_List$_of(elements, $E) {
      var t1,
        list = A._setArrayType([], $E._eval$1("JSArray<0>"));
      for (t1 = elements.get$iterator(elements); t1.moveNext$0();)
        B.JSArray_methods.add$1(list, t1.get$current());
      return list;
    },
    StringBuffer__writeAll(string, objects, separator) {
      var iterator = J.get$iterator$ax(objects);
      if (!iterator.moveNext$0())
        return string;
      if (separator.length === 0) {
        do
          string += A.S(iterator.get$current());
        while (iterator.moveNext$0());
      } else {
        string += A.S(iterator.get$current());
        while (iterator.moveNext$0())
          string = string + separator + A.S(iterator.get$current());
      }
      return string;
    },
    StackTrace_current() {
      return A.getTraceFromException(new Error());
    },
    DateTime__fourDigits(n) {
      var absN = Math.abs(n),
        sign = n < 0 ? "-" : "";
      if (absN >= 1000)
        return "" + n;
      if (absN >= 100)
        return sign + "0" + absN;
      if (absN >= 10)
        return sign + "00" + absN;
      return sign + "000" + absN;
    },
    DateTime__threeDigits(n) {
      if (n >= 100)
        return "" + n;
      if (n >= 10)
        return "0" + n;
      return "00" + n;
    },
    DateTime__twoDigits(n) {
      if (n >= 10)
        return "" + n;
      return "0" + n;
    },
    Error_safeToString(object) {
      if (typeof object == "number" || A._isBool(object) || object == null)
        return J.toString$0$(object);
      if (typeof object == "string")
        return JSON.stringify(object);
      return A.Primitives_safeToString(object);
    },
    Error_throwWithStackTrace(error, stackTrace) {
      A.checkNotNullable(error, "error", type$.Object);
      A.checkNotNullable(stackTrace, "stackTrace", type$.StackTrace);
      A.Error__throw(error, stackTrace);
    },
    AssertionError$(message) {
      return new A.AssertionError(message);
    },
    ArgumentError$(message, $name) {
      return new A.ArgumentError(false, null, $name, message);
    },
    ArgumentError$value(value, $name, message) {
      return new A.ArgumentError(true, value, $name, message);
    },
    RangeError$range(invalidValue, minValue, maxValue, $name, message) {
      return new A.RangeError(minValue, maxValue, true, invalidValue, $name, "Invalid value");
    },
    RangeError_checkValidRange(start, end, $length) {
      if (0 > start || start > $length)
        throw A.wrapException(A.RangeError$range(start, 0, $length, "start", null));
      if (end != null) {
        if (start > end || end > $length)
          throw A.wrapException(A.RangeError$range(end, start, $length, "end", null));
        return end;
      }
      return $length;
    },
    RangeError_checkNotNegative(value, $name) {
      if (value < 0)
        throw A.wrapException(A.RangeError$range(value, 0, null, $name, null));
      return value;
    },
    IndexError$withLength(invalidValue, $length, indexable, $name) {
      return new A.IndexError($length, true, invalidValue, $name, "Index out of range");
    },
    UnsupportedError$(message) {
      return new A.UnsupportedError(message);
    },
    UnimplementedError$(message) {
      return new A.UnimplementedError(message);
    },
    StateError$(message) {
      return new A.StateError(message);
    },
    ConcurrentModificationError$(modifiedObject) {
      return new A.ConcurrentModificationError(modifiedObject);
    },
    Exception_Exception(message) {
      return new A._Exception(message);
    },
    Iterable_iterableToShortString(iterable, leftDelimiter, rightDelimiter) {
      var parts, t1;
      if (A.isToStringVisiting(iterable)) {
        if (leftDelimiter === "(" && rightDelimiter === ")")
          return "(...)";
        return leftDelimiter + "..." + rightDelimiter;
      }
      parts = A._setArrayType([], type$.JSArray_String);
      B.JSArray_methods.add$1($.toStringVisiting, iterable);
      try {
        A._iterablePartsToStrings(iterable, parts);
      } finally {
        if (0 >= $.toStringVisiting.length)
          return A.ioore($.toStringVisiting, -1);
        $.toStringVisiting.pop();
      }
      t1 = A.StringBuffer__writeAll(leftDelimiter, type$.Iterable_dynamic._as(parts), ", ") + rightDelimiter;
      return t1.charCodeAt(0) == 0 ? t1 : t1;
    },
    Iterable_iterableToFullString(iterable, leftDelimiter, rightDelimiter) {
      var buffer, t1;
      if (A.isToStringVisiting(iterable))
        return leftDelimiter + "..." + rightDelimiter;
      buffer = new A.StringBuffer(leftDelimiter);
      B.JSArray_methods.add$1($.toStringVisiting, iterable);
      try {
        t1 = buffer;
        t1._contents = A.StringBuffer__writeAll(t1._contents, iterable, ", ");
      } finally {
        if (0 >= $.toStringVisiting.length)
          return A.ioore($.toStringVisiting, -1);
        $.toStringVisiting.pop();
      }
      buffer._contents += rightDelimiter;
      t1 = buffer._contents;
      return t1.charCodeAt(0) == 0 ? t1 : t1;
    },
    _iterablePartsToStrings(iterable, parts) {
      var next, ultimateString, penultimateString, penultimate, ultimate, ultimate0, elision,
        it = iterable.get$iterator(iterable),
        $length = 0, count = 0;
      for (;;) {
        if (!($length < 80 || count < 3))
          break;
        if (!it.moveNext$0())
          return;
        next = A.S(it.get$current());
        B.JSArray_methods.add$1(parts, next);
        $length += next.length + 2;
        ++count;
      }
      if (!it.moveNext$0()) {
        if (count <= 5)
          return;
        if (0 >= parts.length)
          return A.ioore(parts, -1);
        ultimateString = parts.pop();
        if (0 >= parts.length)
          return A.ioore(parts, -1);
        penultimateString = parts.pop();
      } else {
        penultimate = it.get$current();
        ++count;
        if (!it.moveNext$0()) {
          if (count <= 4) {
            B.JSArray_methods.add$1(parts, A.S(penultimate));
            return;
          }
          ultimateString = A.S(penultimate);
          if (0 >= parts.length)
            return A.ioore(parts, -1);
          penultimateString = parts.pop();
          $length += ultimateString.length + 2;
        } else {
          ultimate = it.get$current();
          ++count;
          for (; it.moveNext$0(); penultimate = ultimate, ultimate = ultimate0) {
            ultimate0 = it.get$current();
            ++count;
            if (count > 100) {
              for (;;) {
                if (!($length > 75 && count > 3))
                  break;
                if (0 >= parts.length)
                  return A.ioore(parts, -1);
                $length -= parts.pop().length + 2;
                --count;
              }
              B.JSArray_methods.add$1(parts, "...");
              return;
            }
          }
          penultimateString = A.S(penultimate);
          ultimateString = A.S(ultimate);
          $length += ultimateString.length + penultimateString.length + 4;
        }
      }
      if (count > parts.length + 2) {
        $length += 5;
        elision = "...";
      } else
        elision = null;
      for (;;) {
        if (!($length > 80 && parts.length > 3))
          break;
        if (0 >= parts.length)
          return A.ioore(parts, -1);
        $length -= parts.pop().length + 2;
        if (elision == null) {
          $length += 5;
          elision = "...";
        }
      }
      if (elision != null)
        B.JSArray_methods.add$1(parts, elision);
      B.JSArray_methods.add$1(parts, penultimateString);
      B.JSArray_methods.add$1(parts, ultimateString);
    },
    Object_hash(object1, object2) {
      var t1 = B.JSInt_methods.get$hashCode(object1);
      object2 = B.JSInt_methods.get$hashCode(object2);
      object2 = A.SystemHash_finish(A.SystemHash_combine(A.SystemHash_combine($.$get$_hashSeed(), t1), object2));
      return object2;
    },
    Object_hashAll(objects) {
      var t1, _i,
        hash = $.$get$_hashSeed();
      for (t1 = objects.length, _i = 0; _i < objects.length; objects.length === t1 || (0, A.throwConcurrentModificationError)(objects), ++_i)
        hash = A.SystemHash_combine(hash, J.get$hashCode$(objects[_i]));
      return A.SystemHash_finish(hash);
    },
    DateTime: function DateTime(t0, t1, t2) {
      this._core$_value = t0;
      this._microsecond = t1;
      this.isUtc = t2;
    },
    Duration: function Duration(t0) {
      this._duration = t0;
    },
    _Enum: function _Enum() {
    },
    Error: function Error() {
    },
    AssertionError: function AssertionError(t0) {
      this.message = t0;
    },
    TypeError: function TypeError() {
    },
    ArgumentError: function ArgumentError(t0, t1, t2, t3) {
      var _ = this;
      _._hasValue = t0;
      _.invalidValue = t1;
      _.name = t2;
      _.message = t3;
    },
    RangeError: function RangeError(t0, t1, t2, t3, t4, t5) {
      var _ = this;
      _.start = t0;
      _.end = t1;
      _._hasValue = t2;
      _.invalidValue = t3;
      _.name = t4;
      _.message = t5;
    },
    IndexError: function IndexError(t0, t1, t2, t3, t4) {
      var _ = this;
      _.length = t0;
      _._hasValue = t1;
      _.invalidValue = t2;
      _.name = t3;
      _.message = t4;
    },
    UnsupportedError: function UnsupportedError(t0) {
      this.message = t0;
    },
    UnimplementedError: function UnimplementedError(t0) {
      this.message = t0;
    },
    StateError: function StateError(t0) {
      this.message = t0;
    },
    ConcurrentModificationError: function ConcurrentModificationError(t0) {
      this.modifiedObject = t0;
    },
    OutOfMemoryError: function OutOfMemoryError() {
    },
    StackOverflowError: function StackOverflowError() {
    },
    _Exception: function _Exception(t0) {
      this.message = t0;
    },
    Iterable: function Iterable() {
    },
    MapEntry: function MapEntry(t0, t1, t2) {
      this.key = t0;
      this.value = t1;
      this.$ti = t2;
    },
    Null: function Null() {
    },
    Object: function Object() {
    },
    _StringStackTrace: function _StringStackTrace() {
    },
    StringBuffer: function StringBuffer(t0) {
      this._contents = t0;
    },
    NullRejectionException: function NullRejectionException(t0) {
      this.isUndefined = t0;
    },
    _callDartFunctionFast0(callback) {
      return type$.Function._as(callback).call$0();
    },
    _callDartFunctionFast1(callback, arg1, $length) {
      type$.Function._as(callback);
      if (A._asInt($length) >= 1)
        return callback.call$1(arg1);
      return callback.call$0();
    },
    _noJsifyRequired(o) {
      return o == null || A._isBool(o) || typeof o == "number" || typeof o == "string" || type$.Int8List._is(o) || type$.Uint8List._is(o) || type$.Uint8ClampedList._is(o) || type$.Int16List._is(o) || type$.Uint16List._is(o) || type$.Int32List._is(o) || type$.Uint32List._is(o) || type$.Float32List._is(o) || type$.Float64List._is(o) || type$.ByteBuffer._is(o) || type$.ByteData._is(o);
    },
    jsify0(object) {
      if (A._noJsifyRequired(object))
        return object;
      return new A.jsify__convert(new A._IdentityHashMap(type$._IdentityHashMap_of_nullable_Object_and_nullable_Object)).call$1(object);
    },
    promiseToFuture(jsPromise, $T) {
      var t1 = new A._Future($.Zone__current, $T._eval$1("_Future<0>")),
        completer = new A._AsyncCompleter(t1, $T._eval$1("_AsyncCompleter<0>"));
      jsPromise.then(A.convertDartClosureToJS(new A.promiseToFuture_closure(completer, $T), 1), A.convertDartClosureToJS(new A.promiseToFuture_closure0(completer), 1));
      return t1;
    },
    _noDartifyRequired(o) {
      return o == null || typeof o === "boolean" || typeof o === "number" || typeof o === "string" || o instanceof Int8Array || o instanceof Uint8Array || o instanceof Uint8ClampedArray || o instanceof Int16Array || o instanceof Uint16Array || o instanceof Int32Array || o instanceof Uint32Array || o instanceof Float32Array || o instanceof Float64Array || o instanceof ArrayBuffer || o instanceof DataView;
    },
    dartify(o) {
      if (A._noDartifyRequired(o))
        return o;
      return new A.dartify_convert(new A._IdentityHashMap(type$._IdentityHashMap_of_nullable_Object_and_nullable_Object)).call$1(o);
    },
    jsify__convert: function jsify__convert(t0) {
      this._convertedObjects = t0;
    },
    promiseToFuture_closure: function promiseToFuture_closure(t0, t1) {
      this.completer = t0;
      this.T = t1;
    },
    promiseToFuture_closure0: function promiseToFuture_closure0(t0) {
      this.completer = t0;
    },
    dartify_convert: function dartify_convert(t0) {
      this._convertedObjects = t0;
    },
    OutputFormat: function OutputFormat(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    ImageConvertThreadRequest: function ImageConvertThreadRequest(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9) {
      var _ = this;
      _.id = t0;
      _.image = t1;
      _.outputFormat = t2;
      _.singleFrame = t3;
      _.pngLevel = t4;
      _.pngFilter = t5;
      _.jpegQuality = t6;
      _.jpegBackgroundColor = t7;
      _.jpegChroma = t8;
      _.generateOnlyImageBounds = t9;
    },
    ThreadRequest: function ThreadRequest() {
    },
    ThreadResponse: function ThreadResponse(t0, t1) {
      this.id = t0;
      this.bytes = t1;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs(value) {
      var t1, t2, t3, jsId, jsMode, jsGenerateOnlyImageBounds, jsJpegChroma, jsJpegQuality, jsJpegBackgroundColor, jsPngFilter, jsPngLevel, jsSingleFrame, jsOutputFormat, jsImage, t4, t5, t6, t7, t8, t9, t10, t11;
      A._asJSObject(value);
      t1 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_convertString();
      t2 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_convertInteger();
      t3 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_convertBool();
      jsId = A.jsGetProperty(value, "id");
      jsMode = A.jsGetProperty(value, "mode");
      jsGenerateOnlyImageBounds = A.jsGetProperty(value, "generateOnlyImageBounds");
      jsJpegChroma = A.jsGetProperty(value, "jpegChroma");
      jsJpegQuality = A.jsGetProperty(value, "jpegQuality");
      jsJpegBackgroundColor = A.jsGetProperty(value, "jpegBackgroundColor");
      jsPngFilter = A.jsGetProperty(value, "pngFilter");
      jsPngLevel = A.jsGetProperty(value, "pngLevel");
      jsSingleFrame = A.jsGetProperty(value, "singleFrame");
      jsOutputFormat = A.jsGetProperty(value, "outputFormat");
      jsImage = A.jsGetProperty(value, "image");
      t4 = t1.call$1(jsId);
      t4.toString;
      t1.call$1(jsMode);
      t5 = t3.call$1(jsGenerateOnlyImageBounds);
      t6 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma().call$1(t1.call$1(jsJpegChroma));
      t7 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpgQuality().call$1(t2.call$1(jsJpegQuality));
      t8 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpgBackgroundColor().call$1(t2.call$1(jsJpegBackgroundColor));
      t9 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter().call$1(t1.call$1(jsPngFilter));
      t10 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngLevel().call$1(t2.call$1(jsPngLevel));
      t3 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getSingleFrame().call$1(t3.call$1(jsSingleFrame));
      t11 = new A.ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat().call$1(t1.call$1(jsOutputFormat));
      return new A.ThreadWebRequest(t4, new A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage(t1, t2).call$1(A._asJSObject(jsImage)), t11, t3, t10, t9, t7, t8, t6, t5);
    },
    ThreadWebRequest: function ThreadWebRequest(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9) {
      var _ = this;
      _.id = t0;
      _.image = t1;
      _.outputFormat = t2;
      _.singleFrame = t3;
      _.pngLevel = t4;
      _.pngFilter = t5;
      _.jpegQuality = t6;
      _.jpegBackgroundColor = t7;
      _.jpegChroma = t8;
      _.generateOnlyImageBounds = t9;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_convertString: function ThreadWebRequest_ThreadWebRequest$fromJs_convertString() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_convertInteger: function ThreadWebRequest_ThreadWebRequest$fromJs_convertInteger() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_convertBool: function ThreadWebRequest_ThreadWebRequest$fromJs_convertBool() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_parseImage: function ThreadWebRequest_ThreadWebRequest$fromJs_parseImage(t0, t1) {
      this.convertString = t0;
      this.convertInteger = t1;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure: function ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure(t0) {
      this.frameType = t0;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure0: function ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure0(t0) {
      this.format = t0;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma: function ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma_closure: function ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma_closure(t0) {
      this.value = t0;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter: function ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter_closure: function ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter_closure(t0) {
      this.value = t0;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat: function ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat_closure: function ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat_closure(t0) {
      this.value = t0;
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getJpgBackgroundColor: function ThreadWebRequest_ThreadWebRequest$fromJs_getJpgBackgroundColor() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getJpgQuality: function ThreadWebRequest_ThreadWebRequest$fromJs_getJpgQuality() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getPngLevel: function ThreadWebRequest_ThreadWebRequest$fromJs_getPngLevel() {
    },
    ThreadWebRequest_ThreadWebRequest$fromJs_getSingleFrame: function ThreadWebRequest_ThreadWebRequest$fromJs_getSingleFrame() {
    },
    ZLibEncoderBase: function ZLibEncoderBase() {
    },
    _ZLibEncoder: function _ZLibEncoder() {
    },
    Deflate$stream(_input, level, output, windowBits) {
      var t1 = A._HuffmanTree$(),
        t2 = A._HuffmanTree$(),
        t3 = A._HuffmanTree$(),
        t4 = new Uint16Array(16),
        t5 = new Uint32Array(573),
        t6 = new Uint8Array(573);
      t1 = new A.Deflate(_input, output, t1, t2, t3, t4, t5, t6);
      t1._deflate$_init$2$windowBits(level, windowBits);
      t1._deflate$1(B._DeflateFlushMode_3);
      return t1;
    },
    Deflate__smaller(tree, n, m, depth) {
      var t3,
        t1 = n * 2,
        t2 = tree.length;
      if (!(t1 >= 0 && t1 < t2))
        return A.ioore(tree, t1);
      t1 = tree[t1];
      t3 = m * 2;
      if (!(t3 >= 0 && t3 < t2))
        return A.ioore(tree, t3);
      t3 = tree[t3];
      if (t1 >= t3)
        if (t1 === t3) {
          if (!(n >= 0 && n < 573))
            return A.ioore(depth, n);
          t1 = depth[n];
          if (!(m >= 0 && m < 573))
            return A.ioore(depth, m);
          t1 = t1 <= depth[m];
        } else
          t1 = false;
      else
        t1 = true;
      return t1;
    },
    _HuffmanTree$() {
      return new A._HuffmanTree();
    },
    _HuffmanTree__genCodes(tree, maxCode, blCount) {
      var code, bits, t1, n, t2, t3, len,
        nextCode = new Uint16Array(16);
      for (code = 0, bits = 1; bits <= 15; ++bits) {
        code = code + blCount[bits - 1] << 1 >>> 0;
        if (!(bits < 16))
          return A.ioore(nextCode, bits);
        nextCode[bits] = code;
      }
      for (t1 = tree.length, n = 0; n <= maxCode; ++n) {
        t2 = n * 2;
        t3 = t2 + 1;
        if (!(t3 < t1))
          return A.ioore(tree, t3);
        len = tree[t3];
        if (len === 0)
          continue;
        if (!(len >= 0 && len < 16))
          return A.ioore(nextCode, len);
        t3 = nextCode[len];
        if (!(len < 16))
          return A.ioore(nextCode, len);
        nextCode[len] = t3 + 1;
        t3 = A._HuffmanTree__reverseBits(t3, len);
        tree.$flags & 2 && A.throwUnsupportedOperation(tree);
        if (!(t2 < t1))
          return A.ioore(tree, t2);
        tree[t2] = t3;
      }
    },
    _HuffmanTree__reverseBits(code, len) {
      var code0, res = 0;
      do {
        code0 = A._rshift(code, 1);
        res = (res | code & 1) << 1 >>> 0;
        if (--len, len > 0) {
          code = code0;
          continue;
        } else
          break;
      } while (true);
      return A._rshift(res, 1);
    },
    _HuffmanTree__dCode(dist) {
      var t1;
      if (dist < 256) {
        if (!(dist >= 0))
          return A.ioore(B.List_BSx, dist);
        t1 = B.List_BSx[dist];
      } else {
        t1 = 256 + A._rshift(dist, 7);
        if (!(t1 < 512))
          return A.ioore(B.List_BSx, t1);
        t1 = B.List_BSx[t1];
      }
      return t1;
    },
    _StaticTree$(staticTree, extraBits, extraBase, numElements, maxLength) {
      return new A._StaticTree(staticTree, extraBits, extraBase, numElements, maxLength);
    },
    _rshift(number, bits) {
      if (number >= 0)
        return B.JSInt_methods.$shr(number, bits);
      else
        return B.JSInt_methods.$shr(number, bits) + B.JSInt_methods._shlPositive$1(2, (~bits >>> 0) + 65536 & 65535);
    },
    _DeflateFlushMode: function _DeflateFlushMode(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    Deflate: function Deflate(t0, t1, t2, t3, t4, t5, t6, t7) {
      var _ = this;
      _._input = t0;
      _._output = t1;
      _._status = null;
      _.total = _.crc32 = 0;
      _.__Deflate__pending_A = _.__Deflate__pendingOut_A = _.__Deflate__pendingBufferSize_A = _.__Deflate__pendingBuffer_A = $;
      _._dataType = 2;
      _.__Deflate__strStart_A = _.__Deflate__matchAvailable_A = _.__Deflate__prevMatch_A = _.__Deflate__matchLength_A = _.__Deflate__blockStart_A = _.__Deflate__hashShift_A = _.__Deflate__hashMask_A = _.__Deflate__hashBits_A = _.__Deflate__hashSize_A = _.__Deflate__insertHash_A = _.__Deflate__head_A = _.__Deflate__prev_A = _.__Deflate__actualWindowSize_A = _.__Deflate__window_A = _.__Deflate__windowMask_A = _.__Deflate__windowBits_A = _.__Deflate__windowSize_A = $;
      _._matchStart = 0;
      _.__Deflate__bitLengthTree_A = _.__Deflate__dynamicDistTree_A = _.__Deflate__dynamicLengthTree_A = _.__Deflate__strategy_A = _.__Deflate__level_A = _.__Deflate__prevLength_A = _.__Deflate__lookAhead_A = $;
      _._lDesc = t2;
      _._dDesc = t3;
      _._blDesc = t4;
      _._bitLengthCount = t5;
      _._heap = t6;
      _.__Deflate__heapMax_A = _.__Deflate__heapLen_A = $;
      _._depth = t7;
      _.__Deflate__numValidBits_A = _.__Deflate__bitBuffer_A = _.__Deflate__lastEOBLen_A = _.__Deflate__matches_A = _.__Deflate__staticLen_A = _.__Deflate__optimalLen_A = _.__Deflate__dbuf_A = _.__Deflate__lastLit_A = _.__Deflate__litBufferSize_A = _.__Deflate__lbuf_A = $;
    },
    _DeflaterConfig: function _DeflaterConfig(t0, t1, t2, t3, t4) {
      var _ = this;
      _.goodLength = t0;
      _.maxLazy = t1;
      _.niceLength = t2;
      _.maxChain = t3;
      _.$function = t4;
    },
    _HuffmanTree: function _HuffmanTree() {
      this.___HuffmanTree_staticDesc_A = this.___HuffmanTree_maxCode_A = this.___HuffmanTree_dynamicTree_A = $;
    },
    _StaticTree: function _StaticTree(t0, t1, t2, t3, t4) {
      var _ = this;
      _.staticTree = t0;
      _.extraBits = t1;
      _.extraBase = t2;
      _.numElements = t3;
      _.maxLength = t4;
    },
    ByteOrder: function ByteOrder(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    InputMemoryStream$(bytes, byteOrder, $length, offset) {
      var t2, data,
        t1 = new A.InputMemoryStream(byteOrder);
      if (offset == null)
        offset = 0;
      if ($length == null)
        $length = bytes.length - offset;
      t2 = bytes.length;
      if (offset + $length > t2)
        $length = t2 - offset;
      data = type$.Uint8List._is(bytes) ? bytes : new Uint8Array(A._ensureNativeList(bytes));
      t2 = J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(data), data.byteOffset + offset, $length);
      t1.buffer = t2;
      t1.__InputMemoryStream__length_A = t2.length;
      return t1;
    },
    InputMemoryStream: function InputMemoryStream(t0) {
      var _ = this;
      _.buffer = null;
      _._position = 0;
      _.__InputMemoryStream__length_A = $;
      _.byteOrder = t0;
    },
    InputStream: function InputStream() {
    },
    OutputMemoryStream$(byteOrder) {
      return new A.OutputMemoryStream(new Uint8Array(32768), byteOrder);
    },
    OutputMemoryStream: function OutputMemoryStream(t0, t1) {
      this.length = 0;
      this._output_memory_stream$_buffer = t0;
      this.byteOrder = t1;
    },
    OutputStream: function OutputStream() {
    },
    ChannelIterator: function ChannelIterator(t0) {
      this.index = -1;
      this.color = t0;
    },
    ChannelOrder: function ChannelOrder(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    Color: function Color() {
    },
    ColorFloat16: function ColorFloat16(t0) {
      this.data = t0;
    },
    ColorFloat32: function ColorFloat32(t0) {
      this.data = t0;
    },
    ColorFloat64: function ColorFloat64(t0) {
      this.data = t0;
    },
    ColorInt16: function ColorInt16(t0) {
      this.data = t0;
    },
    ColorInt32: function ColorInt32(t0) {
      this.data = t0;
    },
    ColorInt8: function ColorInt8(t0) {
      this.data = t0;
    },
    ColorUint1: function ColorUint1(t0, t1) {
      this.length = t0;
      this.__ColorUint1_data_A = t1;
    },
    ColorUint16: function ColorUint16(t0) {
      this.data = t0;
    },
    ColorUint2: function ColorUint2(t0, t1) {
      this.length = t0;
      this.__ColorUint2_data_A = t1;
    },
    ColorUint32: function ColorUint32(t0) {
      this.data = t0;
    },
    ColorUint4: function ColorUint4(t0, t1) {
      this.length = t0;
      this.data = t1;
    },
    ColorUint8: function ColorUint8(t0) {
      this.data = t0;
    },
    convertFormatValue(value, from, to) {
      var t1;
      if (from === to)
        return value;
      switch (from.index) {
        case 0:
          if (value === 0)
            t1 = 0;
          else {
            t1 = B.Map_vw3Ow.$index(0, to);
            t1.toString;
          }
          return t1;
        case 1:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return value;
            case 2:
              return value * 5;
            case 3:
              return value * 75;
            case 4:
              return value * 21845;
            case 5:
              return value * 1431655765;
            case 6:
              return value * 42;
            case 7:
              return value * 10922;
            case 8:
              return value * 715827882;
            case 9:
            case 10:
            case 11:
              return value / 3;
          }
          break;
        case 2:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 1);
            case 2:
              return value;
            case 3:
              return value * 17;
            case 4:
              return value * 4369;
            case 5:
              return value * 286331153;
            case 6:
              return value * 8;
            case 7:
              return value * 2184;
            case 8:
              return value * 143165576;
            case 9:
            case 10:
            case 11:
              return value / 3;
          }
          break;
        case 3:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 6);
            case 2:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 4);
            case 3:
              return value;
            case 4:
              return value * 257;
            case 5:
              return value * 16843009;
            case 6:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 1);
            case 7:
              return value * 128;
            case 8:
              return value * 8421504;
            case 9:
            case 10:
            case 11:
              return value / 255;
          }
          break;
        case 4:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 14);
            case 2:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 12);
            case 3:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 8);
            case 4:
              return value;
            case 5:
              return A._asInt(value) << 8 >>> 0;
            case 6:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 9);
            case 7:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 1);
            case 8:
              return value * 524296;
            case 9:
            case 10:
            case 11:
              return value / 65535;
          }
          break;
        case 5:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 30);
            case 2:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 28);
            case 3:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 24);
            case 4:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 16);
            case 5:
              return value;
            case 6:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 25);
            case 7:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 17);
            case 8:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 1);
            case 9:
            case 10:
            case 11:
              return value / 4294967295;
          }
          break;
        case 6:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 5);
            case 2:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 3);
            case 3:
              return value <= 0 ? 0 : A._asInt(value) << 1 >>> 0;
            case 4:
              return value <= 0 ? 0 : A._asInt(value) * 516;
            case 5:
              return value <= 0 ? 0 : A._asInt(value) * 33818640;
            case 6:
              return value;
            case 7:
              return value * 258;
            case 8:
              return value * 16909320;
            case 9:
            case 10:
            case 11:
              return value / 127;
          }
          break;
        case 7:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 15);
            case 2:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 11);
            case 3:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 7);
            case 4:
              return value <= 0 ? 0 : A._asInt(value) << 1 >>> 0;
            case 5:
              return value <= 0 ? 0 : A._asInt(value) * 131076;
            case 6:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 8);
            case 7:
              return value;
            case 8:
              return A._asInt(value) * 65538;
            case 9:
            case 10:
            case 11:
              return value / 32767;
          }
          break;
        case 8:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 29);
            case 2:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 27);
            case 3:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 23);
            case 4:
              return value <= 0 ? 0 : B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 16);
            case 5:
              return value <= 0 ? 0 : A._asInt(value) << 1 >>> 0;
            case 6:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 24);
            case 7:
              return B.JSInt_methods._shrOtherPositive$1(A._asInt(value), 16);
            case 8:
              return value;
            case 9:
            case 10:
            case 11:
              return value / 2147483647;
          }
          break;
        case 9:
        case 10:
        case 11:
          switch (to.index) {
            case 0:
              return value === 0 ? 0 : 1;
            case 1:
              return B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(value, 0, 1) * 3);
            case 2:
              return B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(value, 0, 1) * 15);
            case 3:
              return B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(value, 0, 1) * 255);
            case 4:
              return B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(value, 0, 1) * 65535);
            case 5:
              return B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(value, 0, 1) * 4294967295);
            case 6:
              return B.JSNumber_methods.toInt$0(value < 0 ? B.JSNumber_methods.clamp$2(value, -1, 1) * 128 : B.JSNumber_methods.clamp$2(value, -1, 1) * 127);
            case 7:
              return B.JSNumber_methods.toInt$0(value < 0 ? B.JSNumber_methods.clamp$2(value, -1, 1) * 32768 : B.JSNumber_methods.clamp$2(value, -1, 1) * 32767);
            case 8:
              return B.JSNumber_methods.toInt$0(value < 0 ? B.JSNumber_methods.clamp$2(value, -1, 1) * 2147483648 : B.JSNumber_methods.clamp$2(value, -1, 1) * 2147483647);
            case 9:
            case 10:
            case 11:
              return value;
          }
          break;
      }
    },
    Format: function Format(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    FormatType: function FormatType(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    ExifData$from(other) {
      var t1 = new A.ExifData(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.IfdDirectory));
      t1.IfdContainer$from$1(other);
      return t1;
    },
    ExifData: function ExifData(t0) {
      this.directories = t0;
    },
    ExifTag$($name, type, count) {
      return new A.ExifTag($name, type);
    },
    ExifTag: function ExifTag(t0, t1) {
      this.name = t0;
      this.type = t1;
    },
    IfdContainer: function IfdContainer(t0) {
      this.directories = t0;
    },
    IfdContainer$from_closure: function IfdContainer$from_closure(t0) {
      this.$this = t0;
    },
    IfdDirectory$from(other) {
      var t1 = new A.IfdDirectory(A.LinkedHashMap_LinkedHashMap$_empty(type$.int, type$.IfdValue), new A.IfdContainer(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.IfdDirectory)));
      t1.copy$1(other);
      return t1;
    },
    IfdDirectory: function IfdDirectory(t0, t1) {
      this.data = t0;
      this.sub = t1;
    },
    IfdDirectory_copy_closure: function IfdDirectory_copy_closure(t0) {
      this.$this = t0;
    },
    IfdDirectory_copy_closure0: function IfdDirectory_copy_closure0(t0) {
      this.$this = t0;
    },
    IfdValueLong$(value) {
      var t1 = new Uint32Array(1);
      t1[0] = value;
      return new A.IfdValueLong(t1);
    },
    IfdValueType: function IfdValueType(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    IfdValue: function IfdValue() {
    },
    IfdByteValue: function IfdByteValue(t0) {
      this.value = t0;
    },
    IfdValueShort: function IfdValueShort(t0) {
      this.value = t0;
    },
    IfdValueLong: function IfdValueLong(t0) {
      this.value = t0;
    },
    IfdValueRational: function IfdValueRational(t0) {
      this.value = t0;
    },
    IfdValueSByte: function IfdValueSByte(t0) {
      this.value = t0;
    },
    IfdValueSShort: function IfdValueSShort(t0) {
      this.value = t0;
    },
    IfdValueSLong: function IfdValueSLong(t0) {
      this.value = t0;
    },
    IfdValueSRational: function IfdValueSRational(t0) {
      this.value = t0;
    },
    IfdValueSingle: function IfdValueSingle(t0) {
      this.value = t0;
    },
    IfdValueDouble: function IfdValueDouble(t0) {
      this.value = t0;
    },
    IfdValueUndefined: function IfdValueUndefined(t0) {
      this.value = t0;
    },
    BmpCompression: function BmpCompression(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    BmpEncoder: function BmpEncoder() {
    },
    CurEncoder: function CurEncoder() {
    },
    Encoder: function Encoder() {
    },
    WinEncoder: function WinEncoder() {
    },
    IcoEncoder: function IcoEncoder() {
    },
    JpegChroma: function JpegChroma(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    JpegHealthyEncoder: function JpegHealthyEncoder(t0, t1, t2, t3, t4, t5, t6, t7, t8) {
      var _ = this;
      _._yTable = t0;
      _._uvTable = t1;
      _._fdtblY = t2;
      _._fdtblUv = t3;
      _._uvdcHuffman = _._ydcHuffman = null;
      _.__JpegHealthyEncoder__uvacHuffman_A = _.__JpegHealthyEncoder__yacHuffman_A = $;
      _._bitCode = t4;
      _._category = t5;
      _._outputfDCTQuant = t6;
      _._du = t7;
      _._rgbYuvTable = t8;
      _._currentQuality = null;
      _._byteNew = 0;
      _._bytePos = 7;
    },
    JpegHealthyEncoder_encode_healthCheck: function JpegHealthyEncoder_encode_healthCheck(t0) {
      this.destroy$ = t0;
    },
    PngFilter: function PngFilter(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    PngEncoder: function PngEncoder(t0, t1) {
      var _ = this;
      _._globalQuantizer = null;
      _.filter = t0;
      _.repeat = 0;
      _.level = t1;
      _.__PngEncoder__frames_A = $;
      _.sequenceNumber = 0;
      _.isAnimated = false;
      _.output = null;
    },
    PvrColorRgbCore: function PvrColorRgbCore() {
    },
    PvrColorRgb: function PvrColorRgb(t0, t1, t2) {
      this.r = t0;
      this.g = t1;
      this.b = t2;
    },
    PvrColorRgba: function PvrColorRgba(t0, t1, t2, t3) {
      var _ = this;
      _.r = t0;
      _.g = t1;
      _.b = t2;
      _.a = t3;
    },
    PvrColorBoundingBox: function PvrColorBoundingBox(t0, t1, t2) {
      this.min = t0;
      this.max = t1;
      this.$ti = t2;
    },
    PvrPacket__getMortonNumber(x, y) {
      var t2,
        t1 = x >>> 8;
      if (!(t1 < 256))
        return A.ioore(B.List_bAA, t1);
      t1 = B.List_bAA[t1];
      t2 = y >>> 8;
      if (!(t2 < 256))
        return A.ioore(B.List_bAA, t2);
      return (t1 << 17 | B.List_bAA[t2] << 16 | B.List_bAA[x & 255] << 1 | B.List_bAA[y & 255]) >>> 0;
    },
    PvrPacket: function PvrPacket(t0) {
      var _ = this;
      _.rawData = t0;
      _.index = 0;
      _._usePunchthroughAlpha = false;
      _._colorA = 0;
      _._colorAIsOpaque = false;
      _._colorB = 0;
      _._colorBIsOpaque = false;
    },
    PvrEncoder__calculateBoundingBoxRgb(bitmap, blockX, blockY) {
      var t1 = new A.PvrEncoder__calculateBoundingBoxRgb_pixel(bitmap, blockX, blockY),
        t2 = t1.call$2(0, 0),
        t3 = t1.call$2(0, 0),
        cbb = new A.PvrColorBoundingBox(t2.copy$0(), t3.copy$0(), type$.PvrColorBoundingBox_PvrColorRgb);
      cbb.add$1(0, t1.call$2(1, 0));
      cbb.add$1(0, t1.call$2(2, 0));
      cbb.add$1(0, t1.call$2(3, 0));
      cbb.add$1(0, t1.call$2(0, 1));
      cbb.add$1(0, t1.call$2(1, 1));
      cbb.add$1(0, t1.call$2(1, 2));
      cbb.add$1(0, t1.call$2(1, 3));
      cbb.add$1(0, t1.call$2(2, 0));
      cbb.add$1(0, t1.call$2(2, 1));
      cbb.add$1(0, t1.call$2(2, 2));
      cbb.add$1(0, t1.call$2(2, 3));
      cbb.add$1(0, t1.call$2(3, 0));
      cbb.add$1(0, t1.call$2(3, 1));
      cbb.add$1(0, t1.call$2(3, 2));
      cbb.add$1(0, t1.call$2(3, 3));
      return cbb;
    },
    PvrEncoder__calculateBoundingBoxRgba(bitmap, blockX, blockY) {
      var t1 = new A.PvrEncoder__calculateBoundingBoxRgba_pixel(bitmap, blockX, blockY),
        t2 = t1.call$2(0, 0),
        t3 = t1.call$2(0, 0),
        cbb = new A.PvrColorBoundingBox(t2.copy$0(), t3.copy$0(), type$.PvrColorBoundingBox_PvrColorRgba);
      cbb.add$1(0, t1.call$2(1, 0));
      cbb.add$1(0, t1.call$2(2, 0));
      cbb.add$1(0, t1.call$2(3, 0));
      cbb.add$1(0, t1.call$2(0, 1));
      cbb.add$1(0, t1.call$2(1, 1));
      cbb.add$1(0, t1.call$2(1, 2));
      cbb.add$1(0, t1.call$2(1, 3));
      cbb.add$1(0, t1.call$2(2, 0));
      cbb.add$1(0, t1.call$2(2, 1));
      cbb.add$1(0, t1.call$2(2, 2));
      cbb.add$1(0, t1.call$2(2, 3));
      cbb.add$1(0, t1.call$2(3, 0));
      cbb.add$1(0, t1.call$2(3, 1));
      cbb.add$1(0, t1.call$2(3, 2));
      cbb.add$1(0, t1.call$2(3, 3));
      return cbb;
    },
    PvrFormat: function PvrFormat(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    PvrEncoder: function PvrEncoder() {
    },
    PvrEncoder__calculateBoundingBoxRgb_pixel: function PvrEncoder__calculateBoundingBoxRgb_pixel(t0, t1, t2) {
      this.bitmap = t0;
      this.blockX = t1;
      this.blockY = t2;
    },
    PvrEncoder__calculateBoundingBoxRgba_pixel: function PvrEncoder__calculateBoundingBoxRgba_pixel(t0, t1, t2) {
      this.bitmap = t0;
      this.blockX = t1;
      this.blockY = t2;
    },
    TgaEncoder: function TgaEncoder() {
    },
    TiffFormat: function TiffFormat(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    TiffEncoder: function TiffEncoder() {
    },
    Image$(backgroundColor, exif, frameDuration, frameType, height, iccp, loopCount, numChannels, palette, width, withPalette) {
      var _null = null,
        t1 = new A.Image(_null, _null, _null, _null, backgroundColor, loopCount, frameType, frameDuration, 0);
      B.JSArray_methods.add$1(t1.get$frames(), t1);
      t1._image$_initialize$7$exif$iccp$numChannels$palette$withPalette(width, height, exif, iccp, numChannels, palette, withPalette);
      return t1;
    },
    Image$fromResized(other, height, noAnimation, width) {
      var t2, _null = null,
        t1 = other._exif;
      t1 = t1 == null ? _null : A.ExifData$from(t1);
      t2 = other.frameType;
      t1 = new A.Image(_null, _null, _null, t1, _null, other.loopCount, t2, other.frameDuration, other.frameIndex);
      t1.Image$fromResized$4$height$noAnimation$width(other, height, noAnimation, width);
      return t1;
    },
    Image$from(other, noAnimation, noPixels) {
      var t2, t3, _null = null,
        t1 = other.data;
      if (t1 == null)
        t1 = _null;
      else {
        t2 = t1.data;
        if (noPixels)
          t2 = new Uint8Array(t2.length);
        else
          t2 = new Uint8Array(A._ensureNativeList(t2));
        t3 = t1.palette;
        t3 = t3 == null ? _null : new A.PaletteUint8(new Uint8Array(A._ensureNativeList(t3.data)), t3.numColors, t3.numChannels);
        t1 = new A.ImageDataUint8(t2, t3, t1.width, t1.height, t1.numChannels);
      }
      t2 = other._exif;
      t2 = t2 == null ? _null : A.ExifData$from(t2);
      t3 = other.frameType;
      t1 = new A.Image(t1, _null, _null, t2, _null, other.loopCount, t3, other.frameDuration, other.frameIndex);
      t1.Image$from$3$noAnimation$noPixels(other, noAnimation, noPixels);
      return t1;
    },
    FrameType: function FrameType(t0, t1) {
      this.index = t0;
      this._name = t1;
    },
    Image: function Image(t0, t1, t2, t3, t4, t5, t6, t7, t8) {
      var _ = this;
      _.data = t0;
      _.extraChannels = null;
      _.iccProfile = t1;
      _.textData = t2;
      _._exif = t3;
      _.backgroundColor = t4;
      _.loopCount = t5;
      _.frameType = t6;
      _.__Image_frames_AI = $;
      _.frameDuration = t7;
      _.frameIndex = t8;
    },
    ImageData: function ImageData() {
    },
    ImageDataUint8: function ImageDataUint8(t0, t1, t2, t3, t4) {
      var _ = this;
      _.data = t0;
      _.palette = t1;
      _.width = t2;
      _.height = t3;
      _.numChannels = t4;
    },
    Palette: function Palette() {
    },
    PaletteUint32: function PaletteUint32(t0, t1, t2) {
      this.data = t0;
      this.numColors = t1;
      this.numChannels = t2;
    },
    PaletteUint8: function PaletteUint8(t0, t1, t2) {
      this.data = t0;
      this.numColors = t1;
      this.numChannels = t2;
    },
    Pixel: function Pixel() {
    },
    PixelUint8$imageData(image) {
      return new A.PixelUint8(-1, 0, -image.numChannels, image);
    },
    PixelUint8: function PixelUint8(t0, t1, t2, t3) {
      var _ = this;
      _._x = t0;
      _._y = t1;
      _._pixel_uint8$_index = t2;
      _.image = t3;
    },
    PixelUndefined: function PixelUndefined() {
    },
    ImageException$(message) {
      return new A.ImageException(message);
    },
    ImageException: function ImageException(t0) {
      this.message = t0;
    },
    NeuralQuantizer: function NeuralQuantizer(t0) {
      var _ = this;
      _.__NeuralQuantizer_palette_A = $;
      _.samplingFactor = 10;
      _.netSize = 16;
      _.specials = 3;
      _.__NeuralQuantizer_cutNetSize_A = _.__NeuralQuantizer_bgColor_A = $;
      _.maxNetPos = null;
      _.__NeuralQuantizer__palette_A = _.__NeuralQuantizer__network_A = _.__NeuralQuantizer__radiusPower_A = _.__NeuralQuantizer_initBiasRadius_A = _.__NeuralQuantizer_initRadius_A = $;
      _._netIndex = t0;
      _.__NeuralQuantizer__freq_A = _.__NeuralQuantizer__bias_A = $;
    },
    OutputBuffer$(bigEndian, size) {
      return new A.OutputBuffer(bigEndian, new Uint8Array(size));
    },
    OutputBuffer: function OutputBuffer(t0, t1) {
      this.length = 0;
      this.bigEndian = t0;
      this._buffer = t1;
    },
    Quantizer: function Quantizer() {
    },
    Rational: function Rational(t0, t1) {
      this.numerator = t0;
      this.denominator = t1;
    },
    convertRawImage(res, destroy$) {
      return A.convertRawImage$body(res, destroy$);
    },
    convertRawImage$body(res, destroy$) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.ThreadResponse),
        $async$returnValue, $async$handler = 2, $async$errorStack = [], bbox, croppedImage, bytes, croppedImage0, t1, t2, t3, exception, $async$exception;
      var $async$convertRawImage = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1) {
          $async$errorStack.push($async$result);
          $async$goto = $async$handler;
        }
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              $async$handler = 4;
              croppedImage0 = res.image;
              t1 = res.generateOnlyImageBounds;
              $async$goto = 7;
              return A._asyncAwait(A._findBoundingBox(destroy$, t1, croppedImage0), $async$convertRawImage);
            case 7:
              // returning from await.
              bbox = $async$result;
              $async$goto = 8;
              return A._asyncAwait(A._healthCheck(destroy$), $async$convertRawImage);
            case 8:
              // returning from await.
              $async$goto = t1 === true ? 9 : 10;
              break;
            case 9:
              // then
              t1 = bbox.left;
              t2 = bbox.top;
              t3 = bbox.width;
              $async$goto = 11;
              return A._asyncAwait(A._resizeCropRect(croppedImage0, destroy$, bbox.height, t1, t2, t3), $async$convertRawImage);
            case 11:
              // returning from await.
              croppedImage0 = $async$result;
            case 10:
              // join
              croppedImage = croppedImage0;
              $async$goto = 12;
              return A._asyncAwait(A._healthCheck(destroy$), $async$convertRawImage);
            case 12:
              // returning from await.
              $async$goto = 13;
              return A._asyncAwait(A.encodeImage(destroy$, croppedImage, res.jpegBackgroundColor, res.jpegChroma, res.jpegQuality, res.outputFormat, res.pngFilter, res.pngLevel, res.singleFrame), $async$convertRawImage);
            case 13:
              // returning from await.
              bytes = $async$result;
              $async$returnValue = new A.ThreadResponse(res.id, bytes);
              // goto return
              $async$goto = 1;
              break;
              $async$handler = 2;
              // goto after finally
              $async$goto = 6;
              break;
            case 4:
              // catch
              $async$handler = 3;
              $async$exception = $async$errorStack.pop();
              $async$returnValue = new A.ThreadResponse(res.id, null);
              // goto return
              $async$goto = 1;
              break;
              // goto after finally
              $async$goto = 6;
              break;
            case 3:
              // uncaught
              // goto rethrow
              $async$goto = 2;
              break;
            case 6:
              // after finally
            case 1:
              // return
              return A._asyncReturn($async$returnValue, $async$completer);
            case 2:
              // rethrow
              return A._asyncRethrow($async$errorStack.at(-1), $async$completer);
          }
      });
      return A._asyncStartSync($async$convertRawImage, $async$completer);
    },
    _healthCheck(destroy$) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.void),
        t1;
      var $async$_healthCheck = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              $async$goto = 2;
              return A._asyncAwait(A.Future_Future$delayed(B.Duration_10, type$.dynamic), $async$_healthCheck);
            case 2:
              // returning from await.
              t1 = destroy$.future._state;
              if ((t1 & 30) !== 0)
                throw A.wrapException(A.ArgumentError$("Kill thread", null));
              // implicit return
              return A._asyncReturn(null, $async$completer);
          }
      });
      return A._asyncStartSync($async$_healthCheck, $async$completer);
    },
    _findBoundingBox(destroy$, generateOnlyImageBounds, image) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$._BoundingBox),
        $async$returnValue, y, t1, x, t2, t3, pixel, bottom, right, left, $top, top0;
      var $async$_findBoundingBox = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              left = image.get$width();
              $top = image.get$height();
              top0 = 0;
              $async$goto = generateOnlyImageBounds === true ? 3 : 5;
              break;
            case 3:
              // then
              y = top0;
              $label0$0:
                for (;;) {
                  t1 = image.data;
                  t1 = t1 == null ? null : t1.height;
                  if (!(y < (t1 == null ? 0 : t1)))
                    break;
                  c$0: {
                    x = 0;
                    for (;;) {
                      t1 = image.data;
                      t2 = t1 == null;
                      t3 = t2 ? null : t1.width;
                      if (!(x < (t3 == null ? 0 : t3)))
                        break;
                      if (t2)
                        pixel = null;
                      else {
                        pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
                        pixel.setPosition$2(x, y);
                      }
                      if ((pixel == null ? new A.PixelUndefined() : pixel).get$a() !== 0) {
                        $top = y;
                        break $label0$0;
                      }
                      ++x;
                    }
                  }
                  ++y;
                }
              $async$goto = 6;
              return A._asyncAwait(A._healthCheck(destroy$), $async$_findBoundingBox);
            case 6:
              // returning from await.
              y = image.get$height() - 1;
              $label1$1:
                for (;;) {
                  if (!(y >= $top)) {
                    bottom = 0;
                    break;
                  }
                  c$1: {
                    x = 0;
                    for (;;) {
                      t1 = image.data;
                      t2 = t1 == null;
                      t3 = t2 ? null : t1.width;
                      if (!(x < (t3 == null ? 0 : t3)))
                        break;
                      if (t2)
                        pixel = null;
                      else {
                        pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
                        pixel.setPosition$2(x, y);
                      }
                      if ((pixel == null ? new A.PixelUndefined() : pixel).get$a() !== 0) {
                        t1 = image.data;
                        t1 = t1 == null ? null : t1.height;
                        bottom = B.JSInt_methods.clamp$2(y, $top, t1 == null ? 0 : t1);
                        break $label1$1;
                      }
                      ++x;
                    }
                  }
                  --y;
                }
              $async$goto = 7;
              return A._asyncAwait(A._healthCheck(destroy$), $async$_findBoundingBox);
            case 7:
              // returning from await.
              x = 0;
              $label2$2:
                for (;;) {
                  t1 = image.data;
                  t1 = t1 == null ? null : t1.width;
                  if (!(x < (t1 == null ? 0 : t1)))
                    break;
                  c$2:
                    for (y = $top; y <= bottom; ++y) {
                      t1 = image.data;
                      if (t1 == null)
                        pixel = null;
                      else {
                        pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
                        pixel.setPosition$2(x, y);
                      }
                      if ((pixel == null ? new A.PixelUndefined() : pixel).get$a() !== 0) {
                        t1 = image.data;
                        t1 = t1 == null ? null : t1.width;
                        left = B.JSInt_methods.clamp$2(x, 0, t1 == null ? 0 : t1);
                        break $label2$2;
                      }
                    }
                  ++x;
                }
              $async$goto = 8;
              return A._asyncAwait(A._healthCheck(destroy$), $async$_findBoundingBox);
            case 8:
              // returning from await.
              x = image.get$width() - 1;
              $label3$3:
                for (;;) {
                  if (!(x >= left)) {
                    right = 0;
                    break;
                  }
                  c$3:
                    for (y = $top; y <= bottom; ++y) {
                      t1 = image.data;
                      if (t1 == null)
                        pixel = null;
                      else {
                        pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
                        pixel.setPosition$2(x, y);
                      }
                      if ((pixel == null ? new A.PixelUndefined() : pixel).get$a() !== 0) {
                        t1 = image.data;
                        t1 = t1 == null ? null : t1.width;
                        right = B.JSInt_methods.clamp$2(x, left, t1 == null ? 0 : t1);
                        break $label3$3;
                      }
                    }
                  --x;
                }
              // goto join
              $async$goto = 4;
              break;
            case 5:
              // else
              right = image.get$width();
              bottom = image.get$height();
              $top = top0;
              left = 0;
            case 4:
              // join
              $async$returnValue = new A._BoundingBox(left, $top, right - left + 1, bottom - $top + 1);
              // goto return
              $async$goto = 1;
              break;
            case 1:
              // return
              return A._asyncReturn($async$returnValue, $async$completer);
          }
      });
      return A._asyncStartSync($async$_findBoundingBox, $async$completer);
    },
    _resizeCropRect(src, destroy$, height, left, $top, width) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.Image),
        $async$returnValue, numFrames, t1, firstFrame, i, value, frame, t2, dst, y, topY, x, pixel, t3, t4, t5, t6, t7, t8, index;
      var $async$_resizeCropRect = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          $async$outer:
            switch ($async$goto) {
              case 0:
                // Function start
                left = B.JSInt_methods.ceil$0(B.JSInt_methods.clamp$2(left, 0, src.get$width() - 1));
                $top = B.JSInt_methods.ceil$0(B.JSInt_methods.clamp$2($top, 0, src.get$height() - 1));
                if (left + width > src.get$width())
                  width = src.get$width() - left;
                if ($top + height > src.get$height())
                  height = src.get$height() - $top;
                numFrames = src.get$frames().length;
                t1 = type$.JSArray_Image, firstFrame = null, i = 0;
              case 3:
                // for condition
                if (!(i < numFrames)) {
                  // goto after for
                  $async$goto = 5;
                  break;
                }
                value = src.__Image_frames_AI;
                if (value === $)
                  value = src.__Image_frames_AI = A._setArrayType([], t1);
                if (!(i < value.length)) {
                  $async$returnValue = A.ioore(value, i);
                  // goto return
                  $async$goto = 1;
                  break;
                }
                frame = value[i];
                t2 = firstFrame == null;
                dst = t2 ? null : firstFrame.addFrame$0();
                if (dst == null)
                  dst = A.Image$fromResized(frame, height, true, width);
                if (t2)
                  firstFrame = dst;
                y = 0;
              case 6:
                // for condition
                if (!(y < height)) {
                  // goto after for
                  $async$goto = 8;
                  break;
                }
                topY = $top + y;
                for (x = 0; x < width; ++x) {
                  t2 = frame.data;
                  if (t2 == null)
                    pixel = null;
                  else {
                    pixel = new A.PixelUint8(-1, 0, -t2.numChannels, t2);
                    pixel.setPosition$2(left + x, topY);
                  }
                  if (pixel == null)
                    pixel = new A.PixelUndefined();
                  t2 = pixel.get$r();
                  t3 = pixel.get$g();
                  t4 = pixel.get$b();
                  t5 = pixel.get$a();
                  t6 = dst.data;
                  if (t6 != null) {
                    t7 = t6.width;
                    t8 = t6.numChannels;
                    index = y * (t7 * t8) + x * t8;
                    t6 = t6.data;
                    t2 = B.JSInt_methods.toInt$0(t2);
                    t6.$flags & 2 && A.throwUnsupportedOperation(t6);
                    t7 = t6.length;
                    if (!(index >= 0 && index < t7)) {
                      $async$returnValue = A.ioore(t6, index);
                      // goto return
                      $async$goto = 1;
                      break $async$outer;
                    }
                    t6[index] = t2;
                    if (t8 > 1) {
                      t2 = index + 1;
                      t3 = B.JSInt_methods.toInt$0(t3);
                      if (!(t2 < t7)) {
                        $async$returnValue = A.ioore(t6, t2);
                        // goto return
                        $async$goto = 1;
                        break $async$outer;
                      }
                      t6[t2] = t3;
                      if (t8 > 2) {
                        t2 = index + 2;
                        t4 = B.JSInt_methods.toInt$0(t4);
                        if (!(t2 < t7)) {
                          $async$returnValue = A.ioore(t6, t2);
                          // goto return
                          $async$goto = 1;
                          break $async$outer;
                        }
                        t6[t2] = t4;
                        if (t8 > 3) {
                          t2 = index + 3;
                          t5 = B.JSInt_methods.toInt$0(t5);
                          if (!(t2 < t7)) {
                            $async$returnValue = A.ioore(t6, t2);
                            // goto return
                            $async$goto = 1;
                            break $async$outer;
                          }
                          t6[t2] = t5;
                        }
                      }
                    }
                  }
                }
                $async$goto = B.JSInt_methods.$mod(y, 100) === 0 ? 9 : 10;
                break;
              case 9:
                // then
                $async$goto = 11;
                return A._asyncAwait(A._healthCheck(destroy$), $async$_resizeCropRect);
              case 11:
                // returning from await.
              case 10:
                // join
              case 7:
                // for update
                ++y;
                // goto for condition
                $async$goto = 6;
                break;
              case 8:
                // after for
              case 4:
                // for update
                ++i;
                // goto for condition
                $async$goto = 3;
                break;
              case 5:
                // after for
                firstFrame.toString;
                $async$returnValue = firstFrame;
                // goto return
                $async$goto = 1;
                break;
              case 1:
                // return
                return A._asyncReturn($async$returnValue, $async$completer);
            }
      });
      return A._asyncStartSync($async$_resizeCropRect, $async$completer);
    },
    _BoundingBox: function _BoundingBox(t0, t1, t2, t3) {
      var _ = this;
      _.left = t0;
      _.top = t1;
      _.width = t2;
      _.height = t3;
    },
    jsGetProperty(obj, propertyName) {
      var t1 = init.G,
        descriptor = A._asJSObjectQ(t1.Object.getOwnPropertyDescriptor(obj, propertyName));
      if (descriptor == null)
        return null;
      return t1.Reflect.get(descriptor, "value");
    },
    jsify(dartObject) {
      var t1, result;
      if (dartObject == null)
        return null;
      if (type$.Uint8List._is(dartObject))
        return type$.NativeArrayBuffer._as(B.NativeUint8List_methods.get$buffer(dartObject));
      if (type$.List_dynamic._is(dartObject)) {
        t1 = J.map$1$1$ax(dartObject, A.web_worker_utils__jsify$closure(), type$.nullable_Object);
        t1 = A.List_List$_of(t1, t1.$ti._eval$1("ListIterable.E"));
        return t1;
      }
      if (type$.Map_dynamic_dynamic._is(dartObject)) {
        t1 = type$.nullable_Object;
        return A.jsify0(dartObject.map$2$1(0, new A.jsify_closure(), t1, t1));
      }
      if (type$.Object_Function._is(dartObject)) {
        if (typeof dartObject == "function")
          A.throwExpression(A.ArgumentError$("Attempting to rewrap a JS function.", null));
        result = function(_call, f) {
          return function() {
            return _call(f);
          };
        }(A._callDartFunctionFast0, dartObject);
        result[$.$get$DART_CLOSURE_PROPERTY_NAME()] = dartObject;
        return result;
      }
      return A.jsify0(dartObject);
    },
    jsify_closure: function jsify_closure() {
    },
    main() {
      new A.WebWorkerManager(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.Completer_void))._init$0();
    },
    WebWorkerManager: function WebWorkerManager(t0) {
      this.tasks = t0;
    },
    WebWorkerManager__init_closure: function WebWorkerManager__init_closure(t0) {
      this.$this = t0;
    },
    WebWorkerManager__handleConvert_closure: function WebWorkerManager__handleConvert_closure() {
    },
    WebWorkerManager__handleConvert_closure0: function WebWorkerManager__handleConvert_closure0(t0, t1) {
      this.$this = t0;
      this.id = t1;
    },
    WebWorkerManager__handleDestroyActiveTasks_closure: function WebWorkerManager__handleDestroyActiveTasks_closure(t0) {
      this.ignoreTaskId = t0;
    },
    Uint32List_Uint32List$view(buffer) {
      return J.asUint32List$2$x(buffer, 0, null);
    },
    getAdler32Stream(stream) {
      var s1, s2, n, t1, t2,
        len = stream.get$length(0);
      for (s1 = 1, s2 = 0; len > 0;) {
        n = 3800 > len ? len : 3800;
        len -= n;
        while (--n, n >= 0) {
          t1 = stream.buffer;
          t1.toString;
          t2 = stream._position++;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          s1 += t1[t2];
          s2 += s1;
        }
        s1 = B.JSInt_methods.$mod(s1, 65521);
        s2 = B.JSInt_methods.$mod(s2, 65521);
      }
      return (s2 << 16 | s1) >>> 0;
    },
    getCrc32(array, crc) {
      var ip, ip0,
        t1 = J.getInterceptor$asx(array),
        len = t1.get$length(array);
      crc ^= 4294967295;
      for (ip = 0; len >= 8;) {
        ip0 = ip + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip)) & 255] ^ crc >>> 8;
        ip = ip0 + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip0)) & 255] ^ crc >>> 8;
        ip0 = ip + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip)) & 255] ^ crc >>> 8;
        ip = ip0 + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip0)) & 255] ^ crc >>> 8;
        ip0 = ip + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip)) & 255] ^ crc >>> 8;
        ip = ip0 + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip0)) & 255] ^ crc >>> 8;
        ip0 = ip + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip)) & 255] ^ crc >>> 8;
        ip = ip0 + 1;
        crc = B.List_kC8[(crc ^ t1.$index(array, ip0)) & 255] ^ crc >>> 8;
        len -= 8;
      }
      if (len > 0)
        do {
          ip0 = ip + 1;
          crc = B.List_kC8[(crc ^ t1.$index(array, ip)) & 255] ^ crc >>> 8;
          if (--len, len > 0) {
            ip = ip0;
            continue;
          } else
            break;
        } while (true);
      return (crc ^ 4294967295) >>> 0;
    },
    _convertColor(c, c2, a) {
      var cl, g, ci, l, v,
        numChannels = c2.get$length(c2),
        format = c2.get$format(),
        fromFormat = c.get$palette() == null ? null : B.Format_3;
      if (fromFormat == null)
        fromFormat = c.get$format();
      cl = c.get$length(c);
      if (numChannels === 1) {
        g = c.get$length(c) > 2 ? c.get$luminance() : c.$index(0, 0);
        c2.$indexSet(0, 0, A.convertFormatValue(A._isInt(c.$index(0, 0)) ? B.JSNumber_methods.floor$0(g) : g, fromFormat, format));
      } else if (numChannels <= cl)
        for (ci = 0; ci < numChannels; ++ci)
          c2.$indexSet(0, ci, A.convertFormatValue(c.$index(0, ci), fromFormat, format));
      else if (cl === 2) {
        l = A.convertFormatValue(c.$index(0, 0), fromFormat, format);
        if (numChannels === 3) {
          c2.$indexSet(0, 0, l);
          c2.$indexSet(0, 1, l);
          c2.$indexSet(0, 2, l);
        } else {
          a = A.convertFormatValue(c.$index(0, 1), fromFormat, format);
          c2.$indexSet(0, 0, l);
          c2.$indexSet(0, 1, l);
          c2.$indexSet(0, 2, l);
          c2.$indexSet(0, 3, a);
        }
      } else {
        for (ci = 0; ci < cl; ++ci)
          c2.$indexSet(0, ci, A.convertFormatValue(c.$index(0, ci), fromFormat, format));
        v = cl === 1 ? c2.$index(0, 0) : 0;
        for (ci = cl; ci < numChannels; ++ci)
          c2.$indexSet(0, ci, ci === 3 ? a : v);
      }
      return c2;
    },
    convertColor(c, alpha, format, numChannels, to) {
      var t1, t2, c2,
        fromFormat = c.get$palette() == null ? null : B.Format_3;
      if (fromFormat == null)
        fromFormat = c.get$format();
      t1 = to == null;
      t2 = t1 ? null : to.get$format();
      format = t2 == null ? format : t2;
      if (format == null)
        format = c.get$format();
      t2 = t1 ? null : to.get$length(to);
      numChannels = t2 == null ? numChannels : t2;
      if (numChannels == null)
        numChannels = c.get$length(c);
      if (alpha == null)
        alpha = 0;
      if (format === fromFormat && numChannels === c.get$length(c)) {
        if (t1)
          return c.clone$0();
        to.$set$1(c);
        return to;
      }
      switch (format.index) {
        case 3:
          if (t1)
            c2 = new A.ColorUint8(new Uint8Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 0:
          return A._convertColor(c, t1 ? new A.ColorUint1(numChannels, 0) : to, alpha);
        case 1:
          return A._convertColor(c, t1 ? new A.ColorUint2(numChannels, 0) : to, alpha);
        case 2:
          if (t1) {
            t1 = numChannels < 3 ? 1 : 2;
            c2 = new A.ColorUint4(numChannels, new Uint8Array(t1));
          } else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 4:
          if (t1)
            c2 = new A.ColorUint16(new Uint16Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 5:
          if (t1)
            c2 = new A.ColorUint32(new Uint32Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 6:
          if (t1)
            c2 = new A.ColorInt8(new Int8Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 7:
          if (t1)
            c2 = new A.ColorInt16(new Int16Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 8:
          if (t1)
            c2 = new A.ColorInt32(new Int32Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 9:
          if (t1)
            c2 = new A.ColorFloat16(new Uint16Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 10:
          if (t1)
            c2 = new A.ColorFloat32(new Float32Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
        case 11:
          if (t1)
            c2 = new A.ColorFloat64(new Float64Array(numChannels));
          else
            c2 = to;
          return A._convertColor(c, c2, alpha);
      }
    },
    getLuminance(c) {
      return 0.299 * c.get$r() + 0.587 * c.get$g() + 0.114 * c.get$b();
    },
    Float16_doubleToFloat16(n) {
      var xI, e, m,
        t1 = $.$get$__float32();
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      t1[0] = n;
      t1 = $.$get$__float32ToUint32();
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      xI = t1[0];
      if (n === 0)
        return xI >>> 16;
      if ($.Float16__toFloatFloat32Data == null)
        A.Float16__initialize();
      e = xI >>> 23 & 511;
      t1 = $.Float16____eLut._readField$0();
      if (!(e < t1.length))
        return A.ioore(t1, e);
      e = t1[e];
      if (e !== 0) {
        m = xI & 8388607;
        return e + (m + 4095 + (m >>> 13 & 1) >>> 13);
      }
      return A.Float16__convert(xI);
    },
    Float16__convert(i) {
      var t, t1,
        s = i >>> 16 & 32768,
        e = (i >>> 23 & 255) - 112,
        m = i & 8388607;
      if (e <= 0) {
        if (e < -10)
          return s;
        m |= 8388608;
        t = 14 - e;
        return (s | B.JSInt_methods.$shr(m + (B.JSInt_methods.$shl(1, t - 1) - 1) + (B.JSInt_methods._shrReceiverPositive$1(m, t) & 1), t)) >>> 0;
      } else if (e === 143)
        if (m === 0)
          return s | 31744;
        else {
          m = m >>> 13;
          t1 = m === 0 ? 1 : 0;
          return s | m | t1 | 31744;
        }
      else {
        m = m + 4095 + (m >>> 13 & 1);
        if ((m & 8388608) !== 0) {
          ++e;
          m = 0;
        }
        if (e > 30)
          return s | 31744;
        return (s | e << 10 | m >>> 13) >>> 0;
      }
    },
    Float16__initialize() {
      var floatUint32Data, i, e, t2, t3,
        t1 = $.Float16__toFloatFloat32Data;
      if (t1 != null)
        return t1;
      floatUint32Data = new Uint32Array(65536);
      $.Float16__toFloatFloat32Data = J.asFloat32List$2$x(B.NativeUint32List_methods.get$buffer(floatUint32Data), 0, null);
      t1 = new Uint16Array(512);
      $.Float16____eLut._value = t1;
      for (i = 0; i < 256; ++i) {
        e = (i & 255) - 112;
        if (e <= 0 || e >= 30) {
          t1[i] = 0;
          t2 = (i | 256) >>> 0;
          if (!(t2 < 512))
            return A.ioore(t1, t2);
          t1[t2] = 0;
        } else {
          t2 = e << 10 >>> 0;
          t1[i] = t2;
          t3 = (i | 256) >>> 0;
          if (!(t3 < 512))
            return A.ioore(t1, t3);
          t1[t3] = (t2 | 32768) >>> 0;
        }
      }
      for (i = 0; i < 65536; ++i)
        floatUint32Data[i] = A.Float16__halfToFloat(i);
      t1 = $.Float16__toFloatFloat32Data;
      t1.toString;
      return t1;
    },
    Float16__halfToFloat(y) {
      var t1,
        s = y >>> 15 & 1,
        e = y >>> 10 & 31,
        m = y & 1023;
      if (e === 0)
        if (m === 0)
          return s << 31 >>> 0;
        else {
          while ((m & 1024) === 0) {
            m = m << 1;
            --e;
          }
          ++e;
          m &= 4294966271;
        }
      else if (e === 31) {
        t1 = s << 31;
        if (m === 0)
          return (t1 | 2139095040) >>> 0;
        else
          return (t1 | m << 13 | 2139095040) >>> 0;
      }
      return (s << 31 | e + 112 << 23 | m << 13) >>> 0;
    },
    encodeImage(destroy$, image, jpegBackgroundColor, jpegChroma, jpegQuality, outputFormat, pngFilter, pngLevel, singleFrame) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.Uint8List),
        $async$returnValue, t1, t2, t3, t4, t5, t6, t7, t8, bytes;
      var $async$encodeImage = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
            case 3:
              // switch
              switch (outputFormat.index) {
                case 0:
                  // goto case
                  $async$goto = 5;
                  break;
                case 1:
                  // goto case
                  $async$goto = 6;
                  break;
                case 2:
                  // goto case
                  $async$goto = 7;
                  break;
                case 3:
                  // goto case
                  $async$goto = 8;
                  break;
                case 4:
                  // goto case
                  $async$goto = 9;
                  break;
                case 5:
                  // goto case
                  $async$goto = 10;
                  break;
                case 6:
                  // goto case
                  $async$goto = 11;
                  break;
                case 7:
                  // goto case
                  $async$goto = 12;
                  break;
                default:
                  // goto default
                  $async$goto = 13;
                  break;
              }
              break;
            case 5:
              // case
              t1 = new Uint8Array(64);
              t2 = new Uint8Array(64);
              t3 = new Float32Array(64);
              t4 = new Float32Array(64);
              t5 = A.List_List$filled(65535, null, false, type$.nullable_List_int);
              t6 = type$.nullable_int;
              t7 = A.List_List$filled(65535, null, false, t6);
              t8 = A.List_List$filled(64, null, false, t6);
              t6 = A.List_List$filled(64, null, false, t6);
              t1 = new A.JpegHealthyEncoder(t1, t2, t3, t4, t5, t7, t8, t6, new Int32Array(2048));
              t1._ydcHuffman = t1._computeHuffmanTable$2(B.List_zcj, B.List_74c);
              t1._uvdcHuffman = t1._computeHuffmanTable$2(B.List_NZS, B.List_74c);
              t2 = type$.List_nullable_List_int;
              t1.__JpegHealthyEncoder__yacHuffman_A = t2._as(t1._computeHuffmanTable$2(B.List_2BR, B.List_CZS));
              t1.__JpegHealthyEncoder__uvacHuffman_A = t2._as(t1._computeHuffmanTable$2(B.List_GUW, B.List_X1N));
              t1._initCategoryNumber$0();
              t1._initRgbYuvTable$0();
              t1.setQuality$1(jpegQuality);
              $async$goto = 14;
              return A._asyncAwait(t1.encode$4$backgroundColor$chroma$destroy$(image, jpegBackgroundColor, jpegChroma, destroy$), $async$encodeImage);
            case 14:
              // returning from await.
              bytes = $async$result;
              // goto after switch
              $async$goto = 4;
              break;
            case 6:
              // case
              bytes = new A.PngEncoder(pngFilter, pngLevel).encode$2$singleFrame(image, singleFrame);
              // goto after switch
              $async$goto = 4;
              break;
            case 7:
              // case
              bytes = new A.TiffEncoder().encode$2$singleFrame(image, singleFrame);
              // goto after switch
              $async$goto = 4;
              break;
            case 8:
              // case
              bytes = new A.BmpEncoder().encode$1(image);
              // goto after switch
              $async$goto = 4;
              break;
            case 9:
              // case
              bytes = new A.CurEncoder().encode$2$singleFrame(image, singleFrame);
              // goto after switch
              $async$goto = 4;
              break;
            case 10:
              // case
              bytes = new A.PvrEncoder().encode$2$singleFrame(image, singleFrame);
              // goto after switch
              $async$goto = 4;
              break;
            case 11:
              // case
              bytes = new A.TgaEncoder().encode$1(image);
              // goto after switch
              $async$goto = 4;
              break;
            case 12:
              // case
              bytes = new A.IcoEncoder().encode$2$singleFrame(image, singleFrame);
              // goto after switch
              $async$goto = 4;
              break;
            case 13:
              // default
              bytes = null;
            case 4:
              // after switch
              $async$returnValue = bytes;
              // goto return
              $async$goto = 1;
              break;
            case 1:
              // return
              return A._asyncReturn($async$returnValue, $async$completer);
          }
      });
      return A._asyncStartSync($async$encodeImage, $async$completer);
    }
  },
  B = {};
  var holders = [A, J, B];
  var $ = {};
  A.JS_CONST.prototype = {};
  J.Interceptor.prototype = {
    $eq(receiver, other) {
      return receiver === other;
    },
    get$hashCode(receiver) {
      return A.Primitives_objectHashCode(receiver);
    },
    toString$0(receiver) {
      return "Instance of '" + A.Primitives_objectTypeName(receiver) + "'";
    },
    get$runtimeType(receiver) {
      return A.createRuntimeType(A._instanceTypeFromConstructor(this));
    }
  };
  J.JSBool.prototype = {
    toString$0(receiver) {
      return String(receiver);
    },
    get$hashCode(receiver) {
      return receiver ? 519018 : 218159;
    },
    get$runtimeType(receiver) {
      return A.createRuntimeType(type$.bool);
    },
    $isTrustedGetRuntimeType: 1,
    $isbool: 1
  };
  J.JSNull.prototype = {
    $eq(receiver, other) {
      return null == other;
    },
    toString$0(receiver) {
      return "null";
    },
    get$hashCode(receiver) {
      return 0;
    },
    $isTrustedGetRuntimeType: 1,
    $isNull: 1
  };
  J.JavaScriptObject.prototype = {$isJSObject: 1};
  J.LegacyJavaScriptObject.prototype = {
    get$hashCode(receiver) {
      return 0;
    },
    toString$0(receiver) {
      return String(receiver);
    }
  };
  J.PlainJavaScriptObject.prototype = {};
  J.UnknownJavaScriptObject.prototype = {};
  J.JavaScriptFunction.prototype = {
    toString$0(receiver) {
      var dartClosure = receiver[$.$get$DART_CLOSURE_PROPERTY_NAME()];
      if (dartClosure == null)
        return this.super$LegacyJavaScriptObject$toString(receiver);
      return "JavaScript function for " + J.toString$0$(dartClosure);
    },
    $isFunction: 1
  };
  J.JavaScriptBigInt.prototype = {
    get$hashCode(receiver) {
      return 0;
    },
    toString$0(receiver) {
      return String(receiver);
    }
  };
  J.JavaScriptSymbol.prototype = {
    get$hashCode(receiver) {
      return 0;
    },
    toString$0(receiver) {
      return String(receiver);
    }
  };
  J.JSArray.prototype = {
    add$1(receiver, value) {
      A._arrayInstanceType(receiver)._precomputed1._as(value);
      receiver.$flags & 1 && A.throwUnsupportedOperation(receiver, 29);
      receiver.push(value);
    },
    addAll$1(receiver, collection) {
      var t1;
      A._arrayInstanceType(receiver)._eval$1("Iterable<1>")._as(collection);
      receiver.$flags & 1 && A.throwUnsupportedOperation(receiver, "addAll", 2);
      for (t1 = collection.get$iterator(collection); t1.moveNext$0();)
        receiver.push(t1.get$current());
    },
    map$1$1(receiver, f, $T) {
      var t1 = A._arrayInstanceType(receiver);
      return new A.MappedListIterable(receiver, t1._bind$1($T)._eval$1("1(2)")._as(f), t1._eval$1("@<1>")._bind$1($T)._eval$1("MappedListIterable<1,2>"));
    },
    firstWhere$1(receiver, test) {
      var end, i, element;
      A._arrayInstanceType(receiver)._eval$1("bool(1)")._as(test);
      end = receiver.length;
      for (i = 0; i < end; ++i) {
        element = receiver[i];
        if (test.call$1(element))
          return element;
        if (receiver.length !== end)
          throw A.wrapException(A.ConcurrentModificationError$(receiver));
      }
      throw A.wrapException(A.IterableElementError_noElement());
    },
    elementAt$1(receiver, index) {
      if (!(index >= 0 && index < receiver.length))
        return A.ioore(receiver, index);
      return receiver[index];
    },
    get$last(receiver) {
      var t1 = receiver.length;
      if (t1 > 0)
        return receiver[t1 - 1];
      throw A.wrapException(A.IterableElementError_noElement());
    },
    toString$0(receiver) {
      return A.Iterable_iterableToFullString(receiver, "[", "]");
    },
    get$iterator(receiver) {
      return new J.ArrayIterator(receiver, receiver.length, A._arrayInstanceType(receiver)._eval$1("ArrayIterator<1>"));
    },
    get$hashCode(receiver) {
      return A.Primitives_objectHashCode(receiver);
    },
    get$length(receiver) {
      return receiver.length;
    },
    set$length(receiver, newLength) {
      receiver.$flags & 1 && A.throwUnsupportedOperation(receiver, "set length", "change the length of");
      if (newLength > receiver.length)
        A._arrayInstanceType(receiver)._precomputed1._as(null);
      receiver.length = newLength;
    },
    $index(receiver, index) {
      if (!(index >= 0 && index < receiver.length))
        throw A.wrapException(A.diagnoseIndexError(receiver, index));
      return receiver[index];
    },
    $indexSet(receiver, index, value) {
      A._arrayInstanceType(receiver)._precomputed1._as(value);
      receiver.$flags & 2 && A.throwUnsupportedOperation(receiver);
      if (!(index >= 0 && index < receiver.length))
        throw A.wrapException(A.diagnoseIndexError(receiver, index));
      receiver[index] = value;
    },
    $isEfficientLengthIterable: 1,
    $isIterable: 1,
    $isList: 1
  };
  J.JSArraySafeToStringHook.prototype = {
    tryFormat$1(array) {
      var flags, info, base;
      if (!Array.isArray(array))
        return null;
      flags = array.$flags | 0;
      if ((flags & 4) !== 0)
        info = "const, ";
      else if ((flags & 2) !== 0)
        info = "unmodifiable, ";
      else
        info = (flags & 1) !== 0 ? "fixed, " : "";
      base = "Instance of '" + A.Primitives_objectTypeName(array) + "'";
      if (info === "")
        return base;
      return base + " (" + info + "length: " + array.length + ")";
    }
  };
  J.JSUnmodifiableArray.prototype = {};
  J.ArrayIterator.prototype = {
    get$current() {
      var t1 = this._current;
      return t1 == null ? this.$ti._precomputed1._as(t1) : t1;
    },
    moveNext$0() {
      var t2, _this = this,
        t1 = _this._iterable,
        $length = t1.length;
      if (_this._length !== $length) {
        t1 = A.throwConcurrentModificationError(t1);
        throw A.wrapException(t1);
      }
      t2 = _this._index;
      if (t2 >= $length) {
        _this._current = null;
        return false;
      }
      _this._current = t1[t2];
      _this._index = t2 + 1;
      return true;
    },
    $isIterator: 1
  };
  J.JSNumber.prototype = {
    compareTo$1(receiver, b) {
      var bIsNegative;
      if (receiver < b)
        return -1;
      else if (receiver > b)
        return 1;
      else if (receiver === b) {
        if (receiver === 0) {
          bIsNegative = B.JSInt_methods.get$isNegative(b);
          if (this.get$isNegative(receiver) === bIsNegative)
            return 0;
          if (this.get$isNegative(receiver))
            return -1;
          return 1;
        }
        return 0;
      } else if (isNaN(receiver)) {
        if (isNaN(b))
          return 0;
        return 1;
      } else
        return -1;
    },
    get$isNegative(receiver) {
      return receiver === 0 ? 1 / receiver < 0 : receiver < 0;
    },
    toInt$0(receiver) {
      var t1;
      if (receiver >= -2147483648 && receiver <= 2147483647)
        return receiver | 0;
      if (isFinite(receiver)) {
        t1 = receiver < 0 ? Math.ceil(receiver) : Math.floor(receiver);
        return t1 + 0;
      }
      throw A.wrapException(A.UnsupportedError$("" + receiver + ".toInt()"));
    },
    ceil$0(receiver) {
      var truncated, d;
      if (receiver >= 0) {
        if (receiver <= 2147483647) {
          truncated = receiver | 0;
          return receiver === truncated ? truncated : truncated + 1;
        }
      } else if (receiver >= -2147483648)
        return receiver | 0;
      d = Math.ceil(receiver);
      if (isFinite(d))
        return d;
      throw A.wrapException(A.UnsupportedError$("" + receiver + ".ceil()"));
    },
    floor$0(receiver) {
      var truncated, d;
      if (receiver >= 0) {
        if (receiver <= 2147483647)
          return receiver | 0;
      } else if (receiver >= -2147483648) {
        truncated = receiver | 0;
        return receiver === truncated ? truncated : truncated - 1;
      }
      d = Math.floor(receiver);
      if (isFinite(d))
        return d;
      throw A.wrapException(A.UnsupportedError$("" + receiver + ".floor()"));
    },
    round$0(receiver) {
      if (receiver > 0) {
        if (receiver !== 1 / 0)
          return Math.round(receiver);
      } else if (receiver > -1 / 0)
        return 0 - Math.round(0 - receiver);
      throw A.wrapException(A.UnsupportedError$("" + receiver + ".round()"));
    },
    clamp$2(receiver, lowerLimit, upperLimit) {
      if (B.JSInt_methods.compareTo$1(lowerLimit, upperLimit) > 0)
        throw A.wrapException(A.argumentErrorValue(lowerLimit));
      if (this.compareTo$1(receiver, lowerLimit) < 0)
        return lowerLimit;
      if (this.compareTo$1(receiver, upperLimit) > 0)
        return upperLimit;
      return receiver;
    },
    toString$0(receiver) {
      if (receiver === 0 && 1 / receiver < 0)
        return "-0.0";
      else
        return "" + receiver;
    },
    get$hashCode(receiver) {
      var absolute, floorLog2, factor, scaled,
        intValue = receiver | 0;
      if (receiver === intValue)
        return intValue & 536870911;
      absolute = Math.abs(receiver);
      floorLog2 = Math.log(absolute) / 0.6931471805599453 | 0;
      factor = Math.pow(2, floorLog2);
      scaled = absolute < 1 ? absolute / factor : factor / absolute;
      return ((scaled * 9007199254740992 | 0) + (scaled * 3542243181176521 | 0)) * 599197 + floorLog2 * 1259 & 536870911;
    },
    $mod(receiver, other) {
      var result = receiver % other;
      if (result === 0)
        return 0;
      if (result > 0)
        return result;
      if (other < 0)
        return result - other;
      else
        return result + other;
    },
    $tdiv(receiver, other) {
      if ((receiver | 0) === receiver)
        if (other >= 1 || other < -1)
          return receiver / other | 0;
      return this._tdivSlow$1(receiver, other);
    },
    _tdivFast$1(receiver, other) {
      return (receiver | 0) === receiver ? receiver / other | 0 : this._tdivSlow$1(receiver, other);
    },
    _tdivSlow$1(receiver, other) {
      var quotient = receiver / other;
      if (quotient >= -2147483648 && quotient <= 2147483647)
        return quotient | 0;
      if (quotient > 0) {
        if (quotient !== 1 / 0)
          return Math.floor(quotient);
      } else if (quotient > -1 / 0)
        return Math.ceil(quotient);
      throw A.wrapException(A.UnsupportedError$("Result of truncating division is " + A.S(quotient) + ": " + A.S(receiver) + " ~/ " + other));
    },
    $shl(receiver, other) {
      if (other < 0)
        throw A.wrapException(A.argumentErrorValue(other));
      return other > 31 ? 0 : receiver << other >>> 0;
    },
    _shlPositive$1(receiver, other) {
      return other > 31 ? 0 : receiver << other >>> 0;
    },
    $shr(receiver, other) {
      var t1;
      if (other < 0)
        throw A.wrapException(A.argumentErrorValue(other));
      if (receiver > 0)
        t1 = this._shrBothPositive$1(receiver, other);
      else {
        t1 = other > 31 ? 31 : other;
        t1 = receiver >> t1 >>> 0;
      }
      return t1;
    },
    _shrOtherPositive$1(receiver, other) {
      var t1;
      if (receiver > 0)
        t1 = this._shrBothPositive$1(receiver, other);
      else {
        t1 = other > 31 ? 31 : other;
        t1 = receiver >> t1 >>> 0;
      }
      return t1;
    },
    _shrReceiverPositive$1(receiver, other) {
      if (0 > other)
        throw A.wrapException(A.argumentErrorValue(other));
      return this._shrBothPositive$1(receiver, other);
    },
    _shrBothPositive$1(receiver, other) {
      return other > 31 ? 0 : receiver >>> other;
    },
    get$runtimeType(receiver) {
      return A.createRuntimeType(type$.num);
    },
    $isdouble: 1,
    $isnum: 1
  };
  J.JSInt.prototype = {
    get$runtimeType(receiver) {
      return A.createRuntimeType(type$.int);
    },
    $isTrustedGetRuntimeType: 1,
    $isint: 1
  };
  J.JSNumNotInt.prototype = {
    get$runtimeType(receiver) {
      return A.createRuntimeType(type$.double);
    },
    $isTrustedGetRuntimeType: 1
  };
  J.JSString.prototype = {
    $mul(receiver, times) {
      var s, result;
      if (0 >= times)
        return "";
      if (times === 1 || receiver.length === 0)
        return receiver;
      if (times !== times >>> 0)
        throw A.wrapException(B.C_OutOfMemoryError);
      for (s = receiver, result = "";;) {
        if ((times & 1) === 1)
          result = s + result;
        times = times >>> 1;
        if (times === 0)
          break;
        s += s;
      }
      return result;
    },
    padLeft$2(receiver, width, padding) {
      var delta = width - receiver.length;
      if (delta <= 0)
        return receiver;
      return this.$mul(padding, delta) + receiver;
    },
    toString$0(receiver) {
      return receiver;
    },
    get$hashCode(receiver) {
      var t1, hash, i;
      for (t1 = receiver.length, hash = 0, i = 0; i < t1; ++i) {
        hash = hash + receiver.charCodeAt(i) & 536870911;
        hash = hash + ((hash & 524287) << 10) & 536870911;
        hash ^= hash >> 6;
      }
      hash = hash + ((hash & 67108863) << 3) & 536870911;
      hash ^= hash >> 11;
      return hash + ((hash & 16383) << 15) & 536870911;
    },
    get$runtimeType(receiver) {
      return A.createRuntimeType(type$.String);
    },
    get$length(receiver) {
      return receiver.length;
    },
    $isTrustedGetRuntimeType: 1,
    $isString: 1
  };
  A.LateError.prototype = {
    toString$0(_) {
      return "LateInitializationError: " + this.__internal$_message;
    }
  };
  A.CodeUnits.prototype = {
    get$length(_) {
      return this._string.length;
    },
    $index(_, i) {
      var t1 = this._string;
      if (!(i >= 0 && i < t1.length))
        return A.ioore(t1, i);
      return t1.charCodeAt(i);
    }
  };
  A.SentinelValue.prototype = {};
  A.EfficientLengthIterable.prototype = {};
  A.ListIterable.prototype = {
    get$iterator(_) {
      var _this = this;
      return new A.ListIterator(_this, _this.get$length(_this), A._instanceType(_this)._eval$1("ListIterator<ListIterable.E>"));
    },
    map$1$1(_, toElement, $T) {
      var t1 = A._instanceType(this);
      return new A.MappedListIterable(this, t1._bind$1($T)._eval$1("1(ListIterable.E)")._as(toElement), t1._eval$1("@<ListIterable.E>")._bind$1($T)._eval$1("MappedListIterable<1,2>"));
    }
  };
  A.ListIterator.prototype = {
    get$current() {
      var t1 = this.__internal$_current;
      return t1 == null ? this.$ti._precomputed1._as(t1) : t1;
    },
    moveNext$0() {
      var t3, _this = this,
        t1 = _this.__internal$_iterable,
        t2 = J.getInterceptor$asx(t1),
        $length = t2.get$length(t1);
      if (_this.__internal$_length !== $length)
        throw A.wrapException(A.ConcurrentModificationError$(t1));
      t3 = _this.__internal$_index;
      if (t3 >= $length) {
        _this.__internal$_current = null;
        return false;
      }
      _this.__internal$_current = t2.elementAt$1(t1, t3);
      ++_this.__internal$_index;
      return true;
    },
    $isIterator: 1
  };
  A.MappedIterable.prototype = {
    get$iterator(_) {
      var t1 = this.__internal$_iterable;
      return new A.MappedIterator(t1.get$iterator(t1), this._f, A._instanceType(this)._eval$1("MappedIterator<1,2>"));
    },
    get$length(_) {
      var t1 = this.__internal$_iterable;
      return t1.get$length(t1);
    }
  };
  A.EfficientLengthMappedIterable.prototype = {$isEfficientLengthIterable: 1};
  A.MappedIterator.prototype = {
    moveNext$0() {
      var _this = this,
        t1 = _this._iterator;
      if (t1.moveNext$0()) {
        _this.__internal$_current = _this._f.call$1(t1.get$current());
        return true;
      }
      _this.__internal$_current = null;
      return false;
    },
    get$current() {
      var t1 = this.__internal$_current;
      return t1 == null ? this.$ti._rest[1]._as(t1) : t1;
    },
    $isIterator: 1
  };
  A.MappedListIterable.prototype = {
    get$length(_) {
      return J.get$length$asx(this._source);
    },
    elementAt$1(_, index) {
      return this._f.call$1(J.elementAt$1$ax(this._source, index));
    }
  };
  A.FixedLengthListMixin.prototype = {};
  A.UnmodifiableListMixin.prototype = {
    $indexSet(_, index, value) {
      A._instanceType(this)._eval$1("UnmodifiableListMixin.E")._as(value);
      throw A.wrapException(A.UnsupportedError$("Cannot modify an unmodifiable list"));
    }
  };
  A.UnmodifiableListBase.prototype = {};
  A.ConstantMap.prototype = {
    toString$0(_) {
      return A.MapBase_mapToString(this);
    },
    map$2$1(_, transform, $K2, $V2) {
      var result = A.LinkedHashMap_LinkedHashMap$_empty($K2, $V2);
      this.forEach$1(0, new A.ConstantMap_map_closure(this, A._instanceType(this)._bind$1($K2)._bind$1($V2)._eval$1("MapEntry<1,2>(3,4)")._as(transform), result));
      return result;
    },
    $isMap: 1
  };
  A.ConstantMap_map_closure.prototype = {
    call$2(key, value) {
      var t1 = A._instanceType(this.$this),
        entry = this.transform.call$2(t1._precomputed1._as(key), t1._rest[1]._as(value));
      this.result.$indexSet(0, entry.key, entry.value);
    },
    $signature() {
      return A._instanceType(this.$this)._eval$1("~(1,2)");
    }
  };
  A.ConstantStringMap.prototype = {
    get$length(_) {
      return this._values.length;
    },
    get$__js_helper$_keys() {
      var keys = this.$keys;
      if (keys == null) {
        keys = Object.keys(this._jsIndex);
        this.$keys = keys;
      }
      return keys;
    },
    containsKey$1(key) {
      if (typeof key != "string")
        return false;
      if ("__proto__" === key)
        return false;
      return this._jsIndex.hasOwnProperty(key);
    },
    $index(_, key) {
      if (!this.containsKey$1(key))
        return null;
      return this._values[this._jsIndex[key]];
    },
    forEach$1(_, f) {
      var keys, values, t1, i;
      this.$ti._eval$1("~(1,2)")._as(f);
      keys = this.get$__js_helper$_keys();
      values = this._values;
      for (t1 = keys.length, i = 0; i < t1; ++i)
        f.call$2(keys[i], values[i]);
    },
    get$keys() {
      return new A._KeysOrValues(this.get$__js_helper$_keys(), this.$ti._eval$1("_KeysOrValues<1>"));
    }
  };
  A._KeysOrValues.prototype = {
    get$length(_) {
      return this._elements.length;
    },
    get$iterator(_) {
      var t1 = this._elements;
      return new A._KeysOrValuesOrElementsIterator(t1, t1.length, this.$ti._eval$1("_KeysOrValuesOrElementsIterator<1>"));
    }
  };
  A._KeysOrValuesOrElementsIterator.prototype = {
    get$current() {
      var t1 = this.__js_helper$_current;
      return t1 == null ? this.$ti._precomputed1._as(t1) : t1;
    },
    moveNext$0() {
      var _this = this,
        t1 = _this.__js_helper$_index;
      if (t1 >= _this.__js_helper$_length) {
        _this.__js_helper$_current = null;
        return false;
      }
      _this.__js_helper$_current = _this._elements[t1];
      _this.__js_helper$_index = t1 + 1;
      return true;
    },
    $isIterator: 1
  };
  A.GeneralConstantMap.prototype = {
    _getMap$0() {
      var _this = this,
        backingMap = _this.$map;
      if (backingMap == null) {
        backingMap = new A.JsConstantLinkedHashMap(_this.$ti._eval$1("JsConstantLinkedHashMap<1,2>"));
        A.fillLiteralMap(_this._jsData, backingMap);
        _this.$map = backingMap;
      }
      return backingMap;
    },
    $index(_, key) {
      return this._getMap$0().$index(0, key);
    },
    forEach$1(_, f) {
      this.$ti._eval$1("~(1,2)")._as(f);
      this._getMap$0().forEach$1(0, f);
    },
    get$keys() {
      var t1 = this._getMap$0();
      return new A.LinkedHashMapKeysIterable(t1, A._instanceType(t1)._eval$1("LinkedHashMapKeysIterable<1>"));
    },
    get$length(_) {
      return this._getMap$0().__js_helper$_length;
    }
  };
  A.SafeToStringHook.prototype = {};
  A.TypeErrorDecoder.prototype = {
    matchTypeError$1(message) {
      var result, t1, _this = this,
        match = new RegExp(_this._pattern).exec(message);
      if (match == null)
        return null;
      result = Object.create(null);
      t1 = _this._arguments;
      if (t1 !== -1)
        result.arguments = match[t1 + 1];
      t1 = _this._argumentsExpr;
      if (t1 !== -1)
        result.argumentsExpr = match[t1 + 1];
      t1 = _this._expr;
      if (t1 !== -1)
        result.expr = match[t1 + 1];
      t1 = _this._method;
      if (t1 !== -1)
        result.method = match[t1 + 1];
      t1 = _this._receiver;
      if (t1 !== -1)
        result.receiver = match[t1 + 1];
      return result;
    }
  };
  A.NullError.prototype = {
    toString$0(_) {
      return "Null check operator used on a null value";
    }
  };
  A.JsNoSuchMethodError.prototype = {
    toString$0(_) {
      var t2, _this = this,
        _s38_ = "NoSuchMethodError: method not found: '",
        t1 = _this._method;
      if (t1 == null)
        return "NoSuchMethodError: " + _this.__js_helper$_message;
      t2 = _this._receiver;
      if (t2 == null)
        return _s38_ + t1 + "' (" + _this.__js_helper$_message + ")";
      return _s38_ + t1 + "' on '" + t2 + "' (" + _this.__js_helper$_message + ")";
    }
  };
  A.UnknownJsTypeError.prototype = {
    toString$0(_) {
      var t1 = this.__js_helper$_message;
      return t1.length === 0 ? "Error" : "Error: " + t1;
    }
  };
  A.NullThrownFromJavaScriptException.prototype = {
    toString$0(_) {
      return "Throw of null ('" + (this._irritant === null ? "null" : "undefined") + "' from JavaScript)";
    }
  };
  A.ExceptionAndStackTrace.prototype = {};
  A._StackTrace.prototype = {
    toString$0(_) {
      var trace,
        t1 = this._trace;
      if (t1 != null)
        return t1;
      t1 = this._exception;
      trace = t1 !== null && typeof t1 === "object" ? t1.stack : null;
      return this._trace = trace == null ? "" : trace;
    },
    $isStackTrace: 1
  };
  A.Closure.prototype = {
    toString$0(_) {
      var $constructor = this.constructor,
        $name = $constructor == null ? null : $constructor.name;
      return "Closure '" + A.unminifyOrTag($name == null ? "unknown" : $name) + "'";
    },
    $isFunction: 1,
    get$$call() {
      return this;
    },
    "call*": "call$1",
    $requiredArgCount: 1,
    $defaultValues: null
  };
  A.Closure0Args.prototype = {"call*": "call$0", $requiredArgCount: 0};
  A.Closure2Args.prototype = {"call*": "call$2", $requiredArgCount: 2};
  A.TearOffClosure.prototype = {};
  A.StaticClosure.prototype = {
    toString$0(_) {
      var $name = this.$static_name;
      if ($name == null)
        return "Closure of unknown static method";
      return "Closure '" + A.unminifyOrTag($name) + "'";
    }
  };
  A.BoundClosure.prototype = {
    $eq(_, other) {
      if (other == null)
        return false;
      if (this === other)
        return true;
      if (!(other instanceof A.BoundClosure))
        return false;
      return this.$_target === other.$_target && this._receiver === other._receiver;
    },
    get$hashCode(_) {
      return (A.objectHashCode(this._receiver) ^ A.Primitives_objectHashCode(this.$_target)) >>> 0;
    },
    toString$0(_) {
      return "Closure '" + this.$_name + "' of " + ("Instance of '" + A.Primitives_objectTypeName(this._receiver) + "'");
    }
  };
  A.RuntimeError.prototype = {
    toString$0(_) {
      return "RuntimeError: " + this.message;
    }
  };
  A.JsLinkedHashMap.prototype = {
    get$length(_) {
      return this.__js_helper$_length;
    },
    get$keys() {
      return new A.LinkedHashMapKeysIterable(this, A._instanceType(this)._eval$1("LinkedHashMapKeysIterable<1>"));
    },
    containsKey$1(key) {
      var strings, nums;
      if (typeof key == "string") {
        strings = this.__js_helper$_strings;
        if (strings == null)
          return false;
        return strings[key] != null;
      } else if (typeof key == "number" && (key & 0x3fffffff) === key) {
        nums = this.__js_helper$_nums;
        if (nums == null)
          return false;
        return nums[key] != null;
      } else
        return this.internalContainsKey$1(key);
    },
    internalContainsKey$1(key) {
      var rest = this.__js_helper$_rest;
      if (rest == null)
        return false;
      return this.internalFindBucketIndex$2(rest[this.internalComputeHashCode$1(key)], key) >= 0;
    },
    $index(_, key) {
      var strings, cell, t1, nums, _null = null;
      if (typeof key == "string") {
        strings = this.__js_helper$_strings;
        if (strings == null)
          return _null;
        cell = strings[key];
        t1 = cell == null ? _null : cell.hashMapCellValue;
        return t1;
      } else if (typeof key == "number" && (key & 0x3fffffff) === key) {
        nums = this.__js_helper$_nums;
        if (nums == null)
          return _null;
        cell = nums[key];
        t1 = cell == null ? _null : cell.hashMapCellValue;
        return t1;
      } else
        return this.internalGet$1(key);
    },
    internalGet$1(key) {
      var bucket, index,
        rest = this.__js_helper$_rest;
      if (rest == null)
        return null;
      bucket = rest[this.internalComputeHashCode$1(key)];
      index = this.internalFindBucketIndex$2(bucket, key);
      if (index < 0)
        return null;
      return bucket[index].hashMapCellValue;
    },
    $indexSet(_, key, value) {
      var strings, nums, _this = this,
        t1 = A._instanceType(_this);
      t1._precomputed1._as(key);
      t1._rest[1]._as(value);
      if (typeof key == "string") {
        strings = _this.__js_helper$_strings;
        _this._addHashTableEntry$3(strings == null ? _this.__js_helper$_strings = _this._newHashTable$0() : strings, key, value);
      } else if (typeof key == "number" && (key & 0x3fffffff) === key) {
        nums = _this.__js_helper$_nums;
        _this._addHashTableEntry$3(nums == null ? _this.__js_helper$_nums = _this._newHashTable$0() : nums, key, value);
      } else
        _this.internalSet$2(key, value);
    },
    internalSet$2(key, value) {
      var rest, hash, bucket, index, _this = this,
        t1 = A._instanceType(_this);
      t1._precomputed1._as(key);
      t1._rest[1]._as(value);
      rest = _this.__js_helper$_rest;
      if (rest == null)
        rest = _this.__js_helper$_rest = _this._newHashTable$0();
      hash = _this.internalComputeHashCode$1(key);
      bucket = rest[hash];
      if (bucket == null)
        rest[hash] = [_this._newLinkedCell$2(key, value)];
      else {
        index = _this.internalFindBucketIndex$2(bucket, key);
        if (index >= 0)
          bucket[index].hashMapCellValue = value;
        else
          bucket.push(_this._newLinkedCell$2(key, value));
      }
    },
    remove$1(_, key) {
      var _this = this;
      if (typeof key == "string")
        return _this._removeHashTableEntry$2(_this.__js_helper$_strings, key);
      else if (typeof key == "number" && (key & 0x3fffffff) === key)
        return _this._removeHashTableEntry$2(_this.__js_helper$_nums, key);
      else
        return _this.internalRemove$1(key);
    },
    internalRemove$1(key) {
      var hash, bucket, index, cell, _this = this,
        rest = _this.__js_helper$_rest;
      if (rest == null)
        return null;
      hash = _this.internalComputeHashCode$1(key);
      bucket = rest[hash];
      index = _this.internalFindBucketIndex$2(bucket, key);
      if (index < 0)
        return null;
      cell = bucket.splice(index, 1)[0];
      _this._unlinkCell$1(cell);
      if (bucket.length === 0)
        delete rest[hash];
      return cell.hashMapCellValue;
    },
    forEach$1(_, action) {
      var cell, modifications, _this = this;
      A._instanceType(_this)._eval$1("~(1,2)")._as(action);
      cell = _this._first;
      modifications = _this._modifications;
      while (cell != null) {
        action.call$2(cell.hashMapCellKey, cell.hashMapCellValue);
        if (modifications !== _this._modifications)
          throw A.wrapException(A.ConcurrentModificationError$(_this));
        cell = cell._next;
      }
    },
    _addHashTableEntry$3(table, key, value) {
      var cell,
        t1 = A._instanceType(this);
      t1._precomputed1._as(key);
      t1._rest[1]._as(value);
      cell = table[key];
      if (cell == null)
        table[key] = this._newLinkedCell$2(key, value);
      else
        cell.hashMapCellValue = value;
    },
    _removeHashTableEntry$2(table, key) {
      var cell;
      if (table == null)
        return null;
      cell = table[key];
      if (cell == null)
        return null;
      this._unlinkCell$1(cell);
      delete table[key];
      return cell.hashMapCellValue;
    },
    _modified$0() {
      this._modifications = this._modifications + 1 & 1073741823;
    },
    _newLinkedCell$2(key, value) {
      var _this = this,
        t1 = A._instanceType(_this),
        cell = new A.LinkedHashMapCell(t1._precomputed1._as(key), t1._rest[1]._as(value));
      if (_this._first == null)
        _this._first = _this._last = cell;
      else {
        t1 = _this._last;
        t1.toString;
        cell._previous = t1;
        _this._last = t1._next = cell;
      }
      ++_this.__js_helper$_length;
      _this._modified$0();
      return cell;
    },
    _unlinkCell$1(cell) {
      var _this = this,
        previous = cell._previous,
        next = cell._next;
      if (previous == null)
        _this._first = next;
      else
        previous._next = next;
      if (next == null)
        _this._last = previous;
      else
        next._previous = previous;
      --_this.__js_helper$_length;
      _this._modified$0();
    },
    internalComputeHashCode$1(key) {
      return J.get$hashCode$(key) & 1073741823;
    },
    internalFindBucketIndex$2(bucket, key) {
      var $length, i;
      if (bucket == null)
        return -1;
      $length = bucket.length;
      for (i = 0; i < $length; ++i)
        if (J.$eq$(bucket[i].hashMapCellKey, key))
          return i;
      return -1;
    },
    toString$0(_) {
      return A.MapBase_mapToString(this);
    },
    _newHashTable$0() {
      var table = Object.create(null);
      table["<non-identifier-key>"] = table;
      delete table["<non-identifier-key>"];
      return table;
    },
    $isLinkedHashMap: 1
  };
  A.LinkedHashMapCell.prototype = {};
  A.LinkedHashMapKeysIterable.prototype = {
    get$length(_) {
      return this.__js_helper$_map.__js_helper$_length;
    },
    get$iterator(_) {
      var t1 = this.__js_helper$_map;
      return new A.LinkedHashMapKeyIterator(t1, t1._modifications, t1._first, this.$ti._eval$1("LinkedHashMapKeyIterator<1>"));
    }
  };
  A.LinkedHashMapKeyIterator.prototype = {
    get$current() {
      return this.__js_helper$_current;
    },
    moveNext$0() {
      var cell, _this = this,
        t1 = _this.__js_helper$_map;
      if (_this._modifications !== t1._modifications)
        throw A.wrapException(A.ConcurrentModificationError$(t1));
      cell = _this._cell;
      if (cell == null) {
        _this.__js_helper$_current = null;
        return false;
      } else {
        _this.__js_helper$_current = cell.hashMapCellKey;
        _this._cell = cell._next;
        return true;
      }
    },
    $isIterator: 1
  };
  A.LinkedHashMapValuesIterable.prototype = {
    get$length(_) {
      return this.__js_helper$_map.__js_helper$_length;
    },
    get$iterator(_) {
      var t1 = this.__js_helper$_map;
      return new A.LinkedHashMapValueIterator(t1, t1._modifications, t1._first, this.$ti._eval$1("LinkedHashMapValueIterator<1>"));
    }
  };
  A.LinkedHashMapValueIterator.prototype = {
    get$current() {
      return this.__js_helper$_current;
    },
    moveNext$0() {
      var cell, _this = this,
        t1 = _this.__js_helper$_map;
      if (_this._modifications !== t1._modifications)
        throw A.wrapException(A.ConcurrentModificationError$(t1));
      cell = _this._cell;
      if (cell == null) {
        _this.__js_helper$_current = null;
        return false;
      } else {
        _this.__js_helper$_current = cell.hashMapCellValue;
        _this._cell = cell._next;
        return true;
      }
    },
    $isIterator: 1
  };
  A.JsConstantLinkedHashMap.prototype = {
    internalComputeHashCode$1(key) {
      return A.constantHashCode(key) & 1073741823;
    },
    internalFindBucketIndex$2(bucket, key) {
      var $length, i;
      if (bucket == null)
        return -1;
      $length = bucket.length;
      for (i = 0; i < $length; ++i)
        if (J.$eq$(bucket[i].hashMapCellKey, key))
          return i;
      return -1;
    }
  };
  A.initHooks_closure.prototype = {
    call$1(o) {
      return this.getTag(o);
    },
    $signature: 12
  };
  A.initHooks_closure0.prototype = {
    call$2(o, tag) {
      return this.getUnknownTag(o, tag);
    },
    $signature: 24
  };
  A.initHooks_closure1.prototype = {
    call$1(tag) {
      return this.prototypeForTag(A._asString(tag));
    },
    $signature: 13
  };
  A._Cell.prototype = {
    _readField$0() {
      var t1 = this._value;
      if (t1 === this)
        throw A.wrapException(A.LateError$fieldNI(this.__late_helper$_name));
      return t1;
    }
  };
  A.NativeByteBuffer.prototype = {
    get$lengthInBytes(receiver) {
      return receiver.byteLength;
    },
    get$runtimeType(receiver) {
      return B.Type_ByteBuffer_rqD;
    },
    asUint8List$2(receiver, offsetInBytes, $length) {
      A._checkViewArguments(receiver, offsetInBytes, $length);
      return $length == null ? new Uint8Array(receiver, offsetInBytes) : new Uint8Array(receiver, offsetInBytes, $length);
    },
    asUint8List$0(receiver) {
      return this.asUint8List$2(receiver, 0, null);
    },
    asUint16List$2(receiver, offsetInBytes, $length) {
      A._checkViewArguments(receiver, offsetInBytes, $length);
      $length = B.JSInt_methods._tdivFast$1(receiver.byteLength - offsetInBytes, 2);
      return new Uint16Array(receiver, offsetInBytes, $length);
    },
    asUint32List$2(receiver, offsetInBytes, $length) {
      A._checkViewArguments(receiver, offsetInBytes, $length);
      $length = B.JSInt_methods._tdivFast$1(receiver.byteLength - offsetInBytes, 4);
      return new Uint32Array(receiver, offsetInBytes, $length);
    },
    asFloat32List$2(receiver, offsetInBytes, $length) {
      A._checkViewArguments(receiver, offsetInBytes, $length);
      $length = B.JSInt_methods._tdivFast$1(receiver.byteLength - offsetInBytes, 4);
      return new Float32Array(receiver, offsetInBytes, $length);
    },
    $isTrustedGetRuntimeType: 1,
    $isNativeByteBuffer: 1,
    $isByteBuffer: 1
  };
  A.NativeArrayBuffer.prototype = {$isNativeArrayBuffer: 1};
  A.NativeTypedData.prototype = {
    get$buffer(receiver) {
      if (((receiver.$flags | 0) & 2) !== 0)
        return new A._UnmodifiableNativeByteBufferView(receiver.buffer);
      else
        return receiver.buffer;
    },
    _invalidPosition$3(receiver, position, $length, $name) {
      var t1 = A.RangeError$range(position, 0, $length, $name, null);
      throw A.wrapException(t1);
    },
    _checkPosition$3(receiver, position, $length, $name) {
      if (position >>> 0 !== position || position > $length)
        this._invalidPosition$3(receiver, position, $length, $name);
    }
  };
  A._UnmodifiableNativeByteBufferView.prototype = {
    get$lengthInBytes(_) {
      return this._data.byteLength;
    },
    asUint8List$2(_, offsetInBytes, $length) {
      var result = A.NativeUint8List_NativeUint8List$view(this._data, offsetInBytes, $length);
      result.$flags = 3;
      return result;
    },
    asUint8List$0(_) {
      return this.asUint8List$2(0, 0, null);
    },
    asUint16List$2(_, offsetInBytes, $length) {
      var result = A.NativeUint16List_NativeUint16List$view(this._data, offsetInBytes, $length);
      result.$flags = 3;
      return result;
    },
    asUint32List$2(_, offsetInBytes, $length) {
      var result = A.NativeUint32List_NativeUint32List$view(this._data, offsetInBytes, $length);
      result.$flags = 3;
      return result;
    },
    asFloat32List$2(_, offsetInBytes, $length) {
      var result = A.NativeFloat32List_NativeFloat32List$view(this._data, offsetInBytes, $length);
      result.$flags = 3;
      return result;
    },
    $isByteBuffer: 1
  };
  A.NativeByteData.prototype = {
    get$runtimeType(receiver) {
      return B.Type_ByteData_9dB;
    },
    $isTrustedGetRuntimeType: 1,
    $isByteData: 1
  };
  A.NativeTypedArray.prototype = {
    get$length(receiver) {
      return receiver.length;
    },
    $isJavaScriptIndexingBehavior: 1
  };
  A.NativeTypedArrayOfDouble.prototype = {
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $indexSet(receiver, index, value) {
      A._asDouble(value);
      receiver.$flags & 2 && A.throwUnsupportedOperation(receiver);
      A._checkValidIndex(index, receiver, receiver.length);
      receiver[index] = value;
    },
    $isEfficientLengthIterable: 1,
    $isIterable: 1,
    $isList: 1
  };
  A.NativeTypedArrayOfInt.prototype = {
    $indexSet(receiver, index, value) {
      A._asInt(value);
      receiver.$flags & 2 && A.throwUnsupportedOperation(receiver);
      A._checkValidIndex(index, receiver, receiver.length);
      receiver[index] = value;
    },
    setRange$4(receiver, start, end, iterable, skipCount) {
      var targetLength, count, sourceLength, source;
      type$.Iterable_int._as(iterable);
      receiver.$flags & 2 && A.throwUnsupportedOperation(receiver, 5);
      if (type$.NativeTypedArrayOfInt._is(iterable)) {
        targetLength = receiver.length;
        this._checkPosition$3(receiver, start, targetLength, "start");
        this._checkPosition$3(receiver, end, targetLength, "end");
        if (start > end)
          A.throwExpression(A.RangeError$range(start, 0, end, null, null));
        count = end - start;
        if (skipCount < 0)
          A.throwExpression(A.ArgumentError$(skipCount, null));
        sourceLength = iterable.length;
        if (sourceLength - skipCount < count)
          A.throwExpression(A.StateError$("Not enough elements"));
        source = skipCount !== 0 || sourceLength !== count ? iterable.subarray(skipCount, skipCount + count) : iterable;
        receiver.set(source, start);
        return;
      }
      this.super$ListBase$setRange(receiver, start, end, iterable, skipCount);
    },
    setRange$3(receiver, start, end, iterable) {
      return this.setRange$4(receiver, start, end, iterable, 0);
    },
    $isEfficientLengthIterable: 1,
    $isIterable: 1,
    $isList: 1
  };
  A.NativeFloat32List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Float32List_9Kz;
    },
    $isTrustedGetRuntimeType: 1,
    $isFloat32List: 1
  };
  A.NativeFloat64List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Float64List_9Kz;
    },
    $isTrustedGetRuntimeType: 1,
    $isFloat64List: 1
  };
  A.NativeInt16List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Int16List_s5h;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isInt16List: 1
  };
  A.NativeInt32List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Int32List_O8Z;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isInt32List: 1
  };
  A.NativeInt8List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Int8List_rFV;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isInt8List: 1
  };
  A.NativeUint16List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Uint16List_kmP;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isUint16List: 1
  };
  A.NativeUint32List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Uint32List_kmP;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isUint32List: 1
  };
  A.NativeUint8ClampedList.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Uint8ClampedList_04U;
    },
    get$length(receiver) {
      return receiver.length;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isUint8ClampedList: 1
  };
  A.NativeUint8List.prototype = {
    get$runtimeType(receiver) {
      return B.Type_Uint8List_8Eb;
    },
    get$length(receiver) {
      return receiver.length;
    },
    $index(receiver, index) {
      A._checkValidIndex(index, receiver, receiver.length);
      return receiver[index];
    },
    $isTrustedGetRuntimeType: 1,
    $isUint8List: 1
  };
  A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin.prototype = {};
  A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin.prototype = {};
  A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin.prototype = {};
  A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin.prototype = {};
  A.Rti.prototype = {
    _eval$1(recipe) {
      return A._Universe_evalInEnvironment(init.typeUniverse, this, recipe);
    },
    _bind$1(typeOrTuple) {
      return A._Universe_bind(init.typeUniverse, this, typeOrTuple);
    }
  };
  A._FunctionParameters.prototype = {};
  A._Type.prototype = {
    toString$0(_) {
      return A._rtiToString(this._rti, null);
    }
  };
  A._Error.prototype = {
    toString$0(_) {
      return this._message;
    }
  };
  A._TypeError.prototype = {$isTypeError: 1};
  A._AsyncRun__initializeScheduleImmediate_internalCallback.prototype = {
    call$1(__wc0_formal) {
      var t1 = this._box_0,
        f = t1.storedCallback;
      t1.storedCallback = null;
      f.call$0();
    },
    $signature: 7
  };
  A._AsyncRun__initializeScheduleImmediate_closure.prototype = {
    call$1(callback) {
      var t1, t2;
      this._box_0.storedCallback = type$.void_Function._as(callback);
      t1 = this.div;
      t2 = this.span;
      t1.firstChild ? t1.removeChild(t2) : t1.appendChild(t2);
    },
    $signature: 26
  };
  A._AsyncRun__scheduleImmediateJsOverride_internalCallback.prototype = {
    call$0() {
      this.callback.call$0();
    },
    $signature: 1
  };
  A._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback.prototype = {
    call$0() {
      this.callback.call$0();
    },
    $signature: 1
  };
  A._TimerImpl.prototype = {
    _TimerImpl$2(milliseconds, callback) {
      if (self.setTimeout != null)
        self.setTimeout(A.convertDartClosureToJS(new A._TimerImpl_internalCallback(this, callback), 0), milliseconds);
      else
        throw A.wrapException(A.UnsupportedError$("`setTimeout()` not found."));
    }
  };
  A._TimerImpl_internalCallback.prototype = {
    call$0() {
      this.callback.call$0();
    },
    $signature: 0
  };
  A._AsyncAwaitCompleter.prototype = {
    complete$1(value) {
      var t2, _this = this,
        t1 = _this.$ti;
      t1._eval$1("1/?")._as(value);
      if (value == null)
        value = t1._precomputed1._as(value);
      if (!_this.isSync)
        _this._future._asyncComplete$1(value);
      else {
        t2 = _this._future;
        if (t1._eval$1("Future<1>")._is(value))
          t2._chainFuture$1(value);
        else
          t2._completeWithValue$1(value);
      }
    },
    complete$0() {
      return this.complete$1(null);
    },
    completeError$2(e, st) {
      var t1 = this._future;
      if (this.isSync)
        t1._completeErrorObject$1(new A.AsyncError(e, st));
      else
        t1._asyncCompleteErrorObject$1(new A.AsyncError(e, st));
    },
    get$isCompleted() {
      return (this._future._state & 30) !== 0;
    },
    $isCompleter: 1
  };
  A._awaitOnObject_closure.prototype = {
    call$1(result) {
      return this.bodyFunction.call$2(0, result);
    },
    $signature: 2
  };
  A._awaitOnObject_closure0.prototype = {
    call$2(error, stackTrace) {
      this.bodyFunction.call$2(1, new A.ExceptionAndStackTrace(error, type$.StackTrace._as(stackTrace)));
    },
    $signature: 28
  };
  A._wrapJsFunctionForAsync_closure.prototype = {
    call$2(errorCode, result) {
      this.$protected(A._asInt(errorCode), result);
    },
    $signature: 9
  };
  A.AsyncError.prototype = {
    toString$0(_) {
      return A.S(this.error);
    },
    $isError: 1,
    get$stackTrace() {
      return this.stackTrace;
    }
  };
  A.Future_Future$delayed_closure.prototype = {
    call$0() {
      this.T._as(null);
      this.result._complete$1(null);
    },
    $signature: 0
  };
  A._Completer.prototype = {
    completeError$2(error, stackTrace) {
      var t1 = this.future;
      if ((t1._state & 30) !== 0)
        throw A.wrapException(A.StateError$("Future already completed"));
      t1._asyncCompleteErrorObject$1(A._interceptUserError(error, stackTrace));
    },
    completeError$1(error) {
      return this.completeError$2(error, null);
    },
    get$isCompleted() {
      return (this.future._state & 30) !== 0;
    },
    $isCompleter: 1
  };
  A._AsyncCompleter.prototype = {
    complete$1(value) {
      var t2,
        t1 = this.$ti;
      t1._eval$1("1/?")._as(value);
      t2 = this.future;
      if ((t2._state & 30) !== 0)
        throw A.wrapException(A.StateError$("Future already completed"));
      t2._asyncComplete$1(t1._eval$1("1/")._as(value));
    },
    complete$0() {
      return this.complete$1(null);
    }
  };
  A._FutureListener.prototype = {
    matchesErrorTest$1(asyncError) {
      if ((this.state & 15) !== 6)
        return true;
      return this.result._zone.runUnary$2$2(type$.bool_Function_Object._as(this.callback), asyncError.error, type$.bool, type$.Object);
    },
    handleError$1(asyncError) {
      var exception, _this = this,
        errorCallback = _this.errorCallback,
        result = null,
        t1 = type$.dynamic,
        t2 = type$.Object,
        t3 = asyncError.error,
        t4 = _this.result._zone;
      if (type$.dynamic_Function_Object_StackTrace._is(errorCallback))
        result = t4.runBinary$3$3(errorCallback, t3, asyncError.stackTrace, t1, t2, type$.StackTrace);
      else
        result = t4.runUnary$2$2(type$.dynamic_Function_Object._as(errorCallback), t3, t1, t2);
      try {
        t1 = _this.$ti._eval$1("2/")._as(result);
        return t1;
      } catch (exception) {
        if (type$.TypeError._is(A.unwrapException(exception))) {
          if ((_this.state & 1) !== 0)
            throw A.wrapException(A.ArgumentError$("The error handler of Future.then must return a value of the returned future's type", "onError"));
          throw A.wrapException(A.ArgumentError$("The error handler of Future.catchError must return a value of the future's type", "onError"));
        } else
          throw exception;
      }
    }
  };
  A._Future.prototype = {
    then$1$2$onError(f, onError, $R) {
      var currentZone, result, t2,
        t1 = this.$ti;
      t1._bind$1($R)._eval$1("1/(2)")._as(f);
      currentZone = $.Zone__current;
      if (currentZone === B.C__RootZone) {
        if (onError != null && !type$.dynamic_Function_Object_StackTrace._is(onError) && !type$.dynamic_Function_Object._is(onError))
          throw A.wrapException(A.ArgumentError$value(onError, "onError", string$.Error_));
      } else {
        $R._eval$1("@<0/>")._bind$1(t1._precomputed1)._eval$1("1(2)")._as(f);
        if (onError != null)
          onError = A._registerErrorHandler(onError, currentZone);
      }
      result = new A._Future(currentZone, $R._eval$1("_Future<0>"));
      t2 = onError == null ? 1 : 3;
      this._addListener$1(new A._FutureListener(result, t2, f, onError, t1._eval$1("@<1>")._bind$1($R)._eval$1("_FutureListener<1,2>")));
      return result;
    },
    then$1$1(f, $R) {
      return this.then$1$2$onError(f, null, $R);
    },
    _thenAwait$1$2(f, onError, $E) {
      var result,
        t1 = this.$ti;
      t1._bind$1($E)._eval$1("1/(2)")._as(f);
      result = new A._Future($.Zone__current, $E._eval$1("_Future<0>"));
      this._addListener$1(new A._FutureListener(result, 19, f, onError, t1._eval$1("@<1>")._bind$1($E)._eval$1("_FutureListener<1,2>")));
      return result;
    },
    _setErrorObject$1(error) {
      this._state = this._state & 1 | 16;
      this._resultOrListeners = error;
    },
    _cloneResult$1(source) {
      this._state = source._state & 30 | this._state & 1;
      this._resultOrListeners = source._resultOrListeners;
    },
    _addListener$1(listener) {
      var source, _this = this,
        t1 = _this._state;
      if (t1 <= 3) {
        listener._nextListener = type$.nullable__FutureListener_dynamic_dynamic._as(_this._resultOrListeners);
        _this._resultOrListeners = listener;
      } else {
        if ((t1 & 4) !== 0) {
          source = type$._Future_dynamic._as(_this._resultOrListeners);
          if ((source._state & 24) === 0) {
            source._addListener$1(listener);
            return;
          }
          _this._cloneResult$1(source);
        }
        A._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new A._Future__addListener_closure(_this, listener)));
      }
    },
    _prependListeners$1(listeners) {
      var t1, existingListeners, next, cursor, next0, source, _this = this, _box_0 = {};
      _box_0.listeners = listeners;
      if (listeners == null)
        return;
      t1 = _this._state;
      if (t1 <= 3) {
        existingListeners = type$.nullable__FutureListener_dynamic_dynamic._as(_this._resultOrListeners);
        _this._resultOrListeners = listeners;
        if (existingListeners != null) {
          next = listeners._nextListener;
          for (cursor = listeners; next != null; cursor = next, next = next0)
            next0 = next._nextListener;
          cursor._nextListener = existingListeners;
        }
      } else {
        if ((t1 & 4) !== 0) {
          source = type$._Future_dynamic._as(_this._resultOrListeners);
          if ((source._state & 24) === 0) {
            source._prependListeners$1(listeners);
            return;
          }
          _this._cloneResult$1(source);
        }
        _box_0.listeners = _this._reverseListeners$1(listeners);
        A._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new A._Future__prependListeners_closure(_box_0, _this)));
      }
    },
    _removeListeners$0() {
      var current = type$.nullable__FutureListener_dynamic_dynamic._as(this._resultOrListeners);
      this._resultOrListeners = null;
      return this._reverseListeners$1(current);
    },
    _reverseListeners$1(listeners) {
      var current, prev, next;
      for (current = listeners, prev = null; current != null; prev = current, current = next) {
        next = current._nextListener;
        current._nextListener = prev;
      }
      return prev;
    },
    _complete$1(value) {
      var listeners, _this = this,
        t1 = _this.$ti;
      t1._eval$1("1/")._as(value);
      if (t1._eval$1("Future<1>")._is(value))
        A._Future__chainCoreFuture(value, _this, true);
      else {
        listeners = _this._removeListeners$0();
        t1._precomputed1._as(value);
        _this._state = 8;
        _this._resultOrListeners = value;
        A._Future__propagateToListeners(_this, listeners);
      }
    },
    _completeWithValue$1(value) {
      var listeners, _this = this;
      _this.$ti._precomputed1._as(value);
      listeners = _this._removeListeners$0();
      _this._state = 8;
      _this._resultOrListeners = value;
      A._Future__propagateToListeners(_this, listeners);
    },
    _completeWithResultOf$1(source) {
      var t1, listeners, _this = this;
      if ((source._state & 16) !== 0) {
        t1 = _this._zone === source._zone;
        t1 = !(t1 || t1);
      } else
        t1 = false;
      if (t1)
        return;
      listeners = _this._removeListeners$0();
      _this._cloneResult$1(source);
      A._Future__propagateToListeners(_this, listeners);
    },
    _completeErrorObject$1(error) {
      var listeners = this._removeListeners$0();
      this._setErrorObject$1(error);
      A._Future__propagateToListeners(this, listeners);
    },
    _asyncComplete$1(value) {
      var t1 = this.$ti;
      t1._eval$1("1/")._as(value);
      if (t1._eval$1("Future<1>")._is(value)) {
        this._chainFuture$1(value);
        return;
      }
      this._asyncCompleteWithValue$1(value);
    },
    _asyncCompleteWithValue$1(value) {
      var _this = this;
      _this.$ti._precomputed1._as(value);
      _this._state ^= 2;
      A._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new A._Future__asyncCompleteWithValue_closure(_this, value)));
    },
    _chainFuture$1(value) {
      A._Future__chainCoreFuture(this.$ti._eval$1("Future<1>")._as(value), this, false);
      return;
    },
    _asyncCompleteErrorObject$1(error) {
      this._state ^= 2;
      A._rootScheduleMicrotask(null, null, this._zone, type$.void_Function._as(new A._Future__asyncCompleteErrorObject_closure(this, error)));
    },
    $isFuture: 1
  };
  A._Future__addListener_closure.prototype = {
    call$0() {
      A._Future__propagateToListeners(this.$this, this.listener);
    },
    $signature: 0
  };
  A._Future__prependListeners_closure.prototype = {
    call$0() {
      A._Future__propagateToListeners(this.$this, this._box_0.listeners);
    },
    $signature: 0
  };
  A._Future__chainCoreFuture_closure.prototype = {
    call$0() {
      A._Future__chainCoreFuture(this._box_0.source, this.target, true);
    },
    $signature: 0
  };
  A._Future__asyncCompleteWithValue_closure.prototype = {
    call$0() {
      this.$this._completeWithValue$1(this.value);
    },
    $signature: 0
  };
  A._Future__asyncCompleteErrorObject_closure.prototype = {
    call$0() {
      this.$this._completeErrorObject$1(this.error);
    },
    $signature: 0
  };
  A._Future__propagateToListeners_handleWhenCompleteCallback.prototype = {
    call$0() {
      var e, s, t1, exception, t2, t3, originalSource, joinedResult, _this = this, completeResult = null;
      try {
        t1 = _this._box_0.listener;
        completeResult = t1.result._zone.run$1$1(type$.dynamic_Function._as(t1.callback), type$.dynamic);
      } catch (exception) {
        e = A.unwrapException(exception);
        s = A.getTraceFromException(exception);
        if (_this.hasError && type$.AsyncError._as(_this._box_1.source._resultOrListeners).error === e) {
          t1 = _this._box_0;
          t1.listenerValueOrError = type$.AsyncError._as(_this._box_1.source._resultOrListeners);
        } else {
          t1 = e;
          t2 = s;
          if (t2 == null)
            t2 = A.AsyncError_defaultStackTrace(t1);
          t3 = _this._box_0;
          t3.listenerValueOrError = new A.AsyncError(t1, t2);
          t1 = t3;
        }
        t1.listenerHasError = true;
        return;
      }
      if (completeResult instanceof A._Future && (completeResult._state & 24) !== 0) {
        if ((completeResult._state & 16) !== 0) {
          t1 = _this._box_0;
          t1.listenerValueOrError = type$.AsyncError._as(completeResult._resultOrListeners);
          t1.listenerHasError = true;
        }
        return;
      }
      if (completeResult instanceof A._Future) {
        originalSource = _this._box_1.source;
        joinedResult = new A._Future(originalSource._zone, originalSource.$ti);
        completeResult.then$1$2$onError(new A._Future__propagateToListeners_handleWhenCompleteCallback_closure(joinedResult, originalSource), new A._Future__propagateToListeners_handleWhenCompleteCallback_closure0(joinedResult), type$.void);
        t1 = _this._box_0;
        t1.listenerValueOrError = joinedResult;
        t1.listenerHasError = false;
      }
    },
    $signature: 0
  };
  A._Future__propagateToListeners_handleWhenCompleteCallback_closure.prototype = {
    call$1(__wc0_formal) {
      this.joinedResult._completeWithResultOf$1(this.originalSource);
    },
    $signature: 7
  };
  A._Future__propagateToListeners_handleWhenCompleteCallback_closure0.prototype = {
    call$2(e, s) {
      A._asObject(e);
      type$.StackTrace._as(s);
      this.joinedResult._completeErrorObject$1(new A.AsyncError(e, s));
    },
    $signature: 10
  };
  A._Future__propagateToListeners_handleValueCallback.prototype = {
    call$0() {
      var e, s, t1, t2, t3, t4, t5, exception;
      try {
        t1 = this._box_0;
        t2 = t1.listener;
        t3 = t2.$ti;
        t4 = t3._precomputed1;
        t5 = t4._as(this.sourceResult);
        t1.listenerValueOrError = t2.result._zone.runUnary$2$2(t3._eval$1("2/(1)")._as(t2.callback), t5, t3._eval$1("2/"), t4);
      } catch (exception) {
        e = A.unwrapException(exception);
        s = A.getTraceFromException(exception);
        t1 = e;
        t2 = s;
        if (t2 == null)
          t2 = A.AsyncError_defaultStackTrace(t1);
        t3 = this._box_0;
        t3.listenerValueOrError = new A.AsyncError(t1, t2);
        t3.listenerHasError = true;
      }
    },
    $signature: 0
  };
  A._Future__propagateToListeners_handleError.prototype = {
    call$0() {
      var asyncError, e, s, t1, exception, t2, t3, _this = this;
      try {
        asyncError = type$.AsyncError._as(_this._box_1.source._resultOrListeners);
        t1 = _this._box_0;
        if (t1.listener.matchesErrorTest$1(asyncError) && t1.listener.errorCallback != null) {
          t1.listenerValueOrError = t1.listener.handleError$1(asyncError);
          t1.listenerHasError = false;
        }
      } catch (exception) {
        e = A.unwrapException(exception);
        s = A.getTraceFromException(exception);
        t1 = type$.AsyncError._as(_this._box_1.source._resultOrListeners);
        if (t1.error === e) {
          t2 = _this._box_0;
          t2.listenerValueOrError = t1;
          t1 = t2;
        } else {
          t1 = e;
          t2 = s;
          if (t2 == null)
            t2 = A.AsyncError_defaultStackTrace(t1);
          t3 = _this._box_0;
          t3.listenerValueOrError = new A.AsyncError(t1, t2);
          t1 = t3;
        }
        t1.listenerHasError = true;
      }
    },
    $signature: 0
  };
  A._AsyncCallbackEntry.prototype = {};
  A._StreamIterator.prototype = {};
  A._Zone.prototype = {$isZone: 1};
  A._rootHandleError_closure.prototype = {
    call$0() {
      A.Error_throwWithStackTrace(this.error, this.stackTrace);
    },
    $signature: 0
  };
  A._RootZone.prototype = {
    runGuarded$1(f) {
      var e, s, exception;
      type$.void_Function._as(f);
      try {
        if (B.C__RootZone === $.Zone__current) {
          f.call$0();
          return;
        }
        A._rootRun(null, null, this, f, type$.void);
      } catch (exception) {
        e = A.unwrapException(exception);
        s = A.getTraceFromException(exception);
        A._rootHandleError(A._asObject(e), type$.StackTrace._as(s));
      }
    },
    bindCallbackGuarded$1(f) {
      return new A._RootZone_bindCallbackGuarded_closure(this, type$.void_Function._as(f));
    },
    run$1$1(f, $R) {
      $R._eval$1("0()")._as(f);
      if ($.Zone__current === B.C__RootZone)
        return f.call$0();
      return A._rootRun(null, null, this, f, $R);
    },
    runUnary$2$2(f, arg, $R, $T) {
      $R._eval$1("@<0>")._bind$1($T)._eval$1("1(2)")._as(f);
      $T._as(arg);
      if ($.Zone__current === B.C__RootZone)
        return f.call$1(arg);
      return A._rootRunUnary(null, null, this, f, arg, $R, $T);
    },
    runBinary$3$3(f, arg1, arg2, $R, $T1, $T2) {
      $R._eval$1("@<0>")._bind$1($T1)._bind$1($T2)._eval$1("1(2,3)")._as(f);
      $T1._as(arg1);
      $T2._as(arg2);
      if ($.Zone__current === B.C__RootZone)
        return f.call$2(arg1, arg2);
      return A._rootRunBinary(null, null, this, f, arg1, arg2, $R, $T1, $T2);
    },
    registerBinaryCallback$3$1(f, $R, $T1, $T2) {
      return $R._eval$1("@<0>")._bind$1($T1)._bind$1($T2)._eval$1("1(2,3)")._as(f);
    }
  };
  A._RootZone_bindCallbackGuarded_closure.prototype = {
    call$0() {
      return this.$this.runGuarded$1(this.f);
    },
    $signature: 0
  };
  A._HashMap.prototype = {
    get$length(_) {
      return this._collection$_length;
    },
    get$keys() {
      return new A._HashMapKeyIterable(this, this.$ti._eval$1("_HashMapKeyIterable<1>"));
    },
    containsKey$1(key) {
      var strings, nums;
      if (typeof key == "string" && key !== "__proto__") {
        strings = this._strings;
        return strings == null ? false : strings[key] != null;
      } else if (typeof key == "number" && (key & 1073741823) === key) {
        nums = this._nums;
        return nums == null ? false : nums[key] != null;
      } else
        return this._containsKey$1(key);
    },
    _containsKey$1(key) {
      var rest = this._collection$_rest;
      if (rest == null)
        return false;
      return this._findBucketIndex$2(this._getBucket$2(rest, key), key) >= 0;
    },
    $index(_, key) {
      var strings, t1, nums;
      if (typeof key == "string" && key !== "__proto__") {
        strings = this._strings;
        t1 = strings == null ? null : A._HashMap__getTableEntry(strings, key);
        return t1;
      } else if (typeof key == "number" && (key & 1073741823) === key) {
        nums = this._nums;
        t1 = nums == null ? null : A._HashMap__getTableEntry(nums, key);
        return t1;
      } else
        return this._get$1(key);
    },
    _get$1(key) {
      var bucket, index,
        rest = this._collection$_rest;
      if (rest == null)
        return null;
      bucket = this._getBucket$2(rest, key);
      index = this._findBucketIndex$2(bucket, key);
      return index < 0 ? null : bucket[index + 1];
    },
    $indexSet(_, key, value) {
      var strings, nums, rest, hash, bucket, index, _this = this,
        t1 = _this.$ti;
      t1._precomputed1._as(key);
      t1._rest[1]._as(value);
      if (typeof key == "string" && key !== "__proto__") {
        strings = _this._strings;
        _this._collection$_addHashTableEntry$3(strings == null ? _this._strings = A._HashMap__newHashTable() : strings, key, value);
      } else if (typeof key == "number" && (key & 1073741823) === key) {
        nums = _this._nums;
        _this._collection$_addHashTableEntry$3(nums == null ? _this._nums = A._HashMap__newHashTable() : nums, key, value);
      } else {
        rest = _this._collection$_rest;
        if (rest == null)
          rest = _this._collection$_rest = A._HashMap__newHashTable();
        hash = A.objectHashCode(key) & 1073741823;
        bucket = rest[hash];
        if (bucket == null) {
          A._HashMap__setTableEntry(rest, hash, [key, value]);
          ++_this._collection$_length;
          _this._keys = null;
        } else {
          index = _this._findBucketIndex$2(bucket, key);
          if (index >= 0)
            bucket[index + 1] = value;
          else {
            bucket.push(key, value);
            ++_this._collection$_length;
            _this._keys = null;
          }
        }
      }
    },
    forEach$1(_, action) {
      var keys, $length, t2, i, key, t3, _this = this,
        t1 = _this.$ti;
      t1._eval$1("~(1,2)")._as(action);
      keys = _this._computeKeys$0();
      for ($length = keys.length, t2 = t1._precomputed1, t1 = t1._rest[1], i = 0; i < $length; ++i) {
        key = keys[i];
        t2._as(key);
        t3 = _this.$index(0, key);
        action.call$2(key, t3 == null ? t1._as(t3) : t3);
        if (keys !== _this._keys)
          throw A.wrapException(A.ConcurrentModificationError$(_this));
      }
    },
    _computeKeys$0() {
      var strings, index, names, entries, i, nums, rest, bucket, $length, i0, _this = this,
        result = _this._keys;
      if (result != null)
        return result;
      result = A.List_List$filled(_this._collection$_length, null, false, type$.dynamic);
      strings = _this._strings;
      index = 0;
      if (strings != null) {
        names = Object.getOwnPropertyNames(strings);
        entries = names.length;
        for (i = 0; i < entries; ++i) {
          result[index] = names[i];
          ++index;
        }
      }
      nums = _this._nums;
      if (nums != null) {
        names = Object.getOwnPropertyNames(nums);
        entries = names.length;
        for (i = 0; i < entries; ++i) {
          result[index] = +names[i];
          ++index;
        }
      }
      rest = _this._collection$_rest;
      if (rest != null) {
        names = Object.getOwnPropertyNames(rest);
        entries = names.length;
        for (i = 0; i < entries; ++i) {
          bucket = rest[names[i]];
          $length = bucket.length;
          for (i0 = 0; i0 < $length; i0 += 2) {
            result[index] = bucket[i0];
            ++index;
          }
        }
      }
      return _this._keys = result;
    },
    _collection$_addHashTableEntry$3(table, key, value) {
      var t1 = this.$ti;
      t1._precomputed1._as(key);
      t1._rest[1]._as(value);
      if (table[key] == null) {
        ++this._collection$_length;
        this._keys = null;
      }
      A._HashMap__setTableEntry(table, key, value);
    },
    _getBucket$2(table, key) {
      return table[A.objectHashCode(key) & 1073741823];
    }
  };
  A._IdentityHashMap.prototype = {
    _findBucketIndex$2(bucket, key) {
      var $length, i, t1;
      if (bucket == null)
        return -1;
      $length = bucket.length;
      for (i = 0; i < $length; i += 2) {
        t1 = bucket[i];
        if (t1 == null ? key == null : t1 === key)
          return i;
      }
      return -1;
    }
  };
  A._HashMapKeyIterable.prototype = {
    get$length(_) {
      return this._map._collection$_length;
    },
    get$iterator(_) {
      var t1 = this._map;
      return new A._HashMapKeyIterator(t1, t1._computeKeys$0(), this.$ti._eval$1("_HashMapKeyIterator<1>"));
    }
  };
  A._HashMapKeyIterator.prototype = {
    get$current() {
      var t1 = this._collection$_current;
      return t1 == null ? this.$ti._precomputed1._as(t1) : t1;
    },
    moveNext$0() {
      var _this = this,
        keys = _this._keys,
        offset = _this._offset,
        t1 = _this._map;
      if (keys !== t1._keys)
        throw A.wrapException(A.ConcurrentModificationError$(t1));
      else if (offset >= keys.length) {
        _this._collection$_current = null;
        return false;
      } else {
        _this._collection$_current = keys[offset];
        _this._offset = offset + 1;
        return true;
      }
    },
    $isIterator: 1
  };
  A.LinkedHashMap_LinkedHashMap$from_closure.prototype = {
    call$2(k, v) {
      this.result.$indexSet(0, this.K._as(k), this.V._as(v));
    },
    $signature: 11
  };
  A.ListBase.prototype = {
    get$iterator(receiver) {
      return new A.ListIterator(receiver, this.get$length(receiver), A.instanceType(receiver)._eval$1("ListIterator<ListBase.E>"));
    },
    elementAt$1(receiver, index) {
      return this.$index(receiver, index);
    },
    map$1$1(receiver, f, $T) {
      var t1 = A.instanceType(receiver);
      return new A.MappedListIterable(receiver, t1._bind$1($T)._eval$1("1(ListBase.E)")._as(f), t1._eval$1("@<ListBase.E>")._bind$1($T)._eval$1("MappedListIterable<1,2>"));
    },
    setRange$4(receiver, start, end, iterable, skipCount) {
      var $length, t1, i;
      A.instanceType(receiver)._eval$1("Iterable<ListBase.E>")._as(iterable);
      A.RangeError_checkValidRange(start, end, this.get$length(receiver));
      $length = end - start;
      if ($length === 0)
        return;
      A.RangeError_checkNotNegative(skipCount, "skipCount");
      t1 = J.getInterceptor$asx(iterable);
      if (skipCount + $length > t1.get$length(iterable))
        throw A.wrapException(A.StateError$("Too few elements"));
      if (skipCount < start)
        for (i = $length - 1; i >= 0; --i)
          this.$indexSet(receiver, start + i, t1.$index(iterable, skipCount + i));
      else
        for (i = 0; i < $length; ++i)
          this.$indexSet(receiver, start + i, t1.$index(iterable, skipCount + i));
    },
    toString$0(receiver) {
      return A.Iterable_iterableToFullString(receiver, "[", "]");
    },
    $isEfficientLengthIterable: 1,
    $isIterable: 1,
    $isList: 1
  };
  A.MapBase.prototype = {
    forEach$1(_, action) {
      var t2, key, t3,
        t1 = A._instanceType(this);
      t1._eval$1("~(1,2)")._as(action);
      for (t2 = this.get$keys(), t2 = t2.get$iterator(t2), t1 = t1._rest[1]; t2.moveNext$0();) {
        key = t2.get$current();
        t3 = this.$index(0, key);
        action.call$2(key, t3 == null ? t1._as(t3) : t3);
      }
    },
    map$2$1(_, transform, $K2, $V2) {
      var result, t2, key, t3, entry,
        t1 = A._instanceType(this);
      t1._bind$1($K2)._bind$1($V2)._eval$1("MapEntry<1,2>(3,4)")._as(transform);
      result = A.LinkedHashMap_LinkedHashMap$_empty($K2, $V2);
      for (t2 = this.get$keys(), t2 = t2.get$iterator(t2), t1 = t1._rest[1]; t2.moveNext$0();) {
        key = t2.get$current();
        t3 = this.$index(0, key);
        entry = transform.call$2(key, t3 == null ? t1._as(t3) : t3);
        result.$indexSet(0, entry.key, entry.value);
      }
      return result;
    },
    get$length(_) {
      var t1 = this.get$keys();
      return t1.get$length(t1);
    },
    toString$0(_) {
      return A.MapBase_mapToString(this);
    },
    $isMap: 1
  };
  A.MapBase_mapToString_closure.prototype = {
    call$2(k, v) {
      var t2,
        t1 = this._box_0;
      if (!t1.first)
        this.result._contents += ", ";
      t1.first = false;
      t1 = this.result;
      t2 = A.S(k);
      t1._contents = (t1._contents += t2) + ": ";
      t2 = A.S(v);
      t1._contents += t2;
    },
    $signature: 8
  };
  A._UnicodeSubsetEncoder.prototype = {
    convert$1(string) {
      var i, codeUnit,
        stringLength = string.length,
        end = A.RangeError_checkValidRange(0, null, stringLength),
        result = new Uint8Array(end);
      for (i = 0; i < end; ++i) {
        if (!(i < stringLength))
          return A.ioore(string, i);
        codeUnit = string.charCodeAt(i);
        if ((codeUnit & 4294967040) !== 0)
          throw A.wrapException(A.ArgumentError$value(string, "string", "Contains invalid characters."));
        if (!(i < end))
          return A.ioore(result, i);
        result[i] = codeUnit;
      }
      return result;
    }
  };
  A.Converter.prototype = {};
  A.Latin1Encoder.prototype = {};
  A.DateTime.prototype = {
    $eq(_, other) {
      var t1;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.DateTime)
        if (this._core$_value === other._core$_value)
          t1 = this._microsecond === other._microsecond;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hash(this._core$_value, this._microsecond);
    },
    toString$0(_) {
      var _this = this,
        y = A.DateTime__fourDigits(A.Primitives_getYear(_this)),
        m = A.DateTime__twoDigits(A.Primitives_getMonth(_this)),
        d = A.DateTime__twoDigits(A.Primitives_getDay(_this)),
        h = A.DateTime__twoDigits(A.Primitives_getHours(_this)),
        min = A.DateTime__twoDigits(A.Primitives_getMinutes(_this)),
        sec = A.DateTime__twoDigits(A.Primitives_getSeconds(_this)),
        ms = A.DateTime__threeDigits(A.Primitives_getMilliseconds(_this)),
        t1 = _this._microsecond,
        us = t1 === 0 ? "" : A.DateTime__threeDigits(t1);
      return y + "-" + m + "-" + d + " " + h + ":" + min + ":" + sec + "." + ms + us + "Z";
    }
  };
  A.Duration.prototype = {
    $eq(_, other) {
      if (other == null)
        return false;
      return other instanceof A.Duration && this._duration === other._duration;
    },
    get$hashCode(_) {
      return B.JSInt_methods.get$hashCode(this._duration);
    },
    toString$0(_) {
      var minutesPadding, seconds, secondsPadding,
        microseconds = this._duration,
        microseconds0 = microseconds % 3600000000,
        minutes = B.JSInt_methods._tdivFast$1(microseconds0, 60000000);
      microseconds0 %= 60000000;
      minutesPadding = minutes < 10 ? "0" : "";
      seconds = B.JSInt_methods._tdivFast$1(microseconds0, 1000000);
      secondsPadding = seconds < 10 ? "0" : "";
      return "" + (microseconds / 3600000000 | 0) + ":" + minutesPadding + minutes + ":" + secondsPadding + seconds + "." + B.JSString_methods.padLeft$2(B.JSInt_methods.toString$0(microseconds0 % 1000000), 6, "0");
    }
  };
  A._Enum.prototype = {
    toString$0(_) {
      return this._enumToString$0();
    }
  };
  A.Error.prototype = {
    get$stackTrace() {
      return A.Primitives_extractStackTrace(this);
    }
  };
  A.AssertionError.prototype = {
    toString$0(_) {
      var t1 = this.message;
      if (t1 != null)
        return "Assertion failed: " + A.Error_safeToString(t1);
      return "Assertion failed";
    }
  };
  A.TypeError.prototype = {};
  A.ArgumentError.prototype = {
    get$_errorName() {
      return "Invalid argument" + (!this._hasValue ? "(s)" : "");
    },
    get$_errorExplanation() {
      return "";
    },
    toString$0(_) {
      var _this = this,
        $name = _this.name,
        nameString = $name == null ? "" : " (" + $name + ")",
        message = _this.message,
        messageString = message == null ? "" : ": " + A.S(message),
        prefix = _this.get$_errorName() + nameString + messageString;
      if (!_this._hasValue)
        return prefix;
      return prefix + _this.get$_errorExplanation() + ": " + A.Error_safeToString(_this.get$invalidValue());
    },
    get$invalidValue() {
      return this.invalidValue;
    }
  };
  A.RangeError.prototype = {
    get$invalidValue() {
      return A._asNumQ(this.invalidValue);
    },
    get$_errorName() {
      return "RangeError";
    },
    get$_errorExplanation() {
      var explanation,
        start = this.start,
        end = this.end;
      if (start == null)
        explanation = end != null ? ": Not less than or equal to " + A.S(end) : "";
      else if (end == null)
        explanation = ": Not greater than or equal to " + A.S(start);
      else if (end > start)
        explanation = ": Not in inclusive range " + A.S(start) + ".." + A.S(end);
      else
        explanation = end < start ? ": Valid value range is empty" : ": Only valid value is " + A.S(start);
      return explanation;
    }
  };
  A.IndexError.prototype = {
    get$invalidValue() {
      return A._asInt(this.invalidValue);
    },
    get$_errorName() {
      return "RangeError";
    },
    get$_errorExplanation() {
      if (A._asInt(this.invalidValue) < 0)
        return ": index must not be negative";
      var t1 = this.length;
      if (t1 === 0)
        return ": no indices are valid";
      return ": index should be less than " + t1;
    },
    get$length(receiver) {
      return this.length;
    }
  };
  A.UnsupportedError.prototype = {
    toString$0(_) {
      return "Unsupported operation: " + this.message;
    }
  };
  A.UnimplementedError.prototype = {
    toString$0(_) {
      return "UnimplementedError: " + this.message;
    }
  };
  A.StateError.prototype = {
    toString$0(_) {
      return "Bad state: " + this.message;
    }
  };
  A.ConcurrentModificationError.prototype = {
    toString$0(_) {
      var t1 = this.modifiedObject;
      if (t1 == null)
        return "Concurrent modification during iteration.";
      return "Concurrent modification during iteration: " + A.Error_safeToString(t1) + ".";
    }
  };
  A.OutOfMemoryError.prototype = {
    toString$0(_) {
      return "Out of Memory";
    },
    get$stackTrace() {
      return null;
    },
    $isError: 1
  };
  A.StackOverflowError.prototype = {
    toString$0(_) {
      return "Stack Overflow";
    },
    get$stackTrace() {
      return null;
    },
    $isError: 1
  };
  A._Exception.prototype = {
    toString$0(_) {
      return "Exception: " + this.message;
    }
  };
  A.Iterable.prototype = {
    map$1$1(_, toElement, $T) {
      var t1 = A._instanceType(this);
      return A.MappedIterable_MappedIterable(this, t1._bind$1($T)._eval$1("1(Iterable.E)")._as(toElement), t1._eval$1("Iterable.E"), $T);
    },
    get$length(_) {
      var count,
        it = this.get$iterator(this);
      for (count = 0; it.moveNext$0();)
        ++count;
      return count;
    },
    elementAt$1(_, index) {
      var iterator, skipCount;
      A.RangeError_checkNotNegative(index, "index");
      iterator = this.get$iterator(this);
      for (skipCount = index; iterator.moveNext$0();) {
        if (skipCount === 0)
          return iterator.get$current();
        --skipCount;
      }
      throw A.wrapException(A.IndexError$withLength(index, index - skipCount, this, "index"));
    },
    toString$0(_) {
      return A.Iterable_iterableToShortString(this, "(", ")");
    }
  };
  A.MapEntry.prototype = {
    toString$0(_) {
      return "MapEntry(" + A.S(this.key) + ": " + A.S(this.value) + ")";
    }
  };
  A.Null.prototype = {
    get$hashCode(_) {
      return A.Object.prototype.get$hashCode.call(this, 0);
    },
    toString$0(_) {
      return "null";
    }
  };
  A.Object.prototype = {$isObject: 1,
    $eq(_, other) {
      return this === other;
    },
    get$hashCode(_) {
      return A.Primitives_objectHashCode(this);
    },
    toString$0(_) {
      return "Instance of '" + A.Primitives_objectTypeName(this) + "'";
    },
    get$runtimeType(_) {
      return A.getRuntimeTypeOfDartObject(this);
    },
    toString() {
      return this.toString$0(this);
    }
  };
  A._StringStackTrace.prototype = {
    toString$0(_) {
      return "";
    },
    $isStackTrace: 1
  };
  A.StringBuffer.prototype = {
    get$length(_) {
      return this._contents.length;
    },
    toString$0(_) {
      var t1 = this._contents;
      return t1.charCodeAt(0) == 0 ? t1 : t1;
    }
  };
  A.NullRejectionException.prototype = {
    toString$0(_) {
      return "Promise was rejected with a value of `" + (this.isUndefined ? "undefined" : "null") + "`.";
    }
  };
  A.jsify__convert.prototype = {
    call$1(o) {
      var t1, convertedMap, key, convertedList;
      if (A._noJsifyRequired(o))
        return o;
      t1 = this._convertedObjects;
      if (t1.containsKey$1(o))
        return t1.$index(0, o);
      if (type$.Map_dynamic_dynamic._is(o)) {
        convertedMap = {};
        t1.$indexSet(0, o, convertedMap);
        for (t1 = o.get$keys(), t1 = t1.get$iterator(t1); t1.moveNext$0();) {
          key = t1.get$current();
          convertedMap[key] = this.call$1(o.$index(0, key));
        }
        return convertedMap;
      } else if (type$.Iterable_dynamic._is(o)) {
        convertedList = [];
        t1.$indexSet(0, o, convertedList);
        B.JSArray_methods.addAll$1(convertedList, J.map$1$1$ax(o, this, type$.dynamic));
        return convertedList;
      } else
        return o;
    },
    $signature: 3
  };
  A.promiseToFuture_closure.prototype = {
    call$1(r) {
      return this.completer.complete$1(this.T._eval$1("0/?")._as(r));
    },
    $signature: 2
  };
  A.promiseToFuture_closure0.prototype = {
    call$1(e) {
      if (e == null)
        return this.completer.completeError$1(new A.NullRejectionException(e === undefined));
      return this.completer.completeError$1(e);
    },
    $signature: 2
  };
  A.dartify_convert.prototype = {
    call$1(o) {
      var t1, millisSinceEpoch, proto, t2, dartObject, originalKeys, dartKeys, i, jsKey, dartKey, l, $length;
      if (A._noDartifyRequired(o))
        return o;
      t1 = this._convertedObjects;
      o.toString;
      if (t1.containsKey$1(o))
        return t1.$index(0, o);
      if (o instanceof Date) {
        millisSinceEpoch = o.getTime();
        if (millisSinceEpoch < -864e13 || millisSinceEpoch > 864e13)
          A.throwExpression(A.RangeError$range(millisSinceEpoch, -864e13, 864e13, "millisecondsSinceEpoch", null));
        A.checkNotNullable(true, "isUtc", type$.bool);
        return new A.DateTime(millisSinceEpoch, 0, true);
      }
      if (o instanceof RegExp)
        throw A.wrapException(A.ArgumentError$("structured clone of RegExp", null));
      if (o instanceof Promise)
        return A.promiseToFuture(o, type$.nullable_Object);
      proto = Object.getPrototypeOf(o);
      if (proto === Object.prototype || proto === null) {
        t2 = type$.nullable_Object;
        dartObject = A.LinkedHashMap_LinkedHashMap$_empty(t2, t2);
        t1.$indexSet(0, o, dartObject);
        originalKeys = Object.keys(o);
        dartKeys = [];
        for (t1 = J.getInterceptor$ax(originalKeys), t2 = t1.get$iterator(originalKeys); t2.moveNext$0();)
          dartKeys.push(A.dartify(t2.get$current()));
        for (i = 0; i < t1.get$length(originalKeys); ++i) {
          jsKey = t1.$index(originalKeys, i);
          if (!(i < dartKeys.length))
            return A.ioore(dartKeys, i);
          dartKey = dartKeys[i];
          if (jsKey != null)
            dartObject.$indexSet(0, dartKey, this.call$1(o[jsKey]));
        }
        return dartObject;
      }
      if (o instanceof Array) {
        l = o;
        dartObject = [];
        t1.$indexSet(0, o, dartObject);
        $length = A._asInt(o.length);
        for (t1 = J.getInterceptor$ax(l), i = 0; i < $length; ++i)
          dartObject.push(this.call$1(t1.$index(l, i)));
        return dartObject;
      }
      return o;
    },
    $signature: 3
  };
  A.OutputFormat.prototype = {
    _enumToString$0() {
      return "OutputFormat." + this._name;
    }
  };
  A.ImageConvertThreadRequest.prototype = {};
  A.ThreadRequest.prototype = {};
  A.ThreadResponse.prototype = {};
  A.ThreadWebRequest.prototype = {};
  A.ThreadWebRequest_ThreadWebRequest$fromJs_convertString.prototype = {
    call$1(value) {
      if (value == null)
        return null;
      return A._asString(value);
    },
    $signature: 14
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_convertInteger.prototype = {
    call$1(value) {
      if (value == null)
        return null;
      return A._asInt(A._asDouble(value));
    },
    $signature: 15
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_convertBool.prototype = {
    call$1(value) {
      if (value == null)
        return null;
      return A._asBool(value);
    },
    $signature: 16
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage.prototype = {
    call$1(data) {
      var t2, t3, t4, t5, t6, t7, t8, t9, t10, _null = null,
        jsWidth = A.jsGetProperty(data, "width"),
        jsHeight = A.jsGetProperty(data, "height"),
        jsFrameDuration = A.jsGetProperty(data, "frameDuration"),
        jsFrameIndex = A.jsGetProperty(data, "frameIndex"),
        jsLoopCount = A.jsGetProperty(data, "loopCount"),
        jsNumChannels = A.jsGetProperty(data, "numChannels"),
        jsRowStride = A.jsGetProperty(data, "rowStride"),
        jsFrameType = A.jsGetProperty(data, "frameType"),
        jsFormat = A.jsGetProperty(data, "format"),
        jsTextData = A.jsGetProperty(data, "textData"),
        t1 = this.convertString,
        frameType = t1.call$1(jsFrameType),
        format = t1.call$1(jsFormat),
        dartBytes = type$.NativeArrayBuffer._as(A.jsGetProperty(data, "buffer")),
        textData = type$.nullable_Map_String_String._as(A.dartify(jsTextData));
      t1 = this.convertInteger;
      t2 = t1.call$1(jsWidth);
      t2.toString;
      t3 = t1.call$1(jsHeight);
      t3.toString;
      t4 = t1.call$1(jsFrameDuration);
      if (t4 == null)
        t4 = 0;
      t5 = t1.call$1(jsFrameIndex);
      if (t5 == null)
        t5 = 0;
      t6 = t1.call$1(jsLoopCount);
      if (t6 == null)
        t6 = 0;
      t7 = t1.call$1(jsNumChannels);
      t1 = t1.call$1(jsRowStride);
      t8 = frameType == null ? B.FrameType_2 : B.JSArray_methods.firstWhere$1(B.List_52t, new A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure(frameType));
      t9 = format == null ? B.Format_3 : B.JSArray_methods.firstWhere$1(B.List_vwN, new A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure0(format));
      t10 = new A.Image(_null, _null, textData, _null, _null, t6, t8, t4, t5);
      t10.Image$fromBytes$18$backgroundColor$bytes$bytesOffset$exif$format$frameDuration$frameIndex$frameType$height$iccp$loopCount$numChannels$order$palette$rowStride$textData$width$withPalette(_null, dartBytes, 0, _null, t9, t4, t5, t8, t3, _null, t6, t7, _null, _null, t1, textData, t2, false);
      return t10;
    },
    $signature: 17
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure.prototype = {
    call$1(el) {
      return type$.FrameType._as(el)._name === this.frameType;
    },
    $signature: 18
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure0.prototype = {
    call$1(el) {
      return type$.Format._as(el)._name === this.format;
    },
    $signature: 19
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma.prototype = {
    call$1(value) {
      return value == null ? B.JpegChroma_0 : B.JSArray_methods.firstWhere$1(B.List_JpegChroma_0_JpegChroma_1, new A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma_closure(value));
    },
    $signature: 20
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma_closure.prototype = {
    call$1(el) {
      return type$.JpegChroma._as(el)._name === this.value;
    },
    $signature: 21
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter.prototype = {
    call$1(value) {
      return value == null ? B.PngFilter_0 : B.JSArray_methods.firstWhere$1(B.List_Eq4, new A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter_closure(value));
    },
    $signature: 22
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter_closure.prototype = {
    call$1(el) {
      return type$.PngFilter._as(el)._name === this.value;
    },
    $signature: 23
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat.prototype = {
    call$1(value) {
      return value == null ? B.OutputFormat_0 : B.JSArray_methods.firstWhere$1(B.List_D9t, new A.ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat_closure(value));
    },
    $signature: 37
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat_closure.prototype = {
    call$1(el) {
      return type$.OutputFormat._as(el)._name === this.value;
    },
    $signature: 25
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpgBackgroundColor.prototype = {
    call$1(value) {
      return value == null ? 4278190080 : value;
    },
    $signature: 5
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpgQuality.prototype = {
    call$1(value) {
      return value == null ? 100 : value;
    },
    $signature: 5
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngLevel.prototype = {
    call$1(value) {
      return value == null ? 6 : value;
    },
    $signature: 5
  };
  A.ThreadWebRequest_ThreadWebRequest$fromJs_getSingleFrame.prototype = {
    call$1(value) {
      return value === true;
    },
    $signature: 27
  };
  A.ZLibEncoderBase.prototype = {};
  A._ZLibEncoder.prototype = {
    encodeStream$5$level$raw$windowBits(input, output, level, raw, windowBits) {
      var cmf, cmf256, fcheck, t1, startPos, adler32, t2, t3, t4;
      output.byteOrder = B.ByteOrder_1;
      cmf = (B.JSInt_methods.clamp$2(15, 0, 15) - 8 << 4 | 8) >>> 0;
      output.writeByte$1(cmf);
      cmf256 = cmf * 256;
      for (fcheck = 0; t1 = (fcheck | 0) >>> 0, B.JSInt_methods.$mod(cmf256 + t1, 31) !== 0;)
        ++fcheck;
      output.writeByte$1(t1);
      startPos = input._position;
      adler32 = A.getAdler32Stream(input);
      input._position = startPos;
      t1 = level == null ? 6 : level;
      A.Deflate$stream(input, t1, output, 15);
      t1 = adler32 & 255;
      t2 = adler32 >>> 24 & 255;
      t3 = adler32 >>> 16 & 255;
      t4 = adler32 >>> 8 & 255;
      if (output.byteOrder === B.ByteOrder_1) {
        output.writeByte$1(t2);
        output.writeByte$1(t3);
        output.writeByte$1(t4);
        output.writeByte$1(t1);
      } else {
        output.writeByte$1(t1);
        output.writeByte$1(t4);
        output.writeByte$1(t3);
        output.writeByte$1(t2);
      }
    }
  };
  A._DeflateFlushMode.prototype = {
    _enumToString$0() {
      return "_DeflateFlushMode." + this._name;
    }
  };
  A.Deflate.prototype = {
    _deflate$_init$2$windowBits(level, windowBits) {
      var config, t2, t3, t4, _this = this,
        t1 = true;
      if (windowBits >= 9)
        if (windowBits <= 15)
          if (level >= 0)
            t1 = level > 9;
      if (t1)
        return false;
      config = _this._getConfig$1(level);
      if (config == null)
        return false;
      $.Deflate____config._value = config;
      t1 = new Uint16Array(1146);
      _this.__Deflate__dynamicLengthTree_A = t1;
      t2 = new Uint16Array(122);
      _this.__Deflate__dynamicDistTree_A = t2;
      t3 = new Uint16Array(78);
      _this.__Deflate__bitLengthTree_A = t3;
      _this.__Deflate__windowBits_A = windowBits;
      t4 = _this.__Deflate__windowSize_A = B.JSInt_methods._shlPositive$1(1, windowBits);
      _this.__Deflate__windowMask_A = t4 - 1;
      _this.__Deflate__hashBits_A = 15;
      _this.__Deflate__hashSize_A = 32768;
      _this.__Deflate__hashMask_A = 32767;
      _this.__Deflate__hashShift_A = 5;
      _this.__Deflate__window_A = new Uint8Array(t4 * 2);
      _this.__Deflate__prev_A = new Uint16Array(t4);
      _this.__Deflate__head_A = new Uint16Array(32768);
      _this.__Deflate__litBufferSize_A = 16384;
      _this.__Deflate__pendingBuffer_A = new Uint8Array(65536);
      _this.__Deflate__pendingBufferSize_A = 65536;
      _this.__Deflate__dbuf_A = 16384;
      _this.__Deflate__lbuf_A = 49152;
      _this.__Deflate__level_A = level;
      _this.__Deflate__pendingOut_A = _this.__Deflate__pending_A = _this.__Deflate__strategy_A = 0;
      _this._status = 113;
      _this.crc32 = 0;
      t4 = _this._lDesc;
      t4.___HuffmanTree_dynamicTree_A = t1;
      t4.___HuffmanTree_staticDesc_A = $.$get$_StaticTree_staticLDesc();
      t4 = _this._dDesc;
      t4.___HuffmanTree_dynamicTree_A = t2;
      t4.___HuffmanTree_staticDesc_A = $.$get$_StaticTree_staticDDesc();
      t4 = _this._blDesc;
      t4.___HuffmanTree_dynamicTree_A = t3;
      t4.___HuffmanTree_staticDesc_A = $.$get$_StaticTree_staticBlDesc();
      _this.__Deflate__numValidBits_A = _this.__Deflate__bitBuffer_A = 0;
      _this.__Deflate__lastEOBLen_A = 8;
      _this._initBlock$0();
      _this._lmInit$0();
      return true;
    },
    _deflate$1(flush) {
      var t2, t3, bState, i, _this = this,
        t1 = _this.__Deflate__pending_A;
      t1 === $ && A.throwLateFieldNI("_pending");
      if (t1 !== 0)
        _this._flushPending$0();
      t1 = _this._input;
      t2 = t1._position;
      t1 = t1.__InputMemoryStream__length_A;
      t1 === $ && A.throwLateFieldNI("_length");
      t3 = true;
      if (t2 >= t1) {
        t1 = _this.__Deflate__lookAhead_A;
        t1 === $ && A.throwLateFieldNI("_lookAhead");
        if (t1 === 0)
          t1 = flush !== B._DeflateFlushMode_0 && _this._status !== 666;
        else
          t1 = t3;
      } else
        t1 = t3;
      if (t1) {
        switch ($.Deflate____config._readField$0().$function) {
          case 0:
            bState = _this._deflateStored$1(flush);
            break;
          case 1:
            bState = _this._deflateFast$1(flush);
            break;
          case 2:
            bState = _this._deflateSlow$1(flush);
            break;
          default:
            bState = -1;
            break;
        }
        t1 = bState === 2;
        if (t1 || bState === 3)
          _this._status = 666;
        if (bState === 0 || t1)
          return 0;
        if (bState === 1) {
          if (flush === B._DeflateFlushMode_1) {
            _this._sendBits$2(2, 3);
            _this._sendCode$2(256, B.List_LCt);
            _this.biFlush$0();
            t1 = _this.__Deflate__lastEOBLen_A;
            t1 === $ && A.throwLateFieldNI("_lastEOBLen");
            t2 = _this.__Deflate__numValidBits_A;
            t2 === $ && A.throwLateFieldNI("_numValidBits");
            if (1 + t1 + 10 - t2 < 9) {
              _this._sendBits$2(2, 3);
              _this._sendCode$2(256, B.List_LCt);
              _this.biFlush$0();
            }
            _this.__Deflate__lastEOBLen_A = 7;
          } else {
            _this._trStoredBlock$3(0, 0, false);
            if (flush === B._DeflateFlushMode_2) {
              t1 = _this.__Deflate__hashSize_A;
              t1 === $ && A.throwLateFieldNI("_hashSize");
              t2 = _this.__Deflate__head_A;
              i = 0;
              for (; i < t1; ++i) {
                t2 === $ && A.throwLateFieldNI("_head");
                t2.$flags & 2 && A.throwUnsupportedOperation(t2);
                if (!(i < t2.length))
                  return A.ioore(t2, i);
                t2[i] = 0;
              }
            }
          }
          _this._flushPending$0();
        }
      }
      if (flush !== B._DeflateFlushMode_3)
        return 0;
      return 1;
    },
    _lmInit$0() {
      var t2, t3, i, _this = this,
        t1 = _this.__Deflate__windowSize_A;
      t1 === $ && A.throwLateFieldNI("_windowSize");
      _this.__Deflate__actualWindowSize_A = 2 * t1;
      t1 = _this.__Deflate__head_A;
      t1 === $ && A.throwLateFieldNI("_head");
      t2 = _this.__Deflate__hashSize_A;
      t2 === $ && A.throwLateFieldNI("_hashSize");
      --t2;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      t3 = t1.length;
      if (!(t2 >= 0 && t2 < t3))
        return A.ioore(t1, t2);
      t1[t2] = 0;
      for (i = 0; i < t2; ++i) {
        if (!(i < t3))
          return A.ioore(t1, i);
        t1[i] = 0;
      }
      _this.__Deflate__lookAhead_A = _this.__Deflate__blockStart_A = _this.__Deflate__strStart_A = 0;
      _this.__Deflate__matchLength_A = _this.__Deflate__prevLength_A = 2;
      _this.__Deflate__insertHash_A = _this.__Deflate__matchAvailable_A = 0;
    },
    _initBlock$0() {
      var t1, i, t2, t3, _this = this,
        _s18_ = "_dynamicLengthTree";
      for (t1 = _this.__Deflate__dynamicLengthTree_A, i = 0; i < 286; ++i) {
        t1 === $ && A.throwLateFieldNI(_s18_);
        t2 = i * 2;
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 < 1146))
          return A.ioore(t1, t2);
        t1[t2] = 0;
      }
      for (t2 = _this.__Deflate__dynamicDistTree_A, i = 0; i < 30; ++i) {
        t2 === $ && A.throwLateFieldNI("_dynamicDistTree");
        t3 = i * 2;
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        if (!(t3 < 122))
          return A.ioore(t2, t3);
        t2[t3] = 0;
      }
      for (t2 = _this.__Deflate__bitLengthTree_A, i = 0; i < 19; ++i) {
        t2 === $ && A.throwLateFieldNI("_bitLengthTree");
        t3 = i * 2;
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        if (!(t3 < 78))
          return A.ioore(t2, t3);
        t2[t3] = 0;
      }
      t1 === $ && A.throwLateFieldNI(_s18_);
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      t1[512] = 1;
      _this.__Deflate__lastLit_A = _this.__Deflate__matches_A = _this.__Deflate__optimalLen_A = _this.__Deflate__staticLen_A = 0;
    },
    _pqdownheap$2(tree, k) {
      var v, j, t2, t3, t4, j0,
        t1 = this._heap;
      if (!(k >= 0 && k < 573))
        return A.ioore(t1, k);
      v = t1[k];
      j = k << 1 >>> 0;
      t2 = t1.$flags | 0;
      t3 = this._depth;
      for (;;) {
        t4 = this.__Deflate__heapLen_A;
        t4 === $ && A.throwLateFieldNI("_heapLen");
        if (!(j <= t4))
          break;
        if (j < t4) {
          t4 = j + 1;
          if (!(t4 >= 0 && t4 < 573))
            return A.ioore(t1, t4);
          t4 = t1[t4];
          if (!(j >= 0 && j < 573))
            return A.ioore(t1, j);
          t4 = A.Deflate__smaller(tree, t4, t1[j], t3);
        } else
          t4 = false;
        if (t4)
          ++j;
        if (!(j >= 0 && j < 573))
          return A.ioore(t1, j);
        if (A.Deflate__smaller(tree, v, t1[j], t3))
          break;
        t4 = t1[j];
        t2 & 2 && A.throwUnsupportedOperation(t1);
        if (!(k >= 0 && k < 573))
          return A.ioore(t1, k);
        t1[k] = t4;
        j0 = j << 1 >>> 0;
        k = j;
        j = j0;
      }
      t2 & 2 && A.throwUnsupportedOperation(t1);
      if (!(k >= 0 && k < 573))
        return A.ioore(t1, k);
      t1[k] = v;
    },
    _scanTree$2(tree, maxCode) {
      var nextLen, maxCount, minCount, t2, n, prevLen, count, t3, nextLen0, minCount0, t4,
        _s14_ = "_bitLengthTree",
        t1 = tree.length;
      if (1 >= t1)
        return A.ioore(tree, 1);
      nextLen = tree[1];
      if (nextLen === 0) {
        maxCount = 138;
        minCount = 3;
      } else {
        maxCount = 7;
        minCount = 4;
      }
      t2 = (maxCode + 1) * 2 + 1;
      tree.$flags & 2 && A.throwUnsupportedOperation(tree);
      if (!(t2 >= 0 && t2 < t1))
        return A.ioore(tree, t2);
      tree[t2] = 65535;
      for (t2 = this.__Deflate__bitLengthTree_A, n = 0, prevLen = -1, count = 0; n <= maxCode; nextLen = nextLen0) {
        ++n;
        t3 = n * 2 + 1;
        if (!(t3 < t1))
          return A.ioore(tree, t3);
        nextLen0 = tree[t3];
        ++count;
        if (count < maxCount && nextLen === nextLen0)
          continue;
        else {
          minCount0 = 3;
          if (count < minCount) {
            t2 === $ && A.throwLateFieldNI(_s14_);
            t3 = nextLen * 2;
            if (!(t3 >= 0 && t3 < 78))
              return A.ioore(t2, t3);
            t4 = t2[t3];
            t2.$flags & 2 && A.throwUnsupportedOperation(t2);
            t2[t3] = t4 + count;
          } else if (nextLen !== 0) {
            if (nextLen !== prevLen) {
              t2 === $ && A.throwLateFieldNI(_s14_);
              t3 = nextLen * 2;
              if (!(t3 >= 0 && t3 < 78))
                return A.ioore(t2, t3);
              t4 = t2[t3];
              t2.$flags & 2 && A.throwUnsupportedOperation(t2);
              t2[t3] = t4 + 1;
            }
            t2 === $ && A.throwLateFieldNI(_s14_);
            t3 = t2[32];
            t2.$flags & 2 && A.throwUnsupportedOperation(t2);
            t2[32] = t3 + 1;
          } else if (count <= 10) {
            t2 === $ && A.throwLateFieldNI(_s14_);
            t3 = t2[34];
            t2.$flags & 2 && A.throwUnsupportedOperation(t2);
            t2[34] = t3 + 1;
          } else {
            t2 === $ && A.throwLateFieldNI(_s14_);
            t3 = t2[36];
            t2.$flags & 2 && A.throwUnsupportedOperation(t2);
            t2[36] = t3 + 1;
          }
        }
        if (nextLen0 === 0) {
          minCount = minCount0;
          maxCount = 138;
        } else if (nextLen === nextLen0) {
          minCount = minCount0;
          maxCount = 6;
        } else {
          maxCount = 7;
          minCount = 4;
        }
        prevLen = nextLen;
        count = 0;
      }
    },
    _buildBitLengthTree$0() {
      var t2, maxBLIndex, _this = this,
        t1 = _this.__Deflate__dynamicLengthTree_A;
      t1 === $ && A.throwLateFieldNI("_dynamicLengthTree");
      t2 = _this._lDesc.___HuffmanTree_maxCode_A;
      t2 === $ && A.throwLateFieldNI("maxCode");
      _this._scanTree$2(t1, t2);
      t2 = _this.__Deflate__dynamicDistTree_A;
      t2 === $ && A.throwLateFieldNI("_dynamicDistTree");
      t1 = _this._dDesc.___HuffmanTree_maxCode_A;
      t1 === $ && A.throwLateFieldNI("maxCode");
      _this._scanTree$2(t2, t1);
      _this._blDesc._buildTree$1(_this);
      for (t1 = _this.__Deflate__bitLengthTree_A, maxBLIndex = 18; maxBLIndex >= 3; --maxBLIndex) {
        t1 === $ && A.throwLateFieldNI("_bitLengthTree");
        t2 = B.List_lln[maxBLIndex] * 2 + 1;
        if (!(t2 < 78))
          return A.ioore(t1, t2);
        if (t1[t2] !== 0)
          break;
      }
      t1 = _this.__Deflate__optimalLen_A;
      t1 === $ && A.throwLateFieldNI("_optimalLen");
      _this.__Deflate__optimalLen_A = t1 + (3 * (maxBLIndex + 1) + 5 + 5 + 4);
      return maxBLIndex;
    },
    _sendAllTrees$3(lCodes, dCodes, blCodes) {
      var t1, rank, t2, t3, _this = this;
      _this._sendBits$2(lCodes - 257, 5);
      t1 = dCodes - 1;
      _this._sendBits$2(t1, 5);
      _this._sendBits$2(blCodes - 4, 4);
      for (rank = 0; rank < blCodes; ++rank) {
        t2 = _this.__Deflate__bitLengthTree_A;
        t2 === $ && A.throwLateFieldNI("_bitLengthTree");
        if (!(rank < 19))
          return A.ioore(B.List_lln, rank);
        t3 = B.List_lln[rank] * 2 + 1;
        if (!(t3 < 78))
          return A.ioore(t2, t3);
        _this._sendBits$2(t2[t3], 3);
      }
      t2 = _this.__Deflate__dynamicLengthTree_A;
      t2 === $ && A.throwLateFieldNI("_dynamicLengthTree");
      _this._sendTree$2(t2, lCodes - 1);
      t2 = _this.__Deflate__dynamicDistTree_A;
      t2 === $ && A.throwLateFieldNI("_dynamicDistTree");
      _this._sendTree$2(t2, t1);
    },
    _sendTree$2(tree, maxCode) {
      var nextLen, maxCount, minCount, t2, n, prevLen, count, t3, nextLen0, minCount0, t4, t5, t6, _this = this,
        _s14_ = "_bitLengthTree",
        t1 = tree.length;
      if (1 >= t1)
        return A.ioore(tree, 1);
      nextLen = tree[1];
      if (nextLen === 0) {
        maxCount = 138;
        minCount = 3;
      } else {
        maxCount = 7;
        minCount = 4;
      }
      for (t2 = type$.List_int, n = 0, prevLen = -1, count = 0; n <= maxCode; nextLen = nextLen0) {
        ++n;
        t3 = n * 2 + 1;
        if (!(t3 < t1))
          return A.ioore(tree, t3);
        nextLen0 = tree[t3];
        ++count;
        if (count < maxCount && nextLen === nextLen0)
          continue;
        else {
          minCount0 = 3;
          if (count < minCount) {
            t3 = nextLen * 2;
            t4 = t3 + 1;
            do {
              t5 = _this.__Deflate__bitLengthTree_A;
              t5 === $ && A.throwLateFieldNI(_s14_);
              t2._as(t5);
              if (!(t3 >= 0 && t3 < 78))
                return A.ioore(t5, t3);
              t6 = t5[t3];
              if (!(t4 >= 0 && t4 < 78))
                return A.ioore(t5, t4);
              _this._sendBits$2(t6 & 65535, t5[t4] & 65535);
            } while (--count, count !== 0);
          } else if (nextLen !== 0) {
            if (nextLen !== prevLen) {
              t3 = _this.__Deflate__bitLengthTree_A;
              t3 === $ && A.throwLateFieldNI(_s14_);
              t2._as(t3);
              t4 = nextLen * 2;
              if (!(t4 >= 0 && t4 < 78))
                return A.ioore(t3, t4);
              t5 = t3[t4];
              ++t4;
              if (!(t4 < 78))
                return A.ioore(t3, t4);
              _this._sendBits$2(t5 & 65535, t3[t4] & 65535);
              --count;
            }
            t3 = _this.__Deflate__bitLengthTree_A;
            t3 === $ && A.throwLateFieldNI(_s14_);
            t2._as(t3);
            _this._sendBits$2(t3[32] & 65535, t3[33] & 65535);
            _this._sendBits$2(count - 3, 2);
          } else {
            t3 = _this.__Deflate__bitLengthTree_A;
            if (count <= 10) {
              t3 === $ && A.throwLateFieldNI(_s14_);
              t2._as(t3);
              _this._sendBits$2(t3[34] & 65535, t3[35] & 65535);
              _this._sendBits$2(count - 3, 3);
            } else {
              t3 === $ && A.throwLateFieldNI(_s14_);
              t2._as(t3);
              _this._sendBits$2(t3[36] & 65535, t3[37] & 65535);
              _this._sendBits$2(count - 11, 7);
            }
          }
        }
        if (nextLen0 === 0) {
          minCount = minCount0;
          maxCount = 138;
        } else if (nextLen === nextLen0) {
          minCount = minCount0;
          maxCount = 6;
        } else {
          maxCount = 7;
          minCount = 4;
        }
        prevLen = nextLen;
        count = 0;
      }
    },
    _putBytes$3(p, start, len) {
      var t1, t2, _this = this;
      if (len === 0)
        return;
      t1 = _this.__Deflate__pendingBuffer_A;
      t1 === $ && A.throwLateFieldNI("_pendingBuffer");
      t2 = _this.__Deflate__pending_A;
      t2 === $ && A.throwLateFieldNI("_pending");
      B.NativeUint8List_methods.setRange$4(t1, t2, t2 + len, p, start);
      _this.__Deflate__pending_A = _this.__Deflate__pending_A + len;
    },
    _putByte$1(c) {
      var t2,
        t1 = this.__Deflate__pendingBuffer_A;
      t1 === $ && A.throwLateFieldNI("_pendingBuffer");
      t2 = this.__Deflate__pending_A;
      t2 === $ && A.throwLateFieldNI("_pending");
      this.__Deflate__pending_A = t2 + 1;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (!(t2 >= 0 && t2 < t1.length))
        return A.ioore(t1, t2);
      t1[t2] = c;
    },
    _sendCode$2(c, tree) {
      var t1, t2, t3;
      type$.List_int._as(tree);
      t1 = c * 2;
      t2 = tree.length;
      if (!(t1 >= 0 && t1 < t2))
        return A.ioore(tree, t1);
      t3 = tree[t1];
      ++t1;
      if (!(t1 < t2))
        return A.ioore(tree, t1);
      this._sendBits$2(t3 & 65535, tree[t1] & 65535);
    },
    _sendBits$2(valueRenamed, $length) {
      var t2, _this = this,
        _s10_ = "_bitBuffer",
        t1 = _this.__Deflate__numValidBits_A;
      t1 === $ && A.throwLateFieldNI("_numValidBits");
      t2 = _this.__Deflate__bitBuffer_A;
      if (t1 > 16 - $length) {
        t2 === $ && A.throwLateFieldNI(_s10_);
        t1 = _this.__Deflate__bitBuffer_A = (t2 | B.JSInt_methods.$shl(valueRenamed, t1) & 65535) >>> 0;
        _this._putByte$1(t1);
        _this._putByte$1(A._rshift(t1, 8));
        _this.__Deflate__bitBuffer_A = A._rshift(valueRenamed, 16 - _this.__Deflate__numValidBits_A);
        _this.__Deflate__numValidBits_A = _this.__Deflate__numValidBits_A + ($length - 16);
      } else {
        t2 === $ && A.throwLateFieldNI(_s10_);
        _this.__Deflate__bitBuffer_A = (t2 | B.JSInt_methods.$shl(valueRenamed, t1) & 65535) >>> 0;
        _this.__Deflate__numValidBits_A = t1 + $length;
      }
    },
    _trTally$2(dist, lc) {
      var t2, t3, t4, outLength, dcode, _this = this,
        _s18_ = "_dynamicLengthTree",
        _s8_ = "_matches",
        _s16_ = "_dynamicDistTree",
        t1 = _this.__Deflate__pendingBuffer_A;
      t1 === $ && A.throwLateFieldNI("_pendingBuffer");
      t2 = _this.__Deflate__dbuf_A;
      t2 === $ && A.throwLateFieldNI("_dbuf");
      t3 = _this.__Deflate__lastLit_A;
      t3 === $ && A.throwLateFieldNI("_lastLit");
      t3 = t2 + t3 * 2;
      t2 = A._rshift(dist, 8);
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (!(t3 < t1.length))
        return A.ioore(t1, t3);
      t1[t3] = t2;
      t2 = _this.__Deflate__pendingBuffer_A;
      t3 = _this.__Deflate__dbuf_A;
      t1 = _this.__Deflate__lastLit_A;
      t3 = t3 + t1 * 2 + 1;
      t2.$flags & 2 && A.throwUnsupportedOperation(t2);
      t4 = t2.length;
      if (!(t3 < t4))
        return A.ioore(t2, t3);
      t2[t3] = dist;
      t3 = _this.__Deflate__lbuf_A;
      t3 === $ && A.throwLateFieldNI("_lbuf");
      t3 += t1;
      if (!(t3 < t4))
        return A.ioore(t2, t3);
      t2[t3] = lc;
      _this.__Deflate__lastLit_A = t1 + 1;
      if (dist === 0) {
        t1 = _this.__Deflate__dynamicLengthTree_A;
        t1 === $ && A.throwLateFieldNI(_s18_);
        t2 = lc * 2;
        if (!(t2 >= 0 && t2 < 1146))
          return A.ioore(t1, t2);
        t3 = t1[t2];
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[t2] = t3 + 1;
      } else {
        t1 = _this.__Deflate__matches_A;
        t1 === $ && A.throwLateFieldNI(_s8_);
        _this.__Deflate__matches_A = t1 + 1;
        t1 = _this.__Deflate__dynamicLengthTree_A;
        t1 === $ && A.throwLateFieldNI(_s18_);
        if (!(lc >= 0 && lc < 256))
          return A.ioore(B.List_GYx, lc);
        t2 = (B.List_GYx[lc] + 256 + 1) * 2;
        if (!(t2 < 1146))
          return A.ioore(t1, t2);
        t3 = t1[t2];
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[t2] = t3 + 1;
        t3 = _this.__Deflate__dynamicDistTree_A;
        t3 === $ && A.throwLateFieldNI(_s16_);
        t2 = A._HuffmanTree__dCode(dist - 1) * 2;
        if (!(t2 < 122))
          return A.ioore(t3, t2);
        t1 = t3[t2];
        t3.$flags & 2 && A.throwUnsupportedOperation(t3);
        t3[t2] = t1 + 1;
      }
      t1 = _this.__Deflate__lastLit_A;
      if ((t1 & 8191) === 0) {
        t2 = _this.__Deflate__level_A;
        t2 === $ && A.throwLateFieldNI("_level");
        t2 = t2 > 2;
      } else
        t2 = false;
      if (t2) {
        outLength = t1 * 8;
        t1 = _this.__Deflate__strStart_A;
        t1 === $ && A.throwLateFieldNI("_strStart");
        t2 = _this.__Deflate__blockStart_A;
        t2 === $ && A.throwLateFieldNI("_blockStart");
        for (t3 = _this.__Deflate__dynamicDistTree_A, dcode = 0; dcode < 30; ++dcode) {
          t3 === $ && A.throwLateFieldNI(_s16_);
          t4 = dcode * 2;
          if (!(t4 < 122))
            return A.ioore(t3, t4);
          outLength += t3[t4] * (5 + B.List_HmF[dcode]);
        }
        outLength = A._rshift(outLength, 3);
        t3 = _this.__Deflate__matches_A;
        t3 === $ && A.throwLateFieldNI(_s8_);
        t4 = _this.__Deflate__lastLit_A;
        if (t3 < t4 / 2 && outLength < (t1 - t2) / 2)
          return true;
        t1 = t4;
      }
      t2 = _this.__Deflate__litBufferSize_A;
      t2 === $ && A.throwLateFieldNI("_litBufferSize");
      return t1 === t2 - 1;
    },
    _compressBlock$2(ltree, dtree) {
      var lx, t2, t3, t4, dist, lc, code, extra, _this = this,
        t1 = type$.List_int;
      t1._as(ltree);
      t1._as(dtree);
      t1 = _this.__Deflate__lastLit_A;
      t1 === $ && A.throwLateFieldNI("_lastLit");
      if (t1 !== 0) {
        lx = 0;
        do {
          t1 = _this.__Deflate__pendingBuffer_A;
          t1 === $ && A.throwLateFieldNI("_pendingBuffer");
          t2 = _this.__Deflate__dbuf_A;
          t2 === $ && A.throwLateFieldNI("_dbuf");
          t2 += lx * 2;
          t3 = t1.length;
          if (!(t2 < t3))
            return A.ioore(t1, t2);
          t4 = t1[t2];
          ++t2;
          if (!(t2 < t3))
            return A.ioore(t1, t2);
          dist = t4 << 8 & 65280 | t1[t2] & 255;
          t2 = _this.__Deflate__lbuf_A;
          t2 === $ && A.throwLateFieldNI("_lbuf");
          t2 += lx;
          if (!(t2 < t3))
            return A.ioore(t1, t2);
          lc = t1[t2] & 255;
          ++lx;
          if (dist === 0)
            _this._sendCode$2(lc, ltree);
          else {
            code = B.List_GYx[lc];
            _this._sendCode$2(code + 256 + 1, ltree);
            if (!(code < 29))
              return A.ioore(B.List_1eA, code);
            extra = B.List_1eA[code];
            if (extra !== 0)
              _this._sendBits$2(lc - B.List_2Xs[code], extra);
            --dist;
            code = A._HuffmanTree__dCode(dist);
            _this._sendCode$2(code, dtree);
            if (!(code < 30))
              return A.ioore(B.List_HmF, code);
            extra = B.List_HmF[code];
            if (extra !== 0)
              _this._sendBits$2(dist - B.List_972[code], extra);
          }
        } while (lx < _this.__Deflate__lastLit_A);
      }
      _this._sendCode$2(256, ltree);
      if (513 >= ltree.length)
        return A.ioore(ltree, 513);
      _this.__Deflate__lastEOBLen_A = ltree[513];
    },
    setDataType$0() {
      var t1, n, binFreq, t2, asciiFreq,
        _s18_ = "_dynamicLengthTree";
      for (t1 = this.__Deflate__dynamicLengthTree_A, n = 0, binFreq = 0; n < 7;) {
        t1 === $ && A.throwLateFieldNI(_s18_);
        t2 = n * 2;
        if (!(t2 < 1146))
          return A.ioore(t1, t2);
        binFreq += t1[t2];
        ++n;
      }
      for (asciiFreq = 0; n < 128;) {
        t1 === $ && A.throwLateFieldNI(_s18_);
        t2 = n * 2;
        if (!(t2 < 1146))
          return A.ioore(t1, t2);
        asciiFreq += t1[t2];
        ++n;
      }
      while (n < 256) {
        t1 === $ && A.throwLateFieldNI(_s18_);
        t2 = n * 2;
        if (!(t2 < 1146))
          return A.ioore(t1, t2);
        binFreq += t1[t2];
        ++n;
      }
      this._dataType = binFreq > A._rshift(asciiFreq, 2) ? 0 : 1;
    },
    biFlush$0() {
      var _this = this,
        _s10_ = "_bitBuffer",
        t1 = _this.__Deflate__numValidBits_A;
      t1 === $ && A.throwLateFieldNI("_numValidBits");
      if (t1 === 16) {
        t1 = _this.__Deflate__bitBuffer_A;
        t1 === $ && A.throwLateFieldNI(_s10_);
        _this._putByte$1(t1);
        _this._putByte$1(A._rshift(t1, 8));
        _this.__Deflate__numValidBits_A = _this.__Deflate__bitBuffer_A = 0;
      } else if (t1 >= 8) {
        t1 = _this.__Deflate__bitBuffer_A;
        t1 === $ && A.throwLateFieldNI(_s10_);
        _this._putByte$1(t1);
        _this.__Deflate__bitBuffer_A = A._rshift(_this.__Deflate__bitBuffer_A, 8);
        _this.__Deflate__numValidBits_A = _this.__Deflate__numValidBits_A - 8;
      }
    },
    _biWindup$0() {
      var _this = this,
        _s10_ = "_bitBuffer",
        t1 = _this.__Deflate__numValidBits_A;
      t1 === $ && A.throwLateFieldNI("_numValidBits");
      if (t1 > 8) {
        t1 = _this.__Deflate__bitBuffer_A;
        t1 === $ && A.throwLateFieldNI(_s10_);
        _this._putByte$1(t1);
        _this._putByte$1(A._rshift(t1, 8));
      } else if (t1 > 0) {
        t1 = _this.__Deflate__bitBuffer_A;
        t1 === $ && A.throwLateFieldNI(_s10_);
        _this._putByte$1(t1);
      }
      _this.__Deflate__numValidBits_A = _this.__Deflate__bitBuffer_A = 0;
    },
    _flushBlockOnly$1(eof) {
      var t2, t3, maxBlIndex, optLenb, staticLenb, _this = this,
        t1 = _this.__Deflate__blockStart_A;
      t1 === $ && A.throwLateFieldNI("_blockStart");
      if (t1 >= 0)
        t2 = t1;
      else
        t2 = -1;
      t3 = _this.__Deflate__strStart_A;
      t3 === $ && A.throwLateFieldNI("_strStart");
      t1 = t3 - t1;
      t3 = _this.__Deflate__level_A;
      t3 === $ && A.throwLateFieldNI("_level");
      if (t3 > 0) {
        if (_this._dataType === 2)
          _this.setDataType$0();
        _this._lDesc._buildTree$1(_this);
        _this._dDesc._buildTree$1(_this);
        maxBlIndex = _this._buildBitLengthTree$0();
        t3 = _this.__Deflate__optimalLen_A;
        t3 === $ && A.throwLateFieldNI("_optimalLen");
        optLenb = A._rshift(t3 + 3 + 7, 3);
        t3 = _this.__Deflate__staticLen_A;
        t3 === $ && A.throwLateFieldNI("_staticLen");
        staticLenb = A._rshift(t3 + 3 + 7, 3);
        if (staticLenb <= optLenb)
          optLenb = staticLenb;
      } else {
        staticLenb = t1 + 5;
        optLenb = staticLenb;
        maxBlIndex = 0;
      }
      if (t1 + 4 <= optLenb && t2 !== -1)
        _this._trStoredBlock$3(t2, t1, eof);
      else if (staticLenb === optLenb) {
        _this._sendBits$2(2 + (eof ? 1 : 0), 3);
        _this._compressBlock$2(B.List_LCt, B.List_LJO);
      } else {
        _this._sendBits$2(4 + (eof ? 1 : 0), 3);
        t1 = _this._lDesc.___HuffmanTree_maxCode_A;
        t1 === $ && A.throwLateFieldNI("maxCode");
        t2 = _this._dDesc.___HuffmanTree_maxCode_A;
        t2 === $ && A.throwLateFieldNI("maxCode");
        _this._sendAllTrees$3(t1 + 1, t2 + 1, maxBlIndex + 1);
        t2 = _this.__Deflate__dynamicLengthTree_A;
        t2 === $ && A.throwLateFieldNI("_dynamicLengthTree");
        t1 = _this.__Deflate__dynamicDistTree_A;
        t1 === $ && A.throwLateFieldNI("_dynamicDistTree");
        _this._compressBlock$2(t2, t1);
      }
      _this._initBlock$0();
      if (eof)
        _this._biWindup$0();
      _this.__Deflate__blockStart_A = _this.__Deflate__strStart_A;
      _this._flushPending$0();
    },
    _deflateStored$1(flush) {
      var maxBlockSize, t2, t3, maxStart, t4, _this = this,
        t1 = _this.__Deflate__pendingBufferSize_A;
      t1 === $ && A.throwLateFieldNI("_pendingBufferSize");
      maxBlockSize = t1 - 5;
      maxBlockSize = 65535 > maxBlockSize ? maxBlockSize : 65535;
      for (t1 = flush === B._DeflateFlushMode_0;;) {
        t2 = _this.__Deflate__lookAhead_A;
        t2 === $ && A.throwLateFieldNI("_lookAhead");
        if (t2 <= 1) {
          _this._fillWindow$0();
          t2 = _this.__Deflate__lookAhead_A;
          t3 = t2 === 0;
          if (t3 && t1)
            return 0;
          if (t3)
            break;
        }
        t3 = _this.__Deflate__strStart_A;
        t3 === $ && A.throwLateFieldNI("_strStart");
        t2 = _this.__Deflate__strStart_A = t3 + t2;
        _this.__Deflate__lookAhead_A = 0;
        t3 = _this.__Deflate__blockStart_A;
        t3 === $ && A.throwLateFieldNI("_blockStart");
        maxStart = t3 + maxBlockSize;
        if (t2 >= maxStart) {
          _this.__Deflate__lookAhead_A = t2 - maxStart;
          _this.__Deflate__strStart_A = maxStart;
          _this._flushBlockOnly$1(false);
        }
        t2 = _this.__Deflate__strStart_A;
        t3 = _this.__Deflate__blockStart_A;
        t4 = _this.__Deflate__windowSize_A;
        t4 === $ && A.throwLateFieldNI("_windowSize");
        if (t2 - t3 >= t4 - 262)
          _this._flushBlockOnly$1(false);
      }
      t1 = flush === B._DeflateFlushMode_3;
      _this._flushBlockOnly$1(t1);
      return t1 ? 3 : 1;
    },
    _trStoredBlock$3(buf, storedLen, eof) {
      var t1, _this = this;
      _this._sendBits$2(eof ? 1 : 0, 3);
      _this._biWindup$0();
      _this.__Deflate__lastEOBLen_A = 8;
      _this._putByte$1(storedLen);
      _this._putByte$1(A._rshift(storedLen, 8));
      t1 = (~storedLen >>> 0) + 65536 & 65535;
      _this._putByte$1(t1);
      _this._putByte$1(A._rshift(t1, 8));
      t1 = _this.__Deflate__window_A;
      t1 === $ && A.throwLateFieldNI("_window");
      _this._putBytes$3(t1, buf, storedLen);
    },
    _fillWindow$0() {
      var t2, t3, t4, more, p, t5, p0, n, m, t6, t7, _this = this,
        _s11_ = "_windowSize",
        t1 = _this._input;
      do {
        t2 = _this.__Deflate__actualWindowSize_A;
        t2 === $ && A.throwLateFieldNI("_actualWindowSize");
        t3 = _this.__Deflate__lookAhead_A;
        t3 === $ && A.throwLateFieldNI("_lookAhead");
        t4 = _this.__Deflate__strStart_A;
        t4 === $ && A.throwLateFieldNI("_strStart");
        more = t2 - t3 - t4;
        if (more === 0 && t4 === 0 && t3 === 0) {
          t2 = _this.__Deflate__windowSize_A;
          t2 === $ && A.throwLateFieldNI(_s11_);
          more = t2;
        } else {
          t2 = _this.__Deflate__windowSize_A;
          t2 === $ && A.throwLateFieldNI(_s11_);
          if (t4 >= t2 + t2 - 262) {
            t3 = _this.__Deflate__window_A;
            t3 === $ && A.throwLateFieldNI("_window");
            B.NativeUint8List_methods.setRange$4(t3, 0, t2, t3, t2);
            t2 = _this._matchStart;
            p = _this.__Deflate__windowSize_A;
            _this._matchStart = t2 - p;
            _this.__Deflate__strStart_A = _this.__Deflate__strStart_A - p;
            t2 = _this.__Deflate__blockStart_A;
            t2 === $ && A.throwLateFieldNI("_blockStart");
            _this.__Deflate__blockStart_A = t2 - p;
            t2 = _this.__Deflate__hashSize_A;
            t2 === $ && A.throwLateFieldNI("_hashSize");
            t3 = _this.__Deflate__head_A;
            t3 === $ && A.throwLateFieldNI("_head");
            t4 = t3.length;
            t5 = t3.$flags | 0;
            p0 = t2;
            n = p0;
            do {
              --p0;
              if (!(p0 >= 0 && p0 < t4))
                return A.ioore(t3, p0);
              m = t3[p0] & 65535;
              t2 = m >= p ? m - p : 0;
              t5 & 2 && A.throwUnsupportedOperation(t3);
              t3[p0] = t2;
            } while (--n, n !== 0);
            t2 = _this.__Deflate__prev_A;
            t2 === $ && A.throwLateFieldNI("_prev");
            t3 = t2.length;
            t4 = t2.$flags | 0;
            p0 = p;
            n = p0;
            do {
              --p0;
              if (!(p0 >= 0 && p0 < t3))
                return A.ioore(t2, p0);
              m = t2[p0] & 65535;
              t5 = m >= p ? m - p : 0;
              t4 & 2 && A.throwUnsupportedOperation(t2);
              t2[p0] = t5;
            } while (--n, n !== 0);
            more += p;
          }
        }
        t2 = t1._position;
        t3 = t1.__InputMemoryStream__length_A;
        t3 === $ && A.throwLateFieldNI("_length");
        if (t2 >= t3)
          return;
        t2 = _this.__Deflate__window_A;
        t2 === $ && A.throwLateFieldNI("_window");
        n = _this._readBuf$3(t2, _this.__Deflate__strStart_A + _this.__Deflate__lookAhead_A, more);
        t2 = _this.__Deflate__lookAhead_A = _this.__Deflate__lookAhead_A + n;
        if (t2 >= 3) {
          t3 = _this.__Deflate__window_A;
          t4 = _this.__Deflate__strStart_A;
          t5 = t3.length;
          if (t4 >>> 0 !== t4 || t4 >= t5)
            return A.ioore(t3, t4);
          t6 = t3[t4] & 255;
          _this.__Deflate__insertHash_A = t6;
          t7 = _this.__Deflate__hashShift_A;
          t7 === $ && A.throwLateFieldNI("_hashShift");
          t7 = B.JSInt_methods.$shl(t6, t7);
          ++t4;
          if (!(t4 < t5))
            return A.ioore(t3, t4);
          t4 = t3[t4];
          t3 = _this.__Deflate__hashMask_A;
          t3 === $ && A.throwLateFieldNI("_hashMask");
          _this.__Deflate__insertHash_A = ((t7 ^ t4 & 255) & t3) >>> 0;
        }
      } while (t2 < 262 && !(t1._position >= t1.__InputMemoryStream__length_A));
    },
    _deflateFast$1(flush) {
      var t1, t2, hashHead, t3, t4, t5, t6, t7, t8, bflush, t9, _this = this,
        _s11_ = "_insertHash",
        _s10_ = "_hashShift",
        _s7_ = "_window",
        _s9_ = "_strStart",
        _s9_0 = "_hashMask",
        _s11_0 = "_windowMask";
      for (t1 = flush === B._DeflateFlushMode_0, t2 = $.Deflate____config.__late_helper$_name, hashHead = 0;;) {
        t3 = _this.__Deflate__lookAhead_A;
        t3 === $ && A.throwLateFieldNI("_lookAhead");
        if (t3 < 262) {
          _this._fillWindow$0();
          t3 = _this.__Deflate__lookAhead_A;
          if (t3 < 262 && t1)
            return 0;
          if (t3 === 0)
            break;
        }
        if (t3 >= 3) {
          t3 = _this.__Deflate__insertHash_A;
          t3 === $ && A.throwLateFieldNI(_s11_);
          t4 = _this.__Deflate__hashShift_A;
          t4 === $ && A.throwLateFieldNI(_s10_);
          t4 = B.JSInt_methods.$shl(t3, t4);
          t3 = _this.__Deflate__window_A;
          t3 === $ && A.throwLateFieldNI(_s7_);
          t5 = _this.__Deflate__strStart_A;
          t5 === $ && A.throwLateFieldNI(_s9_);
          t6 = t5 + 2;
          if (!(t6 >= 0 && t6 < t3.length))
            return A.ioore(t3, t6);
          t6 = t3[t6];
          t3 = _this.__Deflate__hashMask_A;
          t3 === $ && A.throwLateFieldNI(_s9_0);
          t3 = ((t4 ^ t6 & 255) & t3) >>> 0;
          _this.__Deflate__insertHash_A = t3;
          t6 = _this.__Deflate__head_A;
          t6 === $ && A.throwLateFieldNI("_head");
          if (!(t3 < t6.length))
            return A.ioore(t6, t3);
          t4 = t6[t3];
          hashHead = t4 & 65535;
          t7 = _this.__Deflate__prev_A;
          t7 === $ && A.throwLateFieldNI("_prev");
          t8 = _this.__Deflate__windowMask_A;
          t8 === $ && A.throwLateFieldNI(_s11_0);
          t8 = (t5 & t8) >>> 0;
          t7.$flags & 2 && A.throwUnsupportedOperation(t7);
          if (!(t8 >= 0 && t8 < t7.length))
            return A.ioore(t7, t8);
          t7[t8] = t4;
          t6.$flags & 2 && A.throwUnsupportedOperation(t6);
          t6[t3] = t5;
        }
        if (hashHead !== 0) {
          t3 = _this.__Deflate__strStart_A;
          t3 === $ && A.throwLateFieldNI(_s9_);
          t4 = _this.__Deflate__windowSize_A;
          t4 === $ && A.throwLateFieldNI("_windowSize");
          t4 = (t3 - hashHead & 65535) <= t4 - 262;
          t3 = t4;
        } else
          t3 = false;
        if (t3) {
          t3 = _this.__Deflate__strategy_A;
          t3 === $ && A.throwLateFieldNI("_strategy");
          if (t3 !== 2)
            _this.__Deflate__matchLength_A = _this._longestMatch$1(hashHead);
        }
        t3 = _this.__Deflate__matchLength_A;
        t3 === $ && A.throwLateFieldNI("_matchLength");
        t4 = _this.__Deflate__strStart_A;
        if (t3 >= 3) {
          t4 === $ && A.throwLateFieldNI(_s9_);
          bflush = _this._trTally$2(t4 - _this._matchStart, t3 - 3);
          t3 = _this.__Deflate__lookAhead_A;
          t4 = _this.__Deflate__matchLength_A;
          t3 -= t4;
          _this.__Deflate__lookAhead_A = t3;
          t5 = $.Deflate____config._value;
          if (t5 === $.Deflate____config)
            A.throwExpression(A.LateError$fieldNI(t2));
          if (t4 <= t5.maxLazy && t3 >= 3) {
            t3 = _this.__Deflate__matchLength_A = t4 - 1;
            do {
              t4 = _this.__Deflate__strStart_A = _this.__Deflate__strStart_A + 1;
              t5 = _this.__Deflate__insertHash_A;
              t5 === $ && A.throwLateFieldNI(_s11_);
              t6 = _this.__Deflate__hashShift_A;
              t6 === $ && A.throwLateFieldNI(_s10_);
              t6 = B.JSInt_methods.$shl(t5, t6);
              t5 = _this.__Deflate__window_A;
              t5 === $ && A.throwLateFieldNI(_s7_);
              t7 = t4 + 2;
              if (!(t7 >= 0 && t7 < t5.length))
                return A.ioore(t5, t7);
              t7 = t5[t7];
              t5 = _this.__Deflate__hashMask_A;
              t5 === $ && A.throwLateFieldNI(_s9_0);
              t5 = ((t6 ^ t7 & 255) & t5) >>> 0;
              _this.__Deflate__insertHash_A = t5;
              t7 = _this.__Deflate__head_A;
              t7 === $ && A.throwLateFieldNI("_head");
              if (!(t5 < t7.length))
                return A.ioore(t7, t5);
              t6 = t7[t5];
              hashHead = t6 & 65535;
              t8 = _this.__Deflate__prev_A;
              t8 === $ && A.throwLateFieldNI("_prev");
              t9 = _this.__Deflate__windowMask_A;
              t9 === $ && A.throwLateFieldNI(_s11_0);
              t9 = (t4 & t9) >>> 0;
              t8.$flags & 2 && A.throwUnsupportedOperation(t8);
              if (!(t9 >= 0 && t9 < t8.length))
                return A.ioore(t8, t9);
              t8[t9] = t6;
              t7.$flags & 2 && A.throwUnsupportedOperation(t7);
              t7[t5] = t4;
            } while (t3 = _this.__Deflate__matchLength_A = t3 - 1, t3 !== 0);
            _this.__Deflate__strStart_A = t4 + 1;
          } else {
            t3 = _this.__Deflate__strStart_A = _this.__Deflate__strStart_A + t4;
            _this.__Deflate__matchLength_A = 0;
            t4 = _this.__Deflate__window_A;
            t4 === $ && A.throwLateFieldNI(_s7_);
            t5 = t4.length;
            if (!(t3 >= 0 && t3 < t5))
              return A.ioore(t4, t3);
            t6 = t4[t3] & 255;
            _this.__Deflate__insertHash_A = t6;
            t7 = _this.__Deflate__hashShift_A;
            t7 === $ && A.throwLateFieldNI(_s10_);
            t7 = B.JSInt_methods.$shl(t6, t7);
            ++t3;
            if (!(t3 < t5))
              return A.ioore(t4, t3);
            t3 = t4[t3];
            t4 = _this.__Deflate__hashMask_A;
            t4 === $ && A.throwLateFieldNI(_s9_0);
            _this.__Deflate__insertHash_A = ((t7 ^ t3 & 255) & t4) >>> 0;
          }
        } else {
          t3 = _this.__Deflate__window_A;
          t3 === $ && A.throwLateFieldNI(_s7_);
          t4 === $ && A.throwLateFieldNI(_s9_);
          if (!(t4 >= 0 && t4 < t3.length))
            return A.ioore(t3, t4);
          bflush = _this._trTally$2(0, t3[t4] & 255);
          _this.__Deflate__lookAhead_A = _this.__Deflate__lookAhead_A - 1;
          _this.__Deflate__strStart_A = _this.__Deflate__strStart_A + 1;
        }
        if (bflush)
          _this._flushBlockOnly$1(false);
      }
      t1 = flush === B._DeflateFlushMode_3;
      _this._flushBlockOnly$1(t1);
      return t1 ? 3 : 1;
    },
    _deflateSlow$1(flush) {
      var t1, t2, hashHead, t3, t4, t5, t6, t7, t8, maxInsert, bflush, t9, _this = this,
        _s11_ = "_insertHash",
        _s10_ = "_hashShift",
        _s7_ = "_window",
        _s9_ = "_strStart",
        _s9_0 = "_hashMask",
        _s11_0 = "_windowMask",
        _s15_ = "_matchAvailable";
      for (t1 = flush === B._DeflateFlushMode_0, t2 = $.Deflate____config.__late_helper$_name, hashHead = 0;;) {
        t3 = _this.__Deflate__lookAhead_A;
        t3 === $ && A.throwLateFieldNI("_lookAhead");
        if (t3 < 262) {
          _this._fillWindow$0();
          t3 = _this.__Deflate__lookAhead_A;
          if (t3 < 262 && t1)
            return 0;
          if (t3 === 0)
            break;
        }
        if (t3 >= 3) {
          t3 = _this.__Deflate__insertHash_A;
          t3 === $ && A.throwLateFieldNI(_s11_);
          t4 = _this.__Deflate__hashShift_A;
          t4 === $ && A.throwLateFieldNI(_s10_);
          t4 = B.JSInt_methods.$shl(t3, t4);
          t3 = _this.__Deflate__window_A;
          t3 === $ && A.throwLateFieldNI(_s7_);
          t5 = _this.__Deflate__strStart_A;
          t5 === $ && A.throwLateFieldNI(_s9_);
          t6 = t5 + 2;
          if (!(t6 >= 0 && t6 < t3.length))
            return A.ioore(t3, t6);
          t6 = t3[t6];
          t3 = _this.__Deflate__hashMask_A;
          t3 === $ && A.throwLateFieldNI(_s9_0);
          t3 = ((t4 ^ t6 & 255) & t3) >>> 0;
          _this.__Deflate__insertHash_A = t3;
          t6 = _this.__Deflate__head_A;
          t6 === $ && A.throwLateFieldNI("_head");
          if (!(t3 < t6.length))
            return A.ioore(t6, t3);
          t4 = t6[t3];
          hashHead = t4 & 65535;
          t7 = _this.__Deflate__prev_A;
          t7 === $ && A.throwLateFieldNI("_prev");
          t8 = _this.__Deflate__windowMask_A;
          t8 === $ && A.throwLateFieldNI(_s11_0);
          t8 = (t5 & t8) >>> 0;
          t7.$flags & 2 && A.throwUnsupportedOperation(t7);
          if (!(t8 >= 0 && t8 < t7.length))
            return A.ioore(t7, t8);
          t7[t8] = t4;
          t6.$flags & 2 && A.throwUnsupportedOperation(t6);
          t6[t3] = t5;
        }
        t3 = _this.__Deflate__matchLength_A;
        t3 === $ && A.throwLateFieldNI("_matchLength");
        _this.__Deflate__prevLength_A = t3;
        _this.__Deflate__prevMatch_A = _this._matchStart;
        _this.__Deflate__matchLength_A = 2;
        t4 = false;
        if (hashHead !== 0) {
          t5 = $.Deflate____config._value;
          if (t5 === $.Deflate____config)
            A.throwExpression(A.LateError$fieldNI(t2));
          if (t3 < t5.maxLazy) {
            t3 = _this.__Deflate__strStart_A;
            t3 === $ && A.throwLateFieldNI(_s9_);
            t4 = _this.__Deflate__windowSize_A;
            t4 === $ && A.throwLateFieldNI("_windowSize");
            t4 = (t3 - hashHead & 65535) <= t4 - 262;
            t3 = t4;
          } else
            t3 = t4;
        } else
          t3 = t4;
        t4 = 2;
        if (t3) {
          t3 = _this.__Deflate__strategy_A;
          t3 === $ && A.throwLateFieldNI("_strategy");
          if (t3 !== 2) {
            t3 = _this._longestMatch$1(hashHead);
            _this.__Deflate__matchLength_A = t3;
          } else
            t3 = t4;
          t5 = false;
          if (t3 <= 5)
            if (_this.__Deflate__strategy_A !== 1) {
              if (t3 === 3) {
                t5 = _this.__Deflate__strStart_A;
                t5 === $ && A.throwLateFieldNI(_s9_);
                t5 = t5 - _this._matchStart > 4096;
              }
            } else
              t5 = true;
          if (t5) {
            _this.__Deflate__matchLength_A = 2;
            t3 = t4;
          }
        } else
          t3 = t4;
        t4 = _this.__Deflate__prevLength_A;
        if (t4 >= 3 && t3 <= t4) {
          t3 = _this.__Deflate__strStart_A;
          t3 === $ && A.throwLateFieldNI(_s9_);
          maxInsert = t3 + _this.__Deflate__lookAhead_A - 3;
          bflush = _this._trTally$2(t3 - 1 - _this.__Deflate__prevMatch_A, t4 - 3);
          t4 = _this.__Deflate__lookAhead_A;
          t3 = _this.__Deflate__prevLength_A;
          _this.__Deflate__lookAhead_A = t4 - (t3 - 1);
          t3 = _this.__Deflate__prevLength_A = t3 - 2;
          do {
            t4 = _this.__Deflate__strStart_A = _this.__Deflate__strStart_A + 1;
            if (t4 <= maxInsert) {
              t5 = _this.__Deflate__insertHash_A;
              t5 === $ && A.throwLateFieldNI(_s11_);
              t6 = _this.__Deflate__hashShift_A;
              t6 === $ && A.throwLateFieldNI(_s10_);
              t6 = B.JSInt_methods.$shl(t5, t6);
              t5 = _this.__Deflate__window_A;
              t5 === $ && A.throwLateFieldNI(_s7_);
              t7 = t4 + 2;
              if (!(t7 >= 0 && t7 < t5.length))
                return A.ioore(t5, t7);
              t7 = t5[t7];
              t5 = _this.__Deflate__hashMask_A;
              t5 === $ && A.throwLateFieldNI(_s9_0);
              t5 = ((t6 ^ t7 & 255) & t5) >>> 0;
              _this.__Deflate__insertHash_A = t5;
              t7 = _this.__Deflate__head_A;
              t7 === $ && A.throwLateFieldNI("_head");
              if (!(t5 < t7.length))
                return A.ioore(t7, t5);
              t6 = t7[t5];
              hashHead = t6 & 65535;
              t8 = _this.__Deflate__prev_A;
              t8 === $ && A.throwLateFieldNI("_prev");
              t9 = _this.__Deflate__windowMask_A;
              t9 === $ && A.throwLateFieldNI(_s11_0);
              t9 = (t4 & t9) >>> 0;
              t8.$flags & 2 && A.throwUnsupportedOperation(t8);
              if (!(t9 >= 0 && t9 < t8.length))
                return A.ioore(t8, t9);
              t8[t9] = t6;
              t7.$flags & 2 && A.throwUnsupportedOperation(t7);
              t7[t5] = t4;
            }
          } while (t3 = _this.__Deflate__prevLength_A = t3 - 1, t3 !== 0);
          _this.__Deflate__matchAvailable_A = 0;
          _this.__Deflate__matchLength_A = 2;
          _this.__Deflate__strStart_A = t4 + 1;
          if (bflush)
            _this._flushBlockOnly$1(false);
        } else {
          t3 = _this.__Deflate__matchAvailable_A;
          t3 === $ && A.throwLateFieldNI(_s15_);
          if (t3 !== 0) {
            t3 = _this.__Deflate__window_A;
            t3 === $ && A.throwLateFieldNI(_s7_);
            t4 = _this.__Deflate__strStart_A;
            t4 === $ && A.throwLateFieldNI(_s9_);
            --t4;
            if (!(t4 >= 0 && t4 < t3.length))
              return A.ioore(t3, t4);
            if (_this._trTally$2(0, t3[t4] & 255))
              _this._flushBlockOnly$1(false);
            _this.__Deflate__strStart_A = _this.__Deflate__strStart_A + 1;
            _this.__Deflate__lookAhead_A = _this.__Deflate__lookAhead_A - 1;
          } else {
            _this.__Deflate__matchAvailable_A = 1;
            t3 = _this.__Deflate__strStart_A;
            t3 === $ && A.throwLateFieldNI(_s9_);
            _this.__Deflate__strStart_A = t3 + 1;
            _this.__Deflate__lookAhead_A = _this.__Deflate__lookAhead_A - 1;
          }
        }
      }
      t1 = _this.__Deflate__matchAvailable_A;
      t1 === $ && A.throwLateFieldNI(_s15_);
      if (t1 !== 0) {
        t1 = _this.__Deflate__window_A;
        t1 === $ && A.throwLateFieldNI(_s7_);
        t2 = _this.__Deflate__strStart_A;
        t2 === $ && A.throwLateFieldNI(_s9_);
        --t2;
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        _this._trTally$2(0, t1[t2] & 255);
        _this.__Deflate__matchAvailable_A = 0;
      }
      t1 = flush === B._DeflateFlushMode_3;
      _this._flushBlockOnly$1(t1);
      return t1 ? 3 : 1;
    },
    _longestMatch$1(curMatch) {
      var t2, t3, limit, niceMatch, strend, t4, t5, t6, t7, scanEnd1, scanEnd, scan, bestLen, scan0, match, len, _this = this,
        chainLength = $.Deflate____config._readField$0().maxChain,
        t1 = _this.__Deflate__strStart_A;
      t1 === $ && A.throwLateFieldNI("_strStart");
      t2 = _this.__Deflate__prevLength_A;
      t2 === $ && A.throwLateFieldNI("_prevLength");
      t3 = _this.__Deflate__windowSize_A;
      t3 === $ && A.throwLateFieldNI("_windowSize");
      t3 -= 262;
      limit = t1 > t3 ? t1 - t3 : 0;
      niceMatch = $.Deflate____config._readField$0().niceLength;
      t3 = _this.__Deflate__windowMask_A;
      t3 === $ && A.throwLateFieldNI("_windowMask");
      strend = _this.__Deflate__strStart_A + 258;
      t4 = _this.__Deflate__window_A;
      t4 === $ && A.throwLateFieldNI("_window");
      t5 = t1 + t2;
      t6 = t5 - 1;
      t7 = t4.length;
      if (!(t6 >= 0 && t6 < t7))
        return A.ioore(t4, t6);
      scanEnd1 = t4[t6];
      if (!(t5 >= 0 && t5 < t7))
        return A.ioore(t4, t5);
      scanEnd = t4[t5];
      if (_this.__Deflate__prevLength_A >= $.Deflate____config._readField$0().goodLength)
        chainLength = chainLength >>> 2;
      t4 = _this.__Deflate__lookAhead_A;
      t4 === $ && A.throwLateFieldNI("_lookAhead");
      if (niceMatch > t4)
        niceMatch = t4;
      scan = strend - 258;
      bestLen = t2;
      scan0 = t1;
      do {
        c$0: {
          t1 = _this.__Deflate__window_A;
          t2 = curMatch + bestLen;
          t4 = t1.length;
          if (!(t2 >= 0 && t2 < t4))
            return A.ioore(t1, t2);
          t5 = true;
          if (t1[t2] === scanEnd) {
            --t2;
            if (!(t2 >= 0))
              return A.ioore(t1, t2);
            if (t1[t2] === scanEnd1) {
              if (!(curMatch >= 0 && curMatch < t4))
                return A.ioore(t1, curMatch);
              t2 = t1[curMatch];
              if (!(scan0 >= 0 && scan0 < t4))
                return A.ioore(t1, scan0);
              if (t2 === t1[scan0]) {
                match = curMatch + 1;
                if (!(match < t4))
                  return A.ioore(t1, match);
                t2 = t1[match];
                t5 = scan0 + 1;
                if (!(t5 < t4))
                  return A.ioore(t1, t5);
                t5 = t2 !== t1[t5];
                t2 = t5;
              } else {
                t2 = t5;
                match = curMatch;
              }
            } else {
              t2 = t5;
              match = curMatch;
            }
          } else {
            t2 = t5;
            match = curMatch;
          }
          if (t2)
            break c$0;
          scan0 += 2;
          ++match;
          do {
            ++scan0;
            if (!(scan0 >= 0 && scan0 < t4))
              return A.ioore(t1, scan0);
            t2 = t1[scan0];
            ++match;
            if (!(match >= 0 && match < t4))
              return A.ioore(t1, match);
            t5 = false;
            if (t2 === t1[match]) {
              ++scan0;
              if (!(scan0 < t4))
                return A.ioore(t1, scan0);
              t2 = t1[scan0];
              ++match;
              if (!(match < t4))
                return A.ioore(t1, match);
              if (t2 === t1[match]) {
                ++scan0;
                if (!(scan0 < t4))
                  return A.ioore(t1, scan0);
                t2 = t1[scan0];
                ++match;
                if (!(match < t4))
                  return A.ioore(t1, match);
                if (t2 === t1[match]) {
                  ++scan0;
                  if (!(scan0 < t4))
                    return A.ioore(t1, scan0);
                  t2 = t1[scan0];
                  ++match;
                  if (!(match < t4))
                    return A.ioore(t1, match);
                  if (t2 === t1[match]) {
                    ++scan0;
                    if (!(scan0 < t4))
                      return A.ioore(t1, scan0);
                    t2 = t1[scan0];
                    ++match;
                    if (!(match < t4))
                      return A.ioore(t1, match);
                    if (t2 === t1[match]) {
                      ++scan0;
                      if (!(scan0 < t4))
                        return A.ioore(t1, scan0);
                      t2 = t1[scan0];
                      ++match;
                      if (!(match < t4))
                        return A.ioore(t1, match);
                      if (t2 === t1[match]) {
                        ++scan0;
                        if (!(scan0 < t4))
                          return A.ioore(t1, scan0);
                        t2 = t1[scan0];
                        ++match;
                        if (!(match < t4))
                          return A.ioore(t1, match);
                        if (t2 === t1[match]) {
                          ++scan0;
                          if (!(scan0 < t4))
                            return A.ioore(t1, scan0);
                          t2 = t1[scan0];
                          ++match;
                          if (!(match < t4))
                            return A.ioore(t1, match);
                          t2 = t2 === t1[match] && scan0 < strend;
                        } else
                          t2 = t5;
                      } else
                        t2 = t5;
                    } else
                      t2 = t5;
                  } else
                    t2 = t5;
                } else
                  t2 = t5;
              } else
                t2 = t5;
            } else
              t2 = t5;
          } while (t2);
          len = 258 - (strend - scan0);
          if (len > bestLen) {
            _this._matchStart = curMatch;
            if (len >= niceMatch) {
              bestLen = len;
              break;
            }
            t1 = _this.__Deflate__window_A;
            t2 = scan + len;
            t4 = t2 - 1;
            t5 = t1.length;
            if (!(t4 >= 0 && t4 < t5))
              return A.ioore(t1, t4);
            scanEnd1 = t1[t4];
            if (!(t2 < t5))
              return A.ioore(t1, t2);
            scanEnd = t1[t2];
            bestLen = len;
          }
          scan0 = scan;
        }
        t1 = _this.__Deflate__prev_A;
        t1 === $ && A.throwLateFieldNI("_prev");
        t2 = curMatch & t3;
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        curMatch = t1[t2] & 65535;
        if (curMatch > limit) {
          --chainLength;
          t1 = chainLength !== 0;
        } else
          t1 = false;
      } while (t1);
      t1 = _this.__Deflate__lookAhead_A;
      if (bestLen <= t1)
        return bestLen;
      return t1;
    },
    _readBuf$3(buf, start, size) {
      var t1, t2, bytes, len, len0, _this = this;
      if (size !== 0) {
        t1 = _this._input;
        t2 = t1._position;
        t1 = t1.__InputMemoryStream__length_A;
        t1 === $ && A.throwLateFieldNI("_length");
        t1 = t2 >= t1;
      } else
        t1 = true;
      if (t1)
        return 0;
      t1 = _this._input;
      bytes = t1.subset$2$length$position(size, t1._position);
      t1._position = t1._position + bytes.get$length(0);
      len = bytes.get$length(0);
      if (len === 0)
        return 0;
      bytes = bytes.toUint8List$0();
      len0 = bytes.length;
      if (len > len0)
        len = len0;
      B.NativeUint8List_methods.setRange$3(buf, start, start + len, bytes);
      _this.total += len;
      _this.crc32 = A.getCrc32(bytes, _this.crc32);
      return len;
    },
    _flushPending$0() {
      var t2, _this = this,
        t1 = _this.__Deflate__pending_A;
      t1 === $ && A.throwLateFieldNI("_pending");
      t2 = _this.__Deflate__pendingBuffer_A;
      t2 === $ && A.throwLateFieldNI("_pendingBuffer");
      _this._output.writeBytes$2$length(t2, t1);
      t2 = _this.__Deflate__pendingOut_A;
      t2 === $ && A.throwLateFieldNI("_pendingOut");
      _this.__Deflate__pendingOut_A = t2 + t1;
      t1 = _this.__Deflate__pending_A - t1;
      _this.__Deflate__pending_A = t1;
      if (t1 === 0)
        _this.__Deflate__pendingOut_A = 0;
    },
    _getConfig$1(level) {
      switch (level) {
        case 0:
          return new A._DeflaterConfig(0, 0, 0, 0, 0);
        case 1:
          return new A._DeflaterConfig(4, 4, 8, 4, 1);
        case 2:
          return new A._DeflaterConfig(4, 5, 16, 8, 1);
        case 3:
          return new A._DeflaterConfig(4, 6, 32, 32, 1);
        case 4:
          return new A._DeflaterConfig(4, 4, 16, 16, 2);
        case 5:
          return new A._DeflaterConfig(8, 16, 32, 32, 2);
        case 6:
          return new A._DeflaterConfig(8, 16, 128, 128, 2);
        case 7:
          return new A._DeflaterConfig(8, 32, 128, 256, 2);
        case 8:
          return new A._DeflaterConfig(32, 128, 258, 1024, 2);
        case 9:
          return new A._DeflaterConfig(32, 258, 258, 4096, 2);
      }
      return null;
    }
  };
  A._DeflaterConfig.prototype = {};
  A._HuffmanTree.prototype = {
    _genBitlen$1(s) {
      var t2, stree, extra, baseRenamed, maxLength, t3, bits, t4, t5, t6, t7, h, overflow, n, t8, t9, t10, xbits, f, bits0, m, _this = this,
        _s11_ = "_optimalLen",
        t1 = _this.___HuffmanTree_dynamicTree_A;
      t1 === $ && A.throwLateFieldNI("dynamicTree");
      t2 = _this.___HuffmanTree_staticDesc_A;
      t2 === $ && A.throwLateFieldNI("staticDesc");
      stree = t2.staticTree;
      extra = t2.extraBits;
      baseRenamed = t2.extraBase;
      maxLength = t2.maxLength;
      for (t2 = s._bitLengthCount, t3 = t2.$flags | 0, bits = 0; bits <= 15; ++bits) {
        t3 & 2 && A.throwUnsupportedOperation(t2);
        t2[bits] = 0;
      }
      t4 = s._heap;
      t5 = s.__Deflate__heapMax_A;
      t5 === $ && A.throwLateFieldNI("_heapMax");
      if (!(t5 >= 0 && t5 < 573))
        return A.ioore(t4, t5);
      t6 = t4[t5] * 2 + 1;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      t7 = t1.length;
      if (!(t6 >= 0 && t6 < t7))
        return A.ioore(t1, t6);
      t1[t6] = 0;
      for (h = t5 + 1, t5 = stree != null, t6 = extra.length, overflow = 0; h < 573; ++h) {
        n = t4[h];
        t8 = n * 2;
        t9 = t8 + 1;
        if (!(t9 >= 0 && t9 < t7))
          return A.ioore(t1, t9);
        t10 = t1[t9] * 2 + 1;
        if (!(t10 >= 0 && t10 < t7))
          return A.ioore(t1, t10);
        bits = t1[t10] + 1;
        if (bits > maxLength) {
          ++overflow;
          bits = maxLength;
        }
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[t9] = bits;
        t10 = _this.___HuffmanTree_maxCode_A;
        t10 === $ && A.throwLateFieldNI("maxCode");
        if (n > t10)
          continue;
        if (!(bits >= 0 && bits < 16))
          return A.ioore(t2, bits);
        t10 = t2[bits];
        t3 & 2 && A.throwUnsupportedOperation(t2);
        t2[bits] = t10 + 1;
        if (n >= baseRenamed) {
          t10 = n - baseRenamed;
          if (!(t10 >= 0 && t10 < t6))
            return A.ioore(extra, t10);
          xbits = extra[t10];
        } else
          xbits = 0;
        if (!(t8 >= 0 && t8 < t7))
          return A.ioore(t1, t8);
        f = t1[t8];
        t8 = s.__Deflate__optimalLen_A;
        t8 === $ && A.throwLateFieldNI(_s11_);
        s.__Deflate__optimalLen_A = t8 + f * (bits + xbits);
        if (t5) {
          t8 = s.__Deflate__staticLen_A;
          t8 === $ && A.throwLateFieldNI("_staticLen");
          if (!(t9 < stree.length))
            return A.ioore(stree, t9);
          s.__Deflate__staticLen_A = t8 + f * (stree[t9] + xbits);
        }
      }
      if (overflow === 0)
        return;
      bits = maxLength - 1;
      do {
        bits0 = bits;
        for (;;) {
          if (!(bits0 >= 0 && bits0 < 16))
            return A.ioore(t2, bits0);
          t5 = t2[bits0];
          if (!(t5 === 0))
            break;
          --bits0;
        }
        t3 & 2 && A.throwUnsupportedOperation(t2);
        t2[bits0] = t5 - 1;
        t5 = bits0 + 1;
        if (!(t5 < 16))
          return A.ioore(t2, t5);
        t2[t5] = t2[t5] + 2;
        if (!(maxLength < 16))
          return A.ioore(t2, maxLength);
        t2[maxLength] = t2[maxLength] - 1;
        overflow -= 2;
      } while (overflow > 0);
      for (bits = maxLength; bits !== 0; --bits) {
        if (!(bits >= 0))
          return A.ioore(t2, bits);
        n = t2[bits];
        while (n !== 0) {
          --h;
          if (!(h >= 0 && h < 573))
            return A.ioore(t4, h);
          m = t4[h];
          t3 = _this.___HuffmanTree_maxCode_A;
          t3 === $ && A.throwLateFieldNI("maxCode");
          if (m > t3)
            continue;
          t3 = m * 2;
          t5 = t3 + 1;
          if (!(t5 >= 0 && t5 < t7))
            return A.ioore(t1, t5);
          t6 = t1[t5];
          if (t6 !== bits) {
            t8 = s.__Deflate__optimalLen_A;
            t8 === $ && A.throwLateFieldNI(_s11_);
            if (!(t3 >= 0 && t3 < t7))
              return A.ioore(t1, t3);
            s.__Deflate__optimalLen_A = t8 + (bits - t6) * t1[t3];
            t1.$flags & 2 && A.throwUnsupportedOperation(t1);
            t1[t5] = bits;
          }
          --n;
        }
      }
    },
    _buildTree$1(s) {
      var t2, stree, elems, t3, t4, t5, t6, t7, n, maxCode, t8, t9, node, t10, m, t11, t12, node0, _this = this,
        t1 = _this.___HuffmanTree_dynamicTree_A;
      t1 === $ && A.throwLateFieldNI("dynamicTree");
      t2 = _this.___HuffmanTree_staticDesc_A;
      t2 === $ && A.throwLateFieldNI("staticDesc");
      stree = t2.staticTree;
      elems = t2.numElements;
      s.__Deflate__heapLen_A = 0;
      s.__Deflate__heapMax_A = 573;
      for (t2 = t1.length, t3 = s._heap, t4 = t3.$flags | 0, t5 = s._depth, t6 = t5.$flags | 0, t7 = t1.$flags | 0, n = 0, maxCode = -1; n < elems; ++n) {
        t8 = n * 2;
        if (!(t8 < t2))
          return A.ioore(t1, t8);
        if (t1[t8] !== 0) {
          t8 = ++s.__Deflate__heapLen_A;
          t4 & 2 && A.throwUnsupportedOperation(t3);
          if (!(t8 >= 0 && t8 < 573))
            return A.ioore(t3, t8);
          t3[t8] = n;
          t6 & 2 && A.throwUnsupportedOperation(t5);
          if (!(n < 573))
            return A.ioore(t5, n);
          t5[n] = 0;
          maxCode = n;
        } else {
          ++t8;
          t7 & 2 && A.throwUnsupportedOperation(t1);
          if (!(t8 < t2))
            return A.ioore(t1, t8);
          t1[t8] = 0;
        }
      }
      for (t8 = stree != null; t9 = s.__Deflate__heapLen_A, t9 < 2;) {
        ++t9;
        s.__Deflate__heapLen_A = t9;
        if (maxCode < 2) {
          ++maxCode;
          node = maxCode;
        } else
          node = 0;
        t4 & 2 && A.throwUnsupportedOperation(t3);
        if (!(t9 >= 0))
          return A.ioore(t3, t9);
        t3[t9] = node;
        t9 = node * 2;
        t7 & 2 && A.throwUnsupportedOperation(t1);
        if (!(t9 >= 0 && t9 < t2))
          return A.ioore(t1, t9);
        t1[t9] = 1;
        t6 & 2 && A.throwUnsupportedOperation(t5);
        if (!(node >= 0))
          return A.ioore(t5, node);
        t5[node] = 0;
        t10 = s.__Deflate__optimalLen_A;
        t10 === $ && A.throwLateFieldNI("_optimalLen");
        s.__Deflate__optimalLen_A = t10 - 1;
        if (t8) {
          t10 = s.__Deflate__staticLen_A;
          t10 === $ && A.throwLateFieldNI("_staticLen");
          ++t9;
          if (!(t9 < stree.length))
            return A.ioore(stree, t9);
          s.__Deflate__staticLen_A = t10 - stree[t9];
        }
      }
      _this.___HuffmanTree_maxCode_A = maxCode;
      for (n = B.JSInt_methods._tdivFast$1(t9, 2); n >= 1; --n)
        s._pqdownheap$2(t1, n);
      node = elems;
      do {
        n = t3[1];
        t8 = s.__Deflate__heapLen_A--;
        if (!(t8 >= 0 && t8 < 573))
          return A.ioore(t3, t8);
        t8 = t3[t8];
        t4 & 2 && A.throwUnsupportedOperation(t3);
        t3[1] = t8;
        s._pqdownheap$2(t1, 1);
        m = t3[1];
        t8 = --s.__Deflate__heapMax_A;
        if (!(t8 >= 0 && t8 < 573))
          return A.ioore(t3, t8);
        t3[t8] = n;
        --t8;
        s.__Deflate__heapMax_A = t8;
        if (!(t8 >= 0))
          return A.ioore(t3, t8);
        t3[t8] = m;
        t8 = node * 2;
        t9 = n * 2;
        if (!(t9 >= 0 && t9 < t2))
          return A.ioore(t1, t9);
        t10 = t1[t9];
        t11 = m * 2;
        if (!(t11 >= 0 && t11 < t2))
          return A.ioore(t1, t11);
        t12 = t1[t11];
        t7 & 2 && A.throwUnsupportedOperation(t1);
        if (!(t8 < t2))
          return A.ioore(t1, t8);
        t1[t8] = t10 + t12;
        if (!(n >= 0 && n < 573))
          return A.ioore(t5, n);
        t12 = t5[n];
        if (!(m >= 0 && m < 573))
          return A.ioore(t5, m);
        t10 = t5[m];
        t8 = t12 > t10 ? t12 : t10;
        t6 & 2 && A.throwUnsupportedOperation(t5);
        if (!(node < 573))
          return A.ioore(t5, node);
        t5[node] = t8 + 1;
        ++t9;
        ++t11;
        if (!(t11 < t2))
          return A.ioore(t1, t11);
        t1[t11] = node;
        if (!(t9 < t2))
          return A.ioore(t1, t9);
        t1[t9] = node;
        node0 = node + 1;
        t3[1] = node;
        s._pqdownheap$2(t1, 1);
        if (s.__Deflate__heapLen_A >= 2) {
          node = node0;
          continue;
        } else
          break;
      } while (true);
      t2 = --s.__Deflate__heapMax_A;
      t4 = t3[1];
      if (!(t2 >= 0 && t2 < 573))
        return A.ioore(t3, t2);
      t3[t2] = t4;
      _this._genBitlen$1(s);
      A._HuffmanTree__genCodes(t1, maxCode, s._bitLengthCount);
    }
  };
  A._StaticTree.prototype = {};
  A.ByteOrder.prototype = {
    _enumToString$0() {
      return "ByteOrder." + this._name;
    }
  };
  A.InputMemoryStream.prototype = {
    get$length(_) {
      var t1 = this.buffer;
      return t1 == null ? 0 : t1.length - this._position;
    },
    subset$2$length$position($length, position) {
      var t1 = this.buffer;
      if (t1 == null)
        return A.InputMemoryStream$(A._setArrayType([], type$.JSArray_int), B.ByteOrder_0, null, null);
      return A.InputMemoryStream$(t1, this.byteOrder, $length, position);
    },
    toUint8List$0() {
      var len, t2, t3, _this = this,
        t1 = _this.buffer;
      if (t1 == null)
        return new Uint8Array(0);
      len = _this.get$length(0);
      t2 = _this._position;
      t3 = t1.length;
      if (t2 + len > t3)
        len = t3 - t2;
      return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(t1), _this.buffer.byteOffset + _this._position, len);
    }
  };
  A.InputStream.prototype = {};
  A.OutputMemoryStream.prototype = {
    writeByte$1(value) {
      var t1, t2, _this = this;
      if (_this.length === _this._output_memory_stream$_buffer.length)
        _this._output_memory_stream$_expandBuffer$0();
      t1 = _this._output_memory_stream$_buffer;
      t2 = _this.length++;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (!(t2 >= 0 && t2 < t1.length))
        return A.ioore(t1, t2);
      t1[t2] = value;
    },
    writeBytes$2$length(bytes, $length) {
      var t1, t2, t3, t4, _this = this;
      type$.List_int._as(bytes);
      while (t1 = _this.length, t2 = t1 + $length, t3 = _this._output_memory_stream$_buffer, t4 = t3.length, t2 > t4)
        _this._output_memory_stream$_expandBuffer$1(t2 - t4);
      B.NativeUint8List_methods.setRange$3(t3, t1, t2, bytes);
      _this.length += $length;
    },
    _output_memory_stream$_expandBuffer$1(required) {
      var blockSize = required != null ? required > 32768 ? required : 32768 : 32768,
        t1 = this._output_memory_stream$_buffer,
        t2 = t1.length,
        newBuffer = new Uint8Array((t2 + blockSize) * 2);
      B.NativeUint8List_methods.setRange$3(newBuffer, 0, t2, t1);
      this._output_memory_stream$_buffer = newBuffer;
    },
    _output_memory_stream$_expandBuffer$0() {
      return this._output_memory_stream$_expandBuffer$1(null);
    },
    get$length(receiver) {
      return this.length;
    }
  };
  A.OutputStream.prototype = {};
  A.ChannelIterator.prototype = {
    moveNext$0() {
      var t1 = this.color;
      return ++this.index < t1.get$length(t1);
    },
    get$current() {
      return this.color.$index(0, this.index);
    },
    $isIterator: 1
  };
  A.ChannelOrder.prototype = {
    _enumToString$0() {
      return "ChannelOrder." + this._name;
    }
  };
  A.Color.prototype = {};
  A.ColorFloat16.prototype = {
    clone$0() {
      return new A.ColorFloat16(new Uint16Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_9;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
        t2 = $.Float16__toFloatFloat32Data;
        t2 = t2 != null ? t2 : A.Float16__initialize();
        if (!(t1 < t2.length))
          return A.ioore(t2, t1);
        t1 = t2[t1];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = A.Float16_doubleToFloat16(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      return this.get$r();
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
        t2 = $.Float16__toFloatFloat32Data;
        t2 = t2 != null ? t2 : A.Float16__initialize();
        if (!(t1 < t2.length))
          return A.ioore(t2, t1);
        t1 = t2[t1];
      } else
        t1 = 0;
      return t1;
    },
    set$r(v) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t3 = A.Float16_doubleToFloat16(v);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = t3;
      }
    },
    get$g() {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t1 = t1[1];
        t2 = $.Float16__toFloatFloat32Data;
        t2 = t2 != null ? t2 : A.Float16__initialize();
        if (!(t1 < t2.length))
          return A.ioore(t2, t1);
        t1 = t2[t1];
      } else
        t1 = 0;
      return t1;
    },
    set$g(v) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = A.Float16_doubleToFloat16(v);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t1 = t1[2];
        t2 = $.Float16__toFloatFloat32Data;
        t2 = t2 != null ? t2 : A.Float16__initialize();
        if (!(t1 < t2.length))
          return A.ioore(t2, t1);
        t1 = t2[t1];
      } else
        t1 = 0;
      return t1;
    },
    set$b(v) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = A.Float16_doubleToFloat16(v);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t2,
        t1 = this.data;
      if (t1.length > 3) {
        t1 = t1[3];
        t2 = $.Float16__toFloatFloat32Data;
        t2 = t2 != null ? t2 : A.Float16__initialize();
        if (!(t1 < t2.length))
          return A.ioore(t2, t1);
        t1 = t2[t1];
      } else
        t1 = 0;
      return t1;
    },
    get$aNormalized() {
      return this.get$a() / 1;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = A.Float16_doubleToFloat16(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorFloat32.prototype = {
    clone$0() {
      return new A.ColorFloat32(new Float32Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_10;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = value;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = r;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t1 = this.data;
      if (t1.length > 1) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = g;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t1 = this.data;
      if (t1.length > 2) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = b;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 1;
    },
    get$aNormalized() {
      return this.get$a() / 1;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorFloat64.prototype = {
    clone$0() {
      return new A.ColorFloat64(new Float64Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_11;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = value;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = r;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t1 = this.data;
      if (t1.length > 1) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = g;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t1 = this.data;
      if (t1.length > 2) {
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = b;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 1;
    },
    get$aNormalized() {
      return this.get$a() / 1;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorInt16.prototype = {
    clone$0() {
      return new A.ColorInt16(new Int16Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_7;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = B.JSNumber_methods.toInt$0(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t3 = B.JSNumber_methods.toInt$0(r);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = t3;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = B.JSNumber_methods.toInt$0(g);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = B.JSNumber_methods.toInt$0(b);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 0;
    },
    get$aNormalized() {
      return this.get$a() / 32767;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = B.JSNumber_methods.toInt$0(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorInt32.prototype = {
    clone$0() {
      return new A.ColorInt32(new Int32Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_8;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = B.JSNumber_methods.toInt$0(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        A._asInt(r);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = r;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = B.JSNumber_methods.toInt$0(g);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = B.JSNumber_methods.toInt$0(b);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 0;
    },
    get$aNormalized() {
      return this.get$a() / 2147483647;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = B.JSNumber_methods.toInt$0(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorInt8.prototype = {
    clone$0() {
      return new A.ColorInt8(new Int8Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_6;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = B.JSNumber_methods.toInt$0(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t3 = B.JSNumber_methods.toInt$0(r);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = t3;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = B.JSNumber_methods.toInt$0(g);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = B.JSNumber_methods.toInt$0(b);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 0;
    },
    get$aNormalized() {
      return this.get$a() / 127;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = B.JSNumber_methods.toInt$0(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorUint1.prototype = {
    clone$0() {
      var t1 = this.__ColorUint1_data_A;
      t1 === $ && A.throwLateFieldNI("data");
      return new A.ColorUint1(this.length, t1);
    },
    get$format() {
      return B.Format_0;
    },
    get$palette() {
      return null;
    },
    _color_uint1$_getChannel$1(ci) {
      var t1;
      if (ci < this.length) {
        t1 = this.__ColorUint1_data_A;
        t1 === $ && A.throwLateFieldNI("data");
        t1 = B.JSInt_methods._shrReceiverPositive$1(t1, 7 - ci) & 1;
      } else
        t1 = 0;
      return t1;
    },
    _color_uint1$_setChannel$2(ci, value) {
      var t1;
      if (ci >= this.length)
        return;
      ci = 7 - ci;
      t1 = this.__ColorUint1_data_A;
      t1 === $ && A.throwLateFieldNI("data");
      this.__ColorUint1_data_A = value !== 0 ? (t1 | B.JSInt_methods.$shl(1, ci)) >>> 0 : (t1 & ~(B.JSInt_methods.$shl(1, ci) & 255)) >>> 0;
    },
    $index(_, index) {
      return this._color_uint1$_getChannel$1(index);
    },
    $indexSet(_, index, value) {
      return this._color_uint1$_setChannel$2(index, value);
    },
    get$index() {
      return this._color_uint1$_getChannel$1(0);
    },
    get$r() {
      return this._color_uint1$_getChannel$1(0);
    },
    set$r(v) {
      this._color_uint1$_setChannel$2(0, v);
    },
    get$g() {
      return this._color_uint1$_getChannel$1(1);
    },
    set$g(v) {
      this._color_uint1$_setChannel$2(1, v);
    },
    get$b() {
      return this._color_uint1$_getChannel$1(2);
    },
    set$b(v) {
      this._color_uint1$_setChannel$2(2, v);
    },
    get$a() {
      return this._color_uint1$_getChannel$1(3);
    },
    get$aNormalized() {
      return this._color_uint1$_getChannel$1(3) / 1;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var _this = this,
        t1 = c.get$r(),
        t2 = c.get$g(),
        t3 = c.get$b(),
        t4 = c.get$a();
      _this._color_uint1$_setChannel$2(0, t1);
      _this._color_uint1$_setChannel$2(1, t2);
      _this._color_uint1$_setChannel$2(2, t3);
      _this._color_uint1$_setChannel$2(3, t4);
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    },
    get$length(receiver) {
      return this.length;
    }
  };
  A.ColorUint16.prototype = {
    clone$0() {
      return new A.ColorUint16(new Uint16Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_4;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = B.JSNumber_methods.toInt$0(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t3 = B.JSNumber_methods.toInt$0(r);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = t3;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = B.JSNumber_methods.toInt$0(g);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = B.JSNumber_methods.toInt$0(b);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 0;
    },
    get$aNormalized() {
      return this.get$a() / 65535;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = B.JSNumber_methods.toInt$0(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorUint2.prototype = {
    clone$0() {
      var t1 = this.__ColorUint2_data_A;
      t1 === $ && A.throwLateFieldNI("data");
      return new A.ColorUint2(this.length, t1);
    },
    get$format() {
      return B.Format_1;
    },
    get$palette() {
      return null;
    },
    _color_uint2$_getChannel$1(ci) {
      var t1;
      if (ci < this.length) {
        t1 = this.__ColorUint2_data_A;
        t1 === $ && A.throwLateFieldNI("data");
        t1 = B.JSInt_methods._shrReceiverPositive$1(t1, 6 - (ci << 1 >>> 0)) & 3;
      } else
        t1 = 0;
      return t1;
    },
    _color_uint2$_setChannel$2(ci, value) {
      var mask, t1, t2;
      if (ci >= this.length)
        return;
      if (!(ci >= 0 && ci < 4))
        return A.ioore(B.List_63_207_243_252, ci);
      mask = B.List_63_207_243_252[ci];
      t1 = B.JSNumber_methods.toInt$0(value);
      t2 = this.__ColorUint2_data_A;
      t2 === $ && A.throwLateFieldNI("data");
      this.__ColorUint2_data_A = (t2 & mask | B.JSInt_methods.$shl(t1 & 3, 6 - (ci << 1 >>> 0))) >>> 0;
    },
    $index(_, index) {
      return this._color_uint2$_getChannel$1(index);
    },
    $indexSet(_, index, value) {
      return this._color_uint2$_setChannel$2(index, value);
    },
    get$index() {
      return this._color_uint2$_getChannel$1(0);
    },
    get$r() {
      return this._color_uint2$_getChannel$1(0);
    },
    set$r(v) {
      this._color_uint2$_setChannel$2(0, v);
    },
    get$g() {
      return this._color_uint2$_getChannel$1(1);
    },
    set$g(v) {
      this._color_uint2$_setChannel$2(1, v);
    },
    get$b() {
      return this._color_uint2$_getChannel$1(2);
    },
    set$b(v) {
      this._color_uint2$_setChannel$2(2, v);
    },
    get$a() {
      return this._color_uint2$_getChannel$1(3);
    },
    get$aNormalized() {
      return this._color_uint2$_getChannel$1(3) / 3;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var _this = this,
        t1 = c.get$r(),
        t2 = c.get$g(),
        t3 = c.get$b(),
        t4 = c.get$a();
      _this._color_uint2$_setChannel$2(0, t1);
      _this._color_uint2$_setChannel$2(1, t2);
      _this._color_uint2$_setChannel$2(2, t3);
      _this._color_uint2$_setChannel$2(3, t4);
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    },
    get$length(receiver) {
      return this.length;
    }
  };
  A.ColorUint32.prototype = {
    clone$0() {
      return new A.ColorUint32(new Uint32Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_5;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = B.JSNumber_methods.toInt$0(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t3 = B.JSNumber_methods.toInt$0(r);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = t3;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = B.JSNumber_methods.toInt$0(g);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = B.JSNumber_methods.toInt$0(b);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 0;
    },
    get$aNormalized() {
      return this.get$a() / 4294967295;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = B.JSNumber_methods.toInt$0(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.ColorUint4.prototype = {
    clone$0() {
      return new A.ColorUint4(this.length, new Uint8Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_2;
    },
    get$palette() {
      return null;
    },
    _getChannel$1(ci) {
      var t1, t2;
      if (ci < 0 || ci >= this.length)
        t1 = 0;
      else {
        t1 = this.data;
        t2 = t1.length;
        if (ci < 2) {
          if (0 >= t2)
            return A.ioore(t1, 0);
          t1 = B.JSInt_methods._shrReceiverPositive$1(t1[0], 4 - (ci << 2 >>> 0)) & 15;
        } else {
          if (1 >= t2)
            return A.ioore(t1, 1);
          t1 = B.JSInt_methods._shrReceiverPositive$1(t1[1], 4 - ((ci & 1) << 2)) & 15;
        }
      }
      return t1;
    },
    _setChannel$2(ci, value) {
      var vi, i, t1, t2;
      if (ci >= this.length)
        return;
      vi = B.JSInt_methods.clamp$2(B.JSNumber_methods.toInt$0(value), 0, 15);
      if (ci > 1) {
        ci &= 1;
        i = 1;
      } else
        i = 0;
      if (ci === 0) {
        t1 = this.data;
        if (!(i < t1.length))
          return A.ioore(t1, i);
        t2 = t1[i];
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[i] = (t2 & 15 | vi << 4) >>> 0;
      } else if (ci === 1) {
        t1 = this.data;
        if (!(i < t1.length))
          return A.ioore(t1, i);
        t2 = t1[i];
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[i] = (t2 & 240 | vi) >>> 0;
      }
    },
    $index(_, index) {
      return this._getChannel$1(index);
    },
    $indexSet(_, index, value) {
      return this._setChannel$2(index, value);
    },
    get$index() {
      return this._getChannel$1(0);
    },
    get$r() {
      return this._getChannel$1(0);
    },
    set$r(v) {
      this._setChannel$2(0, v);
    },
    get$g() {
      return this._getChannel$1(1);
    },
    set$g(v) {
      this._setChannel$2(1, v);
    },
    get$b() {
      return this._getChannel$1(2);
    },
    set$b(v) {
      this._setChannel$2(2, v);
    },
    get$a() {
      return this._getChannel$1(3);
    },
    get$aNormalized() {
      return this._getChannel$1(3) / 15;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var _this = this,
        t1 = c.get$r(),
        t2 = c.get$g(),
        t3 = c.get$b(),
        t4 = c.get$a();
      _this._setChannel$2(0, t1);
      _this._setChannel$2(1, t2);
      _this._setChannel$2(2, t3);
      _this._setChannel$2(3, t4);
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    },
    get$length(receiver) {
      return this.length;
    }
  };
  A.ColorUint8.prototype = {
    clone$0() {
      return new A.ColorUint8(new Uint8Array(A._ensureNativeList(this.data)));
    },
    get$format() {
      return B.Format_3;
    },
    get$length(_) {
      return this.data.length;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      var t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1 = t1[index];
      } else
        t1 = 0;
      return t1;
    },
    $indexSet(_, index, value) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (index < t2) {
        t3 = B.JSNumber_methods.toInt$0(value);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(index >= 0))
          return A.ioore(t1, index);
        t1[index] = t3;
      }
    },
    get$index() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    get$r() {
      var t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0];
      } else
        t1 = 0;
      return t1;
    },
    set$r(r) {
      var t3,
        t1 = this.data,
        t2 = t1.length;
      if (t2 !== 0) {
        t3 = B.JSNumber_methods.toInt$0(r);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1[0] = t3;
      }
    },
    get$g() {
      var t1 = this.data;
      return t1.length > 1 ? t1[1] : 0;
    },
    set$g(g) {
      var t2,
        t1 = this.data;
      if (t1.length > 1) {
        t2 = B.JSNumber_methods.toInt$0(g);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[1] = t2;
      }
    },
    get$b() {
      var t1 = this.data;
      return t1.length > 2 ? t1[2] : 0;
    },
    set$b(b) {
      var t2,
        t1 = this.data;
      if (t1.length > 2) {
        t2 = B.JSNumber_methods.toInt$0(b);
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        t1[2] = t2;
      }
    },
    get$a() {
      var t1 = this.data;
      return t1.length > 3 ? t1[3] : 255;
    },
    get$aNormalized() {
      return this.get$a() / 255;
    },
    get$luminance() {
      return A.getLuminance(this);
    },
    $set$1(c) {
      var t1, t2, _this = this;
      _this.set$r(c.get$r());
      _this.set$g(c.get$g());
      _this.set$b(c.get$b());
      t1 = c.get$a();
      t2 = _this.data;
      if (t2.length > 3) {
        t1 = B.JSNumber_methods.toInt$0(t1);
        t2.$flags & 2 && A.throwUnsupportedOperation(t2);
        t2[3] = t1;
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      t1 = false;
      if (other instanceof A.Color)
        if (other.get$length(other) === this.data.length) {
          t1 = other.get$hashCode(other);
          t2 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
          t1 = t1 === A.Object_hashAll(t2);
        }
      return t1;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    }
  };
  A.Format.prototype = {
    _enumToString$0() {
      return "Format." + this._name;
    }
  };
  A.FormatType.prototype = {
    _enumToString$0() {
      return "FormatType." + this._name;
    }
  };
  A.ExifData.prototype = {
    getTagName$1(tag) {
      var t1 = $.$get$exifImageTags();
      if (!t1.containsKey$1(tag))
        return "<unknown>";
      return t1.$index(0, tag).name;
    },
    toString$0(_) {
      var t1, t2, t3, t4, t5, t6, t7, t8, directory, t9, value, t10, subDirectory, t11, _this = this;
      for (t1 = _this.directories, t2 = new A.LinkedHashMapKeyIterator(t1, t1._modifications, t1._first, A._instanceType(t1)._eval$1("LinkedHashMapKeyIterator<1>")), t3 = type$.int, t4 = type$.IfdValue, t5 = type$.String, t6 = type$.IfdDirectory, t7 = ""; t2.moveNext$0();) {
        t8 = t2.__js_helper$_current;
        t7 += t8 + "\n";
        directory = t1.$index(0, t8);
        for (t8 = directory.data, t8 = new A.LinkedHashMapKeyIterator(t8, t8._modifications, t8._first, A._instanceType(t8)._eval$1("LinkedHashMapKeyIterator<1>")); t8.moveNext$0();) {
          t9 = t8.__js_helper$_current;
          value = directory.$index(0, t9);
          t7 = value == null ? t7 + ("\t" + _this.getTagName$1(t9) + "\n") : t7 + ("\t" + _this.getTagName$1(t9) + ": " + value.toString$0(0) + "\n");
        }
        for (t8 = directory.sub.directories, t9 = new A.LinkedHashMapKeyIterator(t8, t8._modifications, t8._first, A._instanceType(t8)._eval$1("LinkedHashMapKeyIterator<1>")); t9.moveNext$0();) {
          t10 = t9.__js_helper$_current;
          t7 += t10 + "\n";
          if (!t8.containsKey$1(t10))
            t8.$indexSet(0, t10, new A.IfdDirectory(A.LinkedHashMap_LinkedHashMap$_empty(t3, t4), new A.IfdContainer(A.LinkedHashMap_LinkedHashMap$_empty(t5, t6))));
          subDirectory = t8.$index(0, t10);
          for (t10 = subDirectory.data, t10 = new A.LinkedHashMapKeyIterator(t10, t10._modifications, t10._first, A._instanceType(t10)._eval$1("LinkedHashMapKeyIterator<1>")); t10.moveNext$0();) {
            t11 = t10.__js_helper$_current;
            value = subDirectory.$index(0, t11);
            t7 = value == null ? t7 + ("\t" + _this.getTagName$1(t11) + "\n") : t7 + ("\t" + _this.getTagName$1(t11) + ": " + value.toString$0(0) + "\n");
          }
        }
      }
      return t7.charCodeAt(0) == 0 ? t7 : t7;
    },
    write$1(out) {
      var t1, t2, t3, offsets, t4, t5, t6, t7, dataOffset, t8, t9, t10, t11, dataSize, subSize, t12, numIfd, i, $name, ifd, _this = this, _s4_ = "exif",
        _s7_ = "interop",
        saveEndian = out.bigEndian;
      out.bigEndian = true;
      out.writeUint16$1(19789);
      out.writeUint16$1(42);
      out.writeUint32$1(8);
      t1 = _this.directories;
      if (t1.$index(0, "ifd0") == null)
        t1.$indexSet(0, "ifd0", new A.IfdDirectory(A.LinkedHashMap_LinkedHashMap$_empty(type$.int, type$.IfdValue), new A.IfdContainer(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.IfdDirectory))));
      t2 = type$.String;
      t3 = type$.int;
      offsets = A.LinkedHashMap_LinkedHashMap$_empty(t2, t3);
      for (t4 = A._instanceType(t1), t5 = new A.LinkedHashMapKeyIterator(t1, t1._modifications, t1._first, t4._eval$1("LinkedHashMapKeyIterator<1>")), t6 = type$.IfdValue, t7 = type$.IfdDirectory, dataOffset = 8; t5.moveNext$0();) {
        t8 = t5.__js_helper$_current;
        t9 = t1.$index(0, t8);
        t9.toString;
        offsets.$indexSet(0, t8, dataOffset);
        t8 = t9.sub.directories;
        if (t8.containsKey$1(_s4_)) {
          t10 = new Uint32Array(1);
          t10[0] = 0;
          t9.$indexSet(0, 34665, new A.IfdValueLong(t10));
        } else
          t9.data.remove$1(0, 34665);
        if (t8.containsKey$1(_s7_)) {
          t10 = new Uint32Array(1);
          t10[0] = 0;
          t9.$indexSet(0, 40965, new A.IfdValueLong(t10));
        } else
          t9.data.remove$1(0, 40965);
        if (t8.containsKey$1("gps")) {
          t10 = new Uint32Array(1);
          t10[0] = 0;
          t9.$indexSet(0, 34853, new A.IfdValueLong(t10));
        } else
          t9.data.remove$1(0, 34853);
        t9 = t9.data;
        dataOffset += 2 + 12 * t9.__js_helper$_length + 4;
        for (t9 = new A.LinkedHashMapValueIterator(t9, t9._modifications, t9._first, A._instanceType(t9)._eval$1("LinkedHashMapValueIterator<2>")); t9.moveNext$0();) {
          t10 = t9.__js_helper$_current;
          t11 = t10.get$type().index;
          if (!(t11 < 13))
            return A.ioore(B.List_w4E, t11);
          dataSize = B.List_w4E[t11] * t10.get$length(t10);
          if (dataSize > 4)
            dataOffset += dataSize;
        }
        for (t9 = new A.LinkedHashMapKeyIterator(t8, t8._modifications, t8._first, A._instanceType(t8)._eval$1("LinkedHashMapKeyIterator<1>")); t9.moveNext$0();) {
          t10 = t9.__js_helper$_current;
          if (!t8.containsKey$1(t10))
            t8.$indexSet(0, t10, new A.IfdDirectory(A.LinkedHashMap_LinkedHashMap$_empty(t3, t6), new A.IfdContainer(A.LinkedHashMap_LinkedHashMap$_empty(t2, t7))));
          t11 = t8.$index(0, t10);
          t11.toString;
          offsets.$indexSet(0, t10, dataOffset);
          t11 = t11.data;
          subSize = 2 + 12 * t11.__js_helper$_length;
          for (t10 = new A.LinkedHashMapValueIterator(t11, t11._modifications, t11._first, A._instanceType(t11)._eval$1("LinkedHashMapValueIterator<2>")); t10.moveNext$0();) {
            t11 = t10.__js_helper$_current;
            t12 = t11.get$type().index;
            if (!(t12 < 13))
              return A.ioore(B.List_w4E, t12);
            dataSize = B.List_w4E[t12] * t11.get$length(t11);
            if (dataSize > 4)
              subSize += dataSize;
          }
          dataOffset += subSize;
        }
      }
      numIfd = t1.__js_helper$_length;
      for (t5 = t4._eval$1("LinkedHashMapKeysIterable<1>"), t8 = numIfd - 1, t4 = t4._eval$1("LinkedHashMapValuesIterable<2>"), i = 0; i < numIfd; ++i) {
        $name = new A.LinkedHashMapKeysIterable(t1, t5).elementAt$1(0, i);
        ifd = new A.LinkedHashMapValuesIterable(t1, t4).elementAt$1(0, i);
        t9 = ifd.sub.directories;
        if (t9.containsKey$1(_s4_)) {
          t10 = ifd.$index(0, 34665);
          t10.toString;
          t11 = offsets.$index(0, _s4_);
          t11.toString;
          t10.setInt$1(t11);
        }
        if (t9.containsKey$1(_s7_)) {
          t10 = ifd.$index(0, 40965);
          t10.toString;
          t11 = offsets.$index(0, _s7_);
          t11.toString;
          t10.setInt$1(t11);
        }
        if (t9.containsKey$1("gps")) {
          t10 = ifd.$index(0, 34853);
          t10.toString;
          t11 = offsets.$index(0, "gps");
          t11.toString;
          t10.setInt$1(t11);
        }
        t10 = offsets.$index(0, $name);
        t10.toString;
        _this._writeDirectory$3(out, ifd, t10 + 2 + 12 * ifd.data.__js_helper$_length + 4);
        if (i === t8)
          out.writeUint32$1(0);
        else {
          t10 = offsets.$index(0, new A.LinkedHashMapKeysIterable(t1, t5).elementAt$1(0, i + 1));
          t10.toString;
          out.writeUint32$1(t10);
        }
        _this._writeDirectoryLargeValues$2(out, ifd);
        for (t10 = new A.LinkedHashMapKeyIterator(t9, t9._modifications, t9._first, A._instanceType(t9)._eval$1("LinkedHashMapKeyIterator<1>")); t10.moveNext$0();) {
          t11 = t10.__js_helper$_current;
          if (!t9.containsKey$1(t11))
            t9.$indexSet(0, t11, new A.IfdDirectory(A.LinkedHashMap_LinkedHashMap$_empty(t3, t6), new A.IfdContainer(A.LinkedHashMap_LinkedHashMap$_empty(t2, t7))));
          t12 = t9.$index(0, t11);
          t12.toString;
          t11 = offsets.$index(0, t11);
          t11.toString;
          _this._writeDirectory$3(out, t12, t11 + 2 + 12 * t12.data.__js_helper$_length);
          _this._writeDirectoryLargeValues$2(out, t12);
        }
      }
      out.bigEndian = saveEndian;
    },
    _writeDirectory$3(out, ifd, dataOffset) {
      var t2, t3, t4, tagType, tagLength, size,
        t1 = ifd.data;
      out.writeUint16$1(t1.__js_helper$_length);
      for (t1 = new A.LinkedHashMapKeyIterator(t1, t1._modifications, t1._first, A._instanceType(t1)._eval$1("LinkedHashMapKeyIterator<1>")); t1.moveNext$0();) {
        t2 = t1.__js_helper$_current;
        t3 = ifd.$index(0, t2);
        t3.toString;
        t4 = t2 === 273;
        tagType = t4 && t3.get$type() === B.IfdValueType_7 ? B.IfdValueType_4 : t3.get$type();
        tagLength = t4 && t3.get$type() === B.IfdValueType_7 ? 1 : t3.get$length(t3);
        out.writeUint16$1(t2);
        out.writeUint16$1(tagType.index);
        out.writeUint32$1(tagLength);
        t2 = t3.get$type().index;
        if (!(t2 < 13))
          return A.ioore(B.List_w4E, t2);
        size = B.List_w4E[t2] * t3.get$length(t3);
        if (size <= 4) {
          t3.write$1(out);
          while (size < 4) {
            out.writeByte$1(0);
            ++size;
          }
        } else {
          out.writeUint32$1(dataOffset);
          dataOffset += size;
        }
      }
      return dataOffset;
    },
    _writeDirectoryLargeValues$2(out, ifd) {
      var t1, t2, t3;
      for (t1 = ifd.data, t1 = new A.LinkedHashMapValueIterator(t1, t1._modifications, t1._first, A._instanceType(t1)._eval$1("LinkedHashMapValueIterator<2>")); t1.moveNext$0();) {
        t2 = t1.__js_helper$_current;
        t3 = t2.get$type().index;
        if (!(t3 < 13))
          return A.ioore(B.List_w4E, t3);
        if (B.List_w4E[t3] * t2.get$length(t2) > 4)
          t2.write$1(out);
      }
    }
  };
  A.ExifTag.prototype = {};
  A.IfdContainer.prototype = {
    IfdContainer$from$1(other) {
      other.directories.forEach$1(0, new A.IfdContainer$from_closure(this));
    },
    get$isEmpty(_) {
      var t2,
        t1 = this.directories;
      if (t1.__js_helper$_length === 0)
        return true;
      for (t1 = new A.LinkedHashMapValueIterator(t1, t1._modifications, t1._first, A._instanceType(t1)._eval$1("LinkedHashMapValueIterator<2>")); t1.moveNext$0();) {
        t2 = t1.__js_helper$_current;
        if (!(t2.data.__js_helper$_length === 0 && t2.sub.get$isEmpty(0)))
          return false;
      }
      return true;
    },
    $index(_, ifdName) {
      var t1 = this.directories;
      if (!t1.containsKey$1(ifdName))
        t1.$indexSet(0, ifdName, new A.IfdDirectory(A.LinkedHashMap_LinkedHashMap$_empty(type$.int, type$.IfdValue), new A.IfdContainer(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.IfdDirectory))));
      t1 = t1.$index(0, ifdName);
      t1.toString;
      return t1;
    }
  };
  A.IfdContainer$from_closure.prototype = {
    call$2(key, value) {
      var t1;
      A._asString(key);
      t1 = A.IfdDirectory$from(type$.IfdDirectory._as(value));
      this.$this.directories.$indexSet(0, key, t1);
      return t1;
    },
    $signature: 6
  };
  A.IfdDirectory.prototype = {
    copy$1(other) {
      other.data.forEach$1(0, new A.IfdDirectory_copy_closure(this));
      other.sub.directories.forEach$1(0, new A.IfdDirectory_copy_closure0(this));
    },
    $index(_, tag) {
      var t1 = this.data.$index(0, tag);
      return t1;
    },
    $indexSet(_, tag, value) {
      var tagInfo, t1, t2, _length, _list, index, t3, t4, _this = this;
      if (typeof tag == "string")
        tag = B.Map_1DOpr.$index(0, tag);
      if (!A._isInt(tag))
        return;
      if (value instanceof A.IfdValue)
        _this.data.$indexSet(0, tag, value);
      else {
        tagInfo = $.$get$exifImageTags().$index(0, tag);
        if (tagInfo != null)
          switch (tagInfo.type.index) {
            case 1:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdByteValue(new Uint8Array(A._ensureNativeList(new Uint8Array(A._ensureNativeList(value))))));
              else if (A._isInt(value)) {
                t1 = new Uint8Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdByteValue(t1));
              }
              break;
            case 2:
              break;
            case 3:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueShort(new Uint16Array(A._ensureNativeList(new Uint16Array(A._ensureNativeList(value))))));
              else if (A._isInt(value)) {
                t1 = new Uint16Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdValueShort(t1));
              }
              break;
            case 4:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueLong(new Uint32Array(A._ensureNativeList(new Uint32Array(A._ensureNativeList(value))))));
              else if (A._isInt(value))
                _this.data.$indexSet(0, tag, A.IfdValueLong$(value));
              break;
            case 5:
              if (type$.List_Rational._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueRational(A.List_List$from(value, type$.Rational)));
              else if (type$.List_int._is(value) && value.length === 2) {
                t1 = value.length;
                if (0 >= t1)
                  return A.ioore(value, 0);
                t2 = value[0];
                if (1 >= t1)
                  return A.ioore(value, 1);
                _this.data.$indexSet(0, tag, new A.IfdValueRational(A._setArrayType([new A.Rational(t2, value[1])], type$.JSArray_Rational)));
              } else if (type$.List_List_int._is(value)) {
                _length = value.length;
                t1 = type$.Rational;
                _list = J.JSArray_JSArray$allocateGrowable(_length, t1);
                for (index = 0; index < _length; ++index) {
                  t2 = value[index];
                  t3 = t2.length;
                  if (0 >= t3)
                    return A.ioore(t2, 0);
                  t4 = t2[0];
                  if (1 >= t3)
                    return A.ioore(t2, 1);
                  _list[index] = new A.Rational(t4, t2[1]);
                }
                _this.data.$indexSet(0, tag, new A.IfdValueRational(A.List_List$from(_list, t1)));
              }
              break;
            case 6:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueSByte(new Int8Array(A._ensureNativeList(new Int8Array(A._ensureNativeList(value))))));
              else if (A._isInt(value)) {
                t1 = new Int8Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdValueSByte(t1));
              }
              break;
            case 7:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueUndefined(new Uint8Array(A._ensureNativeList(new Uint8Array(A._ensureNativeList(value))))));
              break;
            case 8:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueSShort(new Int16Array(A._ensureNativeList(new Int16Array(A._ensureNativeList(value))))));
              else if (A._isInt(value)) {
                t1 = new Int16Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdValueSShort(t1));
              }
              break;
            case 9:
              if (type$.List_int._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueSLong(new Int32Array(A._ensureNativeList(new Int32Array(A._ensureNativeList(value))))));
              else if (A._isInt(value)) {
                t1 = new Int32Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdValueSLong(t1));
              }
              break;
            case 10:
              if (type$.List_Rational._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueSRational(A.List_List$from(value, type$.Rational)));
              else if (type$.List_int._is(value) && value.length === 2) {
                t1 = value.length;
                if (0 >= t1)
                  return A.ioore(value, 0);
                t2 = value[0];
                if (1 >= t1)
                  return A.ioore(value, 1);
                _this.data.$indexSet(0, tag, new A.IfdValueSRational(A._setArrayType([new A.Rational(t2, value[1])], type$.JSArray_Rational)));
              } else if (type$.List_List_int._is(value)) {
                _length = value.length;
                t1 = type$.Rational;
                _list = J.JSArray_JSArray$allocateGrowable(_length, t1);
                for (index = 0; index < _length; ++index) {
                  t2 = value[index];
                  t3 = t2.length;
                  if (0 >= t3)
                    return A.ioore(t2, 0);
                  t4 = t2[0];
                  if (1 >= t3)
                    return A.ioore(t2, 1);
                  _list[index] = new A.Rational(t4, t2[1]);
                }
                _this.data.$indexSet(0, tag, new A.IfdValueSRational(A.List_List$from(_list, t1)));
              }
              break;
            case 11:
              if (type$.List_double._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueSingle(new Float32Array(A._ensureNativeList(new Float32Array(A._ensureNativeList(value))))));
              else if (typeof value == "number") {
                t1 = new Float32Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdValueSingle(t1));
              }
              break;
            case 12:
              if (type$.List_double._is(value))
                _this.data.$indexSet(0, tag, new A.IfdValueDouble(new Float64Array(A._ensureNativeList(new Float64Array(A._ensureNativeList(value))))));
              else if (typeof value == "number") {
                t1 = new Float64Array(1);
                t1[0] = value;
                _this.data.$indexSet(0, tag, new A.IfdValueDouble(t1));
              }
              break;
            case 0:
              break;
          }
      }
    }
  };
  A.IfdDirectory_copy_closure.prototype = {
    call$2(tag, value) {
      var t1;
      A._asInt(tag);
      t1 = type$.IfdValue._as(value).clone$0();
      this.$this.data.$indexSet(0, tag, t1);
      return t1;
    },
    $signature: 29
  };
  A.IfdDirectory_copy_closure0.prototype = {
    call$2(tag, value) {
      var t1;
      A._asString(tag);
      t1 = A.IfdDirectory$from(type$.IfdDirectory._as(value));
      this.$this.sub.directories.$indexSet(0, tag, t1);
      return t1;
    },
    $signature: 6
  };
  A.IfdValueType.prototype = {
    _enumToString$0() {
      return "IfdValueType." + this._name;
    }
  };
  A.IfdValue.prototype = {
    toString$0(_) {
      return "";
    },
    $eq(_, other) {
      var _this = this;
      if (other == null)
        return false;
      return other instanceof A.IfdValue && _this.get$type() === other.get$type() && _this.get$length(_this) === other.get$length(other) && _this.get$hashCode(_this) === other.get$hashCode(other);
    },
    get$hashCode(_) {
      return 0;
    },
    setInt$1(v) {
    }
  };
  A.IfdByteValue.prototype = {
    clone$0() {
      return new A.IfdByteValue(new Uint8Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_1;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdByteValue) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    setInt$1(v) {
      var t1 = this.value;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      t1[0] = v;
    },
    write$1(out) {
      out.writeBytes$1(this.value);
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = "" + t1[0];
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueShort.prototype = {
    clone$0() {
      return new A.IfdValueShort(new Uint16Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_3;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueShort) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    setInt$1(v) {
      var t1 = this.value;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      t1[0] = v;
    },
    write$1(out) {
      var i,
        t1 = this.value,
        l = t1.length;
      for (i = 0; i < l; ++i)
        out.writeUint16$1(t1[i]);
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = "" + t1[0];
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueLong.prototype = {
    clone$0() {
      return new A.IfdValueLong(new Uint32Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_4;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueLong) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    setInt$1(v) {
      var t1 = this.value;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      t1[0] = v;
    },
    write$1(out) {
      var i,
        t1 = this.value,
        l = t1.length;
      for (i = 0; i < l; ++i)
        out.writeUint32$1(t1[i]);
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = "" + t1[0];
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueRational.prototype = {
    clone$0() {
      return new A.IfdValueRational(A.List_List$from(this.value, type$.Rational));
    },
    get$type() {
      return B.IfdValueType_5;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2, t3;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueRational) {
        t1 = this.value;
        t2 = t1.length;
        t3 = other.value;
        t1 = t2 === t3.length && A.Object_hashAll(t1) === A.Object_hashAll(t3);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    write$1(out) {
      var t1, t2, _i, v;
      for (t1 = this.value, t2 = t1.length, _i = 0; _i < t1.length; t1.length === t2 || (0, A.throwConcurrentModificationError)(t1), ++_i) {
        v = t1[_i];
        out.writeUint32$1(v.numerator);
        out.writeUint32$1(v.denominator);
      }
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0].toString$0(0);
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueSByte.prototype = {
    clone$0() {
      return new A.IfdValueSByte(new Int8Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_6;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueSByte) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    setInt$1(v) {
      var t1 = this.value;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      t1[0] = v;
    },
    write$1(out) {
      out.writeBytes$1(J.asUint8List$2$x(B.NativeInt8List_methods.get$buffer(this.value), 0, null));
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = "" + t1[0];
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueSShort.prototype = {
    clone$0() {
      return new A.IfdValueSShort(new Int16Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_8;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueSShort) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    setInt$1(v) {
      var t1 = this.value;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      t1[0] = v;
    },
    write$1(out) {
      var t2, i, t3,
        v = new Int16Array(1),
        vb = J.asUint16List$2$x(B.NativeInt16List_methods.get$buffer(v), 0, null),
        t1 = this.value,
        l = t1.length;
      for (t2 = vb.length, i = 0; i < l; ++i) {
        t3 = t1[i];
        if (0 >= 1)
          return A.ioore(v, 0);
        v[0] = t3;
        if (0 >= t2)
          return A.ioore(vb, 0);
        out.writeUint16$1(vb[0]);
      }
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = "" + t1[0];
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueSLong.prototype = {
    clone$0() {
      return new A.IfdValueSLong(new Int32Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_9;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueSLong) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    setInt$1(v) {
      var t1 = this.value;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (0 >= t1.length)
        return A.ioore(t1, 0);
      t1[0] = v;
    },
    write$1(out) {
      var i, t2, t3,
        t1 = this.value,
        l = t1.length;
      for (i = 0; i < l; ++i) {
        t2 = t1[i];
        t3 = $.$get$__int32();
        t3.$flags & 2 && A.throwUnsupportedOperation(t3);
        t3[0] = t2;
        t2 = $.$get$__int32ToUint32();
        if (0 >= t2.length)
          return A.ioore(t2, 0);
        out.writeUint32$1(t2[0]);
      }
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = "" + t1[0];
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueSRational.prototype = {
    clone$0() {
      return new A.IfdValueSRational(A.List_List$from(this.value, type$.Rational));
    },
    get$type() {
      return B.IfdValueType_10;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2, t3;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueSRational) {
        t1 = this.value;
        t2 = t1.length;
        t3 = other.value;
        t1 = t2 === t3.length && A.Object_hashAll(t1) === A.Object_hashAll(t3);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    write$1(out) {
      var t1, t2, _i, v, t3, t4;
      for (t1 = this.value, t2 = t1.length, _i = 0; _i < t1.length; t1.length === t2 || (0, A.throwConcurrentModificationError)(t1), ++_i) {
        v = t1[_i];
        t3 = $.$get$__int32();
        t3.$flags & 2 && A.throwUnsupportedOperation(t3);
        t3[0] = v.numerator;
        t4 = $.$get$__int32ToUint32();
        if (0 >= t4.length)
          return A.ioore(t4, 0);
        out.writeUint32$1(t4[0]);
        t3[0] = v.denominator;
        out.writeUint32$1(t4[0]);
      }
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = t1[0].toString$0(0);
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueSingle.prototype = {
    clone$0() {
      return new A.IfdValueSingle(new Float32Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_11;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueSingle) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    write$1(out) {
      var i,
        t1 = this.value,
        l = t1.length;
      for (i = 0; i < l; ++i)
        out.writeFloat32$1(t1[i]);
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = A.S(t1[0]);
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueDouble.prototype = {
    clone$0() {
      return new A.IfdValueDouble(new Float64Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_12;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueDouble) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    write$1(out) {
      var i,
        t1 = this.value,
        l = t1.length;
      for (i = 0; i < l; ++i)
        out.writeFloat64$1(t1[i]);
    },
    toString$0(_) {
      var t1 = this.value,
        t2 = t1.length;
      if (t2 === 1) {
        if (0 >= t2)
          return A.ioore(t1, 0);
        t1 = A.S(t1[0]);
      } else
        t1 = A.S(t1);
      return t1;
    }
  };
  A.IfdValueUndefined.prototype = {
    clone$0() {
      return new A.IfdValueUndefined(new Uint8Array(A._ensureNativeList(this.value)));
    },
    get$type() {
      return B.IfdValueType_7;
    },
    get$length(_) {
      return this.value.length;
    },
    $eq(_, other) {
      var t1, t2;
      if (other == null)
        return false;
      if (other instanceof A.IfdValueUndefined) {
        t1 = this.value;
        t2 = other.value;
        t1 = t1.length === t2.length && A.Object_hashAll(t1) === A.Object_hashAll(t2);
      } else
        t1 = false;
      return t1;
    },
    get$hashCode(_) {
      return A.Object_hashAll(this.value);
    },
    write$1(out) {
      out.writeBytes$1(this.value);
    },
    toString$0(_) {
      return "<data>";
    }
  };
  A.BmpCompression.prototype = {
    _enumToString$0() {
      return "BmpCompression." + this._name;
    }
  };
  A.BmpEncoder.prototype = {
    encode$1(image) {
      var t2, t3, bpp, compression, imageStride, fileStride, rowPaddingSize, rowPadding, implicitPaletteSize, imageFileSize, headerInfoSize, headerSize, paletteSize, origImageOffset, gapSize, blueMask, greenMask, redMask, alphaMask, l, pi, v, gap1, gap10, offset, h, t4, y, t5, bytes, xi, b, hasAlpha, w, p, pixel, x, _null = null,
        out = A.OutputBuffer$(false, 8192),
        nc = image.get$numChannels(),
        t1 = image.data,
        palette = t1 == null ? _null : t1.palette,
        format = image.get$format();
      t1 = format === B.Format_0;
      if (t1 && nc === 1 && palette == null) {
        palette = new A.PaletteUint8(new Uint8Array(6), 2, 3);
        palette.setRgb$4(0, 0, 0, 0);
        palette.setRgb$4(1, 255, 255, 255);
      } else if (t1 && nc === 4)
        image = image.convert$1$numChannels(4);
      else {
        t1 = format === B.Format_1;
        if (t1 && nc === 2) {
          image = image.convert$1$withPalette(true);
          t1 = image.data;
          palette = t1 == null ? _null : t1.palette;
        } else if (t1 && nc === 3 && palette == null) {
          image = image.convert$1$withPalette(true);
          t1 = image.data;
          palette = t1 == null ? _null : t1.palette;
        } else if (t1 && nc === 4) {
          image = image.convert$1$withPalette(true);
          t1 = image.data;
          palette = t1 == null ? _null : t1.palette;
        } else {
          t1 = format === B.Format_2;
          if (t1 && nc === 1 && palette == null) {
            image = image.convert$1$withPalette(true);
            t1 = image.data;
            palette = t1 == null ? _null : t1.palette;
          } else if (t1 && nc === 2)
            image = image.convert$1$numChannels(3);
          else if (t1 && nc === 3 && palette == null)
            image = image.convert$1$numChannels(3);
          else if (t1 && nc === 4)
            image = image.convert$1$numChannels(4);
          else {
            t1 = format === B.Format_3;
            if (t1 && nc === 1 && palette == null)
              image = image.convert$1$withPalette(true);
            else if (t1 && nc === 2)
              image.convert$1$numChannels(3);
            else {
              image.get$isHdrFormat();
              if (image.get$hasPalette() && image.get$numChannels() === 4)
                image = image.convert$1$numChannels(4);
            }
          }
        }
      }
      t1 = image.get$bitsPerChannel();
      t2 = image.data;
      t3 = t2.numChannels;
      bpp = t1 * t3;
      if (bpp === 12)
        bpp = 16;
      t1 = bpp > 8;
      compression = t1 ? B.BmpCompression_3 : B.BmpCompression_0;
      imageStride = t2.width * t3;
      if (imageStride === null)
        imageStride = 0;
      fileStride = B.JSInt_methods._tdivFast$1(image.get$width() * bpp + 31, 32) * 4;
      rowPaddingSize = fileStride - imageStride;
      rowPadding = rowPaddingSize > 0 ? A.List_List$filled(rowPaddingSize, 255, false, type$.int) : _null;
      implicitPaletteSize = bpp >= 1 && bpp <= 8 ? B.JSInt_methods.$shl(1, bpp) : 0;
      imageFileSize = fileStride * image.get$height();
      headerInfoSize = t1 ? 124 : 40;
      headerSize = headerInfoSize + 14;
      paletteSize = implicitPaletteSize * 4;
      origImageOffset = headerSize + paletteSize;
      gapSize = origImageOffset - origImageOffset;
      out.writeUint16$1(19778);
      out.writeUint32$1(imageFileSize + headerSize + paletteSize + gapSize);
      out.writeUint32$1(0);
      out.writeUint32$1(origImageOffset);
      out.writeUint32$1(headerInfoSize);
      out.writeUint32$1(image.get$width());
      out.writeUint32$1(image.get$height());
      out.writeUint16$1(1);
      out.writeUint16$1(bpp);
      out.writeUint32$1(compression.index);
      out.writeUint32$1(imageFileSize);
      out.writeUint32$1(11811);
      out.writeUint32$1(11811);
      t2 = bpp === 8;
      out.writeUint32$1(t2 ? 255 : 0);
      out.writeUint32$1(t2 ? 255 : 0);
      if (t1) {
        t1 = bpp === 16;
        blueMask = t1 ? 15 : 255;
        greenMask = t1 ? 240 : 65280;
        redMask = t1 ? 3840 : 16711680;
        alphaMask = t1 ? 61440 : 4278190080;
        out.writeUint32$1(redMask);
        out.writeUint32$1(greenMask);
        out.writeUint32$1(blueMask);
        out.writeUint32$1(alphaMask);
        out.writeUint32$1(1934772034);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(2);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
        out.writeUint32$1(0);
      }
      t1 = bpp === 1;
      t3 = !t1;
      if (!t3 || bpp === 2 || bpp === 4 || t2)
        if (palette != null) {
          l = palette.numColors;
          if (l > implicitPaletteSize)
            l = implicitPaletteSize;
          for (pi = 0; pi < l; ++pi) {
            out.writeByte$1(B.JSInt_methods.toInt$0(palette.getBlue$1(pi)));
            out.writeByte$1(B.JSInt_methods.toInt$0(palette.getGreen$1(pi)));
            out.writeByte$1(B.JSInt_methods.toInt$0(palette.getRed$1(pi)));
            out.writeByte$1(0);
          }
          for (; pi < implicitPaletteSize; ++pi) {
            out.writeByte$1(0);
            out.writeByte$1(0);
            out.writeByte$1(0);
            out.writeByte$1(0);
          }
        } else if (t1) {
          out.writeByte$1(0);
          out.writeByte$1(0);
          out.writeByte$1(0);
          out.writeByte$1(0);
          out.writeByte$1(255);
          out.writeByte$1(255);
          out.writeByte$1(255);
          out.writeByte$1(0);
        } else if (bpp === 2)
          for (pi = 0; pi < 4; ++pi) {
            v = pi * 85;
            out.writeByte$1(v);
            out.writeByte$1(v);
            out.writeByte$1(v);
            out.writeByte$1(0);
          }
        else if (bpp === 4)
          for (pi = 0; pi < 16; ++pi) {
            v = pi * 17;
            out.writeByte$1(v);
            out.writeByte$1(v);
            out.writeByte$1(v);
            out.writeByte$1(0);
          }
        else if (t2)
          for (pi = 0; pi < 256; ++pi) {
            out.writeByte$1(pi);
            out.writeByte$1(pi);
            out.writeByte$1(pi);
            out.writeByte$1(0);
          }
      for (gap1 = gapSize; gap10 = gap1 - 1, gap1 > 0; gap1 = gap10)
        out.writeByte$1(0);
      if (!t3 || bpp === 2 || bpp === 4 || t2) {
        offset = image.get$lengthInBytes(0) - imageStride;
        h = image.get$height();
        for (t2 = rowPadding != null, t3 = bpp === 4, t4 = bpp === 2, y = 0; y < h; ++y) {
          t5 = image.data;
          t5 = t5 == null ? _null : B.NativeUint8List_methods.get$buffer(t5.data);
          if (t5 == null)
            t5 = B.NativeUint8List_methods.get$buffer(new Uint8Array(0));
          bytes = J.asUint8List$2$x(t5, offset, imageStride);
          if (t1)
            out.writeBytes$1(bytes);
          else if (t4) {
            l = bytes.length;
            for (xi = 0; xi < l; ++xi) {
              b = bytes[xi];
              out.writeByte$1((b & 15) << 4 | b >>> 4);
            }
          } else if (t3) {
            l = bytes.length;
            for (xi = 0; xi < l; ++xi) {
              b = bytes[xi];
              out.writeByte$1(b >>> 4 << 4 | b & 15);
            }
          } else
            out.writeBytes$1(bytes);
          if (t2)
            out.writeBytes$1(rowPadding);
          offset -= imageStride;
        }
        return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(out._buffer), 0, out.length);
      }
      hasAlpha = image.get$numChannels() === 4;
      h = image.get$height();
      w = image.get$width();
      if (bpp === 16)
        for (y = h - 1, t1 = rowPadding != null, p = _null; y >= 0; --y) {
          t2 = image.data;
          if (t2 == null)
            p = _null;
          else {
            pixel = p == null || !(p instanceof A.PixelUint8) || p.image !== t2 ? new A.PixelUint8(-1, 0, -t2.numChannels, t2) : p;
            pixel.setPosition$2(0, y);
            p = pixel;
          }
          if (p == null)
            p = new A.PixelUndefined();
          for (x = 0; x < w; ++x) {
            out.writeByte$1((B.JSInt_methods.toInt$0(p.get$g()) << 4 | B.JSInt_methods.toInt$0(p.get$b())) >>> 0);
            out.writeByte$1((B.JSInt_methods.toInt$0(p.get$a()) << 4 | B.JSInt_methods.toInt$0(p.get$r())) >>> 0);
            p.moveNext$0();
          }
          if (t1)
            out.writeBytes$1(rowPadding);
        }
      else
        for (y = h - 1, t1 = rowPadding != null, p = _null; y >= 0; --y) {
          t2 = image.data;
          if (t2 == null)
            p = _null;
          else {
            pixel = p == null || !(p instanceof A.PixelUint8) || p.image !== t2 ? new A.PixelUint8(-1, 0, -t2.numChannels, t2) : p;
            pixel.setPosition$2(0, y);
            p = pixel;
          }
          if (p == null)
            p = new A.PixelUndefined();
          for (x = 0; x < w; ++x) {
            out.writeByte$1(p.get$b());
            out.writeByte$1(p.get$g());
            out.writeByte$1(p.get$r());
            if (hasAlpha)
              out.writeByte$1(p.get$a());
            p.moveNext$0();
          }
          if (t1)
            out.writeBytes$1(rowPadding);
        }
      return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(out._buffer), 0, out.length);
    }
  };
  A.CurEncoder.prototype = {
    colorPlanesOrXHotSpot$1(index) {
      return 0;
    },
    bitsPerPixelOrYHotSpot$1(index) {
      return 0;
    },
    get$type() {
      return 2;
    }
  };
  A.Encoder.prototype = {};
  A.WinEncoder.prototype = {
    encode$2$singleFrame(image, singleFrame) {
      if (image.get$frames().length > 1 && !singleFrame)
        return this.encodeImages$1(image.get$frames());
      else
        return this.encodeImages$1(A._setArrayType([image], type$.JSArray_Image));
    },
    encodeImages$1(images) {
      var count, out, offset, imageDataList, t1, i, _i, img, t2, t3, t4, data, _null = null;
      type$.List_Image._as(images);
      count = images.length;
      out = A.OutputBuffer$(false, 8192);
      out.writeUint16$1(0);
      out.writeUint16$1(this.get$type());
      out.writeUint16$1(count);
      offset = 6 + count * 16;
      imageDataList = A._setArrayType([A._setArrayType([], type$.JSArray_int)], type$.JSArray_List_int);
      for (t1 = images.length, i = 0, _i = 0; _i < images.length; images.length === t1 || (0, A.throwConcurrentModificationError)(images), ++_i) {
        img = images[_i];
        t2 = img.data;
        t3 = t2 == null;
        t4 = t3 ? _null : t2.width;
        if ((t4 == null ? 0 : t4) <= 256) {
          t4 = t3 ? _null : t2.height;
          t4 = (t4 == null ? 0 : t4) > 256;
        } else
          t4 = true;
        if (t4)
          throw A.wrapException(A.Exception_Exception("ICO and CUR support only sizes until 256"));
        t2 = t3 ? _null : t2.width;
        out.writeByte$1(t2 == null ? 0 : t2);
        t2 = img.data;
        t2 = t2 == null ? _null : t2.height;
        out.writeByte$1(t2 == null ? 0 : t2);
        out.writeByte$1(0);
        out.writeByte$1(0);
        out.writeUint16$1(this.colorPlanesOrXHotSpot$1(i));
        out.writeUint16$1(this.bitsPerPixelOrYHotSpot$1(i));
        data = new A.PngEncoder(B.PngFilter_4, _null).encode$1(img);
        t2 = data.length;
        out.writeUint32$1(t2);
        out.writeUint32$1(offset);
        offset += t2;
        ++i;
        B.JSArray_methods.add$1(imageDataList, data);
      }
      for (t1 = imageDataList.length, _i = 0; _i < imageDataList.length; imageDataList.length === t1 || (0, A.throwConcurrentModificationError)(imageDataList), ++_i)
        out.writeBytes$1(imageDataList[_i]);
      return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(out._buffer), 0, out.length);
    }
  };
  A.IcoEncoder.prototype = {
    colorPlanesOrXHotSpot$1(index) {
      return 0;
    },
    bitsPerPixelOrYHotSpot$1(index) {
      return 32;
    },
    get$type() {
      return 1;
    }
  };
  A.JpegChroma.prototype = {
    _enumToString$0() {
      return "JpegChroma." + this._name;
    }
  };
  A.JpegHealthyEncoder.prototype = {
    setQuality$1(quality) {
      quality = B.JSInt_methods.toInt$0(B.JSInt_methods.clamp$2(quality, 1, 100));
      if (this._currentQuality === quality)
        return;
      this._initQuantTables$1(quality < 50 ? B.JSNumber_methods.floor$0(5000 / quality) : B.JSInt_methods.floor$0(200 - quality * 2));
      this._currentQuality = quality;
    },
    encode$4$backgroundColor$chroma$destroy$(image, backgroundColor, chroma, destroy$) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.Uint8List),
        $async$returnValue, $async$self = this, healthCheck, width, height, ydu, udu, vdu, dcy, dcu, dcv, y, x, t4, i, sudu, svdu, t5, t6, t7, t8, t9, t10, t11, t12, t13, t14, t15, t16, fp, t1, t2, t3, fallback;
      var $async$encode$4$backgroundColor$chroma$destroy$ = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              fp = A.OutputBuffer$(true, 8192);
              t1 = B.JSInt_methods._shrOtherPositive$1(backgroundColor, 16);
              t2 = B.JSInt_methods._shrOtherPositive$1(backgroundColor, 8);
              t3 = new Int32Array(3);
              fallback = new A.ColorInt32(t3);
              t3[0] = t1 & 255;
              t3[1] = t2 & 255;
              t3[2] = backgroundColor & 255;
              healthCheck = new A.JpegHealthyEncoder_encode_healthCheck(destroy$);
              $async$self._writeMarker$2(fp, 216);
              $async$self._writeMarker$2(fp, 224);
              fp.writeUint16$1(16);
              fp.writeByte$1(74);
              fp.writeByte$1(70);
              fp.writeByte$1(73);
              fp.writeByte$1(70);
              fp.writeByte$1(0);
              fp.writeByte$1(1);
              fp.writeByte$1(1);
              fp.writeByte$1(0);
              fp.writeUint16$1(1);
              fp.writeUint16$1(1);
              fp.writeByte$1(0);
              fp.writeByte$1(0);
              $async$self._writeAPP1$2(fp, image.get$exif());
              $async$self._writeDQT$1(fp);
              t1 = image.get$width();
              t2 = image.get$height();
              $async$self._writeMarker$2(fp, 192);
              fp.writeUint16$1(17);
              fp.writeByte$1(8);
              fp.writeUint16$1(t2);
              fp.writeUint16$1(t1);
              fp.writeByte$1(3);
              fp.writeByte$1(1);
              t1 = chroma === B.JpegChroma_0;
              fp.writeByte$1(t1 ? 17 : 34);
              fp.writeByte$1(0);
              fp.writeByte$1(2);
              fp.writeByte$1(17);
              fp.writeByte$1(1);
              fp.writeByte$1(3);
              fp.writeByte$1(17);
              fp.writeByte$1(1);
              $async$self._writeDHT$1(fp);
              $async$self._writeMarker$2(fp, 218);
              fp.writeUint16$1(12);
              fp.writeByte$1(3);
              fp.writeByte$1(1);
              fp.writeByte$1(0);
              fp.writeByte$1(2);
              fp.writeByte$1(17);
              fp.writeByte$1(3);
              fp.writeByte$1(17);
              fp.writeByte$1(0);
              fp.writeByte$1(63);
              fp.writeByte$1(0);
              $async$self._byteNew = 0;
              $async$self._bytePos = 7;
              width = image.get$width();
              height = image.get$height();
              $async$goto = t1 ? 3 : 5;
              break;
            case 3:
              // then
              ydu = new Float32Array(64);
              udu = new Float32Array(64);
              vdu = new Float32Array(64);
              t1 = $async$self._fdtblY, t2 = $async$self._fdtblUv, dcy = 0, dcu = 0, dcv = 0, y = 0;
            case 6:
              // for condition
              if (!(y < height)) {
                // goto after for
                $async$goto = 8;
                break;
              }
              for (x = 0; x < width; x += 8) {
                $async$self._calculateYUV$9$imageBackground(image, x, y, width, height, ydu, udu, vdu, fallback);
                t3 = $async$self._ydcHuffman;
                t4 = $async$self.__JpegHealthyEncoder__yacHuffman_A;
                t4 === $ && A.throwLateFieldNI("_yacHuffman");
                dcy = $async$self._processDU$6(fp, ydu, t1, dcy, t3, t4);
                t4 = $async$self._uvdcHuffman;
                t3 = $async$self.__JpegHealthyEncoder__uvacHuffman_A;
                t3 === $ && A.throwLateFieldNI("_uvacHuffman");
                dcu = $async$self._processDU$6(fp, udu, t2, dcu, t4, t3);
                dcv = $async$self._processDU$6(fp, vdu, t2, dcv, $async$self._uvdcHuffman, $async$self.__JpegHealthyEncoder__uvacHuffman_A);
              }
              $async$goto = B.JSInt_methods.$mod(y, 24) === 0 ? 9 : 10;
              break;
            case 9:
              // then
              $async$goto = 11;
              return A._asyncAwait(healthCheck.call$0(), $async$encode$4$backgroundColor$chroma$destroy$);
            case 11:
              // returning from await.
            case 10:
              // join
            case 7:
              // for update
              y += 8;
              // goto for condition
              $async$goto = 6;
              break;
            case 8:
              // after for
              // goto join
              $async$goto = 4;
              break;
            case 5:
              // else
              t1 = type$.Float32List;
              ydu = J.JSArray_JSArray$allocateGrowable(4, t1);
              for (i = 0; i < 4; ++i)
                ydu[i] = new Float32Array(64);
              udu = J.JSArray_JSArray$allocateGrowable(4, t1);
              for (i = 0; i < 4; ++i)
                udu[i] = new Float32Array(64);
              vdu = J.JSArray_JSArray$allocateGrowable(4, t1);
              for (i = 0; i < 4; ++i)
                vdu[i] = new Float32Array(64);
              sudu = new Float32Array(64);
              svdu = new Float32Array(64);
              for (t1 = $async$self._fdtblY, t2 = $async$self._fdtblUv, dcy = 0, dcu = 0, dcv = 0, y = 0; y < height; y += 16)
                for (t3 = y + 8, x = 0; x < width; x += 16) {
                  t4 = ydu[0];
                  t5 = udu[0];
                  t6 = vdu[0];
                  $async$self._calculateYUV$9$imageBackground(image, x, y, width, height, t4, t5, t6, fallback);
                  t7 = x + 8;
                  t8 = ydu[1];
                  t9 = udu[1];
                  t10 = vdu[1];
                  $async$self._calculateYUV$9$imageBackground(image, t7, y, width, height, t8, t9, t10, fallback);
                  t11 = ydu[2];
                  t12 = udu[2];
                  t13 = vdu[2];
                  $async$self._calculateYUV$9$imageBackground(image, x, t3, width, height, t11, t12, t13, fallback);
                  t14 = ydu[3];
                  t15 = udu[3];
                  t16 = vdu[3];
                  $async$self._calculateYUV$9$imageBackground(image, t7, t3, width, height, t14, t15, t16, fallback);
                  $async$self._downsampleDU$5(sudu, t5, t9, t12, t15);
                  $async$self._downsampleDU$5(svdu, t6, t10, t13, t16);
                  t16 = $async$self._ydcHuffman;
                  t13 = $async$self.__JpegHealthyEncoder__yacHuffman_A;
                  t13 === $ && A.throwLateFieldNI("_yacHuffman");
                  dcy = $async$self._processDU$6(fp, t14, t1, $async$self._processDU$6(fp, t11, t1, $async$self._processDU$6(fp, t8, t1, $async$self._processDU$6(fp, t4, t1, dcy, t16, t13), $async$self._ydcHuffman, $async$self.__JpegHealthyEncoder__yacHuffman_A), $async$self._ydcHuffman, $async$self.__JpegHealthyEncoder__yacHuffman_A), $async$self._ydcHuffman, $async$self.__JpegHealthyEncoder__yacHuffman_A);
                  t13 = $async$self._uvdcHuffman;
                  t16 = $async$self.__JpegHealthyEncoder__uvacHuffman_A;
                  t16 === $ && A.throwLateFieldNI("_uvacHuffman");
                  dcu = $async$self._processDU$6(fp, sudu, t2, dcu, t13, t16);
                  dcv = $async$self._processDU$6(fp, svdu, t2, dcv, $async$self._uvdcHuffman, $async$self.__JpegHealthyEncoder__uvacHuffman_A);
                }
            case 4:
              // join
              t1 = $async$self._bytePos;
              if (t1 >= 0) {
                ++t1;
                $async$self._writeBits$2(fp, A._setArrayType([B.JSInt_methods.$shl(1, t1) - 1, t1], type$.JSArray_int));
              }
              $async$self._writeMarker$2(fp, 217);
              $async$returnValue = J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(fp._buffer), 0, fp.length);
              // goto return
              $async$goto = 1;
              break;
            case 1:
              // return
              return A._asyncReturn($async$returnValue, $async$completer);
          }
      });
      return A._asyncStartSync($async$encode$4$backgroundColor$chroma$destroy$, $async$completer);
    },
    _calculateYUV$9$imageBackground(image, x, y, width, height, ydu, udu, vdu, imageBackground) {
      var t1, t2, t3, t4, t5, t6, t7, t8, t9, t10, pos, row, yy, xx, t11, p, pixel, a, invA, t12, r, g, b, t13;
      for (t1 = this._rgbYuvTable, t2 = y + 1, t3 = imageBackground.data, t4 = t3.length, t5 = t4 > 2, t6 = t4 > 1, t7 = t4 !== 0, t8 = ydu.$flags | 0, t9 = udu.$flags | 0, t10 = vdu.$flags | 0, pos = 0; pos < 64; ++pos) {
        row = pos >>> 3;
        yy = y + row;
        xx = x + (pos & 7);
        if (yy >= height)
          yy -= t2 + row - height;
        if (xx >= width)
          xx -= xx - width + 1;
        t11 = image.data;
        if (t11 == null)
          p = null;
        else {
          pixel = new A.PixelUint8(-1, 0, -t11.numChannels, t11);
          pixel.setPosition$2(xx, yy);
          p = pixel;
        }
        if (p == null)
          p = new A.PixelUndefined();
        if (p.get$format() !== B.Format_3)
          p = p.convert$1$format(B.Format_3);
        if (p.get$length(p) > 3) {
          a = p.get$aNormalized();
          invA = 1 - a;
          t11 = p.get$r();
          if (t7) {
            if (0 >= t4)
              return A.ioore(t3, 0);
            t12 = t3[0];
          } else
            t12 = 0;
          p.set$r(B.JSNumber_methods.round$0(t11 * a + t12 * invA));
          t12 = p.get$g();
          t11 = t6 ? t3[1] : 0;
          p.set$g(B.JSNumber_methods.round$0(t12 * a + t11 * invA));
          t11 = p.get$b();
          t12 = t5 ? t3[2] : 0;
          p.set$b(B.JSNumber_methods.round$0(t11 * a + t12 * invA));
        }
        r = B.JSNumber_methods.toInt$0(p.get$r());
        g = B.JSNumber_methods.toInt$0(p.get$g());
        b = B.JSNumber_methods.toInt$0(p.get$b());
        if (!(r >= 0 && r < 2048))
          return A.ioore(t1, r);
        t11 = t1[r];
        t12 = g + 256;
        if (!(t12 >= 0 && t12 < 2048))
          return A.ioore(t1, t12);
        t12 = t1[t12];
        t13 = b + 512;
        if (!(t13 >= 0 && t13 < 2048))
          return A.ioore(t1, t13);
        t13 = B.JSInt_methods._shrOtherPositive$1(t11 + t12 + t1[t13], 16);
        t8 & 2 && A.throwUnsupportedOperation(ydu);
        ydu[pos] = t13 - 128;
        t13 = r + 768;
        if (!(t13 < 2048))
          return A.ioore(t1, t13);
        t13 = t1[t13];
        t12 = g + 1024;
        if (!(t12 >= 0 && t12 < 2048))
          return A.ioore(t1, t12);
        t12 = t1[t12];
        t11 = b + 1280;
        if (!(t11 >= 0 && t11 < 2048))
          return A.ioore(t1, t11);
        t11 = B.JSInt_methods._shrOtherPositive$1(t13 + t12 + t1[t11], 16);
        t9 & 2 && A.throwUnsupportedOperation(udu);
        udu[pos] = t11 - 128;
        t11 = r + 1280;
        if (!(t11 < 2048))
          return A.ioore(t1, t11);
        t11 = t1[t11];
        t12 = g + 1536;
        if (!(t12 >= 0 && t12 < 2048))
          return A.ioore(t1, t12);
        t12 = t1[t12];
        t13 = b + 1792;
        if (!(t13 >= 0 && t13 < 2048))
          return A.ioore(t1, t13);
        t13 = B.JSInt_methods._shrOtherPositive$1(t11 + t12 + t1[t13], 16);
        t10 & 2 && A.throwUnsupportedOperation(vdu);
        vdu[pos] = t13 - 128;
      }
    },
    _downsampleDU$5(duOut, duIn1, duIn2, duIn3, duIn4) {
      var t1, posOut, du, pos, t2, t3, t4, t5;
      for (t1 = duOut.$flags | 0, posOut = 0; posOut < 64; ++posOut) {
        if (posOut < 32)
          du = B.JSInt_methods.$mod(posOut, 8) < 4 ? duIn1 : duIn2;
        else
          du = B.JSInt_methods.$mod(posOut, 8) < 4 ? duIn3 : duIn4;
        pos = (B.JSInt_methods._tdivFast$1(B.JSInt_methods.$mod(posOut, 32), 8) << 4 >>> 0) + (B.JSInt_methods.$mod(posOut, 4) << 1 >>> 0);
        if (!(pos < 64))
          return A.ioore(du, pos);
        t2 = du[pos];
        t3 = pos + 1;
        if (!(t3 < 64))
          return A.ioore(du, t3);
        t3 = du[t3];
        t4 = pos + 8;
        if (!(t4 < 64))
          return A.ioore(du, t4);
        t4 = du[t4];
        t5 = pos + 9;
        if (!(t5 < 64))
          return A.ioore(du, t5);
        t5 = du[t5];
        t1 & 2 && A.throwUnsupportedOperation(duOut);
        if (!(posOut < 64))
          return A.ioore(duOut, posOut);
        duOut[posOut] = (t2 + t3 + t4 + t5) / 4;
      }
    },
    _writeMarker$2(fp, marker) {
      fp.writeByte$1(255);
      fp.writeByte$1(marker & 255);
    },
    _initQuantTables$1(sf) {
      var t1, t2, i, t, t3, j, u, t4, t5, t6, k, row, col, t7, t8, t9, t10, _this = this;
      for (t1 = _this._yTable, t2 = t1.$flags | 0, i = 0; i < 64; ++i) {
        t = B.JSNumber_methods.floor$0((B.List_aYr[i] * sf + 50) / 100);
        if (t < 1)
          t = 1;
        else if (t > 255)
          t = 255;
        t3 = B.List_EVh[i];
        t2 & 2 && A.throwUnsupportedOperation(t1);
        if (!(t3 < 64))
          return A.ioore(t1, t3);
        t1[t3] = t;
      }
      for (t2 = _this._uvTable, t3 = t2.$flags | 0, j = 0; j < 64; ++j) {
        u = B.JSNumber_methods.floor$0((B.List_6sz[j] * sf + 50) / 100);
        if (u < 1)
          u = 1;
        else if (u > 255)
          u = 255;
        t4 = B.List_EVh[j];
        t3 & 2 && A.throwUnsupportedOperation(t2);
        if (!(t4 < 64))
          return A.ioore(t2, t4);
        t2[t4] = u;
      }
      for (t3 = _this._fdtblY, t4 = t3.$flags | 0, t5 = _this._fdtblUv, t6 = t5.$flags | 0, k = 0, row = 0; row < 8; ++row)
        for (col = 0; col < 8; ++col) {
          if (!(k >= 0 && k < 64))
            return A.ioore(B.List_EVh, k);
          t7 = B.List_EVh[k];
          if (!(t7 < 64))
            return A.ioore(t1, t7);
          t8 = t1[t7];
          t9 = B.List_A98[row];
          t10 = B.List_A98[col];
          t4 & 2 && A.throwUnsupportedOperation(t3);
          t3[k] = 1 / (t8 * t9 * t10 * 8);
          t7 = t2[t7];
          t6 & 2 && A.throwUnsupportedOperation(t5);
          t5[k] = 1 / (t7 * t9 * t10 * 8);
          ++k;
        }
    },
    _computeHuffmanTable$2(nrCodes, stdTable) {
      var ht, t2, codeValue, posInTable, k, j, index,
        t1 = type$.List_int;
      t1._as(nrCodes);
      t1._as(stdTable);
      t1 = type$.JSArray_int;
      ht = A._setArrayType([A._setArrayType([], t1)], type$.JSArray_nullable_List_int);
      for (t2 = stdTable.length, codeValue = 0, posInTable = 0, k = 1; k <= 16; ++k) {
        for (j = 1; j <= nrCodes[k]; ++j) {
          if (!(posInTable >= 0 && posInTable < t2))
            return A.ioore(stdTable, posInTable);
          index = stdTable[posInTable];
          if (ht.length <= index)
            B.JSArray_methods.set$length(ht, index + 1);
          B.JSArray_methods.$indexSet(ht, index, A._setArrayType([codeValue, k], t1));
          ++posInTable;
          ++codeValue;
        }
        codeValue *= 2;
      }
      return ht;
    },
    _initCategoryNumber$0() {
      var t1, t2, t3, nrLower, nrUpper, cat, nr, t4, nrNeg, t5, t6;
      for (t1 = this._category, t2 = this._bitCode, t3 = type$.JSArray_int, nrLower = 1, nrUpper = 2, cat = 1; cat <= 15; ++cat) {
        for (nr = nrLower; nr < nrUpper; ++nr) {
          t4 = 32767 + nr;
          B.JSArray_methods.$indexSet(t1, t4, cat);
          B.JSArray_methods.$indexSet(t2, t4, A._setArrayType([nr, cat], t3));
        }
        for (t4 = nrUpper - 1, nrNeg = -t4, t5 = -nrLower; nrNeg <= t5; ++nrNeg) {
          t6 = 32767 + nrNeg;
          B.JSArray_methods.$indexSet(t1, t6, cat);
          B.JSArray_methods.$indexSet(t2, t6, A._setArrayType([t4 + nrNeg, cat], t3));
        }
        nrLower = nrLower << 1 >>> 0;
        nrUpper = nrUpper << 1 >>> 0;
      }
    },
    _initRgbYuvTable$0() {
      var t1, t2, i;
      for (t1 = this._rgbYuvTable, t2 = t1.$flags | 0, i = 0; i < 256; ++i) {
        t2 & 2 && A.throwUnsupportedOperation(t1);
        t1[i] = 19595 * i;
        t1[i + 256] = 38470 * i;
        t1[i + 512] = 7471 * i + 32768;
        t1[i + 768] = -11059 * i;
        t1[i + 1024] = -21709 * i;
        t1[i + 1280] = 32768 * i + 8421375;
        t1[i + 1536] = -27439 * i;
        t1[i + 1792] = -5329 * i;
      }
    },
    _fDCTQuant$2(data, fdtbl) {
      var dataOff, i, d0, t2, d1, t3, d2, t4, d3, t5, d4, t6, d5, t7, d6, t8, d7, tmp0, tmp7, tmp1, tmp6, tmp2, tmp5, tmp3, tmp10, tmp13, tmp11, z1, tmp12, z5, z2, z4, z3, z11, z13, tmp0p2, tmp7p2, tmp1p2, tmp6p2, tmp2p2, tmp5p2, tmp3p2, tmp10p2, tmp13p2, tmp11p2, z1p2, tmp12p2, z5p2, z2p2, z4p2, z3p2, z11p2, z13p2, fDCTQuant,
        t1 = type$.List_double;
      t1._as(data);
      t1._as(fdtbl);
      for (t1 = data.$flags | 0, dataOff = 0, i = 0; i < 8; ++i) {
        if (!(dataOff < 64))
          return A.ioore(data, dataOff);
        d0 = data[dataOff];
        t2 = dataOff + 1;
        if (!(t2 < 64))
          return A.ioore(data, t2);
        d1 = data[t2];
        t3 = dataOff + 2;
        if (!(t3 < 64))
          return A.ioore(data, t3);
        d2 = data[t3];
        t4 = dataOff + 3;
        if (!(t4 < 64))
          return A.ioore(data, t4);
        d3 = data[t4];
        t5 = dataOff + 4;
        if (!(t5 < 64))
          return A.ioore(data, t5);
        d4 = data[t5];
        t6 = dataOff + 5;
        if (!(t6 < 64))
          return A.ioore(data, t6);
        d5 = data[t6];
        t7 = dataOff + 6;
        if (!(t7 < 64))
          return A.ioore(data, t7);
        d6 = data[t7];
        t8 = dataOff + 7;
        if (!(t8 < 64))
          return A.ioore(data, t8);
        d7 = data[t8];
        tmp0 = d0 + d7;
        tmp7 = d0 - d7;
        tmp1 = d1 + d6;
        tmp6 = d1 - d6;
        tmp2 = d2 + d5;
        tmp5 = d2 - d5;
        tmp3 = d3 + d4;
        tmp10 = tmp0 + tmp3;
        tmp13 = tmp0 - tmp3;
        tmp11 = tmp1 + tmp2;
        t1 & 2 && A.throwUnsupportedOperation(data);
        if (!(dataOff < 64))
          return A.ioore(data, dataOff);
        data[dataOff] = tmp10 + tmp11;
        if (!(t5 < 64))
          return A.ioore(data, t5);
        data[t5] = tmp10 - tmp11;
        z1 = (tmp1 - tmp2 + tmp13) * 0.707106781;
        if (!(t3 < 64))
          return A.ioore(data, t3);
        data[t3] = tmp13 + z1;
        if (!(t7 < 64))
          return A.ioore(data, t7);
        data[t7] = tmp13 - z1;
        tmp10 = d3 - d4 + tmp5;
        tmp12 = tmp6 + tmp7;
        z5 = (tmp10 - tmp12) * 0.382683433;
        z2 = 0.5411961 * tmp10 + z5;
        z4 = 1.306562965 * tmp12 + z5;
        z3 = (tmp5 + tmp6) * 0.707106781;
        z11 = tmp7 + z3;
        z13 = tmp7 - z3;
        if (!(t6 < 64))
          return A.ioore(data, t6);
        data[t6] = z13 + z2;
        if (!(t4 < 64))
          return A.ioore(data, t4);
        data[t4] = z13 - z2;
        if (!(t2 < 64))
          return A.ioore(data, t2);
        data[t2] = z11 + z4;
        if (!(t8 < 64))
          return A.ioore(data, t8);
        data[t8] = z11 - z4;
        dataOff += 8;
      }
      for (dataOff = 0, i = 0; i < 8; ++i) {
        if (!(dataOff < 64))
          return A.ioore(data, dataOff);
        d0 = data[dataOff];
        t2 = dataOff + 8;
        if (!(t2 < 64))
          return A.ioore(data, t2);
        d1 = data[t2];
        t3 = dataOff + 16;
        if (!(t3 < 64))
          return A.ioore(data, t3);
        d2 = data[t3];
        t4 = dataOff + 24;
        if (!(t4 < 64))
          return A.ioore(data, t4);
        d3 = data[t4];
        t5 = dataOff + 32;
        if (!(t5 < 64))
          return A.ioore(data, t5);
        d4 = data[t5];
        t6 = dataOff + 40;
        if (!(t6 < 64))
          return A.ioore(data, t6);
        d5 = data[t6];
        t7 = dataOff + 48;
        if (!(t7 < 64))
          return A.ioore(data, t7);
        d6 = data[t7];
        t8 = dataOff + 56;
        if (!(t8 < 64))
          return A.ioore(data, t8);
        d7 = data[t8];
        tmp0p2 = d0 + d7;
        tmp7p2 = d0 - d7;
        tmp1p2 = d1 + d6;
        tmp6p2 = d1 - d6;
        tmp2p2 = d2 + d5;
        tmp5p2 = d2 - d5;
        tmp3p2 = d3 + d4;
        tmp10p2 = tmp0p2 + tmp3p2;
        tmp13p2 = tmp0p2 - tmp3p2;
        tmp11p2 = tmp1p2 + tmp2p2;
        t1 & 2 && A.throwUnsupportedOperation(data);
        if (!(dataOff < 64))
          return A.ioore(data, dataOff);
        data[dataOff] = tmp10p2 + tmp11p2;
        if (!(t5 < 64))
          return A.ioore(data, t5);
        data[t5] = tmp10p2 - tmp11p2;
        z1p2 = (tmp1p2 - tmp2p2 + tmp13p2) * 0.707106781;
        if (!(t3 < 64))
          return A.ioore(data, t3);
        data[t3] = tmp13p2 + z1p2;
        if (!(t7 < 64))
          return A.ioore(data, t7);
        data[t7] = tmp13p2 - z1p2;
        tmp10p2 = d3 - d4 + tmp5p2;
        tmp12p2 = tmp6p2 + tmp7p2;
        z5p2 = (tmp10p2 - tmp12p2) * 0.382683433;
        z2p2 = 0.5411961 * tmp10p2 + z5p2;
        z4p2 = 1.306562965 * tmp12p2 + z5p2;
        z3p2 = (tmp5p2 + tmp6p2) * 0.707106781;
        z11p2 = tmp7p2 + z3p2;
        z13p2 = tmp7p2 - z3p2;
        if (!(t6 < 64))
          return A.ioore(data, t6);
        data[t6] = z13p2 + z2p2;
        if (!(t4 < 64))
          return A.ioore(data, t4);
        data[t4] = z13p2 - z2p2;
        if (!(t2 < 64))
          return A.ioore(data, t2);
        data[t2] = z11p2 + z4p2;
        if (!(t8 < 64))
          return A.ioore(data, t8);
        data[t8] = z11p2 - z4p2;
        ++dataOff;
      }
      for (t1 = this._outputfDCTQuant, i = 0; i < 64; ++i) {
        fDCTQuant = data[i] * fdtbl[i];
        B.JSArray_methods.$indexSet(t1, i, fDCTQuant > 0 ? B.JSNumber_methods.toInt$0(fDCTQuant + 0.5) : B.JSNumber_methods.toInt$0(fDCTQuant - 0.5));
      }
      return t1;
    },
    _writeAPP1$2(out, exif) {
      var exifData, exifBytes;
      if (exif.get$isEmpty(0))
        return;
      exifData = A.OutputBuffer$(false, 8192);
      exif.write$1(exifData);
      exifBytes = J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(exifData._buffer), 0, exifData.length);
      this._writeMarker$2(out, 225);
      out.writeUint16$1(exifBytes.length + 8);
      out.writeUint32$1(1165519206);
      out.writeUint16$1(0);
      out.writeBytes$1(exifBytes);
    },
    _writeDQT$1(out) {
      var t1, i, j;
      this._writeMarker$2(out, 219);
      out.writeUint16$1(132);
      out.writeByte$1(0);
      for (t1 = this._yTable, i = 0; i < 64; ++i)
        out.writeByte$1(t1[i]);
      out.writeByte$1(1);
      for (t1 = this._uvTable, j = 0; j < 64; ++j)
        out.writeByte$1(t1[j]);
    },
    _writeDHT$1(out) {
      var i, j, k, l, m, n, o, p;
      this._writeMarker$2(out, 196);
      out.writeUint16$1(418);
      out.writeByte$1(0);
      for (i = 0; i < 16;) {
        ++i;
        out.writeByte$1(B.List_zcj[i]);
      }
      for (j = 0; j <= 11; ++j)
        out.writeByte$1(B.List_74c[j]);
      out.writeByte$1(16);
      for (k = 0; k < 16;) {
        ++k;
        out.writeByte$1(B.List_2BR[k]);
      }
      for (l = 0; l <= 161; ++l)
        out.writeByte$1(B.List_CZS[l]);
      out.writeByte$1(1);
      for (m = 0; m < 16;) {
        ++m;
        out.writeByte$1(B.List_NZS[m]);
      }
      for (n = 0; n <= 11; ++n)
        out.writeByte$1(B.List_74c[n]);
      out.writeByte$1(17);
      for (o = 0; o < 16;) {
        ++o;
        out.writeByte$1(B.List_GUW[o]);
      }
      for (p = 0; p <= 161; ++p)
        out.writeByte$1(B.List_X1N[p]);
    },
    _processDU$6(out, cdu, fdtbl, dc, htdc, htac) {
      var eob, m16Zeroes, duDct, j, t2, diff, t3, pos, end0pos, t4, i, i0, nrzeroes, lng, nrmarker, t5, _this = this,
        t1 = type$.List_double;
      t1._as(cdu);
      t1._as(fdtbl);
      type$.nullable_List_nullable_List_int._as(htdc);
      type$.List_nullable_List_int._as(htac);
      t1 = htac.length;
      if (0 >= t1)
        return A.ioore(htac, 0);
      eob = htac[0];
      if (240 >= t1)
        return A.ioore(htac, 240);
      m16Zeroes = htac[240];
      duDct = _this._fDCTQuant$2(cdu, fdtbl);
      for (t1 = _this._du, j = 0; j < 64; ++j)
        B.JSArray_methods.$indexSet(t1, B.List_EVh[j], duDct[j]);
      t2 = t1[0];
      t2.toString;
      diff = t2 - dc;
      if (diff === 0) {
        if (0 >= htdc.length)
          return A.ioore(htdc, 0);
        t3 = htdc[0];
        t3.toString;
        _this._writeBits$2(out, t3);
      } else {
        pos = 32767 + diff;
        htdc.toString;
        t3 = _this._category;
        if (!(pos >= 0 && pos < 65535))
          return A.ioore(t3, pos);
        t3 = t3[pos];
        t3.toString;
        if (!(t3 < htdc.length))
          return A.ioore(htdc, t3);
        t3 = htdc[t3];
        t3.toString;
        _this._writeBits$2(out, t3);
        t3 = _this._bitCode[pos];
        t3.toString;
        _this._writeBits$2(out, t3);
      }
      end0pos = 63;
      for (;;) {
        if (!(end0pos > 0 && t1[end0pos] === 0))
          break;
        --end0pos;
      }
      if (end0pos === 0) {
        eob.toString;
        _this._writeBits$2(out, eob);
        return t2;
      }
      for (t3 = _this._category, t4 = _this._bitCode, i = 1; i <= end0pos;) {
        i0 = i;
        for (;;) {
          if (!(i0 >= 0 && i0 < 64))
            return A.ioore(t1, i0);
          if (!(t1[i0] === 0 && i0 <= end0pos))
            break;
          ++i0;
        }
        nrzeroes = i0 - i;
        if (nrzeroes >= 16) {
          lng = B.JSInt_methods._shrOtherPositive$1(nrzeroes, 4);
          for (nrmarker = 1; nrmarker <= lng; ++nrmarker) {
            m16Zeroes.toString;
            _this._writeBits$2(out, m16Zeroes);
          }
          nrzeroes &= 15;
        }
        t5 = t1[i0];
        t5.toString;
        pos = 32767 + t5;
        if (!(pos >= 0 && pos < 65535))
          return A.ioore(t3, pos);
        t5 = t3[pos];
        t5.toString;
        t5 = (nrzeroes << 4 >>> 0) + t5;
        if (!(t5 < htac.length))
          return A.ioore(htac, t5);
        t5 = htac[t5];
        t5.toString;
        _this._writeBits$2(out, t5);
        t5 = t4[pos];
        t5.toString;
        _this._writeBits$2(out, t5);
        i = i0 + 1;
      }
      if (end0pos !== 63) {
        eob.toString;
        _this._writeBits$2(out, eob);
      }
      return t2;
    },
    _writeBits$2(out, bits) {
      var t1, value, posval, _this = this;
      type$.List_int._as(bits);
      t1 = bits.length;
      if (0 >= t1)
        return A.ioore(bits, 0);
      value = bits[0];
      if (1 >= t1)
        return A.ioore(bits, 1);
      posval = bits[1] - 1;
      while (posval >= 0) {
        if ((value & B.JSInt_methods.$shl(1, posval)) >>> 0 !== 0)
          _this._byteNew = (_this._byteNew | B.JSInt_methods.$shl(1, _this._bytePos)) >>> 0;
        --posval;
        if (--_this._bytePos < 0) {
          t1 = _this._byteNew;
          if (t1 === 255) {
            out.writeByte$1(255);
            out.writeByte$1(0);
          } else
            out.writeByte$1(t1);
          _this._bytePos = 7;
          _this._byteNew = 0;
        }
      }
    }
  };
  A.JpegHealthyEncoder_encode_healthCheck.prototype = {
    call$0() {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.void),
        $async$self = this, t1;
      var $async$call$0 = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              $async$goto = 2;
              return A._asyncAwait(A.Future_Future$delayed(B.Duration_10, type$.dynamic), $async$call$0);
            case 2:
              // returning from await.
              t1 = $async$self.destroy$;
              if ((t1 == null ? null : (t1.future._state & 30) !== 0) === true)
                throw A.wrapException(A.ArgumentError$("Kill encode jpg", null));
              // implicit return
              return A._asyncReturn(null, $async$completer);
          }
      });
      return A._asyncStartSync($async$call$0, $async$completer);
    },
    $signature: 30
  };
  A.PngFilter.prototype = {
    _enumToString$0() {
      return "PngFilter." + this._name;
    }
  };
  A.PngEncoder.prototype = {
    addFrame$1(image) {
      var t1, chunk, nc, channelBytes, t2, t3, filteredImage, output, compressed, fdat, _this = this, _null = null, _8192 = 8192;
      image.get$isHdrFormat();
      t1 = image.get$bitsPerChannel() < 8 && !image.get$hasPalette() && image.get$numChannels() > 1;
      if (t1)
        image = image.convert$0();
      if (_this.output == null) {
        t1 = A.OutputBuffer$(true, _8192);
        _this.output = t1;
        t1.writeBytes$1(A._setArrayType([137, 80, 78, 71, 13, 10, 26, 10], type$.JSArray_int));
        chunk = A.OutputBuffer$(true, _8192);
        chunk.writeUint32$1(image.get$width());
        chunk.writeUint32$1(image.get$height());
        chunk.writeByte$1(image.get$bitsPerChannel());
        if (image.get$hasPalette())
          t1 = 3;
        else if (image.get$numChannels() === 1)
          t1 = 0;
        else if (image.get$numChannels() === 2)
          t1 = 4;
        else
          t1 = image.get$numChannels() === 3 ? 2 : 6;
        chunk.writeByte$1(t1);
        chunk.writeByte$1(0);
        chunk.writeByte$1(0);
        chunk.writeByte$1(0);
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "IHDR", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(chunk._buffer), 0, chunk.length));
        if (image.get$hasPalette()) {
          t1 = _this._globalQuantizer;
          if (t1 != null) {
            t1 = t1.__NeuralQuantizer_palette_A;
            t1 === $ && A.throwLateFieldNI("palette");
            _this._writePalette$1(t1);
          } else {
            t1 = image.data;
            t1 = t1 == null ? _null : t1.palette;
            t1.toString;
            _this._writePalette$1(t1);
          }
        }
        if (_this.isAnimated) {
          chunk = A.OutputBuffer$(true, _8192);
          t1 = _this.__PngEncoder__frames_A;
          t1 === $ && A.throwLateFieldNI("_frames");
          chunk.writeUint32$1(t1);
          chunk.writeUint32$1(_this.repeat);
          t1 = _this.output;
          t1.toString;
          _this._writeChunk$3(t1, "acTL", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(chunk._buffer), 0, chunk.length));
        }
      }
      nc = image.get$hasPalette() ? 1 : image.get$numChannels();
      channelBytes = image.get$format() === B.Format_4 ? 2 : 1;
      t1 = image.get$width();
      t2 = image.get$height();
      t3 = image.get$height();
      filteredImage = new Uint8Array(t1 * t2 * nc * channelBytes + t3);
      _this._filter$2(0, image, filteredImage);
      type$.List_int._as(filteredImage);
      output = A.OutputMemoryStream$(B.ByteOrder_1);
      B.C__ZLibEncoder.encodeStream$5$level$raw$windowBits(A.InputMemoryStream$(filteredImage, B.ByteOrder_0, _null, _null), output, _this.level, false, _null);
      compressed = J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(output._output_memory_stream$_buffer), output._output_memory_stream$_buffer.byteOffset, output.length);
      t1 = image.textData;
      if (t1 != null)
        for (t1 = t1.get$keys(), t1 = t1.get$iterator(t1); t1.moveNext$0();) {
          t2 = t1.get$current();
          t3 = image.textData.$index(0, t2);
          t3.toString;
          chunk = new A.OutputBuffer(true, new Uint8Array(8192));
          chunk.writeBytes$1(B.C_Latin1Encoder.convert$1(t2));
          chunk.writeByte$1(0);
          chunk.writeBytes$1(B.C_Latin1Encoder.convert$1(t3));
          t2 = _this.output;
          t2.toString;
          _this._writeChunk$3(t2, "tEXt", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(chunk._buffer), 0, chunk.length));
        }
      if (_this.isAnimated) {
        chunk = A.OutputBuffer$(true, _8192);
        chunk.writeUint32$1(_this.sequenceNumber);
        chunk.writeUint32$1(image.get$width());
        chunk.writeUint32$1(image.get$height());
        chunk.writeUint32$1(0);
        chunk.writeUint32$1(0);
        chunk.writeUint16$1(image.frameDuration);
        chunk.writeUint16$1(1000);
        chunk.writeByte$1(1);
        chunk.writeByte$1(0);
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "fcTL", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(chunk._buffer), 0, chunk.length));
        ++_this.sequenceNumber;
      }
      if (_this.sequenceNumber <= 1) {
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "IDAT", compressed);
      } else {
        fdat = A.OutputBuffer$(true, _8192);
        fdat.writeUint32$1(_this.sequenceNumber);
        fdat.writeBytes$1(compressed);
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "fdAT", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(fdat._buffer), 0, fdat.length));
        ++_this.sequenceNumber;
      }
    },
    finish$0() {
      var bytes, _this = this,
        t1 = _this.output;
      if (t1 == null)
        return null;
      _this._writeChunk$3(t1, "IEND", A._setArrayType([], type$.JSArray_int));
      _this.sequenceNumber = 0;
      t1 = _this.output;
      bytes = J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(t1._buffer), 0, t1.length);
      _this.output = null;
      return bytes;
    },
    encode$2$singleFrame(image, singleFrame) {
      var t1, q, t2, _i, frame, t3, _this = this;
      if (image.get$frames().length <= 1 || singleFrame) {
        _this.__PngEncoder__frames_A = 1;
        _this.isAnimated = false;
        _this.addFrame$1(image);
      } else {
        t1 = image.get$frames().length;
        _this.__PngEncoder__frames_A = t1;
        _this.isAnimated = t1 > 1;
        _this.repeat = image.loopCount;
        if (image.get$hasPalette()) {
          q = new A.NeuralQuantizer(new Int32Array(256));
          q._initialize$1(256);
          q.addImage$1(image);
          _this._globalQuantizer = q;
          for (t1 = image.get$frames(), t2 = t1.length, _i = 0; _i < t1.length; t1.length === t2 || (0, A.throwConcurrentModificationError)(t1), ++_i) {
            frame = t1[_i];
            if (frame !== image) {
              q._learn$1(frame);
              q._fix$0();
              q._inxBuild$0();
              q._copyColorMap$0();
            }
          }
        }
        for (t1 = image.get$frames(), t2 = t1.length, _i = 0; _i < t1.length; t1.length === t2 || (0, A.throwConcurrentModificationError)(t1), ++_i) {
          frame = t1[_i];
          t3 = _this._globalQuantizer;
          if (t3 != null)
            _this.addFrame$1(t3.getIndexImage$1(frame));
          else
            _this.addFrame$1(frame);
        }
      }
      t1 = _this.finish$0();
      t1.toString;
      return t1;
    },
    encode$1(image) {
      return this.encode$2$singleFrame(image, false);
    },
    _writePalette$1(palette) {
      var t1, chunk, i, _this = this;
      if (palette.numChannels === 3 && palette.numColors === 256) {
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "PLTE", J.asUint8List$2$x(palette.get$buffer(0), 0, null));
      } else {
        t1 = palette.numColors;
        chunk = A.OutputBuffer$(true, t1 * 3);
        for (i = 0; i < t1; ++i) {
          chunk.writeByte$1(B.JSInt_methods.toInt$0(palette.getRed$1(i)));
          chunk.writeByte$1(B.JSInt_methods.toInt$0(palette.getGreen$1(i)));
          chunk.writeByte$1(B.JSInt_methods.toInt$0(palette.getBlue$1(i)));
        }
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "PLTE", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(chunk._buffer), 0, chunk.length));
      }
      if (palette.numChannels === 4) {
        t1 = palette.numColors;
        chunk = A.OutputBuffer$(true, t1);
        for (i = 0; i < t1; ++i)
          chunk.writeByte$1(B.JSInt_methods.toInt$0(palette.getAlpha$1(i)));
        t1 = _this.output;
        t1.toString;
        _this._writeChunk$3(t1, "tRNS", J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(chunk._buffer), 0, chunk.length));
      }
    },
    _writeChunk$3(out, type, chunk) {
      type$.List_int._as(chunk);
      out.writeUint32$1(chunk.length);
      out.writeBytes$1(new A.CodeUnits(type));
      out.writeBytes$1(chunk);
      out.writeUint32$1(A.getCrc32(chunk, A.getCrc32(new A.CodeUnits(type), 0)));
    },
    _filter$2(_, image, out) {
      var t2, oi, rowOffset, prevRow, y, t3, rowBytes, _this = this,
        filter = image.get$hasPalette() ? B.PngFilter_0 : _this.filter,
        buffer = image.get$buffer(0),
        t1 = image.data,
        rowStride = t1.width * t1.numChannels,
        nc = image.get$hasPalette() ? 1 : image.get$numChannels(),
        bpp = B.JSInt_methods._shrOtherPositive$1(nc * image.get$bitsPerChannel() + 7, 3),
        bpc = image.get$bitsPerChannel() + 7 >>> 3;
      t1 = filter.index;
      t2 = J.getInterceptor$x(buffer);
      oi = 0;
      rowOffset = 0;
      prevRow = null;
      y = 0;
      for (;;) {
        t3 = image.data;
        t3 = t3 == null ? null : t3.height;
        if (!(y < (t3 == null ? 0 : t3)))
          break;
        rowBytes = t2.asUint8List$2(buffer, rowOffset, rowStride);
        rowOffset += rowStride;
        switch (t1) {
          case 1:
            oi = _this._filterSub$5(rowBytes, bpc, bpp, out, oi);
            break;
          case 2:
            oi = _this._filterUp$5(rowBytes, prevRow, bpc, out, oi);
            break;
          case 3:
            oi = _this._filterAverage$6(rowBytes, prevRow, bpc, bpp, out, oi);
            break;
          case 4:
            oi = _this._filterPaeth$6(rowBytes, prevRow, bpc, bpp, out, oi);
            break;
          default:
            oi = _this._filterNone$4(rowBytes, bpc, out, oi);
            break;
        }
        ++y;
        prevRow = rowBytes;
      }
    },
    _write$5(bpc, row, ri, out, oi) {
      var t1, t2, oi0, t3;
      --bpc;
      for (t1 = row.length, t2 = out.$flags | 0; bpc >= 0; oi = oi0) {
        oi0 = oi + 1;
        t3 = ri + bpc;
        if (!(t3 < t1))
          return A.ioore(row, t3);
        t3 = row[t3];
        t2 & 2 && A.throwUnsupportedOperation(out);
        if (!(oi < out.length))
          return A.ioore(out, oi);
        out[oi] = t3;
        --bpc;
      }
      return oi;
    },
    _filterNone$4(rowBytes, bpc, out, oi) {
      var t1, l, i, t2,
        oi0 = oi + 1;
      out.$flags & 2 && A.throwUnsupportedOperation(out);
      t1 = out.length;
      if (!(oi < t1))
        return A.ioore(out, oi);
      out[oi] = 0;
      l = rowBytes.length;
      if (bpc === 1)
        for (oi = oi0, i = 0; i < l; ++i, oi = oi0) {
          oi0 = oi + 1;
          t2 = rowBytes[i];
          if (!(oi < t1))
            return A.ioore(out, oi);
          out[oi] = t2;
        }
      else
        for (oi = oi0, i = 0; i < l; i += bpc)
          oi = this._write$5(bpc, rowBytes, i, out, oi);
      return oi;
    },
    _filterSub$5(row, bpc, bpp, out, oi) {
      var t1, x, l, c2, t2, c20, c, t3, t4,
        oi0 = oi + 1;
      out.$flags & 2 && A.throwUnsupportedOperation(out);
      t1 = out.length;
      if (!(oi < t1))
        return A.ioore(out, oi);
      out[oi] = 1;
      for (oi = oi0, x = 0; x < bpp; x += bpc)
        oi = this._write$5(bpc, row, x, out, oi);
      l = row.length;
      for (c2 = bpc - 1, t2 = out.$flags | 0, x = bpp; x < l; x += bpc)
        for (c20 = c2, c = 0; c < bpc; ++c, --c20, oi = oi0) {
          oi0 = oi + 1;
          t3 = x + c20;
          if (!(t3 >= 0 && t3 < l))
            return A.ioore(row, t3);
          t4 = row[t3];
          t3 -= bpp;
          if (!(t3 >= 0))
            return A.ioore(row, t3);
          t3 = row[t3];
          t2 & 2 && A.throwUnsupportedOperation(out);
          if (!(oi >= 0 && oi < t1))
            return A.ioore(out, oi);
          out[oi] = t4 - t3 & 255;
        }
      return oi;
    },
    _filterUp$5(row, prevRow, bpc, out, oi) {
      var t1, l, c2, t2, t3, x, c20, c, t4, b,
        oi0 = oi + 1;
      out.$flags & 2 && A.throwUnsupportedOperation(out);
      t1 = out.length;
      if (!(oi < t1))
        return A.ioore(out, oi);
      out[oi] = 2;
      l = row.length;
      for (c2 = bpc - 1, t2 = out.$flags | 0, t3 = prevRow != null, oi = oi0, x = 0; x < l; x += bpc)
        for (c20 = c2, c = 0; c < bpc; ++c, --c20, oi = oi0) {
          if (t3) {
            t4 = x + c20;
            if (!(t4 >= 0 && t4 < prevRow.length))
              return A.ioore(prevRow, t4);
            b = prevRow[t4];
          } else
            b = 0;
          oi0 = oi + 1;
          t4 = x + c20;
          if (!(t4 >= 0 && t4 < l))
            return A.ioore(row, t4);
          t4 = row[t4];
          t2 & 2 && A.throwUnsupportedOperation(out);
          if (!(oi >= 0 && oi < t1))
            return A.ioore(out, oi);
          out[oi] = t4 - b & 255;
        }
      return oi;
    },
    _filterAverage$6(row, prevRow, bpc, bpp, out, oi) {
      var t1, l, c2, t2, t3, x, c20, c, x2, p1, t4, p2, p3,
        oi0 = oi + 1;
      out.$flags & 2 && A.throwUnsupportedOperation(out);
      t1 = out.length;
      if (!(oi < t1))
        return A.ioore(out, oi);
      out[oi] = 3;
      l = row.length;
      for (c2 = bpc - 1, t2 = out.$flags | 0, t3 = prevRow == null, oi = oi0, x = 0; x < l; x += bpc)
        for (c20 = c2, c = 0; c < bpc; ++c, --c20, oi = oi0) {
          x2 = x + c20;
          if (x2 < bpp)
            p1 = 0;
          else {
            t4 = x2 - bpp;
            if (!(t4 >= 0 && t4 < l))
              return A.ioore(row, t4);
            p1 = row[t4];
          }
          if (t3)
            p2 = 0;
          else {
            if (!(x2 >= 0 && x2 < prevRow.length))
              return A.ioore(prevRow, x2);
            p2 = prevRow[x2];
          }
          if (!(x2 >= 0 && x2 < l))
            return A.ioore(row, x2);
          p3 = row[x2];
          oi0 = oi + 1;
          t2 & 2 && A.throwUnsupportedOperation(out);
          if (!(oi >= 0 && oi < t1))
            return A.ioore(out, oi);
          out[oi] = p3 - (p1 + p2 >>> 1);
        }
      return oi;
    },
    _paethPredictor$3(a, b, c) {
      var p = a + b - c,
        pa = p > a ? p - a : a - p,
        pb = p > b ? p - b : b - p,
        pc = p > c ? p - c : c - p;
      if (pa <= pb && pa <= pc)
        return a;
      else if (pb <= pc)
        return b;
      return c;
    },
    _filterPaeth$6(row, prevRow, bpc, bpp, out, oi) {
      var t1, l, c2, t2, t3, x, c20, c, x2, t4, p0, t5, p1, p2, p, pi,
        oi0 = oi + 1;
      out.$flags & 2 && A.throwUnsupportedOperation(out);
      t1 = out.length;
      if (!(oi < t1))
        return A.ioore(out, oi);
      out[oi] = 4;
      l = row.length;
      for (c2 = bpc - 1, t2 = out.$flags | 0, t3 = prevRow == null, oi = oi0, x = 0; x < l; x += bpc)
        for (c20 = c2, c = 0; c < bpc; ++c, --c20, oi = oi0) {
          x2 = x + c20;
          t4 = x2 < bpp;
          if (t4)
            p0 = 0;
          else {
            t5 = x2 - bpp;
            if (!(t5 >= 0 && t5 < l))
              return A.ioore(row, t5);
            p0 = row[t5];
          }
          if (t3)
            p1 = 0;
          else {
            if (!(x2 >= 0 && x2 < prevRow.length))
              return A.ioore(prevRow, x2);
            p1 = prevRow[x2];
          }
          if (t4 || t3)
            p2 = 0;
          else {
            t4 = x2 - bpp;
            if (!(t4 >= 0 && t4 < prevRow.length))
              return A.ioore(prevRow, t4);
            p2 = prevRow[t4];
          }
          if (!(x2 >= 0 && x2 < l))
            return A.ioore(row, x2);
          p = row[x2];
          pi = this._paethPredictor$3(p0, p1, p2);
          oi0 = oi + 1;
          t2 & 2 && A.throwUnsupportedOperation(out);
          if (!(oi >= 0 && oi < t1))
            return A.ioore(out, oi);
          out[oi] = p - pi & 255;
        }
      return oi;
    }
  };
  A.PvrColorRgbCore.prototype = {};
  A.PvrColorRgb.prototype = {
    copy$0() {
      return new A.PvrColorRgb(this.r, this.g, this.b);
    },
    setMin$1(c) {
      var t1, _this = this;
      type$.PvrColorRgb._as(c);
      t1 = c.r;
      if (t1 < _this.r)
        _this.r = t1;
      t1 = c.g;
      if (t1 < _this.g)
        _this.g = t1;
      t1 = c.b;
      if (t1 < _this.b)
        _this.b = t1;
    },
    setMax$1(c) {
      var t1, _this = this;
      type$.PvrColorRgb._as(c);
      t1 = c.r;
      if (t1 > _this.r)
        _this.r = t1;
      t1 = c.g;
      if (t1 > _this.g)
        _this.g = t1;
      t1 = c.b;
      if (t1 > _this.b)
        _this.b = t1;
    }
  };
  A.PvrColorRgba.prototype = {
    copy$0() {
      var _this = this;
      return new A.PvrColorRgba(_this.r, _this.g, _this.b, _this.a);
    },
    $add(_, x) {
      var _this = this;
      return new A.PvrColorRgba(_this.r + x.r, _this.g + x.g, _this.b + x.b, _this.a + x.a);
    },
    $sub(_, x) {
      var _this = this;
      return new A.PvrColorRgba(_this.r - x.r, _this.g - x.g, _this.b - x.b, _this.a - x.a);
    },
    dotProd$1(x) {
      var _this = this;
      return _this.r * x.r + _this.g * x.g + _this.b * x.b + _this.a * x.a;
    },
    setMin$1(c) {
      var t1, _this = this;
      type$.PvrColorRgba._as(c);
      t1 = c.r;
      if (t1 < _this.r)
        _this.r = t1;
      t1 = c.g;
      if (t1 < _this.g)
        _this.g = t1;
      t1 = c.b;
      if (t1 < _this.b)
        _this.b = t1;
      t1 = c.a;
      if (t1 < _this.a)
        _this.a = t1;
    },
    setMax$1(c) {
      var t1, _this = this;
      type$.PvrColorRgba._as(c);
      t1 = c.r;
      if (t1 > _this.r)
        _this.r = t1;
      t1 = c.g;
      if (t1 > _this.g)
        _this.g = t1;
      t1 = c.b;
      if (t1 > _this.b)
        _this.b = t1;
      t1 = c.a;
      if (t1 > _this.a)
        _this.a = t1;
    }
  };
  A.PvrColorBoundingBox.prototype = {
    add$1(_, c) {
      this.$ti._precomputed1._as(c);
      this.min.setMin$1(c);
      this.max.setMax$1(c);
    }
  };
  A.PvrPacket.prototype = {
    set$colorData(x) {
      var t1 = this.rawData,
        t2 = this.index + 1;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (!(t2 < t1.length))
        return A.ioore(t1, t2);
      t1[t2] = x;
    },
    getColorRgbA$0() {
      var r,
        t1 = this._colorAIsOpaque,
        t2 = this._colorA;
      if (t1) {
        r = t2 >>> 9;
        if (!(r < 32))
          return A.ioore(B.List_vhF, r);
        return new A.PvrColorRgb(B.List_vhF[r], B.List_vhF[t2 >>> 4 & 31], B.List_qqA[t2 & 15]);
      } else
        return new A.PvrColorRgb(B.List_qqA[t2 >>> 7 & 15], B.List_qqA[t2 >>> 3 & 15], B.List_vdB[t2 & 7]);
    },
    getColorRgbaA$0() {
      var r,
        t1 = this._colorAIsOpaque,
        t2 = this._colorA;
      if (t1) {
        r = t2 >>> 9;
        if (!(r < 32))
          return A.ioore(B.List_vhF, r);
        return new A.PvrColorRgba(B.List_vhF[r], B.List_vhF[t2 >>> 4 & 31], B.List_qqA[t2 & 15], 255);
      } else
        return new A.PvrColorRgba(B.List_qqA[t2 >>> 7 & 15], B.List_qqA[t2 >>> 3 & 15], B.List_vdB[t2 & 7], B.List_vdB[t2 >>> 11 & 7]);
    },
    getColorRgbB$0() {
      var r,
        t1 = this._colorBIsOpaque,
        t2 = this._colorB;
      if (t1) {
        r = t2 >>> 10;
        if (!(r < 32))
          return A.ioore(B.List_vhF, r);
        return new A.PvrColorRgb(B.List_vhF[r], B.List_vhF[t2 >>> 5 & 31], B.List_vhF[t2 & 31]);
      } else
        return new A.PvrColorRgb(B.List_qqA[t2 >>> 8 & 15], B.List_qqA[t2 >>> 4 & 15], B.List_qqA[t2 & 15]);
    },
    getColorRgbaB$0() {
      var r,
        t1 = this._colorBIsOpaque,
        t2 = this._colorB;
      if (t1) {
        r = t2 >>> 10;
        if (!(r < 32))
          return A.ioore(B.List_vhF, r);
        return new A.PvrColorRgba(B.List_vhF[r], B.List_vhF[t2 >>> 5 & 31], B.List_vhF[t2 & 31], 255);
      } else
        return new A.PvrColorRgba(B.List_qqA[t2 >>> 8 & 15], B.List_qqA[t2 >>> 4 & 15], B.List_qqA[t2 & 15], B.List_vdB[t2 >>> 12 & 7]);
    },
    _getColorData$0() {
      var _this = this,
        t1 = _this._usePunchthroughAlpha ? 1 : 0,
        t2 = _this._colorA,
        t3 = _this._colorAIsOpaque ? 1 : 0,
        t4 = _this._colorB,
        t5 = _this._colorBIsOpaque ? 1 : 0;
      return (t1 | (t2 & 16383) << 1 | t3 << 15 | (t4 & 32767) << 16 | t5 << 31) >>> 0;
    },
    _update$0() {
      var x, _this = this,
        t1 = _this.rawData,
        t2 = _this.index + 1;
      if (!(t2 < t1.length))
        return A.ioore(t1, t2);
      x = t1[t2];
      _this._usePunchthroughAlpha = (x & 1) === 1;
      _this.set$colorData(_this._getColorData$0());
      _this._colorA = x >>> 1 & 16383;
      _this.set$colorData(_this._getColorData$0());
      _this._colorAIsOpaque = (x >>> 15 & 1) === 1;
      _this.set$colorData(_this._getColorData$0());
      _this._colorB = x >>> 16 & 32767;
      _this.set$colorData(_this._getColorData$0());
      _this._colorBIsOpaque = (x >>> 31 & 1) === 1;
      _this.set$colorData(_this._getColorData$0());
    }
  };
  A.PvrFormat.prototype = {
    _enumToString$0() {
      return "PvrFormat." + this._name;
    }
  };
  A.PvrEncoder.prototype = {
    encode$2$singleFrame(image, singleFrame) {
      var pvrtc, format, height, width,
        output = A.OutputBuffer$(false, 8192);
      switch (0) {
        case 0:
          if (image.get$numChannels() === 3) {
            pvrtc = this.encodeRgb4bpp$1(image);
            format = B.PvrFormat_3;
          } else {
            pvrtc = this.encodeRgba4bpp$1(image);
            format = B.PvrFormat_4;
          }
          break;
      }
      height = image.get$height();
      width = image.get$width();
      output.writeUint32$1(55727696);
      output.writeUint32$1(0);
      output.writeUint32$1(format.index - 1);
      output.writeUint32$1(0);
      output.writeUint32$1(0);
      output.writeUint32$1(0);
      output.writeUint32$1(height);
      output.writeUint32$1(width);
      output.writeUint32$1(1);
      output.writeUint32$1(1);
      output.writeUint32$1(1);
      output.writeUint32$1(1);
      output.writeUint32$1(0);
      output.writeBytes$1(pvrtc);
      return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(output._buffer), 0, output.length);
    },
    encodeRgb4bpp$1(bitmap) {
      var t1, blocks, blockMask, outputData, packet, p0, p1, p2, p3, t2, t3, y, x, cbb, t4, t5, t6, r, g, y4, x4, factorIndex, modulationData, py, y0, y1, px, x0, x1, t7, t8, t9, t10, t11, t12, t13, t14, t15, t16, t17, t18, t19, t20, t21, t22, t23, pi, pixel, projection, lengthSquared;
      if (bitmap.get$width() !== bitmap.get$height())
        throw A.wrapException(A.ImageException$("PVRTC requires a square image."));
      t1 = bitmap.get$width();
      if ((t1 & t1 - 1) >>> 0 !== 0)
        throw A.wrapException(A.ImageException$(string$.PVRTC_));
      blocks = B.JSInt_methods._tdivFast$1(bitmap.get$width(), 4);
      blockMask = blocks - 1;
      t1 = B.JSInt_methods._tdivFast$1(bitmap.get$width() * bitmap.get$height(), 2);
      outputData = new Uint8Array(t1);
      t1 = J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null);
      packet = new A.PvrPacket(t1);
      p0 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      p1 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      p2 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      p3 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      for (t2 = t1.$flags | 0, t3 = type$.PvrColorRgb, y = 0; y < blocks; ++y)
        for (x = 0; x < blocks; ++x) {
          cbb = A.PvrEncoder__calculateBoundingBoxRgb(bitmap, x, y);
          packet.index = A.PvrPacket__getMortonNumber(x, y) << 1 >>> 0;
          packet._update$0();
          packet._usePunchthroughAlpha = false;
          t4 = packet._getColorData$0();
          t5 = packet.index + 1;
          t2 & 2 && A.throwUnsupportedOperation(t1);
          if (!(t5 < t1.length))
            return A.ioore(t1, t5);
          t1[t5] = t4;
          t4 = t3._as(cbb.min);
          t6 = t4.r;
          if (!(t6 >= 0 && t6 < 256))
            return A.ioore(B.List_i9p, t6);
          r = B.List_i9p[t6];
          t6 = t4.g;
          if (!(t6 >= 0 && t6 < 256))
            return A.ioore(B.List_i9p, t6);
          g = B.List_i9p[t6];
          t4 = t4.b;
          if (!(t4 >= 0 && t4 < 256))
            return A.ioore(B.List_0H6, t4);
          packet._colorA = (r << 9 | g << 4 | B.List_0H6[t4]) >>> 0;
          t1[t5] = packet._getColorData$0();
          packet._colorAIsOpaque = true;
          t1[t5] = packet._getColorData$0();
          t4 = t3._as(cbb.max);
          t6 = t4.r;
          if (!(t6 >= 0 && t6 < 256))
            return A.ioore(B.List_ODE, t6);
          r = B.List_ODE[t6];
          t6 = t4.g;
          if (!(t6 >= 0 && t6 < 256))
            return A.ioore(B.List_ODE, t6);
          g = B.List_ODE[t6];
          t4 = t4.b;
          if (!(t4 >= 0 && t4 < 256))
            return A.ioore(B.List_ODE, t4);
          packet._colorB = (r << 10 | g << 5 | B.List_ODE[t4]) >>> 0;
          t1[t5] = packet._getColorData$0();
          packet._colorBIsOpaque = false;
          t1[t5] = packet._getColorData$0();
        }
      for (y = 0, y4 = 0; y < blocks; ++y, y4 += 4)
        for (x = 0, x4 = 0; x < blocks; ++x, x4 += 4) {
          for (factorIndex = 0, modulationData = 0, py = 0; py < 4; ++py) {
            y0 = (y + (py < 2 ? -1 : 0) & blockMask) >>> 0;
            y1 = (y0 + 1 & blockMask) >>> 0;
            for (t3 = y4 + py, px = 0; px < 4; ++px) {
              x0 = (x + (px < 2 ? -1 : 0) & blockMask) >>> 0;
              x1 = (x0 + 1 & blockMask) >>> 0;
              p0.index = A.PvrPacket__getMortonNumber(x0, y0) << 1 >>> 0;
              p0._update$0();
              p1.index = A.PvrPacket__getMortonNumber(x1, y0) << 1 >>> 0;
              p1._update$0();
              p2.index = A.PvrPacket__getMortonNumber(x0, y1) << 1 >>> 0;
              p2._update$0();
              p3.index = A.PvrPacket__getMortonNumber(x1, y1) << 1 >>> 0;
              p3._update$0();
              t4 = p0.getColorRgbA$0();
              if (!(factorIndex >= 0 && factorIndex < 16))
                return A.ioore(B.List_zrs, factorIndex);
              t5 = B.List_zrs[factorIndex][0];
              t6 = t4.r;
              t7 = t4.g;
              t4 = t4.b;
              t8 = p1.getColorRgbA$0();
              t9 = B.List_zrs[factorIndex][1];
              t10 = t8.r;
              t11 = t8.g;
              t8 = t8.b;
              t12 = p2.getColorRgbA$0();
              t13 = B.List_zrs[factorIndex][2];
              t14 = t12.r;
              t15 = t12.g;
              t12 = t12.b;
              t16 = p3.getColorRgbA$0();
              t17 = B.List_zrs[factorIndex][3];
              t14 = t6 * t5 + t10 * t9 + t14 * t13 + t16.r * t17;
              t15 = t7 * t5 + t11 * t9 + t15 * t13 + t16.g * t17;
              t17 = t4 * t5 + t8 * t9 + t12 * t13 + t16.b * t17;
              t16 = p0.getColorRgbB$0();
              t13 = B.List_zrs[factorIndex][0];
              t12 = t16.r;
              t9 = t16.g;
              t16 = t16.b;
              t8 = p1.getColorRgbB$0();
              t5 = B.List_zrs[factorIndex][1];
              t4 = t8.r;
              t11 = t8.g;
              t8 = t8.b;
              t7 = p2.getColorRgbB$0();
              t10 = B.List_zrs[factorIndex][2];
              t6 = t7.r;
              t18 = t7.g;
              t7 = t7.b;
              t19 = p3.getColorRgbB$0();
              t20 = B.List_zrs[factorIndex][3];
              t21 = t19.r;
              t22 = t19.g;
              t19 = t19.b;
              t23 = bitmap.data;
              if (t23 == null)
                pi = null;
              else {
                pixel = new A.PixelUint8(-1, 0, -t23.numChannels, t23);
                pixel.setPosition$2(x4 + px, t3);
                pi = pixel;
              }
              if (pi == null)
                pi = new A.PixelUndefined();
              t4 = t12 * t13 + t4 * t5 + t6 * t10 + t21 * t20 - t14;
              t22 = t9 * t13 + t11 * t5 + t18 * t10 + t22 * t20 - t15;
              t20 = t16 * t13 + t8 * t5 + t7 * t10 + t19 * t20 - t17;
              projection = ((B.JSInt_methods.toInt$0(pi.get$r()) * 16 - t14) * t4 + (B.JSInt_methods.toInt$0(pi.get$g()) * 16 - t15) * t22 + (B.JSInt_methods.toInt$0(pi.get$b()) * 16 - t17) * t20) * 16;
              lengthSquared = t4 * t4 + t22 * t22 + t20 * t20;
              if (projection > 3 * lengthSquared)
                ++modulationData;
              if (projection > 8 * lengthSquared)
                ++modulationData;
              if (projection > 13 * lengthSquared)
                ++modulationData;
              modulationData = (modulationData >>> 2 | modulationData << 30) >>> 0;
              ++factorIndex;
            }
          }
          packet.index = A.PvrPacket__getMortonNumber(x, y) << 1 >>> 0;
          packet._update$0();
          t3 = packet.index;
          t2 & 2 && A.throwUnsupportedOperation(t1);
          if (!(t3 < t1.length))
            return A.ioore(t1, t3);
          t1[t3] = modulationData;
        }
      return outputData;
    },
    encodeRgba4bpp$1(bitmap) {
      var t1, blocks, blockMask, outputData, packet, p0, p1, p2, p3, t2, t3, y, y4, x, x4, cbb, t4, t5, t6, a, t7, r, g, factorIndex, modulationData, py, y0, y1, px, x0, x1, t8, t9, t10, ca, cb, bp, pixel, b, d, projection, lengthSquared;
      if (bitmap.get$width() !== bitmap.get$height())
        throw A.wrapException(A.ImageException$("PVRTC requires a square image."));
      t1 = bitmap.get$width();
      if ((t1 & t1 - 1) >>> 0 !== 0)
        throw A.wrapException(A.ImageException$(string$.PVRTC_));
      blocks = B.JSInt_methods._tdivFast$1(bitmap.get$width(), 4);
      blockMask = blocks - 1;
      t1 = B.JSInt_methods._tdivFast$1(bitmap.get$width() * bitmap.get$height(), 2);
      outputData = new Uint8Array(t1);
      t1 = J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null);
      packet = new A.PvrPacket(t1);
      p0 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      p1 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      p2 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      p3 = new A.PvrPacket(J.asUint32List$2$x(B.NativeUint8List_methods.get$buffer(outputData), 0, null));
      for (t2 = type$.PvrColorRgba, t3 = t1.$flags | 0, y = 0, y4 = 0; y < blocks; ++y, y4 += 4)
        for (x = 0, x4 = 0; x < blocks; ++x, x4 += 4) {
          cbb = A.PvrEncoder__calculateBoundingBoxRgba(bitmap, x4, y4);
          packet.index = A.PvrPacket__getMortonNumber(x, y) << 1 >>> 0;
          packet._update$0();
          packet._usePunchthroughAlpha = false;
          t4 = packet._getColorData$0();
          t5 = packet.index + 1;
          t3 & 2 && A.throwUnsupportedOperation(t1);
          if (!(t5 < t1.length))
            return A.ioore(t1, t5);
          t1[t5] = t4;
          t4 = t2._as(cbb.min);
          t6 = t4.a;
          if (!(t6 >= 0 && t6 < 256))
            return A.ioore(B.List_mEo, t6);
          a = B.List_mEo[t6];
          t6 = t4.r;
          t7 = t4.g;
          t4 = t4.b;
          if (a === 7) {
            if (!(t6 >= 0 && t6 < 256))
              return A.ioore(B.List_i9p, t6);
            r = B.List_i9p[t6];
            if (!(t7 >= 0 && t7 < 256))
              return A.ioore(B.List_i9p, t7);
            g = B.List_i9p[t7];
            if (!(t4 >= 0 && t4 < 256))
              return A.ioore(B.List_0H6, t4);
            packet._colorA = (r << 9 | g << 4 | B.List_0H6[t4]) >>> 0;
            t1[t5] = packet._getColorData$0();
            packet._colorAIsOpaque = true;
            t1[t5] = packet._getColorData$0();
          } else {
            if (!(t6 >= 0 && t6 < 256))
              return A.ioore(B.List_0H6, t6);
            r = B.List_0H6[t6];
            if (!(t7 >= 0 && t7 < 256))
              return A.ioore(B.List_0H6, t7);
            g = B.List_0H6[t7];
            if (!(t4 >= 0 && t4 < 256))
              return A.ioore(B.List_mEo, t4);
            packet._colorA = (a << 11 | r << 7 | g << 3 | B.List_mEo[t4]) >>> 0;
            t1[t5] = packet._getColorData$0();
            packet._colorAIsOpaque = false;
            t1[t5] = packet._getColorData$0();
          }
          t4 = t2._as(cbb.max);
          t6 = t4.a;
          if (!(t6 >= 0 && t6 < 256))
            return A.ioore(B.List_4f6, t6);
          a = B.List_4f6[t6];
          t6 = t4.r;
          t7 = t4.g;
          t4 = t4.b;
          if (a === 7) {
            if (!(t6 >= 0 && t6 < 256))
              return A.ioore(B.List_ODE, t6);
            r = B.List_ODE[t6];
            if (!(t7 >= 0 && t7 < 256))
              return A.ioore(B.List_ODE, t7);
            g = B.List_ODE[t7];
            if (!(t4 >= 0 && t4 < 256))
              return A.ioore(B.List_ODE, t4);
            packet._colorB = (r << 10 | g << 5 | B.List_ODE[t4]) >>> 0;
            t1[t5] = packet._getColorData$0();
            packet._colorBIsOpaque = true;
            t1[t5] = packet._getColorData$0();
          } else {
            if (!(t6 >= 0 && t6 < 256))
              return A.ioore(B.List_Ib9, t6);
            r = B.List_Ib9[t6];
            if (!(t7 >= 0 && t7 < 256))
              return A.ioore(B.List_Ib9, t7);
            g = B.List_Ib9[t7];
            if (!(t4 >= 0 && t4 < 256))
              return A.ioore(B.List_Ib9, t4);
            packet._colorB = (a << 12 | r << 8 | g << 4 | B.List_Ib9[t4]) >>> 0;
            t1[t5] = packet._getColorData$0();
            packet._colorBIsOpaque = false;
            t1[t5] = packet._getColorData$0();
          }
        }
      for (y = 0, y4 = 0; y < blocks; ++y, y4 += 4)
        for (x = 0, x4 = 0; x < blocks; ++x, x4 += 4) {
          for (factorIndex = 0, modulationData = 0, py = 0; py < 4; ++py) {
            y0 = (y + (py < 2 ? -1 : 0) & blockMask) >>> 0;
            y1 = (y0 + 1 & blockMask) >>> 0;
            for (t2 = y4 + py, px = 0; px < 4; ++px) {
              x0 = (x + (px < 2 ? -1 : 0) & blockMask) >>> 0;
              x1 = (x0 + 1 & blockMask) >>> 0;
              p0.index = A.PvrPacket__getMortonNumber(x0, y0) << 1 >>> 0;
              p0._update$0();
              p1.index = A.PvrPacket__getMortonNumber(x1, y0) << 1 >>> 0;
              p1._update$0();
              p2.index = A.PvrPacket__getMortonNumber(x0, y1) << 1 >>> 0;
              p2._update$0();
              p3.index = A.PvrPacket__getMortonNumber(x1, y1) << 1 >>> 0;
              p3._update$0();
              t4 = p0.getColorRgbaA$0();
              if (!(factorIndex >= 0 && factorIndex < 16))
                return A.ioore(B.List_zrs, factorIndex);
              t5 = B.List_zrs[factorIndex][0];
              t6 = t4.r;
              t7 = t4.g;
              t8 = t4.b;
              t4 = t4.a;
              t9 = p1.getColorRgbaA$0();
              t10 = B.List_zrs[factorIndex][1];
              t10 = new A.PvrColorRgba(t6 * t5, t7 * t5, t8 * t5, t4 * t5).$add(0, new A.PvrColorRgba(t9.r * t10, t9.g * t10, t9.b * t10, t9.a * t10));
              t9 = p2.getColorRgbaA$0();
              t5 = B.List_zrs[factorIndex][2];
              t5 = t10.$add(0, new A.PvrColorRgba(t9.r * t5, t9.g * t5, t9.b * t5, t9.a * t5));
              t9 = p3.getColorRgbaA$0();
              t10 = B.List_zrs[factorIndex][3];
              ca = t5.$add(0, new A.PvrColorRgba(t9.r * t10, t9.g * t10, t9.b * t10, t9.a * t10));
              t10 = p0.getColorRgbaB$0();
              t9 = B.List_zrs[factorIndex][0];
              t5 = t10.r;
              t4 = t10.g;
              t8 = t10.b;
              t10 = t10.a;
              t7 = p1.getColorRgbaB$0();
              t6 = B.List_zrs[factorIndex][1];
              t6 = new A.PvrColorRgba(t5 * t9, t4 * t9, t8 * t9, t10 * t9).$add(0, new A.PvrColorRgba(t7.r * t6, t7.g * t6, t7.b * t6, t7.a * t6));
              t7 = p2.getColorRgbaB$0();
              t9 = B.List_zrs[factorIndex][2];
              t9 = t6.$add(0, new A.PvrColorRgba(t7.r * t9, t7.g * t9, t7.b * t9, t7.a * t9));
              t7 = p3.getColorRgbaB$0();
              t6 = B.List_zrs[factorIndex][3];
              cb = t9.$add(0, new A.PvrColorRgba(t7.r * t6, t7.g * t6, t7.b * t6, t7.a * t6));
              t6 = bitmap.data;
              if (t6 == null)
                bp = null;
              else {
                pixel = new A.PixelUint8(-1, 0, -t6.numChannels, t6);
                pixel.setPosition$2(x4 + px, t2);
                bp = pixel;
              }
              if (bp == null)
                bp = new A.PixelUndefined();
              r = bp.get$r();
              g = bp.get$g();
              b = bp.get$b();
              a = bp.get$a();
              d = cb.$sub(0, ca);
              projection = new A.PvrColorRgba(r * 16, g * 16, b * 16, a * 16).$sub(0, ca).dotProd$1(d) * 16;
              lengthSquared = d.dotProd$1(d);
              if (projection > 3 * lengthSquared)
                ++modulationData;
              if (projection > 8 * lengthSquared)
                ++modulationData;
              if (projection > 13 * lengthSquared)
                ++modulationData;
              modulationData = (modulationData >>> 2 | modulationData << 30) >>> 0;
              ++factorIndex;
            }
          }
          packet.index = A.PvrPacket__getMortonNumber(x, y) << 1 >>> 0;
          packet._update$0();
          t2 = packet.index;
          t3 & 2 && A.throwUnsupportedOperation(t1);
          if (!(t2 < t1.length))
            return A.ioore(t1, t2);
          t1[t2] = modulationData;
        }
      return outputData;
    }
  };
  A.PvrEncoder__calculateBoundingBoxRgb_pixel.prototype = {
    call$2(x, y) {
      var p = this.bitmap.getPixel$2(this.blockX + x, this.blockY + y);
      return new A.PvrColorRgb(p.get$r(), p.get$g(), p.get$b());
    },
    $signature: 31
  };
  A.PvrEncoder__calculateBoundingBoxRgba_pixel.prototype = {
    call$2(x, y) {
      var p = this.bitmap.getPixel$2(this.blockX + x, this.blockY + y);
      return new A.PvrColorRgba(p.get$r(), p.get$g(), p.get$b(), p.get$a());
    },
    $signature: 32
  };
  A.TgaEncoder.prototype = {
    encode$1(image) {
      var t1, nc, y, x, t2, t3, c, pixel, _null = null,
        out = A.OutputBuffer$(true, 8192),
        header = A.List_List$filled(18, 0, false, type$.int);
      B.JSArray_methods.$indexSet(header, 2, 2);
      B.JSArray_methods.$indexSet(header, 12, image.get$width() & 255);
      B.JSArray_methods.$indexSet(header, 13, B.JSInt_methods._shrOtherPositive$1(image.get$width(), 8) & 255);
      B.JSArray_methods.$indexSet(header, 14, image.get$height() & 255);
      B.JSArray_methods.$indexSet(header, 15, B.JSInt_methods._shrOtherPositive$1(image.get$height(), 8) & 255);
      t1 = image.data;
      t1 = t1 == null ? _null : t1.palette;
      nc = t1 == null ? _null : t1.numChannels;
      if (nc == null)
        nc = image.get$numChannels();
      B.JSArray_methods.$indexSet(header, 16, nc === 3 ? 24 : 32);
      out.writeBytes$1(header);
      if (nc === 4)
        for (y = image.get$height() - 1; y >= 0; --y) {
          x = 0;
          for (;;) {
            t1 = image.data;
            t2 = t1 == null;
            t3 = t2 ? _null : t1.width;
            if (!(x < (t3 == null ? 0 : t3)))
              break;
            if (t2)
              c = _null;
            else {
              pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
              pixel.setPosition$2(x, y);
              c = pixel;
            }
            if (c == null)
              c = new A.PixelUndefined();
            out.writeByte$1(c.get$b());
            out.writeByte$1(c.get$g());
            out.writeByte$1(c.get$r());
            out.writeByte$1(c.get$a());
            ++x;
          }
        }
      else
        for (y = image.get$height() - 1; y >= 0; --y) {
          x = 0;
          for (;;) {
            t1 = image.data;
            t2 = t1 == null;
            t3 = t2 ? _null : t1.width;
            if (!(x < (t3 == null ? 0 : t3)))
              break;
            if (t2)
              c = _null;
            else {
              pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
              pixel.setPosition$2(x, y);
              c = pixel;
            }
            if (c == null)
              c = new A.PixelUndefined();
            out.writeByte$1(c.get$b());
            out.writeByte$1(c.get$g());
            out.writeByte$1(c.get$r());
            ++x;
          }
        }
      return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(out._buffer), 0, out.length);
    }
  };
  A.TiffFormat.prototype = {
    _enumToString$0() {
      return "TiffFormat." + this._name;
    }
  };
  A.TiffEncoder.prototype = {
    encode$2$singleFrame(image, singleFrame) {
      var type, nc, ifd0, t1, p, numC, colorMap, t2, t3, t4, c, ci, t5, i, ci0, t6, _s4_ = "ifd0",
        out = A.OutputBuffer$(false, 8192),
        exif = new A.ExifData(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.IfdDirectory));
      if (image._exif != null)
        exif.$index(0, _s4_).copy$1(image.get$exif().$index(0, _s4_));
      image.get$isHdrFormat();
      if (image.get$numChannels() === 1)
        type = 1;
      else
        type = image.get$hasPalette() ? 3 : 2;
      nc = image.get$numChannels();
      ifd0 = exif.$index(0, _s4_);
      ifd0.$indexSet(0, "ImageWidth", image.get$width());
      ifd0.$indexSet(0, "ImageHeight", image.get$height());
      ifd0.$indexSet(0, "BitsPerSample", image.get$bitsPerChannel());
      ifd0.$indexSet(0, "SampleFormat", this._getSampleFormat$1(image).index);
      ifd0.$indexSet(0, "SamplesPerPixel", image.get$hasPalette() ? 1 : nc);
      ifd0.$indexSet(0, "Compression", 1);
      ifd0.$indexSet(0, "PhotometricInterpretation", type);
      ifd0.$indexSet(0, "RowsPerStrip", image.get$height());
      ifd0.$indexSet(0, "PlanarConfiguration", 1);
      ifd0.$indexSet(0, "TileWidth", image.get$width());
      ifd0.$indexSet(0, "TileLength", image.get$height());
      ifd0.$indexSet(0, "StripByteCounts", image.get$lengthInBytes(0));
      t1 = image.data;
      t1 = t1 == null ? null : J.asUint8List$0$x(B.NativeUint8List_methods.get$buffer(t1.data));
      ifd0.$indexSet(0, "StripOffsets", new A.IfdValueUndefined(new Uint8Array(A._ensureNativeList(t1 == null ? J.asUint8List$0$x(image.get$buffer(0)) : t1))));
      if (image.get$hasPalette()) {
        t1 = image.data;
        p = t1 == null ? null : t1.palette;
        numC = p.numColors;
        t1 = numC * 3;
        colorMap = new Uint16Array(t1);
        for (t2 = p.numChannels, t3 = p.data, t4 = t3.length, c = 0, ci = 0; c < 3; ++c)
          for (t5 = c < t2, i = 0; i < numC; ++i, ci = ci0) {
            ci0 = ci + 1;
            if (t5) {
              t6 = i * t2 + c;
              if (!(t6 >= 0 && t6 < t4))
                return A.ioore(t3, t6);
              t6 = t3[t6];
            } else
              t6 = 0;
            t6 = B.JSInt_methods.toInt$0(t6);
            if (!(ci >= 0 && ci < t1))
              return A.ioore(colorMap, ci);
            colorMap[ci] = t6 << 8 >>> 0;
          }
        ifd0.$indexSet(0, "ColorMap", colorMap);
      }
      exif.write$1(out);
      return J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(out._buffer), 0, out.length);
    },
    _getSampleFormat$1(image) {
      var t1 = image.data == null ? null : B.FormatType_0;
      switch ((t1 == null ? B.FormatType_0 : t1).index) {
        case 0:
          return B.TiffFormat_1;
        case 1:
          return B.TiffFormat_2;
        case 2:
          return B.TiffFormat_3;
      }
    }
  };
  A.FrameType.prototype = {
    _enumToString$0() {
      return "FrameType." + this._name;
    }
  };
  A.Image.prototype = {
    Image$fromResized$4$height$noAnimation$width(other, height, noAnimation, width) {
      var numFrames, fi, value, _this = this,
        t1 = other.get$numChannels(),
        t2 = other.data;
      _this._createImageData$4(width, height, t1, t2 == null ? null : t2.palette);
      t1 = other.extraChannels;
      if (t1 != null)
        _this.extraChannels = A.LinkedHashMap_LinkedHashMap$from(t1, type$.String, type$.ImageData);
      t1 = other.textData;
      if (t1 != null) {
        t2 = type$.String;
        _this.textData = A.LinkedHashMap_LinkedHashMap$from(t1, t2, t2);
      }
      B.JSArray_methods.add$1(_this.get$frames(), _this);
      if (!noAnimation) {
        numFrames = other.get$frames().length;
        for (t1 = type$.JSArray_Image, fi = 1; fi < numFrames; ++fi) {
          value = other.__Image_frames_AI;
          if (value === $)
            value = other.__Image_frames_AI = A._setArrayType([], t1);
          if (!(fi < value.length))
            return A.ioore(value, fi);
          _this.addFrame$1(A.Image$fromResized(value[fi], height, false, width));
        }
      }
    },
    Image$from$3$noAnimation$noPixels(other, noAnimation, noPixels) {
      var t2, numFrames, fi, value, _this = this,
        t1 = other.extraChannels;
      if (t1 != null)
        _this.extraChannels = A.LinkedHashMap_LinkedHashMap$from(t1, type$.String, type$.ImageData);
      t1 = other.textData;
      if (t1 != null) {
        t2 = type$.String;
        _this.textData = A.LinkedHashMap_LinkedHashMap$from(t1, t2, t2);
      }
      B.JSArray_methods.add$1(_this.get$frames(), _this);
      if (!noAnimation && other.get$frames().length > 1) {
        numFrames = other.get$frames().length;
        for (t1 = type$.JSArray_Image, fi = 1; fi < numFrames; ++fi) {
          value = other.__Image_frames_AI;
          if (value === $)
            value = other.__Image_frames_AI = A._setArrayType([], t1);
          if (!(fi < value.length))
            return A.ioore(value, fi);
          _this.addFrame$1(A.Image$from(value[fi], false, false));
        }
      }
    },
    Image$fromBytes$18$backgroundColor$bytes$bytesOffset$exif$format$frameDuration$frameIndex$frameType$height$iccp$loopCount$numChannels$order$palette$rowStride$textData$width$withPalette(backgroundColor, bytes, bytesOffset, exif, format, frameDuration, frameIndex, frameType, height, iccp, loopCount, numChannels, order, palette, rowStride, textData, width, withPalette) {
      var t1, toBytes, fromBytes, t2, dataStride, stride, dOff, bOff, y, elementSize, end, dOff0, p, t3, r, t4, t5, g, b, a, _this = this;
      B.JSArray_methods.add$1(_this.get$frames(), _this);
      if (numChannels == null)
        numChannels = 3;
      if (numChannels < 0 || numChannels > 4)
        throw A.wrapException(A.ImageException$("An Image can only have 1-4 channels."));
      if (numChannels === 3)
        order = B.ChannelOrder_4;
      else if (numChannels === 4)
        order = B.ChannelOrder_0;
      else {
        t1 = numChannels === 1 ? B.ChannelOrder_7 : B.ChannelOrder_6;
        order = t1;
      }
      if (numChannels === 1)
        order = B.ChannelOrder_7;
      else if (numChannels === 2)
        order = B.ChannelOrder_6;
      else if (numChannels === 3) {
        if (order !== B.ChannelOrder_4 && order !== B.ChannelOrder_5)
          order = B.ChannelOrder_4;
      } else if (numChannels === 4)
        if (order !== B.ChannelOrder_1 && order !== B.ChannelOrder_0 && order !== B.ChannelOrder_2 && order !== B.ChannelOrder_3)
          order = B.ChannelOrder_0;
      _this._image$_initialize$7$exif$iccp$numChannels$palette$withPalette(width, height, exif, iccp, numChannels, palette, false);
      t1 = _this.data;
      if (t1 == null)
        return;
      toBytes = J.asUint8List$0$x(B.NativeUint8List_methods.get$buffer(t1.data));
      fromBytes = B.NativeArrayBuffer_methods.asUint8List$2(bytes, bytesOffset, null);
      if (rowStride == null)
        if (format === B.Format_0)
          rowStride = B.JSNumber_methods.ceil$0(width * numChannels / 8);
        else if (format === B.Format_1) {
          t1 = B.JSNumber_methods.ceil$0(width * numChannels / 4);
          rowStride = t1;
        } else {
          t1 = width * numChannels;
          if (format === B.Format_2)
            t1 = B.JSNumber_methods.ceil$0(t1 / 2);
          else {
            t2 = B.Map_vw4lG.$index(0, format);
            t2.toString;
            t2 = t1 * t2;
            t1 = t2;
          }
          rowStride = t1;
        }
      t1 = _this.data;
      dataStride = t1.width * t1.numChannels;
      stride = Math.min(rowStride, dataStride);
      for (dOff = 0, bOff = 0, y = 0; y < height; ++y, bOff += rowStride, dOff = dOff0) {
        elementSize = fromBytes.BYTES_PER_ELEMENT;
        end = A.RangeError_checkValidRange(bOff, bOff + stride, B.JSInt_methods.$tdiv(fromBytes.byteLength, elementSize));
        dOff0 = dOff + dataStride;
        B.NativeUint8List_methods.setRange$3(toBytes, dOff, dOff0, J.asUint8List$2$x(B.NativeUint8List_methods.get$buffer(fromBytes), fromBytes.byteOffset + bOff * elementSize, (end - bOff) * elementSize));
      }
      if (numChannels === 3 && order === B.ChannelOrder_5) {
        t1 = _this.data;
        t1.toString;
        p = A.PixelUint8$imageData(t1);
        t1 = p.image;
        t2 = t1.numChannels > 0;
        t1 = t1.data;
        t3 = t1.$flags | 0;
        while (p.moveNext$0()) {
          r = p.get$r();
          t4 = p.get$b();
          if (t2) {
            t5 = p._pixel_uint8$_index;
            t4 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(t4, 0, 255));
            t3 & 2 && A.throwUnsupportedOperation(t1);
            if (!(t5 >= 0 && t5 < t1.length))
              return A.ioore(t1, t5);
            t1[t5] = t4;
          }
          p.set$b(r);
        }
      } else {
        t1 = numChannels === 4;
        if (t1 && order === B.ChannelOrder_2) {
          t1 = _this.data;
          t1.toString;
          p = A.PixelUint8$imageData(t1);
          t1 = p.image;
          t2 = t1.numChannels > 0;
          t1 = t1.data;
          t3 = t1.$flags | 0;
          while (p.moveNext$0()) {
            r = p.get$r();
            g = p.get$g();
            b = p.get$b();
            a = p.get$a();
            if (t2) {
              t4 = p._pixel_uint8$_index;
              t5 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(a, 0, 255));
              t3 & 2 && A.throwUnsupportedOperation(t1);
              if (!(t4 >= 0 && t4 < t1.length))
                return A.ioore(t1, t4);
              t1[t4] = t5;
            }
            p.set$g(b);
            p.set$b(g);
            p.set$a(r);
          }
        } else if (t1 && order === B.ChannelOrder_3) {
          t1 = _this.data;
          t1.toString;
          p = A.PixelUint8$imageData(t1);
          t1 = p.image;
          t2 = t1.numChannels > 0;
          t1 = t1.data;
          t3 = t1.$flags | 0;
          while (p.moveNext$0()) {
            r = p.get$r();
            g = p.get$g();
            b = p.get$b();
            a = p.get$a();
            if (t2) {
              t4 = p._pixel_uint8$_index;
              t5 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(a, 0, 255));
              t3 & 2 && A.throwUnsupportedOperation(t1);
              if (!(t4 >= 0 && t4 < t1.length))
                return A.ioore(t1, t4);
              t1[t4] = t5;
            }
            p.set$g(r);
            p.set$b(g);
            p.set$a(b);
          }
        } else if (t1 && order === B.ChannelOrder_1) {
          t1 = _this.data;
          t1.toString;
          p = A.PixelUint8$imageData(t1);
          t1 = p.image;
          t2 = t1.numChannels > 0;
          t1 = t1.data;
          t3 = t1.$flags | 0;
          while (p.moveNext$0()) {
            r = p.get$r();
            g = p.get$g();
            b = p.get$b();
            a = p.get$a();
            if (t2) {
              t4 = p._pixel_uint8$_index;
              t5 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(b, 0, 255));
              t3 & 2 && A.throwUnsupportedOperation(t1);
              if (!(t4 >= 0 && t4 < t1.length))
                return A.ioore(t1, t4);
              t1[t4] = t5;
            }
            p.set$g(g);
            p.set$b(r);
            p.set$a(a);
          }
        }
      }
    },
    get$frames() {
      var value = this.__Image_frames_AI;
      return value === $ ? this.__Image_frames_AI = A._setArrayType([], type$.JSArray_Image) : value;
    },
    addFrame$1(image) {
      var _this = this;
      if (image == null)
        image = A.Image$from(_this, true, true);
      image.frameIndex = _this.get$frames().length;
      if (B.JSArray_methods.get$last(_this.get$frames()) !== image)
        B.JSArray_methods.add$1(_this.get$frames(), image);
      return image;
    },
    addFrame$0() {
      return this.addFrame$1(null);
    },
    _image$_initialize$7$exif$iccp$numChannels$palette$withPalette(width, height, exif, iccp, numChannels, palette, withPalette) {
      var t1, _this = this;
      _this.iccProfile = iccp;
      if (exif != null)
        _this._exif = A.ExifData$from(exif);
      t1 = false;
      if (palette == null)
        if (withPalette)
          t1 = _this.get$format() === B.Format_0 || _this.get$format() === B.Format_1 || _this.get$format() === B.Format_2 || _this.get$format() === B.Format_3 || _this.get$format() === B.Format_4;
      if (t1) {
        t1 = _this.get$format() === B.Format_4 ? 65536 : 256;
        palette = new A.PaletteUint8(new Uint8Array(t1 * numChannels), t1, numChannels);
      }
      _this._createImageData$4(width, height, numChannels, palette);
    },
    _createImageData$4(width, height, numChannels, palette) {
      var t1 = width * height;
      if (palette == null)
        this.data = new A.ImageDataUint8(new Uint8Array(t1 * numChannels), null, width, height, numChannels);
      else
        this.data = new A.ImageDataUint8(new Uint8Array(t1), palette, width, height, 1);
    },
    toString$0(_) {
      var _this = this;
      return "Image(" + _this.get$width() + ", " + _this.get$height() + ", " + _this.get$format()._name + ", " + _this.get$numChannels() + ")";
    },
    get$width() {
      var t1 = this.data;
      t1 = t1 == null ? null : t1.width;
      return t1 == null ? 0 : t1;
    },
    get$height() {
      var t1 = this.data;
      t1 = t1 == null ? null : t1.height;
      return t1 == null ? 0 : t1;
    },
    get$format() {
      var t1 = this.data == null ? null : B.Format_3;
      return t1 == null ? B.Format_3 : t1;
    },
    get$exif() {
      var t1 = this._exif;
      return t1 == null ? this._exif = new A.ExifData(A.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.IfdDirectory)) : t1;
    },
    get$iterator(_) {
      var t1 = this.data;
      t1.toString;
      return A.PixelUint8$imageData(t1);
    },
    get$buffer(_) {
      var t1 = this.data;
      t1 = t1 == null ? null : B.NativeUint8List_methods.get$buffer(t1.data);
      if (t1 == null)
        t1 = B.NativeUint8List_methods.get$buffer(new Uint8Array(0));
      return t1;
    },
    get$lengthInBytes(_) {
      var t1 = this.data;
      t1 = t1 == null ? null : J.get$lengthInBytes$x(B.NativeUint8List_methods.get$buffer(t1.data));
      return t1 == null ? 0 : t1;
    },
    get$numChannels() {
      var t1 = this.data,
        t2 = t1 == null,
        t3 = t2 ? null : t1.palette;
      t3 = t3 == null ? null : t3.numChannels;
      if (t3 == null)
        t1 = t2 ? null : t1.numChannels;
      else
        t1 = t3;
      return t1 == null ? 0 : t1;
    },
    get$isHdrFormat() {
      var t1 = this.data == null && null;
      return t1 === true;
    },
    get$hasPalette() {
      var t1 = this.data;
      return (t1 == null ? null : t1.palette) != null;
    },
    get$bitsPerChannel() {
      var t1 = this.data == null ? null : 8;
      return t1 == null ? 0 : t1;
    },
    getPixel$3(x, y, pixel) {
      var t2,
        t1 = this.data;
      if (t1 == null)
        t1 = null;
      else {
        if (pixel == null || !(pixel instanceof A.PixelUint8) || pixel.image !== t1)
          pixel = A.PixelUint8$imageData(t1);
        pixel._x = x;
        pixel._y = y;
        t1 = pixel.image;
        t2 = t1.numChannels;
        pixel._pixel_uint8$_index = y * t1.width * t2 + x * t2;
        t1 = pixel;
      }
      return t1 == null ? new A.PixelUndefined() : t1;
    },
    getPixel$2(x, y) {
      return this.getPixel$3(x, y, null);
    },
    convert$2$numChannels$withPalette(numChannels, withPalette) {
      var alpha, t1, t2, t3, t4, firstFrame, _i, frame, t5, t6, t7, t8, newImage, firstFrame0, pal, f, usedColors, op, pixel, np, c, numColors, nr, ng, nb, h, _this = this, _null = null,
        format = _this.get$format();
      if (numChannels == null)
        numChannels = _this.get$numChannels();
      alpha = B.Map_vw3Ow.$index(0, format);
      t1 = false;
      if (format === _this.get$format())
        if (numChannels === _this.get$numChannels()) {
          if (!withPalette) {
            t2 = _this.data;
            t2 = (t2 == null ? _null : t2.palette) == null;
          } else
            t2 = false;
          if (!t2) {
            if (withPalette) {
              t1 = _this.data;
              t1 = (t1 == null ? _null : t1.palette) != null;
            }
          } else
            t1 = true;
        }
      if (t1)
        return A.Image$from(_this, false, false);
      for (t1 = _this.get$frames(), t2 = t1.length, t3 = type$.String, t4 = type$.int, firstFrame = _null, _i = 0; _i < t1.length; t1.length === t2 || (0, A.throwConcurrentModificationError)(t1), ++_i, firstFrame = firstFrame0) {
        frame = t1[_i];
        t5 = frame.data;
        t6 = t5 == null;
        t7 = t6 ? _null : t5.width;
        if (t7 == null)
          t7 = 0;
        t5 = t6 ? _null : t5.height;
        if (t5 == null)
          t5 = 0;
        t6 = frame._exif;
        t6 = t6 == null ? _null : A.ExifData$from(t6);
        t8 = frame.frameType;
        newImage = A.Image$(_null, t6, frame.frameDuration, t8, t5, _null, frame.loopCount, numChannels, _null, t7, withPalette);
        t5 = frame.textData;
        newImage.set$textData(t5 != null ? A.LinkedHashMap_LinkedHashMap$from(t5, t3, t3) : _null);
        if (firstFrame != null) {
          firstFrame.addFrame$1(newImage);
          firstFrame0 = firstFrame;
        } else
          firstFrame0 = newImage;
        t5 = newImage.data;
        t6 = t5 == null;
        pal = t6 ? _null : t5.palette;
        f = (t6 ? _null : t5.palette) == null ? _null : B.Format_3;
        if (f == null)
          f = format;
        t5 = frame.data;
        if (pal != null) {
          usedColors = A.LinkedHashMap_LinkedHashMap$_empty(t4, t4);
          if (t5 == null)
            op = _null;
          else {
            pixel = new A.PixelUint8(-1, 0, -t5.numChannels, t5);
            pixel.setPosition$2(0, 0);
            op = pixel;
          }
          if (op == null)
            op = new A.PixelUndefined();
          for (t5 = newImage.data, np = new A.PixelUint8(-1, 0, -t5.numChannels, t5), t5 = t5.data, t6 = t5.$flags | 0, c = _null, numColors = 0; np.moveNext$0();) {
            nr = B.JSNumber_methods.floor$0(op.get$rNormalized() * 255);
            ng = B.JSNumber_methods.floor$0(op.get$gNormalized() * 255);
            nb = B.JSNumber_methods.floor$0(op.get$bNormalized() * 255);
            h = (B.JSInt_methods.clamp$2(nr, 0, 255) | B.JSInt_methods.clamp$2(ng, 0, 255) << 8 | B.JSInt_methods.clamp$2(nb, 0, 255) << 16 | B.JSInt_methods.clamp$2(0, 0, 255) << 24) >>> 0;
            if (usedColors.containsKey$1(h)) {
              t7 = usedColors.$index(0, h);
              t7.toString;
              t8 = np._pixel_uint8$_index;
              t7 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(t7, 0, 255));
              t6 & 2 && A.throwUnsupportedOperation(t5);
              if (!(t8 >= 0 && t8 < t5.length))
                return A.ioore(t5, t8);
              t5[t8] = t7;
            } else {
              usedColors.$indexSet(0, h, numColors);
              t7 = np._pixel_uint8$_index;
              t8 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(numColors, 0, 255));
              t6 & 2 && A.throwUnsupportedOperation(t5);
              if (!(t7 >= 0 && t7 < t5.length))
                return A.ioore(t5, t7);
              t5[t7] = t8;
              c = A.convertColor(op, alpha, f, numChannels, c);
              pal.setRgb$4(numColors, c.get$r(), c.get$g(), c.get$b());
              ++numColors;
            }
            op.moveNext$0();
          }
        } else {
          if (t5 == null)
            op = _null;
          else {
            pixel = new A.PixelUint8(-1, 0, -t5.numChannels, t5);
            pixel.setPosition$2(0, 0);
            op = pixel;
          }
          if (op == null)
            op = new A.PixelUndefined();
          for (t5 = newImage.data, np = new A.PixelUint8(-1, 0, -t5.numChannels, t5); np.moveNext$0();) {
            A.convertColor(op, alpha, _null, _null, np);
            op.moveNext$0();
          }
        }
      }
      firstFrame.toString;
      return firstFrame;
    },
    convert$1$numChannels(numChannels) {
      return this.convert$2$numChannels$withPalette(numChannels, false);
    },
    convert$1$withPalette(withPalette) {
      return this.convert$2$numChannels$withPalette(null, withPalette);
    },
    convert$0() {
      return this.convert$2$numChannels$withPalette(null, false);
    },
    set$textData(textData) {
      this.textData = type$.nullable_Map_String_String._as(textData);
    }
  };
  A.ImageData.prototype = {};
  A.ImageDataUint8.prototype = {
    get$iterator(_) {
      return A.PixelUint8$imageData(this);
    },
    get$length(_) {
      return this.data.byteLength;
    },
    get$maxChannelValue() {
      var t1 = this.palette == null ? null : 255;
      return t1 == null ? 255 : t1;
    },
    toString$0(_) {
      return "ImageDataUint8(" + this.width + ", " + this.height + ", " + this.numChannels + ")";
    }
  };
  A.Palette.prototype = {};
  A.PaletteUint32.prototype = {};
  A.PaletteUint8.prototype = {
    get$buffer(_) {
      return B.NativeUint8List_methods.get$buffer(this.data);
    },
    setRgb$4(index, r, g, b) {
      var t2, t3, t4, t5,
        t1 = this.numChannels;
      index *= t1;
      t2 = this.data;
      t3 = B.JSNumber_methods.toInt$0(r);
      t2.$flags & 2 && A.throwUnsupportedOperation(t2);
      t4 = t2.length;
      if (!(index >= 0 && index < t4))
        return A.ioore(t2, index);
      t2[index] = t3;
      if (t1 > 1) {
        t3 = index + 1;
        t5 = B.JSNumber_methods.toInt$0(g);
        if (!(t3 < t4))
          return A.ioore(t2, t3);
        t2[t3] = t5;
        if (t1 > 2) {
          t1 = index + 2;
          t3 = B.JSNumber_methods.toInt$0(b);
          if (!(t1 < t4))
            return A.ioore(t2, t1);
          t2[t1] = t3;
        }
      }
    },
    $get$2(index, channel) {
      var t2,
        t1 = this.numChannels;
      if (channel < t1) {
        t2 = this.data;
        t1 = index * t1 + channel;
        if (!(t1 >= 0 && t1 < t2.length))
          return A.ioore(t2, t1);
        t1 = t2[t1];
      } else
        t1 = 0;
      return t1;
    },
    getRed$1(index) {
      var t1, t2;
      index *= this.numChannels;
      t1 = this.data;
      t2 = t1.length;
      if (index >= t2)
        return 0;
      if (!(index >= 0))
        return A.ioore(t1, index);
      return t1[index];
    },
    getGreen$1(index) {
      var t2, t3,
        t1 = this.numChannels;
      if (t1 < 2)
        return 0;
      index *= t1;
      t1 = this.data;
      t2 = t1.length;
      if (index >= t2)
        return 0;
      t3 = index + 1;
      if (!(t3 >= 0 && t3 < t2))
        return A.ioore(t1, t3);
      return t1[t3];
    },
    getBlue$1(index) {
      var t2, t3,
        t1 = this.numChannels;
      if (t1 < 3)
        return 0;
      index *= t1;
      t1 = this.data;
      t2 = t1.length;
      if (index >= t2)
        return 0;
      t3 = index + 2;
      if (!(t3 >= 0 && t3 < t2))
        return A.ioore(t1, t3);
      return t1[t3];
    },
    getAlpha$1(index) {
      var t2, t3,
        t1 = this.numChannels;
      if (t1 < 4)
        return 255;
      index *= t1;
      t1 = this.data;
      t2 = t1.length;
      if (index >= t2)
        return 0;
      t3 = index + 3;
      if (!(t3 >= 0 && t3 < t2))
        return A.ioore(t1, t3);
      return t1[t3];
    }
  };
  A.Pixel.prototype = {$isIterator: 1};
  A.PixelUint8.prototype = {
    clone$0() {
      var _this = this;
      return new A.PixelUint8(_this._x, _this._y, _this._pixel_uint8$_index, _this.image);
    },
    get$length(_) {
      var t1 = this.image,
        t2 = t1.palette;
      t2 = t2 == null ? null : t2.numChannels;
      return t2 == null ? t1.numChannels : t2;
    },
    get$palette() {
      return this.image.palette;
    },
    get$format() {
      return B.Format_3;
    },
    setPosition$2(x, y) {
      var t1, t2, _this = this;
      _this._x = x;
      _this._y = y;
      t1 = _this.image;
      t2 = t1.numChannels;
      _this._pixel_uint8$_index = y * t1.width * t2 + x * t2;
    },
    get$current() {
      return this;
    },
    moveNext$0() {
      var t2, _this = this,
        t1 = _this.image;
      if (++_this._x === t1.width) {
        _this._x = 0;
        if (++_this._y === t1.height)
          return false;
      }
      t2 = _this._pixel_uint8$_index;
      t2 += t1.palette == null ? t1.numChannels : 1;
      _this._pixel_uint8$_index = t2;
      return t2 < t1.data.length;
    },
    $get$1(ci) {
      var t3,
        t1 = this.image,
        t2 = t1.palette;
      if (t2 != null) {
        t1 = t1.data;
        t3 = this._pixel_uint8$_index;
        if (!(t3 >= 0 && t3 < t1.length))
          return A.ioore(t1, t3);
        t3 = t2.$get$2(t1[t3], ci);
        t1 = t3;
      } else if (ci < t1.numChannels) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index + ci;
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t2 = t1[t2];
        t1 = t2;
      } else
        t1 = 0;
      return t1;
    },
    $index(_, ci) {
      return this.$get$1(ci);
    },
    $indexSet(_, ci, value) {
      var t2, t3,
        t1 = this.image;
      if (ci < t1.numChannels) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index + ci;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(value, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      }
    },
    get$index() {
      var t1 = this.image.data,
        t2 = this._pixel_uint8$_index;
      if (!(t2 >= 0 && t2 < t1.length))
        return A.ioore(t1, t2);
      return t1[t2];
    },
    set$index(i) {
      var t1 = this.image.data,
        t2 = this._pixel_uint8$_index,
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(i, 0, 255));
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (!(t2 >= 0 && t2 < t1.length))
        return A.ioore(t1, t2);
      t1[t2] = t3;
    },
    get$r() {
      var t3,
        t1 = this.image,
        t2 = t1.palette;
      if (t2 == null)
        if (t1.numChannels > 0) {
          t1 = t1.data;
          t2 = this._pixel_uint8$_index;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else
          t1 = 0;
      else {
        t1 = t1.data;
        t3 = this._pixel_uint8$_index;
        if (!(t3 >= 0 && t3 < t1.length))
          return A.ioore(t1, t3);
        t3 = t2.getRed$1(t1[t3]);
        t1 = t3;
      }
      return t1;
    },
    set$r(r) {
      var t2, t3,
        t1 = this.image;
      if (t1.numChannels > 0) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(r, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      }
    },
    get$g() {
      var t3, _this = this,
        t1 = _this.image,
        t2 = t1.palette;
      if (t2 == null) {
        t2 = t1.numChannels;
        if (t2 === 2) {
          t1 = t1.data;
          t2 = _this._pixel_uint8$_index;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else if (t2 > 1) {
          t1 = t1.data;
          t2 = _this._pixel_uint8$_index + 1;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else
          t1 = 0;
      } else {
        t1 = t1.data;
        t3 = _this._pixel_uint8$_index;
        if (!(t3 >= 0 && t3 < t1.length))
          return A.ioore(t1, t3);
        t3 = t2.getGreen$1(t1[t3]);
        t1 = t3;
      }
      return t1;
    },
    set$g(g) {
      var t3,
        t1 = this.image,
        t2 = t1.numChannels;
      if (t2 === 2) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(g, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      } else if (t2 > 1) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index + 1;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(g, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      }
    },
    get$b() {
      var t3, _this = this,
        t1 = _this.image,
        t2 = t1.palette;
      if (t2 == null) {
        t2 = t1.numChannels;
        if (t2 === 2) {
          t1 = t1.data;
          t2 = _this._pixel_uint8$_index;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else if (t2 > 2) {
          t1 = t1.data;
          t2 = _this._pixel_uint8$_index + 2;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else
          t1 = 0;
      } else {
        t1 = t1.data;
        t3 = _this._pixel_uint8$_index;
        if (!(t3 >= 0 && t3 < t1.length))
          return A.ioore(t1, t3);
        t3 = t2.getBlue$1(t1[t3]);
        t1 = t3;
      }
      return t1;
    },
    set$b(b) {
      var t3,
        t1 = this.image,
        t2 = t1.numChannels;
      if (t2 === 2) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(b, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      } else if (t2 > 2) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index + 2;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(b, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      }
    },
    get$a() {
      var t3, _this = this,
        t1 = _this.image,
        t2 = t1.palette;
      if (t2 == null) {
        t2 = t1.numChannels;
        if (t2 === 2) {
          t1 = t1.data;
          t2 = _this._pixel_uint8$_index + 1;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else if (t2 > 3) {
          t1 = t1.data;
          t2 = _this._pixel_uint8$_index + 3;
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t2 = t1[t2];
          t1 = t2;
        } else
          t1 = 255;
      } else {
        t1 = t1.data;
        t3 = _this._pixel_uint8$_index;
        if (!(t3 >= 0 && t3 < t1.length))
          return A.ioore(t1, t3);
        t3 = t2.getAlpha$1(t1[t3]);
        t1 = t3;
      }
      return t1;
    },
    set$a(a) {
      var t3,
        t1 = this.image,
        t2 = t1.numChannels;
      if (t2 === 2) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index + 1;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(a, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      } else if (t2 > 3) {
        t1 = t1.data;
        t2 = this._pixel_uint8$_index + 3;
        t3 = B.JSNumber_methods.toInt$0(B.JSNumber_methods.clamp$2(a, 0, 255));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(t2 >= 0 && t2 < t1.length))
          return A.ioore(t1, t2);
        t1[t2] = t3;
      }
    },
    get$rNormalized() {
      return this.get$r() / this.image.get$maxChannelValue();
    },
    get$gNormalized() {
      return this.get$g() / this.image.get$maxChannelValue();
    },
    get$bNormalized() {
      return this.get$b() / this.image.get$maxChannelValue();
    },
    get$aNormalized() {
      return this.get$a() / this.image.get$maxChannelValue();
    },
    get$luminance() {
      return this.image.numChannels === 2 ? this.get$r() : A.getLuminance(this);
    },
    $set$1(c) {
      var _this = this;
      if (_this.image.palette != null)
        _this.set$index(c.get$index());
      else {
        _this.set$r(c.get$r());
        _this.set$g(c.get$g());
        _this.set$b(c.get$b());
        _this.set$a(c.get$a());
      }
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    $eq(_, other) {
      var t1, t2, nc, _this = this;
      if (other == null)
        return false;
      if (other instanceof A.PixelUint8) {
        t1 = A.List_List$_of(_this, A._instanceType(_this)._eval$1("Iterable.E"));
        t1 = A.Object_hashAll(t1);
        t2 = A.List_List$_of(other, A._instanceType(other)._eval$1("Iterable.E"));
        return t1 === A.Object_hashAll(t2);
      }
      if (type$.List_int._is(other)) {
        t1 = _this.image;
        t2 = t1.palette;
        nc = t2 != null ? t2.numChannels : t1.numChannels;
        t1 = J.getInterceptor$asx(other);
        if (t1.get$length(other) !== nc)
          return false;
        if (_this.$get$1(0) !== t1.$index(other, 0))
          return false;
        if (nc > 1) {
          if (_this.$get$1(1) !== t1.$index(other, 1))
            return false;
          if (nc > 2) {
            if (_this.$get$1(2) !== t1.$index(other, 2))
              return false;
            if (nc > 3)
              if (_this.$get$1(3) !== t1.$index(other, 3))
                return false;
          }
        }
        return true;
      }
      return false;
    },
    get$hashCode(_) {
      var t1 = A.List_List$_of(this, A._instanceType(this)._eval$1("Iterable.E"));
      return A.Object_hashAll(t1);
    },
    convert$1$format(format) {
      return A.convertColor(this, null, format, null, null);
    }
  };
  A.PixelUndefined.prototype = {
    clone$0() {
      return new A.PixelUndefined();
    },
    get$length(_) {
      return 0;
    },
    get$format() {
      return B.Format_3;
    },
    get$palette() {
      return null;
    },
    $index(_, index) {
      return 0;
    },
    $indexSet(_, index, value) {
    },
    get$index() {
      return 0;
    },
    get$r() {
      return 0;
    },
    set$r(r) {
    },
    get$g() {
      return 0;
    },
    set$g(g) {
    },
    get$b() {
      return 0;
    },
    set$b(b) {
    },
    get$a() {
      return 0;
    },
    get$rNormalized() {
      return 0;
    },
    get$gNormalized() {
      return 0;
    },
    get$bNormalized() {
      return 0;
    },
    get$aNormalized() {
      return 0;
    },
    get$luminance() {
      return 0;
    },
    $set$1(c) {
    },
    get$current() {
      return this;
    },
    moveNext$0() {
      return false;
    },
    $eq(_, other) {
      if (other == null)
        return false;
      return other instanceof A.PixelUndefined;
    },
    get$hashCode(_) {
      return 0;
    },
    get$iterator(_) {
      return new A.ChannelIterator(this);
    },
    convert$1$format(format) {
      return this;
    }
  };
  A.ImageException.prototype = {
    toString$0(_) {
      return "ImageException: " + this.message;
    }
  };
  A.NeuralQuantizer.prototype = {
    addImage$1(image) {
      var _this = this;
      _this._learn$1(image);
      _this._fix$0();
      _this._inxBuild$0();
      _this._copyColorMap$0();
    },
    _initialize$1(numberOfColors) {
      var t2, t3, f, i, i0, p, p0, _this = this,
        t1 = _this.netSize = Math.max(numberOfColors, 4);
      _this.__NeuralQuantizer_cutNetSize_A = t1 - _this.specials;
      _this.maxNetPos = t1 - 1;
      t2 = B.JSNumber_methods._tdivFast$1(t1, 8);
      _this.__NeuralQuantizer_initRadius_A = t2;
      _this.__NeuralQuantizer_initBiasRadius_A = t2 * 256;
      _this.__NeuralQuantizer__palette_A = new A.PaletteUint32(new Uint32Array(1024), 256, 4);
      _this.__NeuralQuantizer_palette_A = new A.PaletteUint8(new Uint8Array(768), 256, 3);
      _this.specials = 3;
      _this.__NeuralQuantizer_bgColor_A = 2;
      t2 = B.JSNumber_methods._shrOtherPositive$1(t1, 3);
      _this.__NeuralQuantizer__radiusPower_A = new Int32Array(t2);
      t2 = type$.double;
      t3 = type$.List_double;
      _this.__NeuralQuantizer__network_A = t3._as(A.List_List$filled(t1 * 3, 0, false, t2));
      _this.__NeuralQuantizer__bias_A = t3._as(A.List_List$filled(_this.netSize, 0, false, t2));
      _this.__NeuralQuantizer__freq_A = t3._as(A.List_List$filled(_this.netSize, 0, false, t2));
      B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, 0, 0);
      B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, 1, 0);
      B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, 2, 0);
      B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, 3, 255);
      B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, 4, 255);
      B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, 5, 255);
      f = 1 / _this.netSize;
      for (i = 0; i0 = _this.specials, i < i0; ++i) {
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__freq_A, i, f);
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__bias_A, i, 0);
      }
      for (p = i0 * 3, i = i0; i < _this.netSize; ++i, p = p0) {
        p0 = p + 1;
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, p, 255 * (i - _this.specials) / _this.__NeuralQuantizer_cutNetSize_A);
        p = p0 + 1;
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, p0, 255 * (i - _this.specials) / _this.__NeuralQuantizer_cutNetSize_A);
        p0 = p + 1;
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, p, 255 * (i - _this.specials) / _this.__NeuralQuantizer_cutNetSize_A);
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__freq_A, i, f);
        B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__bias_A, i, 0);
      }
    },
    _copyColorMap$0() {
      var i, t1, t2, t3, t4, t5, t6;
      for (i = 0; i < this.netSize; ++i) {
        t1 = this.__NeuralQuantizer_palette_A;
        t1 === $ && A.throwLateFieldNI("palette");
        t2 = this.__NeuralQuantizer__palette_A;
        t2 === $ && A.throwLateFieldNI("_palette");
        t3 = t2.numChannels;
        if (2 < t3) {
          t4 = t2.data;
          t5 = i * t3 + 2;
          if (!(t5 >= 0 && t5 < t4.length))
            return A.ioore(t4, t5);
          t5 = t4[t5];
          t4 = t5;
        } else
          t4 = 0;
        if (1 < t3) {
          t5 = t2.data;
          t6 = i * t3 + 1;
          if (!(t6 >= 0 && t6 < t5.length))
            return A.ioore(t5, t6);
          t6 = t5[t6];
          t5 = t6;
        } else
          t5 = 0;
        if (0 < t3) {
          t2 = t2.data;
          t3 = i * t3;
          if (!(t3 >= 0 && t3 < t2.length))
            return A.ioore(t2, t3);
          t3 = t2[t3];
          t2 = t3;
        } else
          t2 = 0;
        t1.setRgb$4(i, Math.abs(t4), Math.abs(t5), Math.abs(t2));
      }
    },
    _inxSearch$3(b, g, r) {
      var i, j, i0, bestD, best, t2, t3, t4, dist, a,
        _s8_ = "_palette",
        t1 = this._netIndex;
      if (!(g >= 0 && g < 256))
        return A.ioore(t1, g);
      i = t1[g];
      j = i - 1;
      i0 = this.netSize;
      t1 = this.__NeuralQuantizer__palette_A;
      bestD = 1000;
      best = -1;
      for (;;) {
        t2 = i < i0;
        if (!(t2 || j >= 0))
          break;
        if (t2) {
          t1 === $ && A.throwLateFieldNI(_s8_);
          t2 = t1.numChannels;
          if (1 < t2) {
            t3 = t1.data;
            t4 = i * t2 + 1;
            if (!(t4 >= 0 && t4 < t3.length))
              return A.ioore(t3, t4);
            t4 = t3[t4];
            t3 = t4;
          } else
            t3 = 0;
          dist = t3 - g;
          if (dist >= bestD)
            i = i0;
          else {
            if (dist < 0)
              dist = -dist;
            if (0 < t2) {
              t3 = t1.data;
              t4 = i * t2;
              if (!(t4 >= 0 && t4 < t3.length))
                return A.ioore(t3, t4);
              t4 = t3[t4];
              t3 = t4;
            } else
              t3 = 0;
            a = t3 - b;
            dist += a < 0 ? -a : a;
            if (dist < bestD) {
              if (2 < t2) {
                t3 = t1.data;
                t2 = i * t2 + 2;
                if (!(t2 >= 0 && t2 < t3.length))
                  return A.ioore(t3, t2);
                t2 = t3[t2];
              } else
                t2 = 0;
              a = t2 - r;
              dist += a < 0 ? -a : a;
              if (dist < bestD) {
                best = i;
                bestD = dist;
              }
            }
            ++i;
          }
        }
        if (j >= 0) {
          t1 === $ && A.throwLateFieldNI(_s8_);
          t2 = t1.numChannels;
          if (1 < t2) {
            t3 = t1.data;
            t4 = j * t2 + 1;
            if (!(t4 >= 0 && t4 < t3.length))
              return A.ioore(t3, t4);
            t4 = t3[t4];
            t3 = t4;
          } else
            t3 = 0;
          dist = g - t3;
          if (dist >= bestD)
            j = -1;
          else {
            if (dist < 0)
              dist = -dist;
            if (0 < t2) {
              t3 = t1.data;
              t4 = j * t2;
              if (!(t4 >= 0 && t4 < t3.length))
                return A.ioore(t3, t4);
              t4 = t3[t4];
              t3 = t4;
            } else
              t3 = 0;
            a = t3 - b;
            dist += a < 0 ? -a : a;
            if (dist < bestD) {
              if (2 < t2) {
                t3 = t1.data;
                t2 = j * t2 + 2;
                if (!(t2 >= 0 && t2 < t3.length))
                  return A.ioore(t3, t2);
                t2 = t3[t2];
              } else
                t2 = 0;
              a = t2 - r;
              dist += a < 0 ? -a : a;
              if (dist < bestD) {
                best = j;
                bestD = dist;
              }
            }
            --j;
          }
        }
      }
      return best;
    },
    _fix$0() {
      var i, p, j, t1, x, t2, t3, _this = this,
        _s8_ = "_palette";
      for (i = 0, p = 0; i < _this.netSize; ++i) {
        for (j = 0; j < 3; ++j, ++p) {
          t1 = _this.__NeuralQuantizer__network_A;
          t1 === $ && A.throwLateFieldNI("_network");
          if (!(p >= 0 && p < t1.length))
            return A.ioore(t1, p);
          x = B.JSInt_methods.clamp$2(B.JSNumber_methods.toInt$0(0.5 + t1[p]), 0, 255);
          t1 = _this.__NeuralQuantizer__palette_A;
          t1 === $ && A.throwLateFieldNI(_s8_);
          t2 = t1.numChannels;
          if (j < t2) {
            t1 = t1.data;
            t2 = i * t2 + j;
            t3 = B.JSInt_methods.toInt$0(x);
            t1.$flags & 2 && A.throwUnsupportedOperation(t1);
            if (!(t2 >= 0 && t2 < t1.length))
              return A.ioore(t1, t2);
            t1[t2] = t3;
          }
        }
        t1 = _this.__NeuralQuantizer__palette_A;
        t1 === $ && A.throwLateFieldNI(_s8_);
        t2 = t1.numChannels;
        if (3 < t2) {
          t1 = t1.data;
          t2 = i * t2 + 3;
          t3 = B.JSInt_methods.toInt$0(i);
          t1.$flags & 2 && A.throwUnsupportedOperation(t1);
          if (!(t2 >= 0 && t2 < t1.length))
            return A.ioore(t1, t2);
          t1[t2] = t3;
        }
      }
    },
    _inxBuild$0() {
      var t1, t2, t3, t4, previousColor, startPos, i, t5, t6, t7, t8, smallVal, j, j0, smallPos, t9, index, _this = this;
      for (t1 = _this.netSize, t2 = _this.__NeuralQuantizer__palette_A, t3 = _this._netIndex, t4 = t3.$flags | 0, previousColor = 0, startPos = 0, i = 0; i < t1; i = j) {
        t2 === $ && A.throwLateFieldNI("_palette");
        t5 = t2.numChannels;
        t6 = 1 < t5;
        if (t6) {
          t7 = t2.data;
          t8 = i * t5 + 1;
          if (!(t8 >= 0 && t8 < t7.length))
            return A.ioore(t7, t8);
          smallVal = t7[t8];
        } else
          smallVal = 0;
        for (j = i + 1, j0 = j, smallPos = i; j0 < t1; ++j0) {
          if (t6) {
            t7 = t2.data;
            t8 = j0 * t5 + 1;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            t8 = t7[t8];
            t7 = t8;
          } else
            t7 = 0;
          if (t7 < smallVal) {
            if (t6) {
              t7 = t2.data;
              t8 = j0 * t5 + 1;
              if (!(t8 >= 0 && t8 < t7.length))
                return A.ioore(t7, t8);
              smallVal = t7[t8];
            } else
              smallVal = 0;
            smallPos = j0;
          }
        }
        if (i !== smallPos) {
          t7 = 0 < t5;
          if (t7) {
            t8 = t2.data;
            t9 = smallPos * t5;
            if (!(t9 >= 0 && t9 < t8.length))
              return A.ioore(t8, t9);
            j0 = t8[t9];
          } else
            j0 = 0;
          if (t7) {
            t8 = t2.data;
            t9 = i * t5;
            if (!(t9 >= 0 && t9 < t8.length))
              return A.ioore(t8, t9);
            t9 = t8[t9];
            t8 = t9;
          } else
            t8 = 0;
          if (t7) {
            index = smallPos * t5;
            t9 = t2.data;
            t8 = B.JSInt_methods.toInt$0(t8);
            t9.$flags & 2 && A.throwUnsupportedOperation(t9);
            if (!(index >= 0 && index < t9.length))
              return A.ioore(t9, index);
            t9[index] = t8;
          }
          if (t7) {
            index = i * t5;
            t7 = t2.data;
            t8 = B.JSInt_methods.toInt$0(j0);
            t7.$flags & 2 && A.throwUnsupportedOperation(t7);
            if (!(index >= 0 && index < t7.length))
              return A.ioore(t7, index);
            t7[index] = t8;
          }
          if (t6) {
            t7 = t2.data;
            t8 = smallPos * t5 + 1;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            j0 = t7[t8];
          } else
            j0 = 0;
          if (t6) {
            t7 = t2.data;
            t8 = i * t5 + 1;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            t8 = t7[t8];
            t7 = t8;
          } else
            t7 = 0;
          if (t6) {
            t8 = t2.data;
            t9 = smallPos * t5 + 1;
            t7 = B.JSInt_methods.toInt$0(t7);
            t8.$flags & 2 && A.throwUnsupportedOperation(t8);
            if (!(t9 >= 0 && t9 < t8.length))
              return A.ioore(t8, t9);
            t8[t9] = t7;
          }
          if (t6) {
            t6 = t2.data;
            t7 = i * t5 + 1;
            t8 = B.JSInt_methods.toInt$0(j0);
            t6.$flags & 2 && A.throwUnsupportedOperation(t6);
            if (!(t7 >= 0 && t7 < t6.length))
              return A.ioore(t6, t7);
            t6[t7] = t8;
          }
          t6 = 2 < t5;
          if (t6) {
            t7 = t2.data;
            t8 = smallPos * t5 + 2;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            j0 = t7[t8];
          } else
            j0 = 0;
          if (t6) {
            t7 = t2.data;
            t8 = i * t5 + 2;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            t8 = t7[t8];
            t7 = t8;
          } else
            t7 = 0;
          if (t6) {
            t8 = t2.data;
            t9 = smallPos * t5 + 2;
            t7 = B.JSInt_methods.toInt$0(t7);
            t8.$flags & 2 && A.throwUnsupportedOperation(t8);
            if (!(t9 >= 0 && t9 < t8.length))
              return A.ioore(t8, t9);
            t8[t9] = t7;
          }
          if (t6) {
            t6 = t2.data;
            t7 = i * t5 + 2;
            t8 = B.JSInt_methods.toInt$0(j0);
            t6.$flags & 2 && A.throwUnsupportedOperation(t6);
            if (!(t7 >= 0 && t7 < t6.length))
              return A.ioore(t6, t7);
            t6[t7] = t8;
          }
          t6 = 3 < t5;
          if (t6) {
            t7 = t2.data;
            t8 = smallPos * t5 + 3;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            j0 = t7[t8];
          } else
            j0 = 0;
          if (t6) {
            t7 = t2.data;
            t8 = i * t5 + 3;
            if (!(t8 >= 0 && t8 < t7.length))
              return A.ioore(t7, t8);
            t8 = t7[t8];
            t7 = t8;
          } else
            t7 = 0;
          if (t6) {
            t8 = t2.data;
            t9 = smallPos * t5 + 3;
            t7 = B.JSInt_methods.toInt$0(t7);
            t8.$flags & 2 && A.throwUnsupportedOperation(t8);
            if (!(t9 >= 0 && t9 < t8.length))
              return A.ioore(t8, t9);
            t8[t9] = t7;
          }
          if (t6) {
            t6 = t2.data;
            t5 = i * t5 + 3;
            t7 = B.JSInt_methods.toInt$0(j0);
            t6.$flags & 2 && A.throwUnsupportedOperation(t6);
            if (!(t5 >= 0 && t5 < t6.length))
              return A.ioore(t6, t5);
            t6[t5] = t7;
          }
        }
        if (smallVal !== previousColor) {
          t4 & 2 && A.throwUnsupportedOperation(t3);
          if (!(previousColor >= 0 && previousColor < 256))
            return A.ioore(t3, previousColor);
          t3[previousColor] = startPos + i >>> 1;
          for (j0 = previousColor + 1; j0 < smallVal; ++j0) {
            if (!(j0 < 256))
              return A.ioore(t3, j0);
            t3[j0] = i;
          }
          startPos = i;
          previousColor = smallVal;
        }
      }
      t1 = _this.maxNetPos;
      t1.toString;
      t2 = B.JSInt_methods._shrOtherPositive$1(startPos + t1, 1);
      t4 & 2 && A.throwUnsupportedOperation(t3);
      if (!(previousColor >= 0 && previousColor < 256))
        return A.ioore(t3, previousColor);
      t3[previousColor] = t2;
      for (j = previousColor + 1; j < 256; ++j)
        t3[j] = t1;
    },
    _updateRadiusPower$2(rad, alpha) {
      var t1, t2, i, t3;
      for (t1 = this.__NeuralQuantizer__radiusPower_A, t2 = rad * rad, i = 0; i < rad; ++i) {
        t1 === $ && A.throwLateFieldNI("_radiusPower");
        t3 = B.JSNumber_methods.toInt$0(alpha * ((t2 - i * i) * 256 / t2));
        t1.$flags & 2 && A.throwUnsupportedOperation(t1);
        if (!(i < t1.length))
          return A.ioore(t1, i);
        t1[i] = t3;
      }
    },
    _learn$1(image) {
      var t2, alphaDec, lengthCount, samplePixels, delta, rad, step, w, h, biasRadius, alpha, pos, x, y, i, p, pixel, red, green, blue, j, a, t3, _this = this,
        _s8_ = "_network",
        t1 = _this.__NeuralQuantizer_initBiasRadius_A;
      t1 === $ && A.throwLateFieldNI("initBiasRadius");
      t2 = _this.samplingFactor;
      alphaDec = 30 + B.JSInt_methods._tdivFast$1(t2 - 1, 3);
      lengthCount = image.get$width() * image.get$height();
      samplePixels = B.JSInt_methods.$tdiv(lengthCount, t2);
      delta = Math.max(B.JSInt_methods._tdivFast$1(samplePixels, 100), 1);
      if (delta === 0)
        delta = 1;
      rad = B.JSInt_methods._shrOtherPositive$1(t1, 8);
      if (rad <= 1)
        rad = 0;
      _this._updateRadiusPower$2(rad, 1024);
      if (lengthCount < 1509)
        step = _this.samplingFactor = 1;
      else if (B.JSInt_methods.$mod(lengthCount, 499) !== 0)
        step = 499;
      else if (B.JSInt_methods.$mod(lengthCount, 491) !== 0)
        step = 491;
      else
        step = B.JSInt_methods.$mod(lengthCount, 487) !== 0 ? 487 : 503;
      w = image.get$width();
      h = image.get$height();
      for (biasRadius = t1, alpha = 1024, pos = 0, x = 0, y = 0, i = 0; i < samplePixels;) {
        t1 = image.data;
        if (t1 == null)
          p = null;
        else {
          pixel = new A.PixelUint8(-1, 0, -t1.numChannels, t1);
          pixel.setPosition$2(x, y);
          p = pixel;
        }
        if (p == null)
          p = new A.PixelUndefined();
        red = p.get$r();
        green = p.get$g();
        blue = p.get$b();
        if (i === 0) {
          t1 = _this.__NeuralQuantizer__network_A;
          t1 === $ && A.throwLateFieldNI(_s8_);
          t2 = _this.__NeuralQuantizer_bgColor_A;
          t2 === $ && A.throwLateFieldNI("bgColor");
          B.JSArray_methods.$indexSet(t1, t2 * 3, blue);
          B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, _this.__NeuralQuantizer_bgColor_A * 3 + 1, green);
          B.JSArray_methods.$indexSet(_this.__NeuralQuantizer__network_A, _this.__NeuralQuantizer_bgColor_A * 3 + 2, red);
        }
        j = _this._specialFind$3(blue, green, red);
        if (j < 0)
          j = _this._contest$3(blue, green, red);
        if (j >= _this.specials) {
          a = alpha / 1024;
          p = j * 3;
          t1 = _this.__NeuralQuantizer__network_A;
          t1 === $ && A.throwLateFieldNI(_s8_);
          if (!(p >= 0 && p < t1.length))
            return A.ioore(t1, p);
          t2 = t1[p];
          B.JSArray_methods.$indexSet(t1, p, t2 - a * (t2 - blue));
          t2 = _this.__NeuralQuantizer__network_A;
          t1 = p + 1;
          if (!(t1 < t2.length))
            return A.ioore(t2, t1);
          t3 = t2[t1];
          B.JSArray_methods.$indexSet(t2, t1, t3 - a * (t3 - green));
          t3 = _this.__NeuralQuantizer__network_A;
          t1 = p + 2;
          if (!(t1 < t3.length))
            return A.ioore(t3, t1);
          t2 = t3[t1];
          B.JSArray_methods.$indexSet(t3, t1, t2 - a * (t2 - red));
          if (rad > 0)
            _this._alterNeighbors$6(a, rad, j, blue, green, red);
        }
        pos += step;
        x += step;
        while (x > w) {
          x -= w;
          ++y;
        }
        while (pos >= lengthCount) {
          pos -= lengthCount;
          y -= h;
        }
        ++i;
        if (B.JSInt_methods.$mod(i, delta) === 0) {
          alpha -= B.JSInt_methods.$tdiv(alpha, alphaDec);
          biasRadius -= B.JSInt_methods._tdivFast$1(biasRadius, 30);
          rad = B.JSInt_methods._shrOtherPositive$1(biasRadius, 8);
          if (rad <= 1)
            rad = 0;
          _this._updateRadiusPower$2(rad, alpha);
        }
      }
    },
    _alterNeighbors$6(alpha, rad, i, b, g, r) {
      var hi, hi0, j, k, m, t1, t2, m0, a, p, t3, _this = this,
        _s8_ = "_network",
        lo = i - rad,
        lo0 = _this.specials - 1;
      if (lo < lo0)
        lo = lo0;
      hi = i + rad;
      hi0 = _this.netSize;
      if (hi > hi0)
        hi = hi0;
      j = i + 1;
      k = i - 1;
      m = 1;
      for (;;) {
        t1 = j < hi;
        if (!(t1 || k > lo))
          break;
        t2 = _this.__NeuralQuantizer__radiusPower_A;
        t2 === $ && A.throwLateFieldNI("_radiusPower");
        m0 = m + 1;
        if (!(m < t2.length))
          return A.ioore(t2, m);
        a = t2[m];
        if (t1) {
          p = j * 3;
          t1 = _this.__NeuralQuantizer__network_A;
          t1 === $ && A.throwLateFieldNI(_s8_);
          if (!(p >= 0 && p < t1.length))
            return A.ioore(t1, p);
          t2 = t1[p];
          B.JSArray_methods.$indexSet(t1, p, t2 - a * (t2 - b) / 262144);
          t2 = _this.__NeuralQuantizer__network_A;
          t1 = p + 1;
          if (!(t1 < t2.length))
            return A.ioore(t2, t1);
          t3 = t2[t1];
          B.JSArray_methods.$indexSet(t2, t1, t3 - a * (t3 - g) / 262144);
          t3 = _this.__NeuralQuantizer__network_A;
          t1 = p + 2;
          if (!(t1 < t3.length))
            return A.ioore(t3, t1);
          t2 = t3[t1];
          B.JSArray_methods.$indexSet(t3, t1, t2 - a * (t2 - r) / 262144);
          ++j;
        }
        if (k > lo) {
          p = k * 3;
          t1 = _this.__NeuralQuantizer__network_A;
          t1 === $ && A.throwLateFieldNI(_s8_);
          if (!(p >= 0 && p < t1.length))
            return A.ioore(t1, p);
          t2 = t1[p];
          B.JSArray_methods.$indexSet(t1, p, t2 - a * (t2 - b) / 262144);
          t2 = _this.__NeuralQuantizer__network_A;
          t1 = p + 1;
          if (!(t1 < t2.length))
            return A.ioore(t2, t1);
          t3 = t2[t1];
          B.JSArray_methods.$indexSet(t2, t1, t3 - a * (t3 - g) / 262144);
          t3 = _this.__NeuralQuantizer__network_A;
          t1 = p + 2;
          if (!(t1 < t3.length))
            return A.ioore(t3, t1);
          t2 = t3[t1];
          B.JSArray_methods.$indexSet(t3, t1, t2 - a * (t2 - r) / 262144);
          --k;
        }
        m = m0;
      }
    },
    _contest$3(b, g, r) {
      var i, p, bestBiasDist, bestD, bestPos, bestBiasPos, t1, p0, t2, dist, a, a0, biasDist, t3, _this = this, _1000000000000000019884624838656 = 1e30;
      for (i = _this.specials, p = i * 3, bestBiasDist = _1000000000000000019884624838656, bestD = bestBiasDist, bestPos = -1, bestBiasPos = -1; i < _this.netSize; ++i, p = p0) {
        t1 = _this.__NeuralQuantizer__network_A;
        t1 === $ && A.throwLateFieldNI("_network");
        p0 = p + 1;
        t2 = t1.length;
        if (!(p < t2))
          return A.ioore(t1, p);
        dist = t1[p] - b;
        if (dist < 0)
          dist = -dist;
        p = p0 + 1;
        if (!(p0 < t2))
          return A.ioore(t1, p0);
        a = t1[p0] - g;
        if (a < 0)
          a = -a;
        p0 = p + 1;
        if (!(p < t2))
          return A.ioore(t1, p);
        a0 = t1[p] - r;
        if (a0 < 0)
          a0 = -a0;
        dist = dist + a + a0;
        if (dist < bestD) {
          bestPos = i;
          bestD = dist;
        }
        t1 = _this.__NeuralQuantizer__bias_A;
        t1 === $ && A.throwLateFieldNI("_bias");
        if (!(i < t1.length))
          return A.ioore(t1, i);
        biasDist = dist - t1[i];
        if (biasDist < bestBiasDist) {
          bestBiasPos = i;
          bestBiasDist = biasDist;
        }
        t1 = _this.__NeuralQuantizer__freq_A;
        t1 === $ && A.throwLateFieldNI("_freq");
        if (!(i < t1.length))
          return A.ioore(t1, i);
        t2 = t1[i];
        B.JSArray_methods.$indexSet(t1, i, t2 - 0.0009765625 * t2);
        t2 = _this.__NeuralQuantizer__bias_A;
        if (!(i < t2.length))
          return A.ioore(t2, i);
        t1 = t2[i];
        t3 = _this.__NeuralQuantizer__freq_A;
        if (!(i < t3.length))
          return A.ioore(t3, i);
        B.JSArray_methods.$indexSet(t2, i, t1 + t3[i]);
      }
      t1 = _this.__NeuralQuantizer__freq_A;
      t1 === $ && A.throwLateFieldNI("_freq");
      if (!(bestPos >= 0 && bestPos < t1.length))
        return A.ioore(t1, bestPos);
      B.JSArray_methods.$indexSet(t1, bestPos, t1[bestPos] + 0.0009765625);
      t1 = _this.__NeuralQuantizer__bias_A;
      t1 === $ && A.throwLateFieldNI("_bias");
      if (!(bestPos < t1.length))
        return A.ioore(t1, bestPos);
      B.JSArray_methods.$indexSet(t1, bestPos, t1[bestPos] - 1);
      return bestBiasPos;
    },
    _specialFind$3(b, g, r) {
      var t1, t2, i, p, p0, t3, t4;
      for (t1 = this.specials, t2 = this.__NeuralQuantizer__network_A, i = 0, p = 0; i < t1; ++i) {
        t2 === $ && A.throwLateFieldNI("_network");
        p0 = p + 1;
        t3 = t2.length;
        if (!(p < t3))
          return A.ioore(t2, p);
        t4 = false;
        if (t2[p] === b) {
          p = p0 + 1;
          if (!(p0 < t3))
            return A.ioore(t2, p0);
          if (t2[p0] === g) {
            p0 = p + 1;
            if (!(p < t3))
              return A.ioore(t2, p);
            t3 = t2[p] === r;
            p = p0;
          } else
            t3 = t4;
        } else {
          t3 = t4;
          p = p0;
        }
        if (t3)
          return i;
      }
      return -1;
    }
  };
  A.OutputBuffer.prototype = {
    writeByte$1(value) {
      var t1, t2, _this = this;
      if (_this.length === _this._buffer.length)
        _this._expandBuffer$0();
      t1 = _this._buffer;
      t2 = _this.length++;
      t1.$flags & 2 && A.throwUnsupportedOperation(t1);
      if (!(t2 >= 0 && t2 < t1.length))
        return A.ioore(t1, t2);
      t1[t2] = value & 255;
    },
    writeBytes$1(bytes) {
      var len, t1, t2, t3, t4, _this = this;
      type$.List_int._as(bytes);
      len = J.get$length$asx(bytes);
      while (t1 = _this.length, t2 = t1 + len, t3 = _this._buffer, t4 = t3.length, t2 > t4)
        _this._expandBuffer$1(t2 - t4);
      B.NativeUint8List_methods.setRange$3(t3, t1, t2, bytes);
      _this.length += len;
    },
    writeUint16$1(value) {
      var _this = this;
      if (_this.bigEndian) {
        _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 8) & 255);
        _this.writeByte$1(value & 255);
        return;
      }
      _this.writeByte$1(value & 255);
      _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 8) & 255);
    },
    writeUint32$1(value) {
      var _this = this;
      if (_this.bigEndian) {
        _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 24) & 255);
        _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 16) & 255);
        _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 8) & 255);
        _this.writeByte$1(value & 255);
        return;
      }
      _this.writeByte$1(value & 255);
      _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 8) & 255);
      _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 16) & 255);
      _this.writeByte$1(B.JSInt_methods._shrOtherPositive$1(value, 24) & 255);
    },
    writeFloat32$1(value) {
      var b, t1, _this = this,
        fb = new Float32Array(1);
      fb[0] = value;
      b = J.asUint8List$2$x(B.NativeFloat32List_methods.get$buffer(fb), 0, null);
      if (_this.bigEndian) {
        if (3 >= b.length)
          return A.ioore(b, 3);
        _this.writeByte$1(b[3]);
        _this.writeByte$1(b[2]);
        _this.writeByte$1(b[1]);
        _this.writeByte$1(b[0]);
        return;
      }
      t1 = b.length;
      if (0 >= t1)
        return A.ioore(b, 0);
      _this.writeByte$1(b[0]);
      if (1 >= t1)
        return A.ioore(b, 1);
      _this.writeByte$1(b[1]);
      if (2 >= t1)
        return A.ioore(b, 2);
      _this.writeByte$1(b[2]);
      if (3 >= t1)
        return A.ioore(b, 3);
      _this.writeByte$1(b[3]);
    },
    writeFloat64$1(value) {
      var b, t1, _this = this,
        fb = new Float64Array(1);
      fb[0] = value;
      b = J.asUint8List$2$x(B.NativeFloat64List_methods.get$buffer(fb), 0, null);
      if (_this.bigEndian) {
        if (7 >= b.length)
          return A.ioore(b, 7);
        _this.writeByte$1(b[7]);
        _this.writeByte$1(b[6]);
        _this.writeByte$1(b[5]);
        _this.writeByte$1(b[4]);
        _this.writeByte$1(b[3]);
        _this.writeByte$1(b[2]);
        _this.writeByte$1(b[1]);
        _this.writeByte$1(b[0]);
        return;
      }
      t1 = b.length;
      if (0 >= t1)
        return A.ioore(b, 0);
      _this.writeByte$1(b[0]);
      if (1 >= t1)
        return A.ioore(b, 1);
      _this.writeByte$1(b[1]);
      if (2 >= t1)
        return A.ioore(b, 2);
      _this.writeByte$1(b[2]);
      if (3 >= t1)
        return A.ioore(b, 3);
      _this.writeByte$1(b[3]);
      if (4 >= t1)
        return A.ioore(b, 4);
      _this.writeByte$1(b[4]);
      if (5 >= t1)
        return A.ioore(b, 5);
      _this.writeByte$1(b[5]);
      if (6 >= t1)
        return A.ioore(b, 6);
      _this.writeByte$1(b[6]);
      if (7 >= t1)
        return A.ioore(b, 7);
      _this.writeByte$1(b[7]);
    },
    _expandBuffer$1(required) {
      var blockSize, t1, t2, newBuffer;
      if (required != null)
        blockSize = required;
      else {
        t1 = this._buffer.length;
        blockSize = t1 === 0 ? 8192 : t1 * 2;
      }
      t1 = this._buffer;
      t2 = t1.length;
      newBuffer = new Uint8Array(t2 + blockSize);
      B.NativeUint8List_methods.setRange$3(newBuffer, 0, t2, t1);
      this._buffer = newBuffer;
    },
    _expandBuffer$0() {
      return this._expandBuffer$1(null);
    },
    get$length(receiver) {
      return this.length;
    }
  };
  A.Quantizer.prototype = {
    getIndexImage$1(image) {
      var target, ti, p, r, g, t4, t5,
        t1 = image.get$width(),
        t2 = image.get$height(),
        t3 = this.__NeuralQuantizer_palette_A;
      t3 === $ && A.throwLateFieldNI("palette");
      target = A.Image$(null, null, 0, B.FrameType_2, t2, null, 0, 1, t3, t1, false);
      t1 = target.data;
      t1.toString;
      ti = A.PixelUint8$imageData(t1);
      ti.moveNext$0();
      target.frameIndex = image.frameIndex;
      target.frameType = image.frameType;
      target.frameDuration = image.frameDuration;
      t1 = image.data;
      t1.toString;
      p = A.PixelUint8$imageData(t1);
      t1 = ti.image;
      t2 = 0 < t1.numChannels;
      t1 = t1.data;
      t3 = t1.$flags | 0;
      while (p.moveNext$0()) {
        r = B.JSInt_methods.toInt$0(p.get$r());
        g = B.JSInt_methods.toInt$0(p.get$g());
        t4 = this._inxSearch$3(B.JSInt_methods.toInt$0(p.get$b()), g, r);
        if (t2) {
          t5 = ti._pixel_uint8$_index;
          t4 = B.JSNumber_methods.toInt$0(B.JSInt_methods.clamp$2(t4, 0, 255));
          t3 & 2 && A.throwUnsupportedOperation(t1);
          if (!(t5 >= 0 && t5 < t1.length))
            return A.ioore(t1, t5);
          t1[t5] = t4;
        }
        ti.moveNext$0();
      }
      return target;
    }
  };
  A.Rational.prototype = {
    $eq(_, other) {
      if (other == null)
        return false;
      return other instanceof A.Rational && this.numerator === other.numerator && this.denominator === other.denominator;
    },
    get$hashCode(_) {
      return A.Object_hash(this.numerator, this.denominator);
    },
    toString$0(_) {
      return "" + this.numerator + "/" + this.denominator;
    }
  };
  A._BoundingBox.prototype = {};
  A.jsify_closure.prototype = {
    call$2(key, value) {
      return new A.MapEntry(A.jsify(key), A.jsify(value), type$.MapEntry_of_nullable_Object_and_nullable_Object);
    },
    $signature: 33
  };
  A.WebWorkerManager.prototype = {
    _init$0() {
      var result,
        t1 = A._asJSObject(init.G.self),
        t2 = new A.WebWorkerManager__init_closure(this);
      if (typeof t2 == "function")
        A.throwExpression(A.ArgumentError$("Attempting to rewrap a JS function.", null));
      result = function(_call, f) {
        return function(arg1) {
          return _call(f, arg1, arguments.length);
        };
      }(A._callDartFunctionFast1, t2);
      result[$.$get$DART_CLOSURE_PROPERTY_NAME()] = t2;
      t1.onmessage = result;
    },
    _handleConvert$1(data) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.void),
        $async$self = this, t1, action, t2, result, id, destroy$;
      var $async$_handleConvert$1 = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              id = data.id;
              destroy$ = new A._AsyncCompleter(new A._Future($.Zone__current, type$._Future_dynamic), type$._AsyncCompleter_dynamic);
              $async$self.tasks.$indexSet(0, id, destroy$);
              t1 = A.convertRawImage(new A.ImageConvertThreadRequest(id, data.image, data.outputFormat, data.singleFrame, data.pngLevel, data.pngFilter, data.jpegQuality, data.jpegBackgroundColor, data.jpegChroma, data.generateOnlyImageBounds), destroy$).then$1$1(new A.WebWorkerManager__handleConvert_closure(), type$.Null);
              action = type$.dynamic_Function._as(new A.WebWorkerManager__handleConvert_closure0($async$self, id));
              t2 = t1.$ti;
              result = new A._Future($.Zone__current, t2);
              t1._addListener$1(new A._FutureListener(result, 8, action, null, t2._eval$1("_FutureListener<1,1>")));
              $async$goto = 2;
              return A._asyncAwait(result, $async$_handleConvert$1);
            case 2:
              // returning from await.
              // implicit return
              return A._asyncReturn(null, $async$completer);
          }
      });
      return A._asyncStartSync($async$_handleConvert$1, $async$completer);
    },
    _handleEncode$1(data) {
      var $async$goto = 0,
        $async$completer = A._makeAsyncAwaitCompleter(type$.void),
        bytes;
      var $async$_handleEncode$1 = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
        if ($async$errorCode === 1)
          return A._asyncRethrow($async$result, $async$completer);
        for (;;)
          switch ($async$goto) {
            case 0:
              // Function start
              $async$goto = 2;
              return A._asyncAwait(A.encodeImage(null, data.image, data.jpegBackgroundColor, data.jpegChroma, data.jpegQuality, data.outputFormat, data.pngFilter, data.pngLevel, data.singleFrame), $async$_handleEncode$1);
            case 2:
              // returning from await.
              bytes = $async$result;
              A._asJSObject(init.G.self).postMessage(A.jsify(A.LinkedHashMap_LinkedHashMap$_literal(["bytes", bytes, "id", data.id], type$.String, type$.Object)));
              // implicit return
              return A._asyncReturn(null, $async$completer);
          }
      });
      return A._asyncStartSync($async$_handleEncode$1, $async$completer);
    },
    _handleDestroyActiveTasks$1(ignoreTaskId) {
      this.tasks.forEach$1(0, new A.WebWorkerManager__handleDestroyActiveTasks_closure(ignoreTaskId));
    }
  };
  A.WebWorkerManager__init_closure.prototype = {
    call$1($event) {
      A._asJSObject($event);
      switch (A._asString(A.jsGetProperty(A._asJSObject($event.data), "mode"))) {
        case "convert":
          this.$this._handleConvert$1(A.ThreadWebRequest_ThreadWebRequest$fromJs($event.data));
          break;
        case "encode":
          this.$this._handleEncode$1(A.ThreadWebRequest_ThreadWebRequest$fromJs($event.data));
          break;
        case "destroyActiveTasks":
          this.$this._handleDestroyActiveTasks$1(A._asString(A.jsGetProperty(A._asJSObject($event.data), "ignoreTaskId")));
          break;
        case "kill":
          A._asJSObject(init.G.self).close();
          break;
        default:
          break;
      }
    },
    $signature: 34
  };
  A.WebWorkerManager__handleConvert_closure.prototype = {
    call$1(res) {
      type$.ThreadResponse._as(res);
      A._asJSObject(init.G.self).postMessage(A.jsify(A.LinkedHashMap_LinkedHashMap$_literal(["bytes", res.bytes, "id", res.id], type$.String, type$.nullable_Object)));
    },
    $signature: 35
  };
  A.WebWorkerManager__handleConvert_closure0.prototype = {
    call$0() {
      var t1 = this.$this.tasks,
        t2 = this.id,
        t3 = t1.$index(0, t2);
      if ((t3 == null ? null : (t3.future._state & 30) !== 0) !== true) {
        t3 = t1.$index(0, t2);
        if (t3 != null)
          t3.complete$1(null);
      }
      t1.remove$1(0, t2);
    },
    $signature: 1
  };
  A.WebWorkerManager__handleDestroyActiveTasks_closure.prototype = {
    call$2(key, value) {
      A._asString(key);
      type$.Completer_void._as(value);
      if (key !== this.ignoreTaskId)
        if (!value.get$isCompleted())
          value.complete$0();
    },
    $signature: 36
  };
  (function aliases() {
    var _ = J.LegacyJavaScriptObject.prototype;
    _.super$LegacyJavaScriptObject$toString = _.toString$0;
    _ = A.ListBase.prototype;
    _.super$ListBase$setRange = _.setRange$4;
  })();
  (function installTearOffs() {
    var _static_1 = hunkHelpers._static_1,
      _static_0 = hunkHelpers._static_0;
    _static_1(A, "async__AsyncRun__scheduleImmediateJsOverride$closure", "_AsyncRun__scheduleImmediateJsOverride", 4);
    _static_1(A, "async__AsyncRun__scheduleImmediateWithSetImmediate$closure", "_AsyncRun__scheduleImmediateWithSetImmediate", 4);
    _static_1(A, "async__AsyncRun__scheduleImmediateWithTimer$closure", "_AsyncRun__scheduleImmediateWithTimer", 4);
    _static_0(A, "async___startMicrotaskLoop$closure", "_startMicrotaskLoop", 0);
    _static_1(A, "web_worker_utils__jsify$closure", "jsify", 3);
  })();
  (function inheritance() {
    var _mixin = hunkHelpers.mixin,
      _inherit = hunkHelpers.inherit,
      _inheritMany = hunkHelpers.inheritMany;
    _inherit(A.Object, null);
    _inheritMany(A.Object, [A.JS_CONST, J.Interceptor, A.SafeToStringHook, J.ArrayIterator, A.Error, A.ListBase, A.SentinelValue, A.Iterable, A.ListIterator, A.MappedIterator, A.FixedLengthListMixin, A.UnmodifiableListMixin, A.ConstantMap, A.Closure, A._KeysOrValuesOrElementsIterator, A.TypeErrorDecoder, A.NullThrownFromJavaScriptException, A.ExceptionAndStackTrace, A._StackTrace, A.MapBase, A.LinkedHashMapCell, A.LinkedHashMapKeyIterator, A.LinkedHashMapValueIterator, A._Cell, A._UnmodifiableNativeByteBufferView, A.Rti, A._FunctionParameters, A._Type, A._TimerImpl, A._AsyncAwaitCompleter, A.AsyncError, A._Completer, A._FutureListener, A._Future, A._AsyncCallbackEntry, A._StreamIterator, A._Zone, A._HashMapKeyIterator, A.Converter, A.DateTime, A.Duration, A._Enum, A.OutOfMemoryError, A.StackOverflowError, A._Exception, A.MapEntry, A.Null, A._StringStackTrace, A.StringBuffer, A.NullRejectionException, A.ThreadRequest, A.ThreadResponse, A.ZLibEncoderBase, A.Deflate, A._DeflaterConfig, A._HuffmanTree, A._StaticTree, A.InputStream, A.OutputStream, A.ChannelIterator, A.IfdContainer, A.ExifTag, A.IfdDirectory, A.IfdValue, A.Encoder, A.JpegHealthyEncoder, A.PvrColorRgbCore, A.PvrColorBoundingBox, A.PvrPacket, A.Palette, A.ImageException, A.Quantizer, A.OutputBuffer, A.Rational, A._BoundingBox, A.WebWorkerManager]);
    _inheritMany(J.Interceptor, [J.JSBool, J.JSNull, J.JavaScriptObject, J.JavaScriptBigInt, J.JavaScriptSymbol, J.JSNumber, J.JSString]);
    _inheritMany(J.JavaScriptObject, [J.LegacyJavaScriptObject, J.JSArray, A.NativeByteBuffer, A.NativeTypedData]);
    _inheritMany(J.LegacyJavaScriptObject, [J.PlainJavaScriptObject, J.UnknownJavaScriptObject, J.JavaScriptFunction]);
    _inherit(J.JSArraySafeToStringHook, A.SafeToStringHook);
    _inherit(J.JSUnmodifiableArray, J.JSArray);
    _inheritMany(J.JSNumber, [J.JSInt, J.JSNumNotInt]);
    _inheritMany(A.Error, [A.LateError, A.TypeError, A.JsNoSuchMethodError, A.UnknownJsTypeError, A.RuntimeError, A._Error, A.AssertionError, A.ArgumentError, A.UnsupportedError, A.UnimplementedError, A.StateError, A.ConcurrentModificationError]);
    _inherit(A.UnmodifiableListBase, A.ListBase);
    _inherit(A.CodeUnits, A.UnmodifiableListBase);
    _inheritMany(A.Iterable, [A.EfficientLengthIterable, A.MappedIterable, A._KeysOrValues, A.Color, A.Image, A.ImageData]);
    _inheritMany(A.EfficientLengthIterable, [A.ListIterable, A.LinkedHashMapKeysIterable, A.LinkedHashMapValuesIterable, A._HashMapKeyIterable]);
    _inherit(A.EfficientLengthMappedIterable, A.MappedIterable);
    _inherit(A.MappedListIterable, A.ListIterable);
    _inheritMany(A.Closure, [A.Closure2Args, A.Closure0Args, A.TearOffClosure, A.initHooks_closure, A.initHooks_closure1, A._AsyncRun__initializeScheduleImmediate_internalCallback, A._AsyncRun__initializeScheduleImmediate_closure, A._awaitOnObject_closure, A._Future__propagateToListeners_handleWhenCompleteCallback_closure, A.jsify__convert, A.promiseToFuture_closure, A.promiseToFuture_closure0, A.dartify_convert, A.ThreadWebRequest_ThreadWebRequest$fromJs_convertString, A.ThreadWebRequest_ThreadWebRequest$fromJs_convertInteger, A.ThreadWebRequest_ThreadWebRequest$fromJs_convertBool, A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage, A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure, A.ThreadWebRequest_ThreadWebRequest$fromJs_parseImage_closure0, A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma, A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpegChroma_closure, A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter, A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngFilter_closure, A.ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat, A.ThreadWebRequest_ThreadWebRequest$fromJs_getOutputFormat_closure, A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpgBackgroundColor, A.ThreadWebRequest_ThreadWebRequest$fromJs_getJpgQuality, A.ThreadWebRequest_ThreadWebRequest$fromJs_getPngLevel, A.ThreadWebRequest_ThreadWebRequest$fromJs_getSingleFrame, A.WebWorkerManager__init_closure, A.WebWorkerManager__handleConvert_closure]);
    _inheritMany(A.Closure2Args, [A.ConstantMap_map_closure, A.initHooks_closure0, A._awaitOnObject_closure0, A._wrapJsFunctionForAsync_closure, A._Future__propagateToListeners_handleWhenCompleteCallback_closure0, A.LinkedHashMap_LinkedHashMap$from_closure, A.MapBase_mapToString_closure, A.IfdContainer$from_closure, A.IfdDirectory_copy_closure, A.IfdDirectory_copy_closure0, A.PvrEncoder__calculateBoundingBoxRgb_pixel, A.PvrEncoder__calculateBoundingBoxRgba_pixel, A.jsify_closure, A.WebWorkerManager__handleDestroyActiveTasks_closure]);
    _inheritMany(A.ConstantMap, [A.ConstantStringMap, A.GeneralConstantMap]);
    _inherit(A.NullError, A.TypeError);
    _inheritMany(A.TearOffClosure, [A.StaticClosure, A.BoundClosure]);
    _inheritMany(A.MapBase, [A.JsLinkedHashMap, A._HashMap]);
    _inherit(A.JsConstantLinkedHashMap, A.JsLinkedHashMap);
    _inherit(A.NativeArrayBuffer, A.NativeByteBuffer);
    _inheritMany(A.NativeTypedData, [A.NativeByteData, A.NativeTypedArray]);
    _inheritMany(A.NativeTypedArray, [A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin]);
    _inherit(A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin);
    _inherit(A.NativeTypedArrayOfDouble, A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin);
    _inherit(A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin, A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin);
    _inherit(A.NativeTypedArrayOfInt, A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin);
    _inheritMany(A.NativeTypedArrayOfDouble, [A.NativeFloat32List, A.NativeFloat64List]);
    _inheritMany(A.NativeTypedArrayOfInt, [A.NativeInt16List, A.NativeInt32List, A.NativeInt8List, A.NativeUint16List, A.NativeUint32List, A.NativeUint8ClampedList, A.NativeUint8List]);
    _inherit(A._TypeError, A._Error);
    _inheritMany(A.Closure0Args, [A._AsyncRun__scheduleImmediateJsOverride_internalCallback, A._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback, A._TimerImpl_internalCallback, A.Future_Future$delayed_closure, A._Future__addListener_closure, A._Future__prependListeners_closure, A._Future__chainCoreFuture_closure, A._Future__asyncCompleteWithValue_closure, A._Future__asyncCompleteErrorObject_closure, A._Future__propagateToListeners_handleWhenCompleteCallback, A._Future__propagateToListeners_handleValueCallback, A._Future__propagateToListeners_handleError, A._rootHandleError_closure, A._RootZone_bindCallbackGuarded_closure, A.JpegHealthyEncoder_encode_healthCheck, A.WebWorkerManager__handleConvert_closure0]);
    _inherit(A._AsyncCompleter, A._Completer);
    _inherit(A._RootZone, A._Zone);
    _inherit(A._IdentityHashMap, A._HashMap);
    _inherit(A._UnicodeSubsetEncoder, A.Converter);
    _inherit(A.Latin1Encoder, A._UnicodeSubsetEncoder);
    _inheritMany(A.ArgumentError, [A.RangeError, A.IndexError]);
    _inheritMany(A._Enum, [A.OutputFormat, A._DeflateFlushMode, A.ByteOrder, A.ChannelOrder, A.Format, A.FormatType, A.IfdValueType, A.BmpCompression, A.JpegChroma, A.PngFilter, A.PvrFormat, A.TiffFormat, A.FrameType]);
    _inheritMany(A.ThreadRequest, [A.ImageConvertThreadRequest, A.ThreadWebRequest]);
    _inherit(A._ZLibEncoder, A.ZLibEncoderBase);
    _inherit(A.InputMemoryStream, A.InputStream);
    _inherit(A.OutputMemoryStream, A.OutputStream);
    _inheritMany(A.Color, [A.ColorFloat16, A.ColorFloat32, A.ColorFloat64, A.ColorInt16, A.ColorInt32, A.ColorInt8, A.ColorUint1, A.ColorUint16, A.ColorUint2, A.ColorUint32, A.ColorUint4, A.ColorUint8, A.Pixel]);
    _inherit(A.ExifData, A.IfdContainer);
    _inheritMany(A.IfdValue, [A.IfdByteValue, A.IfdValueShort, A.IfdValueLong, A.IfdValueRational, A.IfdValueSByte, A.IfdValueSShort, A.IfdValueSLong, A.IfdValueSRational, A.IfdValueSingle, A.IfdValueDouble, A.IfdValueUndefined]);
    _inheritMany(A.Encoder, [A.BmpEncoder, A.WinEncoder, A.PngEncoder, A.PvrEncoder, A.TgaEncoder, A.TiffEncoder]);
    _inheritMany(A.WinEncoder, [A.CurEncoder, A.IcoEncoder]);
    _inheritMany(A.PvrColorRgbCore, [A.PvrColorRgb, A.PvrColorRgba]);
    _inherit(A.ImageDataUint8, A.ImageData);
    _inheritMany(A.Palette, [A.PaletteUint32, A.PaletteUint8]);
    _inheritMany(A.Pixel, [A.PixelUint8, A.PixelUndefined]);
    _inherit(A.NeuralQuantizer, A.Quantizer);
    _mixin(A.UnmodifiableListBase, A.UnmodifiableListMixin);
    _mixin(A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, A.ListBase);
    _mixin(A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, A.FixedLengthListMixin);
    _mixin(A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin, A.ListBase);
    _mixin(A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin, A.FixedLengthListMixin);
  })();
  var init = {
    G: typeof self != "undefined" ? self : globalThis,
    typeUniverse: {eC: new Map(), tR: {}, eT: {}, tPV: {}, sEA: []},
    mangledGlobalNames: {int: "int", double: "double", num: "num", String: "String", bool: "bool", Null: "Null", List: "List", Object: "Object", Map: "Map", JSObject: "JSObject"},
    mangledNames: {},
    types: ["~()", "Null()", "~(@)", "Object?(Object?)", "~(~())", "int(int?)", "~(String,IfdDirectory)", "Null(@)", "~(Object?,Object?)", "~(int,@)", "Null(Object,StackTrace)", "~(@,@)", "@(@)", "@(String)", "String?(Object?)", "int?(Object?)", "bool?(Object?)", "Image(JSObject)", "bool(FrameType)", "bool(Format)", "JpegChroma(String?)", "bool(JpegChroma)", "PngFilter(String?)", "bool(PngFilter)", "@(@,String)", "bool(OutputFormat)", "Null(~())", "bool(bool?)", "Null(@,StackTrace)", "~(int,IfdValue)", "Future<~>()", "PvrColorRgb(int,int)", "PvrColorRgba(int,int)", "MapEntry<Object?,Object?>(@,@)", "Null(JSObject)", "Null(ThreadResponse)", "~(String,Completer<~>)", "OutputFormat(String?)"],
    interceptorsByTag: null,
    leafTags: null,
    arrayRti: Symbol("$ti")
  };
  A._Universe_addRules(init.typeUniverse, JSON.parse('{"JavaScriptFunction":"LegacyJavaScriptObject","PlainJavaScriptObject":"LegacyJavaScriptObject","UnknownJavaScriptObject":"LegacyJavaScriptObject","NativeSharedArrayBuffer":"NativeByteBuffer","JSBool":{"bool":[],"TrustedGetRuntimeType":[]},"JSNull":{"Null":[],"TrustedGetRuntimeType":[]},"JavaScriptObject":{"JSObject":[]},"LegacyJavaScriptObject":{"JSObject":[]},"JSArray":{"List":["1"],"EfficientLengthIterable":["1"],"JSObject":[],"Iterable":["1"]},"JSArraySafeToStringHook":{"SafeToStringHook":[]},"JSUnmodifiableArray":{"JSArray":["1"],"List":["1"],"EfficientLengthIterable":["1"],"JSObject":[],"Iterable":["1"]},"ArrayIterator":{"Iterator":["1"]},"JSNumber":{"double":[],"num":[]},"JSInt":{"double":[],"int":[],"num":[],"TrustedGetRuntimeType":[]},"JSNumNotInt":{"double":[],"num":[],"TrustedGetRuntimeType":[]},"JSString":{"String":[],"TrustedGetRuntimeType":[]},"LateError":{"Error":[]},"CodeUnits":{"ListBase":["int"],"UnmodifiableListMixin":["int"],"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"],"ListBase.E":"int","UnmodifiableListMixin.E":"int"},"EfficientLengthIterable":{"Iterable":["1"]},"ListIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"ListIterator":{"Iterator":["1"]},"MappedIterable":{"Iterable":["2"],"Iterable.E":"2"},"EfficientLengthMappedIterable":{"MappedIterable":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"MappedIterator":{"Iterator":["2"]},"MappedListIterable":{"ListIterable":["2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"ListIterable.E":"2","Iterable.E":"2"},"UnmodifiableListBase":{"ListBase":["1"],"UnmodifiableListMixin":["1"],"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"ConstantMap":{"Map":["1","2"]},"ConstantStringMap":{"ConstantMap":["1","2"],"Map":["1","2"]},"_KeysOrValues":{"Iterable":["1"],"Iterable.E":"1"},"_KeysOrValuesOrElementsIterator":{"Iterator":["1"]},"GeneralConstantMap":{"ConstantMap":["1","2"],"Map":["1","2"]},"NullError":{"TypeError":[],"Error":[]},"JsNoSuchMethodError":{"Error":[]},"UnknownJsTypeError":{"Error":[]},"_StackTrace":{"StackTrace":[]},"Closure":{"Function":[]},"Closure0Args":{"Function":[]},"Closure2Args":{"Function":[]},"TearOffClosure":{"Function":[]},"StaticClosure":{"Function":[]},"BoundClosure":{"Function":[]},"RuntimeError":{"Error":[]},"JsLinkedHashMap":{"MapBase":["1","2"],"LinkedHashMap":["1","2"],"Map":["1","2"]},"LinkedHashMapKeysIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"LinkedHashMapKeyIterator":{"Iterator":["1"]},"LinkedHashMapValuesIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"LinkedHashMapValueIterator":{"Iterator":["1"]},"JsConstantLinkedHashMap":{"JsLinkedHashMap":["1","2"],"MapBase":["1","2"],"LinkedHashMap":["1","2"],"Map":["1","2"]},"NativeByteBuffer":{"JSObject":[],"ByteBuffer":[],"TrustedGetRuntimeType":[]},"NativeArrayBuffer":{"NativeByteBuffer":[],"JSObject":[],"ByteBuffer":[],"TrustedGetRuntimeType":[]},"NativeTypedData":{"JSObject":[]},"_UnmodifiableNativeByteBufferView":{"ByteBuffer":[]},"NativeByteData":{"ByteData":[],"JSObject":[],"TrustedGetRuntimeType":[]},"NativeTypedArray":{"JavaScriptIndexingBehavior":["1"],"JSObject":[]},"NativeTypedArrayOfDouble":{"ListBase":["double"],"NativeTypedArray":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"]},"NativeTypedArrayOfInt":{"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"]},"NativeFloat32List":{"Float32List":[],"ListBase":["double"],"NativeTypedArray":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"],"TrustedGetRuntimeType":[],"ListBase.E":"double"},"NativeFloat64List":{"Float64List":[],"ListBase":["double"],"NativeTypedArray":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"],"TrustedGetRuntimeType":[],"ListBase.E":"double"},"NativeInt16List":{"NativeTypedArrayOfInt":[],"Int16List":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeInt32List":{"NativeTypedArrayOfInt":[],"Int32List":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeInt8List":{"NativeTypedArrayOfInt":[],"Int8List":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint16List":{"NativeTypedArrayOfInt":[],"Uint16List":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint32List":{"NativeTypedArrayOfInt":[],"Uint32List":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint8ClampedList":{"NativeTypedArrayOfInt":[],"Uint8ClampedList":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint8List":{"NativeTypedArrayOfInt":[],"Uint8List":[],"ListBase":["int"],"NativeTypedArray":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"_Error":{"Error":[]},"_TypeError":{"TypeError":[],"Error":[]},"_AsyncAwaitCompleter":{"Completer":["1"]},"AsyncError":{"Error":[]},"_Completer":{"Completer":["1"]},"_AsyncCompleter":{"_Completer":["1"],"Completer":["1"]},"_Future":{"Future":["1"]},"_Zone":{"Zone":[]},"_RootZone":{"_Zone":[],"Zone":[]},"_HashMap":{"MapBase":["1","2"],"Map":["1","2"]},"_IdentityHashMap":{"_HashMap":["1","2"],"MapBase":["1","2"],"Map":["1","2"]},"_HashMapKeyIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"_HashMapKeyIterator":{"Iterator":["1"]},"ListBase":{"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"MapBase":{"Map":["1","2"]},"double":{"num":[]},"int":{"num":[]},"List":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"AssertionError":{"Error":[]},"TypeError":{"Error":[]},"ArgumentError":{"Error":[]},"RangeError":{"Error":[]},"IndexError":{"Error":[]},"UnsupportedError":{"Error":[]},"UnimplementedError":{"Error":[]},"StateError":{"Error":[]},"ConcurrentModificationError":{"Error":[]},"OutOfMemoryError":{"Error":[]},"StackOverflowError":{"Error":[]},"_StringStackTrace":{"StackTrace":[]},"InputMemoryStream":{"InputStream":[]},"OutputMemoryStream":{"OutputStream":[]},"ChannelIterator":{"Iterator":["num"]},"Color":{"Iterable":["num"]},"ColorFloat16":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorFloat32":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorFloat64":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorInt16":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorInt32":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorInt8":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorUint1":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorUint16":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorUint2":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorUint32":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorUint4":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ColorUint8":{"Color":[],"Iterable":["num"],"Iterable.E":"num"},"ExifData":{"IfdContainer":[]},"IfdByteValue":{"IfdValue":[]},"IfdValueShort":{"IfdValue":[]},"IfdValueLong":{"IfdValue":[]},"IfdValueRational":{"IfdValue":[]},"IfdValueSByte":{"IfdValue":[]},"IfdValueSShort":{"IfdValue":[]},"IfdValueSLong":{"IfdValue":[]},"IfdValueSRational":{"IfdValue":[]},"IfdValueSingle":{"IfdValue":[]},"IfdValueDouble":{"IfdValue":[]},"IfdValueUndefined":{"IfdValue":[]},"Image":{"Iterable":["Pixel"],"Iterable.E":"Pixel"},"ImageData":{"Iterable":["Pixel"]},"ImageDataUint8":{"ImageData":[],"Iterable":["Pixel"],"Iterable.E":"Pixel"},"PaletteUint32":{"Palette":[]},"PaletteUint8":{"Palette":[]},"Pixel":{"Color":[],"Iterable":["num"],"Iterator":["Pixel"]},"PixelUint8":{"Pixel":[],"Color":[],"Iterable":["num"],"Iterator":["Pixel"],"Iterable.E":"num"},"PixelUndefined":{"Pixel":[],"Color":[],"Iterable":["num"],"Iterator":["Pixel"],"Iterable.E":"num"},"NeuralQuantizer":{"Quantizer":[]},"Int8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8ClampedList":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Float32List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"Float64List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]}}'));
  A._Universe_addErasedTypes(init.typeUniverse, JSON.parse('{"EfficientLengthIterable":1,"UnmodifiableListBase":1,"NativeTypedArray":1,"Converter":2,"PvrColorRgbCore":1}'));
  var string$ = {
    Error_: "Error handler must accept one Object or one Object and a StackTrace as arguments, and return a value of the returned future's type",
    PVRTC_: "PVRTC requires a power-of-two sized image."
  };
  var type$ = (function rtii() {
    var findType = A.findType;
    return {
      AsyncError: findType("AsyncError"),
      ByteBuffer: findType("ByteBuffer"),
      ByteData: findType("ByteData"),
      Completer_void: findType("Completer<~>"),
      EfficientLengthIterable_dynamic: findType("EfficientLengthIterable<@>"),
      Error: findType("Error"),
      Float32List: findType("Float32List"),
      Float64List: findType("Float64List"),
      Format: findType("Format"),
      FrameType: findType("FrameType"),
      Function: findType("Function"),
      GeneralConstantMap_Format_int: findType("GeneralConstantMap<Format,int>"),
      IfdDirectory: findType("IfdDirectory"),
      IfdValue: findType("IfdValue"),
      Image: findType("Image"),
      ImageData: findType("ImageData"),
      Int16List: findType("Int16List"),
      Int32List: findType("Int32List"),
      Int8List: findType("Int8List"),
      Iterable_dynamic: findType("Iterable<@>"),
      Iterable_int: findType("Iterable<int>"),
      JSArray_Image: findType("JSArray<Image>"),
      JSArray_List_int: findType("JSArray<List<int>>"),
      JSArray_Rational: findType("JSArray<Rational>"),
      JSArray_String: findType("JSArray<String>"),
      JSArray_dynamic: findType("JSArray<@>"),
      JSArray_int: findType("JSArray<int>"),
      JSArray_nullable_List_int: findType("JSArray<List<int>?>"),
      JSNull: findType("JSNull"),
      JSObject: findType("JSObject"),
      JavaScriptFunction: findType("JavaScriptFunction"),
      JavaScriptIndexingBehavior_dynamic: findType("JavaScriptIndexingBehavior<@>"),
      JpegChroma: findType("JpegChroma"),
      List_Image: findType("List<Image>"),
      List_List_int: findType("List<List<int>>"),
      List_Rational: findType("List<Rational>"),
      List_double: findType("List<double>"),
      List_dynamic: findType("List<@>"),
      List_int: findType("List<int>"),
      List_nullable_List_int: findType("List<List<int>?>"),
      MapEntry_of_nullable_Object_and_nullable_Object: findType("MapEntry<Object?,Object?>"),
      Map_dynamic_dynamic: findType("Map<@,@>"),
      NativeArrayBuffer: findType("NativeArrayBuffer"),
      NativeTypedArrayOfInt: findType("NativeTypedArrayOfInt"),
      Null: findType("Null"),
      Object: findType("Object"),
      Object_Function: findType("Object()"),
      OutputFormat: findType("OutputFormat"),
      PngFilter: findType("PngFilter"),
      PvrColorBoundingBox_PvrColorRgb: findType("PvrColorBoundingBox<PvrColorRgb>"),
      PvrColorBoundingBox_PvrColorRgba: findType("PvrColorBoundingBox<PvrColorRgba>"),
      PvrColorRgb: findType("PvrColorRgb"),
      PvrColorRgba: findType("PvrColorRgba"),
      Rational: findType("Rational"),
      Record: findType("Record"),
      StackTrace: findType("StackTrace"),
      String: findType("String"),
      ThreadResponse: findType("ThreadResponse"),
      TrustedGetRuntimeType: findType("TrustedGetRuntimeType"),
      TypeError: findType("TypeError"),
      Uint16List: findType("Uint16List"),
      Uint32List: findType("Uint32List"),
      Uint8ClampedList: findType("Uint8ClampedList"),
      Uint8List: findType("Uint8List"),
      UnknownJavaScriptObject: findType("UnknownJavaScriptObject"),
      _AsyncCompleter_dynamic: findType("_AsyncCompleter<@>"),
      _BoundingBox: findType("_BoundingBox"),
      _Future_dynamic: findType("_Future<@>"),
      _IdentityHashMap_of_nullable_Object_and_nullable_Object: findType("_IdentityHashMap<Object?,Object?>"),
      bool: findType("bool"),
      bool_Function_Object: findType("bool(Object)"),
      double: findType("double"),
      dynamic: findType("@"),
      dynamic_Function: findType("@()"),
      dynamic_Function_Object: findType("@(Object)"),
      dynamic_Function_Object_StackTrace: findType("@(Object,StackTrace)"),
      int: findType("int"),
      nullable_Future_Null: findType("Future<Null>?"),
      nullable_JSObject: findType("JSObject?"),
      nullable_List_int: findType("List<int>?"),
      nullable_List_nullable_List_int: findType("List<List<int>?>?"),
      nullable_Map_String_String: findType("Map<String,String>?"),
      nullable_Object: findType("Object?"),
      nullable_String: findType("String?"),
      nullable__FutureListener_dynamic_dynamic: findType("_FutureListener<@,@>?"),
      nullable_bool: findType("bool?"),
      nullable_double: findType("double?"),
      nullable_int: findType("int?"),
      nullable_num: findType("num?"),
      num: findType("num"),
      void: findType("~"),
      void_Function: findType("~()")
    };
  })();
  (function constants() {
    var makeConstList = hunkHelpers.makeConstList;
    B.Interceptor_methods = J.Interceptor.prototype;
    B.JSArray_methods = J.JSArray.prototype;
    B.JSInt_methods = J.JSInt.prototype;
    B.JSNumber_methods = J.JSNumber.prototype;
    B.JSString_methods = J.JSString.prototype;
    B.JavaScriptFunction_methods = J.JavaScriptFunction.prototype;
    B.JavaScriptObject_methods = J.JavaScriptObject.prototype;
    B.NativeArrayBuffer_methods = A.NativeArrayBuffer.prototype;
    B.NativeFloat32List_methods = A.NativeFloat32List.prototype;
    B.NativeFloat64List_methods = A.NativeFloat64List.prototype;
    B.NativeInt16List_methods = A.NativeInt16List.prototype;
    B.NativeInt32List_methods = A.NativeInt32List.prototype;
    B.NativeInt8List_methods = A.NativeInt8List.prototype;
    B.NativeUint32List_methods = A.NativeUint32List.prototype;
    B.NativeUint8List_methods = A.NativeUint8List.prototype;
    B.PlainJavaScriptObject_methods = J.PlainJavaScriptObject.prototype;
    B.UnknownJavaScriptObject_methods = J.UnknownJavaScriptObject.prototype;
    B.BmpCompression_0 = new A.BmpCompression(0, "none");
    B.BmpCompression_3 = new A.BmpCompression(3, "bitfields");
    B.ByteOrder_0 = new A.ByteOrder(0, "littleEndian");
    B.ByteOrder_1 = new A.ByteOrder(1, "bigEndian");
    B.C_JS_CONST = function getTagFallback(o) {
  var s = Object.prototype.toString.call(o);
  return s.substring(8, s.length - 1);
};
    B.C_JS_CONST0 = function() {
  var toStringFunction = Object.prototype.toString;
  function getTag(o) {
    var s = toStringFunction.call(o);
    return s.substring(8, s.length - 1);
  }
  function getUnknownTag(object, tag) {
    if (/^HTML[A-Z].*Element$/.test(tag)) {
      var name = toStringFunction.call(object);
      if (name == "[object Object]") return null;
      return "HTMLElement";
    }
  }
  function getUnknownTagGenericBrowser(object, tag) {
    if (object instanceof HTMLElement) return "HTMLElement";
    return getUnknownTag(object, tag);
  }
  function prototypeForTag(tag) {
    if (typeof window == "undefined") return null;
    if (typeof window[tag] == "undefined") return null;
    var constructor = window[tag];
    if (typeof constructor != "function") return null;
    return constructor.prototype;
  }
  function discriminator(tag) { return null; }
  var isBrowser = typeof HTMLElement == "function";
  return {
    getTag: getTag,
    getUnknownTag: isBrowser ? getUnknownTagGenericBrowser : getUnknownTag,
    prototypeForTag: prototypeForTag,
    discriminator: discriminator };
};
    B.C_JS_CONST6 = function(getTagFallback) {
  return function(hooks) {
    if (typeof navigator != "object") return hooks;
    var userAgent = navigator.userAgent;
    if (typeof userAgent != "string") return hooks;
    if (userAgent.indexOf("DumpRenderTree") >= 0) return hooks;
    if (userAgent.indexOf("Chrome") >= 0) {
      function confirm(p) {
        return typeof window == "object" && window[p] && window[p].name == p;
      }
      if (confirm("Window") && confirm("HTMLElement")) return hooks;
    }
    hooks.getTag = getTagFallback;
  };
};
    B.C_JS_CONST1 = function(hooks) {
  if (typeof dartExperimentalFixupGetTag != "function") return hooks;
  hooks.getTag = dartExperimentalFixupGetTag(hooks.getTag);
};
    B.C_JS_CONST5 = function(hooks) {
  if (typeof navigator != "object") return hooks;
  var userAgent = navigator.userAgent;
  if (typeof userAgent != "string") return hooks;
  if (userAgent.indexOf("Firefox") == -1) return hooks;
  var getTag = hooks.getTag;
  var quickMap = {
    "BeforeUnloadEvent": "Event",
    "DataTransfer": "Clipboard",
    "GeoGeolocation": "Geolocation",
    "Location": "!Location",
    "WorkerMessageEvent": "MessageEvent",
    "XMLDocument": "!Document"};
  function getTagFirefox(o) {
    var tag = getTag(o);
    return quickMap[tag] || tag;
  }
  hooks.getTag = getTagFirefox;
};
    B.C_JS_CONST4 = function(hooks) {
  if (typeof navigator != "object") return hooks;
  var userAgent = navigator.userAgent;
  if (typeof userAgent != "string") return hooks;
  if (userAgent.indexOf("Trident/") == -1) return hooks;
  var getTag = hooks.getTag;
  var quickMap = {
    "BeforeUnloadEvent": "Event",
    "DataTransfer": "Clipboard",
    "HTMLDDElement": "HTMLElement",
    "HTMLDTElement": "HTMLElement",
    "HTMLPhraseElement": "HTMLElement",
    "Position": "Geoposition"
  };
  function getTagIE(o) {
    var tag = getTag(o);
    var newTag = quickMap[tag];
    if (newTag) return newTag;
    if (tag == "Object") {
      if (window.DataView && (o instanceof window.DataView)) return "DataView";
    }
    return tag;
  }
  function prototypeForTagIE(tag) {
    var constructor = window[tag];
    if (constructor == null) return null;
    return constructor.prototype;
  }
  hooks.getTag = getTagIE;
  hooks.prototypeForTag = prototypeForTagIE;
};
    B.C_JS_CONST2 = function(hooks) {
  var getTag = hooks.getTag;
  var prototypeForTag = hooks.prototypeForTag;
  function getTagFixed(o) {
    var tag = getTag(o);
    if (tag == "Document") {
      if (!!o.xmlVersion) return "!Document";
      return "!HTMLDocument";
    }
    return tag;
  }
  function prototypeForTagFixed(tag) {
    if (tag == "Document") return null;
    return prototypeForTag(tag);
  }
  hooks.getTag = getTagFixed;
  hooks.prototypeForTag = prototypeForTagFixed;
};
    B.C_JS_CONST3 = function(hooks) { return hooks; }
;
    B.C_Latin1Encoder = new A.Latin1Encoder();
    B.C_OutOfMemoryError = new A.OutOfMemoryError();
    B.C_SentinelValue = new A.SentinelValue();
    B.C__RootZone = new A._RootZone();
    B.C__StringStackTrace = new A._StringStackTrace();
    B.C__ZLibEncoder = new A._ZLibEncoder();
    B.ChannelOrder_0 = new A.ChannelOrder(0, "rgba");
    B.ChannelOrder_1 = new A.ChannelOrder(1, "bgra");
    B.ChannelOrder_2 = new A.ChannelOrder(2, "abgr");
    B.ChannelOrder_3 = new A.ChannelOrder(3, "argb");
    B.ChannelOrder_4 = new A.ChannelOrder(4, "rgb");
    B.ChannelOrder_5 = new A.ChannelOrder(5, "bgr");
    B.ChannelOrder_6 = new A.ChannelOrder(6, "grayAlpha");
    B.ChannelOrder_7 = new A.ChannelOrder(7, "red");
    B.Duration_0 = new A.Duration(0);
    B.Duration_10 = new A.Duration(10);
    B.FormatType_0 = new A.FormatType(0, "uint");
    B.Format_0 = new A.Format(0, "uint1");
    B.Format_1 = new A.Format(1, "uint2");
    B.Format_10 = new A.Format(10, "float32");
    B.Format_11 = new A.Format(11, "float64");
    B.Format_2 = new A.Format(2, "uint4");
    B.Format_3 = new A.Format(3, "uint8");
    B.Format_4 = new A.Format(4, "uint16");
    B.Format_5 = new A.Format(5, "uint32");
    B.Format_6 = new A.Format(6, "int8");
    B.Format_7 = new A.Format(7, "int16");
    B.Format_8 = new A.Format(8, "int32");
    B.Format_9 = new A.Format(9, "float16");
    B.FrameType_2 = new A.FrameType(2, "sequence");
    B.IfdValueType_0 = new A.IfdValueType(0, "none");
    B.IfdValueType_1 = new A.IfdValueType(1, "byte");
    B.IfdValueType_10 = new A.IfdValueType(10, "sRational");
    B.IfdValueType_11 = new A.IfdValueType(11, "single");
    B.IfdValueType_12 = new A.IfdValueType(12, "double");
    B.IfdValueType_2 = new A.IfdValueType(2, "ascii");
    B.IfdValueType_3 = new A.IfdValueType(3, "short");
    B.IfdValueType_4 = new A.IfdValueType(4, "long");
    B.IfdValueType_5 = new A.IfdValueType(5, "rational");
    B.IfdValueType_6 = new A.IfdValueType(6, "sByte");
    B.IfdValueType_7 = new A.IfdValueType(7, "undefined");
    B.IfdValueType_8 = new A.IfdValueType(8, "sShort");
    B.IfdValueType_9 = new A.IfdValueType(9, "sLong");
    B.JpegChroma_0 = new A.JpegChroma(0, "yuv444");
    B.List_0H6 = makeConstList([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15], type$.JSArray_int);
    B.List_1eA = makeConstList([0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0], type$.JSArray_int);
    B.List_2BR = makeConstList([0, 0, 2, 1, 3, 3, 2, 4, 3, 5, 5, 4, 4, 0, 0, 1, 125], type$.JSArray_int);
    B.List_2Xs = makeConstList([0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 12, 14, 16, 20, 24, 28, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 0], type$.JSArray_int);
    B.List_2gL = makeConstList([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7], type$.JSArray_int);
    B.List_4f6 = makeConstList([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7], type$.JSArray_int);
    B.FrameType_0 = new A.FrameType(0, "animation");
    B.FrameType_1 = new A.FrameType(1, "page");
    B.List_52t = makeConstList([B.FrameType_0, B.FrameType_1, B.FrameType_2], A.findType("JSArray<FrameType>"));
    B.List_63_207_243_252 = makeConstList([63, 207, 243, 252], type$.JSArray_int);
    B.List_6sz = makeConstList([17, 18, 24, 47, 99, 99, 99, 99, 18, 21, 26, 66, 99, 99, 99, 99, 24, 26, 56, 99, 99, 99, 99, 99, 47, 66, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99], type$.JSArray_int);
    B.List_74c = makeConstList([0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], type$.JSArray_int);
    B.List_972 = makeConstList([0, 1, 2, 3, 4, 6, 8, 12, 16, 24, 32, 48, 64, 96, 128, 192, 256, 384, 512, 768, 1024, 1536, 2048, 3072, 4096, 6144, 8192, 12288, 16384, 24576], type$.JSArray_int);
    B.List_A98 = makeConstList([1, 1.387039845, 1.306562965, 1.175875602, 1, 0.785694958, 0.5411961, 0.275899379], A.findType("JSArray<double>"));
    B.List_BSx = makeConstList([0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 16, 17, 18, 18, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29], type$.JSArray_int);
    B.List_CZS = makeConstList([1, 2, 3, 0, 4, 17, 5, 18, 33, 49, 65, 6, 19, 81, 97, 7, 34, 113, 20, 50, 129, 145, 161, 8, 35, 66, 177, 193, 21, 82, 209, 240, 36, 51, 98, 114, 130, 9, 10, 22, 23, 24, 25, 26, 37, 38, 39, 40, 41, 42, 52, 53, 54, 55, 56, 57, 58, 67, 68, 69, 70, 71, 72, 73, 74, 83, 84, 85, 86, 87, 88, 89, 90, 99, 100, 101, 102, 103, 104, 105, 106, 115, 116, 117, 118, 119, 120, 121, 122, 131, 132, 133, 134, 135, 136, 137, 138, 146, 147, 148, 149, 150, 151, 152, 153, 154, 162, 163, 164, 165, 166, 167, 168, 169, 170, 178, 179, 180, 181, 182, 183, 184, 185, 186, 194, 195, 196, 197, 198, 199, 200, 201, 202, 210, 211, 212, 213, 214, 215, 216, 217, 218, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250], type$.JSArray_int);
    B.OutputFormat_0 = new A.OutputFormat(0, "jpg");
    B.OutputFormat_1 = new A.OutputFormat(1, "png");
    B.OutputFormat_2 = new A.OutputFormat(2, "tiff");
    B.OutputFormat_3 = new A.OutputFormat(3, "bmp");
    B.OutputFormat_4 = new A.OutputFormat(4, "cur");
    B.OutputFormat_5 = new A.OutputFormat(5, "pvr");
    B.OutputFormat_6 = new A.OutputFormat(6, "tga");
    B.OutputFormat_7 = new A.OutputFormat(7, "ico");
    B.List_D9t = makeConstList([B.OutputFormat_0, B.OutputFormat_1, B.OutputFormat_2, B.OutputFormat_3, B.OutputFormat_4, B.OutputFormat_5, B.OutputFormat_6, B.OutputFormat_7], A.findType("JSArray<OutputFormat>"));
    B.List_EVh = makeConstList([0, 1, 5, 6, 14, 15, 27, 28, 2, 4, 7, 13, 16, 26, 29, 42, 3, 8, 12, 17, 25, 30, 41, 43, 9, 11, 18, 24, 31, 40, 44, 53, 10, 19, 23, 32, 39, 45, 52, 54, 20, 22, 33, 38, 46, 51, 55, 60, 21, 34, 37, 47, 50, 56, 59, 61, 35, 36, 48, 49, 57, 58, 62, 63], type$.JSArray_int);
    B.PngFilter_0 = new A.PngFilter(0, "none");
    B.PngFilter_1 = new A.PngFilter(1, "sub");
    B.PngFilter_2 = new A.PngFilter(2, "up");
    B.PngFilter_3 = new A.PngFilter(3, "average");
    B.PngFilter_4 = new A.PngFilter(4, "paeth");
    B.List_Eq4 = makeConstList([B.PngFilter_0, B.PngFilter_1, B.PngFilter_2, B.PngFilter_3, B.PngFilter_4], A.findType("JSArray<PngFilter>"));
    B.List_GUW = makeConstList([0, 0, 2, 1, 2, 4, 4, 3, 4, 7, 5, 4, 4, 0, 1, 2, 119], type$.JSArray_int);
    B.List_GYx = makeConstList([0, 1, 2, 3, 4, 5, 6, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 19, 19, 19, 19, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 28], type$.JSArray_int);
    B.List_HmF = makeConstList([0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13], type$.JSArray_int);
    B.List_Ib9 = makeConstList([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], type$.JSArray_int);
    B.JpegChroma_1 = new A.JpegChroma(1, "yuv420");
    B.List_JpegChroma_0_JpegChroma_1 = makeConstList([B.JpegChroma_0, B.JpegChroma_1], A.findType("JSArray<JpegChroma>"));
    B.List_LCt = makeConstList([12, 8, 140, 8, 76, 8, 204, 8, 44, 8, 172, 8, 108, 8, 236, 8, 28, 8, 156, 8, 92, 8, 220, 8, 60, 8, 188, 8, 124, 8, 252, 8, 2, 8, 130, 8, 66, 8, 194, 8, 34, 8, 162, 8, 98, 8, 226, 8, 18, 8, 146, 8, 82, 8, 210, 8, 50, 8, 178, 8, 114, 8, 242, 8, 10, 8, 138, 8, 74, 8, 202, 8, 42, 8, 170, 8, 106, 8, 234, 8, 26, 8, 154, 8, 90, 8, 218, 8, 58, 8, 186, 8, 122, 8, 250, 8, 6, 8, 134, 8, 70, 8, 198, 8, 38, 8, 166, 8, 102, 8, 230, 8, 22, 8, 150, 8, 86, 8, 214, 8, 54, 8, 182, 8, 118, 8, 246, 8, 14, 8, 142, 8, 78, 8, 206, 8, 46, 8, 174, 8, 110, 8, 238, 8, 30, 8, 158, 8, 94, 8, 222, 8, 62, 8, 190, 8, 126, 8, 254, 8, 1, 8, 129, 8, 65, 8, 193, 8, 33, 8, 161, 8, 97, 8, 225, 8, 17, 8, 145, 8, 81, 8, 209, 8, 49, 8, 177, 8, 113, 8, 241, 8, 9, 8, 137, 8, 73, 8, 201, 8, 41, 8, 169, 8, 105, 8, 233, 8, 25, 8, 153, 8, 89, 8, 217, 8, 57, 8, 185, 8, 121, 8, 249, 8, 5, 8, 133, 8, 69, 8, 197, 8, 37, 8, 165, 8, 101, 8, 229, 8, 21, 8, 149, 8, 85, 8, 213, 8, 53, 8, 181, 8, 117, 8, 245, 8, 13, 8, 141, 8, 77, 8, 205, 8, 45, 8, 173, 8, 109, 8, 237, 8, 29, 8, 157, 8, 93, 8, 221, 8, 61, 8, 189, 8, 125, 8, 253, 8, 19, 9, 275, 9, 147, 9, 403, 9, 83, 9, 339, 9, 211, 9, 467, 9, 51, 9, 307, 9, 179, 9, 435, 9, 115, 9, 371, 9, 243, 9, 499, 9, 11, 9, 267, 9, 139, 9, 395, 9, 75, 9, 331, 9, 203, 9, 459, 9, 43, 9, 299, 9, 171, 9, 427, 9, 107, 9, 363, 9, 235, 9, 491, 9, 27, 9, 283, 9, 155, 9, 411, 9, 91, 9, 347, 9, 219, 9, 475, 9, 59, 9, 315, 9, 187, 9, 443, 9, 123, 9, 379, 9, 251, 9, 507, 9, 7, 9, 263, 9, 135, 9, 391, 9, 71, 9, 327, 9, 199, 9, 455, 9, 39, 9, 295, 9, 167, 9, 423, 9, 103, 9, 359, 9, 231, 9, 487, 9, 23, 9, 279, 9, 151, 9, 407, 9, 87, 9, 343, 9, 215, 9, 471, 9, 55, 9, 311, 9, 183, 9, 439, 9, 119, 9, 375, 9, 247, 9, 503, 9, 15, 9, 271, 9, 143, 9, 399, 9, 79, 9, 335, 9, 207, 9, 463, 9, 47, 9, 303, 9, 175, 9, 431, 9, 111, 9, 367, 9, 239, 9, 495, 9, 31, 9, 287, 9, 159, 9, 415, 9, 95, 9, 351, 9, 223, 9, 479, 9, 63, 9, 319, 9, 191, 9, 447, 9, 127, 9, 383, 9, 255, 9, 511, 9, 0, 7, 64, 7, 32, 7, 96, 7, 16, 7, 80, 7, 48, 7, 112, 7, 8, 7, 72, 7, 40, 7, 104, 7, 24, 7, 88, 7, 56, 7, 120, 7, 4, 7, 68, 7, 36, 7, 100, 7, 20, 7, 84, 7, 52, 7, 116, 7, 3, 8, 131, 8, 67, 8, 195, 8, 35, 8, 163, 8, 99, 8, 227, 8], type$.JSArray_int);
    B.List_LJO = makeConstList([0, 5, 16, 5, 8, 5, 24, 5, 4, 5, 20, 5, 12, 5, 28, 5, 2, 5, 18, 5, 10, 5, 26, 5, 6, 5, 22, 5, 14, 5, 30, 5, 1, 5, 17, 5, 9, 5, 25, 5, 5, 5, 21, 5, 13, 5, 29, 5, 3, 5, 19, 5, 11, 5, 27, 5, 7, 5, 23, 5], type$.JSArray_int);
    B.List_NZS = makeConstList([0, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], type$.JSArray_int);
    B.List_ODE = makeConstList([0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 19, 19, 19, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 26, 26, 26, 27, 27, 27, 27, 27, 27, 27, 27, 27, 28, 28, 28, 28, 28, 28, 28, 28, 29, 29, 29, 29, 29, 29, 29, 29, 30, 30, 30, 30, 30, 30, 30, 30, 31, 31, 31, 31, 31, 31, 31, 31, 31], type$.JSArray_int);
    B.List_X1N = makeConstList([0, 1, 2, 3, 17, 4, 5, 33, 49, 6, 18, 65, 81, 7, 97, 113, 19, 34, 50, 129, 8, 20, 66, 145, 161, 177, 193, 9, 35, 51, 82, 240, 21, 98, 114, 209, 10, 22, 36, 52, 225, 37, 241, 23, 24, 25, 26, 38, 39, 40, 41, 42, 53, 54, 55, 56, 57, 58, 67, 68, 69, 70, 71, 72, 73, 74, 83, 84, 85, 86, 87, 88, 89, 90, 99, 100, 101, 102, 103, 104, 105, 106, 115, 116, 117, 118, 119, 120, 121, 122, 130, 131, 132, 133, 134, 135, 136, 137, 138, 146, 147, 148, 149, 150, 151, 152, 153, 154, 162, 163, 164, 165, 166, 167, 168, 169, 170, 178, 179, 180, 181, 182, 183, 184, 185, 186, 194, 195, 196, 197, 198, 199, 200, 201, 202, 210, 211, 212, 213, 214, 215, 216, 217, 218, 226, 227, 228, 229, 230, 231, 232, 233, 234, 242, 243, 244, 245, 246, 247, 248, 249, 250], type$.JSArray_int);
    B.List_aYr = makeConstList([16, 11, 10, 16, 24, 40, 51, 61, 12, 12, 14, 19, 26, 58, 60, 55, 14, 13, 16, 24, 40, 57, 69, 56, 14, 17, 22, 29, 51, 87, 80, 62, 18, 22, 37, 56, 68, 109, 103, 77, 24, 35, 55, 64, 81, 104, 113, 92, 49, 64, 78, 87, 103, 121, 120, 101, 72, 92, 95, 98, 112, 100, 103, 99], type$.JSArray_int);
    B.List_bAA = makeConstList([0, 1, 4, 5, 16, 17, 20, 21, 64, 65, 68, 69, 80, 81, 84, 85, 256, 257, 260, 261, 272, 273, 276, 277, 320, 321, 324, 325, 336, 337, 340, 341, 1024, 1025, 1028, 1029, 1040, 1041, 1044, 1045, 1088, 1089, 1092, 1093, 1104, 1105, 1108, 1109, 1280, 1281, 1284, 1285, 1296, 1297, 1300, 1301, 1344, 1345, 1348, 1349, 1360, 1361, 1364, 1365, 4096, 4097, 4100, 4101, 4112, 4113, 4116, 4117, 4160, 4161, 4164, 4165, 4176, 4177, 4180, 4181, 4352, 4353, 4356, 4357, 4368, 4369, 4372, 4373, 4416, 4417, 4420, 4421, 4432, 4433, 4436, 4437, 5120, 5121, 5124, 5125, 5136, 5137, 5140, 5141, 5184, 5185, 5188, 5189, 5200, 5201, 5204, 5205, 5376, 5377, 5380, 5381, 5392, 5393, 5396, 5397, 5440, 5441, 5444, 5445, 5456, 5457, 5460, 5461, 16384, 16385, 16388, 16389, 16400, 16401, 16404, 16405, 16448, 16449, 16452, 16453, 16464, 16465, 16468, 16469, 16640, 16641, 16644, 16645, 16656, 16657, 16660, 16661, 16704, 16705, 16708, 16709, 16720, 16721, 16724, 16725, 17408, 17409, 17412, 17413, 17424, 17425, 17428, 17429, 17472, 17473, 17476, 17477, 17488, 17489, 17492, 17493, 17664, 17665, 17668, 17669, 17680, 17681, 17684, 17685, 17728, 17729, 17732, 17733, 17744, 17745, 17748, 17749, 20480, 20481, 20484, 20485, 20496, 20497, 20500, 20501, 20544, 20545, 20548, 20549, 20560, 20561, 20564, 20565, 20736, 20737, 20740, 20741, 20752, 20753, 20756, 20757, 20800, 20801, 20804, 20805, 20816, 20817, 20820, 20821, 21504, 21505, 21508, 21509, 21520, 21521, 21524, 21525, 21568, 21569, 21572, 21573, 21584, 21585, 21588, 21589, 21760, 21761, 21764, 21765, 21776, 21777, 21780, 21781, 21824, 21825, 21828, 21829, 21840, 21841, 21844, 21845], type$.JSArray_int);
    B.List_i9p = makeConstList([0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 19, 19, 19, 19, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 26, 26, 26, 26, 27, 27, 27, 27, 27, 27, 27, 27, 28, 28, 28, 28, 28, 28, 28, 28, 29, 29, 29, 29, 29, 29, 29, 29, 30, 30, 30, 30, 30, 30, 30, 30, 31], type$.JSArray_int);
    B.List_kC8 = makeConstList([0, 1996959894, 3993919788, 2567524794, 124634137, 1886057615, 3915621685, 2657392035, 249268274, 2044508324, 3772115230, 2547177864, 162941995, 2125561021, 3887607047, 2428444049, 498536548, 1789927666, 4089016648, 2227061214, 450548861, 1843258603, 4107580753, 2211677639, 325883990, 1684777152, 4251122042, 2321926636, 335633487, 1661365465, 4195302755, 2366115317, 997073096, 1281953886, 3579855332, 2724688242, 1006888145, 1258607687, 3524101629, 2768942443, 901097722, 1119000684, 3686517206, 2898065728, 853044451, 1172266101, 3705015759, 2882616665, 651767980, 1373503546, 3369554304, 3218104598, 565507253, 1454621731, 3485111705, 3099436303, 671266974, 1594198024, 3322730930, 2970347812, 795835527, 1483230225, 3244367275, 3060149565, 1994146192, 31158534, 2563907772, 4023717930, 1907459465, 112637215, 2680153253, 3904427059, 2013776290, 251722036, 2517215374, 3775830040, 2137656763, 141376813, 2439277719, 3865271297, 1802195444, 476864866, 2238001368, 4066508878, 1812370925, 453092731, 2181625025, 4111451223, 1706088902, 314042704, 2344532202, 4240017532, 1658658271, 366619977, 2362670323, 4224994405, 1303535960, 984961486, 2747007092, 3569037538, 1256170817, 1037604311, 2765210733, 3554079995, 1131014506, 879679996, 2909243462, 3663771856, 1141124467, 855842277, 2852801631, 3708648649, 1342533948, 654459306, 3188396048, 3373015174, 1466479909, 544179635, 3110523913, 3462522015, 1591671054, 702138776, 2966460450, 3352799412, 1504918807, 783551873, 3082640443, 3233442989, 3988292384, 2596254646, 62317068, 1957810842, 3939845945, 2647816111, 81470997, 1943803523, 3814918930, 2489596804, 225274430, 2053790376, 3826175755, 2466906013, 167816743, 2097651377, 4027552580, 2265490386, 503444072, 1762050814, 4150417245, 2154129355, 426522225, 1852507879, 4275313526, 2312317920, 282753626, 1742555852, 4189708143, 2394877945, 397917763, 1622183637, 3604390888, 2714866558, 953729732, 1340076626, 3518719985, 2797360999, 1068828381, 1219638859, 3624741850, 2936675148, 906185462, 1090812512, 3747672003, 2825379669, 829329135, 1181335161, 3412177804, 3160834842, 628085408, 1382605366, 3423369109, 3138078467, 570562233, 1426400815, 3317316542, 2998733608, 733239954, 1555261956, 3268935591, 3050360625, 752459403, 1541320221, 2607071920, 3965973030, 1969922972, 40735498, 2617837225, 3943577151, 1913087877, 83908371, 2512341634, 3803740692, 2075208622, 213261112, 2463272603, 3855990285, 2094854071, 198958881, 2262029012, 4057260610, 1759359992, 534414190, 2176718541, 4139329115, 1873836001, 414664567, 2282248934, 4279200368, 1711684554, 285281116, 2405801727, 4167216745, 1634467795, 376229701, 2685067896, 3608007406, 1308918612, 956543938, 2808555105, 3495958263, 1231636301, 1047427035, 2932959818, 3654703836, 1088359270, 936918000, 2847714899, 3736837829, 1202900863, 817233897, 3183342108, 3401237130, 1404277552, 615818150, 3134207493, 3453421203, 1423857449, 601450431, 3009837614, 3294710456, 1567103746, 711928724, 3020668471, 3272380065, 1510334235, 755167117], type$.JSArray_int);
    B.List_lln = makeConstList([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15], type$.JSArray_int);
    B.List_mEo = makeConstList([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7], type$.JSArray_int);
    B.List_qqA = makeConstList([0, 17, 34, 51, 68, 85, 102, 119, 136, 153, 170, 187, 204, 221, 238, 255], type$.JSArray_int);
    B.List_vdB = makeConstList([0, 36, 72, 109, 145, 182, 218, 255], type$.JSArray_int);
    B.List_vhF = makeConstList([0, 8, 16, 24, 32, 41, 49, 57, 65, 74, 82, 90, 98, 106, 115, 123, 131, 139, 148, 156, 164, 172, 180, 189, 197, 205, 213, 222, 230, 238, 246, 255], type$.JSArray_int);
    B.List_vwN = makeConstList([B.Format_0, B.Format_1, B.Format_2, B.Format_3, B.Format_4, B.Format_5, B.Format_6, B.Format_7, B.Format_8, B.Format_9, B.Format_10, B.Format_11], A.findType("JSArray<Format>"));
    B.List_w4E = makeConstList([0, 1, 1, 2, 4, 8, 1, 1, 2, 4, 8, 4, 8], type$.JSArray_int);
    B.List_zcj = makeConstList([0, 0, 1, 5, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0], type$.JSArray_int);
    B.List_4_4_4_4 = makeConstList([4, 4, 4, 4], type$.JSArray_int);
    B.List_2_6_2_6 = makeConstList([2, 6, 2, 6], type$.JSArray_int);
    B.List_8_0_8_0 = makeConstList([8, 0, 8, 0], type$.JSArray_int);
    B.List_6_2_6_2 = makeConstList([6, 2, 6, 2], type$.JSArray_int);
    B.List_2_2_6_6 = makeConstList([2, 2, 6, 6], type$.JSArray_int);
    B.List_1_3_3_9 = makeConstList([1, 3, 3, 9], type$.JSArray_int);
    B.List_4_0_12_0 = makeConstList([4, 0, 12, 0], type$.JSArray_int);
    B.List_3_1_9_3 = makeConstList([3, 1, 9, 3], type$.JSArray_int);
    B.List_8_8_0_0 = makeConstList([8, 8, 0, 0], type$.JSArray_int);
    B.List_4_12_0_0 = makeConstList([4, 12, 0, 0], type$.JSArray_int);
    B.List_16_0_0_0 = makeConstList([16, 0, 0, 0], type$.JSArray_int);
    B.List_12_4_0_0 = makeConstList([12, 4, 0, 0], type$.JSArray_int);
    B.List_6_6_2_2 = makeConstList([6, 6, 2, 2], type$.JSArray_int);
    B.List_3_9_1_3 = makeConstList([3, 9, 1, 3], type$.JSArray_int);
    B.List_12_0_4_0 = makeConstList([12, 0, 4, 0], type$.JSArray_int);
    B.List_9_3_3_1 = makeConstList([9, 3, 3, 1], type$.JSArray_int);
    B.List_zrs = makeConstList([B.List_4_4_4_4, B.List_2_6_2_6, B.List_8_0_8_0, B.List_6_2_6_2, B.List_2_2_6_6, B.List_1_3_3_9, B.List_4_0_12_0, B.List_3_1_9_3, B.List_8_8_0_0, B.List_4_12_0_0, B.List_16_0_0_0, B.List_12_4_0_0, B.List_6_6_2_2, B.List_3_9_1_3, B.List_12_0_4_0, B.List_9_3_3_1], type$.JSArray_List_int);
    B.Object_XVG = {ProcessingSoftware: 0, SubfileType: 1, OldSubfileType: 2, ImageWidth: 3, ImageLength: 4, ImageHeight: 5, BitsPerSample: 6, Compression: 7, PhotometricInterpretation: 8, Thresholding: 9, CellWidth: 10, CellLength: 11, FillOrder: 12, DocumentName: 13, ImageDescription: 14, Make: 15, Model: 16, StripOffsets: 17, Orientation: 18, SamplesPerPixel: 19, RowsPerStrip: 20, StripByteCounts: 21, MinSampleValue: 22, MaxSampleValue: 23, XResolution: 24, YResolution: 25, PlanarConfiguration: 26, PageName: 27, XPosition: 28, YPosition: 29, GrayResponseUnit: 30, GrayResponseCurve: 31, T4Options: 32, T6Options: 33, ResolutionUnit: 34, PageNumber: 35, ColorResponseUnit: 36, TransferFunction: 37, Software: 38, DateTime: 39, Artist: 40, HostComputer: 41, Predictor: 42, WhitePoint: 43, PrimaryChromaticities: 44, ColorMap: 45, HalftoneHints: 46, TileWidth: 47, TileLength: 48, TileOffsets: 49, TileByteCounts: 50, BadFaxLines: 51, CleanFaxData: 52, ConsecutiveBadFaxLines: 53, InkSet: 54, InkNames: 55, NumberofInks: 56, DotRange: 57, TargetPrinter: 58, ExtraSamples: 59, SampleFormat: 60, SMinSampleValue: 61, SMaxSampleValue: 62, TransferRange: 63, ClipPath: 64, JPEGProc: 65, JPEGInterchangeFormat: 66, JPEGInterchangeFormatLength: 67, YCbCrCoefficients: 68, YCbCrSubSampling: 69, YCbCrPositioning: 70, ReferenceBlackWhite: 71, ApplicationNotes: 72, Rating: 73, CFARepeatPatternDim: 74, CFAPattern: 75, BatteryLevel: 76, Copyright: 77, ExposureTime: 78, FNumber: 79, "IPTC-NAA": 80, ExifOffset: 81, InterColorProfile: 82, ExposureProgram: 83, SpectralSensitivity: 84, GPSOffset: 85, ISOSpeed: 86, OECF: 87, SensitivityType: 88, RecommendedExposureIndex: 89, ExifVersion: 90, DateTimeOriginal: 91, DateTimeDigitized: 92, OffsetTime: 93, OffsetTimeOriginal: 94, OffsetTimeDigitized: 95, ComponentsConfiguration: 96, CompressedBitsPerPixel: 97, ShutterSpeedValue: 98, ApertureValue: 99, BrightnessValue: 100, ExposureBiasValue: 101, MaxApertureValue: 102, SubjectDistance: 103, MeteringMode: 104, LightSource: 105, Flash: 106, FocalLength: 107, SubjectArea: 108, MakerNote: 109, UserComment: 110, SubSecTime: 111, SubSecTimeOriginal: 112, SubSecTimeDigitized: 113, XPTitle: 114, XPComment: 115, XPAuthor: 116, XPKeywords: 117, XPSubject: 118, FlashPixVersion: 119, ColorSpace: 120, ExifImageWidth: 121, ExifImageLength: 122, RelatedSoundFile: 123, InteroperabilityOffset: 124, FlashEnergy: 125, SpatialFrequencyResponse: 126, FocalPlaneXResolution: 127, FocalPlaneYResolution: 128, FocalPlaneResolutionUnit: 129, SubjectLocation: 130, ExposureIndex: 131, SensingMethod: 132, FileSource: 133, SceneType: 134, CVAPattern: 135, CustomRendered: 136, ExposureMode: 137, WhiteBalance: 138, DigitalZoomRatio: 139, FocalLengthIn35mmFilm: 140, SceneCaptureType: 141, GainControl: 142, Contrast: 143, Saturation: 144, Sharpness: 145, DeviceSettingDescription: 146, SubjectDistanceRange: 147, ImageUniqueID: 148, CameraOwnerName: 149, BodySerialNumber: 150, LensSpecification: 151, LensMake: 152, LensModel: 153, LensSerialNumber: 154, Gamma: 155, PrintIM: 156, Padding: 157, OffsetSchema: 158, OwnerName: 159, SerialNumber: 160, InteropIndex: 161, InteropVersion: 162, RelatedImageFileFormat: 163, RelatedImageWidth: 164, RelatedImageLength: 165, GPSVersionID: 166, GPSLatitudeRef: 167, GPSLatitude: 168, GPSLongitudeRef: 169, GPSLongitude: 170, GPSAltitudeRef: 171, GPSAltitude: 172, GPSTimeStamp: 173, GPSSatellites: 174, GPSStatus: 175, GPSMeasureMode: 176, GPSDOP: 177, GPSSpeedRef: 178, GPSSpeed: 179, GPSTrackRef: 180, GPSTrack: 181, GPSImgDirectionRef: 182, GPSImgDirection: 183, GPSMapDatum: 184, GPSDestLatitudeRef: 185, GPSDestLatitude: 186, GPSDestLongitudeRef: 187, GPSDestLongitude: 188, GPSDestBearingRef: 189, GPSDestBearing: 190, GPSDestDistanceRef: 191, GPSDestDistance: 192, GPSProcessingMethod: 193, GPSAreaInformation: 194, GPSDate: 195, GPSDifferential: 196};
    B.Map_1DOpr = new A.ConstantStringMap(B.Object_XVG, [11, 254, 255, 256, 257, 257, 258, 259, 262, 263, 264, 265, 266, 269, 270, 271, 272, 273, 274, 277, 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, 290, 291, 292, 293, 296, 297, 300, 301, 305, 306, 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, 327, 328, 332, 333, 334, 336, 337, 338, 339, 340, 341, 342, 343, 512, 513, 514, 529, 530, 531, 532, 700, 18246, 33421, 33422, 33423, 33432, 33434, 33437, 33723, 34665, 34675, 34850, 34852, 34853, 34855, 34856, 34864, 34866, 36864, 36867, 36868, 36880, 36881, 36882, 37121, 37122, 37377, 37378, 37379, 37380, 37381, 37382, 37383, 37384, 37385, 37386, 37396, 37500, 37510, 37520, 37521, 37522, 40091, 40092, 40093, 40094, 40095, 40960, 40961, 40962, 40963, 40964, 40965, 41483, 41484, 41486, 41487, 41488, 41492, 41493, 41495, 41728, 41729, 41730, 41985, 41986, 41987, 41988, 41989, 41990, 41991, 41992, 41993, 41994, 41995, 41996, 42016, 42032, 42033, 42034, 42035, 42036, 42037, 42240, 50341, 59932, 59933, 65000, 65001, 1, 2, 4096, 4097, 4098, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30], A.findType("ConstantStringMap<String,int>"));
    B.Map_vw3Ow = new A.GeneralConstantMap([B.Format_0, 1, B.Format_1, 3, B.Format_2, 15, B.Format_3, 255, B.Format_4, 65535, B.Format_5, 4294967295, B.Format_6, 127, B.Format_7, 32767, B.Format_8, 2147483647, B.Format_9, 1, B.Format_10, 1, B.Format_11, 1], type$.GeneralConstantMap_Format_int);
    B.Map_vw4lG = new A.GeneralConstantMap([B.Format_0, 1, B.Format_1, 1, B.Format_2, 1, B.Format_3, 1, B.Format_4, 2, B.Format_5, 4, B.Format_6, 1, B.Format_7, 2, B.Format_8, 4, B.Format_9, 2, B.Format_10, 4, B.Format_11, 8], type$.GeneralConstantMap_Format_int);
    B.PvrFormat_0 = new A.PvrFormat(0, "auto");
    B.PvrFormat_3 = new A.PvrFormat(3, "rgb4");
    B.PvrFormat_4 = new A.PvrFormat(4, "rgba4");
    B.TiffFormat_1 = new A.TiffFormat(1, "uint");
    B.TiffFormat_2 = new A.TiffFormat(2, "int");
    B.TiffFormat_3 = new A.TiffFormat(3, "float");
    B.Type_ByteBuffer_rqD = A.typeLiteral("ByteBuffer");
    B.Type_ByteData_9dB = A.typeLiteral("ByteData");
    B.Type_Float32List_9Kz = A.typeLiteral("Float32List");
    B.Type_Float64List_9Kz = A.typeLiteral("Float64List");
    B.Type_Int16List_s5h = A.typeLiteral("Int16List");
    B.Type_Int32List_O8Z = A.typeLiteral("Int32List");
    B.Type_Int8List_rFV = A.typeLiteral("Int8List");
    B.Type_Object_A4p = A.typeLiteral("Object");
    B.Type_Uint16List_kmP = A.typeLiteral("Uint16List");
    B.Type_Uint32List_kmP = A.typeLiteral("Uint32List");
    B.Type_Uint8ClampedList_04U = A.typeLiteral("Uint8ClampedList");
    B.Type_Uint8List_8Eb = A.typeLiteral("Uint8List");
    B._DeflateFlushMode_0 = new A._DeflateFlushMode(0, "none");
    B._DeflateFlushMode_1 = new A._DeflateFlushMode(1, "partial");
    B._DeflateFlushMode_2 = new A._DeflateFlushMode(2, "full");
    B._DeflateFlushMode_3 = new A._DeflateFlushMode(3, "finish");
  })();
  (function staticFields() {
    $._JS_INTEROP_INTERCEPTOR_TAG = null;
    $.toStringVisiting = A._setArrayType([], A.findType("JSArray<Object>"));
    $.Primitives__identityHashCodeProperty = null;
    $.BoundClosure__receiverFieldNameCache = null;
    $.BoundClosure__interceptorFieldNameCache = null;
    $.getTagFunction = null;
    $.alternateTagFunction = null;
    $.prototypeForTagFunction = null;
    $.dispatchRecordsForInstanceTags = null;
    $.interceptorsForUncacheableTags = null;
    $.initNativeDispatchFlag = null;
    $._nextCallback = null;
    $._lastCallback = null;
    $._lastPriorityCallback = null;
    $._isInCallbackLoop = false;
    $.Zone__current = B.C__RootZone;
    $.Deflate____config = A._Cell$named("_config");
    $.Float16__toFloatFloat32Data = null;
    $.Float16____eLut = A._Cell$named("_eLut");
  })();
  (function lazyInitializers() {
    var _lazyFinal = hunkHelpers.lazyFinal;
    _lazyFinal($, "DART_CLOSURE_PROPERTY_NAME", "$get$DART_CLOSURE_PROPERTY_NAME", () => A.getIsolateAffinityTag("_$dart_dartClosure"));
    _lazyFinal($, "_safeToStringHooks", "$get$_safeToStringHooks", () => A._setArrayType([new J.JSArraySafeToStringHook()], A.findType("JSArray<SafeToStringHook>")));
    _lazyFinal($, "TypeErrorDecoder_noSuchMethodPattern", "$get$TypeErrorDecoder_noSuchMethodPattern", () => A.TypeErrorDecoder_extractPattern(A.TypeErrorDecoder_provokeCallErrorOn({
      toString: function() {
        return "$receiver$";
      }
    })));
    _lazyFinal($, "TypeErrorDecoder_notClosurePattern", "$get$TypeErrorDecoder_notClosurePattern", () => A.TypeErrorDecoder_extractPattern(A.TypeErrorDecoder_provokeCallErrorOn({$method$: null,
      toString: function() {
        return "$receiver$";
      }
    })));
    _lazyFinal($, "TypeErrorDecoder_nullCallPattern", "$get$TypeErrorDecoder_nullCallPattern", () => A.TypeErrorDecoder_extractPattern(A.TypeErrorDecoder_provokeCallErrorOn(null)));
    _lazyFinal($, "TypeErrorDecoder_nullLiteralCallPattern", "$get$TypeErrorDecoder_nullLiteralCallPattern", () => A.TypeErrorDecoder_extractPattern(function() {
      var $argumentsExpr$ = "$arguments$";
      try {
        null.$method$($argumentsExpr$);
      } catch (e) {
        return e.message;
      }
    }()));
    _lazyFinal($, "TypeErrorDecoder_undefinedCallPattern", "$get$TypeErrorDecoder_undefinedCallPattern", () => A.TypeErrorDecoder_extractPattern(A.TypeErrorDecoder_provokeCallErrorOn(void 0)));
    _lazyFinal($, "TypeErrorDecoder_undefinedLiteralCallPattern", "$get$TypeErrorDecoder_undefinedLiteralCallPattern", () => A.TypeErrorDecoder_extractPattern(function() {
      var $argumentsExpr$ = "$arguments$";
      try {
        (void 0).$method$($argumentsExpr$);
      } catch (e) {
        return e.message;
      }
    }()));
    _lazyFinal($, "TypeErrorDecoder_nullPropertyPattern", "$get$TypeErrorDecoder_nullPropertyPattern", () => A.TypeErrorDecoder_extractPattern(A.TypeErrorDecoder_provokePropertyErrorOn(null)));
    _lazyFinal($, "TypeErrorDecoder_nullLiteralPropertyPattern", "$get$TypeErrorDecoder_nullLiteralPropertyPattern", () => A.TypeErrorDecoder_extractPattern(function() {
      try {
        null.$method$;
      } catch (e) {
        return e.message;
      }
    }()));
    _lazyFinal($, "TypeErrorDecoder_undefinedPropertyPattern", "$get$TypeErrorDecoder_undefinedPropertyPattern", () => A.TypeErrorDecoder_extractPattern(A.TypeErrorDecoder_provokePropertyErrorOn(void 0)));
    _lazyFinal($, "TypeErrorDecoder_undefinedLiteralPropertyPattern", "$get$TypeErrorDecoder_undefinedLiteralPropertyPattern", () => A.TypeErrorDecoder_extractPattern(function() {
      try {
        (void 0).$method$;
      } catch (e) {
        return e.message;
      }
    }()));
    _lazyFinal($, "_AsyncRun__scheduleImmediateClosure", "$get$_AsyncRun__scheduleImmediateClosure", () => A._AsyncRun__initializeScheduleImmediate());
    _lazyFinal($, "_hashSeed", "$get$_hashSeed", () => A.objectHashCode(B.Type_Object_A4p));
    _lazyFinal($, "_StaticTree_staticLDesc", "$get$_StaticTree_staticLDesc", () => A._StaticTree$(B.List_LCt, B.List_1eA, 257, 286, 15));
    _lazyFinal($, "_StaticTree_staticDDesc", "$get$_StaticTree_staticDDesc", () => A._StaticTree$(B.List_LJO, B.List_HmF, 0, 30, 15));
    _lazyFinal($, "_StaticTree_staticBlDesc", "$get$_StaticTree_staticBlDesc", () => A._StaticTree$(null, B.List_2gL, 0, 19, 7));
    _lazyFinal($, "exifImageTags", "$get$exifImageTags", () => {
      var _null = null,
        _s8_ = "ISOSpeed";
      return A.LinkedHashMap_LinkedHashMap$_literal([11, A.ExifTag$("ProcessingSoftware", B.IfdValueType_2, _null), 254, A.ExifTag$("SubfileType", B.IfdValueType_4, 1), 255, A.ExifTag$("OldSubfileType", B.IfdValueType_4, 1), 256, A.ExifTag$("ImageWidth", B.IfdValueType_4, 1), 257, A.ExifTag$("ImageLength", B.IfdValueType_4, 1), 258, A.ExifTag$("BitsPerSample", B.IfdValueType_3, 1), 259, A.ExifTag$("Compression", B.IfdValueType_3, 1), 262, A.ExifTag$("PhotometricInterpretation", B.IfdValueType_3, 1), 263, A.ExifTag$("Thresholding", B.IfdValueType_3, 1), 264, A.ExifTag$("CellWidth", B.IfdValueType_3, 1), 265, A.ExifTag$("CellLength", B.IfdValueType_3, 1), 266, A.ExifTag$("FillOrder", B.IfdValueType_3, 1), 269, A.ExifTag$("DocumentName", B.IfdValueType_2, _null), 270, A.ExifTag$("ImageDescription", B.IfdValueType_2, _null), 271, A.ExifTag$("Make", B.IfdValueType_2, _null), 272, A.ExifTag$("Model", B.IfdValueType_2, _null), 273, A.ExifTag$("StripOffsets", B.IfdValueType_4, _null), 274, A.ExifTag$("Orientation", B.IfdValueType_3, 1), 277, A.ExifTag$("SamplesPerPixel", B.IfdValueType_3, 1), 278, A.ExifTag$("RowsPerStrip", B.IfdValueType_4, 1), 279, A.ExifTag$("StripByteCounts", B.IfdValueType_4, 1), 280, A.ExifTag$("MinSampleValue", B.IfdValueType_3, 1), 281, A.ExifTag$("MaxSampleValue", B.IfdValueType_3, 1), 282, A.ExifTag$("XResolution", B.IfdValueType_5, 1), 283, A.ExifTag$("YResolution", B.IfdValueType_5, 1), 284, A.ExifTag$("PlanarConfiguration", B.IfdValueType_3, 1), 285, A.ExifTag$("PageName", B.IfdValueType_2, _null), 286, A.ExifTag$("XPosition", B.IfdValueType_5, 1), 287, A.ExifTag$("YPosition", B.IfdValueType_5, 1), 290, A.ExifTag$("GrayResponseUnit", B.IfdValueType_3, 1), 291, A.ExifTag$("GrayResponseCurve", B.IfdValueType_0, _null), 292, A.ExifTag$("T4Options", B.IfdValueType_0, _null), 293, A.ExifTag$("T6Options", B.IfdValueType_0, _null), 296, A.ExifTag$("ResolutionUnit", B.IfdValueType_3, 1), 297, A.ExifTag$("PageNumber", B.IfdValueType_3, 2), 300, A.ExifTag$("ColorResponseUnit", B.IfdValueType_0, _null), 301, A.ExifTag$("TransferFunction", B.IfdValueType_3, 768), 305, A.ExifTag$("Software", B.IfdValueType_2, _null), 306, A.ExifTag$("DateTime", B.IfdValueType_2, _null), 315, A.ExifTag$("Artist", B.IfdValueType_2, _null), 316, A.ExifTag$("HostComputer", B.IfdValueType_2, _null), 317, A.ExifTag$("Predictor", B.IfdValueType_3, 1), 318, A.ExifTag$("WhitePoint", B.IfdValueType_5, 2), 319, A.ExifTag$("PrimaryChromaticities", B.IfdValueType_5, 6), 320, A.ExifTag$("ColorMap", B.IfdValueType_3, _null), 321, A.ExifTag$("HalftoneHints", B.IfdValueType_3, 2), 322, A.ExifTag$("TileWidth", B.IfdValueType_4, 1), 323, A.ExifTag$("TileLength", B.IfdValueType_4, 1), 324, A.ExifTag$("TileOffsets", B.IfdValueType_4, _null), 325, A.ExifTag$("TileByteCounts", B.IfdValueType_0, _null), 326, A.ExifTag$("BadFaxLines", B.IfdValueType_0, _null), 327, A.ExifTag$("CleanFaxData", B.IfdValueType_0, _null), 328, A.ExifTag$("ConsecutiveBadFaxLines", B.IfdValueType_0, _null), 332, A.ExifTag$("InkSet", B.IfdValueType_0, _null), 333, A.ExifTag$("InkNames", B.IfdValueType_0, _null), 334, A.ExifTag$("NumberofInks", B.IfdValueType_0, _null), 336, A.ExifTag$("DotRange", B.IfdValueType_0, _null), 337, A.ExifTag$("TargetPrinter", B.IfdValueType_2, _null), 338, A.ExifTag$("ExtraSamples", B.IfdValueType_0, _null), 339, A.ExifTag$("SampleFormat", B.IfdValueType_3, 1), 340, A.ExifTag$("SMinSampleValue", B.IfdValueType_0, _null), 341, A.ExifTag$("SMaxSampleValue", B.IfdValueType_0, _null), 342, A.ExifTag$("TransferRange", B.IfdValueType_0, _null), 343, A.ExifTag$("ClipPath", B.IfdValueType_0, _null), 512, A.ExifTag$("JPEGProc", B.IfdValueType_0, _null), 513, A.ExifTag$("JPEGInterchangeFormat", B.IfdValueType_0, _null), 514, A.ExifTag$("JPEGInterchangeFormatLength", B.IfdValueType_0, _null), 529, A.ExifTag$("YCbCrCoefficients", B.IfdValueType_5, 3), 530, A.ExifTag$("YCbCrSubSampling", B.IfdValueType_3, 1), 531, A.ExifTag$("YCbCrPositioning", B.IfdValueType_3, 1), 532, A.ExifTag$("ReferenceBlackWhite", B.IfdValueType_5, 6), 700, A.ExifTag$("ApplicationNotes", B.IfdValueType_3, 1), 18246, A.ExifTag$("Rating", B.IfdValueType_3, 1), 33421, A.ExifTag$("CFARepeatPatternDim", B.IfdValueType_0, _null), 33422, A.ExifTag$("CFAPattern", B.IfdValueType_0, _null), 33423, A.ExifTag$("BatteryLevel", B.IfdValueType_0, _null), 33432, A.ExifTag$("Copyright", B.IfdValueType_2, _null), 33434, A.ExifTag$("ExposureTime", B.IfdValueType_5, 1), 33437, A.ExifTag$("FNumber", B.IfdValueType_5, _null), 33723, A.ExifTag$("IPTC-NAA", B.IfdValueType_4, 1), 34665, A.ExifTag$("ExifOffset", B.IfdValueType_0, _null), 34675, A.ExifTag$("InterColorProfile", B.IfdValueType_0, _null), 34850, A.ExifTag$("ExposureProgram", B.IfdValueType_3, 1), 34852, A.ExifTag$("SpectralSensitivity", B.IfdValueType_2, _null), 34853, A.ExifTag$("GPSOffset", B.IfdValueType_0, _null), 34855, A.ExifTag$(_s8_, B.IfdValueType_4, 1), 34856, A.ExifTag$("OECF", B.IfdValueType_0, _null), 34864, A.ExifTag$("SensitivityType", B.IfdValueType_3, 1), 34866, A.ExifTag$("RecommendedExposureIndex", B.IfdValueType_4, 1), 34867, A.ExifTag$(_s8_, B.IfdValueType_4, 1), 36864, A.ExifTag$("ExifVersion", B.IfdValueType_7, _null), 36867, A.ExifTag$("DateTimeOriginal", B.IfdValueType_2, _null), 36868, A.ExifTag$("DateTimeDigitized", B.IfdValueType_2, _null), 36880, A.ExifTag$("OffsetTime", B.IfdValueType_2, _null), 36881, A.ExifTag$("OffsetTimeOriginal", B.IfdValueType_2, _null), 36882, A.ExifTag$("OffsetTimeDigitized", B.IfdValueType_2, _null), 37121, A.ExifTag$("ComponentsConfiguration", B.IfdValueType_7, _null), 37122, A.ExifTag$("CompressedBitsPerPixel", B.IfdValueType_0, _null), 37377, A.ExifTag$("ShutterSpeedValue", B.IfdValueType_0, _null), 37378, A.ExifTag$("ApertureValue", B.IfdValueType_0, _null), 37379, A.ExifTag$("BrightnessValue", B.IfdValueType_0, _null), 37380, A.ExifTag$("ExposureBiasValue", B.IfdValueType_0, _null), 37381, A.ExifTag$("MaxApertureValue", B.IfdValueType_0, _null), 37382, A.ExifTag$("SubjectDistance", B.IfdValueType_0, _null), 37383, A.ExifTag$("MeteringMode", B.IfdValueType_0, _null), 37384, A.ExifTag$("LightSource", B.IfdValueType_0, _null), 37385, A.ExifTag$("Flash", B.IfdValueType_0, _null), 37386, A.ExifTag$("FocalLength", B.IfdValueType_0, _null), 37396, A.ExifTag$("SubjectArea", B.IfdValueType_0, _null), 37500, A.ExifTag$("MakerNote", B.IfdValueType_7, _null), 37510, A.ExifTag$("UserComment", B.IfdValueType_7, _null), 37520, A.ExifTag$("SubSecTime", B.IfdValueType_0, _null), 37521, A.ExifTag$("SubSecTimeOriginal", B.IfdValueType_0, _null), 37522, A.ExifTag$("SubSecTimeDigitized", B.IfdValueType_0, _null), 40091, A.ExifTag$("XPTitle", B.IfdValueType_0, _null), 40092, A.ExifTag$("XPComment", B.IfdValueType_0, _null), 40093, A.ExifTag$("XPAuthor", B.IfdValueType_0, _null), 40094, A.ExifTag$("XPKeywords", B.IfdValueType_0, _null), 40095, A.ExifTag$("XPSubject", B.IfdValueType_0, _null), 40960, A.ExifTag$("FlashPixVersion", B.IfdValueType_0, _null), 40961, A.ExifTag$("ColorSpace", B.IfdValueType_3, 1), 40962, A.ExifTag$("ExifImageWidth", B.IfdValueType_3, 1), 40963, A.ExifTag$("ExifImageLength", B.IfdValueType_3, 1), 40964, A.ExifTag$("RelatedSoundFile", B.IfdValueType_0, _null), 40965, A.ExifTag$("InteroperabilityOffset", B.IfdValueType_0, _null), 41483, A.ExifTag$("FlashEnergy", B.IfdValueType_0, _null), 41484, A.ExifTag$("SpatialFrequencyResponse", B.IfdValueType_0, _null), 41486, A.ExifTag$("FocalPlaneXResolution", B.IfdValueType_0, _null), 41487, A.ExifTag$("FocalPlaneYResolution", B.IfdValueType_0, _null), 41488, A.ExifTag$("FocalPlaneResolutionUnit", B.IfdValueType_0, _null), 41492, A.ExifTag$("SubjectLocation", B.IfdValueType_0, _null), 41493, A.ExifTag$("ExposureIndex", B.IfdValueType_0, _null), 41495, A.ExifTag$("SensingMethod", B.IfdValueType_0, _null), 41728, A.ExifTag$("FileSource", B.IfdValueType_0, _null), 41729, A.ExifTag$("SceneType", B.IfdValueType_0, _null), 41730, A.ExifTag$("CVAPattern", B.IfdValueType_0, _null), 41985, A.ExifTag$("CustomRendered", B.IfdValueType_0, _null), 41986, A.ExifTag$("ExposureMode", B.IfdValueType_0, _null), 41987, A.ExifTag$("WhiteBalance", B.IfdValueType_0, _null), 41988, A.ExifTag$("DigitalZoomRatio", B.IfdValueType_0, _null), 41989, A.ExifTag$("FocalLengthIn35mmFilm", B.IfdValueType_0, _null), 41990, A.ExifTag$("SceneCaptureType", B.IfdValueType_0, _null), 41991, A.ExifTag$("GainControl", B.IfdValueType_0, _null), 41992, A.ExifTag$("Contrast", B.IfdValueType_0, _null), 41993, A.ExifTag$("Saturation", B.IfdValueType_0, _null), 41994, A.ExifTag$("Sharpness", B.IfdValueType_0, _null), 41995, A.ExifTag$("DeviceSettingDescription", B.IfdValueType_0, _null), 41996, A.ExifTag$("SubjectDistanceRange", B.IfdValueType_0, _null), 42016, A.ExifTag$("ImageUniqueID", B.IfdValueType_0, _null), 42032, A.ExifTag$("CameraOwnerName", B.IfdValueType_2, _null), 42033, A.ExifTag$("BodySerialNumber", B.IfdValueType_2, _null), 42034, A.ExifTag$("LensSpecification", B.IfdValueType_0, _null), 42035, A.ExifTag$("LensMake", B.IfdValueType_2, _null), 42036, A.ExifTag$("LensModel", B.IfdValueType_2, _null), 42037, A.ExifTag$("LensSerialNumber", B.IfdValueType_2, _null), 42240, A.ExifTag$("Gamma", B.IfdValueType_5, 1), 50341, A.ExifTag$("PrintIM", B.IfdValueType_0, _null), 59932, A.ExifTag$("Padding", B.IfdValueType_0, _null), 59933, A.ExifTag$("OffsetSchema", B.IfdValueType_0, _null), 65000, A.ExifTag$("OwnerName", B.IfdValueType_2, _null), 65001, A.ExifTag$("SerialNumber", B.IfdValueType_2, _null)], type$.int, A.findType("ExifTag"));
    });
    _lazyFinal($, "__int32", "$get$__int32", () => A.NativeInt32List_NativeInt32List(1));
    _lazyFinal($, "__int32ToUint32", "$get$__int32ToUint32", () => A.Uint32List_Uint32List$view(B.NativeInt32List_methods.get$buffer($.$get$__int32())));
    _lazyFinal($, "__float32", "$get$__float32", () => A.NativeFloat32List_NativeFloat32List(1));
    _lazyFinal($, "__float32ToUint32", "$get$__float32ToUint32", () => A.Uint32List_Uint32List$view(B.NativeFloat32List_methods.get$buffer($.$get$__float32())));
  })();
  (function nativeSupport() {
    !function() {
      var intern = function(s) {
        var o = {};
        o[s] = 1;
        return Object.keys(hunkHelpers.convertToFastObject(o))[0];
      };
      init.getIsolateTag = function(name) {
        return intern("___dart_" + name + init.isolateTag);
      };
      var tableProperty = "___dart_isolate_tags_";
      var usedProperties = Object[tableProperty] || (Object[tableProperty] = Object.create(null));
      var rootProperty = "_ZxYxX";
      for (var i = 0;; i++) {
        var property = intern(rootProperty + "_" + i + "_");
        if (!(property in usedProperties)) {
          usedProperties[property] = 1;
          init.isolateTag = property;
          break;
        }
      }
      init.dispatchPropertyName = init.getIsolateTag("dispatch_record");
    }();
    hunkHelpers.setOrUpdateInterceptorsByTag({SharedArrayBuffer: A.NativeByteBuffer, ArrayBuffer: A.NativeArrayBuffer, ArrayBufferView: A.NativeTypedData, DataView: A.NativeByteData, Float32Array: A.NativeFloat32List, Float64Array: A.NativeFloat64List, Int16Array: A.NativeInt16List, Int32Array: A.NativeInt32List, Int8Array: A.NativeInt8List, Uint16Array: A.NativeUint16List, Uint32Array: A.NativeUint32List, Uint8ClampedArray: A.NativeUint8ClampedList, CanvasPixelArray: A.NativeUint8ClampedList, Uint8Array: A.NativeUint8List});
    hunkHelpers.setOrUpdateLeafTags({SharedArrayBuffer: true, ArrayBuffer: true, ArrayBufferView: false, DataView: true, Float32Array: true, Float64Array: true, Int16Array: true, Int32Array: true, Int8Array: true, Uint16Array: true, Uint32Array: true, Uint8ClampedArray: true, CanvasPixelArray: true, Uint8Array: false});
    A.NativeTypedArray.$nativeSuperclassTag = "ArrayBufferView";
    A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin.$nativeSuperclassTag = "ArrayBufferView";
    A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin.$nativeSuperclassTag = "ArrayBufferView";
    A.NativeTypedArrayOfDouble.$nativeSuperclassTag = "ArrayBufferView";
    A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin.$nativeSuperclassTag = "ArrayBufferView";
    A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin.$nativeSuperclassTag = "ArrayBufferView";
    A.NativeTypedArrayOfInt.$nativeSuperclassTag = "ArrayBufferView";
  })();
  Function.prototype.call$0 = function() {
    return this();
  };
  Function.prototype.call$1 = function(a) {
    return this(a);
  };
  Function.prototype.call$2 = function(a, b) {
    return this(a, b);
  };
  Function.prototype.call$3 = function(a, b, c) {
    return this(a, b, c);
  };
  Function.prototype.call$4 = function(a, b, c, d) {
    return this(a, b, c, d);
  };
  Function.prototype.call$1$1 = function(a) {
    return this(a);
  };
  Function.prototype.call$2$1 = function(a) {
    return this(a);
  };
  convertAllToFastObject(holders);
  convertToFastObject($);
  (function(callback) {
    if (typeof document === "undefined") {
      callback(null);
      return;
    }
    if (typeof document.currentScript != "undefined") {
      callback(document.currentScript);
      return;
    }
    var scripts = document.scripts;
    function onLoad(event) {
      for (var i = 0; i < scripts.length; ++i) {
        scripts[i].removeEventListener("load", onLoad, false);
      }
      callback(event.target);
    }
    for (var i = 0; i < scripts.length; ++i) {
      scripts[i].addEventListener("load", onLoad, false);
    }
  })(function(currentScript) {
    init.currentScript = currentScript;
    var callMain = A.main;
    if (typeof dartMainRunner === "function") {
      dartMainRunner(callMain, []);
    } else {
      callMain([]);
    }
  });
})();

//# sourceMappingURL=web_worker.dart.js.map
