资源描述:
《基于ssh架构的交流社区毕业设计外文翻译》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、毕业设计说明书英文文献及中文翻译班级:学号:姓名:学院:专业:指导教师:2外文参考文献原文1StrutsFrameworkBasedonMVCInthetraditionalWebapplication,JavaServerPages(JSP)pagesareresponsibleforhandlingallthings,forexample,receivingrequests,executingbusinesslogics,choosingthenextpage.Thesecomplicatedthin
2、gsmayleadtochaosofJSPpages’codesandbeharmfulfortheextensionandmaintenanceofpages.TheModel-View-Controller(MVC)modeseparatestheprogrammingcodesintothreedifferentareas,whichhassolvedtheaboveproblem.MVCcanrealizeJ2EEapplicationsystem'sstratificationandtheloo
3、secouplingofthreelayersormultilayer,anditisarealizationwayoforientingdynamiccontent.TheMVCmodedividesapplicationintothreecorecomponentsofModel,ViewandController.StrutsisarealizationofMVC.ItisanopensourceWebapplicationframeworkandusesServletandJSPmarksthat
4、belongtotheJ2EEnormasapartoftherealization.StrutsinheritsMVCcharacteristicsandrealizessomecorrespondingchangesandextensionaccordingtoJ2EEtraits.StrutsseparatesJavacodesofJSPbyJavaBeanandActionclasstobetheMVCmode,transmitsdataamongthethreepartitionsofModel
5、,ViewandController,demonstratestheconnectionbetweenvariousclassesandJSPpagesbyconfigurationfilesfinallyanditintendstorealizetheseparationofpresentationlayer,businesslayeranddatalayer.TheStrutsstructureisshowninFigure1.TheModelcontainsthebusinesslogicthate
6、xchangesdatawithapersistencelayer.TheViewisinchargeofproducingwhatisdirectlyvisibletotheuser,e.g.webpages.TheControlleristhelayerthatreceivesrequestsfromclients,determineswhatbusinesslogictakesplaceandwheretogonext.IntheStrutsframework,theModelusesJavacla
7、ssesforthebusinesslogic.TheViewcanbeimplementedwithJSPandtheTaglibofStruts.TheControllerisaJ2EEcomponentknownasServlet,morespecificallyanActionServletobject,whichdetermineswhatorwhenlogicgetsexecutedandwherethecontrolshouldgetdirected.Figure1.Strutsstruct
8、ure2HibernateFrameworkBasedonORMWorkingwithboththeobject-orientedsoftwareandtherelationaldatabaseisacomplicatedtaskwithJavaDatabaseConnectivity(JDBC)becausethereismismatchbetweenhowdataisrepresentedinobjectsversusre