org.apache.directory.server.xdbm
Interface MasterTable<ID,E>

All Superinterfaces:
Table<ID,E>
All Known Implementing Classes:
AvlMasterTable

public interface MasterTable<ID,E>
extends Table<ID,E>

A master table used to store indexable entries.

Author:
Apache Directory Project

Field Summary
static String DBF
          the base name for the db file for this table
static String SEQPROP_KEY
          the sequence key - stores last sequence value in the admin table
 
Method Summary
 ID getNextId(E entry)
          Gets the next value from the sequence of this MasterTable.
 void resetCounter()
          Resets the root ID to 0, this method should be called after deleting the context entry of the partition
 
Methods inherited from interface org.apache.directory.server.xdbm.Table
close, count, count, cursor, cursor, get, getKeyComparator, getName, getValueComparator, greaterThanCount, has, has, hasGreaterOrEqual, hasGreaterOrEqual, hasLessOrEqual, hasLessOrEqual, isDupsEnabled, lessThanCount, put, remove, remove, valueCursor
 

Field Detail

DBF

static final String DBF
the base name for the db file for this table

See Also:
Constant Field Values

SEQPROP_KEY

static final String SEQPROP_KEY
the sequence key - stores last sequence value in the admin table

See Also:
Constant Field Values
Method Detail

getNextId

ID getNextId(E entry)
             throws Exception
Gets the next value from the sequence of this MasterTable. This has the side-effect of incrementing the sequence values permanently.

Parameters:
entry - the entry in case the id is derived from the entry.
Returns:
the current value of this MasterTable's sequence incremented by one
Throws:
Exception - on failure to update the id sequence

resetCounter

void resetCounter()
                  throws Exception
Resets the root ID to 0, this method should be called after deleting the context entry of the partition

Throws:
Exception - in case of any failure while resetting the root id value


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