Interface Restorable

    • Method Detail

      • createMemento

        Object createMemento()
        Creates a memento which contains all state information used to restore this object at a later point in time by calling setMemento(memento).
        Returns:
        A memento, or null if a memento cannot be created.
      • setMemento

        void setMemento​(Object memento)
        Restores this object's state from the given memento object.

        This method will always (at least) accept the memento objects created by the createMemento() method.

        Parameters:
        memento - A memento object.