Package com.hypixel.hytale.storage
Class IndexedStorageFile_v0
java.lang.Object
com.hypixel.hytale.storage.IndexedStorageFile_v0
- All Implemented Interfaces:
Closeable,AutoCloseable
Deprecated.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static classDeprecated.protected classDeprecated. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intDeprecated.static final intDeprecated.private intDeprecated.(package private) static final IndexedStorageFile_v0.OffsetHelperDeprecated.private static final ThreadLocal<ByteBuffer> Deprecated.static final intDeprecated.private intDeprecated.private booleanDeprecated.static final intDeprecated.static final intDeprecated.static final booleanDeprecated.static final intDeprecated.static final StampedLock[]Deprecated.static final intDeprecated.private final FileChannelDeprecated.static final intDeprecated.static final intDeprecated.(package private) static final IndexedStorageFile_v0.OffsetHelperDeprecated.static final intDeprecated.private StampedLock[]Deprecated.private static final com.hypixel.hytale.logger.HytaleLoggerDeprecated.private static final ByteBufferDeprecated.(package private) static final byte[]Deprecated.static final intDeprecated.static final intDeprecated.static final StringDeprecated.private MappedByteBufferDeprecated.static final MetricsRegistry<IndexedStorageFile_v0> Deprecated.static final intDeprecated.private int[]Deprecated.private final StampedLockDeprecated.static final FileAttribute<?>[]Deprecated.private final PathDeprecated.static final intDeprecated.static final intDeprecated.private StampedLock[]Deprecated.private final StampedLockDeprecated.private intDeprecated.(package private) static final IndexedStorageFile_v0.OffsetHelperDeprecated.static final intDeprecated.static final intDeprecated.static final intDeprecated.static final intDeprecated. -
Constructor Summary
ConstructorsModifierConstructorDescription(package private)IndexedStorageFile_v0(Path path, FileChannel fileChannel) Deprecated.privateIndexedStorageFile_v0(Path path, Set<? extends OpenOption> options, FileAttribute<?>[] attrs) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionprivate static ByteBufferallocateDirect(int length) Deprecated.protected longblobHeaderPosition(int segmentIndex) Deprecated.protected intclearSegments(int firstSegmentIndex, ByteBuffer tempIndexBuffer) Deprecated.voidclose()Deprecated.protected IndexedStorageFile_v0create(int blobCount, int segmentSize) Deprecated.findFreeSegment(int count) Deprecated.voidforce(boolean metaData) Deprecated.intDeprecated.intDeprecated.protected intgetNextIndex(int segmentIndex) Deprecated.getPath()Deprecated.protected StampedLockgetSegmentLock(int segmentIndex) Deprecated.intDeprecated.private static ByteBuffergetTempBuffer(int length) Deprecated.protected intDeprecated.booleanDeprecated.it.unimi.dsi.fastutil.ints.IntListkeys()Deprecated.lock()Deprecated.protected voidDeprecated.protected IndexedStorageFile_v0open()Deprecated.static IndexedStorageFile_v0open(Path path, int blobCount, int segmentSize, OpenOption... options) Deprecated.static IndexedStorageFile_v0open(Path path, int blobCount, int segmentSize, Set<? extends OpenOption> options, FileAttribute<?>... attrs) Deprecated.static IndexedStorageFile_v0open(Path path, OpenOption... options) Deprecated.static IndexedStorageFile_v0open(Path path, Set<? extends OpenOption> options, FileAttribute<?>... attrs) Deprecated.protected intpositionToSegment(long position) Deprecated.protected voidDeprecated.readBlob(int blobIndex) Deprecated.voidreadBlob(int blobIndex, ByteBuffer dest) Deprecated.intreadBlobCompressedLength(int blobIndex) Deprecated.protected ByteBufferreadBlobHeader(int firstSegmentIndex) Deprecated.intreadBlobLength(int blobIndex) Deprecated.protected voidDeprecated.protected voidDeprecated.protected ByteBufferreadSegments(int firstSegmentIndex, int compressedLength, ByteBuffer tempHeaderBuffer) Deprecated.voidremoveBlob(int blobIndex) Deprecated.protected intrequiredSegments(long dataLength) Deprecated.intDeprecated.protected longsegmentOffset(int segmentIndex) Deprecated.protected longsegmentPosition(int segmentIndex) Deprecated.protected longDeprecated.intDeprecated.voidsetCompressionLevel(int compressionLevel) Deprecated.voidsetContiguousBlobs(boolean contiguousBlobs) Deprecated.longsize()Deprecated.toString()Deprecated.protected IndexedStorageFile_v0.SegmentRangeLocktryWriteLockSegmentRange(int start, int count) Deprecated.voidwriteBlob(int blobIndex, ByteBuffer src) Deprecated.protected voidwriteHeader(int blobCount, int segmentSize) Deprecated.protected intwriteSegments(int blobIndex, ByteBuffer data) Deprecated.
-
Field Details
-
LOGGER
private static final com.hypixel.hytale.logger.HytaleLogger LOGGERDeprecated. -
EMPTY_STAMPED_LOCKS
Deprecated. -
METRICS_REGISTRY
Deprecated. -
MAGIC_STRING
Deprecated.- See Also:
-
VERSION
public static final int VERSIONDeprecated.- See Also:
-
DEFAULT_BLOB_COUNT
public static final int DEFAULT_BLOB_COUNTDeprecated.- See Also:
-
DEFAULT_SEGMENT_SIZE
public static final int DEFAULT_SEGMENT_SIZEDeprecated.- See Also:
-
DEFAULT_COMPRESSION_LEVEL
public static final int DEFAULT_COMPRESSION_LEVELDeprecated.- See Also:
-
DEFAULT_CONTIGUOUS_BLOBS
public static final boolean DEFAULT_CONTIGUOUS_BLOBSDeprecated.- See Also:
-
HOH
Deprecated. -
MAGIC_LENGTH
public static final int MAGIC_LENGTHDeprecated.- See Also:
-
MAGIC_OFFSET
public static final int MAGIC_OFFSETDeprecated. -
VERSION_OFFSET
public static final int VERSION_OFFSETDeprecated. -
BLOB_COUNT_OFFSET
public static final int BLOB_COUNT_OFFSETDeprecated. -
SEGMENT_SIZE_OFFSET
public static final int SEGMENT_SIZE_OFFSETDeprecated. -
HEADER_LENGTH
public static final int HEADER_LENGTHDeprecated. -
SOH
Deprecated. -
NEXT_SEGMENT_OFFSET
public static final int NEXT_SEGMENT_OFFSETDeprecated. -
SEGMENT_HEADER_LENGTH
public static final int SEGMENT_HEADER_LENGTHDeprecated. -
BOH
Deprecated. -
SRC_LENGTH_OFFSET
public static final int SRC_LENGTH_OFFSETDeprecated. -
COMPRESSED_LENGTH_OFFSET
public static final int COMPRESSED_LENGTH_OFFSETDeprecated. -
BLOB_HEADER_LENGTH
public static final int BLOB_HEADER_LENGTHDeprecated. -
INDEX_SIZE
public static final int INDEX_SIZEDeprecated.- See Also:
-
UNASSIGNED_INDEX
public static final int UNASSIGNED_INDEXDeprecated.- See Also:
-
END_BLOB_INDEX
public static final int END_BLOB_INDEXDeprecated.- See Also:
-
FIRST_SEGMENT_INDEX
public static final int FIRST_SEGMENT_INDEXDeprecated.- See Also:
-
NO_ATTRIBUTES
Deprecated. -
MAGIC_BYTES
static final byte[] MAGIC_BYTESDeprecated. -
MAGIC_BUFFER
Deprecated. -
CACHED_TEMP_BUFFER
Deprecated. -
path
Deprecated. -
fileChannel
Deprecated. -
compressionLevel
private int compressionLevelDeprecated. -
contiguousBlobs
private boolean contiguousBlobsDeprecated. -
blobCount
private int blobCountDeprecated. -
segmentSize
private int segmentSizeDeprecated. -
indexLocks
Deprecated. -
mappedBlobIndexes
Deprecated. -
segmentLocksLock
Deprecated. -
segmentLocks
Deprecated. -
nextSegmentIndexesLock
Deprecated. -
nextSegmentIndexes
@Nonnull private int[] nextSegmentIndexesDeprecated.
-
-
Constructor Details
-
IndexedStorageFile_v0
private IndexedStorageFile_v0(@Nonnull Path path, Set<? extends OpenOption> options, FileAttribute<?>[] attrs) throws IOException Deprecated.- Throws:
IOException
-
IndexedStorageFile_v0
IndexedStorageFile_v0(@Nonnull Path path, FileChannel fileChannel) throws IOException Deprecated.- Throws:
IOException
-
-
Method Details
-
getTempBuffer
Deprecated. -
allocateDirect
Deprecated. -
open
@Nonnull public static IndexedStorageFile_v0 open(@Nonnull Path path, OpenOption... options) throws IOException Deprecated.- Throws:
IOException
-
open
@Nonnull public static IndexedStorageFile_v0 open(@Nonnull Path path, @Nonnull Set<? extends OpenOption> options, FileAttribute<?>... attrs) throws IOException Deprecated.- Throws:
IOException
-
open
@Nonnull public static IndexedStorageFile_v0 open(@Nonnull Path path, int blobCount, int segmentSize, OpenOption... options) throws IOException Deprecated.- Throws:
IOException
-
open
@Nonnull public static IndexedStorageFile_v0 open(@Nonnull Path path, int blobCount, int segmentSize, @Nonnull Set<? extends OpenOption> options, FileAttribute<?>... attrs) throws IOException Deprecated.- Throws:
IOException
-
getPath
Deprecated. -
getBlobCount
public int getBlobCount()Deprecated. -
getSegmentSize
public int getSegmentSize()Deprecated. -
getCompressionLevel
public int getCompressionLevel()Deprecated. -
setCompressionLevel
public void setCompressionLevel(int compressionLevel) Deprecated. -
isContiguousBlobs
public boolean isContiguousBlobs()Deprecated. -
setContiguousBlobs
public void setContiguousBlobs(boolean contiguousBlobs) Deprecated. -
create
Deprecated.- Throws:
IOException
-
writeHeader
Deprecated.- Throws:
IOException
-
open
Deprecated.- Throws:
IOException
-
readHeader
Deprecated.- Throws:
IOException
-
memoryMapBlobIndexes
Deprecated.- Throws:
IOException
-
readNextIndexes
Deprecated.- Throws:
IOException
-
processTempIndexes
Deprecated.- Throws:
IOException
-
clearSegments
protected int clearSegments(int firstSegmentIndex, @Nonnull ByteBuffer tempIndexBuffer) throws IOException Deprecated.- Throws:
IOException
-
size
Deprecated.- Throws:
IOException
-
segmentSize
public int segmentSize()Deprecated. -
segmentCount
public int segmentCount()Deprecated. -
keys
@Nonnull public it.unimi.dsi.fastutil.ints.IntList keys()Deprecated. -
readBlobLength
Deprecated.- Throws:
IOException
-
readBlobCompressedLength
Deprecated.- Throws:
IOException
-
readBlob
Deprecated.- Throws:
IOException
-
readBlob
Deprecated.- Throws:
IOException
-
readBlobHeader
Deprecated.- Throws:
IOException
-
readSegments
@Nonnull protected ByteBuffer readSegments(int firstSegmentIndex, int compressedLength, @Nonnull ByteBuffer tempHeaderBuffer) throws IOException Deprecated.- Throws:
IOException
-
writeBlob
Deprecated.- Throws:
IOException
-
removeBlob
Deprecated.- Throws:
IOException
-
writeSegments
Deprecated.- Throws:
IOException
-
findFreeSegment
Deprecated. -
getNextIndex
protected int getNextIndex(int segmentIndex) Deprecated. -
getSegmentLock
Deprecated. -
tryWriteLockSegmentRange
@Nullable protected IndexedStorageFile_v0.SegmentRangeLock tryWriteLockSegmentRange(int start, int count) Deprecated. -
indexesLength
protected int indexesLength()Deprecated. -
segmentsBase
protected long segmentsBase()Deprecated. -
segmentOffset
protected long segmentOffset(int segmentIndex) Deprecated. -
segmentPosition
protected long segmentPosition(int segmentIndex) Deprecated. -
positionToSegment
protected int positionToSegment(long position) Deprecated. -
blobHeaderPosition
protected long blobHeaderPosition(int segmentIndex) Deprecated. -
requiredSegments
protected int requiredSegments(long dataLength) Deprecated. -
lock
Deprecated.- Throws:
IOException
-
force
Deprecated.- Throws:
IOException
-
close
Deprecated.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
toString
Deprecated.
-