Class TextAccumulatorMemento

    • Constructor Detail

      • TextAccumulatorMemento

        public TextAccumulatorMemento​(Fragment<?> fragment)
    • Method Detail

      • copy

        public Memento copy()
        Description copied from interface: Memento
        Performs a deep clone of this Memento.
        Specified by:
        copy in interface Memento
        Returns:
        a deep clone of this Memento
      • restore

        public void restore​(Memento memento)
        Description copied from interface: Memento
        Combines a Memento state with this Memento
        Specified by:
        restore in interface Memento
        Parameters:
        memento - the Memento restoring this Memento
      • getFragment

        public Fragment<?> getFragment()
        Specified by:
        getFragment in interface Memento
        Returns:
        the fragment which this Memento is bound to
      • getAnchor

        public String getAnchor()
        Description copied from interface: Memento
        Gets the anchor value of this Memento. Mementos with equal anchor values are considered to be capturing the state of the same object but at different points in time.
        Specified by:
        getAnchor in interface Memento
        Returns:
        the ID of this Memento
      • getText

        public String getText()