Class SerializingRegionBasedStorage<R>

java.lang.Object
net.minecraft.world.storage.SerializingRegionBasedStorage<R>
All Implemented Interfaces:
AutoCloseable
Direct Known Subclasses:
PointOfInterestStorage

public class SerializingRegionBasedStorage<R> extends Object implements AutoCloseable
Mappings:
Namespace Name
named net/minecraft/world/storage/SerializingRegionBasedStorage
intermediary net/minecraft/class_4180
official dwb
  • Field Details

    • LOGGER

      private static final Logger LOGGER
      Mappings:
      Namespace Name Mixin selector
      named LOGGER Lnet/minecraft/world/storage/SerializingRegionBasedStorage;LOGGER:Lorg/slf4j/Logger;
      intermediary field_18691 Lnet/minecraft/class_4180;field_18691:Lorg/slf4j/Logger;
      official a Ldwb;a:Lorg/slf4j/Logger;
    • SECTIONS_KEY

      private static final String SECTIONS_KEY
      See Also:
      Mappings:
      Namespace Name Mixin selector
      named SECTIONS_KEY Lnet/minecraft/world/storage/SerializingRegionBasedStorage;SECTIONS_KEY:Ljava/lang/String;
      intermediary field_31427 Lnet/minecraft/class_4180;field_31427:Ljava/lang/String;
      official b Ldwb;b:Ljava/lang/String;
    • storageAccess

      private final ChunkPosKeyedStorage storageAccess
      Mappings:
      Namespace Name Mixin selector
      named storageAccess Lnet/minecraft/world/storage/SerializingRegionBasedStorage;storageAccess:Lnet/minecraft/world/storage/ChunkPosKeyedStorage;
      intermediary field_48759 Lnet/minecraft/class_4180;field_48759:Lnet/minecraft/class_9172;
      official d Ldwb;d:Ldwc;
    • loadedElements

      private final Long2ObjectMap<Optional<R>> loadedElements
      Mappings:
      Namespace Name Mixin selector
      named loadedElements Lnet/minecraft/world/storage/SerializingRegionBasedStorage;loadedElements:Lit/unimi/dsi/fastutil/longs/Long2ObjectMap;
      intermediary field_18692 Lnet/minecraft/class_4180;field_18692:Lit/unimi/dsi/fastutil/longs/Long2ObjectMap;
      official e Ldwb;e:Lit/unimi/dsi/fastutil/longs/Long2ObjectMap;
    • unsavedElements

      private final LongLinkedOpenHashSet unsavedElements
      Mappings:
      Namespace Name Mixin selector
      named unsavedElements Lnet/minecraft/world/storage/SerializingRegionBasedStorage;unsavedElements:Lit/unimi/dsi/fastutil/longs/LongLinkedOpenHashSet;
      intermediary field_18693 Lnet/minecraft/class_4180;field_18693:Lit/unimi/dsi/fastutil/longs/LongLinkedOpenHashSet;
      official f Ldwb;f:Lit/unimi/dsi/fastutil/longs/LongLinkedOpenHashSet;
    • codecFactory

      private final Function<Runnable,com.mojang.serialization.Codec<R>> codecFactory
      Mappings:
      Namespace Name Mixin selector
      named codecFactory Lnet/minecraft/world/storage/SerializingRegionBasedStorage;codecFactory:Ljava/util/function/Function;
      intermediary field_24750 Lnet/minecraft/class_4180;field_24750:Ljava/util/function/Function;
      official g Ldwb;g:Ljava/util/function/Function;
    • factory

      private final Function<Runnable,R> factory
      Mappings:
      Namespace Name Mixin selector
      named factory Lnet/minecraft/world/storage/SerializingRegionBasedStorage;factory:Ljava/util/function/Function;
      intermediary field_18695 Lnet/minecraft/class_4180;field_18695:Ljava/util/function/Function;
      official h Ldwb;h:Ljava/util/function/Function;
    • registryManager

      private final DynamicRegistryManager registryManager
      Mappings:
      Namespace Name Mixin selector
      named registryManager Lnet/minecraft/world/storage/SerializingRegionBasedStorage;registryManager:Lnet/minecraft/registry/DynamicRegistryManager;
      intermediary field_39315 Lnet/minecraft/class_4180;field_39315:Lnet/minecraft/class_5455;
      official i Ldwb;i:Ljx;
    • world

      protected final HeightLimitView world
      Mappings:
      Namespace Name Mixin selector
      named world Lnet/minecraft/world/storage/SerializingRegionBasedStorage;world:Lnet/minecraft/world/HeightLimitView;
      intermediary field_27240 Lnet/minecraft/class_4180;field_27240:Lnet/minecraft/class_5539;
      official c Ldwb;c:Ldci;
  • Constructor Details

    • SerializingRegionBasedStorage

      public SerializingRegionBasedStorage(ChunkPosKeyedStorage storageAccess, Function<Runnable,com.mojang.serialization.Codec<R>> codecFactory, Function<Runnable,R> factory, DynamicRegistryManager registryManager, HeightLimitView world)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/world/storage/SerializingRegionBasedStorage;<init>(Lnet/minecraft/world/storage/ChunkPosKeyedStorage;Ljava/util/function/Function;Ljava/util/function/Function;Lnet/minecraft/registry/DynamicRegistryManager;Lnet/minecraft/world/HeightLimitView;)V
      intermediary <init> Lnet/minecraft/class_4180;<init>(Lnet/minecraft/class_9172;Ljava/util/function/Function;Ljava/util/function/Function;Lnet/minecraft/class_5455;Lnet/minecraft/class_5539;)V
      official <init> Ldwb;<init>(Ldwc;Ljava/util/function/Function;Ljava/util/function/Function;Ljx;Ldci;)V
  • Method Details

    • tick

      protected void tick(BooleanSupplier shouldKeepTicking)
      Mappings:
      Namespace Name Mixin selector
      named tick Lnet/minecraft/world/storage/SerializingRegionBasedStorage;tick(Ljava/util/function/BooleanSupplier;)V
      intermediary method_19290 Lnet/minecraft/class_4180;method_19290(Ljava/util/function/BooleanSupplier;)V
      official a Ldwb;a(Ljava/util/function/BooleanSupplier;)V
    • hasUnsavedElements

      public boolean hasUnsavedElements()
      Mappings:
      Namespace Name Mixin selector
      named hasUnsavedElements Lnet/minecraft/world/storage/SerializingRegionBasedStorage;hasUnsavedElements()Z
      intermediary method_40020 Lnet/minecraft/class_4180;method_40020()Z
      official a Ldwb;a()Z
    • getIfLoaded

      @Nullable protected @Nullable Optional<R> getIfLoaded(long pos)
      Mappings:
      Namespace Name Mixin selector
      named getIfLoaded Lnet/minecraft/world/storage/SerializingRegionBasedStorage;getIfLoaded(J)Ljava/util/Optional;
      intermediary method_19293 Lnet/minecraft/class_4180;method_19293(J)Ljava/util/Optional;
      official c Ldwb;c(J)Ljava/util/Optional;
    • get

      protected Optional<R> get(long pos)
      Mappings:
      Namespace Name Mixin selector
      named get Lnet/minecraft/world/storage/SerializingRegionBasedStorage;get(J)Ljava/util/Optional;
      intermediary method_19294 Lnet/minecraft/class_4180;method_19294(J)Ljava/util/Optional;
      official d Ldwb;d(J)Ljava/util/Optional;
    • isPosInvalid

      protected boolean isPosInvalid(long pos)
      Mappings:
      Namespace Name Mixin selector
      named isPosInvalid Lnet/minecraft/world/storage/SerializingRegionBasedStorage;isPosInvalid(J)Z
      intermediary method_19292 Lnet/minecraft/class_4180;method_19292(J)Z
      official e Ldwb;e(J)Z
    • getOrCreate

      protected R getOrCreate(long pos)
      Mappings:
      Namespace Name Mixin selector
      named getOrCreate Lnet/minecraft/world/storage/SerializingRegionBasedStorage;getOrCreate(J)Ljava/lang/Object;
      intermediary method_19295 Lnet/minecraft/class_4180;method_19295(J)Ljava/lang/Object;
      official f Ldwb;f(J)Ljava/lang/Object;
    • loadDataAt

      private void loadDataAt(ChunkPos pos)
      Mappings:
      Namespace Name Mixin selector
      named loadDataAt Lnet/minecraft/world/storage/SerializingRegionBasedStorage;loadDataAt(Lnet/minecraft/util/math/ChunkPos;)V
      intermediary method_19289 Lnet/minecraft/class_4180;method_19289(Lnet/minecraft/class_1923;)V
      official b Ldwb;b(Ldbn;)V
    • loadNbt

      Mappings:
      Namespace Name Mixin selector
      named loadNbt Lnet/minecraft/world/storage/SerializingRegionBasedStorage;loadNbt(Lnet/minecraft/util/math/ChunkPos;)Ljava/util/concurrent/CompletableFuture;
      intermediary method_20621 Lnet/minecraft/class_4180;method_20621(Lnet/minecraft/class_1923;)Ljava/util/concurrent/CompletableFuture;
      official c Ldwb;c(Ldbn;)Ljava/util/concurrent/CompletableFuture;
    • update

      private void update(ChunkPos pos, RegistryOps<NbtElement> ops, @Nullable @Nullable NbtCompound nbt)
      Mappings:
      Namespace Name Mixin selector
      named update Lnet/minecraft/world/storage/SerializingRegionBasedStorage;update(Lnet/minecraft/util/math/ChunkPos;Lnet/minecraft/registry/RegistryOps;Lnet/minecraft/nbt/NbtCompound;)V
      intermediary method_20368 Lnet/minecraft/class_4180;method_20368(Lnet/minecraft/class_1923;Lnet/minecraft/class_6903;Lnet/minecraft/class_2487;)V
      official a Ldwb;a(Ldbn;Laki;Ltx;)V
    • save

      private void save(ChunkPos pos)
      Mappings:
      Namespace Name Mixin selector
      named save Lnet/minecraft/world/storage/SerializingRegionBasedStorage;save(Lnet/minecraft/util/math/ChunkPos;)V
      intermediary method_20370 Lnet/minecraft/class_4180;method_20370(Lnet/minecraft/class_1923;)V
      official d Ldwb;d(Ldbn;)V
    • serialize

      private <T> com.mojang.serialization.Dynamic<T> serialize(ChunkPos chunkPos, com.mojang.serialization.DynamicOps<T> ops)
      Mappings:
      Namespace Name Mixin selector
      named serialize Lnet/minecraft/world/storage/SerializingRegionBasedStorage;serialize(Lnet/minecraft/util/math/ChunkPos;Lcom/mojang/serialization/DynamicOps;)Lcom/mojang/serialization/Dynamic;
      intermediary method_20367 Lnet/minecraft/class_4180;method_20367(Lnet/minecraft/class_1923;Lcom/mojang/serialization/DynamicOps;)Lcom/mojang/serialization/Dynamic;
      official a Ldwb;a(Ldbn;Lcom/mojang/serialization/DynamicOps;)Lcom/mojang/serialization/Dynamic;
    • chunkSectionPosAsLong

      private static long chunkSectionPosAsLong(ChunkPos chunkPos, int y)
      Mappings:
      Namespace Name Mixin selector
      named chunkSectionPosAsLong Lnet/minecraft/world/storage/SerializingRegionBasedStorage;chunkSectionPosAsLong(Lnet/minecraft/util/math/ChunkPos;I)J
      intermediary method_33637 Lnet/minecraft/class_4180;method_33637(Lnet/minecraft/class_1923;I)J
      official a Ldwb;a(Ldbn;I)J
    • onLoad

      protected void onLoad(long pos)
      Mappings:
      Namespace Name Mixin selector
      named onLoad Lnet/minecraft/world/storage/SerializingRegionBasedStorage;onLoad(J)V
      intermediary method_19291 Lnet/minecraft/class_4180;method_19291(J)V
      official b Ldwb;b(J)V
    • onUpdate

      protected void onUpdate(long pos)
      Mappings:
      Namespace Name Mixin selector
      named onUpdate Lnet/minecraft/world/storage/SerializingRegionBasedStorage;onUpdate(J)V
      intermediary method_19288 Lnet/minecraft/class_4180;method_19288(J)V
      official a Ldwb;a(J)V
    • getDataVersion

      private static int getDataVersion(com.mojang.serialization.Dynamic<?> dynamic)
      Mappings:
      Namespace Name Mixin selector
      named getDataVersion Lnet/minecraft/world/storage/SerializingRegionBasedStorage;getDataVersion(Lcom/mojang/serialization/Dynamic;)I
      intermediary method_20369 Lnet/minecraft/class_4180;method_20369(Lcom/mojang/serialization/Dynamic;)I
      official a Ldwb;a(Lcom/mojang/serialization/Dynamic;)I
    • saveChunk

      public void saveChunk(ChunkPos pos)
      Mappings:
      Namespace Name Mixin selector
      named saveChunk Lnet/minecraft/world/storage/SerializingRegionBasedStorage;saveChunk(Lnet/minecraft/util/math/ChunkPos;)V
      intermediary method_20436 Lnet/minecraft/class_4180;method_20436(Lnet/minecraft/class_1923;)V
      official a Ldwb;a(Ldbn;)V
    • close

      public void close() throws IOException
      Specified by:
      close in interface AutoCloseable
      Throws:
      IOException