Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


Share this Page URL
Help

Chapter 7: Using Data Providers and Coll... > Using simple data access properties ... - Pg. 143

ADOBE FLEX 3 149 Adobe Flex 3 Developer Guide <!-- A ComboBox populated by the collection view of the Array. --> <mx:ComboBox id="cb1" rowCount="10" dataProvider="{myAC}"/> <mx:Button id="b1" label="Add MD" click="addItemToMyAC();"/> </mx:HBox> </mx:Application> Using simple data access properties and methods Collections provide simple properties and methods for indexed access to linear data. These properties and methods are defined in the IList interface, which provides a direct representation of the underlying data object. Any operation that changes the collection also changes the data provider in a similar manner: if you insert an item as the third item in the collection, it is also the third item in the underlying data object, which is an Array or an XMLList object when working with ArrayCollection objects and XMLListCollection objects, respectively. Note: If you use the ICollectionView interface to sort or filter a collection, do not use the IList interface to manipulate the data, because the results are indeterminate. Simple data access properties and methods let you do the following: