Dr. R. J. Botting
Computer Science Faculty Seminar
California State University, San Bernardino
June 2nd 2003
a. Dr. Tracy Gardner's Ph. D. Thesis, Bristol U., England
b. Inheritance Relationships for Disciplined Software Construction
c. Springer Verlag UK 2002
i. Using 5 special types of inheritance may lead to better software.
c. Preliminary Definitions
e. Missing Things
a. Make software easier to design, understand, maintain, etc.
4. Defining Terms
i. Unified Modeling Language
i. Allowing a class of objects to be like another class.
c. Generalization and Realization
i. The two UML forms of inheritance.
5. Current Situation
a. Using normal inheritance leads to confusion and ambiguity
b. Square and Rectangle
c. Point and ColoredPoint
d. Any Others?
6. The Problem
i. How to structure OO models better.
i. Do not use general inheritance!
iii. Pick special forms of inheritance!
7. Five Structured Inheritance Relationships
(1) Specialization <<spec>>
(2) Variant <<var>>
(3) View <<view>>
(4) Construction <<cons>>
(5) Evolution <<evol>>
8. Primary and Secondary
a. Gardner has primary and secondary abstractions.
i. Primary classes/types model the domain.
(1) Define a complete domain ontology.
(2) They may not refer to secondary types.
(3) They may not have instance objects
(a) I think!
ii. Secondary classes implement the software.
(1) They may have instances.
(2) They implement primary types.
9. A mapping to UML 1.1
(1) <<implementation class>>
10. Details on the Five SIRs
i. A Special Kind Of
b. Primary types only
d. Contracts propagate
e. As old as Aristotle
i. Same operations but variant behaviors
b. Realization of primary.
c. Variations of secondary
d. All variants are secondary.
e. Transitive and propagates contracts.
f. Variant of specialization is a variant of the general.
g. We use it every day.
i. Allow an object to gain new responsibilities
without changing identity.
b. A primary or a secondary type can have secondary views
c. A view is never primary.
d. A view is often a variant of a primary type.
e. The object, dynamically, gains the behaviors and constraints defined by the view.
f. I would like to have a simple way to code views.
i. Example: Points and Pairs
b. Pair p1 = new Pair;
c. Point p2 = view p1 via PairAsPoint;
i. How we combine stereo components into a system.
b. Connect parts, hide behaviors.
c. In specification languages like Z for years.
d. In the UML 1, use composition, realization, and collaborations with OCL specifications.
e. We need a simpler way.
i. Gardner uses generalization with <<cons>>.
b. private inheritance.
c. Controversial! Many deprecate it.
d. "a special kind of association"
e. "object-based not class-oriented".
f. We should look at other ways to show construction.
g. Why not composition?
i. Shows that something can change.
b. Two meanings.
i. Changes in an object's state
(1) eg. Advancement to Candidacy
ii. Changes in a class's description
(1) eg. The addition of a new method.
c. A change to a class, passes to all subclasses and instances.
e. Phase out the old class!
b. I like being able to show model changes.
i. A powerful and important idea.
c. There is a better way for state changes.
i. State-charts or entity life histories handle this better.
ii. Dr. Gardner does not mention them.
19. Missing => Doubts
i. Dr. Gardner does not
b. Mention most of the UML!
i. State charts
ii. Composition, association, aggregation
iii. collaborations (patterns)
20. Missing = Future Work
i. Dr. Gardner does not
b. Prove anything.
c. Both are needed!
i. Prove that all inheritance is covered by the 5 SIRs
(1) Like Boehm and Jacopini
ii. They need to run the gauntlet of the scientific process
iii. Find out how they work in the field.
iv. Develop languages & tools to use them
21. Any Questions?
i. Five SIRs
i. Fascinating ideas. But needs review and testing.
b. The book
i. explains how the SIRs resolve problems.
ii. compares them with other resolutions.
iii. shows how to code SIRs
iv. has many good examples
v. has money dump errors.
c. Dr. Gardner's ideas must not be forgotten.
23. Any Questions
24. Thank You for Coming!
i. Don't forget the many presentations being made this week!.
25. Blank Slide