前面介绍的都是传递简单的字符串,现在开始介绍传递复杂类型的对象。如JavaBean、Array、List、Map等。
1、 首先看看服务器端的代码所需要的JavaBean对象
package com.hoo.entity;
import java.io.Serializable;
/**
* <b>function:</b>User Entity
* @author hoojo
* @createDate Dec 16, 2010 10:20:02 PM
* @file User.java
* @package com.hoo.entity
* @project AxisWebService
* @blog http://blog.csdn.net/IBM_hoojo
* @email hoojo_@126.com
* @version 1.0
*/
public class User implements Serializable {
private static final long serialVersionUID = 677484458789332877L;
private int id;
private String name;
private String email;
private String address;
//getter、setter
@Override
public String toString() {
return this.id + "#" + this.name + "#" + this.email + "#" + this.address;
}
}