Package org.apache.openjpa.jdbc.meta
Class SequenceMapping
- java.lang.Object
-
- org.apache.openjpa.meta.SequenceMetaData
-
- org.apache.openjpa.jdbc.meta.SequenceMapping
-
- All Implemented Interfaces:
java.io.Serializable
,SourceTracker
,Closeable
,Commentable
,MetaDataContext
public class SequenceMapping extends SequenceMetaData
Specialization of sequence metadata for ORM.- Author:
- Abe White
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.openjpa.meta.SequenceMetaData
SequenceMetaData.SequenceFactory
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
IMPL_CLASS_TABLE
ClassTableJDBCSeq
alias.static java.lang.String
IMPL_TABLE
TableJDBCSeq
alias.static java.lang.String
IMPL_VALUE_TABLE
ValueTableJDBCSeq
alias.-
Fields inherited from class org.apache.openjpa.meta.SequenceMetaData
IMPL_NATIVE, IMPL_TIME, NAME_SYSTEM
-
Fields inherited from interface org.apache.openjpa.lib.xml.Commentable
EMPTY_COMMENTS
-
Fields inherited from interface org.apache.openjpa.lib.meta.SourceTracker
SRC_ANNOTATIONS, SRC_OTHER, SRC_XML
-
-
Constructor Summary
Constructors Constructor Description SequenceMapping(java.lang.String name, MappingRepository repos)
Deprecated.SequenceMapping(DBIdentifier name, MappingRepository repos)
Sequence names are a kernel object so DBIdentifiers must be converted to strings
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected void
addStandardProperties(java.lang.StringBuilder props)
Add standard properties to the given properties buffer.java.io.File
getMappingFile()
Allow sequence to have a mapping file separate from its metadata source file.java.lang.String
getPrimaryKeyColumn()
Deprecated.DBIdentifier
getPrimaryKeyColumnIdentifier()
java.lang.String
getPrimaryKeyValue()
Primary key value, if not auto-determined.java.lang.String
getSequenceColumn()
Deprecated.DBIdentifier
getSequenceColumnIdentifier()
java.lang.String
getTable()
Deprecated.DBIdentifier
getTableIdentifier()
java.lang.String[]
getUniqueColumns()
Deprecated.DBIdentifier[]
getUniqueColumnsIdentifier()
DBIdentifier
getUniqueConstraintIdentifier()
java.lang.String
getUniqueConstraintName()
Deprecated.protected PluginValue
newPluginValue(java.lang.String property)
Create a new plugin value for sequences.void
setMappingFile(java.io.File file)
Allow sequence to have a mapping file separate from its metadata source file.void
setPrimaryKeyColumn(java.lang.String primaryKeyColumn)
Deprecated.void
setPrimaryKeyColumnIdentifier(DBIdentifier primaryKeyColumn)
void
setPrimaryKeyValue(java.lang.String primaryKeyValue)
Primary key value, if not auto-determined.void
setSequenceColumn(java.lang.String sequenceColumn)
Deprecated.void
setSequenceColumnIdentifier(DBIdentifier sequenceColumn)
void
setTable(java.lang.String table)
Deprecated.void
setTableIdentifier(DBIdentifier table)
void
setUniqueColumns(java.lang.String[] cols)
Deprecated.void
setUniqueColumnsIdentifier(DBIdentifier[] cols)
void
setUniqueConstraintIdentifier(DBIdentifier name)
void
setUniqueConstraintName(java.lang.String name)
Deprecated.-
Methods inherited from class org.apache.openjpa.meta.SequenceMetaData
appendProperty, appendProperty, close, getAllocate, getCatalog, getColNumber, getComments, getIncrement, getInitialValue, getInstance, getLineNumber, getName, getRepository, getResourceName, getSchema, getSequence, getSequenceFactory, getSequencePlugin, getSourceFile, getSourceScope, getSourceType, getType, instantiate, setAllocate, setCatalog, setColNumber, setComments, setIncrement, setInitialValue, setLineNumber, setSchema, setSequence, setSequenceFactory, setSequencePlugin, setSource, setType, toString, wrapValue
-
-
-
-
Field Detail
-
IMPL_VALUE_TABLE
public static final java.lang.String IMPL_VALUE_TABLE
ValueTableJDBCSeq
alias.- See Also:
- Constant Field Values
-
IMPL_TABLE
public static final java.lang.String IMPL_TABLE
TableJDBCSeq
alias.- See Also:
- Constant Field Values
-
IMPL_CLASS_TABLE
public static final java.lang.String IMPL_CLASS_TABLE
ClassTableJDBCSeq
alias.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SequenceMapping
@Deprecated public SequenceMapping(java.lang.String name, MappingRepository repos)
Deprecated.- Parameters:
name
-repos
-
-
SequenceMapping
public SequenceMapping(DBIdentifier name, MappingRepository repos)
Sequence names are a kernel object so DBIdentifiers must be converted to strings- Parameters:
name
-repos
-
-
-
Method Detail
-
getMappingFile
public java.io.File getMappingFile()
Allow sequence to have a mapping file separate from its metadata source file.
-
setMappingFile
public void setMappingFile(java.io.File file)
Allow sequence to have a mapping file separate from its metadata source file.
-
getTable
@Deprecated public java.lang.String getTable()
Deprecated.Name of sequence table, if any.
-
getTableIdentifier
public DBIdentifier getTableIdentifier()
-
setTable
@Deprecated public void setTable(java.lang.String table)
Deprecated.Name of sequence table, if any.
-
setTableIdentifier
public void setTableIdentifier(DBIdentifier table)
-
getSequenceColumn
@Deprecated public java.lang.String getSequenceColumn()
Deprecated.Name of sequence column, if any.
-
getSequenceColumnIdentifier
public DBIdentifier getSequenceColumnIdentifier()
-
setSequenceColumn
@Deprecated public void setSequenceColumn(java.lang.String sequenceColumn)
Deprecated.Name of sequence column, if any.
-
setSequenceColumnIdentifier
public void setSequenceColumnIdentifier(DBIdentifier sequenceColumn)
-
getPrimaryKeyColumn
@Deprecated public java.lang.String getPrimaryKeyColumn()
Deprecated.Name of primary key column, if any.
-
getPrimaryKeyColumnIdentifier
public DBIdentifier getPrimaryKeyColumnIdentifier()
-
setPrimaryKeyColumn
@Deprecated public void setPrimaryKeyColumn(java.lang.String primaryKeyColumn)
Deprecated.Name of primary key column, if any.
-
setPrimaryKeyColumnIdentifier
public void setPrimaryKeyColumnIdentifier(DBIdentifier primaryKeyColumn)
-
getPrimaryKeyValue
public java.lang.String getPrimaryKeyValue()
Primary key value, if not auto-determined.
-
setPrimaryKeyValue
public void setPrimaryKeyValue(java.lang.String primaryKeyValue)
Primary key value, if not auto-determined.
-
setUniqueColumns
@Deprecated public void setUniqueColumns(java.lang.String[] cols)
Deprecated.- Parameters:
cols
-
-
setUniqueColumnsIdentifier
public void setUniqueColumnsIdentifier(DBIdentifier[] cols)
-
getUniqueColumns
@Deprecated public java.lang.String[] getUniqueColumns()
Deprecated.
-
getUniqueColumnsIdentifier
public DBIdentifier[] getUniqueColumnsIdentifier()
-
newPluginValue
protected PluginValue newPluginValue(java.lang.String property)
Description copied from class:SequenceMetaData
Create a new plugin value for sequences. Returns a standardSeqValue
by default.- Overrides:
newPluginValue
in classSequenceMetaData
-
addStandardProperties
protected void addStandardProperties(java.lang.StringBuilder props)
Description copied from class:SequenceMetaData
Add standard properties to the given properties buffer.- Overrides:
addStandardProperties
in classSequenceMetaData
-
setUniqueConstraintName
@Deprecated public void setUniqueConstraintName(java.lang.String name)
Deprecated.- Parameters:
name
-
-
setUniqueConstraintIdentifier
public void setUniqueConstraintIdentifier(DBIdentifier name)
-
getUniqueConstraintName
@Deprecated public java.lang.String getUniqueConstraintName()
Deprecated.
-
getUniqueConstraintIdentifier
public DBIdentifier getUniqueConstraintIdentifier()
-
-