Java Techies- Solution for All
Design Patterns
Design patterns are the best practices to solve the common design/coding problems. Design patterns are programming
language independent strategy for solving common object-oriented design problems.
Learn more... |
Design patterns make it easier to reuse successful designs and architectures.Expressing proven techniques as design patterns makes them more accessible to
developers of new systems.
Learn more... |
Creational patterns defines the best possible way to initialize the object. These initialize the object according to the nature of the program.
Learn more... |
2.2 Factory Pattern
Factory pattern or Factory method pattern is a java class that is use to encapsulate object creation code.
Learn more... |
Abstract factory pattern is one level higher than factory pattern.
Learn more... |
Singleton pattern is one of the most important pattern used commonly. This pattern is used when we want to restrict class to make only single object and that single object is used by all other classes.
Learn more... |
2.5 Builder Pattern
Builder pattern is used to build complex object from simple objects.
Learn more... |
As a name suggest Prototype means making a clone that is a new object is created by cloning an existing one.
Learn more... |
Structural pattern
Structural patterns are concerned with how classes and objects are composed to form larger structures.Structural class patterns use inheritance to compose
interfaces or implementations.
Learn more... |
3.2 Adapter pattern
Convert the interface of a class into another interface clients expect.
Learn more... |
3.3 Bridge pattern
In this pattern, we separate an abstraction and its implementation and develop separate inheritance structures for both the abstraction and the implementor.
Learn more... |
In this pattern object are compose into tree structure to represent part-whole hierarchies.
Learn more... |
Decorator pattern or wrapper is use to add responsibility or behavior to an object.
Learn more... |
3.6 Façade pattern
Facade pattern defines a higher-level interface that makes the subsystem easier to use.
Learn more... |
In this pattern, instead of creating large numbers of similar objects, objects are reused.
Learn more... |
3.8 Proxy pattern
If creation of object is expensive, its creation can be postponed till the very need arises
Learn more... |
Behavioral pattern
A behavioral class pattern uses inheritance for distribution of behavior. The interactions between the objects should be such that they are talking to each other and still are loosely coupled.
Learn more... |
4.2 Command Pattern
In this pattern client request passes as a command and based on this command request maps to particular modules as result request module invokes.
Learn more... |
4.3 Observer pattern
This pattern defines one to many dependency between objects so that if one object changes state, all its dependent objects are inform and change automatically.
Learn more... |
4.4 Iterator pattern
Iterator pattern allow use to iterate through a collection of data using a common interface without knowing internal structure
Learn more... |
4.5 Strategy pattern
Define a family of algorithms, encapsulate each one, and make them interchangeable.
Learn more... |
4.6 Template pattern
This pattern implement the invariant parts of an algorithm once and leave it upto subclasses to implement the behavior that can vary.
Learn more... |
4.7 Visitor pattern
In Visitor pattern, we use a visitor class which changes the executing algorithm of an element class.
Learn more... |