Observations and Measurements

From CSSEMediaWiki
Revision as of 01:33, 18 October 2010 by Joey Scarr (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Observations and Measurements refers to a group of analysis patterns from Martin Fowler 1997. These patterns apply to computer systems that record information about objects in the real world. The typical way of doing this is by recording each piece of information as an attribute of an object. However, this is not always an ideal solution, and these design patterns are intended to provide better solutions by factoring out data into objects.

Quantity

When recording measurements in a computer system, the simplest way is to store the data as a numerical attribute on a class. However, it isn't meaningful to measure something by a number only - there must also be a unit present for the quantity to have any significance. This obvious "clump" of data (see the Data clumps smell) implies that the two fields should be factored out into a new class.

Personal tools