Presentation is loading. Please wait.

Presentation is loading. Please wait.

Fall 2009ACS-3913 Ron McFadyen1 Design Class Diagrams n Class diagram with – classes – associations – attributes – methods – navigability – interfaces,

Similar presentations


Presentation on theme: "Fall 2009ACS-3913 Ron McFadyen1 Design Class Diagrams n Class diagram with – classes – associations – attributes – methods – navigability – interfaces,"— Presentation transcript:

1 Fall 2009ACS-3913 Ron McFadyen1 Design Class Diagrams n Class diagram with – classes – associations – attributes – methods – navigability – interfaces, attribute types, dependencies n we are designing software classes now - no longer conceptual

2 Fall 2009ACS-3913 Ron McFadyen2 analysis design

3 Fall 2009ACS-3913 Ron McFadyen3 An interaction diagram showing a register sending a makeLineItem message to a sale, implies that the Sale software class must have a makeLineItem method Usually don’t show create, accessor, or mutator methods uninteresting Messages imply Methods

4 Fall 2009ACS-3913 Ron McFadyen4 The navigability arrow (also called a navigability adornment) indicates that a Register object is connected uni-directionally to Sale objects … the Register class has an attribute, currentSale, pointing to a Sale object Do we have any interaction diagrams showing a message from a Sale object to a Register object? Navigability

5 Fall 2009ACS-3913 Ron McFadyen5 The directed arrow is unidirectional, and shows navigability. The above shows that a register object can navigate to a sale object: I.e. a register needs to know the sale object, but not the other way around. Register can send a message to a sale, sale can respond, but doesn’t initiate. In an OO language, Register will have an attribute that references a Sale instance

6 Fall 2009ACS-3913 Ron McFadyen6 Navigability: An association line with a navigability adornment indicates that an object of one class (A) is connected uni-directionally to an object of another class (B) An object of class A can navigate to an object of class B. I.e. an object of class A needs to know the B object, but not the other way around. A can send a message to an instance of B, the instance can respond, but doesn’t initiate. An association line that has no specific navigation indicated, is considered to be bi-directional In an OO language, an A will have an attribute that references a B instance A b: B B

7 Fall 2009ACS-3913 Ron McFadyen7 the result from analyzing all interaction diagrams for navigability.

8 Fall 2009ACS-3913 Ron McFadyen8 we see additional dependencies shown … the dashed arrow line … register and sale have visibility to ProductSpecifications … register knows of a product due to the lookup in the catalogue and a sale receives a product specification in the makeLineItem message


Download ppt "Fall 2009ACS-3913 Ron McFadyen1 Design Class Diagrams n Class diagram with – classes – associations – attributes – methods – navigability – interfaces,"

Similar presentations


Ads by Google