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:
yueh
2015-10-08 15:42:42 +02:00
parent 1ea48fb389
commit 500fc47490
463 changed files with 5670 additions and 3757 deletions
@@ -48,10 +48,10 @@ import appeng.tile.events.TileEventType;
public class TilePaint extends AEBaseTile
{
static final int LIGHT_PER_DOT = 12;
private static final int LIGHT_PER_DOT = 12;
int isLit = 0;
List<Splotch> dots = null;
private int isLit = 0;
private List<Splotch> dots = null;
@TileEvent( TileEventType.WORLD_NBT_WRITE )
public void writeToNBT_TilePaint( final NBTTagCompound data )
@@ -64,7 +64,7 @@ public class TilePaint extends AEBaseTile
}
}
void writeBuffer( final ByteBuf out )
private void writeBuffer( final ByteBuf out )
{
if( this.dots == null )
{
@@ -89,7 +89,7 @@ public class TilePaint extends AEBaseTile
}
}
void readBuffer( final ByteBuf in )
private void readBuffer( final ByteBuf in )
{
final byte howMany = in.readByte();
@@ -109,7 +109,7 @@ public class TilePaint extends AEBaseTile
this.isLit = 0;
for( final Splotch s : this.dots )
{
if( s.lumen )
if( s.isLumen() )
{
this.isLit += LIGHT_PER_DOT;
}
@@ -174,7 +174,7 @@ public class TilePaint extends AEBaseTile
while( i.hasNext() )
{
final Splotch s = i.next();
if( s.side == side )
if( s.getSide() == side )
{
i.remove();
}
@@ -189,7 +189,7 @@ public class TilePaint extends AEBaseTile
this.isLit = 0;
for( final Splotch s : this.dots )
{
if( s.lumen )
if( s.isLumen() )
{
this.isLit += LIGHT_PER_DOT;
}