Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConcreteFlyweight ¶
type ConcreteFlyweight struct {
// contains filtered or unexported fields
}
创建具体享元类,可以共享以支持大型有效的对象数量
func (ConcreteFlyweight) Operation ¶
func (fw ConcreteFlyweight) Operation(extrinsicState string) string
具体享元对象的方法
type FlyweightFactory ¶
type FlyweightFactory struct {
// contains filtered or unexported fields
}
创建用于创建和存储享元的享元工厂类
func (*FlyweightFactory) GetFlyweight ¶
func (f *FlyweightFactory) GetFlyweight(state string) *ConcreteFlyweight
获取或创建具体享元对象
Click to show internal directories.
Click to hide internal directories.