Interface CassandraIndexFunctions
-
public interface CassandraIndexFunctions
-
-
Field Summary
Fields Modifier and Type Field Description static CassandraIndexFunctions
CLUSTERING_COLUMN_INDEX_FUNCTIONS
static CassandraIndexFunctions
COLLECTION_ENTRY_INDEX_FUNCTIONS
static CassandraIndexFunctions
COLLECTION_KEY_INDEX_FUNCTIONS
static CassandraIndexFunctions
COLLECTION_VALUE_INDEX_FUNCTIONS
static CassandraIndexFunctions
KEYS_INDEX_FUNCTIONS
static CassandraIndexFunctions
PARTITION_KEY_INDEX_FUNCTIONS
static CassandraIndexFunctions
REGULAR_COLUMN_INDEX_FUNCTIONS
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default TableMetadata.Builder
addIndexClusteringColumns(TableMetadata.Builder builder, TableMetadata baseMetadata, ColumnMetadata cfDef)
Add the clustering columns for a specific type of index table to the a TableMetadata.Builder (which is being used to construct the index table's TableMetadata.default AbstractType<?>
getIndexedPartitionKeyType(ColumnMetadata indexedColumn)
default AbstractType<?>
getIndexedValueType(ColumnMetadata indexedColumn)
Returns the type of the the values in the index.CassandraIndex
newIndexInstance(ColumnFamilyStore baseCfs, IndexMetadata indexMetadata)
-
-
-
Field Detail
-
KEYS_INDEX_FUNCTIONS
static final CassandraIndexFunctions KEYS_INDEX_FUNCTIONS
-
REGULAR_COLUMN_INDEX_FUNCTIONS
static final CassandraIndexFunctions REGULAR_COLUMN_INDEX_FUNCTIONS
-
CLUSTERING_COLUMN_INDEX_FUNCTIONS
static final CassandraIndexFunctions CLUSTERING_COLUMN_INDEX_FUNCTIONS
-
COLLECTION_KEY_INDEX_FUNCTIONS
static final CassandraIndexFunctions COLLECTION_KEY_INDEX_FUNCTIONS
-
PARTITION_KEY_INDEX_FUNCTIONS
static final CassandraIndexFunctions PARTITION_KEY_INDEX_FUNCTIONS
-
COLLECTION_VALUE_INDEX_FUNCTIONS
static final CassandraIndexFunctions COLLECTION_VALUE_INDEX_FUNCTIONS
-
COLLECTION_ENTRY_INDEX_FUNCTIONS
static final CassandraIndexFunctions COLLECTION_ENTRY_INDEX_FUNCTIONS
-
-
Method Detail
-
newIndexInstance
CassandraIndex newIndexInstance(ColumnFamilyStore baseCfs, IndexMetadata indexMetadata)
- Parameters:
baseCfs
-indexMetadata
-- Returns:
-
getIndexedValueType
default AbstractType<?> getIndexedValueType(ColumnMetadata indexedColumn)
Returns the type of the the values in the index. For most columns this is simply its type, but for collections it depends on whether the index is on the collection name/value element or on a frozen collection- Parameters:
indexedColumn
-- Returns:
-
getIndexedPartitionKeyType
default AbstractType<?> getIndexedPartitionKeyType(ColumnMetadata indexedColumn)
-
addIndexClusteringColumns
default TableMetadata.Builder addIndexClusteringColumns(TableMetadata.Builder builder, TableMetadata baseMetadata, ColumnMetadata cfDef)
Add the clustering columns for a specific type of index table to the a TableMetadata.Builder (which is being used to construct the index table's TableMetadata. In the default implementation, the clustering columns of the index table hold the partition key and clustering columns of the base table. This is overridden in several cases: * When the indexed value is itself a clustering column, in which case, we only need store the base table's *other* clustering values in the index - the indexed value being the index table's partition key * When the indexed value is a collection value, in which case we also need to capture the cell path from the base table * In a KEYS index (for compact storage/static column indexes), where only the base partition key is held in the index table. Called from indexCfsMetadata- Parameters:
builder
-baseMetadata
-cfDef
-- Returns:
-
-