Class Position
java.lang.Object
me.hsgamer.hscore.bukkit.config.object.Position
a wrapper class for
Location.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
Position
public Position(@NotNull @NotNull String world, double x, double y, double z, float yaw, float pitch) ctor.- Parameters:
world- the world.x- the x.y- the y.z- the z.yaw- the yaw.pitch- the pitch.
-
-
Method Details
-
deserialize
converts the given map into a new instance ofthis.- Parameters:
map- map to deserialize.- Returns:
- deserialized
thisinstance. - Throws:
NullPointerException- if the given map has not world, x, y, z, yaw, pitch keys.ClassCastException- if the given map values contain wrong type of value forPosition(String, double, double, double, float, float)
-
get
@NotNull public @NotNull org.bukkit.Location get()convertsthisclass's values into aLocation.- Returns:
- a new
Locationinstance. - Throws:
NullPointerException- if theworldworld is not found in the server.
-
serialize
convertsthisclass's values into a map.- Returns:
- a serialized map.
-