edu.indiana.iucbrf.feature
Class DBFeatureKeyIntFactory

java.lang.Object
  extended by edu.indiana.iucbrf.feature.FeatureKeyFactory
      extended by edu.indiana.iucbrf.feature.FeatureKeyIntFactory
          extended by edu.indiana.iucbrf.feature.DBFeatureKeyIntFactory
All Implemented Interfaces:
java.io.Serializable

public class DBFeatureKeyIntFactory
extends FeatureKeyIntFactory

In contrast to FeatureKeyIntFactory, DBFeatureKeyIntFactory does not store the next key in memory. Rather, it reads from the database each time a new key is needed, and writes to the database each time the next available key is incremented.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class edu.indiana.iucbrf.feature.FeatureKeyIntFactory
nextKey
 
Fields inherited from class edu.indiana.iucbrf.feature.FeatureKeyFactory
constantName, dbFactory, info, nextKeyValueSet
 
Constructor Summary
DBFeatureKeyIntFactory(DBInfo info)
          Creates a new instance of DBFeatureKeyIntFactory
 
Method Summary
 FeatureKey generateKey()
          Method generateKey
 int getAndIncrementNextKeyFromDB()
           
 
Methods inherited from class edu.indiana.iucbrf.feature.FeatureKeyIntFactory
convertDBStringToKey, reset, setNextKey, setNextKeyFromDB, setNextKeyFromDB, storeNextKeyToDB
 
Methods inherited from class edu.indiana.iucbrf.feature.FeatureKeyFactory
finalize, isDBFactory, isNextKeyValueSet, setDBFactory, setNextKeyValueSet, shutDown
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DBFeatureKeyIntFactory

public DBFeatureKeyIntFactory(DBInfo info)
Creates a new instance of DBFeatureKeyIntFactory

Method Detail

generateKey

public FeatureKey generateKey()
Method generateKey

Overrides:
generateKey in class FeatureKeyIntFactory
Returns:
a FeatureKey

getAndIncrementNextKeyFromDB

public int getAndIncrementNextKeyFromDB()