var wt=obj.widgetType; var ts=_9a4[wt]; if(!ts){ _9a4[wt]={"string":null,"node":null}; if(_9a2){ ts={}; }else{ ts=_9a4[wt]; } } if((!obj.templateString)&&(!_9a2)){ obj.templateString=_9a1||ts["string"]; } if((!obj.templateNode)&&(!_9a2)){ obj.templateNode=ts["node"]; } if((!obj.templateNode)&&(!obj.templateString)&&(_9a3)){ var _9a8=dojo.hostenv.getText(_9a3); if(_9a8){ _9a8=_9a8.replace(/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im,""); var _9a9=_9a8.match(/<body[^>]*>\s*([\s\S]+)\s*<\/body>/im); if(_9a9){ _9a8=_9a9[1]; } }else{ _9a8=""; } obj.templateString=_9a8; if(!_9a2){ _9a4[wt]["string"]=_9a8; } } if((!ts["string"])&&(!_9a2)){ ts.string=obj.templateString; } }; 
dojo.widget.fillFromTemplateCache = function( /*DomWidget*/       obj,                         /*String||dojo.uri.Uri*/  templatePath,                        /*String, optional*/    templateString,                        /*Boolean, optional*/   avoidCache){  // summary:  //    static method to build from a template w/ or w/o a real widget in  //    place  // obj: an instance of dojo.widget.DomWidget to initialize the template for  // templatePath: the URL to get the template from   // templateString:  //    a string to use in lieu of fetching the template from a URL  // avoidCache:  //    should the template system not use whatever is in the cache and  //    always use the passed templatePath or templateString?  // dojo.debug("avoidCache:", avoidCache);  var tpath = templatePath || obj.templatePath;  var tmplts = dojo.widget._templateCache;  if(!obj["widgetType"]) { // don't have a real template here    do {      var dummyName = "__dummyTemplate__" + dojo.widget._templateCache.dummyCount++;    } while(tmplts[dummyName]);    obj.widgetType = dummyName;  }  var wt = obj.widgetType;  var ts = tmplts[wt];  if(!ts){    tmplts[wt] = { "string": null, "node": null };    if(avoidCache){      ts = {};    }else{      ts = tmplts[wt];    }  }  if((!obj.templateString)&&(!avoidCache)){    obj.templateString = templateString || ts["string"];  }  if((!obj.templateNode)&&(!avoidCache)){    obj.templateNode = ts["node"];  }  if((!obj.templateNode)&&(!obj.templateString)&&(tpath)){    // fetch a text fragment and assign it to templateString    // NOTE: we rely on blocking IO here!    var tstring = dojo.hostenv.getText(tpath);    if(tstring){      // strip <?xml ...?> declarations so that external SVG and XML      // documents can be added to a document without worry      tstring = tstring.replace(/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im, "");      var matches = tstring.match(/<body[^>]*>\s*([\s\S]+)\s*<\/body>/im);      if(matches){        tstring = matches[1];      }    }else{      tstring = "";    }    obj.templateString = tstring;    if(!avoidCache){      tmplts[wt]["string"] = tstring;    }  }  if((!ts["string"])&&(!avoidCache)){    ts.string = obj.templateString;  }}
6315	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/6315/90939f35f46f873d9b1f5c5f818ecf012711dc71/dojo.js/buggy/src/main/resources/org/apache/struts2/static/dojo/dojo.js