| Entity relationship modeling in object-oriented software development |
| Full text |
Pdf
(129 KB)
|
| Source
|
ACM Annual Computer Science Conference
archive
Proceedings of the 1988 ACM sixteenth annual conference on Computer science
table of contents
Atlanta, Georgia, United States
Pages: 708 - 709
Year of Publication: 1988
ISBN:0-89791-260-8
|
|
Author
|
|
| Sponsor |
|
| Publisher |
|
| Bibliometrics |
Downloads (6 Weeks): 3, Downloads (12 Months): 42, Citation Count: 0
|
|
|
ABSTRACT
In a course in Database Concepts, students design a database of their own choice. They use the Entity-Relationship approach to high level design. Students may be too free in expressing their designs with the ER approach, drawing connecting lines where inappropriate (between relationship figures), as paper and pencil do not sufficiently constrain their enthusiasm. This is similar to what is seen too often in the design of software generally.
The diagram indicates that “dependent” is a weak entity set with defining relationship “Parent”, that “ssn” is the key to “employee” and that “supervision” is one-to-many from “supervisors” to “employee”. “Manages” is a one-one relationship.
The software will also output a list of data definition templates for SQL, a popular relational database front end. A portion of the output for the above ER diagram is:
CREATE TABLE employee ( ssn (), name (), managesdno (), supervisionssn () );
CREATE TABLE worksFor ( percentTime (), ssn (), dno () ),
I have recently developed an application for Entity-Relationship modeling on a microcomputer. The software permits the database designer to sketch an ER diagram and to indicate several important properties of the design (weak entity sets, cardinality, categories, etc.). The software was developed using Object Pascal and runs on the Macintosh.
An example appears below.
This technique has a potentially greater impact, however, on the design of software systems generally. I have been exploring the idea of using the ER technique for logical design of abstract data types modeled on entities of the problem space. In object-oriented programming it is very useful to model such entities as objects in the system. Generally, these entities have some variable state and may exhibit some actions. This is highly consistent with the notion of an object in the sense of Smalltalk. As an example of the use of this technique in the early design of a software system consider the following example ER diagram which is an overview of the data types within the Entity-Relationship program itself.
The program has two major data types. These items are commands and screen_shapes. Screen_shapes are composed of lines and other shapes and these have different properties. Three kinds of commands are needed, to modify screen_shapes and text_streams.
The relationships (diamonds) show the necessary interactions between the entities. Early knowledge of these interactions aids the designer in choosing appropriate representations of the state variables of each data type. One may take the view that the relationship “modifies” between key_handlers and text_streams may be defined in terms of actions such as “enter”, “cut”, “paste”, “select”, “move”, and “undo”. These must be specified early on as a means of defining the user interface. We are a long way toward knowing what a text_stream must look like, as well as a key_handler.
This technique, of modeling the data with ER diagrams, is most useful if the development will be undertaken using an object-oriented system, as the state and procedure information may be encapsulated within the objects themselves. Thus, the above mentioned software has objects to model screen_shapes and objects to represent commands and these encapsulate the ideas made visible in the ER diagram.
Peer to Peer - Readers of this Article have also read:
-
Data structures for quadtree approximation and compression
Communications of the ACM
28, 9
Hanan Samet
-
A hierarchical single-key-lock access control using the Chinese remainder theorem
Proceedings of the 1992 ACM/SIGAPP Symposium on Applied computing
Kim S. Lee
, Huizhu Lu
, D. D. Fisher
-
The GemStone object database management system
Communications of the ACM
34, 10
Paul Butterworth
, Allen Otis
, Jacob Stein
-
Putting innovation to work: adoption strategies for multimedia communication systems
Communications of the ACM
34, 12
Ellen Francik
, Susan Ehrlich Rudman
, Donna Cooper
, Stephen Levine
-
An intelligent component database for behavioral synthesis
Proceedings of the 27th ACM/IEEE Design Automation Conference on
Gwo-Dong Chen
, Daniel D. Gajski
|