Use sharing to support large numbers of fine-grained objects efficiently.
通过共享来支持高效使用大量细粒度对象。
该模式适用于以下所有条件都满足的情形:
Flyweight
) Request(ExtrinsicState)
)。SharedFlyweight
, UnsharedFlyweight
) intrinsicState
),以便实现共享。UnsharedFlyweight
) 还要存储对象的外在状态 (extrinsicState
)。FlyweightFactory
) Clinet
)