SlideShare a Scribd company logo
Factory Design Pattern
 In software engineering, a design pattern is a
general repeatable solution to a commonly
occurring problem in software design. A design
pattern isn't a finished design that can be
transformed directly into code. It is a description
or template for how to solve a problem that can
be used in many different situations.
 In 1994, four authors Erich Gamma, Richard
Helm, Ralph Johnson and John Vlissides
published a book titled Design Patterns -
Elements of Reusable Object-Oriented
Software which initiated the concept of Design
Pattern in Software development.
 These authors are collectively known as Gang
of Four (GOF).
1 Creational Patterns
These design patterns provide a way to create objects while hiding
the creation logic, rather than instantiating objects directly using new
opreator. This gives program more flexibility in deciding which objects
need to be created for a given use case.
2 Structural Patterns
These design patterns concern class and object composition.
Concept of inheritance is used to compose interfaces and define
ways to compose objects to obtain new functionalities.
3 Behavioral Patterns
These design patterns are specifically concerned with communication
between objects.
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Creational
Factory Pattern
Abstract FactoryPattern
BuilderPattern
FactoryMethodPattern
PrototypePattern
SingletonPattern
Structural
BridgePattern
CompositePattern
DecoratorPattern
FacadePattern
FlyweightPattern
ProxyPattern
Behavioral
ChainOfResponsibilityPattern
CommandPattern
InterpreterPattern
IteratorPattern
MediatorPattern
MementoPattern
ObserverPattern
StatePattern
StrategyPattern
TemplateMethodPattern
VisitorPattern
 Factory pattern is one of most used design pattern
in Java. This type of design pattern comes under
creational pattern as this pattern provides one of
the best ways to create an object.
 Define an interface for creating an object, but let
subclasses decide which class to instantiate.
Factory Method lets a class defer instantiation to
subclasses.
 In Factory pattern, we create object without
exposing the creation logic to the client and refer to
newly created object using a common interface.
1.Get Invoice
2.Place Booking Goa
Wayanad
Shimla
1.Get Invoice
2.Place Booking Goa
Wayanad
Shimla
Coorg
Munnar
 1.Customer directly communicating Hotels
 2.In case of New Hotel ,have to share contact
details to Customers
1.Get Invoice
2.Place Booking Goa
Wayanad
Shimla
Coorg
Munnar
Marketing
Office
1.Get Invoice
2.Place Booking
Marketing
Office
Goa
Wayanad
Shimla
Coorg
Munnar
Customer
Marketing
Offices
Different
hotels/Resorts
Set of
rules/Procedure
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Factory Design Pattern
Q & A

More Related Content

PPTX
Factory Method Pattern
PPTX
Design pattern (Abstract Factory & Singleton)
PPTX
Design Pattern - Factory Method Pattern
PPTX
Design Patterns - Abstract Factory Pattern
PPT
Design Pattern For C# Part 1
PPT
Spring Core
PPTX
Facade pattern presentation(.pptx)
PPT
Design patterns ppt
Factory Method Pattern
Design pattern (Abstract Factory & Singleton)
Design Pattern - Factory Method Pattern
Design Patterns - Abstract Factory Pattern
Design Pattern For C# Part 1
Spring Core
Facade pattern presentation(.pptx)
Design patterns ppt

What's hot (20)

PDF
Factory method pattern (Virtual Constructor)
PPTX
Proxy Design Pattern
PPTX
Abstract Factory Design Pattern
PPT
Builder pattern
PPTX
Software design patterns ppt
PPT
Design Patterns
PDF
Solid Principles
PPTX
Design pattern-presentation
PPTX
Creational pattern
PPTX
PATTERNS02 - Creational Design Patterns
PPT
Adapter pattern
PPTX
Builder design pattern
PDF
SOLID Design Principles applied in Java
PPS
Java Hibernate Programming with Architecture Diagram and Example
PPT
Proxy pattern
PDF
Hibernate Presentation
PPT
SOLID Design Principles
PPTX
Solid Principles
PPTX
Let us understand design pattern
PPTX
Solid principles
Factory method pattern (Virtual Constructor)
Proxy Design Pattern
Abstract Factory Design Pattern
Builder pattern
Software design patterns ppt
Design Patterns
Solid Principles
Design pattern-presentation
Creational pattern
PATTERNS02 - Creational Design Patterns
Adapter pattern
Builder design pattern
SOLID Design Principles applied in Java
Java Hibernate Programming with Architecture Diagram and Example
Proxy pattern
Hibernate Presentation
SOLID Design Principles
Solid Principles
Let us understand design pattern
Solid principles
Ad

