public class PersistenceController extends Object
Constructor and Description |
---|
PersistenceController(KeyValuePersistenceSettings settings)
Constructs persistence controller from Ignite cache persistence settings.
|
Modifier and Type | Method and Description |
---|---|
com.datastax.driver.core.BoundStatement |
bindKey(com.datastax.driver.core.PreparedStatement statement,
Object key)
Binds Ignite cache key object to
PreparedStatement . |
com.datastax.driver.core.BoundStatement |
bindKeyValue(com.datastax.driver.core.PreparedStatement statement,
Object key,
Object val)
Binds Ignite cache key and value object to
PreparedStatement . |
Object |
buildKeyObject(com.datastax.driver.core.Row row)
Builds Ignite cache key object from returned Cassandra table row.
|
Object |
buildValueObject(com.datastax.driver.core.Row row)
Builds Ignite cache value object from Cassandra table row .
|
String |
getDeleteStatement(String table)
Returns CQL statement to delete row from Cassandra table.
|
String |
getLoadStatement(String table,
boolean includeKeyFields)
Returns CQL statement to select key/value fields from Cassandra table.
|
KeyValuePersistenceSettings |
getPersistenceSettings()
Returns Ignite cache persistence settings.
|
String |
getWriteStatement(String table)
Returns CQL statement to insert row into Cassandra table.
|
public PersistenceController(KeyValuePersistenceSettings settings)
settings
- persistence settings.public KeyValuePersistenceSettings getPersistenceSettings()
public String getWriteStatement(String table)
table
- Table name.public String getDeleteStatement(String table)
table
- Table name.public String getLoadStatement(String table, boolean includeKeyFields)
table
- Table name.includeKeyFields
- whether to include/exclude key fields from the returned row.public com.datastax.driver.core.BoundStatement bindKey(com.datastax.driver.core.PreparedStatement statement, Object key)
PreparedStatement
.statement
- statement to which key object should be bind.key
- key object.public com.datastax.driver.core.BoundStatement bindKeyValue(com.datastax.driver.core.PreparedStatement statement, Object key, Object val)
PreparedStatement
.statement
- statement to which key and value object should be bind.key
- key object.val
- value object.public Object buildKeyObject(com.datastax.driver.core.Row row)
row
- Cassandra table row.public Object buildValueObject(com.datastax.driver.core.Row row)
row
- Cassandra table row.
GridGain In-Memory Computing Platform : ver. 8.9.15 Release Date : December 3 2024