OOPS and ADO.Net
I am building a bug-tracking application, where I am thinking of taking maximum possible benefits of OOPS starting from my presentation layer to my data access layer. The architecture will be as usual 3-tier but I want to use Design Patterns or simply OOPS concepts to create connection pull out data or something like开发者_开发技巧 that.
Here is a detailed description of an n-layered web application which might be helpful. This particular app is done in .Net 3.5, and it has much more functionality than you might need. You might explore the predecessor project written in .Net 2.0 for a description of the architecture there. Either way, you can download the code and have a very useful architectural model to study.
We can call PIE to main OOPS concepts.
These are Polymorphism, Inheritance and Encapsulation.
You can use these concepts in your application.
Apart from this for 3-tier architecture, you can use MVC (Model-View-Controller) Architecture.
If you want to maximum possible benefits of OOPS Concepts, you should use more popular feature of OOP like as, Encapsulation, Inheritance, Polymorphism ( Compile time or run time as per requirement), Abstract class and Interface as per requirement to design better application.
And you may use MVC(Model-view-Controller), instead of 3-tier Architecture. In MVC you also find that most OOPs Concepts have used.
For Example ActionResult Class has been inherited by most classes like - JsonResult, PartialViewResult, ViewResult etc.
精彩评论