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:
@@ -316,7 +316,7 @@ public class AdaptorIInventory extends InventoryAdaptor
|
||||
return left;
|
||||
}
|
||||
|
||||
boolean canRemoveStackFromSlot( final int x, final ItemStack is )
|
||||
private boolean canRemoveStackFromSlot( final int x, final ItemStack is )
|
||||
{
|
||||
if( this.wrapperEnabled )
|
||||
{
|
||||
@@ -331,11 +331,11 @@ public class AdaptorIInventory extends InventoryAdaptor
|
||||
return new InvIterator();
|
||||
}
|
||||
|
||||
class InvIterator implements Iterator<ItemSlot>
|
||||
private class InvIterator implements Iterator<ItemSlot>
|
||||
{
|
||||
|
||||
final ItemSlot is = new ItemSlot();
|
||||
int x = 0;
|
||||
private final ItemSlot is = new ItemSlot();
|
||||
private int x = 0;
|
||||
|
||||
@Override
|
||||
public boolean hasNext()
|
||||
@@ -348,10 +348,10 @@ public class AdaptorIInventory extends InventoryAdaptor
|
||||
{
|
||||
final ItemStack iss = AdaptorIInventory.this.i.getStackInSlot( this.x );
|
||||
|
||||
this.is.isExtractable = AdaptorIInventory.this.canRemoveStackFromSlot( this.x, iss );
|
||||
this.is.setExtractable( AdaptorIInventory.this.canRemoveStackFromSlot( this.x, iss ) );
|
||||
this.is.setItemStack( iss );
|
||||
|
||||
this.is.slot = this.x;
|
||||
this.is.setSlot( this.x );
|
||||
this.x++;
|
||||
return this.is;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user