Magazine
 
Design Pattern

Pattern word suggests a series of events occurring in a
definite order.

Many a times, you get an easy way to tackle a recurring problem (which has been faced earlier, by people frequently). This solving technique gradually becomes a pattern to tackle that particular problem.

In a broad spectrum, it can be said that a pattern describes a proven solution to a recurring problem. Pattern gives emphasis on the context and the forces causing the problem, and it invents the consequences and impacts of the solution to the problem (where context is the environment, surroundings, situation, or interrelated conditions within which the problem exists).

What is a design pattern?

The design patterns are language-independent strategies used to solve common object-oriented design issues (problems). When you design a problem, you should know some common solutions. It makes communication between team players easier, effective and result oriented.

A good software-developer should know at least some popular solutions to the coding problems. These solutions prove efficient and effective to the new breed of developers as they are gradually developed by the experienced developers. Such solutions are described as so-called design patterns.

Learning design patterns speeds up a developer experience in accumulating OOA/OOD concepts. Once a developer grasp them, he would be benefited from them to be a master of designing and developing. Furthermore, he will use these terms to communicate with his fellows or assessors more effectively. Design pattern is a indispensable part of Java and J2ee technologies.

Learning the design patterns is a multiple step process:

1. Individual acceptance

 

2. Group/Mass recognition
3. Internalization

Why Use Patterns?

They have been proven. Patterns reflect the experience,
knowledge and engineering insights of developers who have successfully used these patterns in their own work.
They are reusable. Patterns provide a ready-made solution that can be adapted to different problems without the need to reinvent the wheel on a project-by-project basis.
They are expressive. Patterns provide a common vocabulary of solutions that can express large solutions succinctly.They provide a design vocabulary and reusable artifacts. Once described, any level engineer can use the pattern. Many programmers don’t know design patterns even with many years of experience. However as an Object-Oriented programmer, they have to know them well, especially for a new Java programmer. Actually, when you solve a coding problem, you use a design pattern rather you may not know a popular name to describe it. It is always beneficial to learn from the experiences of the past to solve the coding problems and use them in your projects are a best way.

To keep pace with the new developments, it is imperative that you are not wasting time in maintaining designs that have poor architecture or code that was poorly written. Just use the Design Patterns as they involved a highly experienced engineering in recognizing, collaborating and refining a design pattern. Design pattern is just a recommendation and it is up to the engineer or architect, to apply a pattern appropriately to his scenario.

A design pattern does not apply that only one solution exists for a problem neither it necessarily imposes as the best solution in all cases. Patterns merely provide a best-practice approach to a particular problem, learned through the countless experiences of the programming community. A pattern often has several variations. Each programmer must determine if and when to apply a particular pattern. Often, the programming environment in use influences the pattern choice. Not all programming environments and languages support all design patterns. What may be easy to create in one environment or language may be extremely difficult in another

Relationship among Design patterns?

Patterns have relationships and work together to form a weave. That is why, it is found that more familiar you are with the different patterns, better you determine their interactions. Generally, to build a system, you may need many patterns to fit together. Patterns can also be used to design frameworks. Different designer may use different patterns to solve the same problem. Usually:

I Some patterns naturally fit together
II One pattern may lead to another
III Some patterns are similar and alternative

July 2007 | Java Jazz Up | 27
 
previous
index
next
 
Pages: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53 ,            Download PDF