public class IntPackedSectorMap<K extends IKey<K>> extends java.lang.Object implements IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K>,K>
| Modifier and Type | Class and Description |
|---|---|
static class |
IntPackedSectorMap.SpecialSectorMapEntry<K extends IKey<K>> |
| Constructor and Description |
|---|
IntPackedSectorMap(int[] data) |
IntPackedSectorMap(int[] data,
java.util.List<IntPackedSectorMap.SpecialSectorMapEntry<K>> specialEntries) |
| Modifier and Type | Method and Description |
|---|---|
java.util.Optional<RegionEntryLocation> |
getEntryLocation(int id) |
EntryLocationHeaderEntryProvider<K> |
headerEntryProvider() |
boolean |
isSpecial(RegionEntryLocation loc) |
java.util.Iterator<RegionEntryLocation> |
iterator() |
static <L extends IKey<L>> |
readOrCreate(java.nio.channels.SeekableByteChannel file,
int entriesPerRegion) |
static <K extends IKey<K>> |
readOrCreate(java.nio.channels.SeekableByteChannel file,
int entriesPerRegion,
java.util.List<IntPackedSectorMap.SpecialSectorMapEntry<K>> specialEntries) |
java.util.Optional<java.util.function.BiConsumer<K,java.nio.ByteBuffer>> |
setOffsetAndSize(K key,
RegionEntryLocation location) |
void |
setSpecial(K key,
java.lang.Object marker) |
java.util.Optional<java.util.function.Function<K,java.nio.ByteBuffer>> |
trySpecialValue(K key) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetEntryLocationpublic IntPackedSectorMap(int[] data)
public IntPackedSectorMap(int[] data,
java.util.List<IntPackedSectorMap.SpecialSectorMapEntry<K>> specialEntries)
public java.util.Optional<java.util.function.Function<K,java.nio.ByteBuffer>> trySpecialValue(K key)
trySpecialValue in interface IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K extends IKey<K>>,K extends IKey<K>>public java.util.Optional<RegionEntryLocation> getEntryLocation(int id)
getEntryLocation in interface IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K extends IKey<K>>,K extends IKey<K>>public java.util.Optional<java.util.function.BiConsumer<K,java.nio.ByteBuffer>> setOffsetAndSize(K key, RegionEntryLocation location) throws java.io.IOException
setOffsetAndSize in interface IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K extends IKey<K>>,K extends IKey<K>>java.io.IOExceptionpublic boolean isSpecial(RegionEntryLocation loc)
isSpecial in interface IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K extends IKey<K>>,K extends IKey<K>>public void setSpecial(K key, java.lang.Object marker)
setSpecial in interface IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K extends IKey<K>>,K extends IKey<K>>public java.util.Iterator<RegionEntryLocation> iterator()
iterator in interface java.lang.Iterable<RegionEntryLocation>public EntryLocationHeaderEntryProvider<K> headerEntryProvider()
headerEntryProvider in interface IKeyIdToSectorMap<IntHeaderEntry,EntryLocationHeaderEntryProvider<K extends IKey<K>>,K extends IKey<K>>public static <K extends IKey<K>> IntPackedSectorMap<K> readOrCreate(java.nio.channels.SeekableByteChannel file, int entriesPerRegion, java.util.List<IntPackedSectorMap.SpecialSectorMapEntry<K>> specialEntries) throws java.io.IOException
java.io.IOExceptionpublic static <L extends IKey<L>> IntPackedSectorMap<L> readOrCreate(java.nio.channels.SeekableByteChannel file, int entriesPerRegion) throws java.io.IOException
java.io.IOException