{"size": 61036, "ext": "js", "max_stars_repo_path": "persevere/jsclient/dojox/rpc/OfflineRest.js", "max_stars_repo_name": "suvajitgupta/Tasks", "max_stars_repo_stars_event_min_datetime": "2015-07-17T17:27:42.000Z", "max_stars_repo_stars_event_max_datetime": "2016-02-01T22:53:31.000Z", "max_issues_repo_path": "persevere/jsclient/dojox/rpc/OfflineRest.js", "max_issues_repo_name": "suvajitgupta/Tasks", "max_issues_repo_issues_event_min_datetime": "2018-03-30T07:16:45.000Z", "max_issues_repo_issues_event_max_datetime": "2018-03-30T07:16:45.000Z", "max_forks_repo_path": "persevere/jsclient/dojox/rpc/OfflineRest.js", "max_forks_repo_name": "suvajitgupta/Tasks", "max_forks_repo_forks_event_min_datetime": "2019-10-23T11:30:21.000Z", "max_forks_repo_forks_event_max_datetime": "2019-10-23T11:30:21.000Z"}
{"max_stars_count": 4, "max_issues_count": 1, "max_forks_count": 1, "avg_line_length": 3590.3529411765, "max_line_length": 60621, "alphanum_fraction": 0.7255554099}
/*
	Copyright (c) 2004-2009, The Dojo Foundation All Rights Reserved.
	Available via Academic Free License >= 2.1 OR the modified BSD license.
	see: http://dojotoolkit.org/license for details
*/

/*
	This is a compiled version of Dojo, built for deployment and not for
	development. To get an editable version, please visit:

		http://dojotoolkit.org

	for documentation and information on getting the source.
*/

