Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Principle of OOD <ul><li>Abdul Hamid </li></ul><ul><li>Cristian </li></ul><ul><li>Jon Kartago Lamida </li></ul>24 Septembe...
Agenda <ul><li>Basic OOD Concept </li></ul><ul><li>General OOD Process </li></ul><ul><li>Software Change </li></ul><ul><li...
Why OOP? <ul><li>Procedural to OOP </li></ul><ul><li>Procedural = start from functionality </li></ul><ul><li>OOP = start f...
Object Oriented Concept
Object Oriented Pilar - PIE <ul><li>Encapsulation </li></ul><ul><li>Inheritance </li></ul><ul><li>Polymorphism </li></ul>
Encapsulation <ul><li>Information Hiding </li></ul><ul><li>Bundling Mechanism </li></ul>
Inheritance <ul><li>Is a... </li></ul><ul><li>extends/implements </li></ul>
Polymorphism <ul><li>Object can detect its type at runtime </li></ul>
Object Design <ul><li>abstraction </li></ul><ul><li>software change </li></ul><ul><li>design pattern </li></ul>
Software Change <ul><li>Rigidity </li></ul><ul><li>Fragility </li></ul><ul><li>Immobility </li></ul><ul><li>Viscocity </li...
Principles of OOCD
Single Responsibility Principle <ul><li>There should not be more than one reason for software to change </li></ul>
Open Close Principle <ul><li>A module should be open for extension but closed for modification. </li></ul>
Liskov Subtitution Principle <ul><li>Subclasses should be substitutable for their base classes. </li></ul>
Dependency Inversion Principle <ul><li>Depend upon Abstractions. Do not depend upon concretions. </li></ul>
Sample One <ul><li>Container Class in Java </li></ul><ul><li>Bad : </li></ul><ul><li>// Depend to concretion </li></ul><ul...
Sample Two
Interface Segregation Principle <ul><li>Many client specific interfaces are better than one general purpose interface </li...
Sample – Duck Simulator
Upcoming SlideShare
Loading in …5
×

Principle of OOD

2,031 views

Published on

Principle of OOD:
Basic OOP Concept
Single Responsibility Principly
Open Close Principle
Liskov Subtitution Principle
Dependency Inversion Principle
Interface Segregation Principle

Published in: Technology
  • Be the first to comment

Principle of OOD

  1. 1. Principle of OOD <ul><li>Abdul Hamid </li></ul><ul><li>Cristian </li></ul><ul><li>Jon Kartago Lamida </li></ul>24 September 2010 New Frontier Solutions
  2. 2. Agenda <ul><li>Basic OOD Concept </li></ul><ul><li>General OOD Process </li></ul><ul><li>Software Change </li></ul><ul><li>Principle of OOD </li></ul><ul><li>Single Responsibility Principle </li></ul><ul><li>Open Close Principle </li></ul><ul><li>Liskov Subtitution Principle </li></ul><ul><li>Dependency Inversion Principle </li></ul><ul><li>Interface Segregation Principle </li></ul>
  3. 3. Why OOP? <ul><li>Procedural to OOP </li></ul><ul><li>Procedural = start from functionality </li></ul><ul><li>OOP = start from data </li></ul><ul><li>Plus: OOP nice for developing complex software with large modul involving many developer </li></ul><ul><li>Minus: OOP Concept is somewhat difficult to grasp at first place </li></ul>
  4. 4. Object Oriented Concept
  5. 5. Object Oriented Pilar - PIE <ul><li>Encapsulation </li></ul><ul><li>Inheritance </li></ul><ul><li>Polymorphism </li></ul>
  6. 6. Encapsulation <ul><li>Information Hiding </li></ul><ul><li>Bundling Mechanism </li></ul>
  7. 7. Inheritance <ul><li>Is a... </li></ul><ul><li>extends/implements </li></ul>
  8. 8. Polymorphism <ul><li>Object can detect its type at runtime </li></ul>
  9. 9. Object Design <ul><li>abstraction </li></ul><ul><li>software change </li></ul><ul><li>design pattern </li></ul>
  10. 10. Software Change <ul><li>Rigidity </li></ul><ul><li>Fragility </li></ul><ul><li>Immobility </li></ul><ul><li>Viscocity </li></ul>
  11. 11. Principles of OOCD
  12. 12. Single Responsibility Principle <ul><li>There should not be more than one reason for software to change </li></ul>
  13. 13. Open Close Principle <ul><li>A module should be open for extension but closed for modification. </li></ul>
  14. 14. Liskov Subtitution Principle <ul><li>Subclasses should be substitutable for their base classes. </li></ul>
  15. 15. Dependency Inversion Principle <ul><li>Depend upon Abstractions. Do not depend upon concretions. </li></ul>
  16. 16. Sample One <ul><li>Container Class in Java </li></ul><ul><li>Bad : </li></ul><ul><li>// Depend to concretion </li></ul><ul><li>ArrayList list = new ArrayList(); </li></ul><ul><li>Good : </li></ul><ul><li>// Depend to abstraction </li></ul><ul><li>List list = new ArrayList(); </li></ul><ul><li>list = new LinkedList(); </li></ul>
  17. 17. Sample Two
  18. 18. Interface Segregation Principle <ul><li>Many client specific interfaces are better than one general purpose interface </li></ul>
  19. 19. Sample – Duck Simulator
  20. 20. Sample – Duck Simulator
  21. 21. Sample – Duck Simulator
  22. 22. Sample – Duck Simulator
  23. 23. Java Project Use Case <ul><li>SRP: entity </li></ul><ul><li>OCP, LSP: AbackingBean </li></ul><ul><li>DIP: JumpActionBaseList </li></ul>
  24. 24. Discussion
  25. 25. Thank You

×