a:24:{s:9:"#provides";s:16:"dijit._Templated";s:9:"#resource";s:13:"_Templated.js";s:9:"#requires";a:3:{i:0;a:2:{i:0;s:6:"common";i:1;s:13:"dijit._Widget";}i:1;a:3:{i:0;s:6:"common";i:1;s:11:"dojo.string";i:2;s:4:"dojo";}i:2;a:3:{i:0;s:6:"common";i:1;s:11:"dojo.parser";i:2;s:4:"dojo";}}s:16:"dijit._Templated";a:3:{s:4:"type";s:8:"Function";s:7:"summary";s:55:"Mixin for widgets that are instantiated from a template";s:9:"classlike";b:1;}s:31:"dijit._Templated.templateString";a:4:{s:9:"prototype";s:16:"dijit._Templated";s:4:"tags";a:1:{i:0;s:9:"protected";}s:4:"type";s:6:"String";s:7:"summary";s:235:"A string that represents the widget template. Pre-empts the templatePath. In builds that have their strings "interned", the templatePath is converted to an inline templateString, thereby preventing a synchronous network call.";}s:29:"dijit._Templated.templatePath";a:4:{s:9:"prototype";s:16:"dijit._Templated";s:4:"tags";a:1:{i:0;s:9:"protected";}s:4:"type";s:6:"String";s:7:"summary";s:69:"Path to template (HTML file) for this widget relative to dojo.baseUrl";}s:34:"dijit._Templated.widgetsInTemplate";a:4:{s:9:"prototype";s:16:"dijit._Templated";s:4:"tags";a:1:{i:0;s:9:"protected";}s:4:"type";s:7:"Boolean";s:7:"summary";s:107:"Should we parse the template to find widgets that might be declared in markup inside it? False by default.";}s:31:"dijit._Templated._skipNodeCache";a:3:{s:9:"prototype";s:16:"dijit._Templated";s:7:"private";b:1;s:7:"summary";s:0:"";}s:28:"dijit._Templated._stringRepl";a:7:{s:9:"prototype";s:16:"dijit._Templated";s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:4:"tmpl";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:866:" var className = this.declaredClass, _this = this; // Cache contains a string because we need to do property replacement // do the property replacement return dojo.string.substitute(tmpl, this, function(value, key){ if(key.charAt(0) == '!'){ value = dojo.getObject(key.substr(1), false, _this); } if(typeof value == "undefined"){ throw new Error(className+" template:"+key); } // a debugging aide if(value == null){ return ""; } // Substitution keys beginning with ! will skip the transform step, // in case a user wishes to insert unescaped markup, e.g. ${!foo} return key.charAt(0) == "!" ? value : // Safer substitution, see heading "Attribute values" in // http://www.w3.org/TR/REC-html40/appendix/notes.html#h-B.3.2 value.toString().replace(/"/g,"""); //TODO: add &? use encodeXML method? }, this);";s:7:"summary";s:62:"Does substitution of ${foo} type properties in template string";s:4:"tags";s:7:"private";s:7:"private";b:1;}s:31:"dijit._Templated.buildRendering";a:4:{s:9:"prototype";s:16:"dijit._Templated";s:4:"type";s:8:"Function";s:6:"source";s:3315:"dojo.provide("dijit._Templated"); dojo.require("dijit._Widget"); dojo.require("dojo.string"); dojo.require("dojo.parser"); dojo.declare("dijit._Templated", null, { // summary: // Mixin for widgets that are instantiated from a template // // templateString: [protected] String // A string that represents the widget template. Pre-empts the // templatePath. In builds that have their strings "interned", the // templatePath is converted to an inline templateString, thereby // preventing a synchronous network call. templateString: null, // templatePath: [protected] String // Path to template (HTML file) for this widget relative to dojo.baseUrl templatePath: null, // widgetsInTemplate: [protected] Boolean // Should we parse the template to find widgets that might be // declared in markup inside it? False by default. widgetsInTemplate: false, // skipNodeCache: [protected] Boolean // If using a cached widget template node poses issues for a // particular widget class, it can set this property to ensure // that its template is always re-built from a string _skipNodeCache: false, _stringRepl: function(tmpl){ // summary: // Does substitution of ${foo} type properties in template string // tags: // private var className = this.declaredClass, _this = this; // Cache contains a string because we need to do property replacement // do the property replacement return dojo.string.substitute(tmpl, this, function(value, key){ if(key.charAt(0) == '!'){ value = dojo.getObject(key.substr(1), false, _this); } if(typeof value == "undefined"){ throw new Error(className+" template:"+key); } // a debugging aide if(value == null){ return ""; } // Substitution keys beginning with ! will skip the transform step, // in case a user wishes to insert unescaped markup, e.g. ${!foo} return key.charAt(0) == "!" ? value : // Safer substitution, see heading "Attribute values" in // http://www.w3.org/TR/REC-html40/appendix/notes.html#h-B.3.2 value.toString().replace(/"/g,"""); //TODO: add &? use encodeXML method? }, this); }, // method over-ride buildRendering: function(){ // summary: // Construct the UI for this widget from a template, setting this.domNode. // tags: // protected // Lookup cached version of template, and download to cache if it // isn't there already. Returns either a DomNode or a string, depending on // whether or not the template contains ${foo} replacement parameters. var cached = dijit._Templated.getCachedTemplate(this.templatePath, this.templateString, this._skipNodeCache); var node; if(dojo.isString(cached)){ node = dojo._toDom(this._stringRepl(cached)); }else{ // if it's a node, all we have to do is clone it node = cached.cloneNode(true); } this.domNode = node; // recurse through the node, looking for, and attaching to, our // attachment points and events, which should be defined on the template node. this._attachTemplateNodes(node); if(this.widgetsInTemplate){ var cw = (this._supportingWidgets = dojo.parser.parse(node)); this._attachTemplateNodes(cw, function(n,p){ return n[p]; }); } this._fillContent(this.srcNodeRef);";s:7:"summary";s:71:"Construct the UI for this widget from a template, setting this.domNode.";}s:29:"dijit._Templated._fillContent";a:7:{s:9:"prototype";s:16:"dijit._Templated";s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:6:"source";a:1:{s:4:"type";s:7:"DomNode";}}s:6:"source";s:144:" var dest = this.containerNode; if(source && dest){ while(source.hasChildNodes()){ dest.appendChild(source.firstChild); } }";s:7:"summary";s:136:"Relocate source contents to templated container node. this.containerNode must be able to receive children, or exceptions will be thrown.";s:4:"tags";s:9:"protected";s:7:"private";b:1;}s:37:"dijit._Templated._attachTemplateNodes";a:8:{s:9:"prototype";s:16:"dijit._Templated";s:4:"type";s:8:"Function";s:10:"parameters";a:2:{s:8:"rootNode";a:2:{s:4:"type";s:21:"DomNode|Array[Widgets";s:7:"summary";s:65:"the node to search for properties. All children will be searched.";}s:11:"getAttrFunc";a:3:{s:4:"type";s:8:"Function";s:8:"optional";b:1;s:7:"summary";s:75:"a function which will be used to obtain property for a given DomNode/Widget";}}s:6:"source";s:1943:" getAttrFunc = getAttrFunc || function(n,p){ return n.getAttribute(p); }; var nodes = dojo.isArray(rootNode) ? rootNode : (rootNode.all || rootNode.getElementsByTagName("*")); var x = dojo.isArray(rootNode) ? 0 : -1; for(; x/im, ""); var matches = tString.match(/]*>\s*([\s\S]+)\s*<\/body>/im); if(matches){ tString = matches[1]; } }else{ tString = ""; } return tString; //String";s:7:"summary";s:206:"Strips <?xml ...?> declarations so that external SVG and XML documents can be added to a document without worry. Also, if the string is an HTML document, only the part inside the body tag is returned.";s:7:"returns";s:6:"String";s:7:"private";b:1;}s:29:"dijit._Widget.dojoAttachEvent";a:2:{s:9:"prototype";s:13:"dijit._Widget";s:7:"summary";s:0:"";}s:29:"dijit._Widget.dojoAttachPoint";a:2:{s:9:"prototype";s:13:"dijit._Widget";s:7:"summary";s:0:"";}s:21:"dijit._Widget.waiRole";a:2:{s:9:"prototype";s:13:"dijit._Widget";s:7:"summary";s:0:"";}s:22:"dijit._Widget.waiState";a:2:{s:9:"prototype";s:13:"dijit._Widget";s:7:"summary";s:0:"";}s:5:"cache";a:1:{s:7:"summary";s:0:"";}s:5:"value";a:1:{s:7:"summary";s:0:"";}s:5:"dijit";a:2:{s:4:"type";s:6:"Object";s:7:"summary";s:0:"";}}