Software Engineering Design Patterns Dr M Tanvir Afzal

  • Slides: 6
Download presentation
Software Engineering Design Patterns Dr. M. Tanvir Afzal

Software Engineering Design Patterns Dr. M. Tanvir Afzal

Design Patterns Why we need it? ü Pre-developed model for solving a recurring problem

Design Patterns Why we need it? ü Pre-developed model for solving a recurring problem in software design. ü You are not the first one working on the problem! 2

Design Patterns Adapter Pattern ü A prefabricated module may have the functionality needed to

Design Patterns Adapter Pattern ü A prefabricated module may have the functionality needed to solve the problem at hand but may not have an interface that is compatible with the current application. ü Adapter pattern provides a standard approach https: //javarevisited. blogspot. com/2016/08/adapter-design-pattern-in-java-example. html 3

Design Patterns Decorator Pattern ü Used when designing a system that performs different combinations

Design Patterns Decorator Pattern ü Used when designing a system that performs different combinations of the same activities depending on the situation at the time. ü Explosion of options. ü Decorator pattern provides a standardized way of implementing such systems that leads to a manageable solution 4 https: //ramj 2 ee. blogspot. com/2014/01/decorator-design-pattern-implementation_2. html#. W-QJa. ZMzb. IU

Design Patterns Goal ü Identification of recurring problem, creation and cataloging of design patterns

Design Patterns Goal ü Identification of recurring problem, creation and cataloging of design patterns for solving them is an ongoing process in software engineering. ü Goal is not to identify the solution, the goal is to identity the best solution flexible for future changes! 5

Summary Design Pattern ü Why we need it. ü Adapter Pattern ü Decorator Pattern

Summary Design Pattern ü Why we need it. ü Adapter Pattern ü Decorator Pattern ü Goal 6