interface Comp<K>
An object providing methods to compare two values of type K
.
Companion namespace: Comp
Type parameters
Name | Description |
---|---|
K | the value type |
Methods
compare
Returns 0 if given value1
and value2
are equal, a positive value is value1
is greater than value2
, and a negative value otherwise.
compare
value1
and value2
are equal, a positive value is value1
is greater than value2
, and a negative value otherwise.isComparable
Returns true if this instance can compare given obj
.
isComparable
obj
.