org.apache.derby.impl.sql.catalog
Class SYSALIASESRowFactory

java.lang.Object
  extended by org.apache.derby.iapi.sql.dictionary.CatalogRowFactory
      extended by org.apache.derby.impl.sql.catalog.SYSALIASESRowFactory

 class SYSALIASESRowFactory
extends CatalogRowFactory

Factory for creating a SYSALIASES row. Here are the directions for adding a new system supplied alias. Misc: All system supplied aliases are class aliases at this point. Additional arrays will need to be added if we supply system aliases of other types. The preloadAliasIDs array is an array of hard coded UUIDs for the system supplied aliases. The preloadAliases array is the array of aliases for the system supplied aliases. This array is in alphabetical order by package and class in Xena. Each alias is the uppercase class name of the alias. The preloadJavaClassNames array is the array of full package.class names for the system supplied aliases. This array is in alphabetical order by package and class in Xena. SYSALIASES_NUM_BOOT_ROWS is the number of boot rows in sys.sysaliases in a new database.


Field Summary
private static int[][] indexColumnPositions
           
private static int SYSALIASES_ALIAS
           
private static int SYSALIASES_ALIASID
           
static int SYSALIASES_ALIASINFO
           
private static int SYSALIASES_ALIASTYPE
           
private static int SYSALIASES_COLUMN_COUNT
           
protected static int SYSALIASES_INDEX1_ID
           
protected static int SYSALIASES_INDEX2_ID
           
protected static int SYSALIASES_INDEX3_ID
           
private static int SYSALIASES_JAVACLASSNAME
           
private static int SYSALIASES_NAMESPACE
           
private static int SYSALIASES_SCHEMAID
           
private static int SYSALIASES_SPECIFIC_NAME
           
private static int SYSALIASES_SYSTEMALIAS
           
private static boolean[] uniqueness
           
private static java.lang.String[] uuids
           
 
Fields inherited from class org.apache.derby.iapi.sql.dictionary.CatalogRowFactory
dvf, heapUUID, indexNames, indexUniqueness, indexUUID, tableUUID
 
Constructor Summary
SYSALIASESRowFactory(UUIDFactory uuidf, ExecutionFactory ef, DataValueFactory dvf)
           
 
Method Summary
 SystemColumn[] buildColumnList()
          Builds a list of columns suitable for creating this Catalog.
 TupleDescriptor buildDescriptor(ExecRow row, TupleDescriptor parentTupleDescriptor, DataDictionary dd)
          Make a AliasDescriptor out of a SYSALIASES row
 ExecRow makeRow(TupleDescriptor td, TupleDescriptor parent)
          Make a SYSALIASES row
 
Methods inherited from class org.apache.derby.iapi.sql.dictionary.CatalogRowFactory
generateIndexName, getCanonicalHeapName, getCanonicalHeapUUID, getCanonicalIndexUUID, getCanonicalTableUUID, getCatalogName, getCreateHeapProperties, getCreateIndexProperties, getDataValueFactory, getExecutionFactory, getHeapColumnCount, getIndexColumnCount, getIndexColumnPositions, getIndexName, getNumIndexes, getPrimaryKeyIndexNumber, getUUIDFactory, initInfo, isIndexUnique, makeEmptyRow
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SYSALIASES_COLUMN_COUNT

private static final int SYSALIASES_COLUMN_COUNT
See Also:
Constant Field Values

SYSALIASES_ALIASID

private static final int SYSALIASES_ALIASID
See Also:
Constant Field Values

SYSALIASES_ALIAS

private static final int SYSALIASES_ALIAS
See Also:
Constant Field Values

SYSALIASES_SCHEMAID

private static final int SYSALIASES_SCHEMAID
See Also:
Constant Field Values

SYSALIASES_JAVACLASSNAME

private static final int SYSALIASES_JAVACLASSNAME
See Also:
Constant Field Values

SYSALIASES_ALIASTYPE

private static final int SYSALIASES_ALIASTYPE
See Also:
Constant Field Values

SYSALIASES_NAMESPACE

private static final int SYSALIASES_NAMESPACE
See Also:
Constant Field Values

SYSALIASES_SYSTEMALIAS

private static final int SYSALIASES_SYSTEMALIAS
See Also:
Constant Field Values

SYSALIASES_ALIASINFO

public static final int SYSALIASES_ALIASINFO
See Also:
Constant Field Values

SYSALIASES_SPECIFIC_NAME

private static final int SYSALIASES_SPECIFIC_NAME
See Also:
Constant Field Values

SYSALIASES_INDEX1_ID

protected static final int SYSALIASES_INDEX1_ID
See Also:
Constant Field Values

SYSALIASES_INDEX2_ID

protected static final int SYSALIASES_INDEX2_ID
See Also:
Constant Field Values

SYSALIASES_INDEX3_ID

protected static final int SYSALIASES_INDEX3_ID
See Also:
Constant Field Values

uniqueness

private static final boolean[] uniqueness

indexColumnPositions

private static int[][] indexColumnPositions

uuids

private static final java.lang.String[] uuids
Constructor Detail

SYSALIASESRowFactory

SYSALIASESRowFactory(UUIDFactory uuidf,
                     ExecutionFactory ef,
                     DataValueFactory dvf)
Method Detail

makeRow

public ExecRow makeRow(TupleDescriptor td,
                       TupleDescriptor parent)
                throws StandardException
Make a SYSALIASES row

Overrides:
makeRow in class CatalogRowFactory
Returns:
Row suitable for inserting into SYSALIASES.
Throws:
StandardException - thrown on failure

buildDescriptor

public TupleDescriptor buildDescriptor(ExecRow row,
                                       TupleDescriptor parentTupleDescriptor,
                                       DataDictionary dd)
                                throws StandardException
Make a AliasDescriptor out of a SYSALIASES row

Specified by:
buildDescriptor in class CatalogRowFactory
Parameters:
row - a SYSALIASES row
parentTupleDescriptor - Null for this kind of descriptor.
dd - dataDictionary
Throws:
StandardException - thrown on failure

buildColumnList

public SystemColumn[] buildColumnList()
                               throws StandardException
Builds a list of columns suitable for creating this Catalog. DERBY-1734 fixed an issue where older code created the BOOLEAN column SYSTEMALIAS with maximum length 0 instead of 1. DERBY-1742 was opened to track if upgrade changes are needed.

Specified by:
buildColumnList in class CatalogRowFactory
Returns:
array of SystemColumn suitable for making this catalog.
Throws:
StandardException

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.