!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.util=e():(t.tui=t.tui||{},t.tui.util=e())}(this,function(){return r=[function(t,e,n){"use strict";var r={},o=n(1),i=o.extend;i(r,o),i(r,n(3)),i(r,n(2)),i(r,n(4)),i(r,n(5)),i(r,n(6)),i(r,n(7)),i(r,n(8)),i(r,n(9)),r.browser=n(10),r.popup=n(11),r.formatDate=n(12),r.defineClass=n(13),r.defineModule=n(14),r.defineNamespace=n(15),r.CustomEvents=n(16),r.Enum=n(17),r.ExMap=n(18),r.HashMap=n(20),r.Map=n(19),t.exports=r},function(t,e,n){"use strict";var u=n(2),s=n(3),r=0;function o(t,e){for(var n=arguments,r=n[0],o=1,i=n.length;o","'":"'"," ":" "};return t.replace(/&|<|>|"|'| /g,function(t){return e[t]||t})},encodeHTMLEntity:function(t){var e={'"':"quot","&":"amp","<":"lt",">":"gt","'":"#39"};return t.replace(/[<>&"']/g,function(t){return e[t]?"&"+e[t]+";":t})},hasEncodableString:function(t){return/[<>&"']/.test(t)},getDuplicatedChar:function(t,e){for(var n,r=0,o=t.length,i={};r=this._length?t.done=!0:(t.done=!1,t.value=this._valueGetter(this._keys[this._index],this._index)),t},f.prototype._setInitData=function(t){if(!o.isArray(t))throw new Error("Only Array is supported.");r.forEachArray(t,function(t){this.set(t[0],t[1])},this)},f.prototype._isNaN=function(t){return"number"==typeof t&&t!=t},f.prototype._getKeyIndex=function(t){var e,n=-1;return o.isString(t)?(e=this._valuesForString[t])&&(n=e.keyIndex):n=i.inArray(t,this._keys),n},f.prototype._getOriginKey=function(t){var e=t;return t===c?e=void 0:t===a&&(e=NaN),e},f.prototype._getUniqueKey=function(t){var e=t;return o.isUndefined(t)?e=c:this._isNaN(t)&&(e=a),e},f.prototype._getValueObject=function(t,e){return o.isString(t)?this._valuesForString[t]:0<=(e=o.isUndefined(e)?this._getKeyIndex(t):e)?this._valuesForIndex[e]:void 0},f.prototype._getOriginValue=function(t,e){return this._getValueObject(t,e).origin},f.prototype._getKeyValuePair=function(t,e){return[this._getOriginKey(t),this._getOriginValue(t,e)]},f.prototype._createValueObject=function(t,e){return{keyIndex:e,origin:t}},f.prototype.set=function(t,e){var n=this._getUniqueKey(t),r=this._getKeyIndex(n);return r<0&&(r=this._keys.push(n)-1,this.size+=1),n=this._createValueObject(e,r),o.isString(t)?this._valuesForString[t]=n:this._valuesForIndex[r]=n,this},f.prototype.get=function(t){t=this._getUniqueKey(t),t=this._getValueObject(t);return t&&t.origin},f.prototype.keys=function(){return new p(this._keys,s.bind(this._getOriginKey,this))},f.prototype.values=function(){return new p(this._keys,s.bind(this._getOriginValue,this))},f.prototype.entries=function(){return new p(this._keys,s.bind(this._getKeyValuePair,this))},f.prototype.has=function(t){return!!this._getValueObject(t)},f.prototype.delete=function(t){var e;o.isString(t)?this._valuesForString[t]&&(e=this._valuesForString[t].keyIndex,delete this._valuesForString[t]):0<=(e=this._getKeyIndex(t))&&delete this._valuesForIndex[e],0<=e&&(delete this._keys[e],--this.size)},f.prototype.forEach=function(e,n){n=n||this,r.forEachArray(this._keys,function(t){o.isUndefined(t)||e.call(n,this._getValueObject(t).origin,t,this)},this)},f.prototype.clear=function(){f.call(this)},window.Map&&(u.firefox&&37<=u.version||u.chrome&&42<=u.version)&&(f=window.Map),t.exports=f},function(t,e,n){"use strict";var i=n(4),r=n(2);function o(t){this.length=0,t&&this.setObject(t)}o.prototype.set=function(t,e){2===arguments.length?this.setKeyValue(t,e):this.setObject(t)},o.prototype.setKeyValue=function(t,e){this.has(t)||(this.length+=1),this[this.encodeKey(t)]=e},o.prototype.setObject=function(t){var n=this;i.forEachOwnProperties(t,function(t,e){n.setKeyValue(e,t)})},o.prototype.merge=function(t){var n=this;t.each(function(t,e){n.setKeyValue(e,t)})},o.prototype.encodeKey=function(t){return"å"+t},o.prototype.decodeKey=function(t){t=t.split("å");return t[t.length-1]},o.prototype.get=function(t){return this[this.encodeKey(t)]},o.prototype.has=function(t){return this.hasOwnProperty(this.encodeKey(t))},o.prototype.remove=function(t){return 1