day20-work
//1.定义一个存储Person对象的ArrayList(集合)
new
//2.往list里放入Person对象
.add()
//3.创建对象流 (存在了对象流的内存中)
ByteArrayOutputStream(代替FIle) \\ ObjectOutputStream
//4.使用对象流的writeObject对list进行序列化
.writeObjuect()
//5.创建一个反序列化的ObjuectInputSteam
ByteArrayInputSteam \\ ObjectInputSteam
Person per = new Person("","");
浙公网安备 33010602011771号