(function (_, kotlin_kotlin) {
  'use strict';
  //region block: imports
  var Unit_getInstance = kotlin_kotlin.$_$.i6;
  var VOID = kotlin_kotlin.$_$.g;
  var ArrayList_init_$Create$ = kotlin_kotlin.$_$.p;
  var ensureNotNull = kotlin_kotlin.$_$.in;
  var toSet = kotlin_kotlin.$_$.uc;
  var protoOf = kotlin_kotlin.$_$.bg;
  var toInt = kotlin_kotlin.$_$.vk;
  var toIntOrNull = kotlin_kotlin.$_$.uk;
  var toLong = kotlin_kotlin.$_$.yk;
  var toLongOrNull = kotlin_kotlin.$_$.xk;
  var toDouble = kotlin_kotlin.$_$.sk;
  var toDoubleOrNull = kotlin_kotlin.$_$.rk;
  var toBoolean = kotlin_kotlin.$_$.ok;
  var classMeta = kotlin_kotlin.$_$.me;
  var setMetadataFor = kotlin_kotlin.$_$.cg;
  var objectMeta = kotlin_kotlin.$_$.ag;
  var interfaceMeta = kotlin_kotlin.$_$.cf;
  //endregion
  //region block: pre-declaration
  setMetadataFor(Settings, 'Settings', interfaceMeta);
  setMetadataFor(StorageSettings, 'StorageSettings', classMeta, VOID, [Settings], StorageSettings);
  setMetadataFor(Companion, 'Companion', objectMeta);
  function create$default(name, $super) {
    name = name === VOID ? null : name;
    return $super === VOID ? this.create_9xd763_k$(name) : $super.create_9xd763_k$.call(this, name);
  }
  setMetadataFor(Factory, 'Factory', interfaceMeta);
  //endregion
  function _get_delegate__idh0py($this) {
    return $this.delegate_1;
  }
  function StorageSettings(delegate) {
    var tmp;
    if (delegate === VOID) {
      // Inline function 'com.russhwolf.settings.localStorage' call
      tmp = localStorage;
    } else {
      tmp = delegate;
    }
    delegate = tmp;
    this.delegate_1 = delegate;
  }
  protoOf(StorageSettings).get_keys_wop4xp_k$ = function () {
    // Inline function 'kotlin.collections.List' call
    // Inline function 'kotlin.collections.MutableList' call
    var size = this.get_size_woubt6_k$();
    var list = ArrayList_init_$Create$(size);
    // Inline function 'kotlin.repeat' call
    // Inline function 'kotlin.contracts.contract' call
    var inductionVariable = 0;
    if (inductionVariable < size)
      do {
        var index = inductionVariable;
        inductionVariable = inductionVariable + 1 | 0;
        // Inline function 'kotlin.collections.MutableList.<anonymous>' call
        // Inline function 'com.russhwolf.settings.StorageSettings.<get-keys>.<anonymous>' call
        var tmp$ret$0 = ensureNotNull(this.delegate_1.key(index));
        list.add_utx5q5_k$(tmp$ret$0);
      }
       while (inductionVariable < size);
    return toSet(list);
  };
  protoOf(StorageSettings).get_size_woubt6_k$ = function () {
    return this.delegate_1.length;
  };
  protoOf(StorageSettings).clear_j9egeb_k$ = function () {
    return this.delegate_1.clear();
  };
  protoOf(StorageSettings).remove_6241ba_k$ = function (key) {
    return this.delegate_1.removeItem(key);
  };
  protoOf(StorageSettings).hasKey_eh4zcl_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    return !(this.delegate_1.getItem(key) == null);
  };
  protoOf(StorageSettings).putInt_yr2eaa_k$ = function (key, value) {
    // Inline function 'com.russhwolf.settings.set' call
    var this_0 = this.delegate_1;
    var value_0 = value.toString();
    this_0.setItem(key, value_0);
  };
  protoOf(StorageSettings).getInt_2td1pl_k$ = function (key, defaultValue) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : toInt(tmp0_safe_receiver);
    return tmp1_elvis_lhs == null ? defaultValue : tmp1_elvis_lhs;
  };
  protoOf(StorageSettings).getIntOrNull_k6b6a1_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    return tmp0_safe_receiver == null ? null : toIntOrNull(tmp0_safe_receiver);
  };
  protoOf(StorageSettings).putLong_nzmv01_k$ = function (key, value) {
    // Inline function 'com.russhwolf.settings.set' call
    var this_0 = this.delegate_1;
    var value_0 = value.toString();
    this_0.setItem(key, value_0);
  };
  protoOf(StorageSettings).getLong_peyug6_k$ = function (key, defaultValue) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : toLong(tmp0_safe_receiver);
    return tmp1_elvis_lhs == null ? defaultValue : tmp1_elvis_lhs;
  };
  protoOf(StorageSettings).getLongOrNull_gj71ya_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    return tmp0_safe_receiver == null ? null : toLongOrNull(tmp0_safe_receiver);
  };
  protoOf(StorageSettings).putString_q7x3bk_k$ = function (key, value) {
    // Inline function 'com.russhwolf.settings.set' call
    this.delegate_1.setItem(key, value);
  };
  protoOf(StorageSettings).getString_27nxc7_k$ = function (key, defaultValue) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_elvis_lhs = this.delegate_1.getItem(key);
    return tmp0_elvis_lhs == null ? defaultValue : tmp0_elvis_lhs;
  };
  protoOf(StorageSettings).getStringOrNull_w9a5ex_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    return this.delegate_1.getItem(key);
  };
  protoOf(StorageSettings).putFloat_g52tvf_k$ = function (key, value) {
    // Inline function 'com.russhwolf.settings.set' call
    var this_0 = this.delegate_1;
    var value_0 = value.toString();
    this_0.setItem(key, value_0);
  };
  protoOf(StorageSettings).getFloat_fcwboc_k$ = function (key, defaultValue) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    var tmp;
    if (tmp0_safe_receiver == null) {
      tmp = null;
    } else {
      // Inline function 'kotlin.text.toFloat' call
      // Inline function 'kotlin.js.unsafeCast' call
      // Inline function 'kotlin.js.asDynamic' call
      tmp = toDouble(tmp0_safe_receiver);
    }
    var tmp1_elvis_lhs = tmp;
    return tmp1_elvis_lhs == null ? defaultValue : tmp1_elvis_lhs;
  };
  protoOf(StorageSettings).getFloatOrNull_6pnqqy_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    var tmp;
    if (tmp0_safe_receiver == null) {
      tmp = null;
    } else {
      // Inline function 'kotlin.text.toFloatOrNull' call
      // Inline function 'kotlin.js.unsafeCast' call
      // Inline function 'kotlin.js.asDynamic' call
      tmp = toDoubleOrNull(tmp0_safe_receiver);
    }
    return tmp;
  };
  protoOf(StorageSettings).putDouble_go8clg_k$ = function (key, value) {
    // Inline function 'com.russhwolf.settings.set' call
    var this_0 = this.delegate_1;
    var value_0 = value.toString();
    this_0.setItem(key, value_0);
  };
  protoOf(StorageSettings).getDouble_x004j1_k$ = function (key, defaultValue) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : toDouble(tmp0_safe_receiver);
    return tmp1_elvis_lhs == null ? defaultValue : tmp1_elvis_lhs;
  };
  protoOf(StorageSettings).getDoubleOrNull_9teqll_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    return tmp0_safe_receiver == null ? null : toDoubleOrNull(tmp0_safe_receiver);
  };
  protoOf(StorageSettings).putBoolean_wwpo7g_k$ = function (key, value) {
    // Inline function 'com.russhwolf.settings.set' call
    var this_0 = this.delegate_1;
    var value_0 = value.toString();
    this_0.setItem(key, value_0);
  };
  protoOf(StorageSettings).getBoolean_95o09p_k$ = function (key, defaultValue) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : toBoolean(tmp0_safe_receiver);
    return tmp1_elvis_lhs == null ? defaultValue : tmp1_elvis_lhs;
  };
  protoOf(StorageSettings).getBooleanOrNull_qz9oyq_k$ = function (key) {
    // Inline function 'com.russhwolf.settings.get' call
    var tmp0_safe_receiver = this.delegate_1.getItem(key);
    return tmp0_safe_receiver == null ? null : toBoolean(tmp0_safe_receiver);
  };
  function get(_this__u8e3s4, key) {
    return _this__u8e3s4.getItem(key);
  }
  function set(_this__u8e3s4, key, value) {
    return _this__u8e3s4.setItem(key, value);
  }
  function set_0(_this__u8e3s4, key, value) {
    return _this__u8e3s4.putString_q7x3bk_k$(key, value);
  }
  function set_1(_this__u8e3s4, key, value) {
    return _this__u8e3s4.putBoolean_wwpo7g_k$(key, value);
  }
  function get_0(_this__u8e3s4, key, defaultValue) {
    return _this__u8e3s4.getInt_2td1pl_k$(key, defaultValue);
  }
  function Companion() {
    Companion_instance = this;
  }
  var Companion_instance;
  function Companion_getInstance() {
    if (Companion_instance == null)
      new Companion();
    return Companion_instance;
  }
  function Factory() {
  }
  function Settings() {
  }
  function get_localStorage() {
    return localStorage;
  }
  //region block: exports
  _.$_$ = _.$_$ || {};
  _.$_$.a = Settings;
  _.$_$.b = StorageSettings;
  //endregion
  return _;
}(module.exports, require('./kotlin-kotlin-stdlib.js')));

//# sourceMappingURL=MultiplatformSettings-multiplatform-settings.js.map
