Reduces visibility of internal fields/methods
Reduces the visibility of all fields to private and create setters/getters when necessary. Exceptions are fields with GuiSync as these need to be public. Reduces the visibility of internal methods to private/protected/default when possible.
This commit is contained in:
@@ -22,12 +22,11 @@ package appeng.hooks;
|
||||
public class CompassResult
|
||||
{
|
||||
|
||||
public final boolean hasResult;
|
||||
public final boolean spin;
|
||||
public final double rad;
|
||||
public final long time;
|
||||
|
||||
public boolean requested = false;
|
||||
private final boolean hasResult;
|
||||
private final boolean spin;
|
||||
private final double rad;
|
||||
private final long time;
|
||||
private boolean requested = false;
|
||||
|
||||
public CompassResult( final boolean hasResult, final boolean spin, final double rad )
|
||||
{
|
||||
@@ -36,4 +35,34 @@ public class CompassResult
|
||||
this.rad = rad;
|
||||
this.time = System.currentTimeMillis();
|
||||
}
|
||||
|
||||
public boolean isValidResult()
|
||||
{
|
||||
return this.hasResult;
|
||||
}
|
||||
|
||||
public boolean isSpin()
|
||||
{
|
||||
return this.spin;
|
||||
}
|
||||
|
||||
public double getRad()
|
||||
{
|
||||
return this.rad;
|
||||
}
|
||||
|
||||
boolean isRequested()
|
||||
{
|
||||
return this.requested;
|
||||
}
|
||||
|
||||
void setRequested( final boolean requested )
|
||||
{
|
||||
this.requested = requested;
|
||||
}
|
||||
|
||||
long getTime()
|
||||
{
|
||||
return this.time;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user