Class LevelStorage
java.lang.Object
net.minecraft.world.level.storage.LevelStorage
- Mappings:
Namespace Name official dyvintermediary net/minecraft/class_32named net/minecraft/world/level/storage/LevelStorage
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordclass -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Pathprivate static final String(package private) final com.mojang.datafixers.DataFixerprivate static final ImmutableList<String>(package private) static final Logger(package private) final Path(package private) static final DateTimeFormatter -
Constructor Summary
ConstructorsConstructorDescriptionLevelStorage(Path savesDirectory, Path backupsDirectory, com.mojang.datafixers.DataFixer dataFixer) -
Method Summary
Modifier and TypeMethodDescriptionstatic LevelStorage(package private) static BiFunction<Path,com.mojang.datafixers.DataFixer, com.mojang.datafixers.util.Pair<SaveProperties, DimensionOptionsRegistryHolder.DimensionsConfig>> createLevelDataParser(com.mojang.serialization.DynamicOps<NbtElement> ops, DataConfiguration dataConfiguration, Registry<DimensionOptions> dimensionOptionsRegistry, com.mojang.serialization.Lifecycle lifecycle) (package private) BiFunction<Path,com.mojang.datafixers.DataFixer, LevelSummary> createLevelDataParser(LevelStorage.LevelSave levelSave, boolean locked) createSession(String directoryName) private intbooleanisLevelNameValid(String name) booleanlevelExists(String name) private static @Nullable NbtElementloadCompactLevelData(Path path) Returns the compact version of the NBT for the level datafile.loadSummaries(LevelStorage.LevelList levels) private static DataConfigurationparseDataPackSettings(com.mojang.serialization.Dynamic<?> dynamic) private static FeatureSetparseEnabledFeatures(com.mojang.serialization.Dynamic<?> levelData) private static @Nullable DataConfigurationreadDataPackSettings(Path path, com.mojang.datafixers.DataFixer dataFixer) private static <T> com.mojang.serialization.DataResult<WorldGenSettings>readGeneratorProperties(com.mojang.serialization.Dynamic<T> levelData, com.mojang.datafixers.DataFixer dataFixer, int version) (package private) <T> TreadLevelProperties(LevelStorage.LevelSave levelSave, BiFunction<Path, com.mojang.datafixers.DataFixer, T> levelDataParser)
-
Field Details
-
LOGGER
- Mappings:
Namespace Name Mixin selector official aLdyv;a:Lorg/slf4j/Logger;intermediary field_17665Lnet/minecraft/class_32;field_17665:Lorg/slf4j/Logger;named LOGGERLnet/minecraft/world/level/storage/LevelStorage;LOGGER:Lorg/slf4j/Logger;
-
TIME_FORMATTER
- Mappings:
Namespace Name Mixin selector official bLdyv;b:Ljava/time/format/DateTimeFormatter;intermediary field_200Lnet/minecraft/class_32;field_200:Ljava/time/format/DateTimeFormatter;named TIME_FORMATTERLnet/minecraft/world/level/storage/LevelStorage;TIME_FORMATTER:Ljava/time/format/DateTimeFormatter;
-
GENERATOR_OPTION_KEYS
- Mappings:
Namespace Name Mixin selector official cLdyv;c:Lcom/google/common/collect/ImmutableList;intermediary field_25020Lnet/minecraft/class_32;field_25020:Lcom/google/common/collect/ImmutableList;named GENERATOR_OPTION_KEYSLnet/minecraft/world/level/storage/LevelStorage;GENERATOR_OPTION_KEYS:Lcom/google/common/collect/ImmutableList;
-
DATA_KEY
- See Also:
- Mappings:
Namespace Name Mixin selector official dLdyv;d:Ljava/lang/String;intermediary field_36348Lnet/minecraft/class_32;field_36348:Ljava/lang/String;named DATA_KEYLnet/minecraft/world/level/storage/LevelStorage;DATA_KEY:Ljava/lang/String;
-
savesDirectory
- Mappings:
Namespace Name Mixin selector official eLdyv;e:Ljava/nio/file/Path;intermediary field_17666Lnet/minecraft/class_32;field_17666:Ljava/nio/file/Path;named savesDirectoryLnet/minecraft/world/level/storage/LevelStorage;savesDirectory:Ljava/nio/file/Path;
-
backupsDirectory
- Mappings:
Namespace Name Mixin selector official fLdyv;f:Ljava/nio/file/Path;intermediary field_17667Lnet/minecraft/class_32;field_17667:Ljava/nio/file/Path;named backupsDirectoryLnet/minecraft/world/level/storage/LevelStorage;backupsDirectory:Ljava/nio/file/Path;
-
dataFixer
final com.mojang.datafixers.DataFixer dataFixer- Mappings:
Namespace Name Mixin selector official gLdyv;g:Lcom/mojang/datafixers/DataFixer;intermediary field_17668Lnet/minecraft/class_32;field_17668:Lcom/mojang/datafixers/DataFixer;named dataFixerLnet/minecraft/world/level/storage/LevelStorage;dataFixer:Lcom/mojang/datafixers/DataFixer;
-
-
Constructor Details
-
LevelStorage
public LevelStorage(Path savesDirectory, Path backupsDirectory, com.mojang.datafixers.DataFixer dataFixer) - Mappings:
Namespace Name Mixin selector official <init>Ldyv;<init>(Ljava/nio/file/Path;Ljava/nio/file/Path;Lcom/mojang/datafixers/DataFixer;)Vintermediary <init>Lnet/minecraft/class_32;<init>(Ljava/nio/file/Path;Ljava/nio/file/Path;Lcom/mojang/datafixers/DataFixer;)Vnamed <init>Lnet/minecraft/world/level/storage/LevelStorage;<init>(Ljava/nio/file/Path;Ljava/nio/file/Path;Lcom/mojang/datafixers/DataFixer;)V
-
-
Method Details
-
create
- Mappings:
Namespace Name Mixin selector official aLdyv;a(Ljava/nio/file/Path;)Ldyv;intermediary method_26999Lnet/minecraft/class_32;method_26999(Ljava/nio/file/Path;)Lnet/minecraft/class_32;named createLnet/minecraft/world/level/storage/LevelStorage;create(Ljava/nio/file/Path;)Lnet/minecraft/world/level/storage/LevelStorage;
-
readGeneratorProperties
private static <T> com.mojang.serialization.DataResult<WorldGenSettings> readGeneratorProperties(com.mojang.serialization.Dynamic<T> levelData, com.mojang.datafixers.DataFixer dataFixer, int version) - Mappings:
Namespace Name Mixin selector official aLdyv;a(Lcom/mojang/serialization/Dynamic;Lcom/mojang/datafixers/DataFixer;I)Lcom/mojang/serialization/DataResult;intermediary method_29010Lnet/minecraft/class_32;method_29010(Lcom/mojang/serialization/Dynamic;Lcom/mojang/datafixers/DataFixer;I)Lcom/mojang/serialization/DataResult;named readGeneratorPropertiesLnet/minecraft/world/level/storage/LevelStorage;readGeneratorProperties(Lcom/mojang/serialization/Dynamic;Lcom/mojang/datafixers/DataFixer;I)Lcom/mojang/serialization/DataResult;
-
parseDataPackSettings
- Mappings:
Namespace Name Mixin selector official aLdyv;a(Lcom/mojang/serialization/Dynamic;)Lcnd;intermediary method_29580Lnet/minecraft/class_32;method_29580(Lcom/mojang/serialization/Dynamic;)Lnet/minecraft/class_7712;named parseDataPackSettingsLnet/minecraft/world/level/storage/LevelStorage;parseDataPackSettings(Lcom/mojang/serialization/Dynamic;)Lnet/minecraft/resource/DataConfiguration;
-
getFormatName
- Mappings:
Namespace Name Mixin selector official aLdyv;a()Ljava/lang/String;intermediary method_35504Lnet/minecraft/class_32;method_35504()Ljava/lang/String;named getFormatNameLnet/minecraft/world/level/storage/LevelStorage;getFormatName()Ljava/lang/String;
-
getLevelList
- Throws:
LevelStorageException- Mappings:
Namespace Name Mixin selector official bLdyv;b()Ldyv$a;intermediary method_235Lnet/minecraft/class_32;method_235()Lnet/minecraft/class_32$class_7410;named getLevelListLnet/minecraft/world/level/storage/LevelStorage;getLevelList()Lnet/minecraft/world/level/storage/LevelStorage$LevelList;
-
loadSummaries
- Mappings:
Namespace Name Mixin selector official aLdyv;a(Ldyv$a;)Ljava/util/concurrent/CompletableFuture;intermediary method_43417Lnet/minecraft/class_32;method_43417(Lnet/minecraft/class_32$class_7410;)Ljava/util/concurrent/CompletableFuture;named loadSummariesLnet/minecraft/world/level/storage/LevelStorage;loadSummaries(Lnet/minecraft/world/level/storage/LevelStorage$LevelList;)Ljava/util/concurrent/CompletableFuture;
-
getCurrentVersion
private int getCurrentVersion()- Mappings:
Namespace Name Mixin selector official eLdyv;e()Iintermediary method_17931Lnet/minecraft/class_32;method_17931()Inamed getCurrentVersionLnet/minecraft/world/level/storage/LevelStorage;getCurrentVersion()I
-
readLevelProperties
@Nullable <T> T readLevelProperties(LevelStorage.LevelSave levelSave, BiFunction<Path, com.mojang.datafixers.DataFixer, T> levelDataParser) - Mappings:
Namespace Name Mixin selector official aLdyv;a(Ldyv$b;Ljava/util/function/BiFunction;)Ljava/lang/Object;intermediary method_26998Lnet/minecraft/class_32;method_26998(Lnet/minecraft/class_32$class_7411;Ljava/util/function/BiFunction;)Ljava/lang/Object;named readLevelPropertiesLnet/minecraft/world/level/storage/LevelStorage;readLevelProperties(Lnet/minecraft/world/level/storage/LevelStorage$LevelSave;Ljava/util/function/BiFunction;)Ljava/lang/Object;
-
readDataPackSettings
@Nullable private static @Nullable DataConfiguration readDataPackSettings(Path path, com.mojang.datafixers.DataFixer dataFixer) - Mappings:
Namespace Name Mixin selector official aLdyv;a(Ljava/nio/file/Path;Lcom/mojang/datafixers/DataFixer;)Lcnd;intermediary method_29583Lnet/minecraft/class_32;method_29583(Ljava/nio/file/Path;Lcom/mojang/datafixers/DataFixer;)Lnet/minecraft/class_7712;named readDataPackSettingsLnet/minecraft/world/level/storage/LevelStorage;readDataPackSettings(Ljava/nio/file/Path;Lcom/mojang/datafixers/DataFixer;)Lnet/minecraft/resource/DataConfiguration;
-
createLevelDataParser
static BiFunction<Path,com.mojang.datafixers.DataFixer, createLevelDataParsercom.mojang.datafixers.util.Pair<SaveProperties, DimensionOptionsRegistryHolder.DimensionsConfig>> (com.mojang.serialization.DynamicOps<NbtElement> ops, DataConfiguration dataConfiguration, Registry<DimensionOptions> dimensionOptionsRegistry, com.mojang.serialization.Lifecycle lifecycle) - Mappings:
Namespace Name Mixin selector official aLdyv;a(Lcom/mojang/serialization/DynamicOps;Lcnd;Lhr;Lcom/mojang/serialization/Lifecycle;)Ljava/util/function/BiFunction;intermediary method_17926Lnet/minecraft/class_32;method_17926(Lcom/mojang/serialization/DynamicOps;Lnet/minecraft/class_7712;Lnet/minecraft/class_2378;Lcom/mojang/serialization/Lifecycle;)Ljava/util/function/BiFunction;named createLevelDataParserLnet/minecraft/world/level/storage/LevelStorage;createLevelDataParser(Lcom/mojang/serialization/DynamicOps;Lnet/minecraft/resource/DataConfiguration;Lnet/minecraft/registry/Registry;Lcom/mojang/serialization/Lifecycle;)Ljava/util/function/BiFunction;
-
createLevelDataParser
BiFunction<Path,com.mojang.datafixers.DataFixer, createLevelDataParserLevelSummary> (LevelStorage.LevelSave levelSave, boolean locked) - Mappings:
Namespace Name Mixin selector official aLdyv;a(Ldyv$b;Z)Ljava/util/function/BiFunction;intermediary method_29014Lnet/minecraft/class_32;method_29014(Lnet/minecraft/class_32$class_7411;Z)Ljava/util/function/BiFunction;named createLevelDataParserLnet/minecraft/world/level/storage/LevelStorage;createLevelDataParser(Lnet/minecraft/world/level/storage/LevelStorage$LevelSave;Z)Ljava/util/function/BiFunction;
-
parseEnabledFeatures
- Mappings:
Namespace Name Mixin selector official bLdyv;b(Lcom/mojang/serialization/Dynamic;)Lcau;intermediary method_45552Lnet/minecraft/class_32;method_45552(Lcom/mojang/serialization/Dynamic;)Lnet/minecraft/class_7699;named parseEnabledFeaturesLnet/minecraft/world/level/storage/LevelStorage;parseEnabledFeatures(Lcom/mojang/serialization/Dynamic;)Lnet/minecraft/resource/featuretoggle/FeatureSet;
-
loadCompactLevelData
Returns the compact version of the NBT for the level datafile.The returned NBT will not have
PlayerandWorldGenSettingskeys.- Returns:
- the compact version of the NBT for the level data
file - Throws:
IOException- Mappings:
Namespace Name Mixin selector official bLdyv;b(Ljava/nio/file/Path;)Lrk;intermediary method_40035Lnet/minecraft/class_32;method_40035(Ljava/nio/file/Path;)Lnet/minecraft/class_2520;named loadCompactLevelDataLnet/minecraft/world/level/storage/LevelStorage;loadCompactLevelData(Ljava/nio/file/Path;)Lnet/minecraft/nbt/NbtElement;
-
isLevelNameValid
- Mappings:
Namespace Name Mixin selector official aLdyv;a(Ljava/lang/String;)Zintermediary method_240Lnet/minecraft/class_32;method_240(Ljava/lang/String;)Znamed isLevelNameValidLnet/minecraft/world/level/storage/LevelStorage;isLevelNameValid(Ljava/lang/String;)Z
-
levelExists
- Mappings:
Namespace Name Mixin selector official bLdyv;b(Ljava/lang/String;)Zintermediary method_230Lnet/minecraft/class_32;method_230(Ljava/lang/String;)Znamed levelExistsLnet/minecraft/world/level/storage/LevelStorage;levelExists(Ljava/lang/String;)Z
-
getSavesDirectory
- Mappings:
Namespace Name Mixin selector official cLdyv;c()Ljava/nio/file/Path;intermediary method_19636Lnet/minecraft/class_32;method_19636()Ljava/nio/file/Path;named getSavesDirectoryLnet/minecraft/world/level/storage/LevelStorage;getSavesDirectory()Ljava/nio/file/Path;
-
getBackupsDirectory
- Mappings:
Namespace Name Mixin selector official dLdyv;d()Ljava/nio/file/Path;intermediary method_236Lnet/minecraft/class_32;method_236()Ljava/nio/file/Path;named getBackupsDirectoryLnet/minecraft/world/level/storage/LevelStorage;getBackupsDirectory()Ljava/nio/file/Path;
-
createSession
- Throws:
IOException- Mappings:
Namespace Name Mixin selector official cLdyv;c(Ljava/lang/String;)Ldyv$c;intermediary method_27002Lnet/minecraft/class_32;method_27002(Ljava/lang/String;)Lnet/minecraft/class_32$class_5143;named createSessionLnet/minecraft/world/level/storage/LevelStorage;createSession(Ljava/lang/String;)Lnet/minecraft/world/level/storage/LevelStorage$Session;
-