Download presentation
Presentation is loading. Please wait.
Published byAugust Powell Modified over 9 years ago
1
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones1 Object Oriented Principles – Chapter 8 Encapsulation and Connascence Encapsulation –Levels –Structure Connascence –Definition –Contranascence
2
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones2 Encapsulation Abstracting a set of constructs to a single higher level construct –Can limit access –Allows one to manage complexity –Promotes sharing
3
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones3 Encapsulation - Levels Levels –Line of code –Procedure –Class –Component –…
4
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones4 Encapsulation - Levels Can examine inter/intra level encapsulation –0 – 1: Fan out –1 – 0: Cohesion –1 – 1: Coupling Extends up
5
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones5 Connascence Definition: A and B exhibit connascence –Changing A implies check/change B –Changes may require A and B both change Contrascence: A and B are independent and must be kept that way
6
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones6 Connascence - Types Name Type Convention Algorithm Position Execution Timing Value Identity
7
CSE 8313 Spr 2003 M. DiazFundamentals of OO Design in UML/Page-Jones7 Connascence – Design Encapsulation boundaries Maintainability Abuses: “friend,” inheritance, implementation side effects
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.