From f5d02b2807e48f4ddfd7cbce97de45823cc3269b Mon Sep 17 00:00:00 2001 From: Nick Date: Mon, 14 Mar 2016 18:55:44 -0700 Subject: [PATCH] Interface cleanup Specifying public in an interface is redundant. --- .../bloodmagic/api/iface/IUpgradeTrainer.java | 4 ++-- .../api/livingArmour/ILivingArmour.java | 21 +++++++++++-------- .../api/soul/IDemonWillConduit.java | 12 +++++------ .../bloodmagic/api/soul/IDemonWillGem.java | 16 +++++++------- .../bloodmagic/api/soul/IDemonWillWeapon.java | 2 +- .../bloodmagic/api/teleport/ITeleport.java | 4 ++-- .../routing/IInputItemRoutingNode.java | 4 ++-- .../routing/IMasterRoutingNode.java | 10 ++++----- .../routing/IOutputItemRoutingNode.java | 4 ++-- .../bloodmagic/routing/IRoutingNode.java | 18 ++++++++-------- 10 files changed, 49 insertions(+), 46 deletions(-) diff --git a/src/main/java/WayofTime/bloodmagic/api/iface/IUpgradeTrainer.java b/src/main/java/WayofTime/bloodmagic/api/iface/IUpgradeTrainer.java index db33f93b..26bfa051 100644 --- a/src/main/java/WayofTime/bloodmagic/api/iface/IUpgradeTrainer.java +++ b/src/main/java/WayofTime/bloodmagic/api/iface/IUpgradeTrainer.java @@ -10,7 +10,7 @@ import net.minecraft.item.ItemStack; */ public interface IUpgradeTrainer { - public List getTrainedUpgrades(ItemStack stack); + List getTrainedUpgrades(ItemStack stack); - public boolean setTrainedUpgrades(ItemStack stack, List keys); + boolean setTrainedUpgrades(ItemStack stack, List keys); } diff --git a/src/main/java/WayofTime/bloodmagic/api/livingArmour/ILivingArmour.java b/src/main/java/WayofTime/bloodmagic/api/livingArmour/ILivingArmour.java index d395d10a..ba052ed4 100644 --- a/src/main/java/WayofTime/bloodmagic/api/livingArmour/ILivingArmour.java +++ b/src/main/java/WayofTime/bloodmagic/api/livingArmour/ILivingArmour.java @@ -15,34 +15,37 @@ import com.google.common.collect.Multimap; */ public interface ILivingArmour { - public Multimap getAttributeModifiers(); + Multimap getAttributeModifiers(); - public boolean upgradeArmour(EntityPlayer user, LivingArmourUpgrade upgrade); + boolean upgradeArmour(EntityPlayer user, LivingArmourUpgrade upgrade); - public boolean removeUpgrade(EntityPlayer user, LivingArmourUpgrade upgrade); + boolean removeUpgrade(EntityPlayer user, LivingArmourUpgrade upgrade); - public void notifyPlayerOfUpgrade(EntityPlayer user, LivingArmourUpgrade upgrade); + void notifyPlayerOfUpgrade(EntityPlayer user, LivingArmourUpgrade upgrade); /** * Ticks the upgrades and stat trackers, passing in the world and player as * well as the LivingArmour * * @param world + * - The World * @param player + * - The player wearing the Armour */ - public void onTick(World world, EntityPlayer player); + void onTick(World world, EntityPlayer player); - public void readFromNBT(NBTTagCompound tag); + void readFromNBT(NBTTagCompound tag); - public void writeToNBT(NBTTagCompound tag, boolean forceWrite); + void writeToNBT(NBTTagCompound tag, boolean forceWrite); /** * Writes the LivingArmour to the NBTTag. This will only write the trackers * that are dirty. * * @param tag + * - The NBT tag to write to */ - public void writeDirtyToNBT(NBTTagCompound tag); + void writeDirtyToNBT(NBTTagCompound tag); - public void writeToNBT(NBTTagCompound tag); + void writeToNBT(NBTTagCompound tag); } diff --git a/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillConduit.java b/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillConduit.java index d5523ac4..3527af42 100644 --- a/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillConduit.java +++ b/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillConduit.java @@ -6,15 +6,15 @@ package WayofTime.bloodmagic.api.soul; */ public interface IDemonWillConduit { - public int getWeight(); + int getWeight(); - public double fillDemonWill(EnumDemonWillType type, double amount, boolean doFill); + double fillDemonWill(EnumDemonWillType type, double amount, boolean doFill); - public double drainDemonWill(EnumDemonWillType type, double amount, boolean doDrain); + double drainDemonWill(EnumDemonWillType type, double amount, boolean doDrain); - public boolean canFill(EnumDemonWillType type); + boolean canFill(EnumDemonWillType type); - public boolean canDrain(EnumDemonWillType type); + boolean canDrain(EnumDemonWillType type); - public double getCurrentWill(EnumDemonWillType type); + double getCurrentWill(EnumDemonWillType type); } diff --git a/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillGem.java b/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillGem.java index d88258f6..9f57e3f2 100644 --- a/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillGem.java +++ b/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillGem.java @@ -5,7 +5,7 @@ import net.minecraft.item.ItemStack; public interface IDemonWillGem { /** - * + * * @param willGemStack * - The ItemStack for this demon will gem. * @param willStack @@ -13,20 +13,20 @@ public interface IDemonWillGem * @return - The remainder willStack after the will has been absorbed into * the gem. Return null if there is no will left in the stack. */ - public ItemStack fillDemonWillGem(ItemStack willGemStack, ItemStack willStack); + ItemStack fillDemonWillGem(ItemStack willGemStack, ItemStack willStack); /** * Returns the number of souls that are left in the soul gem. Returns a * double because souls can be fractionally drained. - * + * */ - public double getWill(EnumDemonWillType type, ItemStack willGemStack); + double getWill(EnumDemonWillType type, ItemStack willGemStack); - public void setWill(EnumDemonWillType type, ItemStack willGemStack, double amount); + void setWill(EnumDemonWillType type, ItemStack willGemStack, double amount); - public int getMaxWill(EnumDemonWillType type, ItemStack willGemStack); + int getMaxWill(EnumDemonWillType type, ItemStack willGemStack); - public double drainWill(EnumDemonWillType type, ItemStack stack, double drainAmount); + double drainWill(EnumDemonWillType type, ItemStack stack, double drainAmount); - public double fillWill(EnumDemonWillType type, ItemStack stack, double fillAmount); + double fillWill(EnumDemonWillType type, ItemStack stack, double fillAmount); } diff --git a/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillWeapon.java b/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillWeapon.java index fa75dd6f..3a0a5032 100644 --- a/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillWeapon.java +++ b/src/main/java/WayofTime/bloodmagic/api/soul/IDemonWillWeapon.java @@ -7,5 +7,5 @@ import net.minecraft.item.ItemStack; public interface IDemonWillWeapon { - public List getRandomDemonWillDrop(EntityLivingBase killedEntity, EntityLivingBase attackingEntity, ItemStack stack, int looting); + List getRandomDemonWillDrop(EntityLivingBase killedEntity, EntityLivingBase attackingEntity, ItemStack stack, int looting); } diff --git a/src/main/java/WayofTime/bloodmagic/api/teleport/ITeleport.java b/src/main/java/WayofTime/bloodmagic/api/teleport/ITeleport.java index 0e74e7f7..f9e48986 100644 --- a/src/main/java/WayofTime/bloodmagic/api/teleport/ITeleport.java +++ b/src/main/java/WayofTime/bloodmagic/api/teleport/ITeleport.java @@ -2,7 +2,7 @@ package WayofTime.bloodmagic.api.teleport; public interface ITeleport { - public void teleport(); + void teleport(); - public int getTeleportCost(); + int getTeleportCost(); } diff --git a/src/main/java/WayofTime/bloodmagic/routing/IInputItemRoutingNode.java b/src/main/java/WayofTime/bloodmagic/routing/IInputItemRoutingNode.java index 04e9ad7f..b61db904 100644 --- a/src/main/java/WayofTime/bloodmagic/routing/IInputItemRoutingNode.java +++ b/src/main/java/WayofTime/bloodmagic/routing/IInputItemRoutingNode.java @@ -4,7 +4,7 @@ import net.minecraft.util.EnumFacing; public interface IInputItemRoutingNode extends IItemRoutingNode { - public boolean isInput(EnumFacing side); + boolean isInput(EnumFacing side); - public IItemFilter getInputFilterForSide(EnumFacing side); + IItemFilter getInputFilterForSide(EnumFacing side); } diff --git a/src/main/java/WayofTime/bloodmagic/routing/IMasterRoutingNode.java b/src/main/java/WayofTime/bloodmagic/routing/IMasterRoutingNode.java index 0b32c3dc..0adcd53e 100644 --- a/src/main/java/WayofTime/bloodmagic/routing/IMasterRoutingNode.java +++ b/src/main/java/WayofTime/bloodmagic/routing/IMasterRoutingNode.java @@ -6,13 +6,13 @@ import net.minecraft.util.BlockPos; public interface IMasterRoutingNode extends IRoutingNode { - public boolean isConnected(List path, BlockPos nodePos); + boolean isConnected(List path, BlockPos nodePos); - public void addNodeToList(IRoutingNode node); + void addNodeToList(IRoutingNode node); - public void addConnections(BlockPos pos, List connectionList); + void addConnections(BlockPos pos, List connectionList); - public void addConnection(BlockPos pos1, BlockPos pos2); + void addConnection(BlockPos pos1, BlockPos pos2); - public void removeConnection(BlockPos pos1, BlockPos pos2); + void removeConnection(BlockPos pos1, BlockPos pos2); } diff --git a/src/main/java/WayofTime/bloodmagic/routing/IOutputItemRoutingNode.java b/src/main/java/WayofTime/bloodmagic/routing/IOutputItemRoutingNode.java index 327eb842..091cebd2 100644 --- a/src/main/java/WayofTime/bloodmagic/routing/IOutputItemRoutingNode.java +++ b/src/main/java/WayofTime/bloodmagic/routing/IOutputItemRoutingNode.java @@ -4,7 +4,7 @@ import net.minecraft.util.EnumFacing; public interface IOutputItemRoutingNode extends IItemRoutingNode { - public boolean isOutput(EnumFacing side); + boolean isOutput(EnumFacing side); - public IItemFilter getOutputFilterForSide(EnumFacing side); + IItemFilter getOutputFilterForSide(EnumFacing side); } diff --git a/src/main/java/WayofTime/bloodmagic/routing/IRoutingNode.java b/src/main/java/WayofTime/bloodmagic/routing/IRoutingNode.java index 3fe0a449..8a8df054 100644 --- a/src/main/java/WayofTime/bloodmagic/routing/IRoutingNode.java +++ b/src/main/java/WayofTime/bloodmagic/routing/IRoutingNode.java @@ -7,21 +7,21 @@ import net.minecraft.world.World; public interface IRoutingNode { - public void connectMasterToRemainingNode(World world, List alreadyChecked, IMasterRoutingNode master); + void connectMasterToRemainingNode(World world, List alreadyChecked, IMasterRoutingNode master); - public BlockPos getBlockPos(); + BlockPos getBlockPos(); - public List getConnected(); + List getConnected(); - public BlockPos getMasterPos(); + BlockPos getMasterPos(); - public boolean isConnectionEnabled(BlockPos testPos); + boolean isConnectionEnabled(BlockPos testPos); - public boolean isMaster(IMasterRoutingNode master); + boolean isMaster(IMasterRoutingNode master); - public void addConnection(BlockPos pos1); + void addConnection(BlockPos pos1); - public void removeConnection(BlockPos pos1); + void removeConnection(BlockPos pos1); - public void removeAllConnections(); + void removeAllConnections(); }