[cs13001] Class Diagrams

Mikhail Nesterenko mikhail at cs.kent.edu
Sun May 4 16:33:15 EDT 2014


> 
> 
> While looking over the slides for Diagrams, I noticed that the
> structure of the class diagram was stated differently on two
> different slides. One example shows the operations (methods) on top
> of the instance variables (member variables), while the other shows
> member variables above operations. Which one should we use when
> writing them ourselves?
> 
> 

I have seen it done both ways. For the purposes of this class let's
standardize on name of the class first, then variables, then methods
(i.e. the opposite of C++ convention). This is more common. I updated
the slides to match this.

Methods and variables sections are optional and may be omitted on a
diagram as it is done on several diagram examples. Also, the return
type and parameter argument types for methods are optional. However,
if they are stated, the prevalent convention is:

  methodName(arugmentName: argType): returnType

Thanks,
--
Mikhail




More information about the cs13001 mailing list