public abstract class AbstractKeyValueAdapter extends Object implements KeyValueAdapter
KeyValueAdapter
holds QueryEngine
to delegate find and
count execution to.Modifier | Constructor and Description |
---|---|
protected |
AbstractKeyValueAdapter()
Creates new
AbstractKeyValueAdapter with using the default query engine. |
protected |
AbstractKeyValueAdapter(QueryEngine<? extends KeyValueAdapter,?,?> engine)
Creates new
AbstractKeyValueAdapter with using the default query engine. |
Modifier and Type | Method and Description |
---|---|
long |
count(KeyValueQuery<?> query,
Serializable keyspace)
Count all matching objects within keyspace.
|
<T> T |
delete(Serializable id,
Serializable keyspace,
Class<T> type) |
Collection<?> |
find(KeyValueQuery<?> query,
Serializable keyspace)
Find all matching objects within keyspace.
|
<T> Iterable<T> |
find(KeyValueQuery<?> query,
Serializable keyspace,
Class<T> type) |
<T> T |
get(Serializable id,
Serializable keyspace,
Class<T> type) |
protected QueryEngine<? extends KeyValueAdapter,?,?> |
getQueryEngine()
Get the
QueryEngine used. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
clear, contains, count, delete, deleteAllOf, entries, get, getAllOf, put
destroy
protected AbstractKeyValueAdapter()
AbstractKeyValueAdapter
with using the default query engine.protected AbstractKeyValueAdapter(QueryEngine<? extends KeyValueAdapter,?,?> engine)
AbstractKeyValueAdapter
with using the default query engine.engine
- will be defaulted to SpelQueryEngine
if null.protected QueryEngine<? extends KeyValueAdapter,?,?> getQueryEngine()
QueryEngine
used.public <T> T get(Serializable id, Serializable keyspace, Class<T> type)
get
in interface KeyValueAdapter
public <T> T delete(Serializable id, Serializable keyspace, Class<T> type)
delete
in interface KeyValueAdapter
public <T> Iterable<T> find(KeyValueQuery<?> query, Serializable keyspace, Class<T> type)
find
in interface KeyValueAdapter
public Collection<?> find(KeyValueQuery<?> query, Serializable keyspace)
KeyValueAdapter
find
in interface KeyValueAdapter
keyspace
- must not be null.Collection
if no match found.public long count(KeyValueQuery<?> query, Serializable keyspace)
KeyValueAdapter
count
in interface KeyValueAdapter
keyspace
- must not be null.Copyright © 2011-2016–2016 Pivotal Software, Inc.. All rights reserved.