Comparator

open class Comparator<T> : Comparator<T> (source)

A comparator implementation based on the names returned by the given namer.

Parameters

<T>

The type of object that the namer can name

Constructors

Link copied to clipboard
constructor(namer: Namer<in T>)

Functions

Link copied to clipboard
open fun compare(o1: T, o2: T): Int
Link copied to clipboard
open fun <T, U> comparing(keyExtractor: (in T) -> out U, keyComparator: Comparator<in U>): Comparator<T>
Link copied to clipboard
open fun <T> comparingDouble(keyExtractor: ToDoubleFunction<in T>): Comparator<T>
Link copied to clipboard
open fun <T> comparingInt(keyExtractor: ToIntFunction<in T>): Comparator<T>
Link copied to clipboard
open fun <T> comparingLong(keyExtractor: ToLongFunction<in T>): Comparator<T>
Link copied to clipboard
open fun equals(obj: Any): Boolean
Link copied to clipboard
open fun hashCode(): Int
Link copied to clipboard
open fun <T : Comparable<in T>?> naturalOrder(): Comparator<T>
Link copied to clipboard
open fun <T> nullsFirst(comparator: Comparator<in T>): Comparator<T>
Link copied to clipboard
open fun <T> nullsLast(comparator: Comparator<in T>): Comparator<T>
Link copied to clipboard
open fun reversed(): Comparator<T>
Link copied to clipboard
open fun <T : Comparable<in T>?> reverseOrder(): Comparator<T>
Link copied to clipboard
open fun thenComparing(other: Comparator<in T>): Comparator<T>
Link copied to clipboard
open fun thenComparingDouble(keyExtractor: ToDoubleFunction<in T>): Comparator<T>
Link copied to clipboard
open fun thenComparingInt(keyExtractor: ToIntFunction<in T>): Comparator<T>
Link copied to clipboard
open fun thenComparingLong(keyExtractor: ToLongFunction<in T>): Comparator<T>