Override cleanup methods in BlockCache implementations to remove world

references.
This commit is contained in:
asofold 2013-03-13 20:47:42 +01:00
parent 5197dbdbae
commit f2ab4c9a7c
6 changed files with 54 additions and 0 deletions

View File

@ -63,4 +63,13 @@ public class BlockCacheBukkit extends BlockCache{
return false;
}
/* (non-Javadoc)
* @see fr.neatmonster.nocheatplus.utilities.BlockCache#cleanup()
*/
@Override
public void cleanup() {
super.cleanup();
world = null;
}
}

View File

@ -85,6 +85,15 @@ public class BlockCacheCB2511 extends BlockCache implements IBlockAccess{
return false;
}
/* (non-Javadoc)
* @see fr.neatmonster.nocheatplus.utilities.BlockCache#cleanup()
*/
@Override
public void cleanup() {
super.cleanup();
world = null;
}
@Override
public Material getMaterial(final int x, final int y, final int z) {
return world.getMaterial(x, y, z);

View File

@ -85,6 +85,15 @@ public class BlockCacheCB2512 extends BlockCache implements IBlockAccess{
return false;
}
/* (non-Javadoc)
* @see fr.neatmonster.nocheatplus.utilities.BlockCache#cleanup()
*/
@Override
public void cleanup() {
super.cleanup();
world = null;
}
@Override
public Material getMaterial(final int x, final int y, final int z) {
return world.getMaterial(x, y, z);

View File

@ -85,6 +85,15 @@ public class BlockCacheCB2545 extends BlockCache implements IBlockAccess{
return false;
}
/* (non-Javadoc)
* @see fr.neatmonster.nocheatplus.utilities.BlockCache#cleanup()
*/
@Override
public void cleanup() {
super.cleanup();
world = null;
}
@Override
public Material getMaterial(final int x, final int y, final int z) {
return world.getMaterial(x, y, z);

View File

@ -86,6 +86,15 @@ public class BlockCacheCB2602 extends BlockCache implements IBlockAccess{
return false;
}
/* (non-Javadoc)
* @see fr.neatmonster.nocheatplus.utilities.BlockCache#cleanup()
*/
@Override
public void cleanup() {
super.cleanup();
world = null;
}
@Override
public Material getMaterial(final int x, final int y, final int z) {
return world.getMaterial(x, y, z);

View File

@ -85,6 +85,15 @@ public class BlockCacheCBDev extends BlockCache implements IBlockAccess{
return false;
}
/* (non-Javadoc)
* @see fr.neatmonster.nocheatplus.utilities.BlockCache#cleanup()
*/
@Override
public void cleanup() {
super.cleanup();
world = null;
}
@Override
public Material getMaterial(final int x, final int y, final int z) {
return world.getMaterial(x, y, z);