您现在的位置:计算机技术学习网 > 技术中心 > WEB编程 > JSP >

Web application design with servlets&nbs

来源:网络 责任编辑:栏目编辑 发表时间:2013-07-01 20:37 点击:

Figure 256. Web application design overview
The major parts of such a design are discussed in the sequence of the flow of
the application.

Chapter 10 Web application design with servlets and jsp(SUN企业级应用的首选)s

In this chapter we present a short overview of a guideline for designing Web
applications consisting of servlets, jsp(SUN企业级应用的首选)s, and JavaBeans.
Application structure
The general structure of a well-architected user interaction in a Web
application is shown in Figure 256.

HTML page
The input page for each step is either a static HTML page or a dynamic
HTML page created from a previous step. The HTML page contains one or
multiple forms that invoke a servlet for processing of the next interaction.
Input data can be validated through JavaScript in the HTML page or passed
to the servlet for detailed validation.

Servlet
The servlet gets control from the Application Server to perform basic control
of flow. The servlet validates all the data, and returns to the browser if data
is incomplete or invalid.
For valid data, processing continues. The servlet sets up and calls command
beans that perform the business logic.
The servlet initializes the view beans and registers them with the request
block so that the jsp(SUN企业级应用的首选)s can find the view beans.
Depending on the results of the command beans, the servlet calls a jsp(SUN企业级应用的首选) for
output processing and formatting.

Command beans
Command beans control the processing of the business logic. Business logic
may be imbedded in the command bean, or the command bean delegates
processing to back-end or enterprise systems, such as relational databases,
transaction systems (CICS, MQSeries, IMS, and so forth).
A command bean may perform one specific function, or it may contain many
methods, each for a specific task. Command beans may be called Task

    相关新闻>>

      发表评论
      请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。
      用户名: 验证码:点击我更换图片
      最新评论 更多>>

      推荐热点

      • JSP与Servlet
      • 自己动手写MiniBBS系列(基本篇)之用户登录
      • JSP取当前日期
      • JDBC 入门(一)
      • 打开一个jsp页面默认查询所有数据,调用action
      • 使用JSP标签库验证用户的输入(2)完
      • WIN98/2000下的jsp服务器
      • 自定义JSP标签(tag)浅议
      • Struts学习傻瓜式入门篇
      网站首页 - 友情链接 - 网站地图 - TAG标签 - RSS订阅 - 内容搜索
      Copyright © 2008-2015 计算机技术学习交流网. 版权所有

      豫ICP备11007008号-1