Patterns knowledge help to improving
our coding architect skills. If you are code beginner, you
can analysis which is the suitable for your project. If you done on
anything wrong it will be transformed directly into code and you also mind how
to solve a problem that can be used in many different situations.
MVC Design Pattern:
This pattern is used by many of framework like
as PHP, JAVA & .NET. MVC design pattern was
introduced in 1970’s. It will divide an application into three main
part
·
Model
·
View
·
Controller
Model: The model represents a set
of classes that describe the business logic. It also
defines business rules for data means how the data can be changed and
manipulated.
View: The view represents the UI
Components like HTML, CSS & JS
Controller: The
Controller receives input from users over the View, then
process the user’s data with the help of the model and passing the results back
to the view.
MVVM Design Pattern:
This pattern supports two-way data binding between view and View
model. It will work automatic propagation of changes, within the state of
view model to the View. It will divide an application into three
main part
·
Model
·
View
·
View Model
Model: The model represents a set
of classes that describe the business logic. It also
defines business rules for data means how the data can be changed and
manipulated.
View: The view represents the UI
Components like HTML, CSS & JS
View Model – The View Model is responsible
for exposing methods, commands, and other properties that helps to maintain the
state of the view, manipulate the model as the result of actions on the view,
and trigger events in the view itself
MVP Design Pattern:
This pattern is similar to MVC pattern in which controller has
been replaced by the presenter. It will divide an application
into three main part
·
Model
·
View
·
View Model
Model: The model represents a set
of classes that describe the business logic. It also
defines business rules for data means how the data can be changed and
manipulated.
View: The view represents the UI
Components like HTML, CSS & JS
Presenter – The Presenter is responsible
for handling all UI events on behalf of the view. This
receive input from users via the View, then process the user’s data with the
help of Model and passing the results back to the View. There is
one-to-one relationship between View and Presenter means one View is mapped to
only one Presenter