Represents an object's capability to have its changes undone/redone.
Changes represent transitions between states, which are then able
to be restored or re-done.
No edit actions per se should be performed by
the implementation -- restoreState should exactly re-construct
the state it represents.
Creates a new instance of the current state of the target object.
Note that this method must create a complete copy (either through clone() or
some other method. If only a reference is saved, then all saved states will really
point to the same (current) state and there will appear to be no effect.