flex传集合到java
public class UserService {public String addUser(Users user){System.err.println("用户名:" + user.getName() + "pass");return "aa";}public String addUser(List<Users> users){System.err.println("size=" + users.size());return "success";}public String addShape(List<MyShape> myShapes){System.err.println("size=" + myShapes.size());return "success";}}public class MyShape {?private int x;?private int y;?private int width;?private int height;?private String source;??public int getX() {??return x;?}?public void setX(int x) {??this.x = x;?}?public int getY() {??return y;?}?public void setY(int y) {??this.y = y;?}?public int getWidth() {??return width;?}?public void setWidth(int width) {??this.width = width;?}?public int getHeight() {??return height;?}?public void setHeight(int height) {??this.height = height;?}?public String getSource() {??return source;?}?public void setSource(String source) {??this.source = source;?}??}
package com.deng.javaflex.vo{?[Bindable]?[RemoteClass(alias="com.deng.MyShape")]?public class MyShape?{??public function MyShape()??{??}????public var x: int;??public var y: int;??public var width:int;??public var height: int;??public var source:String;?????}}???public function chuan():void{????/* var user:Users = new Users();????user.name = "zhangshan";????user.pass = "zhangs";????????var users:ArrayCollection = new ArrayCollection();????users.addItem(user);????chuanService.addUser(users); */????????var shape:MyShape = new MyShape();????shape.x = 10;????shape.y = 50;????shape.width = 100;????shape.height = 200;????shape.source = "../image/a.jpg";????var users:ArrayCollection = new ArrayCollection();????users.addItem(shape);????chuanService.addShape(users);???????}?