Similar to Factory Design Pattern (20)

PPTX
Software design and Architecture.pptx
PPTX
Design pattern
PDF
Gang of Four in Java
PPTX
Design patterns
PPTX
Typescript design patterns applied to sharepoint framework - Sharepoint Satur...
PDF
Design Patterns Java programming language.pdf
PDF
dotnet stuff.com tutorials-design-patterns_exploring-net-design-patterns-in-s...
PPT
Oops design pattern intro
PDF
Cracking Low-Level Design Interviews with Tutort Academy: Your Gateway to Tec...
PDF
Design Patterns Presentation - Chetan Gole
PPTX
Designpattern
PPT
Design patterns
PPT
Bartlesville Dot Net User Group Design Patterns
PDF
Refactoring 2 The Max
PDF
Why Design Patterns Are Important In Software Engineering
PPTX
DesignPattern-Overview.pptx
DOCX
Understanding Creational Design Patterns in Python.docx
DOCX
Understanding Creational Design Patterns in Python
PDF
Module 2 design patterns-2
PPTX
OOP design patterns
Software design and Architecture.pptx
Design pattern
Gang of Four in Java
Design patterns
Typescript design patterns applied to sharepoint framework - Sharepoint Satur...
Design Patterns Java programming language.pdf
dotnet stuff.com tutorials-design-patterns_exploring-net-design-patterns-in-s...
Oops design pattern intro
Cracking Low-Level Design Interviews with Tutort Academy: Your Gateway to Tec...
Design Patterns Presentation - Chetan Gole
Designpattern
Design patterns
Bartlesville Dot Net User Group Design Patterns
Refactoring 2 The Max
Why Design Patterns Are Important In Software Engineering
DesignPattern-Overview.pptx
Understanding Creational Design Patterns in Python.docx
Understanding Creational Design Patterns in Python
Module 2 design patterns-2
OOP design patterns
Ad

Recently uploaded (20)

PDF
T3DD25 TYPO3 Content Blocks - Deep Dive by André Kraus
PPTX
Reimagine Home Health with the Power of Agentic AI​
PDF
System and Network Administration Chapter 2
PDF
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
PDF
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
PDF
2025 Textile ERP Trends: SAP, Odoo & Oracle
PDF
Digital Systems & Binary Numbers (comprehensive )
PPTX
Introduction to Artificial Intelligence
PPTX
VVF-Customer-Presentation2025-Ver1.9.pptx
PDF
Design an Analysis of Algorithms I-SECS-1021-03
PDF
Adobe Illustrator 28.6 Crack My Vision of Vector Design
PDF
Digital Strategies for Manufacturing Companies
PDF
Odoo Companies in India – Driving Business Transformation.pdf
PDF
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
PDF
Which alternative to Crystal Reports is best for small or large businesses.pdf
PDF
Wondershare Filmora 15 Crack With Activation Key [2025
PPTX
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
PPTX
assetexplorer- product-overview - presentation
PDF
Nekopoi APK 2025 free lastest update
PDF
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
T3DD25 TYPO3 Content Blocks - Deep Dive by André Kraus
Reimagine Home Health with the Power of Agentic AI​
System and Network Administration Chapter 2
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
2025 Textile ERP Trends: SAP, Odoo & Oracle
Digital Systems & Binary Numbers (comprehensive )
Introduction to Artificial Intelligence
VVF-Customer-Presentation2025-Ver1.9.pptx
Design an Analysis of Algorithms I-SECS-1021-03
Adobe Illustrator 28.6 Crack My Vision of Vector Design
Digital Strategies for Manufacturing Companies
Odoo Companies in India – Driving Business Transformation.pdf
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
Which alternative to Crystal Reports is best for small or large businesses.pdf
Wondershare Filmora 15 Crack With Activation Key [2025
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
assetexplorer- product-overview - presentation
Nekopoi APK 2025 free lastest update
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free

Factory Design Pattern