SolarMetric Kodo JDO 2.5.8 generated on January 11 2004

com.solarmetric.kodo.impl.jdbc.schema
Class ClassDBSequenceFactory

java.lang.Object
  |
  +--com.solarmetric.kodo.impl.jdbc.schema.AbstractSequenceFactory
        |
        +--com.solarmetric.kodo.impl.jdbc.schema.DBSequenceFactory
              |
              +--com.solarmetric.kodo.impl.jdbc.schema.ClassDBSequenceFactory
All Implemented Interfaces:
SchemaSequenceFactory, SequenceFactory, Serializable

public class ClassDBSequenceFactory
extends DBSequenceFactory
implements SchemaSequenceFactory

DBSequenceFactory subclass that overrides methods to be class sensitive. Kept as a subclass to maintain DBSequenceFactory efficiency. The table is automatically created if not already present.

The table this plugin uses is not compatible with the one from DBSequenceFactory

See Also:
Serialized Form

Field Summary
(package private)  Column _clsColumn
           
 
Fields inherited from class com.solarmetric.kodo.impl.jdbc.schema.DBSequenceFactory
_pkColumn, _resolver, _seqColumn
 
Constructor Summary
ClassDBSequenceFactory()
           
 
Method Summary
(package private)  Table buildTable()
          Creates the object-level representation of the sequence table.
 long getNext(Class cls, Connector connector)
          Return a unique primary key value for the given class.
(package private)  Select getSequenceSelect(Class type)
           
 void initializeSchema(SchemaTool tool, Class type)
          Creates the sequence table in the DB.
(package private)  void updateSequence(Class cls, SQLExecutionManager manager)
          Grabs the next handful of sequence numbers.
 
Methods inherited from class com.solarmetric.kodo.impl.jdbc.schema.DBSequenceFactory
dropTable, getCurrentSequence, getIncrement, getSequenceSeed, getTableName, refreshTable, setConfiguration, setIncrement, setTableName
 
Methods inherited from class com.solarmetric.kodo.impl.jdbc.schema.AbstractSequenceFactory
getConfiguration, getDictionary, setConfiguration, setDictionary
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.solarmetric.kodo.impl.jdbc.SequenceFactory
setConfiguration
 

Field Detail

_clsColumn

transient Column _clsColumn
Constructor Detail

ClassDBSequenceFactory

public ClassDBSequenceFactory()
Method Detail

getNext

public long getNext(Class cls,
                    Connector connector)
             throws SQLException
Description copied from interface: SequenceFactory
Return a unique primary key value for the given class.
Specified by:
getNext in interface SequenceFactory
Overrides:
getNext in class DBSequenceFactory

getSequenceSelect

Select getSequenceSelect(Class type)
Overrides:
getSequenceSelect in class DBSequenceFactory

initializeSchema

public void initializeSchema(SchemaTool tool,
                             Class type)
                      throws SQLException
Creates the sequence table in the DB.
Specified by:
initializeSchema in interface SchemaSequenceFactory
Overrides:
initializeSchema in class DBSequenceFactory
Following copied from interface: com.solarmetric.kodo.impl.jdbc.schema.SchemaSequenceFactory
Parameters:
manager - the SQLExecutionManager to use.
type - the class that this sequence factory is being initialize for.

buildTable

Table buildTable()
Creates the object-level representation of the sequence table.
Overrides:
buildTable in class DBSequenceFactory

updateSequence

void updateSequence(Class cls,
                    SQLExecutionManager manager)
              throws SQLException
Grabs the next handful of sequence numbers.
Overrides:
updateSequence in class DBSequenceFactory

SolarMetric Kodo JDO 2.5.8 generated on January 11 2004

Copyright 2001,2002,2003 SolarMetric, Inc. All Rights Reserved.