Class TablesMetadataMapper.TableMapper
java.lang.Object
org.apache.drill.metastore.rdbms.transform.AbstractMetadataMapper<TableMetadataUnit,R>
org.apache.drill.metastore.rdbms.components.tables.TablesMetadataMapper<TablesRecord>
org.apache.drill.metastore.rdbms.components.tables.TablesMetadataMapper.TableMapper
- All Implemented Interfaces:
MetadataMapper<TableMetadataUnit,
TablesRecord>
- Enclosing class:
- TablesMetadataMapper<R extends org.jooq.Record>
TablesMetadataMapper
implementation for Tables.TABLES
table.-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.drill.metastore.rdbms.components.tables.TablesMetadataMapper
TablesMetadataMapper.FileMapper, TablesMetadataMapper.PartitionMapper, TablesMetadataMapper.RowGroupMapper, TablesMetadataMapper.SegmentMapper, TablesMetadataMapper.TableMapper
-
Field Summary
Fields inherited from class org.apache.drill.metastore.rdbms.components.tables.TablesMetadataMapper
COMPONENT_PARTITION_KEY, TABLE_PARTITION_KEY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected Map<MetastoreColumn,
org.jooq.Field<?>> protected RdbmsFilterExpressionVisitor
get()
protected Function<TableMetadataUnit,
List<String>> org.jooq.Table<TablesRecord>
table()
protected List<org.jooq.Condition>
toConditions
(List<String> values) Creates JOOQ conditions based on given list of partition values.toRecord
(TableMetadataUnit unit) Converts Metastore component metadata unit into RDBMS table record.toUnit
(org.jooq.Record record) Converts RDBMS table record into Metastore component metadata unit.Methods inherited from class org.apache.drill.metastore.rdbms.components.tables.TablesMetadataMapper
emptyUnit, toDeleteConditions
Methods inherited from class org.apache.drill.metastore.rdbms.transform.AbstractMetadataMapper
toCondition, toFields
-
Constructor Details
-
TableMapper
public TableMapper()
-
-
Method Details
-
get
-
table
- Returns:
- RDBMS table instance
-
toUnit
Description copied from interface:MetadataMapper
Converts RDBMS table record into Metastore component metadata unit.- Parameters:
record
- RDBMS table record- Returns:
- Metastore component metadata unit instance
-
toRecord
Description copied from interface:MetadataMapper
Converts Metastore component metadata unit into RDBMS table record.- Parameters:
unit
- Metastore component metadata unit- Returns:
- RDBMS table record instance
-
fieldMapper
- Specified by:
fieldMapper
in classAbstractMetadataMapper<TableMetadataUnit,
TablesRecord> - Returns:
- mapper specific field mapper
-
filterVisitor
- Specified by:
filterVisitor
in classAbstractMetadataMapper<TableMetadataUnit,
TablesRecord> - Returns:
- mapper specific filter visitor
-
partitionKey
- Specified by:
partitionKey
in classTablesMetadataMapper<TablesRecord>
- Returns:
- function to determine partition key for specific table
-
toConditions
Description copied from class:TablesMetadataMapper
Creates JOOQ conditions based on given list of partition values. Matching is order based.- Specified by:
toConditions
in classTablesMetadataMapper<TablesRecord>
- Parameters:
values
- partition values- Returns:
- list of JOOQ conditions
-