Design Patterns

Need of Factory Method Design Pattern in Frameworks Explained

In a framework we deal mainly with abstract classes. Application that is going to use our framework provides the derived classes these abstract classes. Let’s understand by an example of Thread pooling Framework, A thread pooling framework provides the facility to execute Tasks in pooled environment by worker threads. It’s doesn’t know what actually the

Need of Factory Method Design Pattern in Frameworks Explained Read More »

Binary Tree Traversal with Strategy design pattern and open-closed principle

Many time we need to perform certain tasks on Binary trees. These tasks can be, Counting nodes that satisfy some criteria. Displaying all nodes in particular pattern like, printing expression from expression tree. Creating mirror image of tree. etc.

Binary Tree Traversal with Strategy design pattern and open-closed principle Read More »

Scroll to Top