Class IndexDefinition
- java.lang.Object
-
- org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition
-
- org.eclipse.persistence.tools.schemaframework.IndexDefinition
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
public class IndexDefinition extends DatabaseObjectDefinition
Purpose: Allow for indexes to be created.
- See Also:
- Serialized Form
- Author:
- James Sutherland
- Since:
- EclipseLink 2.2
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<java.lang.String>
fields
protected boolean
isUnique
protected java.lang.String
targetTable
-
Fields inherited from class org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition
name, qualifier
-
-
Constructor Summary
Constructors Constructor Description IndexDefinition()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addField(java.lang.String fieldName)
PUBLIC: Add the field to the index.java.io.Writer
buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, java.io.Writer writer)
INTERNAL: Return the create type statement.java.io.Writer
buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, java.io.Writer writer)
INTERNAL: Return the drop type statement.java.util.List<java.lang.String>
getFields()
java.lang.String
getTargetTable()
boolean
isUnique()
void
setFields(java.util.List<java.lang.String> fields)
void
setIsUnique(boolean isUnique)
void
setTargetTable(java.lang.String targetTable)
PUBLIC: set qualified table name.-
Methods inherited from class org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition
buildVPDCreationFunctionWriter, buildVPDCreationPolicyWriter, buildVPDDeletionWriter, clone, createDatabaseSchema, createDatabaseSchemaOnDatabase, createObject, createOnDatabase, dropDatabaseSchema, dropDatabaseSchemaOnDatabase, dropFromDatabase, dropObject, getDatabaseSchema, getFieldTypeDefinition, getFieldTypeDefinition, getFullName, getName, getQualifier, hasDatabaseSchema, postCreateObject, preDropObject, setName, setQualifier, shouldCreateDatabaseSchema, shouldCreateVPDCalls, toString
-
-
-
-
Method Detail
-
isUnique
public boolean isUnique()
-
setIsUnique
public void setIsUnique(boolean isUnique)
-
getTargetTable
public java.lang.String getTargetTable()
-
setTargetTable
public void setTargetTable(java.lang.String targetTable)
PUBLIC: set qualified table name.
-
addField
public void addField(java.lang.String fieldName)
PUBLIC: Add the field to the index.
-
buildCreationWriter
public java.io.Writer buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, java.io.Writer writer) throws ValidationException
INTERNAL: Return the create type statement.- Specified by:
buildCreationWriter
in classDatabaseObjectDefinition
- Throws:
ValidationException
-
buildDeletionWriter
public java.io.Writer buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, java.io.Writer writer) throws ValidationException
INTERNAL: Return the drop type statement.- Specified by:
buildDeletionWriter
in classDatabaseObjectDefinition
- Throws:
ValidationException
-
getFields
public java.util.List<java.lang.String> getFields()
-
setFields
public void setFields(java.util.List<java.lang.String> fields)
-
-