Class VarrayDefinition
java.lang.Object
org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition
org.eclipse.persistence.tools.schemaframework.VarrayDefinition
- All Implemented Interfaces:
Serializable,Cloneable
- Direct Known Subclasses:
ObjectVarrayDefinition
Purpose: Allow for creation of varray type.
- See Also:
-
Field Summary
FieldsFields inherited from class org.eclipse.persistence.tools.schemaframework.DatabaseObjectDefinition
name, qualifier -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidappendTypeString(Writer writer, org.eclipse.persistence.internal.sessions.AbstractSession session) INTERNAL: Append the type.buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, Writer writer) INTERNAL: Return the DDL to create theVARRAY.buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, Writer writer) INTERNAL: Return the DDL to drop the varray.intgetSize()PUBLIC: Return the maximum size of the array.getType()PUBLIC: Return the type of the field.PUBLIC: Return the type of the field.intPUBLIC: Return the size of the element field, this is only required for some field types.voidsetSize(int size) PUBLIC: Set the maximum size of the array.voidPUBLIC: Set the type of the field.voidsetTypeName(String typeName) PUBLIC: Set the type of the field.voidsetTypeSize(int typeSize) PUBLIC: Set the size of the element field, this is only required for some field types.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
-
Field Details
-
typeSize
protected int typeSize -
size
protected int size -
type
-
typeName
-
-
Constructor Details
-
VarrayDefinition
public VarrayDefinition()
-
-
Method Details
-
appendTypeString
public void appendTypeString(Writer writer, org.eclipse.persistence.internal.sessions.AbstractSession session) throws ValidationException INTERNAL: Append the type.- Parameters:
writer- Target writer where to write type string.session- Current session context.- Throws:
ValidationException- When invalid or inconsistent data were found.
-
buildCreationWriter
public Writer buildCreationWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, Writer writer) throws ValidationException INTERNAL: Return the DDL to create theVARRAY.- Specified by:
buildCreationWriterin classDatabaseObjectDefinition- Parameters:
writer- Target writer.session- Current session context.- Returns:
- Target writer with
CREATE TYPE ... AS VARRAY (...) OF ...already written to it. - Throws:
ValidationException- When invalid or inconsistent data were found.
-
buildDeletionWriter
public Writer buildDeletionWriter(org.eclipse.persistence.internal.sessions.AbstractSession session, Writer writer) throws ValidationException INTERNAL: Return the DDL to drop the varray.- Specified by:
buildDeletionWriterin classDatabaseObjectDefinition- Throws:
ValidationException
-
getSize
public int getSize()PUBLIC: Return the maximum size of the array. -
getType
PUBLIC: Return the type of the field. This should be set to a java class, such as String.class, Integer.class or Date.class. -
getTypeName
PUBLIC: Return the type of the field. This is the exact DB type name, which can be used instead of the Java class. -
getTypeSize
public int getTypeSize()PUBLIC: Return the size of the element field, this is only required for some field types. -
setSize
public void setSize(int size) PUBLIC: Set the maximum size of the array. -
setType
PUBLIC: Set the type of the field. This should be set to a java class, such as String.class, Integer.class or Date.class. -
setTypeName
PUBLIC: Set the type of the field. This is the exact DB type name, which can be used instead of the Java class. -
setTypeSize
public void setTypeSize(int typeSize) PUBLIC: Set the size of the element field, this is only required for some field types.
-