HCOLL-185 refactored VanillaChronicleMap and ReplicatedChronicleMap; split BytesMapEventListener from MapEventListener; many bug fixes and optimizations; Stateless client queries without serialization/deserialization not working yet

This commit is contained in:
leventov
2014-11-28 00:05:49 +07:00
parent 38a058e3ce
commit 40a3080ac9
28 changed files with 2527 additions and 1877 deletions
@@ -19,6 +19,8 @@
package net.openhft.chronicle.map;
import net.openhft.lang.io.NativeBytes;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.Map;
@@ -28,18 +30,19 @@ import java.util.Map;
*/
interface SharedSegment<K, V> {
AutoCloseable readLock();
/**
* if passed segmentState is null, null is returned instead of readLock
*/
AutoCloseable readLock(@Nullable VanillaChronicleMap.SegmentState segmentState);
AutoCloseable writeLock();
AutoCloseable writeLock(@Nullable VanillaChronicleMap.SegmentState segmentState);
Map.Entry<K, V> getEntry(long pos);
Map.Entry<K, V> getEntry(@NotNull VanillaChronicleMap.SegmentState segmentState, long pos);
void readUnlock();
void writeUnlock();
NativeBytes entry(long pos);
int getIndex();
long offsetFromPos(long pos);