Basic Design Pattern

Design Pattern is not a new word to all the developer from the world. We heard a lot and used it a lot. Today, I want to start here to provide some basic info for the Junior Level developer to go through the patterns.


First, what's the Design pattern?



A design pattern is a documented best practice or core of a solution that has been applied successfully in multiple environments to solve a problem that recurs in a specific set of situations.


Here is something clear for the defination of Design Pattern. Plz notice there are some words, 'best practice', 'solution', 'recurs'.


They are samiliar with the framework actially. We used a lot of popular framework from Apache group, such as Struts, Tapestry and etc.


I will list the difference between Design pattern and framework below in order to make you guys understand.

Table 1.1: Design Patterns versus Frameworks

Design Pattern

Frameworks

Design patterns are recurring solutions to problems that arise during the life of a software application in a particular context.

A framework is a group of components that cooperate with each other to provide a reusable architecture for applications with a given domain.

The primary goal is to:

The primary goal is to:

Help improve the quality of the software in terms of the software being reusable, maintainable, extensible, etc.

Reduce the development time

Help improve the quality of the software in terms of the software being reusable, maintainable, extensible, etc.
Reduce development time

Patterns are logical in nature.

Frameworks are more physical in nature, as they exist in the form of some software.

Pattern descriptions are usually independent of programming language or implementation details.

Because frameworks exist in the form of some software, they are implementation-specific.

Patterns are more generic in nature and can be used in almost any kind of application.

Frameworks provide domain-specific functionality.

A design pattern does not exist in the form of a software component on its own. It needs to be implemented explicitly each time it is used.

Frameworks are not complete applications on their own. Complete applications can be built by either inheriting the components const directly.

Patterns provide a way to do “good” design and are used to help design frameworks.

Design patterns may be used in the design and implementation of a framework. In other words, frameworks typically embody several design patterns.

 

 

 

你可能感兴趣的:(design pattern)