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>
LinkedListSet
that comparesLinkedListSetEntry
instances before adding asLinkedListSetEntry
may hold content that should not be re-added to theLinkedListSet
.Otherwise it ensure strictness of adding/removing
LinkedListSetEntry
instances.- 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 void
addEntry(E entry)
Adds aLinkedListSetEntry
to thisLinkedListSet
.protected abstract boolean
isEqual(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:
true
ifentryA
is equal toentryB
, otherwisefalse
to indicate not equal.
-
addEntry
public void addEntry(E entry)
Description copied from interface:LinkedListSet
Adds aLinkedListSetEntry
to thisLinkedListSet
.- Specified by:
addEntry
in interfaceLinkedListSet<E extends LinkedListSetEntry<E,O>,O>
- Overrides:
addEntry
in classStrictLinkedListSet<E extends LinkedListSetEntry<E,O>,O>
- Parameters:
entry
-LinkedListSetEntry
to be added to thisLinkedListSet
.
-
-