Unbreakify things

This commit is contained in:
Sauilitired 2019-04-04 18:31:47 +02:00
parent 7e401a83cf
commit 3f194f90ce
No known key found for this signature in database
GPG Key ID: C0207FF7EA146678

View File

@ -1,17 +1,42 @@
package com.github.intellectualsites.plotsquared.plot.object;
import com.github.intellectualsites.plotsquared.plot.util.StringMan;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import lombok.AllArgsConstructor;
import org.jetbrains.annotations.Nullable;
@Getter @RequiredArgsConstructor public class PlotLoc {
/**
* (x,y,z) or (x,z) representation for PlotSquared (hence the "Plot" prefix)
*/
@AllArgsConstructor public final class PlotLoc {
private final int x;
private final int y;
private final int z;
/**
* Use the getter
*
* @see #getX()
* @deprecated
*/
@Deprecated public int x;
/**
* Use the getter
*
* @see #getY()
* @deprecated
*/
@Deprecated public int y;
/**
* Use the getter
*
* @see #getZ()
* @deprecated
*/
@Deprecated public int z;
public PlotLoc(int x, int z) {
/**
* Initialize a new {@link PlotLoc} and set the Y value to {@code -1}
* @param x X value
* @param z Y value
*/
public PlotLoc(final int x, final int z) {
this(x, -1, z);
}
@ -38,6 +63,18 @@ import org.jetbrains.annotations.Nullable;
}
}
public int getX() {
return this.x;
}
public int getY() {
return this.y;
}
public int getZ() {
return this.z;
}
@Override public int hashCode() {
final int prime = 31;
int result = 1;