j2ee的blog的設(shè)計與實現(xiàn).doc
j2ee的blog的設(shè)計與實現(xiàn),j2ee的blog的設(shè)計與實現(xiàn)外文文獻及譯文+業(yè)務(wù)類核心代碼摘要隨著互聯(lián)網(wǎng)絡(luò)的發(fā)展,在自由精神與共享精神的影響下博客(weblog,blog)誕生了。blog的產(chǎn)生讓我們可以有更多的機會向別人展示我們自己的見解與日常生活中的信息。java作為目前最為流行的技術(shù)之一,其企業(yè)版本(j2ee)在設(shè)計與實現(xiàn)web應(yīng)用方面非常適...


內(nèi)容介紹
此文檔由會員 5shao 發(fā)布J2EE的Blog的設(shè)計與實現(xiàn)
外文文獻及譯文+業(yè)務(wù)類核心代碼
摘要
隨著互聯(lián)網(wǎng)絡(luò)的發(fā)展,在自由精神與共享精神的影響下博客(Weblog,Blog)誕生了。Blog的產(chǎn)生讓我們可以有更多的機會向別人展示我們自己的見解與日常生活中的信息。
JAVA作為目前最為流行的技術(shù)之一,其企業(yè)版本(J2EE)在設(shè)計與實現(xiàn)Web應(yīng)用方面非常適合。并且,目前基于J2EE的開源框架也已經(jīng)非常成熟??梢岳矛F(xiàn)有的優(yōu)秀框架進行系統(tǒng)的設(shè)計與構(gòu)建。使用J2EE技術(shù)來設(shè)計實現(xiàn)Blog正是本文的目的所在。
本文將設(shè)計并實現(xiàn)一個基于J2EE的Blog系統(tǒng)。該系統(tǒng)以Struts、Spring以及Hibernate框架為基礎(chǔ)進行設(shè)計與構(gòu)建。Struts、Spring以及Hibernate都是開源框架,分別實現(xiàn)MVC(Model-View-Control)、依賴注入(Dependency Injection)以及ORM(Object/Relation Mapping)。
為了提高系統(tǒng)的性能,持久層使用了延遲加載方式。而這種方式需要持久層接口的生命周期延續(xù)到表示層。通過對現(xiàn)有技術(shù)的分析并結(jié)合本系統(tǒng)的特點,筆者設(shè)計了一個延長持久層接口生命周期的有效方式,LongPersist機制。
在利用以上技術(shù)的同時,通過分析Blog的特點,最終完成系統(tǒng)結(jié)構(gòu)的設(shè)計與實現(xiàn)。本系統(tǒng)主要完成了用戶的登錄、注冊以及管理功能,實現(xiàn)了用戶文章的發(fā)表與管理。通過使用URL Rewrite方式使用戶方便的瀏覽自己以及其他用戶的Blog。
關(guān)鍵詞:博客;J2EE;Struts;Spring;Hibernate;框架;
Abstract
With the development of the Internet, under the influence of the spirit of freedom and sharing blog was born. The blog allows us to have more opportunities to demonstrate our own views,news and daily life to others.
JAVA as currently the most popular technology, its enterprise version (J2EE) in design and implementation of Web applications is very suitable. Moreover, the frameworks that are base on J2EE have been very mature so that we can make use of the existing framework for outstanding system design and construction.By using J2EE technology Design Blog is the purpose of this document.
I managed to design and realize a J2EE-based blog system which is based on Struts, Spring and Hibernate frameworks. Struts, Spring and Hibernate are open source frameworks respectively MVC (Model-View-Control), DI (Dependency Injection) and the ORM (Object / Relation Mapping).
In order to improve the performance of the system using the Persist Layer Lazy Loading. This approach requires persistence layer interface extends life cycle to expressed layer. Based on the analysis of existing technologies and combining the features of the system. I designed an interface layer extension lasting effective way which called LongPersist mechanism by myself.
Using the technologies, by analyzing the characteristics blog, I completed the System design and implementation. The system completed the user login, registration and management functions. And the system supposts users’ publication and management of articles. Users can conveniently browse other users themselves and the blog.
Keywords : blog; J2EE; Struts; Spring; Hibernate; Framework;
目錄
前言 1
1 項目概述 2
1.1 系統(tǒng)概述 2
1.1.1 Blog 2
1.1.2 J2EE Web技術(shù) 3
1.1.3 Struts框架 3
1.1.4 Spring框架 4
1.1.5 Hibernate框架 4
1.1.6 Geronimo J2EE 開源服務(wù)器 4
1.2 業(yè)務(wù)流程描述 4
2 可行性分析 6
2.1 技術(shù)可行性 6
2.2 經(jīng)濟可行性 8
2.2.1 支出 9
2.2.2 效益 9
2.2.3 收益/投資比 9
2.3 操作可行性 9
3 需求分析 10
3.1 系統(tǒng)的設(shè)計思想 10
3.1.1 表示層 10
3.1.2 中間層 12
3.1.3 業(yè)務(wù)邏輯層 12
3.1.3 持久層 12
3.1.3 簡單JAVA對象(POJO) 13
3.2 總體目標(biāo) 13
3.3 具體目標(biāo) 13
3.3.1 系統(tǒng)功能設(shè)計 14
3.3.2 系統(tǒng)特點 14
3.4 系統(tǒng)數(shù)據(jù)流程圖 15
3.5 數(shù)據(jù)字典 18
4 概要設(shè)計 24
4.1 BLOG系統(tǒng)結(jié)構(gòu)圖 24
4.2 BLOG系統(tǒng)接口設(shè)計 24
4.3 數(shù)據(jù)庫設(shè)計 25
4.3.1 數(shù)據(jù)庫需求分析 25
4.3.2 數(shù)據(jù)庫概念結(jié)構(gòu)設(shè)計 26
4.3.3 關(guān)系模式設(shè)計 28
4.3.3 數(shù)據(jù)庫表結(jié)構(gòu) 29
4.5 運行設(shè)計 31
4.6 安全技術(shù) 33
5 詳細(xì)設(shè)計 34
5.1 BLOG系統(tǒng)層間協(xié)作設(shè)計 34
5.2 BLOG系統(tǒng)功能模塊設(shè)計 37
5.2.1 用戶身份 37
5.2.2 用戶Blog列表顯示 38
5.2.3 用戶Blog操作 39
5.2.4 Blog評論 43
5.2.5 文章分類管理 43
5.2.6 系統(tǒng)支撐 45
5.3 BLOG系統(tǒng)LONG PERSIST機制 45
5.3.1 利用request對象和Service對象的finalize方法實現(xiàn) 46
5.3.2 利用request對象和EL語言實現(xiàn) 47
6 編碼 49
6.1 系統(tǒng)使用的語言 49
6.2 編碼工具 49
7 系統(tǒng)實現(xiàn) 50
7.1 用戶注冊界面 50
7.2 用戶登錄界面 50
7.3 BLOG導(dǎo)航界面 50
7.4 用戶BLOG顯示界面 52
7.5 用戶信息管理界面 53
8 測試 56
8.1 用戶注冊測試 56
8.1.1 用戶名測試用例 56
8.1.2 用戶密碼測試用例 56
8.1.3 用戶E-mail地址測試用例 57
8.1.4 用戶Blog空間標(biāo)題測試用例 57
8.1.5 用戶Blog空間描述測試用例 58
8.2 用戶登錄測試 58
8.3 用戶文章發(fā)表測試 59
8.4 用戶評論發(fā)表測試 59
8.5 BLOG系統(tǒng)測試結(jié)論 59
結(jié)論 60
致謝 61
參考文獻 62
附錄A 外文文獻翻譯 63
附錄B 外文文獻原文 76
附錄C 業(yè)務(wù)邏輯核心類代碼 92