Skip navigation links
org.eclipse.persistence.tools.schemaframework
Class UnaryTableSequenceDefinition
java.lang.Object
org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition
org.eclipse.persistence.tools.schemaframework.SequenceDefinition
org.eclipse.persistence.tools.schemaframework.UnaryTableSequenceDefinition
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable
-
public class UnaryTableSequenceDefinition
- extends SequenceDefinition
Purpose: Creates / drops an unary sequence table: the name of the table is sequence name; its only field is named unarySequenceCounterFieldName
- See Also:
- Serialized Form
Constructor Summary |
UnaryTableSequenceDefinition(Sequence sequence)
INTERNAL: Should be a sequence defining unary table sequence in the db: either UnaryTableSequence DefaultSequence (only if case platform.getDefaultSequence() is an UnaryTableSequence). |
Method Summary |
java.io.Writer |
buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, java.io.Writer writer)
INTERNAL: Return the SQL required to create the unary sequence table. |
java.io.Writer |
buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, java.io.Writer writer)
INTERNAL: Return the SQL to delete the unary sequence table. |
TableDefinition |
buildTableDefinition()
INTERNAL: Return a TableDefinition specifying a unary sequence table. |
boolean |
checkIfExist(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERAL: Verify whether the sequence exists. |
java.lang.String |
getSequenceCounterFieldName()
PUBLIC: Return the name of the only field of this table |
protected UnaryTableSequence |
getUnaryTableSequence()
|
Methods inherited from class org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition |
buildVPDCreationFunctionWriter, buildVPDCreationPolicyWriter, buildVPDDeletionWriter, clone, createObject, dropFromDatabase, dropObject, getFullName, getName, getQualifier, postCreateObject, preDropObject, setName, setQualifier, shouldCreateVPDCalls, toString |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
UnaryTableSequenceDefinition
public UnaryTableSequenceDefinition(Sequence sequence)
- INTERNAL: Should be a sequence defining unary table sequence in the db: either UnaryTableSequence DefaultSequence (only if case platform.getDefaultSequence() is an UnaryTableSequence).
buildCreationWriter
public java.io.Writer buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session,
java.io.Writer writer)
throws ValidationException
- INTERNAL: Return the SQL required to create the unary sequence table.
-
- Specified by:
buildCreationWriter
in class DatabaseObjectDefinition
-
- Throws:
ValidationException
buildDeletionWriter
public java.io.Writer buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session,
java.io.Writer writer)
throws ValidationException
- INTERNAL: Return the SQL to delete the unary sequence table.
-
- Specified by:
buildDeletionWriter
in class DatabaseObjectDefinition
-
- Throws:
ValidationException
checkIfExist
public boolean checkIfExist(org.eclipse.persistence.internal.sessions.AbstractSession session)
throws DatabaseException
- INTERAL: Verify whether the sequence exists. Assume that the unary sequence table exists.
-
- Specified by:
checkIfExist
in class SequenceDefinition
-
- Throws:
DatabaseException
getSequenceCounterFieldName
public java.lang.String getSequenceCounterFieldName()
- PUBLIC: Return the name of the only field of this table
buildTableDefinition
public TableDefinition buildTableDefinition()
- INTERNAL: Return a TableDefinition specifying a unary sequence table.
-
- Overrides:
buildTableDefinition
in class SequenceDefinition
getUnaryTableSequence
protected UnaryTableSequence getUnaryTableSequence()
Skip navigation links