The State Pattern allows an object to alter its behavior
when its internal state changes. The object will appear to
change its class.
把分散在每个方法的状态反转。
when its internal state changes. The object will appear to
change its class.
把分散在每个方法的状态反转。