Package me.lokka30.levelledmobs.result
Record Class PlayerNetherOrWorldSpawnResult
java.lang.Object
java.lang.Record
me.lokka30.levelledmobs.result.PlayerNetherOrWorldSpawnResult
public record PlayerNetherOrWorldSpawnResult(@NotNull org.bukkit.Location location, boolean isNetherPortalLocation, boolean isWorldPortalLocation)
extends Record
-
Constructor Summary
ConstructorDescriptionPlayerNetherOrWorldSpawnResult
(@NotNull org.bukkit.Location location, boolean isNetherPortalLocation, boolean isWorldPortalLocation) Creates an instance of aPlayerNetherOrWorldSpawnResult
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.boolean
Returns the value of theisNetherPortalLocation
record component.boolean
Returns the value of theisWorldPortalLocation
record component.@NotNull org.bukkit.Location
location()
Returns the value of thelocation
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
PlayerNetherOrWorldSpawnResult
public PlayerNetherOrWorldSpawnResult(@NotNull @NotNull org.bukkit.Location location, boolean isNetherPortalLocation, boolean isWorldPortalLocation) Creates an instance of aPlayerNetherOrWorldSpawnResult
record class.- Parameters:
location
- the value for thelocation
record componentisNetherPortalLocation
- the value for theisNetherPortalLocation
record componentisWorldPortalLocation
- the value for theisWorldPortalLocation
record component
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
location
@NotNull public @NotNull org.bukkit.Location location()Returns the value of thelocation
record component.- Returns:
- the value of the
location
record component
-
isNetherPortalLocation
public boolean isNetherPortalLocation()Returns the value of theisNetherPortalLocation
record component.- Returns:
- the value of the
isNetherPortalLocation
record component
-
isWorldPortalLocation
public boolean isWorldPortalLocation()Returns the value of theisWorldPortalLocation
record component.- Returns:
- the value of the
isWorldPortalLocation
record component
-