Record Class WorldSpigot
java.lang.Object
java.lang.Record
nl.pim16aap2.animatedarchitecture.spigot.util.implementations.WorldSpigot
- All Implemented Interfaces:
IWorld
-
Constructor Summary
ConstructorsConstructorDescriptionWorldSpigot(String worldName) WorldSpigot(String worldName, @Nullable org.bukkit.World world) Creates an instance of aWorldSpigotrecord class.WorldSpigot(org.bukkit.World world) -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.booleanexists()Checks if this is a valid world in the currentIAnimatedArchitecturePlatform.@Nullable org.bukkit.WorldGets the bukkit world represented by thisIWorldgetTime()Gets the time in this world.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.@Nullable org.bukkit.Worldworld()Returns the value of theworldrecord component.Returns the value of theworldNamerecord component.
-
Constructor Details
-
WorldSpigot
-
WorldSpigot
public WorldSpigot(org.bukkit.World world) -
WorldSpigot
Creates an instance of aWorldSpigotrecord class.- Parameters:
worldName- the value for theworldNamerecord componentworld- the value for theworldrecord component
-
-
Method Details
-
exists
public boolean exists()Description copied from interface:IWorldChecks if this is a valid world in the currentIAnimatedArchitecturePlatform.- Specified by:
existsin interfaceIWorld- Returns:
- True if this is a valid world in the current
IAnimatedArchitecturePlatform.
-
getBukkitWorld
public @Nullable org.bukkit.World getBukkitWorld()Gets the bukkit world represented by thisIWorld- Returns:
- The Bukkit world.
-
getTime
-
toString
-
hashCode
-
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). -
worldName
-
world
public @Nullable org.bukkit.World world()Returns the value of theworldrecord component.- Returns:
- the value of the
worldrecord component
-