| |
| | A look at the Composite design pattern - Java World |
 | | Before we dive into the Composite pattern, I must first define composite objects: objects that contain other objects; for example, a drawing may be composed of graphic primitives, such as lines, circles, rectangles, text, and so on. |
 | | But we also want to perform the same operation on composites, such as drawings, that are composed of those primitives. |
 | | If we must distinguish between primitive objects and composites to perform the same operations on those two types of objects, our code would become more complex and more difficult to implement, maintain, and extend. |
| www.javaworld.com /javaworld/jw-09-2002/jw-0913-designpatterns.html (761 words) |
|