Presentation is loading. Please wait.

Presentation is loading. Please wait.

Stephenson College DP 98 1 Associations & Aggregations by Derek Peacock.

Similar presentations


Presentation on theme: "Stephenson College DP 98 1 Associations & Aggregations by Derek Peacock."— Presentation transcript:

1 Stephenson College DP 98 1 Associations & Aggregations by Derek Peacock

2 Stephenson College DP 98 2 Associations a One to One a One to Many a Many to Many 0..110 Associates with 

3 Stephenson College DP 98 3 Uni-Directional Association SwitchLight bulb Controls  Actor Server

4 Stephenson College DP 98 4 Application Associations LecturerUnits Teaches  Contract Teaches to  * Classroom Taught in  * *

5 Stephenson College DP 98 5 Containment v. Containers a One object composed of fixed no of other objects a Can not exist without its components a e.g. a Car is composed of and engine, four wheels a One object may contain a variable no of other objects a Can exist independently a e.g. a Car Boot may contain some luggage, some books, some wine

6 Stephenson College DP 98 6 Composition (of parts) Clock HandFaceBody 2 Battery

7 Stephenson College DP 98 7 Aggregation a Parts can have independent life outside aggregation a e.g. a battery as part of a clock, as opposed to the hands of the clock

8 Stephenson College DP 98 8 A Checkout Aggregation Checkout Barcode reader Weighing scale Till Customer Queue

9 Stephenson College DP 98 9 The Solent Hotel a Has 5 function rooms @ £200 a Has 40 bedrooms a 10 single bedrooms @ £40 a 30 double rooms @ £55 a One set of presentation equipment a Customers name and payee recorded

10 Stephenson College DP 98 10 UML Class Diagram (1) Hotel Single Room Double Room Function Room Equipment Is in  0..1 10305

11 Stephenson College DP 98 11 UML Class Diagram (2) Single Room Double Room Function Room Customer  Books 0..1


Download ppt "Stephenson College DP 98 1 Associations & Aggregations by Derek Peacock."

Similar presentations


Ads by Google