Upgrade to ExtJS 4.0.1 - Released 05/18/2011
[extjs.git] / docs / output / Ext.CompositeElementLite.js
1 Ext.data.JsonP.Ext_CompositeElementLite({
2   "tagname": "class",
3   "name": "Ext.CompositeElementLite",
4   "doc": "<p>This class encapsulates a <i>collection</i> of DOM elements, providing methods to filter\nmembers, or to perform collective actions upon the whole set.</p>\n\n\n<p>Although they are not listed, this class supports all of the methods of <a href=\"#/api/Ext.core.Element\" rel=\"Ext.core.Element\" class=\"docClass\">Ext.core.Element</a> and\n<a href=\"#/api/Ext.fx.Anim\" rel=\"Ext.fx.Anim\" class=\"docClass\">Ext.fx.Anim</a>. The methods from these classes will be performed on all the elements in this collection.</p>\n\n\n<p>Example:</p>\n\n<pre><code>var els = Ext.select(\"#some-el div.some-class\");\n// or select directly from an existing element\nvar el = Ext.get('some-el');\nel.select('div.some-class');\n\nels.setWidth(100); // all elements become 100 width\nels.hide(true); // all elements fade out and hide\n// or\nels.setWidth(100).hide(true);\n</code></pre>\n\n",
5   "extends": null,
6   "mixins": [
7
8   ],
9   "alternateClassNames": [
10
11   ],
12   "xtype": null,
13   "author": null,
14   "docauthor": null,
15   "singleton": false,
16   "private": false,
17   "cfg": [
18
19   ],
20   "method": [
21     {
22       "tagname": "method",
23       "name": "add",
24       "member": "Ext.CompositeElementLite",
25       "doc": "<p>Adds elements to this Composite object.</p>\n",
26       "params": [
27         {
28           "type": "Mixed",
29           "name": "els",
30           "doc": "<p>Either an Array of DOM elements to add, or another Composite object who's elements should be added.</p>\n",
31           "optional": false
32         },
33         {
34           "type": "Object",
35           "name": "root",
36           "doc": "\n",
37           "optional": false
38         }
39       ],
40       "return": {
41         "type": "CompositeElement",
42         "doc": "<p>This Composite object.</p>\n"
43       },
44       "private": false,
45       "static": false,
46       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
47       "linenr": 75,
48       "html_filename": "CompositeElementLite.html",
49       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-add",
50       "shortDoc": "<p>Adds elements to this Composite object.</p>\n"
51     },
52     {
53       "tagname": "method",
54       "name": "clear",
55       "member": "Ext.CompositeElementLite",
56       "doc": "<p>Removes all elements.</p>\n",
57       "params": [
58
59       ],
60       "return": {
61         "type": "void",
62         "doc": "\n"
63       },
64       "private": false,
65       "static": false,
66       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
67       "linenr": 246,
68       "html_filename": "CompositeElementLite.html",
69       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-clear",
70       "shortDoc": "<p>Removes all elements.</p>\n"
71     },
72     {
73       "tagname": "method",
74       "name": "contains",
75       "member": "Ext.CompositeElementLite",
76       "doc": "<p>Returns true if this composite contains the passed element</p>\n",
77       "params": [
78         {
79           "type": "Object",
80           "name": "el",
81           "doc": "<p>{Mixed} The id of an element, or an <a href=\"#/api/Ext.core.Element\" rel=\"Ext.core.Element\" class=\"docClass\">Ext.core.Element</a>, or an HtmlElement to find within the composite collection.</p>\n",
82           "optional": false
83         }
84       ],
85       "return": {
86         "type": "void",
87         "doc": "<p>Boolean</p>\n"
88       },
89       "private": false,
90       "static": false,
91       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite-more.js",
92       "linenr": 35,
93       "html_filename": "CompositeElementLite-more.html",
94       "href": "CompositeElementLite-more.html#Ext-CompositeElementLite-method-contains",
95       "shortDoc": "<p>Returns true if this composite contains the passed element</p>\n"
96     },
97     {
98       "tagname": "method",
99       "name": "each",
100       "member": "Ext.CompositeElementLite",
101       "doc": "<p>Calls the passed function for each element in this composite.</p>\n\n",
102       "params": [
103         {
104           "type": "Function",
105           "name": "fn",
106           "doc": "<p>The function to call. The function is passed the following parameters:<ul>\n<li><b>el</b> : Element<div class=\"sub-desc\">The current Element in the iteration.\n<b>This is the flyweight (shared) <a href=\"#/api/Ext.core.Element\" rel=\"Ext.core.Element\" class=\"docClass\">Ext.core.Element</a> instance, so if you require a\na reference to the dom node, use el.dom.</b></div></li>\n<li><b>c</b> : Composite<div class=\"sub-desc\">This Composite object.</div></li>\n<li><b>idx</b> : Number<div class=\"sub-desc\">The zero-based index in the iteration.</div></li>\n</ul></p>\n",
107           "optional": false
108         },
109         {
110           "type": "Object",
111           "name": "scope",
112           "doc": "<p>(optional) The scope (<i>this</i> reference) in which the function is executed. (defaults to the Element)</p>\n",
113           "optional": true
114         }
115       ],
116       "return": {
117         "type": "CompositeElement",
118         "doc": "<p>this</p>\n"
119       },
120       "private": false,
121       "static": false,
122       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
123       "linenr": 145,
124       "html_filename": "CompositeElementLite.html",
125       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-each",
126       "shortDoc": "<p>Calls the passed function for each element in this composite.</p>\n\n"
127     },
128     {
129       "tagname": "method",
130       "name": "fill",
131       "member": "Ext.CompositeElementLite",
132       "doc": "<p>Clears this Composite and adds the elements passed.</p>\n",
133       "params": [
134         {
135           "type": "Mixed",
136           "name": "els",
137           "doc": "<p>Either an array of DOM elements, or another Composite from which to fill this Composite.</p>\n",
138           "optional": false
139         }
140       ],
141       "return": {
142         "type": "CompositeElement",
143         "doc": "<p>this</p>\n"
144       },
145       "private": false,
146       "static": false,
147       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
148       "linenr": 175,
149       "html_filename": "CompositeElementLite.html",
150       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-fill",
151       "shortDoc": "<p>Clears this Composite and adds the elements passed.</p>\n"
152     },
153     {
154       "tagname": "method",
155       "name": "filter",
156       "member": "Ext.CompositeElementLite",
157       "doc": "<p>Filters this composite to only elements that match the passed selector.</p>\n",
158       "params": [
159         {
160           "type": "String/Function",
161           "name": "selector",
162           "doc": "<p>A string CSS selector or a comparison function.\nThe comparison function will be called with the following arguments:<ul>\n<li><code>el</code> : Ext.core.Element<div class=\"sub-desc\">The current DOM element.</div></li>\n<li><code>index</code> : Number<div class=\"sub-desc\">The current index within the collection.</div></li>\n</ul></p>\n",
163           "optional": false
164         }
165       ],
166       "return": {
167         "type": "CompositeElement",
168         "doc": "<p>this</p>\n"
169       },
170       "private": false,
171       "static": false,
172       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
173       "linenr": 187,
174       "html_filename": "CompositeElementLite.html",
175       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-filter",
176       "shortDoc": "<p>Filters this composite to only elements that match the passed selector.</p>\n"
177     },
178     {
179       "tagname": "method",
180       "name": "first",
181       "member": "Ext.CompositeElementLite",
182       "doc": "<p>Returns the first Element</p>\n",
183       "params": [
184
185       ],
186       "return": {
187         "type": "Ext.core.Element",
188         "doc": "\n"
189       },
190       "private": false,
191       "static": false,
192       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite-more.js",
193       "linenr": 19,
194       "html_filename": "CompositeElementLite-more.html",
195       "href": "CompositeElementLite-more.html#Ext-CompositeElementLite-method-first",
196       "shortDoc": "<p>Returns the first Element</p>\n"
197     },
198     {
199       "tagname": "method",
200       "name": "getCount",
201       "member": "Ext.CompositeElementLite",
202       "doc": "<p>Returns the number of elements in this Composite.</p>\n",
203       "params": [
204
205       ],
206       "return": {
207         "type": "void",
208         "doc": "<p>Number</p>\n"
209       },
210       "private": false,
211       "static": false,
212       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
213       "linenr": 68,
214       "html_filename": "CompositeElementLite.html",
215       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-getCount",
216       "shortDoc": "<p>Returns the number of elements in this Composite.</p>\n"
217     },
218     {
219       "tagname": "method",
220       "name": "indexOf",
221       "member": "Ext.CompositeElementLite",
222       "doc": "<p>Find the index of the passed element within the composite collection.</p>\n",
223       "params": [
224         {
225           "type": "Object",
226           "name": "el",
227           "doc": "<p>{Mixed} The id of an element, or an <a href=\"#/api/Ext.core.Element\" rel=\"Ext.core.Element\" class=\"docClass\">Ext.core.Element</a>, or an HtmlElement to find within the composite collection.</p>\n",
228           "optional": false
229         }
230       ],
231       "return": {
232         "type": "void",
233         "doc": "<p>Number The index of the passed <a href=\"#/api/Ext.core.Element\" rel=\"Ext.core.Element\" class=\"docClass\">Ext.core.Element</a> in the composite collection, or -1 if not found.</p>\n"
234       },
235       "private": false,
236       "static": false,
237       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
238       "linenr": 214,
239       "html_filename": "CompositeElementLite.html",
240       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-indexOf",
241       "shortDoc": "<p>Find the index of the passed element within the composite collection.</p>\n"
242     },
243     {
244       "tagname": "method",
245       "name": "item",
246       "member": "Ext.CompositeElementLite",
247       "doc": "<p>Returns a flyweight Element of the dom element object at the specified index</p>\n",
248       "params": [
249         {
250           "type": "Number",
251           "name": "index",
252           "doc": "\n",
253           "optional": false
254         }
255       ],
256       "return": {
257         "type": "Ext.core.Element",
258         "doc": "\n"
259       },
260       "private": false,
261       "static": false,
262       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
263       "linenr": 115,
264       "html_filename": "CompositeElementLite.html",
265       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-item",
266       "shortDoc": "<p>Returns a flyweight Element of the dom element object at the specified index</p>\n"
267     },
268     {
269       "tagname": "method",
270       "name": "last",
271       "member": "Ext.CompositeElementLite",
272       "doc": "<p>Returns the last Element</p>\n",
273       "params": [
274
275       ],
276       "return": {
277         "type": "Ext.core.Element",
278         "doc": "\n"
279       },
280       "private": false,
281       "static": false,
282       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite-more.js",
283       "linenr": 27,
284       "html_filename": "CompositeElementLite-more.html",
285       "href": "CompositeElementLite-more.html#Ext-CompositeElementLite-method-last",
286       "shortDoc": "<p>Returns the last Element</p>\n"
287     },
288     {
289       "tagname": "method",
290       "name": "removeElement",
291       "member": "Ext.CompositeElementLite",
292       "doc": "<p>Removes the specified element(s).</p>\n",
293       "params": [
294         {
295           "type": "Mixed",
296           "name": "el",
297           "doc": "<p>The id of an element, the Element itself, the index of the element in this composite\nor an array of any of those.</p>\n",
298           "optional": false
299         },
300         {
301           "type": "Boolean",
302           "name": "removeDom",
303           "doc": "<p>(optional) True to also remove the element from the document</p>\n",
304           "optional": true
305         }
306       ],
307       "return": {
308         "type": "CompositeElement",
309         "doc": "<p>this</p>\n"
310       },
311       "private": false,
312       "static": false,
313       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite-more.js",
314       "linenr": 44,
315       "html_filename": "CompositeElementLite-more.html",
316       "href": "CompositeElementLite-more.html#Ext-CompositeElementLite-method-removeElement",
317       "shortDoc": "<p>Removes the specified element(s).</p>\n"
318     },
319     {
320       "tagname": "method",
321       "name": "replaceElement",
322       "member": "Ext.CompositeElementLite",
323       "doc": "<p>Replaces the specified element with the passed element.</p>\n",
324       "params": [
325         {
326           "type": "Mixed",
327           "name": "el",
328           "doc": "<p>The id of an element, the Element itself, the index of the element in this composite\nto replace.</p>\n",
329           "optional": false
330         },
331         {
332           "type": "Mixed",
333           "name": "replacement",
334           "doc": "<p>The id of an element or the Element itself.</p>\n",
335           "optional": false
336         },
337         {
338           "type": "Boolean",
339           "name": "domReplace",
340           "doc": "<p>(Optional) True to remove and replace the element in the document too.</p>\n",
341           "optional": false
342         }
343       ],
344       "return": {
345         "type": "CompositeElement",
346         "doc": "<p>this</p>\n"
347       },
348       "private": false,
349       "static": false,
350       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
351       "linenr": 223,
352       "html_filename": "CompositeElementLite.html",
353       "href": "CompositeElementLite.html#Ext-CompositeElementLite-method-replaceElement",
354       "shortDoc": "<p>Replaces the specified element with the passed element.</p>\n"
355     }
356   ],
357   "property": [
358     {
359       "tagname": "property",
360       "name": "elements",
361       "member": "Ext.CompositeElementLite",
362       "type": "Array",
363       "doc": "<p>The Array of DOM elements which this CompositeElement encapsulates. Read-only.</p>\n\n\n<p>This will not <i>usually</i> be accessed in developers' code, but developers wishing\nto augment the capabilities of the CompositeElementLite class may use it when adding\nmethods to the class.</p>\n\n\n<p>For example to add the <code>nextAll</code> method to the class to <b>add</b> all\nfollowing siblings of selected elements, the code would be</p>\n\n\n<p><code></p>\n\n<pre>Ext.override(Ext.CompositeElementLite, {\n    nextAll: function() {\n        var els = this.elements, i, l = els.length, n, r = [], ri = -1;\n\n//      Loop through all elements in this Composite, accumulating\n//      an Array of all siblings.\n        for (i = 0; i < l; i++) {\n            for (n = els[i].nextSibling; n; n = n.nextSibling) {\n                r[++ri] = n;\n            }\n        }\n\n//      Add all found siblings to this Composite\n        return this.add(r);\n    }\n});</pre>\n\n\n<p></code></p>\n",
364       "private": false,
365       "static": false,
366       "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite.js",
367       "linenr": 20,
368       "html_filename": "CompositeElementLite.html",
369       "href": "CompositeElementLite.html#Ext-CompositeElementLite-property-elements",
370       "shortDoc": "The Array of DOM elements which this CompositeElement encapsulates. Read-only.\n\n\nThis will not usually be accessed in..."
371     }
372   ],
373   "event": [
374
375   ],
376   "filename": "/Users/nick/Projects/sencha/SDK/platform/core/src/dom/CompositeElementLite-more.js",
377   "linenr": 1,
378   "html_filename": "CompositeElementLite-more.html",
379   "href": "CompositeElementLite-more.html#Ext-CompositeElementLite",
380   "cssVar": [
381
382   ],
383   "cssMixin": [
384
385   ],
386   "component": false,
387   "superclasses": [
388
389   ],
390   "subclasses": [
391     "Ext.CompositeElement"
392   ],
393   "mixedInto": [
394
395   ],
396   "allMixins": [
397
398   ]
399 });