T
- The type of the modelled object.public interface MappedTable<T>
MappedDatabase
:
mappedTable = mappedDatabase.table(tableSchema);Modifier and Type | Method and Description |
---|---|
<R> R |
execute(TableOperation<T,?,?,R> operationToPerform)
Executes a command against the database with the context of the primary index of the specific table this object
is linked to.
|
MapperExtension |
getMapperExtension()
Gets the
MapperExtension associated with this mapped resource. |
String |
getTableName()
Gets the physical table name that operations performed by this object will be executed against.
|
TableSchema<T> |
getTableSchema()
Gets the
TableSchema object that this mapped table was built with. |
MappedIndex<T> |
index(String indexName)
Returns a mapped index that can be used to execute commands against a secondary index belonging to the table
being mapped by this object.
|
Key |
keyFrom(T item)
Creates a
Key object from a modelled item. |
MappedIndex<T> index(String indexName)
indexName
- The name of the secondary index to build the command interface for.MappedIndex
object that can be used to execute database commands against.<R> R execute(TableOperation<T,?,?,R> operationToPerform)
R
- The expected return type from the operation. This is typically inferred by the compiler.operationToPerform
- The operation to be performed in the context of the primary index of the table.MapperExtension getMapperExtension()
MapperExtension
associated with this mapped resource.MapperExtension
associated with this mapped resource.TableSchema<T> getTableSchema()
TableSchema
object that this mapped table was built with.TableSchema
object for this mapped table.String getTableName()
Key keyFrom(T item)
Key
object from a modelled item. This key can be used in query conditionals and get
operations to locate a specific record.item
- The item to extract the key fields from.Copyright © 2019. All rights reserved.