Asp.net| program recently we used ASP.net to develop an enterprise internal software development management system, this is the first time we use ASP.net, the language is C #. Below I focus on the structure of our system, I implore you to advise.
Let's talk about the background of system development. System is not large, the purpose of development is also used to manage our company's software development process, while achieving learning. NET's purpose. Since it is the company's own system, but also with the purpose of learning, so in the framework of the system, we also strive to structure integrity and clarity, and the performance of other places in the second consideration. There are a lot of imperfections are inevitable, and we look at it with a critical eye on the good:
The system is divided into 4 layers, namely (WEB) presentation layer, (façade) Business appearance layer, (Rules) business logic Layer and (data) layer. Each layer belongs to project of its own. There is also a project for dealing with common business. The invocation relationship between them is as follows:
Web--> façade--> Rules--> Data--> DB
The functions and characteristics of each layer are as follows:
The data layer is called the database layer, which is responsible for data extraction and transformation. The data layer inherits from the DataTable. It establishes a database mapping relationship, which means that each field in the database has a constant associated with it. It encapsulates the Select,insert and update methods. You can manipulate it like a DataTable, such as calling a Select method before taking a value, and then using Odata.getvalue (I, the alias of the database field) to get the value. Before inserting and updating operations, set the value with Odata.getvalue (I, alias of the database field, value), and then invoke the Insert or Update method. Through this layer, the definition of the database and the upper business logic are separated.
Data above is the rules layer. The rules layer is called the rule layer, so what does it mainly do? In fact, it's very simple, the data layer is equivalent to a database recordset, it may include a lot of records. The rules layer splits the data object that contains multiple records into the rules object and invokes the façade layer by providing the property. On this level, do some processing and checking operations according to the business rules. The previous layer can get the corresponding processed value by calling different properties of the rules object.
The façade layer is called the business Facade layer, which is on the upper level of the rules layer. It is primarily responsible for the appearance of some businesses, organizing multiple rules objects and providing presentation preparation for the Web layer.
The top-level is the Web presentation layer. It is responsible for processing some check and display on the page of the system and so on.
The above structure is also referenced by Microsoft's Duwamish 7.0. And the naming of each layer is entirely in accordance with Microsoft's name. In the implementation of the process, according to the above design, the data and rules layer has been very regular, and the definition of the database through our company's another system to manage, database tables and column definitions can be easily obtained, So we made a gadget that automatically generates the data and rules layers, this gadget automatically generates classes in the data and rules layers, and all you need to do is to enrich the rules layer's classes and process the façade and Web layer based on your business, which greatly reduces our burden.
The system has now coded the test complete and is preparing to put it into trial. Because it is used on the intranet, it does not feel slow:). But the poor performance is certain, and the next step is to figure out how to improve performance.
In the process of development, oneself also always take it to compare with JSP. Personal asp.net is still very good, it can let you like desktop program development like to develop Web programs, Microsoft also provides a very rich control, but many controls feel a bit like chicken, as if it is very convenient to use, but there are various aspects of the defects is not very practical. In addition, there are a lot of bugs in this development tool, as it is in the Web development (we are using Version 2003). Vs.net However, it is said that Vs.net 2005 has improved a lot on the basis of 2003 and is worth looking forward to.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service