Class ComparatorLinkedListSet<E extends LinkedListSetEntry<E,O>,O>
- java.lang.Object
-
- net.officefloor.frame.impl.execute.linkedlistset.StrictLinkedListSet<E,O>
-
- net.officefloor.frame.impl.execute.linkedlistset.ComparatorLinkedListSet<E,O>
-
- All Implemented Interfaces:
LinkedListSet<E,O>
public abstract class ComparatorLinkedListSet<E extends LinkedListSetEntry<E,O>,O> extends StrictLinkedListSet<E,O>
LinkedListSetthat comparesLinkedListSetEntryinstances before adding asLinkedListSetEntrymay hold content that should not be re-added to theLinkedListSet.Otherwise it ensure strictness of adding/removing
LinkedListSetEntryinstances.- Author:
- Daniel Sagenschneider
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class net.officefloor.frame.impl.execute.linkedlistset.StrictLinkedListSet
StrictLinkedListSet.LinkedListItemImpl
-
-
Constructor Summary
Constructors Constructor Description ComparatorLinkedListSet()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidaddEntry(E entry)Adds aLinkedListSetEntryto thisLinkedListSet.protected abstract booleanisEqual(E entryA, E entryB)Invoked to determine if the two entries are equal.-
Methods inherited from class net.officefloor.frame.impl.execute.linkedlistset.StrictLinkedListSet
copyEntries, getHead, getOwner, getTail, purgeEntries, removeEntry
-
-
-
-
Method Detail
-
isEqual
protected abstract boolean isEqual(E entryA, E entryB)
Invoked to determine if the two entries are equal.- Parameters:
entryA- First entry.entryB- Second entry.- Returns:
trueifentryAis equal toentryB, otherwisefalseto indicate not equal.
-
addEntry
public void addEntry(E entry)
Description copied from interface:LinkedListSetAdds aLinkedListSetEntryto thisLinkedListSet.- Specified by:
addEntryin interfaceLinkedListSet<E extends LinkedListSetEntry<E,O>,O>- Overrides:
addEntryin classStrictLinkedListSet<E extends LinkedListSetEntry<E,O>,O>- Parameters:
entry-LinkedListSetEntryto be added to thisLinkedListSet.
-
-