LookupTable

open class LookupTable<T : Number?, R> : TreeMap<K, V>

A lookup table.

Utility from FTCLib Source

Since

1.0.0-pre

Parameters

<T>

the input type

<R>

the output type

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open fun add(key: T, out: R)
Adds a key-value pair to the lookup table.
Link copied to clipboard
open fun get(key: T): R
Returns the closest possible value for the given key.

Inherited functions

Link copied to clipboard
open fun ceilingEntry(key: K): Map.Entry<K, V>
Link copied to clipboard
open fun ceilingKey(key: K): K
Link copied to clipboard
open fun clear()
Link copied to clipboard
open fun clone(): Any
Link copied to clipboard
open fun comparator(): Comparator<in K>
Link copied to clipboard
open fun compute(key: K, remappingFunction: BiFunction<in K, in V, out V>): V
Link copied to clipboard
open fun computeIfAbsent(key: K, mappingFunction: (in K) -> out V): V
Link copied to clipboard
open fun computeIfPresent(key: K, remappingFunction: BiFunction<in K, in V, out V>): V
Link copied to clipboard
open fun containsKey(key: Any): Boolean
Link copied to clipboard
open fun containsValue(value: Any): Boolean
Link copied to clipboard
open fun <K, V> copyOf(map: Map<out K, out V>): Map<K, V>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun <K, V> entry(k: K, v: V): Map.Entry<K, V>
Link copied to clipboard
open fun entrySet(): Set<Map.Entry<K, V>>
Link copied to clipboard
open fun equals(o: Any): Boolean
Link copied to clipboard
open fun firstEntry(): Map.Entry<K, V>
Link copied to clipboard
open fun firstKey(): K
Link copied to clipboard
open fun floorEntry(key: K): Map.Entry<K, V>
Link copied to clipboard
open fun floorKey(key: K): K
Link copied to clipboard
open fun forEach(action: BiConsumer<in K, in V>)
Link copied to clipboard
open fun get(key: Any): V
Link copied to clipboard
open fun getOrDefault(key: Any, defaultValue: V): V
Link copied to clipboard
open fun hashCode(): Int
Link copied to clipboard
open fun headMap(toKey: K): SortedMap<K, V>
open fun headMap(toKey: K, inclusive: Boolean): NavigableMap<K, V>
Link copied to clipboard
open fun higherEntry(key: K): Map.Entry<K, V>
Link copied to clipboard
open fun higherKey(key: K): K
Link copied to clipboard
open fun isEmpty(): Boolean
Link copied to clipboard
open fun keySet(): Set<K>
Link copied to clipboard
open fun lastEntry(): Map.Entry<K, V>
Link copied to clipboard
open fun lastKey(): K
Link copied to clipboard
open fun lowerEntry(key: K): Map.Entry<K, V>
Link copied to clipboard
open fun lowerKey(key: K): K
Link copied to clipboard
open fun merge(key: K, value: V, remappingFunction: BiFunction<in V, in V, out V>): V
Link copied to clipboard
Link copied to clipboard
open fun <K, V> of(): Map<K, V>
Link copied to clipboard
open fun <K, V> ofEntries(entries: Array<Map.Entry<out K, out V>>): Map<K, V>
Link copied to clipboard
open fun pollFirstEntry(): Map.Entry<K, V>
Link copied to clipboard
open fun pollLastEntry(): Map.Entry<K, V>
Link copied to clipboard
open fun put(key: K, value: V): V
Link copied to clipboard
open fun putAll(map: Map<out K, out V>)
Link copied to clipboard
open fun putIfAbsent(key: K, value: V): V
Link copied to clipboard
open fun remove(key: Any, value: Any): Boolean
open fun remove(key: Any): V
Link copied to clipboard
open fun replace(key: K, value: V): V
open fun replace(key: K, oldValue: V, newValue: V): Boolean
Link copied to clipboard
open fun replaceAll(function: BiFunction<in K, in V, out V>)
Link copied to clipboard
open fun size(): Int
Link copied to clipboard
open fun subMap(fromKey: K, toKey: K): SortedMap<K, V>
open fun subMap(fromKey: K, fromInclusive: Boolean, toKey: K, toInclusive: Boolean): NavigableMap<K, V>
Link copied to clipboard
open fun tailMap(fromKey: K): SortedMap<K, V>
open fun tailMap(fromKey: K, inclusive: Boolean): NavigableMap<K, V>
Link copied to clipboard
open fun toString(): String
Link copied to clipboard
open fun values(): Collection<V>