The General Form of GoF Design Patterns

By | August 11, 2018

Siniša Vlajic, Vojislav Stanojevic, Dušan Savic, Miloš Milic, Ilija Antovic, Saša Lazarevic
Department of software engineering, Faculty of organisational sciences, University of Belgrade, Belgrade, Serbia.

Abstract— In this paper, we present a general form of GoF Design Patterns as a process that transforms the BDPSP (the Basic Design Pattern Structure of the Problem) to the BDPSS (the Basic Design Pattern Structure of the Solution), i.e. transforms the unstable structure of the program to the stable structure. The stability of the BDPSP and BDPSS is explained by using Robert C. Martin’s Stability metric. The BDPSP and BDPSS are described by three elements: Client, Abstract Server and Concrete Server. The Client is an element of the pattern structure that uses the functionalities of the abstract server and concrete servers in order to carry out its own functionality. The Abstract Server is an element of the pattern structure that provides the client with an abstract functionalities that can be implemented with various specific functionalities.
The Concrete Server is an element of the pattern structure that provide the client with concrete functionalities that realise abstract functionalities of the abstract server. In this sense, the Design Pattern is a process that relationship Client has Concrete Server, transform to relationships: a) Client has Abstract Server and b) Concrete server is Abstract Server. We believe the BDPSS is the key mechanism or essence of the GoF design patterns, which allow easy maintenance and upgrade of the program. We have showed that in 20 of 23 GoF design patterns the BDPSS completely describes a pattern or a particular part of the pattern. We are using the general form of GoF design patterns in the teaching process, as the first step in the overall understanding of the GoF design patterns, before a detailed explanation of the specific characteristics of GoF design patterns. We think that this paper can greatly help the students and developers to quickly and clearly understand the essence of GoF design patterns.

Keywords- Software design; Design patterns; Stability metric; Software stability; Software maintenance.

2016, Volume 6, Issue 2.

Leave a Reply

Your email address will not be published. Required fields are marked *