Design Patterns

From Uncyclopedia, the content-free encyclopedia.

Jump to: navigation, search

Design Patterns abstract common software design principles into reusable patterns that should be applied where possible. All Patterns differ distinctively from each other and can be classified into different categories, Cremational, Destructural and Misbehavioral. However, implementations of design patterns normally do not appear isolated in large software projects, but are bungled (or merely con-fused) into conglomerates.

As a general rule of thumb, keep in mind that your code instantly gets 270-890% better when using design patterns (unless, of course, you are programming in Perl or Assembly). Note also that design patterns let you score big time with the ladies at parties (unless you abuse Dependency Rejection pattern), increase the size of your member, make you a better driver, and level you directly to OT9.

When writing code in any typical modern software project, it is very important to adhere strictly to these patterns, to avoid shocking your teammates. This is known as the Principle of Least Surprise.

Contents

[edit] Cremational Patterns

Below is a list of five cremational patterns.

[edit] Abject Poverty

The Abject Poverty Pattern is evident in software that is so difficult to test and maintain that doing so results in massive budget overruns.

[edit] Blinder

The Blinder Pattern is an expedient solution to a problem without regard for future changes in requirements. It is unclear as to whether the Blinder is named for the blinders worn by the software designer during the coding phase, or the desire to gouge his eyes out during the maintenance phase.

[edit] Fallacy Method

The Fallacy method is evident in handling corner cases. The logic looks correct, but if anyone actually bothers to test it, or if a corner case occurs, the Fallacy of the logic will become known.

[edit] ProtoTry

The ProtoTry Pattern is a quick and dirty attempt to develop a working model of software. The original intent is to rewrite the ProtoTry, using lessons learned, but schedules never permit. The ProtoTry is also known as legacy code.

[edit] Simpleton

The Simpleton Pattern is an extremely complex pattern used for the most trivial of tasks. The Simpleton is an accurate indicator of the skill level of its creator.

[edit] Destructural Patterns

Below is a list of eight destructural patterns.

[edit] Adopter

The Adopter Pattern provides a home for orphaned functions. The result is a large family of functions that don't look anything alike, whose only relation to one another is through the Adopter.

[edit] Brig

The Brig Pattern is a container class for bad software. Also known as module.

[edit] Compromise

The Compromise Pattern is used to balance the forces of schedule vs. quality. The result is software of inferior quality that is still late.

[edit] Detonator

The Detonator is extremely common, but often undetected. A common example is the calculations based on a 2 digit year field. This bomb is out there, and waiting to explode!

[edit] Fromage

The Fromage Pattern is often full of holes. Fromage consists of cheesy little software tricks that make portability impossible. The older this pattern gets, the riper it smells.

[edit] Flypaper

The Flypaper Pattern is written by one designer and maintained by another. The designer maintaining the Flypaper Pattern finds herself stuck, and will likely perish before getting loose.

[edit] ePoxy

The ePoxy Pattern is evident in tightly coupled software modules. As coupling between modules increases, there appears to be an epoxy bond between them.

[edit] Dependency Rejection

The goal of this pattern is to reduce coupling. A male component sends a request to a female component so they can interoperate. The female component refuses the request with a lame excuse such as a buffer overflow error or a no such method exception.

[edit] Misbehavioral Patterns

Below is a list of twelve misbehavioral patterns.

[edit] Chain of Irresponsibility

The Chain of Irresponsibility Pattern allows many large, useless modules to be combined together to defer implementation to each other. By "passing the buck", this patten frees programmers from having to do actual work. See also Facade Pattern.

[edit] Commando

The Commando Pattern is used to get in and out quick, and get the job done. This pattern can break any encapsulation to accomplish its mission. It takes no prisoners.

[edit] Intersperser

The Intersperser Pattern scatters pieces of functionality throughout a system, making a function impossible to test, modify, or understand.

[edit] Instigator

The Instigator Pattern is seemingly benign, but wreaks havoc on other parts of the software system.

[edit] Momentum

The Momentum Pattern grows exponentially, increasing size, memory requirements, complexity, and processing time.

[edit] Medicator

The Medicator Pattern is a real time hog that makes the rest of the system appear to be medicated with strong sedatives.

[edit] Absolver

The Absolver Pattern is evident in problem ridden code developed by former employees. So many historical problems have been traced to this software that current employees can absolve their software of blame by claiming that the absolver is responsible for any problem reported. Also known as It's-not-in-my-code.

[edit] Stake

The Stake Pattern is evident in problem ridden software written by designers who have since chosen the management ladder. Although fraught with problems, the manager's stake in this software is too high to allow anyone to rewrite it, as it represents the pinnacle of the manager's technical achievement.

[edit] Eulogy

The Eulogy Pattern is eventually used on all projects employing the other 22 Resign Patterns. Also known as Post Mortem.

[edit] Tempest Method

The Tempest Method is used in the last few days before software delivery. The Tempest Method is characterized by lack of comments, and introduction of several Detonator Patterns.

[edit] Visitor From Hell

The Visitor From Hell Pattern is coincident with the absence of run time bounds checking on arrays. Inevitably, at least one control loop per system will have a Visitor From Hell Pattern that will overwrite critical data.

[edit] Unwanted Guest

The Unwanted Guest pattern is the very useful idea of sideffects taken to extreme. This guest uses all kinds of under-the-cover mechanisms, such as reflection in Java, to modify the state of your program when you least expect it.

[edit] References

  • Gamma, E., Helm, R., Johnson, R., Vlissides, J., Design Patterns - Elements of Reusable Object-Oriented Software. Addison-Wesley, 1995.

[edit] Related Articles

Personal tools
projects