CSC 223 Grinnell College Fall, 2005
 
Software Design
 

Discussion Questions for Fowler, Chapter 3

Class Diagrams

Properties: Attributes and Associations

  1. "As a first approximation , you can think of properties as corresponding to fields of a class." (Fowler 35) How safe is this "approximation", are the class fields always equivalent to the properties (as defined in UML)? --Dimitar
  2. Fowler mentions that attributes and associations are the same thing in that most of the same information appears in both notations (36). One difference he mentions is that associations can show multiplicities at both ends of the line. What are some other visible/key differences between attributes and associations? (Mike C)
  3. Can't there be meaningful classes that only have get, set, and print methods? Why aren't these methods meaningful? (Mike L.)
  4. Are there any conventions when to use broken lines for class diagrams? (Monica)
  5. Where exactly is the line drawn between get and set giving away implementation and not giving away implementation? (Mike L.)
  6. When would we need to assign to a multivalued property? Or alternately, when would it be advantageous to do so over updating with add and remove methods? (Alex)
  7. When would one not use bidirectional association? It seems that usually two objects will have a mutual relationship. (Andy)
  8. Which is better, implementation-focused interpretation or interface-oriented interpretation of class diagrams? (Monica)

Multiplicity

  1. Besides the examples given, are there any other qualifiers that would be handy in modifying the elements in a multivalued multiplicity? (Alex)

Operations

  1. In Operations topic, if the getting and setting methods are "entirely internal to the class," then how can we use other classes to help on tasks that are beyond the capabilities of the class? (Chayapan)

Generalization and Interfaces

  1. Has the issue of unwanted inheritence in the Vector class disappeared because java now allows one to make an over-riding Vector class that does not have to implement all of Java's vector class, or because Java's Vector class has improved, and people no longer want to rewrite it?
  2. On Pg 51 Fowler says that Assertions reduce the chances of inheritance redefining a subclass's operations to be inconsisitent with the superclass's operations. The subclasses can choose to strengthen these assertions but cannot weaken them. However, pre-condition, cannot be strengthened. I understand that in most cases it cannot be strengthened, but can't there be even one case where it might have to be strengthened? (Gaurav)
  3. Fowler says on Pg 44, that with conceptual models we shouldnt use it to specify the interface of a class. Why so? (Gaurav)
  4. Wouldn?t using an interface turn a cycle of dependencies into a set of dependencies that all fed into the interface? (Jonathan)

Dependencies

  1. Can you give any tips to avoid dependencies? (David D)
  2. While talking about dependencies Fowler says that we ?should be wary of cycles.? Are cycles just a series of dependencies that form a loop, or are they something else? (Jonathan)
  3. What's the big difference between "assocition" and "dependency" ? Shouldn't we treat them the same? (Chayapan)
  4. How safe are the dependancy rules used by UML in practical programming? Do they work seamlessly, or do they require programmer fine-tuning? -- Dimtar
  5. Fowler writes on pg. 48 that UML has many varieties of dependencies and he mentions a basic dependency. What are some other types of dependencies and how do they differ from the basic dependency? Fowler also states that the basic dependency is not transitive. What are some kinds of dependencies that are transitive? (Mike C)

Constraints

  1. In figure 3.1 Fowler labels what appears to be a comment a constraint (I think the comment contains a constraint, however). Is this an example of Fowler using UML to sketch out information, or is this actually normative notation? (John)
  2. What's the "UML's formal Object Constraint Language (OCL)"? Example please?

Relationships between UML and Programming Languages

  1. What significant differences exist between the UML class diagram and an actual language class specification? (Andy)
  2. What does Fowler mean by "language that supports porperties" (pg 40)? (Saugar)

Other Questions

  1. "The majority of UML diagrams I see are class diagrams. (pg 35)" What are the other types of UML diagrams? (Saugar)
  2. Can you give more examples of queries and modifiers? (David D)
  3. Fowler briefly mentions meta-classes, which I assume correspond to templates in C++. How common are meta-classes in object oriented languages? Do Java and C# have them? (John)
  4. It would be nice to be able to apply these principles in the real-world, even at this early stage. What is a program on MathLAN that we can use to actually do this UML stuff?


This document is available on the World Wide Web as

http://www.cs.grinnell.edu/~walker/courses/223.sp05/readings/fowler-3.shtml

created 6 September 2005
last revised 7 September 2005
Valid HTML 4.01! Valid CSS!
For more information, please contact Henry M. Walker at walker@cs.grinnell.edu.