Skip to content

muthukanna/Design_Pattern_in_java

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Java Project: Design Patterns This project demonstrates five creational design patterns, providing structured approaches to object instantiation in Java. It is implemented using JavaSE-21 and organized into different packages, each focusing on a specific design pattern:

  1. Abstract Factory Pattern (com.creational.abstractfactorydesignpattern) Encapsulates a group of related factory methods to create families of related objects without specifying their concrete classes. Useful when multiple object types share common interfaces.
  2. Builder Pattern (com.creational.builderdesignpattern) Simplifies complex object creation by providing a step-by-step approach. It separates construction from representation, making the code more readable and scalable.
  3. Factory Pattern (com.creational.factorydesignpattern) Provides a way to create objects without exposing the instantiation logic. It relies on an interface or superclass and helps decouple object creation from implementation.
  4. Prototype Pattern (com.creational.prototype) Allows creating a new object by copying an existing one, instead of relying on direct instantiation. It's useful when object creation is costly.
  5. Singleton Pattern (com.creational.singletondesignpattern) Ensures that only one instance of a class exists and provides a global access point to it. This is useful for managing shared resources like configuration settings or logging utilities.

About

Design Pattern

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages