|
In this chapter:
Software applications are most likely to be developed with a database such that all data working with the application system can be retained, resulting in information and knowledge. Hence, database application is widely adopted by businesses of all sizes. In order to access and manipulate the relational database, a standard computer language, Structured Query Language (SQL) has to be used. SQL statements play an important role when developing database application.
Taking a trading system as an example, if the end-user wants to update a Sales Order record, the system has to retrieve the corresponding record from the Sales Order table and display to the end-user. After the end-user confirms the modification of data, the system has to update the record accordingly. It is noticeable that a database application requires a lot of coding for handling SQL statements so as to access and manipulate the database.
Hence, it is inevitable that developers spend almost 50% of development time for implementing the code with SQL statement. Moreover, mapping between the persistent code and database table is maintained throughout the development life cycle. Once there is a change in the structure of a database table, SQL statements which related to the modified table have to be re-written. Developers have to keep an eye on every change in the database schema.
Smart Development Environment for Microsoft Visio Studio .NET (SDE-VS) provides a solution to develop database application by supporting Object-Relational Mapping (ORM). Being supported with object-relational mapping, an ease-to-use environment is provided bridging between object model, data model and relational database. SDE-VS not only provides you a visual modeling for both logical data design and physical data design, but also automates the mapping between object model and data model.
SDE-VS also generates a cost-effective, reliable, scalable and high-performance object to relational mapping layer. The generated mapping layer includes the support of transaction, cache and other optimized feature. SDE-VS increases the productivity and significantly reduces the risk of developing the mapping layer manually.
SDE-VS is capable of generating Java and .NET persistent code; Smart Development Environment Enterprise Edition for Visual Studio .NET (SDE-VS EE) supports both object-relational mapping for Java and .NET while Smart Development Environment Professional Edition for Visual Studio .NET (SDE-VS PE) supports object-relational mapping for .NET. You can thus develop your project in Java or .NET source with object-relational mapping easily.
![]() |
|---|
| Figure 14.1 - Introduction of SDE for ORM |
The overview of SDE-VS for Object-Relational Mapping
Overview Diagram
![]() |
|---|
| Figure 14.2 - The overview of SDE-VS for ORM |
SDE-VS provides the following key features of object-relational mapping so as to simplify your development:
Traditionally developers spend a lot of effort in saving and loading objects between memory and database which makes the program complicated and difficult to maintain. These tasks can be simplified by generating a persistence layer between object and data models.
![]() |
|---|
| Figure 14.3 - Communicate between Object and Data model |
SDE-VS generates object-relational mapping layer which incorporates prime features such as transaction support, pluggable cache layer, connection pool and customizable SQL statement. With this mapping layer, developers can keep away from mundane implementation work and focus on the business requirements.
A true model driven platform for application development is provided. Developers are allowed, not only to start from creating the models using class diagram or entity relationship diagram and generate the executable persistence layer from the models, but also to modify the entity-relational model which is from reversed engineered an existing database, transform into object model and generate persistence layer. With the sophisticated model-code generator, the persistent model will be updated automatically according to any modification.
A wide range of database are supported, including Oracle, DB2, Cloudscape/Derby, Sybase Adaptive Server Enterprise, Sybase SQL Anywhere, Microsoft SQL Server, PostgreSQL, MySQL and more. By enabling the same set of ORM Java objects to work with different databases, an easy migration between databases is promoted. Besides, the proprietary data type is transformed to suit the default database specified.
Reverse engineering an existing database through JDBC and/or .NET database connector into the entity-relational model is supported. Developers can transform the entity-relational model to object model and redesign the database for further development.
![]() |
|---|
| Figure 14.4 - Reverse database to ERD |
The visual modeling environment is inherited from Visual Paradigm for UML, a well-known UML CASE Tool, it not only provides an intuitive inline editing for both object and data models, but also adopts the resource-centric interface for assisting frequently performed tasks.
![]() |
|---|
|
|
|||||||