if(!dojo._hasResource["dojox.json.query"]){dojo._hasResource["dojox.json.query"]=true;dojo.provide("dojox.json.query");(function(){function s(_1,_2,_3,_4){var _5=_1.length,_6=[];_3=_3||_5;_2=(_2<0)?Math.max(0,_2+_5):Math.min(_5,_2);_3=(_3<0)?Math.max(0,_3+_5):Math.min(_5,_3);for(var i=_2;i<_3;i+=_4){_6.push(_1[i]);}return _6;};function e(_7,_8){var _9=[];function _a(_b){if(_8){if(_8===true&&!(_b instanceof Array)){_9.push(_b);}else{if(_b[_8]){_9.push(_b[_8]);}}}for(var i in _b){var _c=_b[i];if(!_8){_9.push(_c);}else{if(_c&&typeof _c=="object"){_a(_c);}}}};if(_8 instanceof Array){if(_8.length==1){return _7[_8[0]];}for(var i=0;i<_8.length;i++){_9.push(_7[_8[i]]);}}else{_a(_7);}return _9;};function _d(_e,_f){var _10=[];var _11={};for(var i=0,l=_e.length;i<l;++i){var _12=_e[i];if(_f(_12,i,_e)){if((typeof _12=="object")&&_12){if(!_12.__included){_12.__included=true;_10.push(_12);}}else{if(!_11[_12+typeof _12]){_11[_12+typeof _12]=true;_10.push(_12);}}}}for(i=0,l=_10.length;i<l;++i){if(_10[i]){delete _10[i].__included;}}return _10;};dojox.json.query=function(_13,obj){var _14=0;var str=[];_13=_13.replace(/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'|[\[\]]/g,function(t){_14+=t=="["?1:t=="]"?-1:0;return (t=="]"&&_14>0)?"`]":(t.charAt(0)=="\""||t.charAt(0)=="'")?"`"+(str.push(t)-1):t;});var _15="";function _16(_17){_15=_17+"("+_15;};function _18(t,a,b,c,d,e,f,g){return str[g].match(/[\*\?]/)||f=="~"?"/^"+str[g].substring(1,str[g].length-1).replace(/\\([btnfr\\"'])|([^\w\*\?])/g,"\\$1$2").replace(/([\*\?])/g,"[\\w\\W]$1")+(f=="~"?"$/i":"$/")+".test("+a+")":t;};_13.replace(/(\]|\)|push|pop|shift|splice|sort|reverse)\s*\(/,function(){throw new Error("Unsafe function call");});_13=_13.replace(/([^=]=)([^=])/g,"$1=$2").replace(/@|(\.\s*)?[a-zA-Z\$_]+(\s*:)?/g,function(t){return t.charAt(0)=="."?t:t=="@"?"$obj":(t.match(/:|^(\$|Math|true|false|null)$/)?"":"$obj.")+t;}).replace(/\.?\.?\[(`\]|[^\]])*\]|\?.*|\.\.([\w\$_]+)|\.\*/g,function(t,a,b){var _19=t.match(/^\.?\.?(\[\s*\^?\?|\^?\?|\[\s*==)(.*?)\]?$/);if(_19){var _1a="";if(t.match(/^\./)){_16("e");_1a=",true)";}_16(_19[1].match(/\=/)?"dojo.map":_19[1].match(/\^/)?"distinctFilter":"dojo.filter");return _1a+",function($obj){return "+_19[2]+"})";}_19=t.match(/^\[\s*([\/\\].*)\]/);if(_19){return ".concat().sort(function(a,b){"+_19[1].replace(/\s*,?\s*([\/\\])\s*([^,\\\/]+)/g,function(t,a,b){return "var av= "+b.replace(/\$obj/,"a")+",bv= "+b.replace(/\$obj/,"b")+";if(av>bv||bv==null){return "+(a=="/"?1:-1)+";}\n"+"if(bv>av||av==null){return "+(a=="/"?-1:1)+";}\n";})+"return 0;})";}_19=t.match(/^\[(-?[0-9]*):(-?[0-9]*):?(-?[0-9]*)\]/);if(_19){_16("s");return ","+(_19[1]||0)+","+(_19[2]||0)+","+(_19[3]||1)+")";}if(t.match(/^\.\.|\.\*|\[\s*\*\s*\]|,/)){_16("e");return (t.charAt(1)=="."?",'"+b+"'":t.match(/,/)?","+t:"")+")";}return t;}).replace(/(\$obj\s*((\.\s*[\w_$]+\s*)|(\[\s*`([0-9]+)\s*`\]))*)(==|~)\s*`([0-9]+)/g,_18).replace(/`([0-9]+)\s*(==|~)\s*(\$obj\s*((\.\s*[\w_$]+)|(\[\s*`([0-9]+)\s*`\]))*)/g,function(t,a,b,c,d,e,f,g){return _18(t,c,d,e,f,g,b,a);});_13=_15+(_13.charAt(0)=="$"?"":"$")+_13.replace(/`([0-9]+|\])/g,function(t,a){return a=="]"?"]":str[a];});var _1b=eval("1&&function($,$1,$2,$3,$4,$5,$6,$7,$8,$9){var $obj=$;return "+_13+"}");for(var i=0;i<arguments.length-1;i++){arguments[i]=arguments[i+1];}return obj?_1b.apply(this,arguments):_1b;};})();}if(!dojo._hasResource["dojo.data.util.filter"]){dojo._hasResource["dojo.data.util.filter"]=true;dojo.provide("dojo.data.util.filter");dojo.data.util.filter.patternToRegExp=function(_1c,_1d){var rxp="^";var c=null;for(var i=0;i<_1c.length;i++){c=_1c.charAt(i);switch(c){case "\\":rxp+=c;i++;rxp+=_1c.charAt(i);break;case "*":rxp+=".*";break;case "?":rxp+=".";break;case "$":case "^":case "/":case "+":case ".":case "|":case "(":case ")":case "{":case "}":case "[":case "]":rxp+="\\";default:rxp+=c;}}rxp+="$";if(_1d){return new RegExp(rxp,"mi");}else{return new RegExp(rxp,"m");}};}if(!dojo._hasResource["dojox.data.ClientFilter"]){dojo._hasResource["dojox.data.ClientFilter"]=true;dojo.provide("dojox.data.ClientFilter");(function(){var cf;var _1e=function(_1f,_20,_21){return function(_22){_1f._updates.push({create:_20&&_22,remove:_21&&_22});cf.onUpdate();};};cf=dojo.declare("dojox.data.ClientFilter",null,{cacheByDefault:false,constructor:function(){this.onSet=_1e(this,true,true);this.onNew=_1e(this,true,false);this.onDelete=_1e(this,false,true);this._updates=[];this._fetchCache=[];},clearCache:function(){this._fetchCache=[];},updateResultSet:function(_23,_24){if(this.isUpdateable(_24)){for(var i=_24._version||0;i<this._updates.length;i++){var _25=this._updates[i].create;var _26=this._updates[i].remove;if(_26){for(var j=0;j<_23.length;j++){if(_23[j]==_26){_23.splice(j--,1);var _27=true;}}}if(_25&&this.matchesQuery(_25,_24)&&dojo.indexOf(_23,_25)==-1){_23.push(_25);_27=true;}}if(_24.sort&&_27){_23.sort(this.makeComparator(_24.sort.concat()));}_23._fullLength=_23.length;if(_24.count&&_27&&_24.count!==Infinity){_23.splice(_24.count,_23.length);}_24._version=this._updates.length;return _27?2:1;}return 0;},querySuperSet:function(_28,_29){if(_28.query==_29.query){return {};}if(!(_29.query instanceof Object&&(!_28.query||typeof _28.query=="object"))){return false;}var _2a=dojo.mixin({},_29.query);for(var i in _28.query){if(_2a[i]==_28.query[i]){delete _2a[i];}else{if(!(typeof _28.query[i]=="string"&&dojo.data.util.filter.patternToRegExp(_28.query[i]).test(_2a[i]))){return false;}}}return _2a;},serverVersion:0,cachingFetch:function(_2b){var _2c=this;for(var i=0;i<this._fetchCache.length;i++){var _2d=this._fetchCache[i];var _2e=this.querySuperSet(_2d,_2b);if(_2e!==false){var _2f=_2d._loading;if(!_2f){_2f=new dojo.Deferred();_2f.callback(_2d.cacheResults);}_2f.addCallback(function(_30){_30=_2c.clientSideFetch(dojo.mixin(dojo.mixin({},_2b),{query:_2e}),_30);_2f.fullLength=_30._fullLength;return _30;});_2b._version=_2d._version;break;}}if(!_2f){var _31=dojo.mixin({},_2b);var _32=(_2b.queryOptions||0).cache;var _33=this._fetchCache;if(_32===undefined?this.cacheByDefault:_32){if(_2b.start||_2b.count){delete _31.start;delete _31.count;_2b.clientQuery=dojo.mixin(_2b.clientQuery||{},{start:_2b.start,count:_2b.count});}_2b=_31;_33.push(_2b);}_2f=_2b._loading=this._doQuery(_2b);_2f.addErrback(function(){_33.splice(dojo.indexOf(_33,_2b),1);});}var _34=this.serverVersion;_2f.addCallback(function(_35){delete _2b._loading;if(_35){_2b._version=typeof _2b._version=="number"?_2b._version:_34;_2c.updateResultSet(_35,_2b);_2b.cacheResults=_35;if(!_2b.count||_35.length<_2b.count){_2f.fullLength=((_2b.start)?_2b.start:0)+_35.length;}}return _35;});return _2f;},isUpdateable:function(_36){return typeof _36.query=="object";},clientSideFetch:function(_37,_38){if(_37.queryOptions&&_37.queryOptions.results){_38=_37.queryOptions.results;}if(_37.query){var _39=[];for(var i=0;i<_38.length;i++){var _3a=_38[i];if(_3a&&this.matchesQuery(_3a,_37)){_39.push(_38[i]);}}}else{_39=_37.sort?_38.concat():_38;}if(_37.sort){_39.sort(this.makeComparator(_37.sort.concat()));}return this.clientSidePaging(_37,_39);},clientSidePaging:function(_3b,_3c){var _3d=_3b.start||0;var _3e=(_3d||_3b.count)?_3c.slice(_3d,_3d+(_3b.count||_3c.length)):_3c;_3e._fullLength=_3c.length;return _3e;},matchesQuery:function(_3f,_40){var _41=_40.query;var _42=_40.queryOptions&&_40.queryOptions.ignoreCase;for(var i in _41){var _43=_41[i];var _44=this.getValue(_3f,i);if((typeof _43=="string"&&(_43.match(/[\*\.]/)||_42))?!dojo.data.util.filter.patternToRegExp(_43,_42).test(_44):_44!=_43){return false;}}return true;},makeComparator:function(_45){var _46=_45.shift();if(!_46){return function(){return 0;};}var _47=_46.attribute;var _48=!!_46.descending;var _49=this.makeComparator(_45);var _4a=this;return function(a,b){var av=_4a.getValue(a,_47);var bv=_4a.getValue(b,_47);if(av!=bv){return av<bv==_48?1:-1;}return _49(a,b);};}});cf.onUpdate=function(){};})();}if(!dojo._hasResource["dojox.rpc.Rest"]){dojo._hasResource["dojox.rpc.Rest"]=true;dojo.provide("dojox.rpc.Rest");(function(){if(dojox.rpc&&dojox.rpc.transportRegistry){dojox.rpc.transportRegistry.register("REST",function(str){return str=="REST";},{getExecutor:function(_4b,_4c,svc){return new dojox.rpc.Rest(_4c.name,(_4c.contentType||svc._smd.contentType||"").match(/json|javascript/),null,function(id,_4d){var _4e=svc._getRequest(_4c,[id]);_4e.url=_4e.target+(_4e.data?"?"+_4e.data:"");return _4e;});}});}var drr;function _4f(_50,_51,_52,id){_50.addCallback(function(_53){if(_50.ioArgs.xhr&&_52){_52=_50.ioArgs.xhr.getResponseHeader("Content-Range");_50.fullLength=_52&&(_52=_52.match(/\/(.*)/))&&parseInt(_52[1]);}return _53;});return _50;};drr=dojox.rpc.Rest=function(_54,_55,_56,_57){var _58;_58=function(id,_59){return drr._get(_58,id,_59);};_58.isJson=_55;_58._schema=_56;_58.cache={serialize:_55?((dojox.json&&dojox.json.ref)||dojo).toJson:function(_5a){return _5a;}};_58._getRequest=_57||function(id,_5b){if(dojo.isObject(id)){id=dojo.objectToQuery(id);id=id?"?"+id:"";}if(_5b&&_5b.sort&&!_5b.queryStr){id+=(id?"&":"?")+"sort(";for(var i=0;i<_5b.sort.length;i++){var _5c=_5b.sort[i];id+=(i>0?",":"")+(_5c.descending?"-":"+")+encodeURIComponent(_5c.attribute);}id+=")";}var _5d={url:_54+(id==null?"":id),handleAs:_55?"json":"text",contentType:_55?"application/json":"text/plain",sync:dojox.rpc._sync,headers:{Accept:_55?"application/json,application/javascript":"*/*"}};if(_5b&&(_5b.start>=0||_5b.count>=0)){_5d.headers.Range="items="+(_5b.start||"0")+"-"+((_5b.count&&_5b.count!=Infinity&&(_5b.count+(_5b.start||0)-1))||"");}dojox.rpc._sync=false;return _5d;};function _5e(_5f){_58[_5f]=function(id,_60){return drr._change(_5f,_58,id,_60);};};_5e("put");_5e("post");_5e("delete");_58.servicePath=_54;return _58;};drr._index={};drr._timeStamps={};drr._change=function(_61,_62,id,_63){var _64=_62._getRequest(id);_64[_61+"Data"]=_63;return _4f(dojo.xhr(_61.toUpperCase(),_64,true),_62);};drr._get=function(_65,id,_66){_66=_66||{};return _4f(dojo.xhrGet(_65._getRequest(id,_66)),_65,(_66.start>=0||_66.count>=0),id);};})();}if(!dojo._hasResource["dojox.storage.Provider"]){dojo._hasResource["dojox.storage.Provider"]=true;dojo.provide("dojox.storage.Provider");dojo.declare("dojox.storage.Provider",null,{constructor:function(){},SUCCESS:"success",FAILED:"failed",PENDING:"pending",SIZE_NOT_AVAILABLE:"Size not available",SIZE_NO_LIMIT:"No size limit",DEFAULT_NAMESPACE:"default",onHideSettingsUI:null,initialize:function(){console.warn("dojox.storage.initialize not implemented");},isAvailable:function(){console.warn("dojox.storage.isAvailable not implemented");},put:function(key,_67,_68,_69){console.warn("dojox.storage.put not implemented");},get:function(key,_6a){console.warn("dojox.storage.get not implemented");},hasKey:function(key,_6b){return !!this.get(key,_6b);},getKeys:function(_6c){console.warn("dojox.storage.getKeys not implemented");},clear:function(_6d){console.warn("dojox.storage.clear not implemented");},remove:function(key,_6e){console.warn("dojox.storage.remove not implemented");},getNamespaces:function(){console.warn("dojox.storage.getNamespaces not implemented");},isPermanent:function(){console.warn("dojox.storage.isPermanent not implemented");},getMaximumSize:function(){console.warn("dojox.storage.getMaximumSize not implemented");},putMultiple:function(_6f,_70,_71,_72){for(var i=0;i<_6f.length;i++){dojox.storage.put(_6f[i],_70[i],_71,_72);}},getMultiple:function(_73,_74){var _75=[];for(var i=0;i<_73.length;i++){_75.push(dojox.storage.get(_73[i],_74));}return _75;},removeMultiple:function(_76,_77){for(var i=0;i<_76.length;i++){dojox.storage.remove(_76[i],_77);}},isValidKeyArray:function(_78){if(_78===null||_78===undefined||!dojo.isArray(_78)){return false;}return !dojo.some(_78,function(key){return !this.isValidKey(key);},this);},hasSettingsUI:function(){return false;},showSettingsUI:function(){console.warn("dojox.storage.showSettingsUI not implemented");},hideSettingsUI:function(){console.warn("dojox.storage.hideSettingsUI not implemented");},isValidKey:function(_79){if(_79===null||_79===undefined){return false;}return /^[0-9A-Za-z_]*$/.test(_79);},getResourceList:function(){return [];}});}if(!dojo._hasResource["dojox.storage.manager"]){dojo._hasResource["dojox.storage.manager"]=true;dojo.provide("dojox.storage.manager");dojox.storage.manager=new function(){this.currentProvider=null;this.available=false;this.providers=[];this._initialized=false;this._onLoadListeners=[];this.initialize=function(){this.autodetect();};this.register=function(_7a,_7b){this.providers.push(_7b);this.providers[_7a]=_7b;};this.setProvider=function(_7c){};this.autodetect=function(){if(this._initialized){return;}var _7d=dojo.config["forceStorageProvider"]||false;var _7e;for(var i=0;i<this.providers.length;i++){_7e=this.providers[i];if(_7d&&_7d==_7e.declaredClass){_7e.isAvailable();break;}else{if(!_7d&&_7e.isAvailable()){break;}}}if(!_7e){this._initialized=true;this.available=false;this.currentProvider=null;console.warn("No storage provider found for this platform");this.loaded();return;}this.currentProvider=_7e;dojo.mixin(dojox.storage,this.currentProvider);dojox.storage.initialize();this._initialized=true;this.available=true;};this.isAvailable=function(){return this.available;};this.addOnLoad=function(_7f){this._onLoadListeners.push(_7f);if(this.isInitialized()){this._fireLoaded();}};this.removeOnLoad=function(_80){for(var i=0;i<this._onLoadListeners.length;i++){if(_80==this._onLoadListeners[i]){this._onLoadListeners=this._onLoadListeners.splice(i,1);break;}}};this.isInitialized=function(){if(this.currentProvider!=null&&this.currentProvider.declaredClass=="dojox.storage.FlashStorageProvider"&&dojox.flash.ready==false){return false;}else{return this._initialized;}};this.supportsProvider=function(_81){try{var _82=eval("new "+_81+"()");var _83=_82.isAvailable();if(!_83){return false;}return _83;}catch(e){return false;}};this.getProvider=function(){return this.currentProvider;};this.loaded=function(){this._fireLoaded();};this._fireLoaded=function(){dojo.forEach(this._onLoadListeners,function(i){try{i();}catch(e){console.debug(e);}});};this.getResourceList=function(){var _84=[];dojo.forEach(dojox.storage.manager.providers,function(_85){_84=_84.concat(_85.getResourceList());});return _84;};};}if(!dojo._hasResource["dojo.gears"]){dojo._hasResource["dojo.gears"]=true;dojo.provide("dojo.gears");dojo.gears._gearsObject=function(){var _86;var _87;var _88=dojo.getObject("google.gears");if(_88){return _88;}if(typeof GearsFactory!="undefined"){_86=new GearsFactory();}else{if(dojo.isIE){try{_86=new ActiveXObject("Gears.Factory");}catch(e){}}else{if(navigator.mimeTypes["application/x-googlegears"]){_86=document.createElement("object");_86.setAttribute("type","application/x-googlegears");_86.setAttribute("width",0);_86.setAttribute("height",0);_86.style.display="none";document.documentElement.appendChild(_86);}}}if(!_86){return null;}dojo.setObject("google.gears.factory",_86);return dojo.getObject("google.gears");};dojo.gears.available=(!!dojo.gears._gearsObject())||0;}if(!dojo._hasResource["dojox.sql._crypto"]){dojo._hasResource["dojox.sql._crypto"]=true;dojo.provide("dojox.sql._crypto");dojo.mixin(dojox.sql._crypto,{_POOL_SIZE:100,encrypt:function(_89,_8a,_8b){this._initWorkerPool();var msg={plaintext:_89,password:_8a};msg=dojo.toJson(msg);msg="encr:"+String(msg);this._assignWork(msg,_8b);},decrypt:function(_8c,_8d,_8e){this._initWorkerPool();var msg={ciphertext:_8c,password:_8d};msg=dojo.toJson(msg);msg="decr:"+String(msg);this._assignWork(msg,_8e);},_initWorkerPool:function(){if(!this._manager){try{this._manager=google.gears.factory.create("beta.workerpool","1.0");this._unemployed=[];this._employed={};this._handleMessage=[];var _8f=this;this._manager.onmessage=function(msg,_90){var _91=_8f._employed["_"+_90];_8f._employed["_"+_90]=undefined;_8f._unemployed.push("_"+_90);if(_8f._handleMessage.length){var _92=_8f._handleMessage.shift();_8f._assignWork(_92.msg,_92.callback);}_91(msg);};var _93="function _workerInit(){"+"gearsWorkerPool.onmessage = "+String(this._workerHandler)+";"+"}";var _94=_93+" _workerInit();";for(var i=0;i<this._POOL_SIZE;i++){this._unemployed.push("_"+this._manager.createWorker(_94));}}catch(exp){throw exp.message||exp;}}},_assignWork:function(msg,_95){if(!this._handleMessage.length&&this._unemployed.length){var _96=this._unemployed.shift().substring(1);this._employed["_"+_96]=_95;this._manager.sendMessage(msg,parseInt(_96,10));}else{this._handleMessage={msg:msg,callback:_95};}},_workerHandler:function(msg,_97){var _98=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22];var _99=[[0,0,0,0],[1,0,0,0],[2,0,0,0],[4,0,0,0],[8,0,0,0],[16,0,0,0],[32,0,0,0],[64,0,0,0],[128,0,0,0],[27,0,0,0],[54,0,0,0]];function _9a(_9b,w){var Nb=4;var Nr=w.length/Nb-1;var _9c=[[],[],[],[]];for(var i=0;i<4*Nb;i++){_9c[i%4][Math.floor(i/4)]=_9b[i];}_9c=_9d(_9c,w,0,Nb);for(var _9e=1;_9e<Nr;_9e++){_9c=_9f(_9c,Nb);_9c=_a0(_9c,Nb);_9c=_a1(_9c,Nb);_9c=_9d(_9c,w,_9e,Nb);}_9c=_9f(_9c,Nb);_9c=_a0(_9c,Nb);_9c=_9d(_9c,w,Nr,Nb);var _a2=new Array(4*Nb);for(var i=0;i<4*Nb;i++){_a2[i]=_9c[i%4][Math.floor(i/4)];}return _a2;};function _9f(s,Nb){for(var r=0;r<4;r++){for(var c=0;c<Nb;c++){s[r][c]=_98[s[r][c]];}}return s;};function _a0(s,Nb){var t=new Array(4);for(var r=1;r<4;r++){for(var c=0;c<4;c++){t[c]=s[r][(c+r)%Nb];}for(var c=0;c<4;c++){s[r][c]=t[c];}}return s;};function _a1(s,Nb){for(var c=0;c<4;c++){var a=new Array(4);var b=new Array(4);for(var i=0;i<4;i++){a[i]=s[i][c];b[i]=s[i][c]&128?s[i][c]<<1^283:s[i][c]<<1;}s[0][c]=b[0]^a[1]^b[1]^a[2]^a[3];s[1][c]=a[0]^b[1]^a[2]^b[2]^a[3];s[2][c]=a[0]^a[1]^b[2]^a[3]^b[3];s[3][c]=a[0]^b[0]^a[1]^a[2]^b[3];}return s;};function _9d(_a3,w,rnd,Nb){for(var r=0;r<4;r++){for(var c=0;c<Nb;c++){_a3[r][c]^=w[rnd*4+c][r];}}return _a3;};function _a4(key){var Nb=4;var Nk=key.length/4;var Nr=Nk+6;var w=new Array(Nb*(Nr+1));var _a5=new Array(4);for(var i=0;i<Nk;i++){var r=[key[4*i],key[4*i+1],key[4*i+2],key[4*i+3]];w[i]=r;}for(var i=Nk;i<(Nb*(Nr+1));i++){w[i]=new Array(4);for(var t=0;t<4;t++){_a5[t]=w[i-1][t];}if(i%Nk==0){_a5=_a6(_a7(_a5));for(var t=0;t<4;t++){_a5[t]^=_99[i/Nk][t];}}else{if(Nk>6&&i%Nk==4){_a5=_a6(_a5);}}for(var t=0;t<4;t++){w[i][t]=w[i-Nk][t]^_a5[t];}}return w;};function _a6(w){for(var i=0;i<4;i++){w[i]=_98[w[i]];}return w;};function _a7(w){w[4]=w[0];for(var i=0;i<4;i++){w[i]=w[i+1];}return w;};function _a8(_a9,_aa,_ab){if(!(_ab==128||_ab==192||_ab==256)){return "";}var _ac=_ab/8;var _ad=new Array(_ac);for(var i=0;i<_ac;i++){_ad[i]=_aa.charCodeAt(i)&255;}var key=_9a(_ad,_a4(_ad));key=key.concat(key.slice(0,_ac-16));var _ae=16;var _af=new Array(_ae);var _b0=(new Date()).getTime();for(var i=0;i<4;i++){_af[i]=(_b0>>>i*8)&255;}for(var i=0;i<4;i++){_af[i+4]=(_b0/4294967296>>>i*8)&255;}var _b1=_a4(key);var _b2=Math.ceil(_a9.length/_ae);var _b3=new Array(_b2);for(var b=0;b<_b2;b++){for(var c=0;c<4;c++){_af[15-c]=(b>>>c*8)&255;}for(var c=0;c<4;c++){_af[15-c-4]=(b/4294967296>>>c*8);}var _b4=_9a(_af,_b1);var _b5=b<_b2-1?_ae:(_a9.length-1)%_ae+1;var ct="";for(var i=0;i<_b5;i++){var _b6=_a9.charCodeAt(b*_ae+i);var _b7=_b6^_b4[i];ct+=String.fromCharCode(_b7);}_b3[b]=_b8(ct);}var _b9="";for(var i=0;i<8;i++){_b9+=String.fromCharCode(_af[i]);}_b9=_b8(_b9);return _b9+"-"+_b3.join("-");};function _ba(_bb,_bc,_bd){if(!(_bd==128||_bd==192||_bd==256)){return "";}var _be=_bd/8;var _bf=new Array(_be);for(var i=0;i<_be;i++){_bf[i]=_bc.charCodeAt(i)&255;}var _c0=_a4(_bf);var key=_9a(_bf,_c0);key=key.concat(key.slice(0,_be-16));var _c1=_a4(key);_bb=_bb.split("-");var _c2=16;var _c3=new Array(_c2);var _c4=_c5(_bb[0]);for(var i=0;i<8;i++){_c3[i]=_c4.charCodeAt(i);}var _c6=new Array(_bb.length-1);for(var b=1;b<_bb.length;b++){for(var c=0;c<4;c++){_c3[15-c]=((b-1)>>>c*8)&255;}for(var c=0;c<4;c++){_c3[15-c-4]=((b/4294967296-1)>>>c*8)&255;}var _c7=_9a(_c3,_c1);_bb[b]=_c5(_bb[b]);var pt="";for(var i=0;i<_bb[b].length;i++){var _c8=_bb[b].charCodeAt(i);var _c9=_c8^_c7[i];pt+=String.fromCharCode(_c9);}_c6[b-1]=pt;}return _c6.join("");};function _b8(str){return str.replace(/[\0\t\n\v\f\r\xa0!-]/g,function(c){return "!"+c.charCodeAt(0)+"!";});};function _c5(str){return str.replace(/!\d\d?\d?!/g,function(c){return String.fromCharCode(c.slice(1,-1));});};function _ca(_cb,_cc){return _a8(_cb,_cc,256);};function _cd(_ce,_cf){return _ba(_ce,_cf,256);};var cmd=msg.substr(0,4);var arg=msg.substr(5);if(cmd=="encr"){arg=eval("("+arg+")");var _d0=arg.plaintext;var _d1=arg.password;var _d2=_ca(_d0,_d1);gearsWorkerPool.sendMessage(String(_d2),_97);}else{if(cmd=="decr"){arg=eval("("+arg+")");var _d3=arg.ciphertext;var _d1=arg.password;var _d2=_cd(_d3,_d1);gearsWorkerPool.sendMessage(String(_d2),_97);}}}});}if(!dojo._hasResource["dojox.sql._base"]){dojo._hasResource["dojox.sql._base"]=true;dojo.provide("dojox.sql._base");dojo.mixin(dojox.sql,{dbName:null,debug:(dojo.exists("dojox.sql.debug")?dojox.sql.debug:false),open:function(_d4){if(this._dbOpen&&(!_d4||_d4==this.dbName)){return;}if(!this.dbName){this.dbName="dot_store_"+window.location.href.replace(/[^0-9A-Za-z_]/g,"_");if(this.dbName.length>63){this.dbName=this.dbName.substring(0,63);}}if(!_d4){_d4=this.dbName;}try{this._initDb();this.db.open(_d4);this._dbOpen=true;}catch(exp){throw exp.message||exp;}},close:function(_d5){if(dojo.isIE){return;}if(!this._dbOpen&&(!_d5||_d5==this.dbName)){return;}if(!_d5){_d5=this.dbName;}try{this.db.close(_d5);this._dbOpen=false;}catch(exp){throw exp.message||exp;}},_exec:function(_d6){try{this._initDb();if(!this._dbOpen){this.open();this._autoClose=true;}var sql=null;var _d7=null;var _d8=null;var _d9=dojo._toArray(_d6);sql=_d9.splice(0,1)[0];if(this._needsEncrypt(sql)||this._needsDecrypt(sql)){_d7=_d9.splice(_d9.length-1,1)[0];_d8=_d9.splice(_d9.length-1,1)[0];}if(this.debug){this._printDebugSQL(sql,_d9);}var _da;if(this._needsEncrypt(sql)){_da=new dojox.sql._SQLCrypto("encrypt",sql,_d8,_d9,_d7);return null;}else{if(this._needsDecrypt(sql)){_da=new dojox.sql._SQLCrypto("decrypt",sql,_d8,_d9,_d7);return null;}}var rs=this.db.execute(sql,_d9);rs=this._normalizeResults(rs);if(this._autoClose){this.close();}return rs;}catch(exp){exp=exp.message||exp;console.debug("SQL Exception: "+exp);if(this._autoClose){try{this.close();}catch(e){console.debug("Error closing database: "+e.message||e);}}throw exp;}return null;},_initDb:function(){if(!this.db){try{this.db=google.gears.factory.create("beta.database","1.0");}catch(exp){dojo.setObject("google.gears.denied",true);if(dojox.off){dojox.off.onFrameworkEvent("coreOperationFailed");}throw "Google Gears must be allowed to run";}}},_printDebugSQL:function(sql,_db){var msg="dojox.sql(\""+sql+"\"";for(var i=0;i<_db.length;i++){if(typeof _db[i]=="string"){msg+=", \""+_db[i]+"\"";}else{msg+=", "+_db[i];}}msg+=")";console.debug(msg);},_normalizeResults:function(rs){var _dc=[];if(!rs){return [];}while(rs.isValidRow()){var row={};for(var i=0;i<rs.fieldCount();i++){var _dd=rs.fieldName(i);var _de=rs.field(i);row[_dd]=_de;}_dc.push(row);rs.next();}rs.close();return _dc;},_needsEncrypt:function(sql){return /encrypt\([^\)]*\)/i.test(sql);},_needsDecrypt:function(sql){return /decrypt\([^\)]*\)/i.test(sql);}});dojo.declare("dojox.sql._SQLCrypto",null,{constructor:function(_df,sql,_e0,_e1,_e2){if(_df=="encrypt"){this._execEncryptSQL(sql,_e0,_e1,_e2);}else{this._execDecryptSQL(sql,_e0,_e1,_e2);}},_execEncryptSQL:function(sql,_e3,_e4,_e5){var _e6=this._stripCryptoSQL(sql);var _e7=this._flagEncryptedArgs(sql,_e4);var _e8=this;this._encrypt(_e6,_e3,_e4,_e7,function(_e9){var _ea=false;var _eb=[];var exp=null;try{_eb=dojox.sql.db.execute(_e6,_e9);}catch(execError){_ea=true;exp=execError.message||execError;}if(exp!=null){if(dojox.sql._autoClose){try{dojox.sql.close();}catch(e){}}_e5(null,true,exp.toString());return;}_eb=dojox.sql._normalizeResults(_eb);if(dojox.sql._autoClose){dojox.sql.close();}if(dojox.sql._needsDecrypt(sql)){var _ec=_e8._determineDecryptedColumns(sql);_e8._decrypt(_eb,_ec,_e3,function(_ed){_e5(_ed,false,null);});}else{_e5(_eb,false,null);}});},_execDecryptSQL:function(sql,_ee,_ef,_f0){var _f1=this._stripCryptoSQL(sql);var _f2=this._determineDecryptedColumns(sql);var _f3=false;var _f4=[];var exp=null;try{_f4=dojox.sql.db.execute(_f1,_ef);}catch(execError){_f3=true;exp=execError.message||execError;}if(exp!=null){if(dojox.sql._autoClose){try{dojox.sql.close();}catch(e){}}_f0(_f4,true,exp.toString());return;}_f4=dojox.sql._normalizeResults(_f4);if(dojox.sql._autoClose){dojox.sql.close();}this._decrypt(_f4,_f2,_ee,function(_f5){_f0(_f5,false,null);});},_encrypt:function(sql,_f6,_f7,_f8,_f9){this._totalCrypto=0;this._finishedCrypto=0;this._finishedSpawningCrypto=false;this._finalArgs=_f7;for(var i=0;i<_f7.length;i++){if(_f8[i]){var _fa=_f7[i];var _fb=i;this._totalCrypto++;dojox.sql._crypto.encrypt(_fa,_f6,dojo.hitch(this,function(_fc){this._finalArgs[_fb]=_fc;this._finishedCrypto++;if(this._finishedCrypto>=this._totalCrypto&&this._finishedSpawningCrypto){_f9(this._finalArgs);}}));}}this._finishedSpawningCrypto=true;},_decrypt:function(_fd,_fe,_ff,_100){this._totalCrypto=0;this._finishedCrypto=0;this._finishedSpawningCrypto=false;this._finalResultSet=_fd;for(var i=0;i<_fd.length;i++){var row=_fd[i];for(var _101 in row){if(_fe=="*"||_fe[_101]){this._totalCrypto++;var _102=row[_101];this._decryptSingleColumn(_101,_102,_ff,i,function(_103){_100(_103);});}}}this._finishedSpawningCrypto=true;},_stripCryptoSQL:function(sql){sql=sql.replace(/DECRYPT\(\*\)/ig,"*");var _104=sql.match(/ENCRYPT\([^\)]*\)/ig);if(_104!=null){for(var i=0;i<_104.length;i++){var _105=_104[i];var _106=_105.match(/ENCRYPT\(([^\)]*)\)/i)[1];sql=sql.replace(_105,_106);}}_104=sql.match(/DECRYPT\([^\)]*\)/ig);if(_104!=null){for(i=0;i<_104.length;i++){var _107=_104[i];var _108=_107.match(/DECRYPT\(([^\)]*)\)/i)[1];sql=sql.replace(_107,_108);}}return sql;},_flagEncryptedArgs:function(sql,args){var _109=new RegExp(/([\"][^\"]*\?[^\"]*[\"])|([\'][^\']*\?[^\']*[\'])|(\?)/ig);var _10a;var _10b=0;var _10c=[];while((_10a=_109.exec(sql))!=null){var _10d=RegExp.lastMatch+"";if(/^[\"\']/.test(_10d)){continue;}var _10e=false;if(/ENCRYPT\([^\)]*$/i.test(RegExp.leftContext)){_10e=true;}_10c[_10b]=_10e;_10b++;}return _10c;},_determineDecryptedColumns:function(sql){var _10f={};if(/DECRYPT\(\*\)/i.test(sql)){_10f="*";}else{var _110=/DECRYPT\((?:\s*\w*\s*\,?)*\)/ig;var _111=_110.exec(sql);while(_111){var _112=new String(RegExp.lastMatch);var _113=_112.replace(/DECRYPT\(/i,"");_113=_113.replace(/\)/,"");_113=_113.split(/\s*,\s*/);dojo.forEach(_113,function(_114){if(/\s*\w* AS (\w*)/i.test(_114)){_114=_114.match(/\s*\w* AS (\w*)/i)[1];}_10f[_114]=true;});_111=_110.exec(sql);}}return _10f;},_decryptSingleColumn:function(_115,_116,_117,_118,_119){dojox.sql._crypto.decrypt(_116,_117,dojo.hitch(this,function(_11a){this._finalResultSet[_118][_115]=_11a;this._finishedCrypto++;if(this._finishedCrypto>=this._totalCrypto&&this._finishedSpawningCrypto){_119(this._finalResultSet);}}));}});(function(){var _11b=dojox.sql;dojox.sql=new Function("return dojox.sql._exec(arguments);");dojo.mixin(dojox.sql,_11b);})();}if(!dojo._hasResource["dojox.sql"]){dojo._hasResource["dojox.sql"]=true;dojo.provide("dojox.sql");}if(!dojo._hasResource["dojox.storage.GearsStorageProvider"]){dojo._hasResource["dojox.storage.GearsStorageProvider"]=true;dojo.provide("dojox.storage.GearsStorageProvider");if(dojo.gears.available){(function(){dojo.declare("dojox.storage.GearsStorageProvider",dojox.storage.Provider,{constructor:function(){},TABLE_NAME:"__DOJO_STORAGE",initialized:false,_available:null,_storageReady:false,initialize:function(){if(dojo.config["disableGearsStorage"]==true){return;}this.TABLE_NAME="__DOJO_STORAGE";this.initialized=true;dojox.storage.manager.loaded();},isAvailable:function(){return this._available=dojo.gears.available;},put:function(key,_11c,_11d,_11e){this._initStorage();if(!this.isValidKey(key)){throw new Error("Invalid key given: "+key);}_11e=_11e||this.DEFAULT_NAMESPACE;if(!this.isValidKey(_11e)){throw new Error("Invalid namespace given: "+key);}if(dojo.isString(_11c)){_11c="string:"+_11c;}else{_11c=dojo.toJson(_11c);}try{dojox.sql("DELETE FROM "+this.TABLE_NAME+" WHERE namespace = ? AND key = ?",_11e,key);dojox.sql("INSERT INTO "+this.TABLE_NAME+" VALUES (?, ?, ?)",_11e,key,_11c);}catch(e){console.debug("dojox.storage.GearsStorageProvider.put:",e);_11d(this.FAILED,key,e.toString(),_11e);return;}if(_11d){_11d(dojox.storage.SUCCESS,key,null,_11e);}},get:function(key,_11f){this._initStorage();if(!this.isValidKey(key)){throw new Error("Invalid key given: "+key);}_11f=_11f||this.DEFAULT_NAMESPACE;if(!this.isValidKey(_11f)){throw new Error("Invalid namespace given: "+key);}var _120=dojox.sql("SELECT * FROM "+this.TABLE_NAME+" WHERE namespace = ? AND "+" key = ?",_11f,key);if(!_120.length){return null;}else{_120=_120[0].value;}if(dojo.isString(_120)&&(/^string:/.test(_120))){_120=_120.substring("string:".length);}else{_120=dojo.fromJson(_120);}return _120;},getNamespaces:function(){this._initStorage();var _121=[dojox.storage.DEFAULT_NAMESPACE];var rs=dojox.sql("SELECT namespace FROM "+this.TABLE_NAME+" DESC GROUP BY namespace");for(var i=0;i<rs.length;i++){if(rs[i].namespace!=dojox.storage.DEFAULT_NAMESPACE){_121.push(rs[i].namespace);}}return _121;},getKeys:function(_122){this._initStorage();_122=_122||this.DEFAULT_NAMESPACE;if(!this.isValidKey(_122)){throw new Error("Invalid namespace given: "+_122);}var rs=dojox.sql("SELECT key FROM "+this.TABLE_NAME+" WHERE namespace = ?",_122);var _123=[];for(var i=0;i<rs.length;i++){_123.push(rs[i].key);}return _123;},clear:function(_124){this._initStorage();_124=_124||this.DEFAULT_NAMESPACE;if(!this.isValidKey(_124)){throw new Error("Invalid namespace given: "+_124);}dojox.sql("DELETE FROM "+this.TABLE_NAME+" WHERE namespace = ?",_124);},remove:function(key,_125){this._initStorage();if(!this.isValidKey(key)){throw new Error("Invalid key given: "+key);}_125=_125||this.DEFAULT_NAMESPACE;if(!this.isValidKey(_125)){throw new Error("Invalid namespace given: "+key);}dojox.sql("DELETE FROM "+this.TABLE_NAME+" WHERE namespace = ? AND"+" key = ?",_125,key);},putMultiple:function(keys,_126,_127,_128){this._initStorage();if(!this.isValidKeyArray(keys)||!_126 instanceof Array||keys.length!=_126.length){throw new Error("Invalid arguments: keys = ["+keys+"], values = ["+_126+"]");}if(_128==null||typeof _128=="undefined"){_128=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_128)){throw new Error("Invalid namespace given: "+_128);}this._statusHandler=_127;try{dojox.sql.open();dojox.sql.db.execute("BEGIN TRANSACTION");var _129="REPLACE INTO "+this.TABLE_NAME+" VALUES (?, ?, ?)";for(var i=0;i<keys.length;i++){var _12a=_126[i];if(dojo.isString(_12a)){_12a="string:"+_12a;}else{_12a=dojo.toJson(_12a);}dojox.sql.db.execute(_129,[_128,keys[i],_12a]);}dojox.sql.db.execute("COMMIT TRANSACTION");dojox.sql.close();}catch(e){console.debug("dojox.storage.GearsStorageProvider.putMultiple:",e);if(_127){_127(this.FAILED,keys,e.toString(),_128);}return;}if(_127){_127(dojox.storage.SUCCESS,keys,null,_128);}},getMultiple:function(keys,_12b){this._initStorage();if(!this.isValidKeyArray(keys)){throw new ("Invalid key array given: "+keys);}if(_12b==null||typeof _12b=="undefined"){_12b=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_12b)){throw new Error("Invalid namespace given: "+_12b);}var _12c="SELECT * FROM "+this.TABLE_NAME+" WHERE namespace = ? AND "+" key = ?";var _12d=[];for(var i=0;i<keys.length;i++){var _12e=dojox.sql(_12c,_12b,keys[i]);if(!_12e.length){_12d[i]=null;}else{_12e=_12e[0].value;if(dojo.isString(_12e)&&(/^string:/.test(_12e))){_12d[i]=_12e.substring("string:".length);}else{_12d[i]=dojo.fromJson(_12e);}}}return _12d;},removeMultiple:function(keys,_12f){this._initStorage();if(!this.isValidKeyArray(keys)){throw new Error("Invalid arguments: keys = ["+keys+"]");}if(_12f==null||typeof _12f=="undefined"){_12f=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_12f)){throw new Error("Invalid namespace given: "+_12f);}dojox.sql.open();dojox.sql.db.execute("BEGIN TRANSACTION");var _130="DELETE FROM "+this.TABLE_NAME+" WHERE namespace = ? AND key = ?";for(var i=0;i<keys.length;i++){dojox.sql.db.execute(_130,[_12f,keys[i]]);}dojox.sql.db.execute("COMMIT TRANSACTION");dojox.sql.close();},isPermanent:function(){return true;},getMaximumSize:function(){return this.SIZE_NO_LIMIT;},hasSettingsUI:function(){return false;},showSettingsUI:function(){throw new Error(this.declaredClass+" does not support a storage settings user-interface");},hideSettingsUI:function(){throw new Error(this.declaredClass+" does not support a storage settings user-interface");},_initStorage:function(){if(this._storageReady){return;}if(!google.gears.factory.hasPermission){var _131=null;var icon=null;var msg="This site would like to use Google Gears to enable "+"enhanced functionality.";var _132=google.gears.factory.getPermission(_131,icon,msg);if(!_132){throw new Error("You must give permission to use Gears in order to "+"store data");}}try{dojox.sql("CREATE TABLE IF NOT EXISTS "+this.TABLE_NAME+"( "+" namespace TEXT, "+" key TEXT, "+" value TEXT "+")");dojox.sql("CREATE UNIQUE INDEX IF NOT EXISTS namespace_key_index"+" ON "+this.TABLE_NAME+" (namespace, key)");}catch(e){console.debug("dojox.storage.GearsStorageProvider._createTables:",e);throw new Error("Unable to create storage tables for Gears in "+"Dojo Storage");}this._storageReady=true;}});dojox.storage.manager.register("dojox.storage.GearsStorageProvider",new dojox.storage.GearsStorageProvider());})();}}if(!dojo._hasResource["dojox.storage.WhatWGStorageProvider"]){dojo._hasResource["dojox.storage.WhatWGStorageProvider"]=true;dojo.provide("dojox.storage.WhatWGStorageProvider");dojo.declare("dojox.storage.WhatWGStorageProvider",[dojox.storage.Provider],{initialized:false,_domain:null,_available:null,_statusHandler:null,_allNamespaces:null,_storageEventListener:null,initialize:function(){if(dojo.config["disableWhatWGStorage"]==true){return;}this._domain=location.hostname;this.initialized=true;dojox.storage.manager.loaded();},isAvailable:function(){try{var _133=globalStorage[location.hostname];}catch(e){this._available=false;return this._available;}this._available=true;return this._available;},put:function(key,_134,_135,_136){if(this.isValidKey(key)==false){throw new Error("Invalid key given: "+key);}_136=_136||this.DEFAULT_NAMESPACE;key=this.getFullKey(key,_136);this._statusHandler=_135;if(dojo.isString(_134)){_134="string:"+_134;}else{_134=dojo.toJson(_134);}var _137=dojo.hitch(this,function(evt){window.removeEventListener("storage",_137,false);if(_135){_135.call(null,this.SUCCESS,key,null,_136);}});window.addEventListener("storage",_137,false);try{var _138=globalStorage[this._domain];_138.setItem(key,_134);}catch(e){this._statusHandler.call(null,this.FAILED,key,e.toString(),_136);}},get:function(key,_139){if(this.isValidKey(key)==false){throw new Error("Invalid key given: "+key);}_139=_139||this.DEFAULT_NAMESPACE;key=this.getFullKey(key,_139);var _13a=globalStorage[this._domain];var _13b=_13a.getItem(key);if(_13b==null||_13b==""){return null;}_13b=_13b.value;if(dojo.isString(_13b)&&(/^string:/.test(_13b))){_13b=_13b.substring("string:".length);}else{_13b=dojo.fromJson(_13b);}return _13b;},getNamespaces:function(){var _13c=[this.DEFAULT_NAMESPACE];var _13d={};var _13e=globalStorage[this._domain];var _13f=/^__([^_]*)_/;for(var i=0;i<_13e.length;i++){var _140=_13e.key(i);if(_13f.test(_140)==true){var _141=_140.match(_13f)[1];if(typeof _13d[_141]=="undefined"){_13d[_141]=true;_13c.push(_141);}}}return _13c;},getKeys:function(_142){_142=_142||this.DEFAULT_NAMESPACE;if(this.isValidKey(_142)==false){throw new Error("Invalid namespace given: "+_142);}var _143;if(_142==this.DEFAULT_NAMESPACE){_143=new RegExp("^([^_]{2}.*)$");}else{_143=new RegExp("^__"+_142+"_(.*)$");}var _144=globalStorage[this._domain];var _145=[];for(var i=0;i<_144.length;i++){var _146=_144.key(i);if(_143.test(_146)==true){_146=_146.match(_143)[1];_145.push(_146);}}return _145;},clear:function(_147){_147=_147||this.DEFAULT_NAMESPACE;if(this.isValidKey(_147)==false){throw new Error("Invalid namespace given: "+_147);}var _148;if(_147==this.DEFAULT_NAMESPACE){_148=new RegExp("^[^_]{2}");}else{_148=new RegExp("^__"+_147+"_");}var _149=globalStorage[this._domain];var keys=[];for(var i=0;i<_149.length;i++){if(_148.test(_149.key(i))==true){keys[keys.length]=_149.key(i);}}dojo.forEach(keys,dojo.hitch(_149,"removeItem"));},remove:function(key,_14a){key=this.getFullKey(key,_14a);var _14b=globalStorage[this._domain];_14b.removeItem(key);},isPermanent:function(){return true;},getMaximumSize:function(){return this.SIZE_NO_LIMIT;},hasSettingsUI:function(){return false;},showSettingsUI:function(){throw new Error(this.declaredClass+" does not support a storage settings user-interface");},hideSettingsUI:function(){throw new Error(this.declaredClass+" does not support a storage settings user-interface");},getFullKey:function(key,_14c){_14c=_14c||this.DEFAULT_NAMESPACE;if(this.isValidKey(_14c)==false){throw new Error("Invalid namespace given: "+_14c);}if(_14c==this.DEFAULT_NAMESPACE){return key;}else{return "__"+_14c+"_"+key;}}});dojox.storage.manager.register("dojox.storage.WhatWGStorageProvider",new dojox.storage.WhatWGStorageProvider());}if(!dojo._hasResource["dojo.AdapterRegistry"]){dojo._hasResource["dojo.AdapterRegistry"]=true;dojo.provide("dojo.AdapterRegistry");dojo.AdapterRegistry=function(_14d){this.pairs=[];this.returnWrappers=_14d||false;};dojo.extend(dojo.AdapterRegistry,{register:function(name,_14e,wrap,_14f,_150){this.pairs[((_150)?"unshift":"push")]([name,_14e,wrap,_14f]);},match:function(){for(var i=0;i<this.pairs.length;i++){var pair=this.pairs[i];if(pair[1].apply(this,arguments)){if((pair[3])||(this.returnWrappers)){return pair[2];}else{return pair[2].apply(this,arguments);}}}throw new Error("No match found");},unregister:function(name){for(var i=0;i<this.pairs.length;i++){var pair=this.pairs[i];if(pair[0]==name){this.pairs.splice(i,1);return true;}}return false;}});}if(!dojo._hasResource["dijit._base.place"]){dojo._hasResource["dijit._base.place"]=true;dojo.provide("dijit._base.place");dijit.getViewport=function(){var _151=(dojo.doc.compatMode=="BackCompat")?dojo.body():dojo.doc.documentElement;var _152=dojo._docScroll();return {w:_151.clientWidth,h:_151.clientHeight,l:_152.x,t:_152.y};};dijit.placeOnScreen=function(node,pos,_153,_154){var _155=dojo.map(_153,function(_156){var c={corner:_156,pos:{x:pos.x,y:pos.y}};if(_154){c.pos.x+=_156.charAt(1)=="L"?_154.x:-_154.x;c.pos.y+=_156.charAt(0)=="T"?_154.y:-_154.y;}return c;});return dijit._place(node,_155);};dijit._place=function(node,_157,_158){var view=dijit.getViewport();if(!node.parentNode||String(node.parentNode.tagName).toLowerCase()!="body"){dojo.body().appendChild(node);}var best=null;dojo.some(_157,function(_159){var _15a=_159.corner;var pos=_159.pos;if(_158){_158(node,_159.aroundCorner,_15a);}var _15b=node.style;var _15c=_15b.display;var _15d=_15b.visibility;_15b.visibility="hidden";_15b.display="";var mb=dojo.marginBox(node);_15b.display=_15c;_15b.visibility=_15d;var _15e=Math.max(view.l,_15a.charAt(1)=="L"?pos.x:(pos.x-mb.w)),_15f=Math.max(view.t,_15a.charAt(0)=="T"?pos.y:(pos.y-mb.h)),endX=Math.min(view.l+view.w,_15a.charAt(1)=="L"?(_15e+mb.w):pos.x),endY=Math.min(view.t+view.h,_15a.charAt(0)=="T"?(_15f+mb.h):pos.y),_160=endX-_15e,_161=endY-_15f,_162=(mb.w-_160)+(mb.h-_161);if(best==null||_162<best.overflow){best={corner:_15a,aroundCorner:_159.aroundCorner,x:_15e,y:_15f,w:_160,h:_161,overflow:_162};}return !_162;});node.style.left=best.x+"px";node.style.top=best.y+"px";if(best.overflow&&_158){_158(node,best.aroundCorner,best.corner);}return best;};dijit.placeOnScreenAroundNode=function(node,_163,_164,_165){_163=dojo.byId(_163);var _166=_163.style.display;_163.style.display="";var _167=dojo.position(_163,true);_163.style.display=_166;return dijit._placeOnScreenAroundRect(node,_167.x,_167.y,_167.w,_167.h,_164,_165);};dijit.placeOnScreenAroundRectangle=function(node,_168,_169,_16a){return dijit._placeOnScreenAroundRect(node,_168.x,_168.y,_168.width,_168.height,_169,_16a);};dijit._placeOnScreenAroundRect=function(node,x,y,_16b,_16c,_16d,_16e){var _16f=[];for(var _170 in _16d){_16f.push({aroundCorner:_170,corner:_16d[_170],pos:{x:x+(_170.charAt(1)=="L"?0:_16b),y:y+(_170.charAt(0)=="T"?0:_16c)}});}return dijit._place(node,_16f,_16e);};dijit.placementRegistry=new dojo.AdapterRegistry();dijit.placementRegistry.register("node",function(n,x){return typeof x=="object"&&typeof x.offsetWidth!="undefined"&&typeof x.offsetHeight!="undefined";},dijit.placeOnScreenAroundNode);dijit.placementRegistry.register("rect",function(n,x){return typeof x=="object"&&"x" in x&&"y" in x&&"width" in x&&"height" in x;},dijit.placeOnScreenAroundRectangle);dijit.placeOnScreenAroundElement=function(node,_171,_172,_173){return dijit.placementRegistry.match.apply(dijit.placementRegistry,arguments);};dijit.getPopupAlignment=function(_174,_175){var _176={};dojo.forEach(_174,function(pos){switch(pos){case "after":_176[_175?"BR":"BL"]=_175?"BL":"BR";break;case "before":_176[_175?"BL":"BR"]=_175?"BR":"BL";break;case "below":_176[_175?"BL":"BR"]=_175?"TL":"TR";_176[_175?"BR":"BL"]=_175?"TR":"TL";break;case "above":default:_176[_175?"TL":"TR"]=_175?"BL":"BR";_176[_175?"TR":"TL"]=_175?"BR":"BL";break;}});return _176;};dijit.getPopupAroundAlignment=function(_177,_178){var _179={};dojo.forEach(_177,function(pos){switch(pos){case "after":_179[_178?"BR":"BL"]=_178?"BL":"BR";break;case "before":_179[_178?"BL":"BR"]=_178?"BR":"BL";break;case "below":_179[_178?"BL":"BR"]=_178?"TL":"TR";_179[_178?"BR":"BL"]=_178?"TR":"TL";break;case "above":default:_179[_178?"TL":"TR"]=_178?"BL":"BR";_179[_178?"TR":"TL"]=_178?"BR":"BL";break;}});return _179;};}if(!dojo._hasResource["dojox.flash._base"]){dojo._hasResource["dojox.flash._base"]=true;dojo.provide("dojox.flash._base");dojo.experimental("dojox.flash");dojox.flash=function(){};dojox.flash={ready:false,url:null,_visible:true,_loadedListeners:[],_installingListeners:[],setSwf:function(url,_17a){this.url=url;this._visible=true;if(_17a!==null&&_17a!==undefined){this._visible=_17a;}this._initialize();},addLoadedListener:function(_17b){this._loadedListeners.push(_17b);},addInstallingListener:function(_17c){this._installingListeners.push(_17c);},loaded:function(){dojox.flash.ready=true;if(dojox.flash._loadedListeners.length){for(var i=0;i<dojox.flash._loadedListeners.length;i++){dojox.flash._loadedListeners[i].call(null);}}},installing:function(){if(dojox.flash._installingListeners.length){for(var i=0;i<dojox.flash._installingListeners.length;i++){dojox.flash._installingListeners[i].call(null);}}},_initialize:function(){var _17d=new dojox.flash.Install();dojox.flash.installer=_17d;if(_17d.needed()){_17d.install();}else{dojox.flash.obj=new dojox.flash.Embed(this._visible);dojox.flash.obj.write();dojox.flash.comm=new dojox.flash.Communicator();}}};dojox.flash.Info=function(){this._detectVersion();};dojox.flash.Info.prototype={version:-1,versionMajor:-1,versionMinor:-1,versionRevision:-1,capable:false,installing:false,isVersionOrAbove:function(_17e,_17f,_180){_180=parseFloat("."+_180);if(this.versionMajor>=_17e&&this.versionMinor>=_17f&&this.versionRevision>=_180){return true;}else{return false;}},_detectVersion:function(){var _181;for(var _182=25;_182>0;_182--){if(dojo.isIE){var axo;try{if(_182>6){axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_182);}else{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}if(typeof axo=="object"){if(_182==6){axo.AllowScriptAccess="always";}_181=axo.GetVariable("$version");}}catch(e){continue;}}else{_181=this._JSFlashInfo(_182);}if(_181==-1){this.capable=false;return;}else{if(_181!=0){var _183;if(dojo.isIE){var _184=_181.split(" ");var _185=_184[1];_183=_185.split(",");}else{_183=_181.split(".");}this.versionMajor=_183[0];this.versionMinor=_183[1];this.versionRevision=_183[2];var _186=this.versionMajor+"."+this.versionRevision;this.version=parseFloat(_186);this.capable=true;break;}}}},_JSFlashInfo:function(_187){if(navigator.plugins!=null&&navigator.plugins.length>0){if(navigator.plugins["Shockwave Flash 2.0"]||navigator.plugins["Shockwave Flash"]){var _188=navigator.plugins["Shockwave Flash 2.0"]?" 2.0":"";var _189=navigator.plugins["Shockwave Flash"+_188].description;var _18a=_189.split(" ");var _18b=_18a[2].split(".");var _18c=_18b[0];var _18d=_18b[1];var _18e=(_18a[3]||_18a[4]).split("r");var _18f=_18e[1]>0?_18e[1]:0;var _190=_18c+"."+_18d+"."+_18f;return _190;}}return -1;}};dojox.flash.Embed=function(_191){this._visible=_191;};dojox.flash.Embed.prototype={width:215,height:138,id:"flashObject",_visible:true,protocol:function(){switch(window.location.protocol){case "https:":return "https";break;default:return "http";break;}},write:function(_192){var _193;var _194=dojox.flash.url;var _195=_194;var _196=_194;var _197=dojo.baseUrl;var _198=document.location.protocol+"//"+document.location.host;if(_192){var _199=escape(window.location);document.title=document.title.slice(0,47)+" - Flash Player Installation";var _19a=escape(document.title);_195+="?MMredirectURL="+_199+"&MMplayerType=ActiveX"+"&MMdoctitle="+_19a+"&baseUrl="+escape(_197)+"&xdomain="+escape(_198);_196+="?MMredirectURL="+_199+"&MMplayerType=PlugIn"+"&baseUrl="+escape(_197)+"&xdomain="+escape(_198);}else{_195+="?cachebust="+new Date().getTime();_195+="&baseUrl="+escape(_197);_195+="&xdomain="+escape(_198);}if(_196.indexOf("?")==-1){_196+="?baseUrl="+escape(_197);}else{_196+="&baseUrl="+escape(_197);}_196+="&xdomain="+escape(_198);_193="<object classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" "+"codebase=\""+this.protocol()+"://fpdownload.macromedia.com/pub/shockwave/cabs/flash/"+"swflash.cab#version=8,0,0,0\"\n "+"width=\""+this.width+"\"\n "+"height=\""+this.height+"\"\n "+"id=\""+this.id+"\"\n "+"name=\""+this.id+"\"\n "+"align=\"middle\">\n "+"<param name=\"allowScriptAccess\" value=\"always\"></param>\n "+"<param name=\"movie\" value=\""+_195+"\"></param>\n "+"<param name=\"quality\" value=\"high\"></param>\n "+"<param name=\"bgcolor\" value=\"#ffffff\"></param>\n "+"<embed src=\""+_196+"\" "+"quality=\"high\" "+"bgcolor=\"#ffffff\" "+"width=\""+this.width+"\" "+"height=\""+this.height+"\" "+"id=\""+this.id+"Embed"+"\" "+"name=\""+this.id+"\" "+"swLiveConnect=\"true\" "+"align=\"middle\" "+"allowScriptAccess=\"always\" "+"type=\"application/x-shockwave-flash\" "+"pluginspage=\""+this.protocol()+"://www.macromedia.com/go/getflashplayer\" "+"></embed>\n"+"</object>\n";dojo.connect(dojo,"loaded",dojo.hitch(this,function(){var _19b=this.id+"Container";if(dojo.byId(_19b)){return;}var div=document.createElement("div");div.id=this.id+"Container";div.style.width=this.width+"px";div.style.height=this.height+"px";if(!this._visible){div.style.position="absolute";div.style.zIndex="10000";div.style.top="-1000px";}div.innerHTML=_193;var body=document.getElementsByTagName("body");if(!body||!body.length){throw new Error("No body tag for this page");}body=body[0];body.appendChild(div);}));},get:function(){if(dojo.isIE||dojo.isWebKit){return dojo.byId(this.id);}else{return document[this.id+"Embed"];}},setVisible:function(_19c){var _19d=dojo.byId(this.id+"Container");if(_19c){_19d.style.position="absolute";_19d.style.visibility="visible";}else{_19d.style.position="absolute";_19d.style.y="-1000px";_19d.style.visibility="hidden";}},center:function(){var _19e=this.width;var _19f=this.height;var _1a0=dijit.getViewport();var x=_1a0.l+(_1a0.w-_19e)/2;var y=_1a0.t+(_1a0.h-_19f)/2;var _1a1=dojo.byId(this.id+"Container");_1a1.style.top=y+"px";_1a1.style.left=x+"px";}};dojox.flash.Communicator=function(){};dojox.flash.Communicator.prototype={_addExternalInterfaceCallback:function(_1a2){var _1a3=dojo.hitch(this,function(){var _1a4=new Array(arguments.length);for(var i=0;i<arguments.length;i++){_1a4[i]=this._encodeData(arguments[i]);}var _1a5=this._execFlash(_1a2,_1a4);_1a5=this._decodeData(_1a5);return _1a5;});this[_1a2]=_1a3;},_encodeData:function(data){if(!data||typeof data!="string"){return data;}data=data.replace("\\","&custom_backslash;");data=data.replace(/\0/g,"&custom_null;");return data;},_decodeData:function(data){if(data&&data.length&&typeof data!="string"){data=data[0];}if(!data||typeof data!="string"){return data;}data=data.replace(/\&custom_null\;/g,"\x00");data=data.replace(/\&custom_lt\;/g,"<").replace(/\&custom_gt\;/g,">").replace(/\&custom_backslash\;/g,"\\");return data;},_execFlash:function(_1a6,_1a7){var _1a8=dojox.flash.obj.get();_1a7=(_1a7)?_1a7:[];for(var i=0;i<_1a7;i++){if(typeof _1a7[i]=="string"){_1a7[i]=this._encodeData(_1a7[i]);}}var _1a9=function(){return eval(_1a8.CallFunction("<invoke name=\""+_1a6+"\" returntype=\"javascript\">"+__flash__argumentsToXML(_1a7,0)+"</invoke>"));};var _1aa=_1a9.call(_1a7);if(typeof _1aa=="string"){_1aa=this._decodeData(_1aa);}return _1aa;}};dojox.flash.Install=function(){};dojox.flash.Install.prototype={needed:function(){if(!dojox.flash.info.capable){return true;}if(!dojox.flash.info.isVersionOrAbove(8,0,0)){return true;}return false;},install:function(){var _1ab;dojox.flash.info.installing=true;dojox.flash.installing();if(dojox.flash.info.capable==false){_1ab=new dojox.flash.Embed(false);_1ab.write();}else{if(dojox.flash.info.isVersionOrAbove(6,0,65)){_1ab=new dojox.flash.Embed(false);_1ab.write(true);_1ab.setVisible(true);_1ab.center();}else{alert("This content requires a more recent version of the Macromedia "+" Flash Player.");window.location.href=+dojox.flash.Embed.protocol()+"://www.macromedia.com/go/getflashplayer";}}},_onInstallStatus:function(msg){if(msg=="Download.Complete"){dojox.flash._initialize();}else{if(msg=="Download.Cancelled"){alert("This content requires a more recent version of the Macromedia "+" Flash Player.");window.location.href=dojox.flash.Embed.protocol()+"://www.macromedia.com/go/getflashplayer";}else{if(msg=="Download.Failed"){alert("There was an error downloading the Flash Player update. "+"Please try again later, or visit macromedia.com to download "+"the latest version of the Flash plugin.");}}}}};dojox.flash.info=new dojox.flash.Info();}if(!dojo._hasResource["dojox.flash"]){dojo._hasResource["dojox.flash"]=true;dojo.provide("dojox.flash");}if(!dojo._hasResource["dojox.storage.FlashStorageProvider"]){dojo._hasResource["dojox.storage.FlashStorageProvider"]=true;dojo.provide("dojox.storage.FlashStorageProvider");dojo.declare("dojox.storage.FlashStorageProvider",dojox.storage.Provider,{initialized:false,_available:null,_statusHandler:null,_flashReady:false,_pageReady:false,initialize:function(){if(dojo.config["disableFlashStorage"]==true){return;}dojox.flash.addLoadedListener(dojo.hitch(this,function(){this._flashReady=true;if(this._flashReady&&this._pageReady){this._loaded();}}));var _1ac=dojo.moduleUrl("dojox","storage/Storage.swf").toString();dojox.flash.setSwf(_1ac,false);dojo.connect(dojo,"loaded",this,function(){this._pageReady=true;if(this._flashReady&&this._pageReady){this._loaded();}});},setFlushDelay:function(_1ad){if(_1ad===null||typeof _1ad==="undefined"||isNaN(_1ad)){throw new Error("Invalid argunment: "+_1ad);}dojox.flash.comm.setFlushDelay(String(_1ad));},getFlushDelay:function(){return Number(dojox.flash.comm.getFlushDelay());},flush:function(_1ae){if(_1ae==null||typeof _1ae=="undefined"){_1ae=dojox.storage.DEFAULT_NAMESPACE;}dojox.flash.comm.flush(_1ae);},isAvailable:function(){return (this._available=!dojo.config["disableFlashStorage"]);},put:function(key,_1af,_1b0,_1b1){if(!this.isValidKey(key)){throw new Error("Invalid key given: "+key);}if(!_1b1){_1b1=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1b1)){throw new Error("Invalid namespace given: "+_1b1);}this._statusHandler=_1b0;if(dojo.isString(_1af)){_1af="string:"+_1af;}else{_1af=dojo.toJson(_1af);}dojox.flash.comm.put(key,_1af,_1b1);},putMultiple:function(keys,_1b2,_1b3,_1b4){if(!this.isValidKeyArray(keys)||!_1b2 instanceof Array||keys.length!=_1b2.length){throw new Error("Invalid arguments: keys = ["+keys+"], values = ["+_1b2+"]");}if(!_1b4){_1b4=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1b4)){throw new Error("Invalid namespace given: "+_1b4);}this._statusHandler=_1b3;var _1b5=keys.join(",");var _1b6=[];for(var i=0;i<_1b2.length;i++){if(dojo.isString(_1b2[i])){_1b2[i]="string:"+_1b2[i];}else{_1b2[i]=dojo.toJson(_1b2[i]);}_1b6[i]=_1b2[i].length;}var _1b7=_1b2.join("");var _1b8=_1b6.join(",");dojox.flash.comm.putMultiple(_1b5,_1b7,_1b8,_1b4);},get:function(key,_1b9){if(!this.isValidKey(key)){throw new Error("Invalid key given: "+key);}if(!_1b9){_1b9=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1b9)){throw new Error("Invalid namespace given: "+_1b9);}var _1ba=dojox.flash.comm.get(key,_1b9);if(_1ba==""){return null;}return this._destringify(_1ba);},getMultiple:function(keys,_1bb){if(!this.isValidKeyArray(keys)){throw new ("Invalid key array given: "+keys);}if(!_1bb){_1bb=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1bb)){throw new Error("Invalid namespace given: "+_1bb);}var _1bc=keys.join(",");var _1bd=dojox.flash.comm.getMultiple(_1bc,_1bb);var _1be=eval("("+_1bd+")");for(var i=0;i<_1be.length;i++){_1be[i]=(_1be[i]=="")?null:this._destringify(_1be[i]);}return _1be;},_destringify:function(_1bf){if(dojo.isString(_1bf)&&(/^string:/.test(_1bf))){_1bf=_1bf.substring("string:".length);}else{_1bf=dojo.fromJson(_1bf);}return _1bf;},getKeys:function(_1c0){if(!_1c0){_1c0=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1c0)){throw new Error("Invalid namespace given: "+_1c0);}var _1c1=dojox.flash.comm.getKeys(_1c0);if(_1c1==null||_1c1=="null"){_1c1="";}_1c1=_1c1.split(",");_1c1.sort();return _1c1;},getNamespaces:function(){var _1c2=dojox.flash.comm.getNamespaces();if(_1c2==null||_1c2=="null"){_1c2=dojox.storage.DEFAULT_NAMESPACE;}_1c2=_1c2.split(",");_1c2.sort();return _1c2;},clear:function(_1c3){if(!_1c3){_1c3=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1c3)){throw new Error("Invalid namespace given: "+_1c3);}dojox.flash.comm.clear(_1c3);},remove:function(key,_1c4){if(!_1c4){_1c4=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1c4)){throw new Error("Invalid namespace given: "+_1c4);}dojox.flash.comm.remove(key,_1c4);},removeMultiple:function(keys,_1c5){if(!this.isValidKeyArray(keys)){dojo.raise("Invalid key array given: "+keys);}if(!_1c5){_1c5=dojox.storage.DEFAULT_NAMESPACE;}if(!this.isValidKey(_1c5)){throw new Error("Invalid namespace given: "+_1c5);}var _1c6=keys.join(",");dojox.flash.comm.removeMultiple(_1c6,_1c5);},isPermanent:function(){return true;},getMaximumSize:function(){return dojox.storage.SIZE_NO_LIMIT;},hasSettingsUI:function(){return true;},showSettingsUI:function(){dojox.flash.comm.showSettings();dojox.flash.obj.setVisible(true);dojox.flash.obj.center();},hideSettingsUI:function(){dojox.flash.obj.setVisible(false);if(dojo.isFunction(dojox.storage.onHideSettingsUI)){dojox.storage.onHideSettingsUI.call(null);}},getResourceList:function(){return [];},_loaded:function(){this._allNamespaces=this.getNamespaces();this.initialized=true;dojox.storage.manager.loaded();},_onStatus:function(_1c7,key,_1c8){var ds=dojox.storage;var dfo=dojox.flash.obj;if(_1c7==ds.PENDING){dfo.center();dfo.setVisible(true);}else{dfo.setVisible(false);}if(ds._statusHandler){ds._statusHandler.call(null,_1c7,key,null,_1c8);}}});dojox.storage.manager.register("dojox.storage.FlashStorageProvider",new dojox.storage.FlashStorageProvider());}if(!dojo._hasResource["dojox.storage._common"]){dojo._hasResource["dojox.storage._common"]=true;dojo.provide("dojox.storage._common");dojox.storage.manager.initialize();}if(!dojo._hasResource["dojox.storage"]){dojo._hasResource["dojox.storage"]=true;dojo.provide("dojox.storage");}if(!dojo._hasResource["dojox.rpc.OfflineRest"]){dojo._hasResource["dojox.rpc.OfflineRest"]=true;dojo.provide("dojox.rpc.OfflineRest");(function(){var Rest=dojox.rpc.Rest;var _1c9="dojox_rpc_OfflineRest";var _1ca;var _1cb=Rest._index;dojox.storage.manager.addOnLoad(function(){_1ca=dojox.storage.manager.available;for(var i in _1cb){_1cc(_1cb[i],i);}});var _1cd;function _1ce(key){return key.replace(/[^0-9A-Za-z_]/g,"_");};function _1cc(_1cf,id){if(_1ca&&!_1cd&&(id||(_1cf&&_1cf.__id))){dojox.storage.put(_1ce(id||_1cf.__id),typeof _1cf=="object"?dojox.json.ref.toJson(_1cf):_1cf,function(){},_1c9);}};function _1d0(_1d1){return _1d1 instanceof Error&&(_1d1.status==503||_1d1.status>12000||!_1d1.status);};function _1d2(){if(_1ca){var _1d3=dojox.storage.get("dirty",_1c9);if(_1d3){for(var _1d4 in _1d3){_1d5(_1d4,_1d3);}}}};var _1d6;function sync(){_1d6.sendChanges();_1d6.downloadChanges();};var _1d7=setInterval(sync,15000);dojo.connect(document,"ononline",sync);_1d6=dojox.rpc.OfflineRest={turnOffAutoSync:function(){clearInterval(_1d7);},sync:sync,sendChanges:_1d2,downloadChanges:function(){},addStore:function(_1d8,_1d9){_1d6.stores.push(_1d8);_1d8.fetch({queryOptions:{cache:true},query:_1d9,onComplete:function(_1da,args){_1d8._localBaseResults=_1da;_1d8._localBaseFetch=args;}});}};_1d6.stores=[];var _1db=Rest._get;Rest._get=function(_1dc,id){try{_1d2();if(window.navigator&&navigator.onLine===false){throw new Error();}var dfd=_1db(_1dc,id);}catch(e){dfd=new dojo.Deferred();dfd.errback(e);}var sync=dojox.rpc._sync;dfd.addCallback(function(_1dd){_1cc(_1dd,_1dc._getRequest(id).url);return _1dd;});dfd.addErrback(function(_1de){if(_1ca){if(_1d0(_1de)){var _1df={};var byId=function(id,_1e0){if(_1df[id]){return _1e0;}var _1e1=dojo.fromJson(dojox.storage.get(_1ce(id),_1c9))||_1e0;_1df[id]=_1e1;for(var i in _1e1){var val=_1e1[i];id=val&&val.$ref;if(id){if(id.substring&&id.substring(0,4)=="cid:"){id=id.substring(4);}_1e1[i]=byId(id,val);}}if(_1e1 instanceof Array){for(i=0;i<_1e1.length;i++){if(_1e1[i]===undefined){_1e1.splice(i--,1);}}}return _1e1;};_1cd=true;var _1e2=byId(_1dc._getRequest(id).url);if(!_1e2){return _1de;}_1cd=false;return _1e2;}else{return _1de;}}else{if(sync){return new Error("Storage manager not loaded, can not continue");}dfd=new dojo.Deferred();dfd.addCallback(arguments.callee);dojox.storage.manager.addOnLoad(function(){dfd.callback();});return dfd;}});return dfd;};function _1e3(_1e4,_1e5,_1e6,_1e7,_1e8){if(_1e4=="delete"){dojox.storage.remove(_1ce(_1e5),_1c9);}else{dojox.storage.put(_1ce(_1e6),_1e7,function(){},_1c9);}var _1e9=_1e8&&_1e8._store;if(_1e9){_1e9.updateResultSet(_1e9._localBaseResults,_1e9._localBaseFetch);dojox.storage.put(_1ce(_1e8._getRequest(_1e9._localBaseFetch.query).url),dojox.json.ref.toJson(_1e9._localBaseResults),function(){},_1c9);}};dojo.addOnLoad(function(){dojo.connect(dojox.data,"restListener",function(_1ea){var _1eb=_1ea.channel;var _1ec=_1ea.event.toLowerCase();var _1ed=dojox.rpc.JsonRest&&dojox.rpc.JsonRest.getServiceAndId(_1eb).service;_1e3(_1ec,_1eb,_1ec=="post"?_1eb+_1ea.result.id:_1eb,dojo.toJson(_1ea.result),_1ed);});});var _1ee=Rest._change;Rest._change=function(_1ef,_1f0,id,_1f1){if(!_1ca){return _1ee.apply(this,arguments);}var _1f2=_1f0._getRequest(id).url;_1e3(_1ef,_1f2,dojox.rpc.JsonRest._contentId,_1f1,_1f0);var _1f3=dojox.storage.get("dirty",_1c9)||{};if(_1ef=="put"||_1ef=="delete"){var _1f4=_1f2;}else{_1f4=0;for(var i in _1f3){if(!isNaN(parseInt(i))){_1f4=i;}}_1f4++;}_1f3[_1f4]={method:_1ef,id:_1f2,content:_1f1};return _1d5(_1f4,_1f3);};function _1d5(_1f5,_1f6){var _1f7=_1f6[_1f5];var _1f8=dojox.rpc.JsonRest.getServiceAndId(_1f7.id);var _1f9=_1ee(_1f7.method,_1f8.service,_1f8.id,_1f7.content);_1f6[_1f5]=_1f7;dojox.storage.put("dirty",_1f6,function(){},_1c9);_1f9.addBoth(function(_1fa){if(_1d0(_1fa)){return null;}var _1fb=dojox.storage.get("dirty",_1c9)||{};delete _1fb[_1f5];dojox.storage.put("dirty",_1fb,function(){},_1c9);return _1fa;});return _1f9;};dojo.connect(_1cb,"onLoad",_1cc);dojo.connect(_1cb,"onUpdate",_1cc);})();}
