Code cleanup continues...

This commit is contained in:
KHobbits 2011-11-18 18:07:28 +00:00
parent e5a8cd88f0
commit 11f02fb947
33 changed files with 406 additions and 13 deletions

View file

@ -47,6 +47,7 @@ public class Backup implements Runnable
} }
} }
@Override
public void run() public void run()
{ {
if (active) if (active)
@ -67,6 +68,7 @@ public class Backup implements Runnable
ess.scheduleAsyncDelayedTask( ess.scheduleAsyncDelayedTask(
new Runnable() new Runnable()
{ {
@Override
public void run() public void run()
{ {
try try
@ -108,6 +110,7 @@ public class Backup implements Runnable
ess.scheduleSyncDelayedTask( ess.scheduleSyncDelayedTask(
new Runnable() new Runnable()
{ {
@Override
public void run() public void run()
{ {
server.dispatchCommand(cs, "save-on"); server.dispatchCommand(cs, "save-on");

View file

@ -19,11 +19,13 @@ public final class Console implements IReplyTo
return server.getConsoleSender(); return server.getConsoleSender();
} }
@Override
public void setReplyTo(CommandSender user) public void setReplyTo(CommandSender user)
{ {
replyTo = user; replyTo = user;
} }
@Override
public CommandSender getReplyTo() public CommandSender getReplyTo()
{ {
return replyTo; return replyTo;

View file

@ -99,6 +99,7 @@ public class EssentialsBlockListener extends BlockListener
ess.scheduleSyncDelayedTask( ess.scheduleSyncDelayedTask(
new Runnable() new Runnable()
{ {
@Override
public void run() public void run()
{ {
user.getInventory().addItem(is); user.getInventory().addItem(is);

View file

@ -142,7 +142,6 @@ public class EssentialsConf extends Configuration
catch (IOException ex) catch (IOException ex)
{ {
LOGGER.log(Level.SEVERE, Util.format("failedToWriteConfig", configFile.toString()), ex); LOGGER.log(Level.SEVERE, Util.format("failedToWriteConfig", configFile.toString()), ex);
return;
} }
finally finally
{ {

View file

@ -124,6 +124,7 @@ public class EssentialsPlayerListener extends PlayerListener
} }
final Thread thread = new Thread(new Runnable() final Thread thread = new Thread(new Runnable()
{ {
@Override
public void run() public void run()
{ {
try try
@ -139,7 +140,6 @@ public class EssentialsPlayerListener extends PlayerListener
} }
catch (InterruptedException ex) catch (InterruptedException ex)
{ {
return;
} }
} }
}); });
@ -300,6 +300,7 @@ public class EssentialsPlayerListener extends PlayerListener
event.getItemStack().setType(event.getBucket()); event.getItemStack().setType(event.getBucket());
ess.scheduleSyncDelayedTask(new Runnable() ess.scheduleSyncDelayedTask(new Runnable()
{ {
@Override
public void run() public void run()
{ {
user.updateInventory(); user.updateInventory();

View file

@ -23,367 +23,440 @@ public class FakeWorld implements World
this.env = environment; this.env = environment;
} }
@Override
public Block getBlockAt(int i, int i1, int i2) public Block getBlockAt(int i, int i1, int i2)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Block getBlockAt(Location lctn) public Block getBlockAt(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public int getBlockTypeIdAt(int i, int i1, int i2) public int getBlockTypeIdAt(int i, int i1, int i2)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public int getBlockTypeIdAt(Location lctn) public int getBlockTypeIdAt(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public int getHighestBlockYAt(int i, int i1) public int getHighestBlockYAt(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public int getHighestBlockYAt(Location lctn) public int getHighestBlockYAt(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Chunk getChunkAt(int i, int i1) public Chunk getChunkAt(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Chunk getChunkAt(Location lctn) public Chunk getChunkAt(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Chunk getChunkAt(Block block) public Chunk getChunkAt(Block block)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean isChunkLoaded(Chunk chunk) public boolean isChunkLoaded(Chunk chunk)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Chunk[] getLoadedChunks() public Chunk[] getLoadedChunks()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void loadChunk(Chunk chunk) public void loadChunk(Chunk chunk)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean isChunkLoaded(int i, int i1) public boolean isChunkLoaded(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void loadChunk(int i, int i1) public void loadChunk(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean loadChunk(int i, int i1, boolean bln) public boolean loadChunk(int i, int i1, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean unloadChunk(int i, int i1) public boolean unloadChunk(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean unloadChunk(int i, int i1, boolean bln) public boolean unloadChunk(int i, int i1, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean unloadChunk(int i, int i1, boolean bln, boolean bln1) public boolean unloadChunk(int i, int i1, boolean bln, boolean bln1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean unloadChunkRequest(int i, int i1) public boolean unloadChunkRequest(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean unloadChunkRequest(int i, int i1, boolean bln) public boolean unloadChunkRequest(int i, int i1, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean regenerateChunk(int i, int i1) public boolean regenerateChunk(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean refreshChunk(int i, int i1) public boolean refreshChunk(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Item dropItem(Location lctn, ItemStack is) public Item dropItem(Location lctn, ItemStack is)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Item dropItemNaturally(Location lctn, ItemStack is) public Item dropItemNaturally(Location lctn, ItemStack is)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Arrow spawnArrow(Location lctn, Vector vector, float f, float f1) public Arrow spawnArrow(Location lctn, Vector vector, float f, float f1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean generateTree(Location lctn, TreeType tt) public boolean generateTree(Location lctn, TreeType tt)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean generateTree(Location lctn, TreeType tt, BlockChangeDelegate bcd) public boolean generateTree(Location lctn, TreeType tt, BlockChangeDelegate bcd)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public LivingEntity spawnCreature(Location lctn, CreatureType ct) public LivingEntity spawnCreature(Location lctn, CreatureType ct)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public LightningStrike strikeLightning(Location lctn) public LightningStrike strikeLightning(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public LightningStrike strikeLightningEffect(Location lctn) public LightningStrike strikeLightningEffect(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public List<Entity> getEntities() public List<Entity> getEntities()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public List<LivingEntity> getLivingEntities() public List<LivingEntity> getLivingEntities()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public List<Player> getPlayers() public List<Player> getPlayers()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public String getName() public String getName()
{ {
return name; return name;
} }
@Override
public long getId() public long getId()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Location getSpawnLocation() public Location getSpawnLocation()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean setSpawnLocation(int i, int i1, int i2) public boolean setSpawnLocation(int i, int i1, int i2)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public long getTime() public long getTime()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setTime(long l) public void setTime(long l)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public long getFullTime() public long getFullTime()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setFullTime(long l) public void setFullTime(long l)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean hasStorm() public boolean hasStorm()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setStorm(boolean bln) public void setStorm(boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public int getWeatherDuration() public int getWeatherDuration()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setWeatherDuration(int i) public void setWeatherDuration(int i)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean isThundering() public boolean isThundering()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setThundering(boolean bln) public void setThundering(boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public int getThunderDuration() public int getThunderDuration()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setThunderDuration(int i) public void setThunderDuration(int i)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Environment getEnvironment() public Environment getEnvironment()
{ {
return env; return env;
} }
@Override
public long getSeed() public long getSeed()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean getPVP() public boolean getPVP()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setPVP(boolean bln) public void setPVP(boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void save() public void save()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean createExplosion(double d, double d1, double d2, float f) public boolean createExplosion(double d, double d1, double d2, float f)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean createExplosion(Location lctn, float f) public boolean createExplosion(Location lctn, float f)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public ChunkGenerator getGenerator() public ChunkGenerator getGenerator()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public List<BlockPopulator> getPopulators() public List<BlockPopulator> getPopulators()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void playEffect(Location lctn, Effect effect, int i) public void playEffect(Location lctn, Effect effect, int i)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void playEffect(Location lctn, Effect effect, int i, int i1) public void playEffect(Location lctn, Effect effect, int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean createExplosion(double d, double d1, double d2, float f, boolean bln) public boolean createExplosion(double d, double d1, double d2, float f, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean createExplosion(Location lctn, float f, boolean bln) public boolean createExplosion(Location lctn, float f, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public <T extends Entity> T spawn(Location lctn, Class<T> type) throws IllegalArgumentException public <T extends Entity> T spawn(Location lctn, Class<T> type) throws IllegalArgumentException
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public ChunkSnapshot getEmptyChunkSnapshot(int i, int i1, boolean bln, boolean bln1) public ChunkSnapshot getEmptyChunkSnapshot(int i, int i1, boolean bln, boolean bln1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setSpawnFlags(boolean bln, boolean bln1) public void setSpawnFlags(boolean bln, boolean bln1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean getAllowAnimals() public boolean getAllowAnimals()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean getAllowMonsters() public boolean getAllowMonsters()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public UUID getUID() public UUID getUID()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Block getHighestBlockAt(int i, int i1) public Block getHighestBlockAt(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Block getHighestBlockAt(Location lctn) public Block getHighestBlockAt(Location lctn)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public Biome getBiome(int i, int i1) public Biome getBiome(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public double getTemperature(int i, int i1) public double getTemperature(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public double getHumidity(int i, int i1) public double getHumidity(int i, int i1)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");

View file

@ -60,6 +60,7 @@ public class Jail extends BlockListener implements IConf
return config.getKeys(null); return config.getKeys(null);
} }
@Override
public void reloadConfig() public void reloadConfig()
{ {
config.load(); config.load();

View file

@ -52,77 +52,93 @@ public class OfflinePlayer implements Player
{ {
} }
@Override
public void setCompassTarget(Location lctn) public void setCompassTarget(Location lctn)
{ {
} }
@Override
public InetSocketAddress getAddress() public InetSocketAddress getAddress()
{ {
return null; return null;
} }
@Override
public void kickPlayer(String string) public void kickPlayer(String string)
{ {
} }
@Override
public PlayerInventory getInventory() public PlayerInventory getInventory()
{ {
return null; return null;
} }
@Override
public ItemStack getItemInHand() public ItemStack getItemInHand()
{ {
return null; return null;
} }
@Override
public void setItemInHand(ItemStack is) public void setItemInHand(ItemStack is)
{ {
} }
@Override
public int getHealth() public int getHealth()
{ {
return 0; return 0;
} }
@Override
public void setHealth(int i) public void setHealth(int i)
{ {
} }
@Override
public Egg throwEgg() public Egg throwEgg()
{ {
return null; return null;
} }
@Override
public Snowball throwSnowball() public Snowball throwSnowball()
{ {
return null; return null;
} }
@Override
public Arrow shootArrow() public Arrow shootArrow()
{ {
return null; return null;
} }
@Override
public boolean isInsideVehicle() public boolean isInsideVehicle()
{ {
return false; return false;
} }
@Override
public boolean leaveVehicle() public boolean leaveVehicle()
{ {
return false; return false;
} }
@Override
public Vehicle getVehicle() public Vehicle getVehicle()
{ {
return null; return null;
} }
@Override
public Location getLocation() public Location getLocation()
{ {
return location; return location;
} }
@Override
public World getWorld() public World getWorld()
{ {
return world; return world;
@ -142,11 +158,13 @@ public class OfflinePlayer implements Player
{ {
} }
@Override
public int getEntityId() public int getEntityId()
{ {
return -1; return -1;
} }
@Override
public boolean performCommand(String string) public boolean performCommand(String string)
{ {
return false; return false;
@ -157,91 +175,109 @@ public class OfflinePlayer implements Player
return false; return false;
} }
@Override
public int getRemainingAir() public int getRemainingAir()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setRemainingAir(int i) public void setRemainingAir(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getMaximumAir() public int getMaximumAir()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setMaximumAir(int i) public void setMaximumAir(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean isSneaking() public boolean isSneaking()
{ {
return false; return false;
} }
@Override
public void setSneaking(boolean bln) public void setSneaking(boolean bln)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void updateInventory() public void updateInventory()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void chat(String string) public void chat(String string)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public double getEyeHeight() public double getEyeHeight()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public double getEyeHeight(boolean bln) public double getEyeHeight(boolean bln)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public List<Block> getLineOfSight(HashSet<Byte> hs, int i) public List<Block> getLineOfSight(HashSet<Byte> hs, int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public Block getTargetBlock(HashSet<Byte> hs, int i) public Block getTargetBlock(HashSet<Byte> hs, int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public List<Block> getLastTwoTargetBlocks(HashSet<Byte> hs, int i) public List<Block> getLastTwoTargetBlocks(HashSet<Byte> hs, int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getFireTicks() public int getFireTicks()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getMaxFireTicks() public int getMaxFireTicks()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setFireTicks(int i) public void setFireTicks(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void remove() public void remove()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public Server getServer() public Server getServer()
{ {
return ess == null ? null : ess.getServer(); return ess == null ? null : ess.getServer();
@ -257,295 +293,354 @@ public class OfflinePlayer implements Player
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setVelocity(Vector vector) public void setVelocity(Vector vector)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public Vector getVelocity() public Vector getVelocity()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void damage(int i) public void damage(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void damage(int i, Entity entity) public void damage(int i, Entity entity)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public Location getEyeLocation() public Location getEyeLocation()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void sendRawMessage(String string) public void sendRawMessage(String string)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public Location getCompassTarget() public Location getCompassTarget()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getMaximumNoDamageTicks() public int getMaximumNoDamageTicks()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setMaximumNoDamageTicks(int i) public void setMaximumNoDamageTicks(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getLastDamage() public int getLastDamage()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setLastDamage(int i) public void setLastDamage(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getNoDamageTicks() public int getNoDamageTicks()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setNoDamageTicks(int i) public void setNoDamageTicks(int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean teleport(Location lctn) public boolean teleport(Location lctn)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean teleport(Entity entity) public boolean teleport(Entity entity)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public Entity getPassenger() public Entity getPassenger()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean setPassenger(Entity entity) public boolean setPassenger(Entity entity)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean isEmpty() public boolean isEmpty()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean eject() public boolean eject()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void saveData() public void saveData()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void loadData() public void loadData()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean isSleeping() public boolean isSleeping()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public int getSleepTicks() public int getSleepTicks()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public List<Entity> getNearbyEntities(double d, double d1, double d2) public List<Entity> getNearbyEntities(double d, double d1, double d2)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean isDead() public boolean isDead()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public float getFallDistance() public float getFallDistance()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setFallDistance(float f) public void setFallDistance(float f)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setSleepingIgnored(boolean bln) public void setSleepingIgnored(boolean bln)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean isSleepingIgnored() public boolean isSleepingIgnored()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void awardAchievement(Achievement a) public void awardAchievement(Achievement a)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void incrementStatistic(Statistic ststc) public void incrementStatistic(Statistic ststc)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void incrementStatistic(Statistic ststc, int i) public void incrementStatistic(Statistic ststc, int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void incrementStatistic(Statistic ststc, Material mtrl) public void incrementStatistic(Statistic ststc, Material mtrl)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void incrementStatistic(Statistic ststc, Material mtrl, int i) public void incrementStatistic(Statistic ststc, Material mtrl, int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void playNote(Location lctn, byte b, byte b1) public void playNote(Location lctn, byte b, byte b1)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void sendBlockChange(Location lctn, Material mtrl, byte b) public void sendBlockChange(Location lctn, Material mtrl, byte b)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void sendBlockChange(Location lctn, int i, byte b) public void sendBlockChange(Location lctn, int i, byte b)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void setLastDamageCause(EntityDamageEvent ede) public void setLastDamageCause(EntityDamageEvent ede)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public EntityDamageEvent getLastDamageCause() public EntityDamageEvent getLastDamageCause()
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public void playEffect(Location lctn, Effect effect, int i) public void playEffect(Location lctn, Effect effect, int i)
{ {
throw new UnsupportedOperationException(Util.i18n("notSupportedYet")); throw new UnsupportedOperationException(Util.i18n("notSupportedYet"));
} }
@Override
public boolean sendChunkChange(Location lctn, int i, int i1, int i2, byte[] bytes) public boolean sendChunkChange(Location lctn, int i, int i1, int i2, byte[] bytes)
{ {
return true; return true;
} }
@Override
public UUID getUniqueId() public UUID getUniqueId()
{ {
return uniqueId; return uniqueId;
} }
@Override
public void playNote(Location lctn, Instrument i, Note note) public void playNote(Location lctn, Instrument i, Note note)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void setPlayerTime(long l, boolean bln) public void setPlayerTime(long l, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public long getPlayerTime() public long getPlayerTime()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public long getPlayerTimeOffset() public long getPlayerTimeOffset()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean isPlayerTimeRelative() public boolean isPlayerTimeRelative()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void resetPlayerTime() public void resetPlayerTime()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public boolean isPermissionSet(String string) public boolean isPermissionSet(String string)
{ {
return false; return false;
} }
@Override
public boolean isPermissionSet(Permission prmsn) public boolean isPermissionSet(Permission prmsn)
{ {
return false; return false;
} }
@Override
public boolean hasPermission(String string) public boolean hasPermission(String string)
{ {
return false; return false;
} }
@Override
public boolean hasPermission(Permission prmsn) public boolean hasPermission(Permission prmsn)
{ {
return false; return false;
} }
@Override
public PermissionAttachment addAttachment(Plugin plugin, String string, boolean bln) public PermissionAttachment addAttachment(Plugin plugin, String string, boolean bln)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public PermissionAttachment addAttachment(Plugin plugin) public PermissionAttachment addAttachment(Plugin plugin)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public PermissionAttachment addAttachment(Plugin plugin, String string, boolean bln, int i) public PermissionAttachment addAttachment(Plugin plugin, String string, boolean bln, int i)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public PermissionAttachment addAttachment(Plugin plugin, int i) public PermissionAttachment addAttachment(Plugin plugin, int i)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void removeAttachment(PermissionAttachment pa) public void removeAttachment(PermissionAttachment pa)
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");
} }
@Override
public void recalculatePermissions() public void recalculatePermissions()
{ {
} }
@Override
public Set<PermissionAttachmentInfo> getEffectivePermissions() public Set<PermissionAttachmentInfo> getEffectivePermissions()
{ {
throw new UnsupportedOperationException("Not supported yet."); throw new UnsupportedOperationException("Not supported yet.");

View file

@ -466,6 +466,7 @@ public class Settings implements ISettings
} }
private final static double MAXMONEY = 10000000000000.0; private final static double MAXMONEY = 10000000000000.0;
@Override
public double getMaxMoney() public double getMaxMoney()
{ {
double max = config.getDouble("max-money", MAXMONEY); double max = config.getDouble("max-money", MAXMONEY);
@ -476,36 +477,43 @@ public class Settings implements ISettings
return max; return max;
} }
@Override
public boolean isEcoLogEnabled() public boolean isEcoLogEnabled()
{ {
return config.getBoolean("economy-log-enabled", false); return config.getBoolean("economy-log-enabled", false);
} }
@Override
public boolean removeGodOnDisconnect() public boolean removeGodOnDisconnect()
{ {
return config.getBoolean("remove-god-on-disconnect", false); return config.getBoolean("remove-god-on-disconnect", false);
} }
@Override
public boolean changeDisplayName() public boolean changeDisplayName()
{ {
return config.getBoolean("change-displayname", true); return config.getBoolean("change-displayname", true);
} }
@Override
public boolean useBukkitPermissions() public boolean useBukkitPermissions()
{ {
return config.getBoolean("use-bukkit-permissions", false); return config.getBoolean("use-bukkit-permissions", false);
} }
@Override
public boolean addPrefixSuffix() public boolean addPrefixSuffix()
{ {
return config.getBoolean("add-prefix-suffix", ess.getServer().getPluginManager().isPluginEnabled("EssentialsChat")); return config.getBoolean("add-prefix-suffix", ess.getServer().getPluginManager().isPluginEnabled("EssentialsChat"));
} }
@Override
public boolean disablePrefix() public boolean disablePrefix()
{ {
return config.getBoolean("disablePrefix", false); return config.getBoolean("disablePrefix", false);
} }
@Override
public boolean disableSuffix() public boolean disableSuffix()
{ {
return config.getBoolean("disableSuffix", false); return config.getBoolean("disableSuffix", false);

View file

@ -95,6 +95,7 @@ public class Spawn implements IConf
return retval; return retval;
} }
@Override
public void reloadConfig() public void reloadConfig()
{ {
config.load(); config.load();

View file

@ -85,6 +85,7 @@ public class TNTExplodeListener extends EntityListener implements Runnable
event.setCancelled(true); event.setCancelled(true);
} }
@Override
public void run() public void run()
{ {
enabled = false; enabled = false;

View file

@ -67,6 +67,7 @@ public class Teleport implements Runnable
this.chargeFor = chargeFor; this.chargeFor = chargeFor;
} }
@Override
public void run() public void run()
{ {
@ -106,7 +107,6 @@ public class Teleport implements Runnable
{ {
ess.showError(user.getBase(), ex, "teleport"); ess.showError(user.getBase(), ex, "teleport");
} }
return;
} }
catch (Exception ex) catch (Exception ex)
{ {

View file

@ -375,6 +375,7 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
return now; return now;
} }
@Override
public boolean isHidden() public boolean isHidden()
{ {
return hidden; return hidden;

View file

@ -29,6 +29,7 @@ public abstract class UserData extends PlayerExtension implements IConf
reloadConfig(); reloadConfig();
} }
@Override
public final void reloadConfig() public final void reloadConfig()
{ {
config.load(); config.load();

View file

@ -85,6 +85,7 @@ public class Warps implements IConf
warpPoints.remove(new StringIgnoreCase(name)); warpPoints.remove(new StringIgnoreCase(name));
} }
@Override
public final void reloadConfig() public final void reloadConfig()
{ {
warpPoints.clear(); warpPoints.clear();

View file

@ -52,6 +52,7 @@ public class Worth implements IConf
config.save(); config.save();
} }
@Override
public void reloadConfig() public void reloadConfig()
{ {
config.load(); config.load();

View file

@ -29,7 +29,7 @@ public class Commandafk extends EssentialsCommand
} }
} }
private final void toggleAfk(User user) private void toggleAfk(User user)
{ {
if (!user.toggleAfk()) if (!user.toggleAfk())
{ {

View file

@ -42,6 +42,7 @@ public class Commandbalancetop extends EssentialsCommand
final List<Map.Entry<User, Double>> sortedEntries = new ArrayList<Map.Entry<User, Double>>(balances.entrySet()); final List<Map.Entry<User, Double>> sortedEntries = new ArrayList<Map.Entry<User, Double>>(balances.entrySet());
Collections.sort(sortedEntries, new Comparator<Map.Entry<User, Double>>() Collections.sort(sortedEntries, new Comparator<Map.Entry<User, Double>>()
{ {
@Override
public int compare(final Entry<User, Double> entry1, final Entry<User, Double> entry2) public int compare(final Entry<User, Double> entry1, final Entry<User, Double> entry2)
{ {
return -entry1.getValue().compareTo(entry2.getValue()); return -entry1.getValue().compareTo(entry2.getValue());

View file

@ -80,6 +80,7 @@ public class Commandessentials extends EssentialsCommand
{ {
int i = 0; int i = 0;
@Override
public void run() public void run()
{ {
final String note = tune[i]; final String note = tune[i];

View file

@ -115,8 +115,6 @@ public class Commandptime extends EssentialsCommand
} }
} }
} }
return;
} }
/** /**
@ -237,6 +235,7 @@ public class Commandptime extends EssentialsCommand
class UserNameComparator implements Comparator<User> class UserNameComparator implements Comparator<User>
{ {
@Override
public int compare(User a, User b) public int compare(User a, User b)
{ {
return a.getName().compareTo(b.getName()); return a.getName().compareTo(b.getName());

View file

@ -71,7 +71,6 @@ public class Commandtime extends EssentialsCommand
{ {
sender.sendMessage(Util.format("timeCurrentWorld", world.getName(), DescParseTickFormat.format(world.getTime()))); sender.sendMessage(Util.format("timeCurrentWorld", world.getName(), DescParseTickFormat.format(world.getTime())));
} }
return;
} }
/** /**
@ -151,6 +150,7 @@ public class Commandtime extends EssentialsCommand
class WorldNameComparator implements Comparator<World> class WorldNameComparator implements Comparator<World>
{ {
@Override
public int compare(World a, World b) public int compare(World a, World b)
{ {
return a.getName().compareTo(b.getName()); return a.getName().compareTo(b.getName());

View file

@ -62,6 +62,5 @@ public class Commandtp extends EssentialsCommand
User toPlayer = getPlayer(server, args, 1); User toPlayer = getPlayer(server, args, 1);
target.getTeleport().now(toPlayer, false); target.getTeleport().now(toPlayer, false);
target.sendMessage(Util.format("teleportAtoB", Console.NAME, toPlayer.getDisplayName())); target.sendMessage(Util.format("teleportAtoB", Console.NAME, toPlayer.getDisplayName()));
return;
} }
} }

View file

@ -50,6 +50,7 @@ public class Commandwarp extends EssentialsCommand
} }
} }
@Override
public void run(Server server, CommandSender sender, String commandLabel, String[] args) throws Exception public void run(Server server, CommandSender sender, String commandLabel, String[] args) throws Exception
{ {
if (args.length < 2 || args[0].matches("[0-9]+")) if (args.length < 2 || args[0].matches("[0-9]+"))

View file

@ -32,7 +32,6 @@ public class Commandweather extends EssentialsCommand
user.sendMessage(isStorm user.sendMessage(isStorm
? Util.format("weatherStormFor", world.getName(), args[1]) ? Util.format("weatherStormFor", world.getName(), args[1])
: Util.format("weatherSunFor", world.getName(), args[1])); : Util.format("weatherSunFor", world.getName(), args[1]));
return;
} }
else else
{ {
@ -40,7 +39,6 @@ public class Commandweather extends EssentialsCommand
user.sendMessage(isStorm user.sendMessage(isStorm
? Util.format("weatherStorm", world.getName()) ? Util.format("weatherStorm", world.getName())
: Util.format("weatherSun", world.getName())); : Util.format("weatherSun", world.getName()));
return;
} }
} }
@ -66,7 +64,6 @@ public class Commandweather extends EssentialsCommand
sender.sendMessage(isStorm sender.sendMessage(isStorm
? Util.format("weatherStormFor", world.getName(), args[2]) ? Util.format("weatherStormFor", world.getName(), args[2])
: Util.format("weatherSunFor", world.getName(), args[2])); : Util.format("weatherSunFor", world.getName(), args[2]));
return;
} }
else else
{ {
@ -74,7 +71,6 @@ public class Commandweather extends EssentialsCommand
sender.sendMessage(isStorm sender.sendMessage(isStorm
? Util.format("weatherStorm", world.getName()) ? Util.format("weatherStorm", world.getName())
: Util.format("weatherSun", world.getName())); : Util.format("weatherSun", world.getName()));
return;
} }
} }
} }

View file

@ -20,11 +20,13 @@ public abstract class EssentialsCommand implements IEssentialsCommand
this.name = name; this.name = name;
} }
@Override
public void setEssentials(final IEssentials ess) public void setEssentials(final IEssentials ess)
{ {
this.ess = ess; this.ess = ess;
} }
@Override
public String getName() public String getName()
{ {
return name; return name;

View file

@ -18,26 +18,31 @@ public class BOSE6 implements Method
{ {
private BOSEconomy BOSEconomy; private BOSEconomy BOSEconomy;
@Override
public BOSEconomy getPlugin() public BOSEconomy getPlugin()
{ {
return this.BOSEconomy; return this.BOSEconomy;
} }
@Override
public String getName() public String getName()
{ {
return "BOSEconomy"; return "BOSEconomy";
} }
@Override
public String getVersion() public String getVersion()
{ {
return "0.6.2"; return "0.6.2";
} }
@Override
public int fractionalDigits() public int fractionalDigits()
{ {
return 0; return 0;
} }
@Override
public String format(double amount) public String format(double amount)
{ {
String currency = this.BOSEconomy.getMoneyNamePlural(); String currency = this.BOSEconomy.getMoneyNamePlural();
@ -50,27 +55,32 @@ public class BOSE6 implements Method
return amount + " " + currency; return amount + " " + currency;
} }
@Override
public boolean hasBanks() public boolean hasBanks()
{ {
return true; return true;
} }
@Override
public boolean hasBank(String bank) public boolean hasBank(String bank)
{ {
return this.BOSEconomy.bankExists(bank); return this.BOSEconomy.bankExists(bank);
} }
@Override
public boolean hasAccount(String name) public boolean hasAccount(String name)
{ {
return this.BOSEconomy.playerRegistered(name, false); return this.BOSEconomy.playerRegistered(name, false);
} }
@Override
public boolean hasBankAccount(String bank, String name) public boolean hasBankAccount(String bank, String name)
{ {
return this.BOSEconomy.isBankOwner(bank, name) return this.BOSEconomy.isBankOwner(bank, name)
|| this.BOSEconomy.isBankMember(bank, name); || this.BOSEconomy.isBankMember(bank, name);
} }
@Override
public boolean createAccount(String name) public boolean createAccount(String name)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -82,6 +92,7 @@ public class BOSE6 implements Method
return true; return true;
} }
@Override
public boolean createAccount(String name, Double balance) public boolean createAccount(String name, Double balance)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -94,6 +105,7 @@ public class BOSE6 implements Method
return true; return true;
} }
@Override
public MethodAccount getAccount(String name) public MethodAccount getAccount(String name)
{ {
if (!hasAccount(name)) if (!hasAccount(name))
@ -104,6 +116,7 @@ public class BOSE6 implements Method
return new BOSEAccount(name, this.BOSEconomy); return new BOSEAccount(name, this.BOSEconomy);
} }
@Override
public MethodBankAccount getBankAccount(String bank, String name) public MethodBankAccount getBankAccount(String bank, String name)
{ {
if (!hasBankAccount(bank, name)) if (!hasBankAccount(bank, name))
@ -114,6 +127,7 @@ public class BOSE6 implements Method
return new BOSEBankAccount(bank, BOSEconomy); return new BOSEBankAccount(bank, BOSEconomy);
} }
@Override
public boolean isCompatible(Plugin plugin) public boolean isCompatible(Plugin plugin)
{ {
return plugin.getDescription().getName().equalsIgnoreCase("boseconomy") return plugin.getDescription().getName().equalsIgnoreCase("boseconomy")
@ -121,6 +135,7 @@ public class BOSE6 implements Method
&& plugin.getDescription().getVersion().equals("0.6.2"); && plugin.getDescription().getVersion().equals("0.6.2");
} }
@Override
public void setPlugin(Plugin plugin) public void setPlugin(Plugin plugin)
{ {
BOSEconomy = (BOSEconomy)plugin; BOSEconomy = (BOSEconomy)plugin;
@ -138,23 +153,27 @@ public class BOSE6 implements Method
this.BOSEconomy = bOSEconomy; this.BOSEconomy = bOSEconomy;
} }
@Override
public double balance() public double balance()
{ {
return (double)this.BOSEconomy.getPlayerMoney(this.name); return (double)this.BOSEconomy.getPlayerMoney(this.name);
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
return this.BOSEconomy.setPlayerMoney(this.name, IntAmount, false); return this.BOSEconomy.setPlayerMoney(this.name, IntAmount, false);
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
return this.BOSEconomy.addPlayerMoney(this.name, IntAmount, false); return this.BOSEconomy.addPlayerMoney(this.name, IntAmount, false);
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -162,6 +181,7 @@ public class BOSE6 implements Method
return this.BOSEconomy.setPlayerMoney(this.name, (balance - IntAmount), false); return this.BOSEconomy.setPlayerMoney(this.name, (balance - IntAmount), false);
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -169,6 +189,7 @@ public class BOSE6 implements Method
return this.BOSEconomy.setPlayerMoney(this.name, (balance * IntAmount), false); return this.BOSEconomy.setPlayerMoney(this.name, (balance * IntAmount), false);
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -176,26 +197,31 @@ public class BOSE6 implements Method
return this.BOSEconomy.setPlayerMoney(this.name, (balance / IntAmount), false); return this.BOSEconomy.setPlayerMoney(this.name, (balance / IntAmount), false);
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return (this.balance() >= amount); return (this.balance() >= amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return (this.balance() > amount); return (this.balance() > amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return (this.balance() < amount); return (this.balance() < amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return (this.balance() < 0); return (this.balance() < 0);
} }
@Override
public boolean remove() public boolean remove()
{ {
return false; return false;
@ -214,27 +240,32 @@ public class BOSE6 implements Method
this.BOSEconomy = bOSEconomy; this.BOSEconomy = bOSEconomy;
} }
@Override
public String getBankName() public String getBankName()
{ {
return this.bank; return this.bank;
} }
@Override
public int getBankId() public int getBankId()
{ {
return -1; return -1;
} }
@Override
public double balance() public double balance()
{ {
return (double)this.BOSEconomy.getBankMoney(bank); return (double)this.BOSEconomy.getBankMoney(bank);
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
return this.BOSEconomy.setBankMoney(bank, IntAmount, true); return this.BOSEconomy.setBankMoney(bank, IntAmount, true);
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -242,6 +273,7 @@ public class BOSE6 implements Method
return this.BOSEconomy.setBankMoney(bank, (balance + IntAmount), false); return this.BOSEconomy.setBankMoney(bank, (balance + IntAmount), false);
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -249,6 +281,7 @@ public class BOSE6 implements Method
return this.BOSEconomy.setBankMoney(bank, (balance - IntAmount), false); return this.BOSEconomy.setBankMoney(bank, (balance - IntAmount), false);
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -256,6 +289,7 @@ public class BOSE6 implements Method
return this.BOSEconomy.setBankMoney(bank, (balance * IntAmount), false); return this.BOSEconomy.setBankMoney(bank, (balance * IntAmount), false);
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
int IntAmount = (int)Math.ceil(amount); int IntAmount = (int)Math.ceil(amount);
@ -263,26 +297,31 @@ public class BOSE6 implements Method
return this.BOSEconomy.setBankMoney(bank, (balance / IntAmount), false); return this.BOSEconomy.setBankMoney(bank, (balance / IntAmount), false);
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return (this.balance() >= amount); return (this.balance() >= amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return (this.balance() > amount); return (this.balance() > amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return (this.balance() < amount); return (this.balance() < amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return (this.balance() < 0); return (this.balance() < 0);
} }
@Override
public boolean remove() public boolean remove()
{ {
return this.BOSEconomy.removeBank(bank); return this.BOSEconomy.removeBank(bank);

View file

@ -18,26 +18,31 @@ public class BOSE7 implements Method
{ {
private BOSEconomy BOSEconomy; private BOSEconomy BOSEconomy;
@Override
public BOSEconomy getPlugin() public BOSEconomy getPlugin()
{ {
return this.BOSEconomy; return this.BOSEconomy;
} }
@Override
public String getName() public String getName()
{ {
return "BOSEconomy"; return "BOSEconomy";
} }
@Override
public String getVersion() public String getVersion()
{ {
return "0.7.0"; return "0.7.0";
} }
@Override
public int fractionalDigits() public int fractionalDigits()
{ {
return this.BOSEconomy.getFractionalDigits(); return this.BOSEconomy.getFractionalDigits();
} }
@Override
public String format(double amount) public String format(double amount)
{ {
String currency = this.BOSEconomy.getMoneyNamePlural(); String currency = this.BOSEconomy.getMoneyNamePlural();
@ -50,26 +55,31 @@ public class BOSE7 implements Method
return amount + " " + currency; return amount + " " + currency;
} }
@Override
public boolean hasBanks() public boolean hasBanks()
{ {
return true; return true;
} }
@Override
public boolean hasBank(String bank) public boolean hasBank(String bank)
{ {
return this.BOSEconomy.bankExists(bank); return this.BOSEconomy.bankExists(bank);
} }
@Override
public boolean hasAccount(String name) public boolean hasAccount(String name)
{ {
return this.BOSEconomy.playerRegistered(name, false); return this.BOSEconomy.playerRegistered(name, false);
} }
@Override
public boolean hasBankAccount(String bank, String name) public boolean hasBankAccount(String bank, String name)
{ {
return this.BOSEconomy.isBankOwner(bank, name) || this.BOSEconomy.isBankMember(bank, name); return this.BOSEconomy.isBankOwner(bank, name) || this.BOSEconomy.isBankMember(bank, name);
} }
@Override
public boolean createAccount(String name) public boolean createAccount(String name)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -81,6 +91,7 @@ public class BOSE7 implements Method
return true; return true;
} }
@Override
public boolean createAccount(String name, Double balance) public boolean createAccount(String name, Double balance)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -93,6 +104,7 @@ public class BOSE7 implements Method
return true; return true;
} }
@Override
public MethodAccount getAccount(String name) public MethodAccount getAccount(String name)
{ {
if (!hasAccount(name)) if (!hasAccount(name))
@ -103,6 +115,7 @@ public class BOSE7 implements Method
return new BOSEAccount(name, this.BOSEconomy); return new BOSEAccount(name, this.BOSEconomy);
} }
@Override
public MethodBankAccount getBankAccount(String bank, String name) public MethodBankAccount getBankAccount(String bank, String name)
{ {
if (!hasBankAccount(bank, name)) if (!hasBankAccount(bank, name))
@ -113,6 +126,7 @@ public class BOSE7 implements Method
return new BOSEBankAccount(bank, BOSEconomy); return new BOSEBankAccount(bank, BOSEconomy);
} }
@Override
public boolean isCompatible(Plugin plugin) public boolean isCompatible(Plugin plugin)
{ {
return plugin.getDescription().getName().equalsIgnoreCase("boseconomy") return plugin.getDescription().getName().equalsIgnoreCase("boseconomy")
@ -120,6 +134,7 @@ public class BOSE7 implements Method
&& !plugin.getDescription().getVersion().equals("0.6.2"); && !plugin.getDescription().getVersion().equals("0.6.2");
} }
@Override
public void setPlugin(Plugin plugin) public void setPlugin(Plugin plugin)
{ {
BOSEconomy = (BOSEconomy)plugin; BOSEconomy = (BOSEconomy)plugin;
@ -137,59 +152,70 @@ public class BOSE7 implements Method
this.BOSEconomy = bOSEconomy; this.BOSEconomy = bOSEconomy;
} }
@Override
public double balance() public double balance()
{ {
return this.BOSEconomy.getPlayerMoneyDouble(this.name); return this.BOSEconomy.getPlayerMoneyDouble(this.name);
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
return this.BOSEconomy.setPlayerMoney(this.name, amount, false); return this.BOSEconomy.setPlayerMoney(this.name, amount, false);
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
return this.BOSEconomy.addPlayerMoney(this.name, amount, false); return this.BOSEconomy.addPlayerMoney(this.name, amount, false);
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setPlayerMoney(this.name, (balance - amount), false); return this.BOSEconomy.setPlayerMoney(this.name, (balance - amount), false);
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setPlayerMoney(this.name, (balance * amount), false); return this.BOSEconomy.setPlayerMoney(this.name, (balance * amount), false);
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setPlayerMoney(this.name, (balance / amount), false); return this.BOSEconomy.setPlayerMoney(this.name, (balance / amount), false);
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return (this.balance() >= amount); return (this.balance() >= amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return (this.balance() > amount); return (this.balance() > amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return (this.balance() < amount); return (this.balance() < amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return (this.balance() < 0); return (this.balance() < 0);
} }
@Override
public boolean remove() public boolean remove()
{ {
return false; return false;
@ -208,70 +234,83 @@ public class BOSE7 implements Method
this.BOSEconomy = bOSEconomy; this.BOSEconomy = bOSEconomy;
} }
@Override
public String getBankName() public String getBankName()
{ {
return this.bank; return this.bank;
} }
@Override
public int getBankId() public int getBankId()
{ {
return -1; return -1;
} }
@Override
public double balance() public double balance()
{ {
return this.BOSEconomy.getBankMoneyDouble(bank); return this.BOSEconomy.getBankMoneyDouble(bank);
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
return this.BOSEconomy.setBankMoney(bank, amount, true); return this.BOSEconomy.setBankMoney(bank, amount, true);
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setBankMoney(bank, (balance + amount), false); return this.BOSEconomy.setBankMoney(bank, (balance + amount), false);
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setBankMoney(bank, (balance - amount), false); return this.BOSEconomy.setBankMoney(bank, (balance - amount), false);
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setBankMoney(bank, (balance * amount), false); return this.BOSEconomy.setBankMoney(bank, (balance * amount), false);
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
double balance = this.balance(); double balance = this.balance();
return this.BOSEconomy.setBankMoney(bank, (balance / amount), false); return this.BOSEconomy.setBankMoney(bank, (balance / amount), false);
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return (this.balance() >= amount); return (this.balance() >= amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return (this.balance() > amount); return (this.balance() > amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return (this.balance() < amount); return (this.balance() < amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return (this.balance() < 0); return (this.balance() < 0);
} }
@Override
public boolean remove() public boolean remove()
{ {
return this.BOSEconomy.removeBank(bank); return this.BOSEconomy.removeBank(bank);

View file

@ -19,73 +19,87 @@ public class MCUR implements Method
{ {
private Currency currencyList; private Currency currencyList;
@Override
public Object getPlugin() public Object getPlugin()
{ {
return this.currencyList; return this.currencyList;
} }
@Override
public String getName() public String getName()
{ {
return "MultiCurrency"; return "MultiCurrency";
} }
@Override
public String getVersion() public String getVersion()
{ {
return "0.09"; return "0.09";
} }
@Override
public int fractionalDigits() public int fractionalDigits()
{ {
return -1; return -1;
} }
@Override
public String format(double amount) public String format(double amount)
{ {
return amount + " Currency"; return amount + " Currency";
} }
@Override
public boolean hasBanks() public boolean hasBanks()
{ {
return false; return false;
} }
@Override
public boolean hasBank(String bank) public boolean hasBank(String bank)
{ {
return false; return false;
} }
@Override
public boolean hasAccount(String name) public boolean hasAccount(String name)
{ {
return true; return true;
} }
@Override
public boolean hasBankAccount(String bank, String name) public boolean hasBankAccount(String bank, String name)
{ {
return false; return false;
} }
@Override
public boolean createAccount(String name) public boolean createAccount(String name)
{ {
CurrencyList.setValue((String)CurrencyList.maxCurrency(name)[0], name, 0); CurrencyList.setValue((String)CurrencyList.maxCurrency(name)[0], name, 0);
return true; return true;
} }
@Override
public boolean createAccount(String name, Double balance) public boolean createAccount(String name, Double balance)
{ {
CurrencyList.setValue((String)CurrencyList.maxCurrency(name)[0], name, balance); CurrencyList.setValue((String)CurrencyList.maxCurrency(name)[0], name, balance);
return true; return true;
} }
@Override
public MethodAccount getAccount(String name) public MethodAccount getAccount(String name)
{ {
return new MCurrencyAccount(name); return new MCurrencyAccount(name);
} }
@Override
public MethodBankAccount getBankAccount(String bank, String name) public MethodBankAccount getBankAccount(String bank, String name)
{ {
return null; return null;
} }
@Override
public boolean isCompatible(Plugin plugin) public boolean isCompatible(Plugin plugin)
{ {
return (plugin.getDescription().getName().equalsIgnoreCase("Currency") return (plugin.getDescription().getName().equalsIgnoreCase("Currency")
@ -93,6 +107,7 @@ public class MCUR implements Method
&& plugin instanceof Currency; && plugin instanceof Currency;
} }
@Override
public void setPlugin(Plugin plugin) public void setPlugin(Plugin plugin)
{ {
currencyList = (Currency)plugin; currencyList = (Currency)plugin;
@ -108,57 +123,68 @@ public class MCUR implements Method
this.name = name; this.name = name;
} }
@Override
public double balance() public double balance()
{ {
return CurrencyList.getValue((String)CurrencyList.maxCurrency(name)[0], name); return CurrencyList.getValue((String)CurrencyList.maxCurrency(name)[0], name);
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
CurrencyList.setValue((String)CurrencyList.maxCurrency(name)[0], name, amount); CurrencyList.setValue((String)CurrencyList.maxCurrency(name)[0], name, amount);
return true; return true;
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
return CurrencyList.add(name, amount); return CurrencyList.add(name, amount);
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
return CurrencyList.subtract(name, amount); return CurrencyList.subtract(name, amount);
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
return CurrencyList.multiply(name, amount); return CurrencyList.multiply(name, amount);
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
return CurrencyList.divide(name, amount); return CurrencyList.divide(name, amount);
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return CurrencyList.hasEnough(name, amount); return CurrencyList.hasEnough(name, amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return CurrencyList.hasOver(name, amount); return CurrencyList.hasOver(name, amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return CurrencyList.hasUnder(name, amount); return CurrencyList.hasUnder(name, amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return CurrencyList.isNegative(name); return CurrencyList.isNegative(name);
} }
@Override
public boolean remove() public boolean remove()
{ {
return CurrencyList.remove(name); return CurrencyList.remove(name);

View file

@ -19,51 +19,61 @@ public class iCo4 implements Method
{ {
private iConomy iConomy; private iConomy iConomy;
@Override
public iConomy getPlugin() public iConomy getPlugin()
{ {
return this.iConomy; return this.iConomy;
} }
@Override
public String getName() public String getName()
{ {
return "iConomy"; return "iConomy";
} }
@Override
public String getVersion() public String getVersion()
{ {
return "4"; return "4";
} }
@Override
public int fractionalDigits() public int fractionalDigits()
{ {
return 2; return 2;
} }
@Override
public String format(double amount) public String format(double amount)
{ {
return com.nijiko.coelho.iConomy.iConomy.getBank().format(amount); return com.nijiko.coelho.iConomy.iConomy.getBank().format(amount);
} }
@Override
public boolean hasBanks() public boolean hasBanks()
{ {
return false; return false;
} }
@Override
public boolean hasBank(String bank) public boolean hasBank(String bank)
{ {
return false; return false;
} }
@Override
public boolean hasAccount(String name) public boolean hasAccount(String name)
{ {
return com.nijiko.coelho.iConomy.iConomy.getBank().hasAccount(name); return com.nijiko.coelho.iConomy.iConomy.getBank().hasAccount(name);
} }
@Override
public boolean hasBankAccount(String bank, String name) public boolean hasBankAccount(String bank, String name)
{ {
return false; return false;
} }
@Override
public boolean createAccount(String name) public boolean createAccount(String name)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -83,6 +93,7 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public boolean createAccount(String name, Double balance) public boolean createAccount(String name, Double balance)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -102,16 +113,19 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public MethodAccount getAccount(String name) public MethodAccount getAccount(String name)
{ {
return new iCoAccount(com.nijiko.coelho.iConomy.iConomy.getBank().getAccount(name)); return new iCoAccount(com.nijiko.coelho.iConomy.iConomy.getBank().getAccount(name));
} }
@Override
public MethodBankAccount getBankAccount(String bank, String name) public MethodBankAccount getBankAccount(String bank, String name)
{ {
return null; return null;
} }
@Override
public boolean isCompatible(Plugin plugin) public boolean isCompatible(Plugin plugin)
{ {
return plugin.getDescription().getName().equalsIgnoreCase("iconomy") return plugin.getDescription().getName().equalsIgnoreCase("iconomy")
@ -119,6 +133,7 @@ public class iCo4 implements Method
&& plugin instanceof iConomy; && plugin instanceof iConomy;
} }
@Override
public void setPlugin(Plugin plugin) public void setPlugin(Plugin plugin)
{ {
iConomy = (iConomy)plugin; iConomy = (iConomy)plugin;
@ -139,11 +154,13 @@ public class iCo4 implements Method
return account; return account;
} }
@Override
public double balance() public double balance()
{ {
return this.account.getBalance(); return this.account.getBalance();
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
if (this.account == null) if (this.account == null)
@ -154,6 +171,7 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
if (this.account == null) if (this.account == null)
@ -164,6 +182,7 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
if (this.account == null) if (this.account == null)
@ -174,6 +193,7 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
if (this.account == null) if (this.account == null)
@ -184,6 +204,7 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
if (this.account == null) if (this.account == null)
@ -194,26 +215,31 @@ public class iCo4 implements Method
return true; return true;
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return this.account.hasEnough(amount); return this.account.hasEnough(amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return this.account.hasOver(amount); return this.account.hasOver(amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return (this.balance() < amount); return (this.balance() < amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return this.account.isNegative(); return this.account.isNegative();
} }
@Override
public boolean remove() public boolean remove()
{ {
if (this.account == null) if (this.account == null)

View file

@ -22,51 +22,61 @@ public class iCo5 implements Method
{ {
private iConomy iConomy; private iConomy iConomy;
@Override
public iConomy getPlugin() public iConomy getPlugin()
{ {
return this.iConomy; return this.iConomy;
} }
@Override
public String getName() public String getName()
{ {
return "iConomy"; return "iConomy";
} }
@Override
public String getVersion() public String getVersion()
{ {
return "5"; return "5";
} }
@Override
public int fractionalDigits() public int fractionalDigits()
{ {
return 2; return 2;
} }
@Override
public String format(double amount) public String format(double amount)
{ {
return com.iConomy.iConomy.format(amount); return com.iConomy.iConomy.format(amount);
} }
@Override
public boolean hasBanks() public boolean hasBanks()
{ {
return Constants.Banking; return Constants.Banking;
} }
@Override
public boolean hasBank(String bank) public boolean hasBank(String bank)
{ {
return (hasBanks()) && com.iConomy.iConomy.Banks.exists(bank); return (hasBanks()) && com.iConomy.iConomy.Banks.exists(bank);
} }
@Override
public boolean hasAccount(String name) public boolean hasAccount(String name)
{ {
return com.iConomy.iConomy.hasAccount(name); return com.iConomy.iConomy.hasAccount(name);
} }
@Override
public boolean hasBankAccount(String bank, String name) public boolean hasBankAccount(String bank, String name)
{ {
return (hasBank(bank)) && com.iConomy.iConomy.getBank(bank).hasAccount(name); return (hasBank(bank)) && com.iConomy.iConomy.getBank(bank).hasAccount(name);
} }
@Override
public boolean createAccount(String name) public boolean createAccount(String name)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -77,6 +87,7 @@ public class iCo5 implements Method
return com.iConomy.iConomy.Accounts.create(name); return com.iConomy.iConomy.Accounts.create(name);
} }
@Override
public boolean createAccount(String name, Double balance) public boolean createAccount(String name, Double balance)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -94,16 +105,19 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public MethodAccount getAccount(String name) public MethodAccount getAccount(String name)
{ {
return new iCoAccount(com.iConomy.iConomy.getAccount(name)); return new iCoAccount(com.iConomy.iConomy.getAccount(name));
} }
@Override
public MethodBankAccount getBankAccount(String bank, String name) public MethodBankAccount getBankAccount(String bank, String name)
{ {
return new iCoBankAccount(com.iConomy.iConomy.getBank(bank).getAccount(name)); return new iCoBankAccount(com.iConomy.iConomy.getBank(bank).getAccount(name));
} }
@Override
public boolean isCompatible(Plugin plugin) public boolean isCompatible(Plugin plugin)
{ {
return plugin.getDescription().getName().equalsIgnoreCase("iconomy") return plugin.getDescription().getName().equalsIgnoreCase("iconomy")
@ -111,6 +125,7 @@ public class iCo5 implements Method
&& plugin instanceof iConomy; && plugin instanceof iConomy;
} }
@Override
public void setPlugin(Plugin plugin) public void setPlugin(Plugin plugin)
{ {
iConomy = (iConomy)plugin; iConomy = (iConomy)plugin;
@ -133,11 +148,13 @@ public class iCo5 implements Method
return account; return account;
} }
@Override
public double balance() public double balance()
{ {
return this.holdings.balance(); return this.holdings.balance();
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -148,6 +165,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -158,6 +176,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -168,6 +187,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -178,6 +198,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -188,26 +209,31 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return this.holdings.hasEnough(amount); return this.holdings.hasEnough(amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return this.holdings.hasOver(amount); return this.holdings.hasOver(amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return this.holdings.hasUnder(amount); return this.holdings.hasUnder(amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return this.holdings.isNegative(); return this.holdings.isNegative();
} }
@Override
public boolean remove() public boolean remove()
{ {
if (this.account == null) if (this.account == null)
@ -236,21 +262,25 @@ public class iCo5 implements Method
return account; return account;
} }
@Override
public String getBankName() public String getBankName()
{ {
return this.account.getBankName(); return this.account.getBankName();
} }
@Override
public int getBankId() public int getBankId()
{ {
return this.account.getBankId(); return this.account.getBankId();
} }
@Override
public double balance() public double balance()
{ {
return this.holdings.balance(); return this.holdings.balance();
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -261,6 +291,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -271,6 +302,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -281,6 +313,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -291,6 +324,7 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -301,26 +335,31 @@ public class iCo5 implements Method
return true; return true;
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return this.holdings.hasEnough(amount); return this.holdings.hasEnough(amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return this.holdings.hasOver(amount); return this.holdings.hasOver(amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return this.holdings.hasUnder(amount); return this.holdings.hasUnder(amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return this.holdings.isNegative(); return this.holdings.isNegative();
} }
@Override
public boolean remove() public boolean remove()
{ {
if (this.account == null) if (this.account == null)

View file

@ -21,51 +21,61 @@ public class iCo6 implements Method
{ {
private iConomy iConomy; private iConomy iConomy;
@Override
public iConomy getPlugin() public iConomy getPlugin()
{ {
return this.iConomy; return this.iConomy;
} }
@Override
public String getName() public String getName()
{ {
return "iConomy"; return "iConomy";
} }
@Override
public String getVersion() public String getVersion()
{ {
return "6"; return "6";
} }
@Override
public int fractionalDigits() public int fractionalDigits()
{ {
return 2; return 2;
} }
@Override
public String format(double amount) public String format(double amount)
{ {
return com.iCo6.iConomy.format(amount); return com.iCo6.iConomy.format(amount);
} }
@Override
public boolean hasBanks() public boolean hasBanks()
{ {
return false; return false;
} }
@Override
public boolean hasBank(String bank) public boolean hasBank(String bank)
{ {
return false; return false;
} }
@Override
public boolean hasAccount(String name) public boolean hasAccount(String name)
{ {
return (new Accounts()).exists(name); return (new Accounts()).exists(name);
} }
@Override
public boolean hasBankAccount(String bank, String name) public boolean hasBankAccount(String bank, String name)
{ {
return false; return false;
} }
@Override
public boolean createAccount(String name) public boolean createAccount(String name)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -76,6 +86,7 @@ public class iCo6 implements Method
return (new Accounts()).create(name); return (new Accounts()).create(name);
} }
@Override
public boolean createAccount(String name, Double balance) public boolean createAccount(String name, Double balance)
{ {
if (hasAccount(name)) if (hasAccount(name))
@ -86,16 +97,19 @@ public class iCo6 implements Method
return (new Accounts()).create(name, balance); return (new Accounts()).create(name, balance);
} }
@Override
public MethodAccount getAccount(String name) public MethodAccount getAccount(String name)
{ {
return new iCoAccount((new Accounts()).get(name)); return new iCoAccount((new Accounts()).get(name));
} }
@Override
public MethodBankAccount getBankAccount(String bank, String name) public MethodBankAccount getBankAccount(String bank, String name)
{ {
return null; return null;
} }
@Override
public boolean isCompatible(Plugin plugin) public boolean isCompatible(Plugin plugin)
{ {
return plugin.getDescription().getName().equalsIgnoreCase("iconomy") return plugin.getDescription().getName().equalsIgnoreCase("iconomy")
@ -103,6 +117,7 @@ public class iCo6 implements Method
&& plugin instanceof iConomy; && plugin instanceof iConomy;
} }
@Override
public void setPlugin(Plugin plugin) public void setPlugin(Plugin plugin)
{ {
iConomy = (iConomy)plugin; iConomy = (iConomy)plugin;
@ -125,11 +140,13 @@ public class iCo6 implements Method
return account; return account;
} }
@Override
public double balance() public double balance()
{ {
return this.holdings.getBalance(); return this.holdings.getBalance();
} }
@Override
public boolean set(double amount) public boolean set(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -140,6 +157,7 @@ public class iCo6 implements Method
return true; return true;
} }
@Override
public boolean add(double amount) public boolean add(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -150,6 +168,7 @@ public class iCo6 implements Method
return true; return true;
} }
@Override
public boolean subtract(double amount) public boolean subtract(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -160,6 +179,7 @@ public class iCo6 implements Method
return true; return true;
} }
@Override
public boolean multiply(double amount) public boolean multiply(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -170,6 +190,7 @@ public class iCo6 implements Method
return true; return true;
} }
@Override
public boolean divide(double amount) public boolean divide(double amount)
{ {
if (this.holdings == null) if (this.holdings == null)
@ -180,26 +201,31 @@ public class iCo6 implements Method
return true; return true;
} }
@Override
public boolean hasEnough(double amount) public boolean hasEnough(double amount)
{ {
return this.holdings.hasEnough(amount); return this.holdings.hasEnough(amount);
} }
@Override
public boolean hasOver(double amount) public boolean hasOver(double amount)
{ {
return this.holdings.hasOver(amount); return this.holdings.hasOver(amount);
} }
@Override
public boolean hasUnder(double amount) public boolean hasUnder(double amount)
{ {
return this.holdings.hasUnder(amount); return this.holdings.hasUnder(amount);
} }
@Override
public boolean isNegative() public boolean isNegative()
{ {
return this.holdings.isNegative(); return this.holdings.isNegative();
} }
@Override
public boolean remove() public boolean remove()
{ {
if (this.account == null) if (this.account == null)

View file

@ -422,24 +422,27 @@ public class EssentialsSign
this.block = event.getBlock(); this.block = event.getBlock();
} }
@Override
public final String getLine(final int index) public final String getLine(final int index)
{ {
return event.getLine(index); return event.getLine(index);
} }
@Override
public final void setLine(final int index, final String text) public final void setLine(final int index, final String text)
{ {
event.setLine(index, text); event.setLine(index, text);
} }
@Override
public Block getBlock() public Block getBlock()
{ {
return block; return block;
} }
@Override
public void updateSign() public void updateSign()
{ {
return;
} }
} }
@ -455,21 +458,25 @@ public class EssentialsSign
this.sign = (Sign)block.getState(); this.sign = (Sign)block.getState();
} }
@Override
public final String getLine(final int index) public final String getLine(final int index)
{ {
return sign.getLine(index); return sign.getLine(index);
} }
@Override
public final void setLine(final int index, final String text) public final void setLine(final int index, final String text)
{ {
sign.setLine(index, text); sign.setLine(index, text);
} }
@Override
public final Block getBlock() public final Block getBlock()
{ {
return block; return block;
} }
@Override
public final void updateSign() public final void updateSign()
{ {
sign.update(); sign.update();

View file

@ -89,16 +89,19 @@ public class TextInput implements IText
} }
} }
@Override
public List<String> getLines() public List<String> getLines()
{ {
return lines; return lines;
} }
@Override
public List<String> getChapters() public List<String> getChapters()
{ {
return chapters; return chapters;
} }
@Override
public Map<String, Integer> getBookmarks() public Map<String, Integer> getBookmarks()
{ {
return bookmarks; return bookmarks;