
Chapter 11 Generating .NET 2.0 Persistent Objects and Windows Applications
Introducing PowerDesigner and the .NET Architecture
PowerDesigner follows the best practices and design patterns for .NET enterprise applications, and defines a typical .NET n-tier architecture as in the following figure.
PowerDesigner can be used to generate all these layers:
- Domain Model - contains persistent POCOs (Plain Old CLR Objects), which are similar to Java's POJOs. These classes act as information holders for the application and do not contain any business logic. A primary key class will also be generated for each persistent class in order to help the "find-by-primary-key" function, especially when the class has a composite primary identifier.
- Data Access Layer - follows the standard DAO pattern, and provides typical CRUD methods for each class. This layer is divided into two parts, one of which contains interfaces for DAL, and another that contains the implementation for these interfaces, using ADO.NET technology to access databases.
The DAL Helper provides common functionalities used by all the DAL implementations, such as connection and transaction management, and the supply of SQL command parameters. Some common classes, such as Session, Criteria, and Exception, are also defined.
PowerDesigner supports two kinds of DAL implementation:
- Business Logic Layer - contains the typical user-defined business logic. This is a wrapper for the DAL, exposing CRUD functionalities providing by the DAL underneath. You can customize this layer according to your needs.
- Windows Application - the Composite UI Application Block, or CAB layer helps you build complex user interface applications that run in Windows. It provides an architecture and implementation that assists with building applications by using the common patterns found in line-of-business client applications.
PowerDesigner can generate data-centric windows applications based on the CAB (see Generating Windows Applications).
Copyright (C) 2006. Sybase Inc. All rights reserved.
|
|