Java技术在web应用程序设计与实现中的应用外文翻译资料

 2022-08-10 05:08

technics technologies education management

Java technology in the design and implementation of web applications

Sead Mascaron;ovi ć1, Muzafer Saračević1, Hamza Kamberović1, Mensura Kudumović2

1Faculty of Science and Mathematics, University of Niscaron;, Serbia

2University of Sarajevo, Bosnia and Hercegovina

Abstract

This paper reviews the development of Web applications in the Java programming language, namely the creation of a Web application through three-layer architecture

using Java Servlet technology and JavaServerPages. The advantages that we specified in this paper are the development of web applications applying Java technology. Motivated by the current popularity of this technology, our aim was to introduce a way of developing web applications that will become a trend in the future. Primary goal of this paper is to present the most appropriate methods of developing web applications. Conclusions from our study are that the Java is programming language with exceptional opportunities when it comes to web development in terms of simplicity of implementation and speed of execution of the final product.

Keywords: Internet, Java, Java Servlet, JavaServerPages.

1. Introduction

This paper shows the development of Web applications in the Java programming language. Web applications are used in order to respond to the usersrsquo; requests, i.e. generate Web pages on the clients request. The applications are stored on the server and operate on the principle of client-server connection, i.e. client sends a server request, when the server fulfills the request, it sends a response to the client. Web applications are by

nature distributed applications, meaning that they are programs that run on more than one computer and communicate through a network or server. Specifically, web applications are accessed with a web browser and are popular because of the ease of using the browser as a user client.

In the Java platform, web components provide the dynamic extension capabilities for a web server. Web components are either Java servlets or JSP pages. Java Servlets are Java classes that extend the functionality of the server. They are executed on a Web server and act as a connection between the client and the server and their life cycle lasts for as long as there is a connection between the client and the server. JSP technology is a mixture of HTML and Java. It is used to display text on the Web, but has full functionality of Java.

The application is created in the three-layer architecture. It is divided into three layers - presentation, business and data layer. Three-layer architecture is used because the applications built into it are easy to transfer and layers are independent. In one part of this paper we present analysis of the popularity of programming languages for web development in order to prove that Java is a leader in this field. The paper also gives an example of a simple Web application designed using three-layer architecture.

2. Related Work

The advantages of Java over other programming languages are numerous. First of all, programming in the Java programming language is one of the highest degree of

1 2012

technics technologies education management

programming. These written programs are easily portable from one platform to another. This means that the same program can run on computers that are running different operating systems, and PDAs, and even on mobile phones.

Below are some similar themes and papers that we compare with our technologies and techniques in this field. The paper [18] is referred to the implementation of web services using Java technology. Listed is an example of the implementation of web services. The paper

  1. has given a concrete example of the online Web shop that designed and implemented through the Java programming language. In paper [2] authors research field is survey method since the aim of the research is to put forward the tendencies of the students in University towards web-based technology education. Authors of paper [19] present the implemented solution based on universal model of web application that support an auction of any product or service.

In the papers [9,13] authors gives a way of development of advanced Java web application and referred to the web application development using open source and Java technologies. Paper [6] provides a comparative

overview and comparison of the implementation of web services, Java RMI and CORBA services. The paper [4] presented testing the Java web services. The authors of papers [12,17] have provided some Java technologies for web application. In the paper

  1. is given implementation of presentation service using Java Web services.

Authors of paper [14] compares and evaluates the ease of application development and the performance of the three design models by building three versions of an online store application using each of the three design models, respectively. The Servlet technology has been the most widely used technology for building scalable Web applications.

Paper [15] presents empirical study detailing software maintenance for Web-based Java applications to aid in understanding and predicting the software maintenance category and effort. The specific application described is a Java Web-based administrative application in the e-Government arena. This study finds that the Web-based Java application is similar

to the distribution in software maintenance studies, which analyzed non object-oriented and non Web-based applications.

In paper [20] authors describes various Web application frameworks and related emerging technologies pertinent t

剩余内容已隐藏,支付完成后下载完整资料


Java技术在web应用程序设计与实现中的应用

摘要

