In recent years, the network technology has been developed quickly and the platform of J2EE(Java 2 Enterprise Edition) has been adopted extensively. And the mufti-layer web architecture based on B/S pattern matures gradually. At the same time, with software function demanding higher and higher,and application range being more and more extensible, it appearances a lot of problems such as repetitive development and difficult maintenance. Web application becomes more and more complex. Thus, how to farthest realize "reuse", including reuse of code, reuse of thinking, reuse of design and reuse of resource, which can increase efficiency and develop high-quality software.Consequently, we introduce the conceptin of design patten. What is called design pattern, it refers to the reuse of successful solution, which adequately embodies the reuse of thinking. MVC(Model-View-Controller) pattern can overcome disadvantages of traditional web application development fashion. It separates the control of data and the view of data so as to meet the demand to the mufti-layer web application complicated more and more. So MVC pattern is the first choice of developing the J2EE web application.Being a embodiment of MVC design pattern, Apache Struts is a prevalent framework in establishing current Web design field based on JSP, Servlet, XML technology. So it is a classical MVC design pattern framework. Model is made up of JavaBean or EJB that implement the business logic. Controller is constituted by ActionServlet and Action. A group of JSP files constitute view. The framework lightens the burden to construct the mufti-layer web application and provides components which can be reused. The design of the strutsconfig.xml and the configuration file is an important part for the struts framework. Struts provides controller component and integrates other related technologies to implement the model component and view component of MVC pattern. Struts is fit for all kinds of projects especially for large ones which can embody more advantages of struts.This thesis analyzed the advantages to set up the web application system based on J2EE platform firstly. Then it studied the MVC pattern and struts framework based on the MVC. Finally it introduced the whole process about the design and realization of Intelligent Building OAS'S enterprise inner information management system based on struts framework, which included demand analysis, system design, system realization. The paper laid emphasis on system realization. Firstly, IDE (Integrated Development Environment) was choosed and database was constructed. Secondly, the paper described how to use struts to implement the model, view, controller for MVC and how to deploy two important files, web.xml and struts-config.xml.According to depiction of the thesis, using the pattern of Struts MVC based on J2EE in the development of Web application, which can simplify the work of each stage, normalize the development of whole system, increase the code quality and the system efficiencies, make the system have many advantages, such as able to cross platform, easy to be extended and maintained etc. The system manifests the technicaladvantages of J2EE architecture and MVC pattern. This project can be a reference to the same kind web application development. |