org.apache.derby.impl.sql.execute
Class ColumnInfo

java.lang.Object
  extended by org.apache.derby.impl.sql.execute.ColumnInfo
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable, Formatable, TypedFormat

public class ColumnInfo
extends java.lang.Object
implements Formatable

This is the Column descriptor that is passed from Compilation to Execution for CREATE TABLE statements.

Version:
0.1
See Also:
Serialized Form

Field Summary
 int action
          This class implements Formatable.
 long autoinc_create_or_modify_Start_Increment
           
 long autoincInc
           
 long autoincStart
           
static int CREATE
           
 DataTypeDescriptor dataType
           
 DefaultInfo defaultInfo
           
 DataValueDescriptor defaultValue
           
static int DROP
           
static int MODIFY_COLUMN_CONSTRAINT
           
static int MODIFY_COLUMN_CONSTRAINT_NOT_NULL
           
static int MODIFY_COLUMN_DEFAULT_INCREMENT
           
static int MODIFY_COLUMN_DEFAULT_RESTART
           
static int MODIFY_COLUMN_DEFAULT_VALUE
           
static int MODIFY_COLUMN_TYPE
           
 java.lang.String name
           
 UUID newDefaultUUID
           
 UUID oldDefaultUUID
           
 ProviderInfo[] providers
           
 
Constructor Summary
ColumnInfo()
          Public niladic constructor.
ColumnInfo(java.lang.String name, DataTypeDescriptor dataType, DataValueDescriptor defaultValue, DefaultInfo defaultInfo, ProviderInfo[] providers, UUID newDefaultUUID, UUID oldDefaultUUID, int action, long autoincStart, long autoincInc, long autoinc_create_or_modify_Start_Increment)
          Make one of these puppies.
 
Method Summary
 int getTypeFormatId()
          Get the formatID which corresponds to this class.
 void readExternal(java.io.ObjectInput in)
          Read this object from a stream of stored objects.
 java.lang.String toString()
           
 void writeExternal(java.io.ObjectOutput out)
          Write this object to a stream of stored objects.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

action

public int action
This class implements Formatable. That means that it can write itself to and from a formatted stream. If you add more fields to this class, make sure that you also write/read them with the writeExternal()/readExternal() methods. If, inbetween releases, you add more fields to this class, then you should bump the version number emitted by the getTypeFormatId() method.


name

public java.lang.String name

dataType

public DataTypeDescriptor dataType

defaultInfo

public DefaultInfo defaultInfo

providers

public ProviderInfo[] providers

defaultValue

public DataValueDescriptor defaultValue

newDefaultUUID

public UUID newDefaultUUID

oldDefaultUUID

public UUID oldDefaultUUID

autoincStart

public long autoincStart

autoincInc

public long autoincInc

autoinc_create_or_modify_Start_Increment

public long autoinc_create_or_modify_Start_Increment

CREATE

public static final int CREATE
See Also:
Constant Field Values

DROP

public static final int DROP
See Also:
Constant Field Values

MODIFY_COLUMN_TYPE

public static final int MODIFY_COLUMN_TYPE
See Also:
Constant Field Values

MODIFY_COLUMN_CONSTRAINT

public static final int MODIFY_COLUMN_CONSTRAINT
See Also:
Constant Field Values

MODIFY_COLUMN_CONSTRAINT_NOT_NULL

public static final int MODIFY_COLUMN_CONSTRAINT_NOT_NULL
See Also:
Constant Field Values

MODIFY_COLUMN_DEFAULT_RESTART

public static final int MODIFY_COLUMN_DEFAULT_RESTART
See Also:
Constant Field Values

MODIFY_COLUMN_DEFAULT_INCREMENT

public static final int MODIFY_COLUMN_DEFAULT_INCREMENT
See Also:
Constant Field Values

MODIFY_COLUMN_DEFAULT_VALUE

public static final int MODIFY_COLUMN_DEFAULT_VALUE
See Also:
Constant Field Values
Constructor Detail

ColumnInfo

public ColumnInfo()
Public niladic constructor. Needed for Formatable interface to work.


ColumnInfo

public ColumnInfo(java.lang.String name,
                  DataTypeDescriptor dataType,
                  DataValueDescriptor defaultValue,
                  DefaultInfo defaultInfo,
                  ProviderInfo[] providers,
                  UUID newDefaultUUID,
                  UUID oldDefaultUUID,
                  int action,
                  long autoincStart,
                  long autoincInc,
                  long autoinc_create_or_modify_Start_Increment)
Make one of these puppies.

Parameters:
name - Column name.
dataType - Column type.
defaultValue - Column default value.
defaultInfo - Column default info.
providers - Array of providers that this column depends on.
newDefaultUUID - New UUID for default.
oldDefaultUUID - Old UUID for default.
action - Action (create, modify default, etc.)
autoincStart - Start of autoincrement values.
autoincInc - Increment of autoincrement values-- if parameter is 0, it implies that this is not an autoincrement value.
Method Detail

readExternal

public void readExternal(java.io.ObjectInput in)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
Read this object from a stream of stored objects.

Specified by:
readExternal in interface java.io.Externalizable
Parameters:
in - read this.
Throws:
java.io.IOException - thrown on error
java.lang.ClassNotFoundException - thrown on error

writeExternal

public void writeExternal(java.io.ObjectOutput out)
                   throws java.io.IOException
Write this object to a stream of stored objects.

Specified by:
writeExternal in interface java.io.Externalizable
Parameters:
out - write bytes here.
Throws:
java.io.IOException - thrown on error

getTypeFormatId

public int getTypeFormatId()
Get the formatID which corresponds to this class.

Specified by:
getTypeFormatId in interface TypedFormat
Returns:
the formatID of this class

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

Built on Thu 2012-03-29 21:53:33+0000, from revision ???

Apache Derby V10.6 Internals - Copyright © 2004,2007 The Apache Software Foundation. All Rights Reserved.