Spring框架-毕业论文外文文献翻译_第1页
Spring框架-毕业论文外文文献翻译_第2页
Spring框架-毕业论文外文文献翻译_第3页
Spring框架-毕业论文外文文献翻译_第4页
全文预览已结束

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

外文文献翻译SpringFramework Springisanopensourceframework,andSpringwaslaunchedin2003asalightweightJavadevelopmentframeworkcreatedbyRodJohnson.Inanutshell,Springisahierarchical,JavaSE/EEfull-stack(one-stop)lightweightopensourceframework.ThepowerfulJavaBeansbasedconfigurationmanagementusingtheInversionofControl(IoC)principlemakesapplicationcomponentsfasterandeasier. 1.facilitatedecouplingandsimplifydevelopment ThroughtheIoCcontainerprovidedbySpring,wecancontroldependenciesbetweenobjectsbySpring,avoidingexcessiveprogramcouplingcausedbyhardcoding.WithSpring,usersdonothavetowritecodeforthebottomtierrequirementsofsingleinstanceschemaclasses,properties,fileparsing,andsoon,andcanfocusmoreontoptierapplications. 2.AOPprogrammingsupport ThroughtheSpringfunctionalityprovidedbyAOP,itiseasytoimplementfaceorientedprogramming,andmanyfeaturesthatarenoteasilyimplementedwithtraditionalOOPcanbeeasilyhandledbyAOP. 3.declarativetransactionsupport InSpring,wecanextricateourselvesfromtediousandtedioustransactionmanagementcodeandflexiblymanagethetransactionthroughdeclarativemanner,soastoimprovetheefficiencyandqualityofdevelopment. 4.convenienceprogramtesting Almostalltestworkcanbedoneinanoncontainerdependentprogrammingmanner,andinSpring,testingisnolongerexpensive,butsomethingtodo.Forexample,SpringsupportsJunit4andcaneasilytestSpringprogramsbyannotations. 5.convenientintegrationofvariousexcellentframework Springdoesnotexcludeallkindsofexcellentopensourceframework,onthecontrary,SpringcanreducethedifficultyoftheuseofSpringframework,providesaframeworkforavarietyofexcellent(suchasStruts,Hibernate,Hessian,Quartz)directlysupportthe. 6.reducethedifficultyofusingJavaEEAPI SpringprovidesathinlayerofencapsulationformanydifficultJava,EE,API(suchasJDBC,JavaMail,remotecalls,etc.),andtheuseoftheseJavaEEAPIisgreatlyreducedthroughthesimplepackageofSpring. 7.Javasourcecodeisaclassicexampleoflearning Springsourcecode,clearstructure,exquisitedesignoriginality,embodiesthemasteroftheJavadesignpatternandtheflexibleuseofJavatechnologyaccomplishment.SpringframeworksourcecodeisundoubtedlythebestpracticeexampleofJavatechnology.IfyouwanttoquicklyimproveyourJavaskillsandapplicationdevelopmentlevelinashorttime,learningan. TheroleofMVC-Springisintegration,butnotjustintegration,andtheSpringframeworkcanbeseenasaframeworkforenterprisesolutionlevels.Theclientsendsarequest,theservercontroller(implementedbyDispatcherServlet)tocompletetherequestforwarding,callacontrollerformappingclassHandlerMapping,theclassisusedtomaprequeststothecorrespondingprocessortoprocesstherequest.HandlerMappingwillrequestismappedtothecorrespondingprocessorController(equivalenttoAction)inSpringifyouwritesomeprocessorcomponents,thegeneralimplementationoftheControllerinterfaceinController,youcancallServiceorDAOtooperatedatafromtheDAOModelAndViewusedtostoretheretrieveddata,somedatacanalsobestoredinresponsetotheview.Ifyouwanttoreturntheresulttotheuser,italsoprovidesaviewofViewResolvercomponentinSpringframework,thecomponentlabeledControllerreturnsaccordingto,findthecorrespondingview,theresponseresponsebacktotheuser. Eachmodule(orcomponent)thatmakesuptheSpringframeworkcanexistalone,orcanbeimplementedinconjunctionwithoneormoreothermodules.Eachmodulehasthefollowingfunctions:1,thecorecontainer:thecorecontainerprovidesthebasicfunctionalityoftheSpringframework(Spring,Core).ThemaincomponentofthecorecontainerisBeanFactory,whichisimplementedinfactorymode.BeanFactoryusesthecontrolinversion(IOC)patterntoseparateapplicationconfigurationanddependencyspecificationsfromtheactualapplicationcode.Spring框架 Spring是一个开源框架,Spring是于2003年兴起的一个轻量级的Java开发框架,由RodJohnson创建。简单来说,Spring是一个分层的JavaSE/EEfull-stack(一站式)轻量级开源框架。强大的基于JavaBeans的采用控制反转(InversionofControl,IoC)原则的配置管理,使得应用程序的组件更加快捷简易。 1.方便解耦,简化开发 通过Spring提供的IoC容器,我们可以将对象之间的依赖关系交由Spring进行控制,避免硬编码所造成的过度程序耦合。有了Spring,用户不必再为单实例模式类、属性文件解析等这些很底层的需求编写代码,可以更专注于上层的应用。 2.AOP编程的支持 通过Spring提供的AOP功能,方便进行面向切面的编程,许多不容易用传统OOP实现的功能可以通过AOP轻松应付。 3.声明式事务的支持 在Spring中,我们可以从单调烦闷的事务管理代码中解脱出来,通过声明式方式灵活地进行事务的管理,提高开发效率和质量。 4.方便程序的测试 可以用非容器依赖的编程方式进行几乎所有的测试工作,在Spring里,测试不再是昂贵的操作,而是随手可做的事情。例如:Spring对Junit4支持,可以通过注解方便的测试Spring程序。 5.方便集成各种优秀框架 Spring不排斥各种优秀的开源框架,相反,Spring可以降低各种框架的使用难度,Spring提供了对各种优秀框架(如Struts,Hibernate、Hessian、Quartz)等的直接支持。 6.降低JavaEEAPI的使用难度 Spring对很多难用的JavaEEAPI(如JDBC,JavaMail,远程调用等)提供了一个薄薄的封装层,通过Spring的简易封装,这些JavaEEAPI的使用难度大为降低。 7.Java源码是经典学习范例 Spring的源码设计精妙、结构清晰、匠心独运,处处体现着大师对Java设计模式灵活运用以及对Java技术的高深造诣。Spring框架源码无疑是Java技术的最佳实践范例。如果想在短时间内迅速提高自己的Java技术水平和应用开发水平,学习和研究Spring源码将会使你收到意想不到的效果。MVC——Spring的作用是整合,但不仅仅限于整合,Spring框架可以被看做是一个企业解决方案级别的框架。客户端发送请求,服务器控制器(由DispatcherServlet实现的)完成请求的转发,控制器调用一个用于映射的类HandlerMapping,该类用于将请求映射到对应的处理器来处理请求。HandlerMapping将请求映射到对应的处理器Controller(相当于Action)在Spring当中如果写一些处理器组件,一般实现Controller接口,在Controller中就可以调用一些Service或DAO来进行数据操作ModelAndView用于存放从DAO中取出的数据,还可以存放响应视图

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论