Interface TrackableCollectionIF<E>

All Superinterfaces:
Collection<E>, Iterable<E>
All Known Implementing Classes:
TrackableLazySet, TrackableSet

public interface TrackableCollectionIF<E> extends Collection<E>
INTERNAL: Interface used by Collection implementations that track the changes performed on them. It keeps track of the objects that have been added and the ones that has been removed.
  • Method Details

    • resetTracking

      void resetTracking()
      INTERNAL: Clears the list of added and removed objects without touching the original collection.
    • selfAdded

      void selfAdded()
      INTERNAL: Consider existing collection elements as having just been added.
    • addWithTracking

      boolean addWithTracking(E item)
      INTERNAL: Adds the item to the collection tracking the change.
    • removeWithTracking

      boolean removeWithTracking(E item)
      INTERNAL: Removes the item from the collection tracking the change.
    • clearWithTracking

      void clearWithTracking()
      INTERNAL: Removes all items from the collection tracking the changes.
    • getAdded

      Collection<E> getAdded()
      INTERNAL: Gets the objects that have been added to the set. This collection is immutable. Null is returned if the added collection has not been initialized, ie. it is empty.
    • getRemoved

      Collection<E> getRemoved()
      INTERNAL: Gets the objects that have been removed from the set. This collection is immutable. Null is returned if the removed collection has not been initialized, ie. it is empty.