Intent
Allow an object to alter its behavior when its internal state changes
Applicability
- an object's behavior depends on its state
- operations have conditional statements that depend on the object's state
Structure
[to do: diagram with Context and State]
Consequences
- easy to add new states
- makes state transitions and instances variables associated with a state
explicit
- increased number of classes
Implementation
- who defines the state transitions
- creating and destroying state objects
- using dynamic inheritance if applicable
Uses in JHotDraw