Class SYSCOLPERMSRowFactory
- java.lang.Object
-
- org.apache.derby.iapi.sql.dictionary.CatalogRowFactory
-
- org.apache.derby.impl.sql.catalog.PermissionsCatalogRowFactory
-
- org.apache.derby.impl.sql.catalog.SYSCOLPERMSRowFactory
-
class SYSCOLPERMSRowFactory extends PermissionsCatalogRowFactory
Factory for creating a SYSCOLPERMS row.
-
-
Field Summary
Fields Modifier and Type Field Description private static int
COLPERMSID_COL_NUM
(package private) static int
COLPERMSID_INDEX_NUM
private static int
COLUMN_COUNT
protected static int
COLUMNS_COL_NUM
private static int
GRANTEE_COL_NUM
static int
GRANTEE_COL_NUM_IN_GRANTEE_TABLE_TYPE_GRANTOR_INDEX
(package private) static int
GRANTEE_TABLE_TYPE_GRANTOR_INDEX_NUM
private static int
GRANTOR_COL_NUM
private static int[][]
indexColumnPositions
private static boolean[]
indexUniqueness
private static int
TABLEID_COL_NUM
(package private) static int
TABLEID_INDEX_NUM
(package private) static java.lang.String
TABLENAME_STRING
protected static int
TOTAL_NUM_OF_INDEXES
private static int
TYPE_COL_NUM
private static java.lang.String[]
uuids
-
Fields inherited from class org.apache.derby.iapi.sql.dictionary.CatalogRowFactory
dvf, heapUUID, indexNames, indexUUID, tableUUID
-
-
Constructor Summary
Constructors Constructor Description SYSCOLPERMSRowFactory(UUIDFactory uuidf, ExecutionFactory ef, DataValueFactory dvf)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SystemColumn[]
buildColumnList()
builds a column list for the catalogTupleDescriptor
buildDescriptor(ExecRow row, TupleDescriptor parentTuple, DataDictionary dataDictionary)
builds a tuple descriptor from a rowExecIndexRow
buildIndexKeyRow(int indexNumber, PermissionsDescriptor perm)
builds an index key row for a given index number.int
getPrimaryKeyIndexNumber()
Get the index number for the primary key index on this catalog.ExecRow
makeRow(TupleDescriptor td, TupleDescriptor parent)
most subclasses should provide this method.int
orPermissions(ExecRow row, PermissionsDescriptor perm, boolean[] colsChanged)
Or a set of permissions in with a row from this catalog tableint
removePermissions(ExecRow row, PermissionsDescriptor perm, boolean[] colsChanged)
Remove a set of permissions from a row from this catalog tablevoid
setUUIDOfThePassedDescriptor(ExecRow row, PermissionsDescriptor perm)
Set the uuid of the passed permission descriptor to the uuid of the row from the system table.-
Methods inherited from class org.apache.derby.impl.sql.catalog.PermissionsCatalogRowFactory
getAuthorizationID, getAuthorizationID, getNullAuthorizationID
-
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, getUUIDFactory, initInfo, isIndexUnique, makeEmptyRow, makeEmptyRowForCurrentVersion
-
-
-
-
Field Detail
-
TABLENAME_STRING
static final java.lang.String TABLENAME_STRING
- See Also:
- Constant Field Values
-
COLPERMSID_COL_NUM
private static final int COLPERMSID_COL_NUM
- See Also:
- Constant Field Values
-
GRANTEE_COL_NUM
private static final int GRANTEE_COL_NUM
- See Also:
- Constant Field Values
-
GRANTOR_COL_NUM
private static final int GRANTOR_COL_NUM
- See Also:
- Constant Field Values
-
TABLEID_COL_NUM
private static final int TABLEID_COL_NUM
- See Also:
- Constant Field Values
-
TYPE_COL_NUM
private static final int TYPE_COL_NUM
- See Also:
- Constant Field Values
-
COLUMNS_COL_NUM
protected static final int COLUMNS_COL_NUM
- See Also:
- Constant Field Values
-
COLUMN_COUNT
private static final int COLUMN_COUNT
- See Also:
- Constant Field Values
-
GRANTEE_TABLE_TYPE_GRANTOR_INDEX_NUM
static final int GRANTEE_TABLE_TYPE_GRANTOR_INDEX_NUM
- See Also:
- Constant Field Values
-
COLPERMSID_INDEX_NUM
static final int COLPERMSID_INDEX_NUM
- See Also:
- Constant Field Values
-
TABLEID_INDEX_NUM
static final int TABLEID_INDEX_NUM
- See Also:
- Constant Field Values
-
TOTAL_NUM_OF_INDEXES
protected static final int TOTAL_NUM_OF_INDEXES
- See Also:
- Constant Field Values
-
indexColumnPositions
private static final int[][] indexColumnPositions
-
GRANTEE_COL_NUM_IN_GRANTEE_TABLE_TYPE_GRANTOR_INDEX
public static final int GRANTEE_COL_NUM_IN_GRANTEE_TABLE_TYPE_GRANTOR_INDEX
- See Also:
- Constant Field Values
-
indexUniqueness
private static final boolean[] indexUniqueness
-
uuids
private static final java.lang.String[] uuids
-
-
Constructor Detail
-
SYSCOLPERMSRowFactory
SYSCOLPERMSRowFactory(UUIDFactory uuidf, ExecutionFactory ef, DataValueFactory dvf)
-
-
Method Detail
-
makeRow
public ExecRow makeRow(TupleDescriptor td, TupleDescriptor parent) throws StandardException
Description copied from class:CatalogRowFactory
most subclasses should provide this method. One or two oddball cases in Replication and SysSTATEMENTSRowFactory don't. For those we call makeRow with the additional arguments.- Overrides:
makeRow
in classCatalogRowFactory
- Throws:
StandardException
-
buildDescriptor
public TupleDescriptor buildDescriptor(ExecRow row, TupleDescriptor parentTuple, DataDictionary dataDictionary) throws StandardException
builds a tuple descriptor from a row- Specified by:
buildDescriptor
in classCatalogRowFactory
- Throws:
StandardException
-
buildColumnList
public SystemColumn[] buildColumnList() throws StandardException
builds a column list for the catalog- Specified by:
buildColumnList
in classCatalogRowFactory
- Throws:
StandardException
-
buildIndexKeyRow
public ExecIndexRow buildIndexKeyRow(int indexNumber, PermissionsDescriptor perm) throws StandardException
builds an index key row for a given index number.- Specified by:
buildIndexKeyRow
in classPermissionsCatalogRowFactory
perm
- a permission descriptor of the appropriate class for this PermissionsCatalogRowFactory class.- Throws:
StandardException
- standard error policy
-
getPrimaryKeyIndexNumber
public int getPrimaryKeyIndexNumber()
Description copied from class:CatalogRowFactory
Get the index number for the primary key index on this catalog.- Overrides:
getPrimaryKeyIndexNumber
in classCatalogRowFactory
- Returns:
- a 0-based number
-
orPermissions
public int orPermissions(ExecRow row, PermissionsDescriptor perm, boolean[] colsChanged) throws StandardException
Or a set of permissions in with a row from this catalog table- Specified by:
orPermissions
in classPermissionsCatalogRowFactory
- Parameters:
row
- an existing rowperm
- a permission descriptor of the appropriate class for this PermissionsCatalogRowFactory class.colsChanged
- An array with one element for each column in row. It is updated to indicate which columns in row were changed- Returns:
- The number of columns that were changed.
- Throws:
StandardException
- standard error policy
-
removePermissions
public int removePermissions(ExecRow row, PermissionsDescriptor perm, boolean[] colsChanged) throws StandardException
Remove a set of permissions from a row from this catalog table- Specified by:
removePermissions
in classPermissionsCatalogRowFactory
- Parameters:
row
- an existing rowperm
- a permission descriptor of the appropriate class for this PermissionsCatalogRowFactory class.colsChanged
- An array with one element for each column in row. It is updated to indicate which columns in row were changed- Returns:
- -1 if there are no permissions left in the row, otherwise the number of columns that were changed.
- Throws:
StandardException
- standard error policy
-
setUUIDOfThePassedDescriptor
public void setUUIDOfThePassedDescriptor(ExecRow row, PermissionsDescriptor perm) throws StandardException
Description copied from class:PermissionsCatalogRowFactory
Set the uuid of the passed permission descriptor to the uuid of the row from the system table. DataDictionary will make this call before calling the dependency manager to send invalidation messages to the objects dependent on the permission descriptor's uuid.- Specified by:
setUUIDOfThePassedDescriptor
in classPermissionsCatalogRowFactory
- Parameters:
row
- The row from the system table for the passed permission descriptorperm
- Permission descriptor- Throws:
StandardException
- See Also:
PermissionsCatalogRowFactory.setUUIDOfThePassedDescriptor(org.apache.derby.iapi.sql.execute.ExecRow, org.apache.derby.iapi.sql.dictionary.PermissionsDescriptor)
-
-