Class LevelStorageSource.LevelStorageAccess
java.lang.Object
net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess
- All Implemented Interfaces:
AutoCloseable
- Enclosing class:
LevelStorageSource
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) final LevelStorageSource.LevelDirectoryprivate final String(package private) final DirectoryLockprivate final Map<LevelResource, Path> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanprivate voidvoidclose()voidlongcom.mojang.serialization.Dynamic<?> private com.mojang.serialization.Dynamic<?> getDataTag(boolean p_310699_) com.mojang.serialization.Dynamic<?> getDataTagRaw(boolean fallback) getDimensionPath(ResourceKey<Level> p_197395_) getFileModificationTime(boolean p_311251_) getLevelPath(LevelResource p_78284_) getSummary(com.mojang.serialization.Dynamic<?> p_310283_) booleanlongprivate voidmodifyLevelDataWithoutDatafix(Consumer<CompoundTag> p_310066_) parent()voidrenameAndDropPlayer(String p_309798_) voidrenameLevel(String p_78298_) booleanvoidvoidsaveDataTag(RegistryAccess p_78288_, WorldData p_78289_) voidsaveDataTag(RegistryAccess p_78291_, WorldData p_78292_, CompoundTag p_78293_) private voidsaveLevelData(CompoundTag p_312575_)
-
Field Details
-
lock
-
levelDirectory
-
levelId
-
resources
-
-
Constructor Details
-
LevelStorageAccess
LevelStorageAccess(String p_289967_, Path p_289988_) throws IOException - Throws:
IOException
-
-
Method Details
-
estimateDiskSpace
public long estimateDiskSpace() -
checkForLowDiskSpace
public boolean checkForLowDiskSpace() -
safeClose
public void safeClose() -
parent
-
getLevelDirectory
-
getLevelId
-
getLevelPath
-
getDimensionPath
-
checkLock
private void checkLock() -
createPlayerStorage
-
getSummary
-
getDataTag
- Throws:
IOException
-
getDataTagFallback
- Throws:
IOException
-
getDataTagRaw
- Throws:
IOException
-
getDataTag
- Throws:
IOException
-
saveDataTag
-
saveDataTag
public void saveDataTag(RegistryAccess p_78291_, WorldData p_78292_, @Nullable CompoundTag p_78293_) -
saveLevelData
-
getIconFile
-
getWorldDir
-
deleteLevel
- Throws:
IOException
-
renameLevel
- Throws:
IOException
-
renameAndDropPlayer
- Throws:
IOException
-
modifyLevelDataWithoutDatafix
- Throws:
IOException
-
makeWorldBackup
- Throws:
IOException
-
hasWorldData
public boolean hasWorldData() -
close
- Specified by:
closein interfaceAutoCloseable- Throws:
IOException
-
restoreLevelDataFromOld
public boolean restoreLevelDataFromOld() -
getFileModificationTime
-