Package io.permazen.kv.mvstore
Class MVMapSnapshot
java.lang.Object
io.permazen.kv.AbstractKVStore
io.permazen.kv.mvstore.MVMapKVStore
io.permazen.kv.mvstore.MVMapSnapshot
- All Implemented Interfaces:
CloseableKVStore
,KVStore
,Closeable
,AutoCloseable
A read-only snapshot an
MVMap
.
Instances must be close()
'd when no longer needed to allow the underlying MVMap
version to be released.
Mutation operations throw UnsupportedOperationException
.
-
Field Summary
Fields inherited from class io.permazen.kv.mvstore.MVMapKVStore
log
-
Constructor Summary
-
Method Summary
Methods inherited from class io.permazen.kv.mvstore.MVMapKVStore
get, getAtLeast, getAtMost, getMVMap, getRange, put, remove, toString
Methods inherited from class io.permazen.kv.AbstractKVStore
adjustCounter, decodeCounter, encodeCounter, removeRange
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface io.permazen.kv.KVStore
adjustCounter, apply, decodeCounter, encodeCounter, get, getAtLeast, getAtMost, getRange, getRange, getRange, put, remove, removeRange, removeRange
-
Constructor Details
-
MVMapSnapshot
public MVMapSnapshot(org.h2.mvstore.MVMap<byte[], byte[]> mvmap) Constructor.- Parameters:
mvmap
- the underlyingMVMap
to snapshot- Throws:
NullPointerException
- ifmvmap
is null
-
-
Method Details
-
close
public void close()Description copied from interface:CloseableKVStore
Close thisKVStore
and release any resources associated with it.If this instance is already closed, then nothing happens.
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceCloseableKVStore
-