define("dojo/data/ItemFileReadStore",["../_base/kernel","../_base/lang","../_base/declare","../_base/array","../_base/xhr","../Evented","./util/filter","./util/simpleFetch","../date/stamp"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9){var_a=_3("dojo.data.ItemFileReadStore",[_6],{constructor:function(_b){this._arrayOfAllItems=[];this._arrayOfTopLevelItems=[];this._loadFinished=false;this._jsonFileUrl=_b.url;this._ccUrl=_b.url;this.url=_b.url;this._jsonData=_b.data;this.data=null;this._datatypeMap=_b.typeMap||{};if(!this._datatypeMap["Date"]){this._datatypeMap["Date"]={type:Date,deserialize:function(_c){return_9.fromISOString(_c);}};}this._features={"dojo.data.api.Read":true,"dojo.data.api.Identity":true};this._itemsByIdentity=null;this._storeRefPropName="_S";this._itemNumPropName="_0";this._rootItemPropName="_RI";this._reverseRefMap="_RRM";this._loadInProgress=false;this._queuedFetches=[];if(_b.urlPreventCache!==undefined){this.urlPreventCache=_b.urlPreventCache?true:false;}if(_b.hierarchical!==undefined){this.hierarchical=_b.hierarchical?true:false;}if(_b.clearOnClose){this.clearOnClose=true;}if("failOk"in_b){this.failOk=_b.failOk?true:false;}},url:"",_ccUrl:"",data:null,typeMap:null,clearOnClose:false,urlPreventCache:false,failOk:false,hierarchical:true,_assertIsItem:function(_d){if(!this.isItem(_d)){thrownewError(this.declaredClass+": Invalid item argument.");}},_assertIsAttribute:function(_e){if(typeof_e!=="string"){thrownewError(this.declaredClass+": Invalid attribute argument.");}},getValue:function(_f,_10,_11){var_12=this.getValues(_f,_10);return(_12.length>0)?_12[0]:_11;},getValues:function(_13,_14){this._assertIsItem(_13);this._assertIsAttribute(_14);return(_13[_14]||[]).slice(0);},getAttributes:function(_15){this._assertIsItem(_15);var_16=[];for(varkeyin_15){if((key!==this._storeRefPropName)&&(key!==this._itemNumPropName)&&(key!==this._rootItemPropName)&&(key!==this._reverseRefMap)){_16.push(key);}}return_16;},hasAttribute:function(_17,_18){this._assertIsItem(_17);this._assertIsAttribute(_18);return(_18in_17);},containsValue:function(_19,_1a,_1b){var_1c=undefined;if(typeof_1b==="string"){_1c=_7.patternToRegExp(_1b,false);}returnthis._containsValue(_19,_1a,_1b,_1c);},_containsValue:function(_1d,_1e,_1f,_20){return_4.some(this.getValues(_1d,_1e),function(_21){if(_21!==null&&!_2.isObject(_21)&&_20){if(_21.toString().match(_20)){returntrue;}}else{if(_1f===_21){returntrue;}}});},isItem:function(_22){if(_22&&_22[this._storeRefPropName]===this){if(this._arrayOfAllItems[_22[this._itemNumPropName]]===_22){returntrue;}}returnfalse;},isItemLoaded:function(_23){returnthis.isItem(_23);},loadItem:function(_24){this._assertIsItem(_24.item);},getFeatures:function(){returnthis._features;},getLabel:function(_25){if(this._labelAttr&&this.isItem(_25)){returnthis.getValue(_25,this._labelAttr);}returnundefined;},getLabelAttributes:function(_26){if(this._labelAttr){return[this._labelAttr];}returnnull;},filter:function(_27,_28,_29){var_2a=[],i,key;if(_27.query){var_2b,_2c=_27.queryOptions?_27.queryOptions.ignoreCase:false;var_2d={};for(keyin_27.query){_2b=_27.query[key];if(typeof_2b==="string"){_2d[key]=_7.patternToRegExp(_2b,_2c);}else{if(_2binstanceofRegExp){_2d[key]=_2b;}}}for(i=0;i<_28.length;++i){var_2e=true;var_2f=_28[i];if(_2f===null){_2e=false;}else{for(keyin_27.query){_2b=_27.query[key];if(!this._containsValue(_2f,key,_2b,_2d[key])){_2e=false;}}}if(_2e){_2a.push(_2f);}}_29(_2a,_27);}else{for(i=0;i<_28.length;++i){var_30=_28[i];if(_30!==null){_2a.push(_30);}}_29(_2a,_27);}},_fetchItems:function(_31,_32,_33){var_34=this;if(this._loadFinished){this.filter(_31,this._getItemsArray(_31.queryOptions),_32);}else{if(this._jsonFileUrl!==this._ccUrl){_1.deprecated(this.declaredClass+": ","To change the url, set the url property of the store,"+" not _jsonFileUrl. _jsonFileUrl support will be removed in 2.0");this._ccUrl=this._jsonFileUrl;this.url=this._jsonFileUrl;}else{if(this.url!==this._ccUrl){this._jsonFileUrl=this.url;this._ccUrl=this.url;}}if(this.data!=null){this._jsonData=this.data;this.da