org.apache.directory.server.xdbm
Class ForwardIndexEntry<V,ID>

java.lang.Object
  extended by org.apache.directory.server.xdbm.AbstractIndexEntry<V,ID>
      extended by org.apache.directory.server.xdbm.ForwardIndexEntry<V,ID>
Type Parameters:
V - The value stored in the Tuple, associated key for the object
ID - The ID of the object
All Implemented Interfaces:
IndexEntry<V,ID>

public class ForwardIndexEntry<V,ID>
extends AbstractIndexEntry<V,ID>

An index id value pair based on a Tuple which can optionally reference the indexed Entry if one has already been loaded.

Author:
Apache Directory Project

Constructor Summary
ForwardIndexEntry()
          Creates a ForwardIndexEntry instance
 
Method Summary
 void clear()
          Clears the id, value and Entry in this IndexEntry.
 void copy(IndexEntry<V,ID> entry)
          Copies the values of another IndexEntry into this IndexEntry.
 ID getId()
          Gets the id of the indexed Entry.
 org.apache.directory.shared.ldap.model.cursor.Tuple<V,ID> getTuple()
          Gets access to the underlying tuple.
 V getValue()
          Gets the value referred to by this IndexEntry.
 void setId(ID id)
          Sets the id of the indexed.Entry
 void setTuple(org.apache.directory.shared.ldap.model.cursor.Tuple<V,ID> tuple, org.apache.directory.shared.ldap.model.entry.Entry entry)
          Sets the key value tuple represented by this ForwardIndexEntry optionally setting the Entry associated with the id if one was loaded from the master table.
 void setValue(V value)
          Sets the value referred to by this IndexEntry.
 String toString()
          
 
Methods inherited from class org.apache.directory.server.xdbm.AbstractIndexEntry
getEntry, setEntry
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ForwardIndexEntry

public ForwardIndexEntry()
Creates a ForwardIndexEntry instance

Method Detail

setTuple

public void setTuple(org.apache.directory.shared.ldap.model.cursor.Tuple<V,ID> tuple,
                     org.apache.directory.shared.ldap.model.entry.Entry entry)
Sets the key value tuple represented by this ForwardIndexEntry optionally setting the Entry associated with the id if one was loaded from the master table.

Parameters:
tuple - the tuple for the ForwardIndexEntry
entry - the resuscitated Entry if any

getId

public ID getId()
Gets the id of the indexed Entry.

Specified by:
getId in interface IndexEntry<V,ID>
Specified by:
getId in class AbstractIndexEntry<V,ID>
Returns:
the id of the indexed Entry

getValue

public V getValue()
Gets the value referred to by this IndexEntry.

Specified by:
getValue in interface IndexEntry<V,ID>
Specified by:
getValue in class AbstractIndexEntry<V,ID>
Returns:
the value of the Entry referred to

setId

public void setId(ID id)
Sets the id of the indexed.Entry

Specified by:
setId in interface IndexEntry<V,ID>
Specified by:
setId in class AbstractIndexEntry<V,ID>
Parameters:
id - the id of the indexed Entry

setValue

public void setValue(V value)
Sets the value referred to by this IndexEntry.

Specified by:
setValue in interface IndexEntry<V,ID>
Specified by:
setValue in class AbstractIndexEntry<V,ID>
Parameters:
value - the value of the Entry referred to

getTuple

public org.apache.directory.shared.ldap.model.cursor.Tuple<V,ID> getTuple()
Gets access to the underlying tuple.

Specified by:
getTuple in interface IndexEntry<V,ID>
Specified by:
getTuple in class AbstractIndexEntry<V,ID>
Returns:
the underlying tuple

clear

public void clear()
Clears the id, value and Entry in this IndexEntry.

Specified by:
clear in interface IndexEntry<V,ID>
Overrides:
clear in class AbstractIndexEntry<V,ID>

copy

public void copy(IndexEntry<V,ID> entry)
Copies the values of another IndexEntry into this IndexEntry.

Specified by:
copy in interface IndexEntry<V,ID>
Overrides:
copy in class AbstractIndexEntry<V,ID>
Parameters:
entry - the entry to copy fields of

toString

public String toString()

Overrides:
toString in class Object


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