Renamed constants
This commit is contained in:
@@ -57,8 +57,8 @@ public class AEItemDef
|
||||
|
||||
public OreReference isOre;
|
||||
|
||||
static final AESharedNBT lowTag = new AESharedNBT( Integer.MIN_VALUE );
|
||||
static final AESharedNBT highTag = new AESharedNBT( Integer.MAX_VALUE );
|
||||
static final AESharedNBT LOW_TAG = new AESharedNBT( Integer.MIN_VALUE );
|
||||
static final AESharedNBT HIGH_TAG = new AESharedNBT( Integer.MAX_VALUE );
|
||||
|
||||
public AEItemDef(Item it) {
|
||||
this.item = it;
|
||||
|
||||
@@ -110,7 +110,7 @@ public final class AEItemStack extends AEStack<IAEItemStack> implements IAEItemS
|
||||
this.setCountRequestable( 0 );
|
||||
|
||||
this.def.reHash();
|
||||
this.def.isOre = OreHelper.instance.isOre( is );
|
||||
this.def.isOre = OreHelper.INSTANCE.isOre( is );
|
||||
}
|
||||
|
||||
public static AEItemStack create(Object a)
|
||||
@@ -401,7 +401,7 @@ public final class AEItemStack extends AEStack<IAEItemStack> implements IAEItemS
|
||||
@Override
|
||||
public boolean sameOre(IAEItemStack is)
|
||||
{
|
||||
return OreHelper.instance.sameOre( this, is );
|
||||
return OreHelper.INSTANCE.sameOre( this, is );
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -467,7 +467,7 @@ public final class AEItemStack extends AEStack<IAEItemStack> implements IAEItemS
|
||||
{
|
||||
ItemStack o = (ItemStack) st;
|
||||
|
||||
OreHelper.instance.sameOre( this, o );
|
||||
OreHelper.INSTANCE.sameOre( this, o );
|
||||
|
||||
if ( o.getItem() == this.getItem() )
|
||||
{
|
||||
@@ -555,7 +555,7 @@ public final class AEItemStack extends AEStack<IAEItemStack> implements IAEItemS
|
||||
newDef.damageValue = newDef.displayDamage;
|
||||
}
|
||||
|
||||
newDef.tagCompound = AEItemDef.lowTag;
|
||||
newDef.tagCompound = AEItemDef.LOW_TAG;
|
||||
newDef.reHash();
|
||||
return bottom;
|
||||
}
|
||||
@@ -594,7 +594,7 @@ public final class AEItemStack extends AEStack<IAEItemStack> implements IAEItemS
|
||||
newDef.damageValue = newDef.displayDamage;
|
||||
}
|
||||
|
||||
newDef.tagCompound = AEItemDef.highTag;
|
||||
newDef.tagCompound = AEItemDef.HIGH_TAG;
|
||||
newDef.reHash();
|
||||
return top;
|
||||
}
|
||||
|
||||
@@ -139,14 +139,14 @@ public class AESharedNBT extends NBTTagCompound implements IAETagCompound
|
||||
/*
|
||||
* Shared Tag Compound Cache.
|
||||
*/
|
||||
private static final WeakHashMap<SharedSearchObject, WeakReference<SharedSearchObject>> sharedTagCompounds = new WeakHashMap<SharedSearchObject, WeakReference<SharedSearchObject>>();
|
||||
private static final WeakHashMap<SharedSearchObject, WeakReference<SharedSearchObject>> SHARED_TAG_COMPOUND = new WeakHashMap<SharedSearchObject, WeakReference<SharedSearchObject>>();
|
||||
|
||||
/*
|
||||
* Debug purposes.
|
||||
*/
|
||||
public static int sharedTagLoad()
|
||||
{
|
||||
return sharedTagCompounds.size();
|
||||
return SHARED_TAG_COMPOUND.size();
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -175,7 +175,7 @@ public class AESharedNBT extends NBTTagCompound implements IAETagCompound
|
||||
|
||||
SharedSearchObject sso = new SharedSearchObject( item, meta, tagCompound );
|
||||
|
||||
WeakReference<SharedSearchObject> c = sharedTagCompounds.get( sso );
|
||||
WeakReference<SharedSearchObject> c = SHARED_TAG_COMPOUND.get( sso );
|
||||
if ( c != null )
|
||||
{
|
||||
SharedSearchObject cg = c.get();
|
||||
@@ -193,7 +193,7 @@ public class AESharedNBT extends NBTTagCompound implements IAETagCompound
|
||||
sso.shared = clone;
|
||||
clone.sso = sso;
|
||||
|
||||
sharedTagCompounds.put( sso, new WeakReference<SharedSearchObject>( sso ) );
|
||||
SHARED_TAG_COMPOUND.put( sso, new WeakReference<SharedSearchObject>( sso ) );
|
||||
return clone;
|
||||
}
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ import appeng.api.storage.data.IAEItemStack;
|
||||
public class OreHelper
|
||||
{
|
||||
|
||||
public static final OreHelper instance = new OreHelper();
|
||||
public static final OreHelper INSTANCE = new OreHelper();
|
||||
|
||||
static class ItemRef
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user