JavaEE5强大的功能高生产率和低复杂性毕业论文外文翻译.docx
- 文档编号:13348262
- 上传时间:2023-06-13
- 格式:DOCX
- 页数:18
- 大小:31.99KB
JavaEE5强大的功能高生产率和低复杂性毕业论文外文翻译.docx
《JavaEE5强大的功能高生产率和低复杂性毕业论文外文翻译.docx》由会员分享,可在线阅读,更多相关《JavaEE5强大的功能高生产率和低复杂性毕业论文外文翻译.docx(18页珍藏版)》请在冰点文库上搜索。
JavaEE5强大的功能高生产率和低复杂性毕业论文外文翻译
原文:
JavaEE5:
Powerandproductivitywithlesscomplexity
AnoverviewofJavaEE5featuresanddeveloper-productivityenhancements
MomentumfororganizationstoadoptJavaPlatform,EnterpriseEdition5(JavaEE5)issteadilyincreasingastheplatform'scontainersupport,developertools,educationalresources,anddeveloper-communityexperienceallimprove.Getahigh-levelviewofthenewproductivityfeaturesandAPIenhancementsinJavaEE5andworkthroughaWebserviceexamplethatdemonstratesitssimplifieddevelopmentmodels.
Introduction
JavaEEtechnologyisanextensiontotheJavalanguageplatformthatenablesyoutocreatescalable,powerful,andportableenterpriseapplications.Itdefinesfourtypesofcontainersforapplicationcomponents:
Web,EnterpriseJavaBean(EJB),applicationclient,andapplet.Thesecontainers,andtheJavaAPIseachmustsupport,aredetailedinanapplication-serverspecificationthatencouragesacompetitivemarketplaceforJavaEEproductswhileguaranteeingserverportabilityforapplicationsthatadheretothespecification.
Thelatestversionoftheplatform,JavaEE5,wasreleasedinMay2006.Primarilyfocusedondeveloperproductivity,JavaEE5bringssimplerprogrammingmodelswithoutsacrificinganyoftheplatform'spowerandrichness.Twomechanisms—Javaannotationsandbetterdefaults—areresponsibleformostofitssimplerdevelopmentmodels.MajorfunctionalimprovementsincludeenhancedWebservicessupportandincorporationofJavaServerFaces(JSF)andtheJavaStandardTagLibrary(JSTL)intotheplatform.
Webservicestechnologies
TheintroductionofannotationsintoJavaEE5makesitsimpletocreatesophisticatedWebserviceendpointsandclientswithlesscodeandashorterlearningcurvethanwaspossiblewithearlierJavaEEversions.Annotations—firstintroducedinJavaSE5—aremodifiersyoucanaddtoyourcodeasmetadata.Theydon'taffectprogramsemanticsdirectly,butthecompiler,developmenttools,andruntimelibrariescanprocessthemtoproduceadditionalJavalanguagesourcefiles,XMLdocuments,orotherartifactsandbehaviorthataugmentthecodecontainingtheannotations.Laterinthearticle,you'llseehowyoucaneasilyturnaregularJavaclassintoaWebservicebyaddingsimpleannotations.
AleapforwardinWebservicessupport
ThecornerstoneofWebservicessupportinJavaEE5isJAX-WS2.0,whichisafollow-ontoJAX-RPC1.1.BothofthesetechnologiesletyoucreateRESTfulandSOAP-basedWebserviceswithoutdealingdirectlywiththetediumofXMLprocessinganddatabindinginherenttoWebservices.DevelopersarefreetocontinueusingJAX-RPC(whichisstillrequiredofJavaEE5containers),butmigratingtoJAX-WSisstronglyrecommended.NewcomerstoJavaWebservicesmightaswellskipJAX-RPCandheadrightforJAX-WS.Thatsaid,it'sgoodtoknowthatbothofthemsupportSOAP1.1overHTTP1.1andsoarefullycompatible:
aJAX-WSWebservicesclientcanaccessaJAX-RPCWebservicesendpoint,andviceversa.
TheadvantagesofJAX-WSoverJAX-RPCarecompelling.JAX-WS:
SupportstheSOAP1.2standard(inadditiontoSOAP1.1).
SupportsXMLoverHTTP.YoucanbypassSOAPifyouwish.
UsestheJavaArchitectureforXMLBinding(JAXB)foritsdata-mappingmodel.JAXBhascompletesupportforXMLschemaandbetterperformance(moreonthatinamoment).
Introducesadynamicprogrammingmodelforbothserverandclient.Theclientmodelsupportsbothamessage-orientedandanasynchronousapproach.
SupportsMessageTransmissionOptimizationMechanism(MTOM),aW3CrecommendationforoptimizingthetransmissionandformatofaSOAPmessage.
UpgradesWebservicesinteroperability(WS-I)support.(ItsupportsBasicProfile1.1;JAX-WSsupportsonlyBasicProfile1.0.)
UpgradesSOAPattachmentsupport.(ItusestheSOAPwithAttachmentsAPIforJava[SAAJ]1.3;JAX-WSsupportsonlySAAJ1.2.)
ThewsimporttoolinJAX-WSautomaticallyhandlesmanyofthemundanedetailsofWebservicedevelopmentandintegrateseasilyintoabuildprocessesinacross-platformmanner,freeingyoutofocusontheapplicationlogicthatimplementsorusesaservice.Itgeneratesartifactssuchasservices,serviceendpointinterfaces(SEIs),asynchronousresponsecode,exceptionsbasedonWSDLfaults,andJavaclassesboundtoschematypesbyJAXB.
JAX-WSalsoenableshigh-performingWebservices.Seeresourceforalinktoanarticle("ImplementingHighPerformanceWebServicesUsingJAX-WS2.0")presentingabenchmarkstudyofequivalentWebserviceimplementationsbasedonthenewJAX-WSstack(whichusestwootherWebservicesfeaturesinJavaEE5—JAXBandStAX)andaJAX-RPCstackavailableinJ2EE1.4.Thestudyfound40%to1000%performanceincreaseswithJAX-WSinvariousfunctionalareasunderdifferentloads.
Webapplicationtechnologies
JavaEE5welcomestwomajorpiecesoffront-endtechnology—JSFandJSTL—intothespecificationtojointheexistingJavaServerPagesandServletspecifications.JSFisasetofAPIsthatenableacomponent-basedapproachtouser-interfacedevelopment.JSTLisasetoftaglibrariesthatsupportembeddingprocedurallogic,accesstoJavaBeans,SQLcommands,localizedformattinginstructions,andXMLprocessinginJSPs.ThemostrecentreleasesofJSF,JSTL,andJSPsupportaunifiedexpressionlanguage(EL)thatallowsthesetechnologiestointegratemoreeasily.
JSF1.2
JSFhasbuilt-insupportforcommonUIconcernssuchascomponentstatemanagement,eventhandling,navigation,user-inputvalidation,andinternationalization.Expertdeveloperscancreatecustomized,powerful,reusablecomponentsorcreatecustomrenderersforclientdevicesotherthanaWebbrowser.Less-technicaluserscanreusecustomcomponents,includingthedefaultJSFtaglibraryforHTMLinterfaces,invisualprogrammingenvironmentssuchasSunJavaStudioCreator.ThisputsthecreationofsophisticatedWebpresentationlayerswithinreachofnoviceprogrammers.
Agrowinglandscapeofthird-partyJSFcomponentsexistsinboththeopensourcecommunityandthelicensed-softwarerealm.You'llturnupdozensofoptionsbysearchingfor"JSFcomponents"or"JSFcomponentlibraries"ontheWeb.ManyofthesecomponentsrelyonAsynchronousJavaScript+XML(Ajax)techniques,whichareadrivingforcebehindthe"Web2.0"experience.WebprogrammerscanusethemtocreateapplicationsthatofferabetteruserexperiencethantraditionalWebapplications,withoutneedingtofusswiththedetailsofwritingAjaxcomponentsfromscratch.
JSP2.1
JSPtechnologyhasbeenaroundsinceJ2EE2.1.ItleveragestheJavaServletspecificationtoenabledeclarativeprogrammingofaUI.ItsupportsprogrammingUIsasdocumentsthataretranslatedintoJavaservlets,compiled,andinvokedbytheWebapplicationcontainertoservicerequests.ThesedocumentstypicallymixJSPdirectivesandscriptletswithapresentationmarkuplanguagesuchasHTML.JSPscanuseanoldersyntaxthatreliesonspecialtagsthatstartwith<%andendwith%>,oronanewersyntaxthatiswell-formedXML.Theytypicallyserveasthe"View"partofaModel-View-Controller(MVC)UIframework.
JSP2.1andJSF1.2aremoremutuallycompatiblethanpriorreleases,primarilybecauseoftheintegrationoftheirELsyntaxintotheunifiedEL.ELenablesoperationssuchas:
AccessingpropertiesofJavaBeansintherequest,session,andapplicationcontexts.
Performinglogicalteststhatdeterminesuchchoicesaswhethertohideorshowaparticularelement.
PerformingcalculationsthataffectnumbersandstringsthatappearintheUI.
Inthepast,thereweredifferencesintheJSPandJSFELsyntaxandhowthecontainerevaluatedthem.TheunifiedELresolvesthesedifferenceswhilealsoaddingfeaturessuchas:
ApluggableframeworktoenablecustomizationofELinterpretation.
SupportfordeferredexpressionsthatcanbeexecutedasneededbyaJSPtaghandler.
Supportforassignmentoperationsthatcan,forexample,useanELexpressiontosetapropertyonaJavaBeanfromwithinJSPcode.
AboonforJSPtag-librarydevelopersisthattaghandlersnowsupportresourceinjectionusingannotations,sotagsthatoncerequiredresourceconfigurationandcodetoperformJavaNamingandDirectoryInterface(JNDI)lookupscannowbegreatlysimplified.
JSTL1.2
JSTLhasbeenaroundforyears,butuntilJavaEE5,itexistedoutsideoftheJavaEEumbrella.JSTLtagsprovidesupportforembeddingthefollowingtypesofelementsinJSPs:
Procedurallogic,suchasloopsandif/elseswitches.
AccesstoJavaBeansthatcanprovidedynamicdatatotheUIorbemodifiedbyUIcode.
SQLcommandstoperformdatabaseaccess.
FormattinginstructionsthatformatUIoutputaccordingtospecificlocales.
XMLprocessing,suchasDocumentObjectModel(DOM)parsingorExtensibleStylesheetLanguage(XSL)transformations.
JSTL1.2isamaintenancereleasethatsupportstheunifiedELandresolvesissuesthatusedtoarisefromtryingtomixJSFtagsandJSTLiterationtagsinthesameJSPpage.
JavaServlet2.5
TheJavaServletspecification—thebackboneofJavaWeb-tiertechnology—isasoldasJavaEEtechnologyitself.Thespecificationisdesignedtoprovideahigh-performing,component-basedapproachtobuildingWebapplicationsthatareportableacrossanyserversthatimplementthespecification.
TheServlet2.5specificationrequiredbyJavaEE5isamaintenancereleasethatincludesminorimprovementsoverthe2.4release.ItintroducesadependencyontheJava5platformalongwithsomeannotationsthatreducetheneedforconfigurationintheWebapplicationdeploymentdescriptor(web.xml)configurationfile.Additionalconfigurationconvenienceshavebeen
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- JavaEE5强大的功能高生产率和低复杂性 毕业论文外文翻译 JavaEE5 强大 功能 生产率 复杂性 毕业论文 外文 翻译