本文回顾了Java编程语言中Web应用程序的开发,即使用Java Servlet技术和JavaServerPages通过三层架构创建Web应用程序。我们在本文中详细介绍的优势是应用Java技术开发web应用程序。受到当前此技术流行的鼓舞,我们的目标是介绍一种开发web应用程序的方法,这种方法将成为未来的一种趋势。本文的主要目标是介绍开发web应用程序的最合适的方法。从我们的研究中得出的结论是,就实现的简单性和最终产品的执行速度而言,Java是一种具有特别机会的编程语言。

关键词:Internet,Java, Java Servlet, JavaServerPages。

  1. 介绍

本文介绍了用Java语言开发Web应用程序的过程。使用Web应用程序是为了响应用户的请求,即根据客户机的请求生成Web页面。应用程序存储在服务器上,按照客户端-服务器连接的原则进行操作,即客户端发送一个服务器请求,当服务器完成请求后,向客户端发送一个响应。Web应用程序本质上是分布式应用程序,这意味着它们是运行在多台计算机上并通过网络或服务器进行通信的程序。具体地说,web应用程序是通过web浏览器访问的,并且由于将浏览器作为用户客户机使用的方便性而受到欢迎。

在Java平台中,web组件为web服务器提供动态扩展功能。Web组件可以是Java servlet,也可以是JSP页面。Java servlet是扩展服务器功能的Java类。它们在Web服务器上执行,充当客户机和服务器之间的连接,只要客户机和服务器之间有连接,它们的生命周期就会持续。JSP技术是HTML和Java的混合。它用于在Web上显示文本,但是具有Java的全部功能。

应用程序是在三层架构中创建的。它被分为三层——表示层、业务层和数据层。之所以使用三层体系结构,是因为构建在其中的应用程序易于传输,且层是独立的。在本文的一部分中,我们分析了web开发中编程语言的流行程度,以证明Java在这一领域处于领先地位。本文还给出了一个使用三层体系结构设计的简单Web应用程序的实例。

  1. 相关工作

Java相对于其他编程语言的优势是很多的。首先,Java编程语言是最高级别的编程语言之一。这些编写的程序很容易从一个平台移植到另一个平台。这意味着相同的程序可以在运行不同操作系统的计算机上运行,也可以在pda上运行,甚至可以在移动电话上运行。

下面是一些类似的主题和论文,我们将其与我们在这一领域的技术进行比较。论文[18]涉及到使用Java技术实现web服务。列出的是web服务实现的一个示例。论文[10]给出了一个通过Java编程语言设计和实现的在线Web商店的具体示例。本研究以问卷调查法为研究领域,提出大学生对网络技术教育的发展趋势。论文[19]的作者提出了基于web应用程序通用模型的实现解决方案,该模型支持任何产品或服务的拍卖。

论文[9,13]中,作者给出了一种开发高级Java web应用程序的方法,并参考了开源和Java技术开发web应用程序。论文[10]提供了一个比较web服务、Java RMI和CORBA服务实现的概述和比较。论文[6]提出了对Java web服务的测试。论文[12,17]的作者已经为web应用提供了一些Java技术。在论文[7]是使用Java Web服务实现的表示服务。

论文[14]的作者通过分别使用这三种设计模型构建一个在线商店应用程序的三个版本,对这三种设计模型的应用程序开发的易用性和性能进行了比较和评估。Servlet技术是构建可伸缩Web应用程序最广泛使用的技术。

论文[15]详细介绍了基于web的Java应用程序的软件维护的经验研究,以帮助理解和预测软件维护的类别和工作量。所描述的具体应用程序是电子政务领域的基于web的Java管理应用程序。本研究发现基于web的Java应用程序与软件维护研究中的分布相似,后者分析了非面向对象和非基于web的应用程序。

在论文[20]中,作者描述了各种与Java相关的Web应用程序框架和相关的新兴技术。从技术的角度来看。提出了Web应用程序框架的价值主张,以说明框架如何提高应用程序开发的生产率和质量。

论文[22]的作者讨论了Web和Java如何标志着fatware的死亡和基于租用组件的动态计算的诞生。真正的范式转变将是用附加在Web页面上的面向事务的Java applet出租来替换购买的软件包。

论文[5]展示了如何成功地实现组合和协调范式用于设计具有多媒体数据交换的协同Java应用程序。作者介绍了协同多媒体应用的发展,并指定了一个基于web的分布式平台来支持组件间的通信。

