【正文】
re creating a new Eclipse project to work with one of the example source directories, just choose File New Project, specify that you want to create a Java project and click Next, give it a name (Hibernate Ch3 in my cas。ll be looking at the examples as they exist in Chapter 3, which is the sample chapter available online. You can also download the source for all of the examples from the book39。s Notebook, you39。s time to start configuring the plugin to put it through its paces! ConfigurationOnce Eclipse es back up, you can close the Install/Update perspective. Open a Java project that uses Hibernate. If you39。s Mac OS X implementation。re using a onebutton mouse) in the Feature Updates view and choose New Site Bookmark. Figure 1. Adding the Hibernate Synchronizer plugin site to the Update ManagerIn the resulting dialog, enter the URL for the version of the plugin that you need. The URL to be entered depends on your Eclipse version:Eclipse : Eclipse 3: You also need to assign a name for the new bookmark. Hibernate Synchronizer makes a lot of sense. Once you click Finish, the new bookmark will appear in the Feature Updates actually install the plugin, click on the disclosure triangle to the left of the bookmark, and again on the next one that appears inside of it, until you can see the icon for the plugin itself. When you click on that, the Preview view will update to show you an interface that allows you to install the Install Now to actually install it, and let Eclipse walk you through the TradeOffs, below, for some discussion about this license agreement. You may wish to read it carefully before deciding to use Hibernate Synchronizer in a project of your own. I think it39。re using it, be sure to apply your own judgment in following these steps! If it helps, my impression is that Hibernate Synchronizer39。m still using the production release, . As I write this, Eclipse 3 has entered its release candidate phase, and I am very much looking forward to being able to upgrade to a production release of version 3 when I return from JavaOne later this summer. (The main reason I mention this is to emphasize that the following instructions are written from an Eclipse 2 perspective。s builtin Update Manager. The plugin offers separate update sites for users of Eclipse and the forthing Eclipse 3. Because I39。s New menu that provides wizards for creating Hibernate configuration and mapping files, and adds contextual menu entries in the package explorer and in other appropriate places, providing easy access to relevant Hibernate operations.OK, enough abstract description, time to get down to the practical stuff! After all, you were already probably interested in this, or you wouldn39。 these may be more helpful if your environment calls for another approach.) In fact, the Hibernate Synchronizer plugin removes the need for you to think about updating your Java code when you change your mapping document. In a very Eclipselike way, it automatically updates the Java code as you edit the mapping. But it goes even farther than Hibernate39。ve found so far, the Hibernate Synchronizer interested me most because it seems to best support the kind of mappingcentric workflow I adopted throughout my Developer39。s Notebook. It turns out there are several such efforts underway。s very helpful. So I became curious about whether anyone had written plugins to work with Hibernate, since I39。s Hibernate book, on how to use Hibernate with Eclipse, which was also a top votegetter in the poll.IntroductionI recently started using Eclipse as my development environment, in part because of its support for the many platforms on which I develop, and in part because Eclipse is a great example of the power of an open, extensible environment in which people all around the world can contribute. I39。JSP(中文版)[M].北京:中國(guó)電力出版社,2006.[11] 耿祥義,(第2版)[M].北京:清華大學(xué)出版社,2007.[12] (美)[M].北京:人民郵電出版社,2009.[13] (德)[M].北京:人民郵電出版社,2006.[14] 張孝祥,徐明華,[M].北京:清華大學(xué)出版社,2009.[15] 張孝祥,徐明華,于坤,周大慶. JavaScript基礎(chǔ)與案例開發(fā)詳解[M].北京:清華大學(xué)出版社,2009.[16] :java對(duì)象持久化技術(shù)詳解(第2版)[M].北京:電子工業(yè)出版社,2009.附錄A 外文翻譯原文部分 外文出處: Chinese Journal of Electronic Working with Hibernate in EclipseAbstract: With our survey results showing a huge interest in Hibernate, we thought this would be a good week to bring back this piece, by the author of O39。四年的風(fēng)風(fēng)雨雨,我們一同走過,充滿著關(guān)愛,給我留下了值得珍藏的最美好的記憶。在此向軟件學(xué)院全體老師表示深深的感謝和崇高的敬意?;厥姿哪辏〉昧诵┰S成績(jī),生活中有快樂也有艱辛。四年的大學(xué)生活就快走入尾聲,校園生活就要?jiǎng)澤暇涮?hào),心中是無盡的難舍與眷戀。正是有了他們的悉心幫助和支持,才使我的畢業(yè)論文工作順利完成,在此向華東交通大學(xué),軟件學(xué)院的全體老師表示由衷的謝意。本設(shè)計(jì)在吳銳老師的悉心指導(dǎo)和嚴(yán)格要求下完成,從課題選擇、方案論證到具體設(shè)計(jì)和調(diào)試,無不凝聚著吳老師的心血和汗水。從開始接到論文題目到系統(tǒng)的實(shí)現(xiàn),再到論文文章的完成,每走一步對(duì)我來說都是新的嘗試與挑戰(zhàn),這也是我在大學(xué)期間獨(dú)立完成的最大的項(xiàng)目。 4) 信息刪除測(cè)試刪除某條信息,顯示刪除成功后查詢剛刪除的那條信息,當(dāng)詢不到剛刪除的那條信息時(shí)說明刪除成功5) 密碼修改測(cè)試 按照系統(tǒng)的要求修改完密碼后,退出管理系統(tǒng),返回到登錄界面,用剛修改的新密碼登錄管理界面,不能成功登錄說明修改失敗,能成功登錄說明密碼修改成功。 2) 信息查詢測(cè)試查詢符合某特定條件的信息,檢查查詢結(jié)果是否和設(shè)計(jì)時(shí)數(shù)據(jù)一致,以確認(rèn)數(shù)據(jù)的正確性。當(dāng)用戶名和密碼都正確但驗(yàn)證碼錯(cuò)誤時(shí)會(huì)提醒驗(yàn)證碼錯(cuò)誤。 (2) 測(cè)試數(shù)據(jù)1)登錄測(cè)試輸入正確的用戶名,密碼及驗(yàn)證碼成功進(jìn)入管理頁(yè)面。 本系統(tǒng)運(yùn)行環(huán)境為網(wǎng)絡(luò)版,在運(yùn)行時(shí)對(duì)系統(tǒng)整體性能要有一定的要求,軟件要求:系統(tǒng)環(huán)境winXP+MySQL 硬件系統(tǒng)環(huán)境要求:P4 、1G內(nèi)存、80G硬盤系統(tǒng)運(yùn)行時(shí)對(duì)數(shù)據(jù)的保密性要求不高對(duì)一般的數(shù)據(jù)不要求進(jìn)行加密。測(cè)試是開發(fā)過程中一個(gè)獨(dú)立且非常重要的階段,測(cè)試過程基本上與開發(fā)過程平行。硬件測(cè)試、網(wǎng)絡(luò)測(cè)試可以根據(jù)具體的性能指標(biāo)來進(jìn)行。應(yīng)根據(jù)開發(fā)各階段的需求、設(shè)計(jì)等文檔或程序的內(nèi)部結(jié)構(gòu)精心設(shè)計(jì)測(cè)試用例,并利用這些實(shí)例來運(yùn)行程序,以便發(fā)現(xiàn)錯(cuò)誤。 } return (forward)。 } }else{ forward = loginFail。 } }else{ forward = loginFail。 (hostelList, hostelList)。 forward = loginFail。 if((id+)!=1){ Student student = (id)。 String forward = new String()。 String realCode = (String)().getAttribute(checkCode)。 String password = (spassword)。 } return (forward)。 } }else{ forward = fail。 } }else{ forward = fail。 }else{ ().setAttribute(loginAdmin, admin)。 if(().equals(password)){ if (!(checkCode)) { (result, 驗(yàn)證碼不正確!)。 String forward = new String()。 String realCode = (String)().getAttribute(checkCode)。 String password = (apassword)。 }else{ return (loginSuperAdmin)。 if (!(checkCode)) {