You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
185 KiB

2 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. /*
  2. This file is part of Ext JS 3.4
  3. Copyright (c) 2011-2013 Sencha Inc
  4. Contact: http://www.sencha.com/contact
  5. GNU General Public License Usage
  6. This file may be used under the terms of the GNU General Public License version 3.0 as
  7. published by the Free Software Foundation and appearing in the file LICENSE included in the
  8. packaging of this file.
  9. Please review the following information to ensure the GNU General Public License version 3.0
  10. requirements will be met: http://www.gnu.org/copyleft/gpl.html.
  11. If you are unsure which license is appropriate for your use, please contact the sales department
  12. at http://www.sencha.com/contact.
  13. Build date: 2013-04-03 15:07:25
  14. */
  15. Ext.data.JsonP.Ext_data_Store({"alternateClassNames":[],"aliases":{"widget":["store"]},"enum":null,"parentMixins":[],"tagname":"class","subclasses":["Ext.data.ArrayStore","Ext.data.DirectStore","Ext.data.GroupingStore","Ext.data.JsonStore","Ext.data.XmlStore"],"extends":"Ext.util.Observable","uses":[],"html":"<div><pre class=\"hierarchy\"><h4>Hierarchy</h4><div class='subclass first-child'><a href='#!/api/Ext.util.Observable' rel='Ext.util.Observable' class='docClass'>Ext.util.Observable</a><div class='subclass '><strong>Ext.data.Store</strong></div></div><h4>Subclasses</h4><div class='dependency'><a href='#!/api/Ext.data.ArrayStore' rel='Ext.data.ArrayStore' class='docClass'>Ext.data.ArrayStore</a></div><div class='dependency'><a href='#!/api/Ext.data.DirectStore' rel='Ext.data.DirectStore' class='docClass'>Ext.data.DirectStore</a></div><div class='dependency'><a href='#!/api/Ext.data.GroupingStore' rel='Ext.data.GroupingStore' class='docClass'>Ext.data.GroupingStore</a></div><div class='dependency'><a href='#!/api/Ext.data.JsonStore' rel='Ext.data.JsonStore' class='docClass'>Ext.data.JsonStore</a></div><div class='dependency'><a href='#!/api/Ext.data.XmlStore' rel='Ext.data.XmlStore' class='docClass'>Ext.data.XmlStore</a></div><h4>Files</h4><div class='dependency'><a href='source/Store.html#Ext-data-Store' target='_blank'>Store.js</a></div></pre><div class='doc-contents'><p>The Store class encapsulates a client side cache of <a href=\"#!/api/Ext.data.Record\" rel=\"Ext.data.Record\" class=\"docClass\">Record</a>\nobjects which provide input data for Components such as the <a href=\"#!/api/Ext.grid.GridPanel\" rel=\"Ext.grid.GridPanel\" class=\"docClass\">GridPanel</a>,\nthe <a href=\"#!/api/Ext.form.ComboBox\" rel=\"Ext.form.ComboBox\" class=\"docClass\">ComboBox</a>, or the <a href=\"#!/api/Ext.DataView\" rel=\"Ext.DataView\" class=\"docClass\">DataView</a>.</p>\n\n\n<p><u>Retrieving Data</u></p>\n\n\n<p>A Store object may access a data object using:<div class=\"mdetail-params\"><ul>\n<li><a href=\"#!/api/Ext.data.Store-cfg-proxy\" rel=\"Ext.data.Store-cfg-proxy\" class=\"docClass\">configured implementation</a> of <a href=\"#!/api/Ext.data.DataProxy\" rel=\"Ext.data.DataProxy\" class=\"docClass\">DataProxy</a></li>\n<li><a href=\"#!/api/Ext.data.Store-cfg-data\" rel=\"Ext.data.Store-cfg-data\" class=\"docClass\">data</a> to automatically pass in data</li>\n<li><a href=\"#!/api/Ext.data.Store-method-loadData\" rel=\"Ext.data.Store-method-loadData\" class=\"docClass\">loadData</a> to manually pass in data</li>\n</ul></div></p>\n\n\n<p><u>Reading Data</u></p>\n\n\n<p>A Store object has no inherent knowledge of the format of the data object (it could be\nan Array, XML, or JSON). A Store object uses an appropriate <a href=\"#!/api/Ext.data.Store-cfg-reader\" rel=\"Ext.data.Store-cfg-reader\" class=\"docClass\">configured implementation</a>\nof a <a href=\"#!/api/Ext.data.DataReader\" rel=\"Ext.data.DataReader\" class=\"docClass\">DataReader</a> to create <a href=\"#!/api/Ext.data.Record\" rel=\"Ext.data.Record\" class=\"docClass\">Record</a> instances from the data\nobject.</p>\n\n\n<p><u>Store Types</u></p>\n\n\n<p>There are several implementations of Store available which are customized for use with\na specific DataReader implementation. Here is an example using an ArrayStore which implicitly\ncreates a reader commensurate to an Array data object.</p>\n\n\n<pre><code>var myStore = new <a href=\"#!/api/Ext.data.ArrayStore\" rel=\"Ext.data.ArrayStore\" class=\"docClass\">Ext.data.ArrayStore</a>({\n fields: ['fullname', 'first'],\n idIndex: 0 // id for each record will be the first element\n});\n</code></pre>\n\n\n<p>For custom implementations create a basic <a href=\"#!/api/Ext.data.Store\" rel=\"Ext.data.Store\" class=\"docClass\">Ext.data.Store</a> configured as needed:</p>\n\n\n<pre><code>// create a <a href=\"#!/api/Ext.data.Record\" rel=\"Ext.data.Record\" class=\"docClass\">Record</a> constructor:\nvar rt = <a href=\"#!/api/Ext.data.Record-static-method-create\" rel=\"Ext.data.Record-static-method-create\" c