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 f054bd699b
commit e94a0cfccf
497 changed files with 7865 additions and 6908 deletions
@@ -68,8 +68,8 @@ import com.google.common.collect.ImmutableSet;
public class TileInterface extends AENetworkInvTile implements IGridTickable, ITileStorageMonitorable, IStorageMonitorable, IInventoryDestination, IInterfaceHost, IPriorityHost
{
final DualityInterface duality = new DualityInterface( this.gridProxy, this );
AEPartLocation pointAt = AEPartLocation.INTERNAL;
private final DualityInterface duality = new DualityInterface( this.getProxy(), this );
private AEPartLocation pointAt = AEPartLocation.INTERNAL;
@MENetworkEventSubscribe
public void stateChange( final MENetworkChannelsChanged c )
@@ -123,10 +123,10 @@ public class TileInterface extends AENetworkInvTile implements IGridTickable, IT
private void configureNodeSides()
{
if ( this.pointAt == AEPartLocation.INTERNAL )
this.gridProxy.setValidSides( EnumSet.allOf(EnumFacing.class) );
if( this.pointAt == AEPartLocation.INTERNAL )
this.getProxy().setValidSides( EnumSet.allOf( EnumFacing.class ) );
else
this.gridProxy.setValidSides( EnumSet.complementOf( EnumSet.of( this.pointAt.getFacing() ) ) );
this.getProxy().setValidSides( EnumSet.complementOf( EnumSet.of( this.pointAt.getFacing() ) ) );
}
@Override
@@ -154,6 +154,7 @@ public class TileInterface extends AENetworkInvTile implements IGridTickable, IT
public void onReady()
{
this.configureNodeSides();
super.onReady();
this.duality.initialize();
}