Name: Shilpashree Srinivasamurthy Subject: ACS 560- Software Engineering Term: Fall 2010

advertisement
Name: Shilpashree Srinivasamurthy
Subject: ACS 560- Software Engineering
Term: Fall 2010
Chapter 15: Class Design
Textbook: Designing Concurrent, Distributed, and Real-Time Applications with
UML
This chapter explains the class design phase in which the information hiding classes are
designed and passive objects are instantiated from these classes.
The chapter first discuss about the categories of information hiding classes during class
design. The various categories are
- Entity classes: the classes determined in the analysis model that encapsulate data.
- Interface classes: the classes that interface to the external environment. These
classes may be further classified as device interface classes, user interface classes,
and system interface classes.
- Control classes: the classes that provide overall coordination for a collection of
objects in a use case.
- Application logic classes: The classes that encapsulates the application specific
logic and algorithms.
- Software decision classes: these classes hide decisions made by the software
designers that are likely to change.
The next section describes how to determine the operations provided by each class by
designing class operations.
- Designing Class Operations from the Interaction Model: The object interaction
model is used to determine each class’s operations. A class’s operations are
determined by considering how an object instantiated from the class interacts with
other objects using either sequence or collaboration diagrams.
- Designing Class Operations from the Finite State Machine Model: The class’s
operations are determined from a statechart.
- Designing Class Operations from the Static Model: The class’s operations are
determined from the class diagrams of the static model.
The next section of the chapter describes the data abstraction classes with an example.
Each entity class in the analysis model that encapsulates data is designed as a data
abstraction class.
The concept of device interface classes along with its various types is explained in the
next section. A device interface class provides a virtual interface that hides the actual
interface to the real world I/O device. There are two types of device interface classes
namely input device interface class that needs an initialize operation to initialize the
device and any internal variables used by the class and an output device interface class
which also has an initialize operation along with an optional output operation.
The next section discuss about state-dependent classes which encapsulates the
information contained on a statechart. State-dependent class determined in the analysis
model is designed during the class design phase.
The concept of algorithm hiding classes and user interface classes are explained in the
next sections. An algorithm hiding class hides an algorithm used in the application
domain. A user interface class hides from other classes, the details of the interface to the
user.
Business logic classes, database wrapper classes, and software decision classes are
explained in the next sections of the chapter. A business logic class defines the decisionmaking, business-specific application logic for processing a client request. Database
wrapper class handles data which is encapsulated by the entity class that has to be stored
in a database. A software decision class hides a design decision made by the software
designer that is considered likely to change.
The next section explains about inheritance along with examples. Inheritance is used
when designing the classes that share many but not all the characteristics. Class
hierarchies can be developed using either top-down, bottom-up or a combination of both
the approaches. An abstract class is designed to be used as a template for creating objects
which can be used only as a superclass from which no objects can be instantiated. The
polymorphism feature of the object-oriented design allows many classes to have the same
operation name but different implementation. Runtime association of a request to an
object and one of its operations is known as dynamic binding.
The last section of the chapter discusses about the class interface specifications along
with examples. A class interface specification defines the interface of the information
hiding class, including the specification of the operations provided by the class. It defines
the information hidden by the information hiding class, class structuring criterion used to
design this class, assumptions made in specifying the class, anticipated changes,
superclass, inherited operations and the operations provided by the class.
Download