Package com.github.tonivade.purefun.data
Class ImmutableTreeMap.JavaBasedImmutableTreeMap<K,V>
- java.lang.Object
-
- com.github.tonivade.purefun.data.ImmutableTreeMap.JavaBasedImmutableTreeMap<K,V>
-
- All Implemented Interfaces:
ImmutableMap<K,V>,ImmutableTreeMap<K,V>,java.io.Serializable,java.lang.Iterable<Tuple2<K,V>>
- Enclosing interface:
- ImmutableTreeMap<K,V>
public static final class ImmutableTreeMap.JavaBasedImmutableTreeMap<K,V> extends java.lang.Object implements ImmutableTreeMap<K,V>, java.io.Serializable
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.github.tonivade.purefun.data.ImmutableMap
ImmutableMap.JavaBasedImmutableMap<K,V>
-
Nested classes/interfaces inherited from interface com.github.tonivade.purefun.data.ImmutableTreeMap
ImmutableTreeMap.Builder<K extends java.lang.Comparable<?>,V>, ImmutableTreeMap.JavaBasedImmutableTreeMap<K,V>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Option<Tuple2<K,V>>ceilingEntry(K key)ImmutableSet<Tuple2<K,V>>entries()booleanequals(java.lang.Object obj)Option<Tuple2<K,V>>floorEntry(K key)Option<V>get(K key)inthashCode()Option<Tuple2<K,V>>headEntry()ImmutableTreeMap<K,V>headMap(K toKey)Option<Tuple2<K,V>>higherEntry(K key)ImmutableSet<K>keys()Option<Tuple2<K,V>>lowerEntry(K key)ImmutableTreeMap<K,V>merge(K key, V value, Operator2<V> merger)ImmutableTreeMap<K,V>put(K key, V value)ImmutableTreeMap<K,V>putAll(ImmutableMap<? extends K,? extends V> other)ImmutableTreeMap<K,V>remove(K key)intsize()Option<Tuple2<K,V>>tailEntry()ImmutableTreeMap<K,V>tailMap(K fromKey)java.util.Map<K,V>toMap()java.util.NavigableMap<K,V>toNavigableMap()java.lang.StringtoString()Sequence<V>values()-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.github.tonivade.purefun.data.ImmutableMap
containsKey, forEach, iterator
-
Methods inherited from interface com.github.tonivade.purefun.data.ImmutableTreeMap
ceilingKey, filterKeys, filterValues, floorKey, getOrDefault, headKey, higherKey, isEmpty, lowerKey, map, mapKeys, mapValues, putIfAbsent, tailKey
-
-
-
-
Method Detail
-
toNavigableMap
public java.util.NavigableMap<K,V> toNavigableMap()
- Specified by:
toNavigableMapin interfaceImmutableTreeMap<K,V>
-
put
public ImmutableTreeMap<K,V> put(K key, V value)
- Specified by:
putin interfaceImmutableMap<K,V>- Specified by:
putin interfaceImmutableTreeMap<K,V>
-
putAll
public ImmutableTreeMap<K,V> putAll(ImmutableMap<? extends K,? extends V> other)
- Specified by:
putAllin interfaceImmutableMap<K,V>- Specified by:
putAllin interfaceImmutableTreeMap<K,V>
-
remove
public ImmutableTreeMap<K,V> remove(K key)
- Specified by:
removein interfaceImmutableMap<K,V>- Specified by:
removein interfaceImmutableTreeMap<K,V>
-
merge
public ImmutableTreeMap<K,V> merge(K key, V value, Operator2<V> merger)
- Specified by:
mergein interfaceImmutableMap<K,V>- Specified by:
mergein interfaceImmutableTreeMap<K,V>
-
headMap
public ImmutableTreeMap<K,V> headMap(K toKey)
- Specified by:
headMapin interfaceImmutableTreeMap<K,V>
-
tailMap
public ImmutableTreeMap<K,V> tailMap(K fromKey)
- Specified by:
tailMapin interfaceImmutableTreeMap<K,V>
-
headEntry
public Option<Tuple2<K,V>> headEntry()
- Specified by:
headEntryin interfaceImmutableTreeMap<K,V>
-
tailEntry
public Option<Tuple2<K,V>> tailEntry()
- Specified by:
tailEntryin interfaceImmutableTreeMap<K,V>
-
higherEntry
public Option<Tuple2<K,V>> higherEntry(K key)
- Specified by:
higherEntryin interfaceImmutableTreeMap<K,V>
-
lowerEntry
public Option<Tuple2<K,V>> lowerEntry(K key)
- Specified by:
lowerEntryin interfaceImmutableTreeMap<K,V>
-
floorEntry
public Option<Tuple2<K,V>> floorEntry(K key)
- Specified by:
floorEntryin interfaceImmutableTreeMap<K,V>
-
ceilingEntry
public Option<Tuple2<K,V>> ceilingEntry(K key)
- Specified by:
ceilingEntryin interfaceImmutableTreeMap<K,V>
-
keys
public ImmutableSet<K> keys()
- Specified by:
keysin interfaceImmutableMap<K,V>
-
entries
public ImmutableSet<Tuple2<K,V>> entries()
- Specified by:
entriesin interfaceImmutableMap<K,V>
-
size
public int size()
- Specified by:
sizein interfaceImmutableMap<K,V>
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-