1 Ext.data.JsonP.Ext_data_Types({
3 "name": "Ext.data.Types",
4 "doc": "<p>This is s static class containing the system-supplied data types which may be given to a <a href=\"#/api/Ext.data.Field\" rel=\"Ext.data.Field\" class=\"docClass\">Field</a>.<p/>\n<p>The properties in this class are used as type indicators in the <a href=\"#/api/Ext.data.Field\" rel=\"Ext.data.Field\" class=\"docClass\">Field</a> class, so to\ntest whether a Field is of a certain type, compare the <a href=\"#/api/Ext.data.Field-cfg-type\" rel=\"Ext.data.Field-cfg-type\" class=\"docClass\">type</a> property against properties\nof this class.</p>\n<p>Developers may add their own application-specific data types to this class. Definition names must be UPPERCASE.\neach type definition must contain three properties:</p>\n<div class=\"mdetail-params\"><ul>\n<li><code>convert</code> : <i>Function</i><div class=\"sub-desc\">A function to convert raw data values from a data block into the data\nto be stored in the Field. The function is passed the collowing parameters:\n<div class=\"mdetail-params\"><ul>\n<li><b>v</b> : Mixed<div class=\"sub-desc\">The data value as read by the Reader, if undefined will use\nthe configured <tt><a href=\"#/api/Ext.data.Field-cfg-defaultValue\" rel=\"Ext.data.Field-cfg-defaultValue\" class=\"docClass\">defaultValue</a></tt>.</div></li>\n<li><b>rec</b> : Mixed<div class=\"sub-desc\">The data object containing the row as read by the Reader.\nDepending on the Reader type, this could be an Array (<a href=\"#/api/Ext.data.reader.Array\" rel=\"Ext.data.reader.Array\" class=\"docClass\">ArrayReader</a>), an object\n(<a href=\"#/api/Ext.data.reader.Json\" rel=\"Ext.data.reader.Json\" class=\"docClass\">JsonReader</a>), or an XML element.</div></li>\n</ul></div></div></li>\n<li><code>sortType</code> : <i>Function</i> <div class=\"sub-desc\">A function to convert the stored data into comparable form, as defined by <a href=\"#/api/Ext.data.SortTypes\" rel=\"Ext.data.SortTypes\" class=\"docClass\">Ext.data.SortTypes</a>.</div></li>\n<li><code>type</code> : <i>String</i> <div class=\"sub-desc\">A textual data type name.</div></li>\n</ul></div>\n<p>For example, to create a VELatLong field (See the Microsoft Bing Mapping API) containing the latitude/longitude value of a datapoint on a map from a JsonReader data block\nwhich contained the properties <code>lat</code> and <code>long</code>, you would define a new data type like this:</p>\n<pre><code>// Add a new Field data type which stores a VELatLong object in the Record.\nExt.data.Types.VELATLONG = {\n convert: function(v, data) {\n return new VELatLong(data.lat, data.long);\n },\n sortType: function(v) {\n return v.Latitude; // When sorting, order by latitude\n },\n type: 'VELatLong'\n};\n</code></pre>\n<p>Then, when declaring a Model, use \n<pre><code>var types = Ext.data.Types; // allow shorthand type access\nExt.define('Unit',\n extend: 'Ext.data.Model', \n fields: [\n { name: 'unitName', mapping: 'UnitName' },\n { name: 'curSpeed', mapping: 'CurSpeed', type: types.INT },\n { name: 'latitude', mapping: 'lat', type: types.FLOAT },\n { name: 'latitude', mapping: 'lat', type: types.FLOAT },\n { name: 'position', type: types.VELATLONG }\n ]\n});\n</code></pre>\n\n",
9 "alternateClassNames": [
25 "tagname": "property",
27 "member": "Ext.data.Types",
29 "doc": "<p>This data type means that no conversion is applied to the raw data before it is placed into a Record.</p>\n",
32 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
34 "html_filename": "Types.html",
35 "href": "Types.html#Ext-data-Types-property-AUTO"
38 "tagname": "property",
40 "member": "Ext.data.Types",
42 "doc": "<p>This data type means that the raw data is converted into a boolean before it is placed into\na Record. The string \"true\" and the number 1 are converted to boolean <code>true</code>.</p>\n\n\n<p>The synonym <code>BOOLEAN</code> is equivalent.</p>\n\n",
45 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
47 "html_filename": "Types.html",
48 "href": "Types.html#Ext-data-Types-property-BOOL",
49 "shortDoc": "This data type means that the raw data is converted into a boolean before it is placed into\na Record. The string \"tru..."
52 "tagname": "property",
54 "member": "Ext.data.Types",
56 "doc": "<p>This data type means that the raw data is converted into a boolean before it is placed into\na Record. The string \"true\" and the number 1 are converted to boolean <code>true</code>.</p>\n\n\n<p>The synonym <code>BOOL</code> is equivalent.</p>\n\n",
59 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
61 "html_filename": "Types.html",
62 "href": "Types.html#Ext-data-Types-property-BOOLEAN",
63 "shortDoc": "This data type means that the raw data is converted into a boolean before it is placed into\na Record. The string \"tru..."
66 "tagname": "property",
68 "member": "Ext.data.Types",
70 "doc": "<p>This data type means that the raw data is converted into a Date before it is placed into a Record.\nThe date format is specified in the constructor of the <a href=\"#/api/Ext.data.Field\" rel=\"Ext.data.Field\" class=\"docClass\">Ext.data.Field</a> to which this type is\nbeing applied.</p>\n",
73 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
75 "html_filename": "Types.html",
76 "href": "Types.html#Ext-data-Types-property-DATE",
77 "shortDoc": "This data type means that the raw data is converted into a Date before it is placed into a Record.\nThe date format is..."
80 "tagname": "property",
82 "member": "Ext.data.Types",
84 "doc": "<p>This data type means that the raw data is converted into a number before it is placed into a Record.</p>\n\n<p>The synonym <code>NUMBER</code> is equivalent.</p>\n\n",
87 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
89 "html_filename": "Types.html",
90 "href": "Types.html#Ext-data-Types-property-FLOAT",
91 "shortDoc": "This data type means that the raw data is converted into a number before it is placed into a Record.\n\nThe synonym NUM..."
94 "tagname": "property",
96 "member": "Ext.data.Types",
98 "doc": "<p>This data type means that the raw data is converted into an integer before it is placed into a Record.</p>\n\n<p>The synonym <code>INTEGER</code> is equivalent.</p>\n\n",
101 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
103 "html_filename": "Types.html",
104 "href": "Types.html#Ext-data-Types-property-INT",
105 "shortDoc": "This data type means that the raw data is converted into an integer before it is placed into a Record.\n\nThe synonym I..."
108 "tagname": "property",
110 "member": "Ext.data.Types",
112 "doc": "<p>This data type means that the raw data is converted into an integer before it is placed into a Record.</p>\n\n<p>The synonym <code>INT</code> is equivalent.</p>\n\n",
115 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
117 "html_filename": "Types.html",
118 "href": "Types.html#Ext-data-Types-property-INTEGER",
119 "shortDoc": "This data type means that the raw data is converted into an integer before it is placed into a Record.\n\nThe synonym I..."
122 "tagname": "property",
124 "member": "Ext.data.Types",
126 "doc": "<p>This data type means that the raw data is converted into a number before it is placed into a Record.</p>\n\n<p>The synonym <code>FLOAT</code> is equivalent.</p>\n\n",
129 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
131 "html_filename": "Types.html",
132 "href": "Types.html#Ext-data-Types-property-NUMBER",
133 "shortDoc": "This data type means that the raw data is converted into a number before it is placed into a Record.\n\nThe synonym FLO..."
136 "tagname": "property",
138 "member": "Ext.data.Types",
140 "doc": "<p>This data type means that the raw data is converted into a String before it is placed into a Record.</p>\n",
143 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
145 "html_filename": "Types.html",
146 "href": "Types.html#Ext-data-Types-property-STRING"
149 "tagname": "property",
151 "member": "Ext.data.Types",
153 "doc": "<p>A regular expression for stripping non-numeric characters from a numeric value. Defaults to <tt>/[\\$,%]/g</tt>.\nThis should be overridden for localization.</p>\n",
156 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
158 "html_filename": "Types.html",
159 "href": "Types.html#Ext-data-Types-property-stripRe",
160 "shortDoc": "A regular expression for stripping non-numeric characters from a numeric value. Defaults to /[\\$,%]/g.\nThis should be..."
166 "filename": "/Users/nick/Projects/sencha/SDK/platform/src/data/Types.js",
168 "html_filename": "Types.html",
169 "href": "Types.html#Ext-data-Types",