org.apache.directory.server.core.partition.avl
Class AvlTableDupsCursor<K,V>

java.lang.Object
  extended by org.apache.directory.server.xdbm.AbstractTupleCursor<K,V>
      extended by org.apache.directory.server.core.partition.avl.AvlTableDupsCursor<K,V>
All Implemented Interfaces:
java.lang.Iterable<Tuple<K,V>>, TupleCursor<K,V>, org.apache.directory.shared.ldap.cursor.Cursor<Tuple<K,V>>

public class AvlTableDupsCursor<K,V>
extends AbstractTupleCursor<K,V>

A Cursor which walks and advance over AvlTables that may contain duplicate keys with values stored in an AvlTree. All duplicate keys are traversed returning the key and the value in a Tuple.

Version:
$Rev$, $Date$
Author:
Apache Directory Project

Constructor Summary
AvlTableDupsCursor(AvlTable<K,V> table)
          Creates a new instance of AvlTableDupsCursor.
 
Method Summary
 void after(Tuple<K,V> element)
          
 void afterKey(K key)
          
 void afterLast()
          
 void afterValue(K key, V value)
          
 boolean available()
          
 void before(Tuple<K,V> element)
          
 void beforeFirst()
          
 void beforeKey(K key)
          
 void beforeValue(K key, V value)
          
 boolean first()
          
 Tuple<K,V> get()
          
 boolean isElementReused()
          
 boolean last()
          
 boolean next()
          
 boolean previous()
          
 
Methods inherited from class org.apache.directory.server.xdbm.AbstractTupleCursor
checkNotClosed, close, close, isClosed, iterator, setClosureMonitor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AvlTableDupsCursor

public AvlTableDupsCursor(AvlTable<K,V> table)
Creates a new instance of AvlTableDupsCursor.

Parameters:
table - the AvlTable to build a Cursor on.
Method Detail

available

public boolean available()


beforeKey

public void beforeKey(K key)
               throws java.lang.Exception

Throws:
java.lang.Exception

beforeValue

public void beforeValue(K key,
                        V value)
                 throws java.lang.Exception

Throws:
java.lang.Exception

afterKey

public void afterKey(K key)
              throws java.lang.Exception

Throws:
java.lang.Exception

afterValue

public void afterValue(K key,
                       V value)
                throws java.lang.Exception

Throws:
java.lang.Exception

after

public void after(Tuple<K,V> element)
           throws java.lang.Exception

Throws:
java.lang.Exception

afterLast

public void afterLast()
               throws java.lang.Exception

Throws:
java.lang.Exception

before

public void before(Tuple<K,V> element)
            throws java.lang.Exception

Throws:
java.lang.Exception

beforeFirst

public void beforeFirst()
                 throws java.lang.Exception

Throws:
java.lang.Exception

first

public boolean first()
              throws java.lang.Exception

Throws:
java.lang.Exception

get

public Tuple<K,V> get()
               throws java.lang.Exception

Throws:
java.lang.Exception

isElementReused

public boolean isElementReused()


last

public boolean last()
             throws java.lang.Exception

Throws:
java.lang.Exception

next

public boolean next()
             throws java.lang.Exception

Throws:
java.lang.Exception

previous

public boolean previous()
                 throws java.lang.Exception

Throws:
java.lang.Exception


Copyright © 2003-2010 The Apache Software Foundation. All Rights Reserved.