Data Access Application Block

"Application Blocks are C# and VB.NET classes distributed as Visual Studio projects that can be downloaded from Microsoft's Web site and used in any .NET application, including ASP.NET Web applications.

Application Blocks were designed by reviewing successful and efficient .NET applications and combining the optimum implementations into classes for our use. As a result, Application Blocks incorporate the current best practices endorsed by Microsoft. However, the greatest facet of Application Blocks is that they are surprisingly well documented. Each Application Block is distributed with complete documentation and source code examples. Even the source code is commented.

A pattern is a way to describe commonly encountered problems. For example, many of us have written (or will write) code that authenticates users for access to a Web site. Our tools are frequently the same, username and password text boxes, a submit button and the code that is executed behind the scenes to perform the validation. The process of logging-in a user can
be abstracted and defined as a pattern. We could further identify certain practices that would facilitate the authentication pattern, making it easier and more efficient to perform the various tasks involved in logging-in a user. The process of defining patterns enables us to design more abstract solutions to address the common situations we encounter when programming any system.

The key to finding the best solution for a pattern is not to ask yourself "How do I solve this problem" but instead, "How do I solve these types of problems".

The Data Access Application Block provides static methods located in the SqlHelper class that encapsulate the most common data access tasks performed with Microsoft SQL server.These static methods can be used to return SqlDataReader, DataSet and XmlReader objects containing database information."

More:

Comments