Oracle神諭

            BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
            284 隨筆 :: 9 文章 :: 106 評論 :: 0 Trackbacks

          今天在看Jbpm的源代碼中,發現其中的Hibernate中的PO的序列化對象基本上都有一個serialVersionUID的一個私有對象,就上網查找了一部分資料。
          http://www.javapractices.com/Topic45.cjp
          Guidelines for serialVersionUID : (serialVersionUID的指導綱要)

          • always include it as a field, for example: "private static final long serialVersionUID = 7526472295622776147L; " include this field even in the first version of the class, as a reminder(提示) of its importance
          • do not change the value of this field in future versions, unless you are knowingly(老練地) making changes to the class which will render(使..變成) it incompatible(不相容的) with old serialized objects
          • new versions of Serializable classes may or may not be able to read old serialized objects;  it depends upon the nature of the change; provide a pointer to Sun's guidelines for what constitutes a compatible(兼容地) change, as a convenience to future maintainers
          posted on 2005-09-17 21:15 java世界暢談 閱讀(505) 評論(0)  編輯  收藏

          只有注冊用戶登錄后才能發表評論。


          網站導航:
           
          主站蜘蛛池模板: 革吉县| 梁河县| 齐齐哈尔市| 广东省| 榆树市| 宝丰县| 文安县| 万全县| 铜鼓县| 宜昌市| 宜春市| 东海县| 突泉县| 通道| 马公市| 黔西县| 上饶县| 定兴县| 观塘区| 荆门市| 双柏县| 宾阳县| 西贡区| 德化县| 色达县| 祁连县| 德州市| 张家界市| 静海县| 浮山县| 高淳县| 澄迈县| 镇宁| 东乌珠穆沁旗| 盐津县| 辉县市| 永春县| 临漳县| 临城县| 札达县| 河源市|