Record Class PointedLocation
java.lang.Object
java.lang.Record
kr.toxicity.hud.api.player.PointedLocation
- Record Components:
source- sourcename- nameicon- pointer namelocation- location
public record PointedLocation(@NotNull PointedLocationSource source, @NotNull String name, @Nullable String icon, @NotNull LocationWrapper location)
extends Record
Location with source and name.
-
Constructor Summary
ConstructorsConstructorDescriptionPointedLocation(@NotNull PointedLocationSource source, @NotNull String name, @Nullable String icon, @NotNull LocationWrapper location) Creates an instance of aPointedLocationrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull PointedLocationdeserialize(@NotNull com.google.gson.JsonObject data) Finds location from JSON.static @NotNull PointedLocationdeserialize(@NotNull YamlObject data) Finds location from YAML.booleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.@Nullable Stringicon()Returns the value of theiconrecord component.@NotNull LocationWrapperlocation()Returns the value of thelocationrecord component.@NotNull Stringname()Returns the value of thenamerecord component.Serializes to map.@NotNull PointedLocationSourcesource()Returns the value of thesourcerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
PointedLocation
public PointedLocation(@NotNull @NotNull PointedLocationSource source, @NotNull @NotNull String name, @Nullable @Nullable String icon, @NotNull @NotNull LocationWrapper location) Creates an instance of aPointedLocationrecord class.
-
-
Method Details
-
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). -
hashCode
-
deserialize
Finds location from YAML.- Parameters:
data- raw data- Returns:
- location
-
deserialize
@NotNull public static @NotNull PointedLocation deserialize(@NotNull @NotNull com.google.gson.JsonObject data) Finds location from JSON.- Parameters:
data- raw data- Returns:
- location
-
serialize
-
toString
-
source
-
name
-
icon
-
location
-