public class VersionedCache extends Object implements Closeable
| Constructor and Description |
|---|
VersionedCache(String name) |
VersionedCache(String name,
io.kcache.Cache<Comparable[],NavigableMap<Long,VersionedValue>> cache) |
| Modifier and Type | Method and Description |
|---|---|
io.kcache.KeyValueIterator<Comparable[],List<VersionedValue>> |
all(long minVersion,
long maxVersion) |
void |
close() |
void |
flush() |
VersionedValue |
get(Comparable[] key,
long version) |
List<VersionedValue> |
get(Comparable[] key,
long minVersion,
long maxVersion) |
String |
getName() |
void |
put(Comparable[] key,
long version,
Comparable[] value) |
io.kcache.KeyValueIterator<Comparable[],List<VersionedValue>> |
range(Comparable[] from,
boolean fromInclusive,
Comparable[] to,
boolean toInclusive,
long minVersion,
long maxVersion) |
void |
remove(Comparable[] key,
long version) |
boolean |
setCommit(Comparable[] key,
long version,
long commit) |
VersionedCache |
subCache(Comparable[] from,
boolean fromInclusive,
Comparable[] to,
boolean toInclusive) |
public VersionedCache(String name)
public VersionedCache(String name, io.kcache.Cache<Comparable[],NavigableMap<Long,VersionedValue>> cache)
public String getName()
public VersionedValue get(Comparable[] key, long version)
public List<VersionedValue> get(Comparable[] key, long minVersion, long maxVersion)
public void put(Comparable[] key, long version, Comparable[] value)
public boolean setCommit(Comparable[] key, long version, long commit)
public void remove(Comparable[] key, long version)
public VersionedCache subCache(Comparable[] from, boolean fromInclusive, Comparable[] to, boolean toInclusive)
public io.kcache.KeyValueIterator<Comparable[],List<VersionedValue>> range(Comparable[] from, boolean fromInclusive, Comparable[] to, boolean toInclusive, long minVersion, long maxVersion)
public io.kcache.KeyValueIterator<Comparable[],List<VersionedValue>> all(long minVersion, long maxVersion)
public void flush()
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionCopyright © 2020. All rights reserved.