java ArrayList 轉成Flex ArrayCollection

  1. server package com.east.flex.serverpush; import java.util.ArrayList; import java.util.List; import java.util.Random; import com.east.flex.serverpush.entity.Product; /** * * @author East(張棟芳) * * 2010-6-13 */ public class CreateProduct extends Thread { private List productList = new ArrayList(); public CreateProduct() { // this.start(); } @Override public void run() { // while (true) { // // Product p = new Product(); // Random random = new Random(); // p.setMonth("Jan"); // p.setProfit(random.nextInt(1000)); // p.setExpenses(random.nextInt(500)); // p.setAmount(random.nextInt(300)); // // productList.add(p); // if (productList.size() == 15) { // try { // break; // } catch (Exception se) { // System.out.println(se.getMessage()); // } // } // System.out.println("Size is :" + productList.size()); // } } public List getProductList() { for (int i = 0; i productList) { this.productList = productList; } } 2.client import com.east.flex.entity.Product width="100%" layout="absolute"> width="1030" paddingLeft="5" paddingRight="5" showDataTips="true" x="0" y="0"> width="107"/> width="107" click="autoRefresh(event)"/> 3. 配置文件: com.east.flex.serverpush.CreateProduct
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章