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 height="100%" width="100%" layout="absolute"> height="100%" width="1030" paddingLeft="5" paddingRight="5" showDataTips="true" x="0" y="0"> 3. 配置文件: com.east.flex.serverpush.CreateProduct
java ArrayList 转成Flex ArrayCollection
最新推荐文章于 2020-06-27 17:39:14 发布