+1

Memento: State Encapsulation.

Torky 1 year ago 0
Instead of having the Memento and the Object coupled on private attributes being declared in both classes (State). We can encapsulate these elements in a State object with a known interface, hence different states can be used and classes are less coupled.