Model View Controller (MVC) Design Pattern

Introduction Model-View-Controller (MVC)is a classic design pattern often used by applications that need the ability to maintain multiple views of the same data. That is when we want to use the same data but rendered on different types of devices like PC, mobile, pad etc. Each of these devices will be required to render the same content in a different format. The MVC pattern hinges … Continue reading Model View Controller (MVC) Design Pattern

Design Pattern and Types

Introduction There are so many books and article on the internet that already explain these topics in depth. But sometimes what we look is brief but up to date description of topics. In the coming days, I will be writing some articles which will explain different design patterns as short as possible. anyone can use this as Quick Reference material. In day to day software … Continue reading Design Pattern and Types

Prototype Pattern

Introduction Is a Creational Pattern. This design pattern that is used to instantiate a class by copying, or cloning, the properties of an existing object. The new object is an exact copy of the prototype but permits modification without altering the original. Cloning can be achieved by implementing ICloneable of the System namespace. The only member of ICloneable interface is Clone method that returns a new … Continue reading Prototype Pattern

Difference between MVC & MVP

Introduction Model-View-Controller (MVC) and Model-View-Presenter (MVP) patterns are used for quite a time by many developers/ architects for designing applications. Both (MVC & MVP) patterns have been used for several years and address a key OO principal namely separation of concerns between the UI and the business layers. One question that keeps coming up over and over again is: What are the differences between the … Continue reading Difference between MVC & MVP

Model View Presenter Pattern

Introduction MVP is a variation of MVC, Loosely couple modules. It separates the concerns of an application’s data, presentation, and user input into specialized components. The view and the model don’t know of each other. There are normally four main classes used in the MVP pattern (3 classes and 1 interface) View (WinForm/ WebForm/XAML-file). Interface (describes the fields in view). Presenter (executes the views actions … Continue reading Model View Presenter Pattern

Facade Pattern

They fall into structural pattern categories. Façade pattern sits on the top of group of subsystems and allows them to communicate in a unified manner. The façade takes care of orchestration part and present more simplified interface to the client.   Example: In a typical online shopping cart when a customer places any order following things happens. Get Product Details Make Payment Print Invoice The … Continue reading Facade Pattern

Singleton Pattern

The singleton pattern falls into Creational patterns. When it is used Used when we want only one object to be shared between clients. The client should not create an object. The object should be created only once and then the same object should service all the client requests. How to Implement There are various different ways of implementing the singleton pattern in C# based on … Continue reading Singleton Pattern