org.datanucleus.metadata
Class TableGeneratorMetaData

java.lang.Object
  extended by org.datanucleus.metadata.MetaData
      extended by org.datanucleus.metadata.TableGeneratorMetaData
All Implemented Interfaces:
java.io.Serializable

public class TableGeneratorMetaData
extends MetaData

Representation of the MetaData of a TableGenerator (JPA).

Since:
1.1
Version:
$Revision: 1.5 $
See Also:
Serialized Form

Field Summary
protected  long allocationSize
          Allocation size for ids from the table.
protected  java.lang.String catalogName
          Name of the catalog to use for the table
protected  long initialValue
          Initial value in the table.
protected  java.lang.String name
          Name under which this table generator is known.
protected  java.lang.String pkColumnName
          Name of the primary-key column name
protected  java.lang.String pkColumnValue
          Name of the primary-key column value
protected  java.lang.String schemaName
          Name of the schema to use for the table
protected  java.lang.String tableName
          Name of the table to use for sequences
protected  java.lang.String valueColumnName
          Name of the value column name
 
Fields inherited from class org.datanucleus.metadata.MetaData
extensions, LOCALISER, METADATA_CREATED_STATE, METADATA_INITIALISED_STATE, METADATA_POPULATED_STATE, METADATA_USED_STATE, metaDataState, parent, VENDOR_NAME, VENDOR_NAME_OLD
 
Constructor Summary
TableGeneratorMetaData(MetaData parent, java.lang.String name, java.lang.String tableName, java.lang.String catalogName, java.lang.String schemaName, java.lang.String pkColumnName, java.lang.String valueColumnName, java.lang.String pkColumnValue, java.lang.String initialValue, java.lang.String allocationSize)
          Constructor.
 
Method Summary
 long getAllocationSize()
          Accessor for the allocation size of the sequence.
 java.lang.String getCatalogName()
          Accessor for the catalog name.
 java.lang.String getFullyQualifiedName()
          Convenience accessor for the fully-qualified name of the sequence.
 long getInitialValue()
          Accessor for the initial value of the sequence.
 java.lang.String getName()
          Accessor for the generator name.
 java.lang.String getPKColumnName()
          Accessor for the PK column name.
 java.lang.String getPKColumnValue()
          Accessor for the PK column value.
 java.lang.String getSchemaName()
          Accessor for the schema name.
 java.lang.String getTableName()
          Accessor for the table name.
 java.lang.String getValueColumnName()
          Accessor for the value column name.
 java.lang.String toString(java.lang.String prefix, java.lang.String indent)
          Returns a string representation of the object.
 
Methods inherited from class org.datanucleus.metadata.MetaData
addExtension, addExtension, getExtensions, getNoOfExtensions, getParent, getValueForExtension, getValuesForExtension, hasExtension, initialise, isInitialised, isPopulated, isUsed, removeExtension, setInitialised, setParent, setPopulated, setUsed, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

protected final java.lang.String name
Name under which this table generator is known.


tableName

protected java.lang.String tableName
Name of the table to use for sequences


catalogName

protected java.lang.String catalogName
Name of the catalog to use for the table


schemaName

protected java.lang.String schemaName
Name of the schema to use for the table


pkColumnName

protected java.lang.String pkColumnName
Name of the primary-key column name


valueColumnName

protected java.lang.String valueColumnName
Name of the value column name


pkColumnValue

protected java.lang.String pkColumnValue
Name of the primary-key column value


initialValue

protected long initialValue
Initial value in the table.


allocationSize

protected long allocationSize
Allocation size for ids from the table.

Constructor Detail

TableGeneratorMetaData

public TableGeneratorMetaData(MetaData parent,
                              java.lang.String name,
                              java.lang.String tableName,
                              java.lang.String catalogName,
                              java.lang.String schemaName,
                              java.lang.String pkColumnName,
                              java.lang.String valueColumnName,
                              java.lang.String pkColumnValue,
                              java.lang.String initialValue,
                              java.lang.String allocationSize)
Constructor.

Parameters:
parent - The parent of this element
name - The generator name
tableName - The table name
catalogName - Catalog name for the table
schemaName - Schema name for the table
pkColumnName - Name of PK column in table
valueColumnName - Name of value column in table
pkColumnValue - Value of the pk in the table
initialValue - Initial value
allocationSize - Allocation size
Method Detail

getFullyQualifiedName

public java.lang.String getFullyQualifiedName()
Convenience accessor for the fully-qualified name of the sequence.

Returns:
Fully qualfiied name of the sequence (including the package name).

getName

public java.lang.String getName()
Accessor for the generator name.

Returns:
generator name

getTableName

public java.lang.String getTableName()
Accessor for the table name.

Returns:
table name

getCatalogName

public java.lang.String getCatalogName()
Accessor for the catalog name.

Returns:
catalog name

getSchemaName

public java.lang.String getSchemaName()
Accessor for the schema name.

Returns:
schema name

getPKColumnName

public java.lang.String getPKColumnName()
Accessor for the PK column name.

Returns:
PK column name

getValueColumnName

public java.lang.String getValueColumnName()
Accessor for the value column name.

Returns:
Value column name

getPKColumnValue

public java.lang.String getPKColumnValue()
Accessor for the PK column value.

Returns:
PK column value

getInitialValue

public long getInitialValue()
Accessor for the initial value of the sequence.

Returns:
The initial value

getAllocationSize

public long getAllocationSize()
Accessor for the allocation size of the sequence.

Returns:
The allocation size

toString

public java.lang.String toString(java.lang.String prefix,
                                 java.lang.String indent)
Returns a string representation of the object.

Overrides:
toString in class MetaData
Parameters:
prefix - prefix string
indent - indent string
Returns:
a string representation of the object.


Copyright © 2009. All Rights Reserved.