Package net.minecraft.server
Record Class WorldStem
java.lang.Object
java.lang.Record
net.minecraft.server.WorldStem
- All Implemented Interfaces:
AutoCloseable
public record WorldStem(CloseableResourceManager resourceManager, ReloadableServerResources dataPackResources, RegistryAccess.Frozen registryAccess, WorldData worldData)
extends Record
implements AutoCloseable
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ReloadableServerResources
The field for thedataPackResources
record component.private final RegistryAccess.Frozen
The field for theregistryAccess
record component.private final CloseableResourceManager
The field for theresourceManager
record component.private final WorldData
The field for theworldData
record component. -
Constructor Summary
ConstructorDescriptionWorldStem
(CloseableResourceManager resourceManager, ReloadableServerResources dataPackResources, RegistryAccess.Frozen registryAccess, WorldData worldData) Creates an instance of aWorldStem
record class. -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Returns the value of thedataPackResources
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.static CompletableFuture<WorldStem>
load
(WorldLoader.InitConfig p_214416_, WorldLoader.WorldDataSupplier<WorldData> p_214417_, Executor p_214418_, Executor p_214419_) Returns the value of theregistryAccess
record component.Returns the value of theresourceManager
record component.final String
toString()
Returns a string representation of this record class.Returns the value of theworldData
record component.
-
Field Details
-
resourceManager
The field for theresourceManager
record component. -
dataPackResources
The field for thedataPackResources
record component. -
registryAccess
The field for theregistryAccess
record component. -
worldData
The field for theworldData
record component.
-
-
Constructor Details
-
WorldStem
public WorldStem(CloseableResourceManager resourceManager, ReloadableServerResources dataPackResources, RegistryAccess.Frozen registryAccess, WorldData worldData) Creates an instance of aWorldStem
record class.- Parameters:
resourceManager
- the value for theresourceManager
record componentdataPackResources
- the value for thedataPackResources
record componentregistryAccess
- the value for theregistryAccess
record componentworldData
- the value for theworldData
record component
-
-
Method Details
-
load
public static CompletableFuture<WorldStem> load(WorldLoader.InitConfig p_214416_, WorldLoader.WorldDataSupplier<WorldData> p_214417_, Executor p_214418_, Executor p_214419_) -
close
public void close()- Specified by:
close
in interfaceAutoCloseable
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
resourceManager
Returns the value of theresourceManager
record component.- Returns:
- the value of the
resourceManager
record component
-
dataPackResources
Returns the value of thedataPackResources
record component.- Returns:
- the value of the
dataPackResources
record component
-
registryAccess
Returns the value of theregistryAccess
record component.- Returns:
- the value of the
registryAccess
record component
-
worldData
Returns the value of theworldData
record component.- Returns:
- the value of the
worldData
record component
-