如何在 ActionScript 3.0 Flash IDE 中使用类似 ArrayCollection 的功能? [英] How can I use ArrayCollection like feature in ActionScript 3.0 Flash IDE?

查看:29
本文介绍了如何在 ActionScript 3.0 Flash IDE 中使用类似 ArrayCollection 的功能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我听说 Flex 上有 ArrayCollection,那么我如何在 ActionScript 3.0 和 Flash IDE 中使用类似 ArrayCollection 的功能.

I heard that ArrayCollection on Flex, so how can I use ArrayCollection like feature in ActionScript 3.0 and Flash IDE.

推荐答案

等效的 Flash IDE 类是 fl.data.DataProvider.

The equivalent Flash IDE class is fl.data.DataProvider.

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/fl/data/DataProvider.html

DataProvider 类提供的方法和属性允许您查询和修改任何基于列表的组件中的数据 - 例如,在 List、DataGrid、TileList 或 ComboBox 组件中.

The DataProvider class provides methods and properties that allow you to query and modify the data in any list-based component--for example, in a List, DataGrid, TileList, or ComboBox component.

数据提供程序是用作数据源的项目的线性集合 - 例如,数组.数据提供程序中的每一项都是一个对象或 XML 对象,其中包含一个或多个数据字段.您可以使用 DataProvider.getItemAt() 方法按索引访问数据提供程序中包含的项目.

A data provider is a linear collection of items that serve as a data source--for example, an array. Each item in a data provider is an object or XML object that contains one or more fields of data. You can access the items that are contained in a data provider by index, by using the DataProvider.getItemAt() method.

这篇关于如何在 ActionScript 3.0 Flash IDE 中使用类似 ArrayCollection 的功能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