Quantcast
Channel: JavaPins - Stories tagged with design pattern
Viewing all articles
Browse latest Browse all 25

Design Patterns Uncovered: The Composite Pattern

$
0
0
Today’s pattern is the Composite pattern, which comes into play when developing a system where a component could either be an individual object or a representation of a collection of objects.Composite in the Real World In programming, composites are used when dealing with tree structures. This itself is quite an abstract concept. One example of composite that you see daily is a menu system, where a menu bar has menu has many menu items, which themselves can have submenus. Anything that can be modelled a...
Pin it

Viewing all articles
Browse latest Browse all 25

Trending Articles