0% found this document useful (0 votes)
22 views7 pages

GoF Patterns in Software Design

This document describes the software design patterns known as GoF patterns. It explains that these patterns originated in the book "Design Patterns" by the authors Gamma, Helm, Johnson, and Vlissides. The GoF patterns are classified into three categories: creational, structural, and behavioral patterns. Within each category, the patterns that compose it are listed and briefly described.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views7 pages

GoF Patterns in Software Design

This document describes the software design patterns known as GoF patterns. It explains that these patterns originated in the book "Design Patterns" by the authors Gamma, Helm, Johnson, and Vlissides. The GoF patterns are classified into three categories: creational, structural, and behavioral patterns. Within each category, the patterns that compose it are listed and briefly described.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

ARCHITECTURE AND

SOFTWARE DESIGN

PROFESORA: SUSANA ALEJANDRA LÓPEZ JIMÉNEZ

GOF PATTERNS

Cuahutemoc Avalos Ponce


13060108

JUAN LUIS GODOY MENDEZ

82SA
Table of contents
1.1 GoF PATTERNS..............................................................................2
1.1.1 YOUR CHARACTERISTICS...............................................................................2
1.2 CLASSIFICATION..............................................................................3
1.2.1 CREATION PATTERNS............................................................................3
1.2.2 STRUCTURAL PATTERNS......................................................................3
1.2.3 BEHAVIOR PATTERNS..............................................................4
BIBLIOGRAPHY.................................................................6
1.1 GoF PATTERNS
GoF patterns are discovered as an indispensable way to face
programming based on the book 'Design Patterns—Elements of Reusable Software' by
Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides, from then on these
patterns are known as the gang of four patterns (GoF, gang of
four).

(madrid)

1.1.1 ITS CHARACTERISTICS


They are concrete solutions. They propose solutions to specific problems, they are not

generic theories.
They are technical solutions. They indicate technical resolutions based on

Object-Oriented Programming (OOP). Sometimes they are more useful with


some programming languages and others are applicable to
anylanguage.
They are used in frequent situations. Because they are based on experience.
accumulated by solving repetitive problems.
They promote code reuse. They help build software based on the
reuse, to build reusable classes. The patterns themselves are reused
every time they are reapplied.
The use of a pattern is not reflected in the code. When applying a pattern, the code
The resultant does not have to reveal the pattern or patterns that inspired it. Not.
however, recently there are multiple efforts focused on the construction of
development tools based on patterns and is often included
in the names of the classes, the name of the pattern on which they are based, facilitating

thus the communication between developers.


It is difficult to reuse the implementation of a pattern. When applying a pattern, issues arise.

concrete classes that solve a specific problem and that will not be applicable to
other problems that require the same pattern.
1.2 CLASSIFICATION

1.2.1 CREATION PATTERNS

They are responsible for the creation of instances of the objects. They abstract the way in which

they create the objects, allowing the classes to be created in a generic way, leaving for
after the decision of what class to create or how to create it.

The creation patterns are:

Abstract Factory: Allows working with objects of different


families in a way that families do not mix with each other and making
transparent the specific type of family that is being used.
Builder (Constructor virtual): Abstracts the process of creating an object
complex, centralizing said process in a single point.
Factory Method: Centralizes in a constructor class the
creation of objects of a subtype of a specific type, hiding from the user
the case law for choosing the subtype that is created.
Prototype: Create new objects by cloning an already existing instance.
existing.
Singleton (Unique instance): Ensures the existence of a single instance for
a class and the creation of a global access mechanism to that instance.

1.2.2 PATTERNS STRUCTURAL


They are the ones who propose relationships between classes, combine them, and form structures.

mayores. Tratan de conseguir que los cambios en los requisitos de la aplicación no


cause changes in the relationships between objects.

Structural patterns are:

Adapter: Adapts an interface so that it can be used by a


class that I otherwise could not use.
Bridge: Decouples an abstraction from its implementation.
Composite (Composite object): Allows treating composite objects as if they were
it was a simple one.
Decorator: Adds functionality to a class dynamically.
Facade: Provides a simple unified interface to access a
interface or group of interfaces of a subsystem.
Flyweight (Lightweight): Reduces redundancy when a large number of objects
they have identical information.
Proxy: Maintains a representative of an object

1.2.3 BEHAVIORAL PATTERNS


It proposes the interaction and cooperation between classes. The patterns of behavior
they study the relationships between calls among different objects, usually
linked with the temporal dimension.

The behavior patterns are:

Chain of Responsibility: Allows to establish the line


What should the messages contain for the objects to perform the indicated task.
Command: Encapsulates an operation in an object, allowing for execution
this operation without the need to know its content.
Interpreter: Given a language, define a grammar for it.
language, as well as the tools necessary to interpret it.
Iterator: Allows traversal over composite objects
regardless of the implementation of these.
Mediator: Defines an object that coordinates communication between
objects of different classes, but that work as a set.
Memento (Recuerdo): Permite volver a estados anteriores del sistema.
Observer: Defines a one-to-many dependency between
objects, so that when an object changes state it is notified and
automatically update all objects that depend on it.
State: Allows an object to change its behavior each time
that changed its internal state.
Template Method: Defines the skeleton of an operation in a
algorithm, delegating some of its steps to the subclasses, this allows for
subclasses redefine certain steps of an algorithm without changing its structure.
Visitor (Visitante): Permite definir nuevas operaciones sobre una jerarquía de
classes without modifying the classes on which it operates.
Strategy (Estrategia): Permite disponer de varios métodos para resolver un
problem and choose which to use at runtime. (EcuRed)

BIBLIOGRAPHY

What is the Object Modeling Technique? (n.d.). Obtained from Rodolfo Quispe-
Otazu: [Link]
[Link]
ARCHITECTURE AND SOFTWARE DESIGN. (JULY 2014). Retrieved from This
[Link] site is the bee's knees:
[Link]
software/
EcuRed. (n.d.). Obtained from Knowledge with everything and for everyone:
[Link]
Madrid, U. p. (n.d.). Obtained from
[Link]
OMT (Object Modeling Technique). (June Tuesday of 2009). Obtained from
[Link]

You might also like