Package net.ontopia.topicmaps.utils
Class TopicNameComparator
java.lang.Object
net.ontopia.topicmaps.utils.ScopedIFComparator<TopicNameIF>
net.ontopia.topicmaps.utils.TopicNameComparator
- All Implemented Interfaces:
Comparator<TopicNameIF>
INTERNAL: Comparator that first sorts by type then by scope,
where untyped base names are ordered before typed ones.
- Since:
- 3.0
-
Field Summary
Fields inherited from class net.ontopia.topicmaps.utils.ScopedIFComparator
scope, subcomparator -
Method Summary
Modifier and TypeMethodDescriptionintcompare(TopicNameIF o1, TopicNameIF o2) INTERNAL: Compares the two ScopedIF objects for their applicability in the scope specified in the constructor.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Method Details
-
compare
Description copied from class:ScopedIFComparatorINTERNAL: Compares the two ScopedIF objects for their applicability in the scope specified in the constructor.- Specified by:
comparein interfaceComparator<TopicNameIF>- Overrides:
comparein classScopedIFComparator<TopicNameIF>- Parameters:
o1- An object implementing ScopedIF.o2- An object implementing ScopedIF.- Returns:
- See
Comparator.compare(Object,Object)
-