2008-05-23

some thoughts of composite & visitor pattern

关键字: composite command visitor java pattern
At first, let's look the typical class structure diagram of composite pattern:   Composite pattern is very suitable for Tree structure. The picture showed above defines a Interface Node and two sub concrete tree types  : Leaf  and Branch.  Branch may contains sub branch and ...