Example usage for java.util.concurrent ConcurrentSkipListMap floorKey

List of usage examples for java.util.concurrent ConcurrentSkipListMap floorKey

Introduction

In this page you can find the example usage for java.util.concurrent ConcurrentSkipListMap floorKey.

Prototype

public K floorKey(K key) 

Source Link

Usage

From source file:com.sm.store.TestScanKey.java

public static Key findFloorKey(ConcurrentSkipListMap map, Key key) {
    Key from = (Key) map.floorKey(key);
    if (from == null)
        from = (Key) map.ceilingKey(key);
    return from;// w  ww. ja  va2 s .c  o m
}

From source file:com.sm.store.TestScanKey.java

public static Key findCeilKey(ConcurrentSkipListMap map, Key key) {
    Key to = (Key) map.ceilingKey(key);
    if (to == null)
        to = (Key) map.floorKey(key);
    return to;//from   ww w . ja v  a2 s  .co m
}

From source file:voldemort.store.cachestore.impl.SortedCacheStore.java

public Key findFloorKey(ConcurrentSkipListMap map, Key key) {
    Key from = (Key) map.floorKey(key);
    if (from == null)
        from = (Key) map.ceilingKey(key);
    return from;/*from  w  w  w.java2  s.  c om*/
}

From source file:voldemort.store.cachestore.impl.SortedCacheStore.java

public Key findCeilKey(ConcurrentSkipListMap map, Key key) {
    Key to = (Key) map.ceilingKey(key);
    if (to == null)
        to = (Key) map.floorKey(key);
    return to;/*from   w  w w . ja  va  2  s . c o  m*/
}