在论文[16]中,作者分析了用于web应用程序开发的典型学术环境的特征和约束。介绍了一组基于java的web技术和工具,并对这些技术和工具进行了回顾。这项工作背后的动机是为大学教师和学生提供有关新兴技术和可用工具的全面资源,以促进web应用程序的快速开发。

  1. Java技术在web应用程序开发中的优势

Web应用程序是根据动态Web页面的请求创建的应用程序,应该在Web服务器提供的平台上执行。

java是一种编程语言,其主要特征是在翻译代码级别上完全独立于物理平台。Java程序以applet的形式嵌入到Web页面中,然后分发给用户[21]。其结果是有可能

客户端应用程序在网络上的自动分发和安装,而不管客户端实际的物理平台是什么——支持Java的Web浏览器就足够了。WWW和Java技术的结合使客户机-服务器信息系统得以实现,与传统系统不同,客户机-服务器信息系统具有以下特点:

·简单且被广泛接受的用户界面形式(Web浏览器);

·客户端应用程序的自动分发和安装;

·更简单的维护,特别是在异构网络中。

    1. Java技术在Web应用开发中的普及

在本文的这一部分中,我们提出了选择Java编程语言的几个原因。我们还与其他编程语言进行了比较分析。这项研究是使用Tiobe1门户进行的,该门户根据商业web应用程序编程的共享程度对编程语言进行排序。Tiobe的排名基于其在全球范围内拥有的熟练工程师、课程和第三方供应商。

Tiobe使用谷歌、Bing和Yahoo搜索引擎来衡量网络“聊天”,从而衡量每种编程语言的受欢迎程度。

表1.网络编程语言排名

排名

排名

编程语言

比例

2011.12

2011.1

(%)

1

1

Java

17.05

2

2

C

16.52

3

6

C#

8.65

4

3

C

7.85

5

8

Objective-C

7.06

6

5

PHP

5.64

7

7

(Visual) Basic

4.31

8

4

Python

3.15

9

10

Perl

2.93

10

9

JavaScript

2.47

Java是这一类别的赢家,其他门户网站的研究也证明了这一点。根据研究门户网站Dice.com2,有35.7%的部分,而根据Evans Data3的一些信息,估计Java在编写web应用程序方面可达45%。

在下面的表格中,我们列出了前一阶段在web开发中编程语言的排名。

表2.前期排名

编程

排名

排名

排名

语言

2011.12

2007.2

1997.2

Java

1

1

4

C

2

2

1

C#

3

8

/

C

4

3

2

Objective-C

5

44

/

PHP

6

4

/

Visual Basic

7

5

6

Python

8

7

27

Perl

9

6

5

JavaScript

10

9

25

    1. 两个Java技术的描述(Java Servlet and JavaServerPages)

Java编程语言中的Web应用程序可以使用两种技术实现:Java servlet和Java Server Pages (JSP)。最优的结果是通过这两种技术的组合来实现的,如下所述。

servlet是动态处理请求并生成响应的Java对象。生成的响应通常是HTML(超文本标记语言)的形式,但是数据可以是另一种形式,例如XML(可扩展标记语言)。servlet在服务器上运行,程序代码永远不会在服务器之外公开,只提交派生的结果。这样,作者的代码就得到了完全的保护,而不是使用Java Applet技术在Web浏览器中运行的应用程序。使用servlet的另一个好处是它们的可移植性。它们可以在不同的服务器上运行,而不需要更改代码。

客户机向服务器发送请求后,它加载servlet并创建一个单独的线程。每个servlet都有doGet()或doPost()方法,它们用于处理请求。对于每个请求,都要创建一个单独的线程,这使得执行速度比任何其他技术都要快得多,在这种技术中,操作系统必须为每个请求创建一个新进程,初始化它,运行它,然后清理它,这是非常慢的。这种技术的一个例子是应用程序逻辑在用户界面中是“硬编码”的。

剩余内容已隐藏,支付完成后下载完整资料


资料编号:[238066],资料为PDF文档或Word文档,PDF文档可免费转换为Word

原文和译文剩余内容已隐藏,您需要先支付 30元 才能查看原文和译文全部内容!立即支付

以上是毕业论文外文翻译,课题毕业论文、任务书、文献综述、开题报告、程序设计、图纸设计等资料可联系客服协助查找。