const googObject = {};
googObject.is = function(a, b) {
    return a === b ? 0 !== a || 1 / a === 1 / b : a !== a && b !== b
};
googObject.forEach = function(a, b, c) {
    for (var d in a)
        b.call(c, a[d], d, a)
};
googObject.filter = function(a, b, c) {
    var d = {},
        e;
    for (e in a)
        b.call(c, a[e], e, a) && (d[e] = a[e]);
    return d
};
googObject.map = function(a, b, c) {
    var d = {},
        e;
    for (e in a)
        d[e] = b.call(c, a[e], e, a);
    return d
};
googObject.some = function(a, b, c) {
    for (var d in a)
        if (b.call(c, a[d], d, a))
            return !0;
    return !1
};
googObject.every = function(a, b, c) {
    for (var d in a)
        if (!b.call(c, a[d], d, a))
            return !1;
    return !0
};
googObject.getCount = function(a) {
    var b = 0,
        c;
    for (c in a)
        b++;
    return b
};
googObject.getAnyKey = function(a) {
    for (var b in a)
        return b
};
googObject.getAnyValue = function(a) {
    for (var b in a)
        return a[b]
};
googObject.contains = function(a, b) {
    return googObject.containsValue(a, b)
};
googObject.getValues = function(a) {
    var b = [],
        c = 0,
        d;
    for (d in a)
        b[c++] = a[d];
    return b
};
googObject.getKeys = function(a) {
    var b = [],
        c = 0,
        d;
    for (d in a)
        b[c++] = d;
    return b
};
googObject.getValueByKeys = function(a, b) {
    var c = goog.isArrayLike(b),
        d = c ? b : arguments;
    for (c = c ? 0 : 1; c < d.length; c++) {
        if (null == a)
            return;
        a = a[d[c]]
    }
    return a
};
googObject.containsKey = function(a, b) {
    return null !== a && b in a
};
googObject.containsValue = function(a, b) {
    for (var c in a)
        if (a[c] == b)
            return !0;
    return !1
};
googObject.findKey = function(a, b, c) {
    for (var d in a)
        if (b.call(c, a[d], d, a))
            return d
};
googObject.findValue = function(a, b, c) {
    return (b = googObject.findKey(a, b, c)) && a[b]
};
googObject.isEmpty = function(a) {
    for (var b in a)
        return !1;
    return !0
};
googObject.clear = function(a) {
    for (var b in a)
        delete a[b]
};
googObject.remove = function(a, b) {
    var c;
    (c = b in a) && delete a[b];
    return c
};
googObject.add = function(a, b, c) {
    if (null !== a && b in a)
        throw Error('The object already contains the key "' + b + '"');
    googObject.set(a, b, c)
};
googObject.get = function(a, b, c) {
    return null !== a && b in a ? a[b] : c
};
googObject.set = function(a, b, c) {
    a[b] = c
};
googObject.setIfUndefined = function(a, b, c) {
    return b in a ? a[b] : a[b] = c
};
googObject.setWithReturnValueIfNotSet = function(a, b, c) {
    if (b in a)
        return a[b];
    c = c();
    return a[b] = c
};
googObject.equals = function(a, b) {
    for (var c in a)
        if (!(c in b) || a[c] !== b[c])
            return !1;
    for (var d in b)
        if (!(d in a))
            return !1;
    return !0
};
googObject.clone = function(a) {
    var b = {},
        c;
    for (c in a)
        b[c] = a[c];
    return b
};
googObject.unsafeClone = function(a) {
    var b = goog.typeOf(a);
    if ("object" == b || "array" == b) {
        if (goog.isFunction(a.clone))
            return a.clone();
        b = "array" == b ? [] : {};
        for (var c in a)
            b[c] = googObject.unsafeClone(a[c]);
        return b
    }
    return a
};
googObject.transpose = function(a) {
    var b = {},
        c;
    for (c in a)
        b[a[c]] = c;
    return b
};
googObject.PROTOTYPE_FIELDS_ = "constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");
googObject.extend = function(a, b) {
    for (var c, d, e = 1; e < arguments.length; e++) {
        d = arguments[e];
        for (c in d)
            a[c] = d[c];
        for (var f = 0; f < googObject.PROTOTYPE_FIELDS_.length; f++)
            c = googObject.PROTOTYPE_FIELDS_[f],
            Object.prototype.hasOwnProperty.call(d, c) && (a[c] = d[c])
    }
};
googObject.create = function(a) {
    var b = arguments.length;
    if (1 == b && goog.isArray(arguments[0]))
        return googObject.create.apply(null, arguments[0]);
    if (b % 2)
        throw Error("Uneven number of arguments");
    for (var c = {}, d = 0; d < b; d += 2)
        c[arguments[d]] = arguments[d + 1];
    return c
};
googObject.createSet = function(a) {
    var b = arguments.length;
    if (1 == b && goog.isArray(arguments[0]))
        return googObject.createSet.apply(null, arguments[0]);
    for (var c = {}, d = 0; d < b; d++)
        c[arguments[d]] = !0;
    return c
};
googObject.createImmutableView = function(a) {
    var b = a;
    Object.isFrozen && !Object.isFrozen(a) && (b = Object.create(a),
        Object.freeze(b));
    return b
};
googObject.isImmutableView = function(a) {
    return !!Object.isFrozen && Object.isFrozen(a)
};
googObject.getAllPropertyNames = function(a, b, c) {
    if (!a)
        return [];
    if (!Object.getOwnPropertyNames || !Object.getPrototypeOf)
        return googObject.getKeys(a);
    for (var d = {}; a && (a !== Object.prototype || b) && (a !== Function.prototype || c);) {
        for (var e = Object.getOwnPropertyNames(a), f = 0; f < e.length; f++)
            d[e[f]] = !0;
        a = Object.getPrototypeOf(a)
    }
    return googObject.getKeys(d)
};
googObject.getSuperClass = function(a) {
    return (a = Object.getPrototypeOf(a.prototype)) && a.constructor
};