Today’s pattern is the Flyweight pattern, used to share large number of objects in an efficient way.Flyweight in the Real World
The classic example of the Flyweight pattern is the representation of a character in a word processor. Rather than each character having seperate glyph objects that represent the font and formatting data, each character could have a reference to a flyweight glyph object shared by every instance of the same cahracter in the document. In this case, the character need only store i...
↧