Intent mIntent = new Intent(Login.this, PlatformActivity.class);
Bundle bundle = new Bundle();
bundle.putSerializable("user",user);
mIntent.putExtras(bundle);
startActivity(mIntent);
public class User implements Serializable {
private List<UserAccount> userAccountList;
...
...
}
的RuntimeException:Parcelable遇到IOException异常写入序列化对象(名称= com.orbis.mobile.User)的Android如何对象的用户从一个活动传递到片段
用户是不是序列化的,我想知道如何用arrayList传递Object。如果用户没有设置userAccountList,它可以工作。
List可以被序列化,UserAccount对象抛出异常。 http://stackoverflow.com/a/1387966/2402866 – 2014-10-07 21:54:20
@AlonLevanon发布你链接确认我说什么。 'List'不是'serializable''ArrayList'。 – Blundell 2014-10-08 07:48:24