Clear Up
SharpKit Reference

CompositeElementLite Class

Namespace: Ext.dom

Base Types

System.Object

Methods

Name Description
add(object, object) Adds elements to this Composite object. @param {HTMLElement[]/Ext.dom.CompositeElementLite} els Either an Array of DOM elements to add, or another Composite object who's elements should be added. @return {Ext.dom.CompositeElementLite} This Composite object.
addElements(object, object)
addListener(object, object, object, object)
clear() Removes all elements.
contains(object) Returns true if this composite contains the passed element @param {String/HTMLElement/Ext.Element/Number} el The id of an element, or an Ext.Element, or an HtmlElement to find within the composite collection. @return {Boolean}
each(JsAction, Element) Calls the passed function for each element in this composite. @param {Function} fn The function to call. @param {Ext.dom.Element} fn.el The current Element in the iteration. **This is the flyweight (shared) Ext.dom.Element instance, so if you require_ a a reference to the dom node, use el.dom.** @param {Ext.dom.CompositeElementLite} fn.c This Composite object. @param {Number} fn.index The zero-based index in the iteration. @param {Object} [scope] The scope (this reference) in which the function is executed. Defaults to the Element. @return {Ext.dom.CompositeElementLite} this
fill(object) Clears this Composite and adds the elements passed. @param {HTMLElement[]/Ext.dom.CompositeElementLite} els Either an array of DOM elements, or another Composite from which to fill this Composite. @return {Ext.dom.CompositeElementLite} this
filter(object) Filters this composite to only elements that match the passed selector. @param {String/Function} selector A string CSS selector or a comparison function. The comparison function will be called with the following arguments: @param {Ext.dom.Element} selector.el The current DOM element. @param {Number} selector.index The current index within the collection. @return {Ext.dom.CompositeElementLite} this
first() Returns the first Element @return {Ext.dom.Element}
getCount() Returns the number of elements in this Composite. @return {Number}
getElement(object)
indexOf(object) Find the index of the passed element within the composite collection. @param {String/HTMLElement/Ext.Element/Number} el The id of an element, or an Ext.dom.Element, or an HtmlElement to find within the composite collection. @return {Number} The index of the passed Ext.dom.Element in the composite collection, or -1 if not found.
invoke(object, object)
item(JsNumber) Returns a flyweight Element of the dom element object at the specified index @param {Number} index @return {Ext.dom.Element}
last() Returns the last Element @return {Ext.dom.Element}
removeElement(object, bool) Removes the specified element(s). @param {String/HTMLElement/Ext.Element/Number} el The id of an element, the Element itself, the index of the element in this composite or an array of any of those. @param {Boolean} [removeDom] True to also remove the element from the document @return {Ext.dom.CompositeElementLite} this
replaceElement(object, object, bool) Replaces the specified element with the passed element. @param {String/HTMLElement/Ext.Element/Number} el The id of an element, the Element itself, the index of the element in this composite to replace. @param {String/Ext.Element} replacement The id of an element or the Element itself. @param {Boolean} [domReplace] True to remove and replace the element in the document too. @return {Ext.dom.CompositeElementLite} this
transformElement(object)

Properties

Name Description
isComposite
© Copyright 2005-2011 SharpKit. All rights reserved.