Package org.apache.ignite.table
Interface Table
public interface Table
Table provides different views (key-value vs record) and approaches (mapped-object vs binary) to access the data.
Binary table views might be useful in the various scenarios, including when the user key-value classes are not in classpath and/or when deserialization of the entire table record is undesirable for performance reasons.
Key-value views project table rows into key-value pairs, where all key columns are mapped to the key object, and the rest of the columns are mapped to the value object. Record and key-value views provide identical functionality, the projection is performed on the client side.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionGets a key-value view of the table.default <K,
V> KeyValueView<K, V> keyValueView
(Class<K> keyCls, Class<V> valCls) Gets a key-value view of the table using the default mapper for the specified key and value classes.<K,
V> KeyValueView<K, V> keyValueView
(Mapper<K> keyMapper, Mapper<V> valMapper) Gets a key-value view of the table using the specified key-value class mappers.default String
name()
Gets the canonical name of the table ([schema_name].[table_name]) with SQL-parser style quotation.Gets the partition manager.Gets the qualified name of the table.Gets a record view of the table.default <R> RecordView<R>
recordView
(Class<R> recCls) Gets a record view of the table using the default mapper for the specified record class.<R> RecordView<R>
recordView
(Mapper<R> recMapper) Gets a record view of the table using the specified record class mapper.
-
Method Details
-
name
Gets the canonical name of the table ([schema_name].[table_name]) with SQL-parser style quotation.E.g. "PUBLIC.TBL0" - for TBL0 table in PUBLIC schema (both names are case insensitive), "\"MySchema\".\"Tbl0\"" - for Tbl0 table in MySchema schema (both names are case sensitive), etc.
- Returns:
- Canonical table name.
-
qualifiedName
QualifiedName qualifiedName()Gets the qualified name of the table.- Returns:
- Qualified name of the table.
-
partitionManager
PartitionManager partitionManager()Gets the partition manager.- Returns:
- Partition manager.
-
recordView
Gets a record view of the table using the specified record class mapper.- Type Parameters:
R
- Record type.- Parameters:
recMapper
- Record class mapper.- Returns:
- Table record view.
-
recordView
RecordView<Tuple> recordView()Gets a record view of the table.- Returns:
- Table record view.
-
recordView
Gets a record view of the table using the default mapper for the specified record class.- Type Parameters:
R
- Record type.- Parameters:
recCls
- Record class.- Returns:
- Table record view.
-
keyValueView
Gets a key-value view of the table using the specified key-value class mappers.- Type Parameters:
K
- Key type.V
- Value type.- Parameters:
keyMapper
- Key class mapper.valMapper
- Value class mapper.- Returns:
- Table key-value view.
-
keyValueView
KeyValueView<Tuple,Tuple> keyValueView()Gets a key-value view of the table.- Returns:
- Table key-value view.
-
keyValueView
Gets a key-value view of the table using the default mapper for the specified key and value classes.- Type Parameters:
K
- Key type.V
- Value type.- Parameters:
keyCls
- Key class.valCls
- Value class.- Returns:
- Table key-value view.
-