Package net.hydromatic.morel.eval
Class Comparators.ComparatorBuilder.DeferredComparator
java.lang.Object
net.hydromatic.morel.eval.Comparators.ComparatorBuilder.DeferredComparator
- All Implemented Interfaces:
Comparator
- Enclosing class:
Comparators.ComparatorBuilder
Comparator that defers the lookup of the comparator until it is first
used. Used for cyclic types, e.g.
datatype 'a list = cons of 'a * 'a list | nil;
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) final com.google.common.base.Supplier<Comparator> -
Constructor Summary
Constructors -
Method Summary
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
-
Field Details
-
supplier
-
-
Constructor Details
-
DeferredComparator
DeferredComparator(Type.Key key)
-
-
Method Details
-
compare
- Specified by:
comparein interfaceComparator
-