if(!Array.forEach)Array.forEach=function(a,d,c){for(var b=0;b<a.length;b++)d.call(c,a[b],b,a)};if(!Function.prototype.forEach)Function.prototype.forEach=function(a,d,c){for(var b in a)typeof this.prototype[b]=="undefined"&&d.call(c,a[b],b,a)};if(!String.forEach)String.forEach=function(a,d,c){Array.forEach(a.split(""),function(b,e){d.call(c,b,e,a)})};
var forEach=function(a,d,c){if(a){var b=Object;if(a instanceof Function)b=Function;else if(a.forEach instanceof Function){a.forEach(d,c);return}else if(typeof a=="string")b=String;else if(typeof a.length=="number")b=Array;b.forEach(a,d,c)}};
function My_atob(a){var d={strlen:a.length%4!=0,chars:/[^ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+\/=]/.test(a),equals:/=/.test(a)&&(/=[^=]/.test(a)||/={3}/.test(a))};if(d.strlen||d.chars||d.equals)throw Error("Invalid base64 data");d=[];for(var c=0;c<a.length;){var b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(c++)),e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(c++)),f="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(c++)),
g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(a.charAt(c++));b=(b<<18)+(e<<12)+((f&63)<<6)+(g&63);f=f==64?-1:(b&65280)>>8;g=g==64?-1:b&255;d.push((b&16711680)>>16);f>=0&&d.push(f);g>=0&&d.push(g)}return d}function clone(a){var d=new this.constructor,c;for(c in this)if(this.hasOwnProperty(c))d[c]=a&&typeof this[c]=="object"&&this[c]?this[c].clone(a):this[c];return d}Object.prototype.clone=clone;
if(!String.prototype.trim){String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"")};String.prototype.ltrim=function(){return this.replace(/^\s+/,"")};String.prototype.rtrim=function(){return this.replace(/\s+$/,"")}}if(!Array.prototype.indexOf)Array.prototype.indexOf=function(a,d){var c=this.length,b=Number(d)||0;b=b<0?Math.ceil(b):Math.floor(b);if(b<0)b+=c;for(;b<c;b++)if(b in this&&this[b]===a)return b;return-1};
if(!Array.prototype.filter)Array.prototype.filter=function(a,d){var c=this.length;if(typeof a!="function")throw new TypeError;for(var b=[],e=0;e<c;e++)if(e in this){var f=this[e];a.call(d,f,e,this)&&b.push(f)}return b};
function equals(a,d){if(typeof a!=typeof d)return false;if(typeof a!="object")return a==d;if(a==d)return true;if(a.constructor==Array&&d.constructor==Array){if(a.length!=d.length)return false;for(var c=0;c<a.length;++c)if(a[c]!=d[c])return false;return true}else throw Error("can't compare non-Array objects");};
