研究(资料)Hibernate持久化技术在网上购书系统中的设计与实现毕业论文

持久化  时间:2021-01-30  阅读:()

学号200532580013

密级________________

武汉大学本科毕业论文

Hibernate持久化技术在网上购书系统中的设计与实现

院系名称国际软件学院

专业名称 软件工程

学生姓名 皮攀

指导教师 

二○○九年六月

BACHELOR'S DEGREE THESISOF WUHAN UNIVER SITY

The design and implement ofHibernate persistence in the OnlineBookstore

College Wuhan University

Subject  International Software

Engineering

Name  PiPan

Directed by  Professor

June 2009

郑重声明

本人呈交的学位论文是在导师的指导下独立进行研究工作所取得的成果所有数据、图片资料真实可靠。尽我所知除文中已经注明引用的内容外本学位论文的研究成果不包含他人享有著作权的内容。对本论文所涉及的研究工作做出贡献的其他个人和集体均已在文中以明确的方式标明。本学位论文的知识产权归属于培养单位。

本人签名 日期

摘 要

Hibernate是一个开放源代码的对象关系映射框架它对JDBC进行了非常轻量级的对象封装使得Java程序员可以随心所欲的使用对象编程思维来操纵数据库。Hibernate可以应用在任何使用JDBC的场合既可以在Java的客户端程序使用也可以在Servlet/JSP的Web应用中使用最具革命意义的是Hibernate可以在应用EJB的J 2EE架构中取代CMP完成数据持久化的重任。

本论文主要研究Hibernate的ORMObject Relationship Mapping 框架、持久 化 功 能 以 及 Hiberna te 中 的 六 个 核 心 接 口Session、SessionFactory、Transaction、Query、Criteria和Configuration 并对其进行相关实践。熟悉Hibernate中的框架结构、工作原理。结合Hibernate在网上购书网站上的实践体会和研究Hibernate的ORM框架和持久化。同时本论文也将说明利用Hiberna te的ORM框架和持久化功能来实现网上购书网站的业务层的基本功能。利用Hibernate的相关技术来对其功能进行优化达到高性能。关键词ORM持久化Hibernate的核心接口

ABSTRACT

Hibernate is a open source object-relation mapping framework, whoencapsulates JDBC in a l ight-weight-object way, and this makes Javaprogrammers operate database in the Object-Oriented way arbitrari ly.The Hibernate could user in the place where the JDBC could use, bothusing in the client, and in the the application of Servlet/JSP, themost revolutionary mean is that, the Hibernate could be used in theJ2EE with EJB instead of CMP, to accomplish the persistence.

The aim of this the paper is to study the ORM framework of theHibernate, persistence and the six core interfaces in the Hibernate:Session, SessionFactory, Transaction, Query  Criteria andConfiguration, and implement them in the project . Understanding theframework of the Hibernate, the principle and the API of theHibernate. With the implement of the Hibernate in the OnlineBookstore, experience and study the framework and persistence of theHibernate. Achievement: With the Hibernate to implementing the basefunctions of the business level of the Online Bookstore. Use the othertechnologies of the Hibernate to optimize the functions, reachinghigher efficiency.

Keywords  ORM  Persistence  Hibernate CoreInterface  Session  SessionFactory Transaction Query Criteria andConfiguration

目 录

第1章绪论. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1

1 .1本章内容介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1

1 .2研究背景. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1

1 .3研究现状及发展趋势. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2

1 31研究现状 2

1 32发展趋势 3

1 .4项目研究的目的和意义. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4

141研究目的 4

142研究意义 5

1 .5论文的主要内容. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5

1 .6本章小结. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6

第2章网上购书系统方案设计. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7

1 .7本章内容介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7

1 .8系统简单介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7

1 81系统的定位以及系统开发软件 7

1 82系统的框架 . 7

1 .9系统总体方案设计. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9

1 91用户模块设计 10

1 92管理员模块设计 13

1 93系统模块设计 17

1 .10本章小结. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .17

第3章Hibernate基本技术介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .18

1 .1 1本章内容介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .18

1 .12 Hibernate是什么. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .18

1 .13Hibernate的主要内容. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .19

1 131 Hibernate的框架 19

1 132Hibernate的工作原理 20

1 133Hibernate的核心接口 22

1 134Hibernate API中的主要部分 24

1 .14 Hibernate的优势和劣势. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .24

1 .15本章小结. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25

第4章数据库设计. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26

1 .16本章内容介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26

1 .17数据库需求分析. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26

1 .18数据库详细设计. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .27

1 .19本章小结. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .32

第5章系统实现与验证. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .33

1 .20本章内容介绍. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .33

1 .21系统实现. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .33

1 21 1系统实现模块图 . 33

1 21 2基本类 34

BuyVM($5/月)不限流量流媒体优化VPS主机 1GB内存

BuyVM商家属于比较老牌的服务商,早年有提供低价年付便宜VPS主机还记得曾经半夜的时候抢购的。但是由于这个商家风控非常严格,即便是有些是正常的操作也会导致被封账户,所以后来陆续无人去理睬,估计被我们风控的抢购低价VPS主机已经手足无措。这两年商家重新调整,而且风控也比较规范,比如才入手他们新上线的流媒体优化VPS主机也没有不适的提示。目前,BuyVM商家有提供新泽西、迈阿密等四个机房的VPS主机...

美国云服务器 1核 1G 100M 10G防御 39元/月 物语云计算

物语云计算(MonogatariCloud)是一家成立于2016年的老牌国人商家,主营国内游戏高防独服业务,拥有多家机房资源,产品质量过硬,颇有一定口碑。本次带来的是美国圣何塞 Equinix 机房的高性能I9-10980XE大带宽VPS,去程CN2GIA回程AS9929,美国原生IP,支持解锁奈飞等应用,支持免费安装Windows系统。值得注意的是,物语云采用的虚拟化技术为Hyper-V,资源全...

hosteons:10Gbps带宽,免费Windows授权,自定义上传ISO,VPS低至$21/年,可选洛杉矶达拉斯纽约

hosteons当前对美国洛杉矶、达拉斯、纽约数据中心的VPS进行特别的促销活动:(1)免费从1Gbps升级到10Gbps带宽,(2)Free Blesta License授权,(3)Windows server 2019授权,要求从2G内存起,而且是年付。 官方网站:https://www.hosteons.com 使用优惠码:zhujicepingEDDB10G,可以获得: 免费升级10...

持久化为你推荐
聚酯纤维和棉哪个好聚酯纤维和棉 那个比较暖和啊迈腾和帕萨特哪个好新帕萨特和新迈腾哪个好?小说软件哪个好用免费什么软件看小说全免费ps软件哪个好PS软件用哪种比较好?急用!手机炒股软件哪个好免费手机炒股软件哪个好?dnf魔枪士转职哪个好dnf魔枪士转职哪个职业好?视频软件哪个好安卓系统在线看视频软件哪个好视频软件哪个好什么看视频的软件好qq空间登录登陆进入QQ空间进去了叫登陆登陆了又叫登陆q空间登录腾讯qq空间登陆
域名论坛 过期备案域名查询 双线vps 动态域名解析软件 万网域名证书查询 罗马假日广场 私服服务器 cloudstack mediafire下载工具 域名优惠码 服务器架设 国外在线代理 刀片式服务器 hinet 如何安装服务器系统 论坛主机 免费php空间 免费网络空间 宿迁服务器 apnic 更多