Cross Cutting Concern

A cross-cutting concern is some software concern (synchronization, logging, memory allocation, Network Transparency, UI preferences) that is for the most part outside of (and orthogonal to) the Problem Domain a software component/module is concerned with, but important nonetheless. Many different techniques have been developed to deal with these--some good, some bad, some Ug Ly.

Techniques include:

Meta Object Protocols, in particular things like before functions, after functions, etc.

Decorators (both Decorator Pattern and the language feature in Java), delegation in general.

RPC tools

Many of the Creational Patterns can be used to allow variation of some cross-cutting concern at runtime.

A programming paradigm dealing with this stuff is Aspect Oriented Programming.

A few bad techniques for dealing with Cross Cutting Concerns include:

Grand Central Station (aggregating lots of independent domain functionality into a Big Ball Of Mud just so the Cross Cutting Concern(s) can be dealt with in one place).



See original on c2.com