Tag Archive 'java'

Now that enterprises have chosen stable platforms (JVM and .Net), on top of which we can choose a syntax out of many available, which language will you pick up as your next favourite?
New languages to have a look at (my own selection)
Based on what I read everyday in various blogs, I arbitrarily reduced the list [...]

This anti-pattern is about Using String instances all the time instead of more powerful objects. This is a special case of primitive obsession.
Examples
Here are some flavours of this anti-pattern:

String as keys in a Map: I have seen calls to toString() on objects just to use their String representation as a key in a Map: [...]

Deciding where and how to place the annotations is not innocent. The last thing we want is to create extra maintenance effort because of the annotations. In other words, we want annotations that are stable, or that change for the same reasons and at the same time than the elements they annotate. This article suggests [...]

Many concepts look obvious because they are used often, not because they are really simple.
Small quantities that we encounter all the time in most projects, such as date, time, price, quantity of items, a min and a max… hardly are a subject of interest from developers “as it is obvious that we can represent them [...]

Patterns represent a couple (intent, solution), where the intent matters most. Based on that intents, that can be generic or specialized, I propose to consider patterns like types in languages with strong typing, for the compiler to enforce their constraints.
Declaring patterns: what for?
Consider the very simple Quantity pattern from Analysis Patterns (Fowler):
Represent dimensioned values with [...]

Low coupling between objects is a key principle to help you win the battle against software entropy. Making sure your dependencies are under control matters. Several tools can enforce dependencies restrictions, such as JDepend. However in a real project with many classes, packages and modules, the real issue is how to decide and configure the [...]

In finance, options are powerful tools for traders, and many design practices including design patterns can be seen as options. Options can -perhaps- yield a great benefit for a certain and immediate cost. If this cost is cheap enough it can be quite attractive.
An option to buy a stock is a right to buy the [...]

I juste wanted to automate the creation of programs for my Akai MPC500 sampler/groove machine, for my personal needs, and I ended up releasing a piece of software to sourceforge. It is called MPC Maid, read “assistant of the MPC”, here is a screenshot of the program editor:
The MPC file format was freely available on [...]

The more patterns developers know, the most efficient they become within a team: it only takes one or two words (the pattern name) to communicate a design decision or proposal, instead of 10 mn of explanations. Communication also gets much more accurate and to-the-point (or less fuzzy).
Because patterns often form a pattern language, not only [...]

Composite patterns, such a the Bureaucracy pattern, are patterns built by the composition of other “smaller” patterns. However even usual design patterns can be considered composite patterns made of smaller subpatterns.
The goal is therefore to find out which are the main subpatterns that enable to reconstruct as many design patterns as possible.
The subpatterns
From an early [...]