[JAVA] 深克隆 另外实现方法【序列化】
private static List cloneObject(
Object obj) throws Exception {
ByteArrayOutputStream byteOut = new ByteArrayOutputStream();
ObjectOutputStream out = new ObjectOutputStream(byteOut);
out.writeObject(obj);
ByteArrayInputStream byteIn = new ByteArrayInputStream(byteOut
.toByteArray());
ObjectInputStream in = new ObjectInputStream(byteIn);
return in.readObject();
}
相关文档:
通过JDBC,我们可以向oracle插入大对象,如图片,音频,长文本等,其插入方法有很多,这里演示一下通过流更新更新的形式插入CLOB大对象。
这是一个存储文本的例子,解释我会在程序中以注释的形式写出
/**
* 将生成的表样存储到数据库
*
* @param htmlParam
* @return
*/
  ......
线程
1---锁对象的方法----obj.wait()----obj.notify()----针对当前线程
& ......
1.代码的装入
2.代码的校验
3.和代码的执行
体会: dao层 方法名 修改后 调用其的 services 。action 都将被重新 编译。
--- 基本类型使用 :
体会:dao层 基本类型 尽量使用对象类型,以为 基本类型 能自动类型提升 而对象类型 为 null 主动类型转换 会报错:NullPointerException
小心 类型主动提升 &nb ......