Package net.minecraft.world.storage
Class RegionFile
java.lang.Object
net.minecraft.world.storage.RegionFile
- All Implemented Interfaces:
AutoCloseable
- Mappings:
Namespace Name named net/minecraft/world/storage/RegionFile
intermediary net/minecraft/class_2861
official ebf
-
Nested Class Summary
Modifier and TypeClassDescriptionprivate class
private static interface
-
Field Summary
Modifier and TypeFieldDescriptionprivate final FileChannel
(package private) final ChunkCompressionFormat
private final Path
private static final int
private static final int
private static final int
private static final int
private static final int
private static final int
private static final String
private final ByteBuffer
private static final Logger
private final Path
private final IntBuffer
protected static final int
private final IntBuffer
protected final SectorMap
(package private) final StorageKey
private static final ByteBuffer
-
Constructor Summary
ConstructorDescriptionRegionFile
(StorageKey storageKey, Path directory, Path path, boolean dsync) RegionFile
(StorageKey storageKey, Path path, Path directory, ChunkCompressionFormat compressionFormat, boolean dsync) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
private @Nullable DataInputStream
decompress
(ChunkPos pos, byte flags, InputStream stream) void
private void
private static byte
getChunkStreamVersionId
(byte flags) private static int
private Path
getExternalChunkPath
(ChunkPos chunkPos) private ByteBuffer
private static int
private static ByteArrayInputStream
getInputStream
(ByteBuffer buffer, int length) private @Nullable DataInputStream
getInputStream
(ChunkPos pos, byte flags) private static int
getOffset
(int sectorData) getPath()
private static int
getSectorCount
(int byteCount) private int
getSectorData
(ChunkPos pos) private static int
getSize
(int sectorData) boolean
private static boolean
hasChunkStreamVersionId
(byte flags) boolean
isChunkValid
(ChunkPos pos) private int
packSectorData
(int offset, int size) void
sync()
protected void
writeChunk
(ChunkPos pos, ByteBuffer buf) private void
private RegionFile.OutputAction
writeSafely
(Path path, ByteBuffer buf)
-
Field Details
-
LOGGER
- Mappings:
Namespace Name Mixin selector named LOGGER
Lnet/minecraft/world/storage/RegionFile;LOGGER:Lorg/slf4j/Logger;
intermediary field_20434
Lnet/minecraft/class_2861;field_20434:Lorg/slf4j/Logger;
official c
Lebf;c:Lorg/slf4j/Logger;
-
field_31418
private static final int field_31418- See Also:
- Mappings:
Namespace Name Mixin selector named field_31418
Lnet/minecraft/world/storage/RegionFile;field_31418:I
intermediary field_31418
Lnet/minecraft/class_2861;field_31418:I
official d
Lebf;d:I
-
SECTOR_DATA_LIMIT
protected static final int SECTOR_DATA_LIMIT- See Also:
- Mappings:
Namespace Name Mixin selector named SECTOR_DATA_LIMIT
Lnet/minecraft/world/storage/RegionFile;SECTOR_DATA_LIMIT:I
intermediary field_31417
Lnet/minecraft/class_2861;field_31417:I
official a
Lebf;a:I
-
field_31419
private static final int field_31419- See Also:
- Mappings:
Namespace Name Mixin selector named field_31419
Lnet/minecraft/world/storage/RegionFile;field_31419:I
intermediary field_31419
Lnet/minecraft/class_2861;field_31419:I
official e
Lebf;e:I
-
field_31420
private static final int field_31420- See Also:
- Mappings:
Namespace Name Mixin selector named field_31420
Lnet/minecraft/world/storage/RegionFile;field_31420:I
intermediary field_31420
Lnet/minecraft/class_2861;field_31420:I
official f
Lebf;f:I
-
ZERO
- Mappings:
Namespace Name Mixin selector named ZERO
Lnet/minecraft/world/storage/RegionFile;ZERO:Ljava/nio/ByteBuffer;
intermediary field_20435
Lnet/minecraft/class_2861;field_20435:Ljava/nio/ByteBuffer;
official g
Lebf;g:Ljava/nio/ByteBuffer;
-
FILE_EXTENSION
- See Also:
- Mappings:
Namespace Name Mixin selector named FILE_EXTENSION
Lnet/minecraft/world/storage/RegionFile;FILE_EXTENSION:Ljava/lang/String;
intermediary field_31421
Lnet/minecraft/class_2861;field_31421:Ljava/lang/String;
official h
Lebf;h:Ljava/lang/String;
-
field_31422
private static final int field_31422- See Also:
- Mappings:
Namespace Name Mixin selector named field_31422
Lnet/minecraft/world/storage/RegionFile;field_31422:I
intermediary field_31422
Lnet/minecraft/class_2861;field_31422:I
official i
Lebf;i:I
-
field_31423
private static final int field_31423- See Also:
- Mappings:
Namespace Name Mixin selector named field_31423
Lnet/minecraft/world/storage/RegionFile;field_31423:I
intermediary field_31423
Lnet/minecraft/class_2861;field_31423:I
official j
Lebf;j:I
-
field_31424
private static final int field_31424- See Also:
- Mappings:
Namespace Name Mixin selector named field_31424
Lnet/minecraft/world/storage/RegionFile;field_31424:I
intermediary field_31424
Lnet/minecraft/class_2861;field_31424:I
official k
Lebf;k:I
-
storageKey
- Mappings:
Namespace Name Mixin selector named storageKey
Lnet/minecraft/world/storage/RegionFile;storageKey:Lnet/minecraft/world/storage/StorageKey;
intermediary field_49102
Lnet/minecraft/class_2861;field_49102:Lnet/minecraft/class_9240;
official l
Lebf;l:Lebi;
-
path
- Mappings:
Namespace Name Mixin selector named path
Lnet/minecraft/world/storage/RegionFile;path:Ljava/nio/file/Path;
intermediary field_48752
Lnet/minecraft/class_2861;field_48752:Ljava/nio/file/Path;
official m
Lebf;m:Ljava/nio/file/Path;
-
channel
- Mappings:
Namespace Name Mixin selector named channel
Lnet/minecraft/world/storage/RegionFile;channel:Ljava/nio/channels/FileChannel;
intermediary field_20436
Lnet/minecraft/class_2861;field_20436:Ljava/nio/channels/FileChannel;
official n
Lebf;n:Ljava/nio/channels/FileChannel;
-
directory
- Mappings:
Namespace Name Mixin selector named directory
Lnet/minecraft/world/storage/RegionFile;directory:Ljava/nio/file/Path;
intermediary field_20657
Lnet/minecraft/class_2861;field_20657:Ljava/nio/file/Path;
official o
Lebf;o:Ljava/nio/file/Path;
-
compressionFormat
- Mappings:
Namespace Name Mixin selector named compressionFormat
Lnet/minecraft/world/storage/RegionFile;compressionFormat:Lnet/minecraft/world/storage/ChunkCompressionFormat;
intermediary field_20437
Lnet/minecraft/class_2861;field_20437:Lnet/minecraft/class_4486;
official p
Lebf;p:Lebh;
-
header
- Mappings:
Namespace Name Mixin selector named header
Lnet/minecraft/world/storage/RegionFile;header:Ljava/nio/ByteBuffer;
intermediary field_20438
Lnet/minecraft/class_2861;field_20438:Ljava/nio/ByteBuffer;
official q
Lebf;q:Ljava/nio/ByteBuffer;
-
sectorData
- Mappings:
Namespace Name Mixin selector named sectorData
Lnet/minecraft/world/storage/RegionFile;sectorData:Ljava/nio/IntBuffer;
intermediary field_20439
Lnet/minecraft/class_2861;field_20439:Ljava/nio/IntBuffer;
official r
Lebf;r:Ljava/nio/IntBuffer;
-
saveTimes
- Mappings:
Namespace Name Mixin selector named saveTimes
Lnet/minecraft/world/storage/RegionFile;saveTimes:Ljava/nio/IntBuffer;
intermediary field_20440
Lnet/minecraft/class_2861;field_20440:Ljava/nio/IntBuffer;
official s
Lebf;s:Ljava/nio/IntBuffer;
-
sectors
- Mappings:
Namespace Name Mixin selector named sectors
Lnet/minecraft/world/storage/RegionFile;sectors:Lnet/minecraft/world/storage/SectorMap;
intermediary field_20441
Lnet/minecraft/class_2861;field_20441:Lnet/minecraft/class_4485;
official b
Lebf;b:Lebe;
-
-
Constructor Details
-
RegionFile
public RegionFile(StorageKey storageKey, Path directory, Path path, boolean dsync) throws IOException - Throws:
IOException
- Mappings:
Namespace Name Mixin selector named <init>
Lnet/minecraft/world/storage/RegionFile;<init>(Lnet/minecraft/world/storage/StorageKey;Ljava/nio/file/Path;Ljava/nio/file/Path;Z)V
intermediary <init>
Lnet/minecraft/class_2861;<init>(Lnet/minecraft/class_9240;Ljava/nio/file/Path;Ljava/nio/file/Path;Z)V
official <init>
Lebf;<init>(Lebi;Ljava/nio/file/Path;Ljava/nio/file/Path;Z)V
-
RegionFile
public RegionFile(StorageKey storageKey, Path path, Path directory, ChunkCompressionFormat compressionFormat, boolean dsync) throws IOException - Throws:
IOException
- Mappings:
Namespace Name Mixin selector named <init>
Lnet/minecraft/world/storage/RegionFile;<init>(Lnet/minecraft/world/storage/StorageKey;Ljava/nio/file/Path;Ljava/nio/file/Path;Lnet/minecraft/world/storage/ChunkCompressionFormat;Z)V
intermediary <init>
Lnet/minecraft/class_2861;<init>(Lnet/minecraft/class_9240;Ljava/nio/file/Path;Ljava/nio/file/Path;Lnet/minecraft/class_4486;Z)V
official <init>
Lebf;<init>(Lebi;Ljava/nio/file/Path;Ljava/nio/file/Path;Lebh;Z)V
-
-
Method Details
-
getPath
- Mappings:
Namespace Name Mixin selector named getPath
Lnet/minecraft/world/storage/RegionFile;getPath()Ljava/nio/file/Path;
intermediary method_56566
Lnet/minecraft/class_2861;method_56566()Ljava/nio/file/Path;
official a
Lebf;a()Ljava/nio/file/Path;
-
getExternalChunkPath
- Mappings:
Namespace Name Mixin selector named getExternalChunkPath
Lnet/minecraft/world/storage/RegionFile;getExternalChunkPath(Lnet/minecraft/util/math/ChunkPos;)Ljava/nio/file/Path;
intermediary method_22413
Lnet/minecraft/class_2861;method_22413(Lnet/minecraft/class_1923;)Ljava/nio/file/Path;
official f
Lebf;f(Ldgn;)Ljava/nio/file/Path;
-
getChunkInputStream
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named getChunkInputStream
Lnet/minecraft/world/storage/RegionFile;getChunkInputStream(Lnet/minecraft/util/math/ChunkPos;)Ljava/io/DataInputStream;
intermediary method_21873
Lnet/minecraft/class_2861;method_21873(Lnet/minecraft/class_1923;)Ljava/io/DataInputStream;
official a
Lebf;a(Ldgn;)Ljava/io/DataInputStream;
-
getEpochTimeSeconds
private static int getEpochTimeSeconds()- Mappings:
Namespace Name Mixin selector named getEpochTimeSeconds
Lnet/minecraft/world/storage/RegionFile;getEpochTimeSeconds()I
intermediary method_31739
Lnet/minecraft/class_2861;method_31739()I
official c
Lebf;c()I
-
hasChunkStreamVersionId
private static boolean hasChunkStreamVersionId(byte flags) - Mappings:
Namespace Name Mixin selector named hasChunkStreamVersionId
Lnet/minecraft/world/storage/RegionFile;hasChunkStreamVersionId(B)Z
intermediary method_22407
Lnet/minecraft/class_2861;method_22407(B)Z
official a
Lebf;a(B)Z
-
getChunkStreamVersionId
private static byte getChunkStreamVersionId(byte flags) - Mappings:
Namespace Name Mixin selector named getChunkStreamVersionId
Lnet/minecraft/world/storage/RegionFile;getChunkStreamVersionId(B)B
intermediary method_22412
Lnet/minecraft/class_2861;method_22412(B)B
official b
Lebf;b(B)B
-
decompress
@Nullable private @Nullable DataInputStream decompress(ChunkPos pos, byte flags, InputStream stream) throws IOException - Throws:
IOException
- Mappings:
Namespace Name Mixin selector named decompress
Lnet/minecraft/world/storage/RegionFile;decompress(Lnet/minecraft/util/math/ChunkPos;BLjava/io/InputStream;)Ljava/io/DataInputStream;
intermediary method_22409
Lnet/minecraft/class_2861;method_22409(Lnet/minecraft/class_1923;BLjava/io/InputStream;)Ljava/io/DataInputStream;
official a
Lebf;a(Ldgn;BLjava/io/InputStream;)Ljava/io/DataInputStream;
-
getInputStream
@Nullable private @Nullable DataInputStream getInputStream(ChunkPos pos, byte flags) throws IOException - Throws:
IOException
- Mappings:
Namespace Name Mixin selector named getInputStream
Lnet/minecraft/world/storage/RegionFile;getInputStream(Lnet/minecraft/util/math/ChunkPos;B)Ljava/io/DataInputStream;
intermediary method_22408
Lnet/minecraft/class_2861;method_22408(Lnet/minecraft/class_1923;B)Ljava/io/DataInputStream;
official a
Lebf;a(Ldgn;B)Ljava/io/DataInputStream;
-
getInputStream
- Mappings:
Namespace Name Mixin selector named getInputStream
Lnet/minecraft/world/storage/RegionFile;getInputStream(Ljava/nio/ByteBuffer;I)Ljava/io/ByteArrayInputStream;
intermediary method_21876
Lnet/minecraft/class_2861;method_21876(Ljava/nio/ByteBuffer;I)Ljava/io/ByteArrayInputStream;
official a
Lebf;a(Ljava/nio/ByteBuffer;I)Ljava/io/ByteArrayInputStream;
-
packSectorData
private int packSectorData(int offset, int size) - Mappings:
Namespace Name Mixin selector named packSectorData
Lnet/minecraft/world/storage/RegionFile;packSectorData(II)I
intermediary method_21872
Lnet/minecraft/class_2861;method_21872(II)I
official a
Lebf;a(II)I
-
getSize
private static int getSize(int sectorData) - Mappings:
Namespace Name Mixin selector named getSize
Lnet/minecraft/world/storage/RegionFile;getSize(I)I
intermediary method_21871
Lnet/minecraft/class_2861;method_21871(I)I
official a
Lebf;a(I)I
-
getOffset
private static int getOffset(int sectorData) - Mappings:
Namespace Name Mixin selector named getOffset
Lnet/minecraft/world/storage/RegionFile;getOffset(I)I
intermediary method_21878
Lnet/minecraft/class_2861;method_21878(I)I
official b
Lebf;b(I)I
-
getSectorCount
private static int getSectorCount(int byteCount) - Mappings:
Namespace Name Mixin selector named getSectorCount
Lnet/minecraft/world/storage/RegionFile;getSectorCount(I)I
intermediary method_21880
Lnet/minecraft/class_2861;method_21880(I)I
official c
Lebf;c(I)I
-
isChunkValid
- Mappings:
Namespace Name Mixin selector named isChunkValid
Lnet/minecraft/world/storage/RegionFile;isChunkValid(Lnet/minecraft/util/math/ChunkPos;)Z
intermediary method_21879
Lnet/minecraft/class_2861;method_21879(Lnet/minecraft/class_1923;)Z
official b
Lebf;b(Ldgn;)Z
-
getChunkOutputStream
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named getChunkOutputStream
Lnet/minecraft/world/storage/RegionFile;getChunkOutputStream(Lnet/minecraft/util/math/ChunkPos;)Ljava/io/DataOutputStream;
intermediary method_21881
Lnet/minecraft/class_2861;method_21881(Lnet/minecraft/class_1923;)Ljava/io/DataOutputStream;
official c
Lebf;c(Ldgn;)Ljava/io/DataOutputStream;
-
sync
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named sync
Lnet/minecraft/world/storage/RegionFile;sync()V
intermediary method_26981
Lnet/minecraft/class_2861;method_26981()V
official b
Lebf;b()V
-
delete
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named delete
Lnet/minecraft/world/storage/RegionFile;delete(Lnet/minecraft/util/math/ChunkPos;)V
intermediary method_31740
Lnet/minecraft/class_2861;method_31740(Lnet/minecraft/class_1923;)V
official d
Lebf;d(Ldgn;)V
-
writeChunk
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named writeChunk
Lnet/minecraft/world/storage/RegionFile;writeChunk(Lnet/minecraft/util/math/ChunkPos;Ljava/nio/ByteBuffer;)V
intermediary method_21874
Lnet/minecraft/class_2861;method_21874(Lnet/minecraft/class_1923;Ljava/nio/ByteBuffer;)V
official a
Lebf;a(Ldgn;Ljava/nio/ByteBuffer;)V
-
getHeaderBuf
- Mappings:
Namespace Name Mixin selector named getHeaderBuf
Lnet/minecraft/world/storage/RegionFile;getHeaderBuf()Ljava/nio/ByteBuffer;
intermediary method_22406
Lnet/minecraft/class_2861;method_22406()Ljava/nio/ByteBuffer;
official d
Lebf;d()Ljava/nio/ByteBuffer;
-
writeSafely
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named writeSafely
Lnet/minecraft/world/storage/RegionFile;writeSafely(Ljava/nio/file/Path;Ljava/nio/ByteBuffer;)Lnet/minecraft/world/storage/RegionFile$OutputAction;
intermediary method_22410
Lnet/minecraft/class_2861;method_22410(Ljava/nio/file/Path;Ljava/nio/ByteBuffer;)Lnet/minecraft/class_2861$class_4549;
official a
Lebf;a(Ljava/nio/file/Path;Ljava/nio/ByteBuffer;)Lebf$b;
-
writeHeader
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named writeHeader
Lnet/minecraft/world/storage/RegionFile;writeHeader()V
intermediary method_21870
Lnet/minecraft/class_2861;method_21870()V
official e
Lebf;e()V
-
getSectorData
- Mappings:
Namespace Name Mixin selector named getSectorData
Lnet/minecraft/world/storage/RegionFile;getSectorData(Lnet/minecraft/util/math/ChunkPos;)I
intermediary method_12419
Lnet/minecraft/class_2861;method_12419(Lnet/minecraft/class_1923;)I
official g
Lebf;g(Ldgn;)I
-
hasChunk
- Mappings:
Namespace Name Mixin selector named hasChunk
Lnet/minecraft/world/storage/RegionFile;hasChunk(Lnet/minecraft/util/math/ChunkPos;)Z
intermediary method_12423
Lnet/minecraft/class_2861;method_12423(Lnet/minecraft/class_1923;)Z
official e
Lebf;e(Ldgn;)Z
-
getIndex
- Mappings:
Namespace Name Mixin selector named getIndex
Lnet/minecraft/world/storage/RegionFile;getIndex(Lnet/minecraft/util/math/ChunkPos;)I
intermediary method_17909
Lnet/minecraft/class_2861;method_17909(Lnet/minecraft/class_1923;)I
official h
Lebf;h(Ldgn;)I
-
close
- Specified by:
close
in interfaceAutoCloseable
- Throws:
IOException
-
fillLastSector
- Throws:
IOException
- Mappings:
Namespace Name Mixin selector named fillLastSector
Lnet/minecraft/world/storage/RegionFile;fillLastSector()V
intermediary method_21877
Lnet/minecraft/class_2861;method_21877()V
official f
Lebf;f()V
-