Class SkipSpan<K extends Comparable<? super K>,V>

java.lang.Object
net.metanotion.util.skiplist.SkipSpan<K,V>
All Implemented Interfaces:
Flushable
Direct Known Subclasses:
BSkipSpan

public class SkipSpan<K extends Comparable<? super K>,V> extends Object implements Flushable
  • Field Details

  • Constructor Details

    • SkipSpan

      protected SkipSpan()
    • SkipSpan

      public SkipSpan(int size)
  • Method Details

    • newInstance

      public SkipSpan<K,V> newInstance(SkipList<K,V> sl)
    • killInstance

      public void killInstance()
    • flush

      public void flush()
      Specified by:
      flush in interface Flushable
    • print

      public String print()
      dumps all the data from here to the end
    • getEnd

      public SkipSpan<K,V> getEnd()
    • getSpan

      public SkipSpan<K,V> getSpan(K key, int[] search)
    • get

      public V get(K key)
    • put

      public SkipSpan<K,V> put(K key, V val, SkipList<K,V> sl)
      Returns:
      the new span if it caused a split, else null if it went in an existing span
    • remove

      public Object[] remove(K key, SkipList<K,V> sl)
      Returns:
      An array of two objects or null. rv[0] is the removed object. rv[1] is the deleted SkipSpan if the removed object was the last in the SkipSpan. rv is null if no object was removed.
    • firstKey

      public K firstKey()
      I2P