diff --git a/paper-api/checkstyle.xml b/paper-api/checkstyle.xml
new file mode 100644
index 0000000000..8372bb7140
--- /dev/null
+++ b/paper-api/checkstyle.xml
@@ -0,0 +1,36 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/paper-api/pom.xml b/paper-api/pom.xml
index 051eafb8a4..b5c6f250c7 100644
--- a/paper-api/pom.xml
+++ b/paper-api/pom.xml
@@ -164,6 +164,30 @@
+
+ org.apache.maven.plugins
+ maven-checkstyle-plugin
+ 3.0.0
+
+
+ validate
+
+ check
+
+
+
+
+ checkstyle.xml
+ true
+
+
+
+ com.puppycrawl.tools
+ checkstyle
+ 8.19
+
+
+ org.codehaus.mojoanimal-sniffer-maven-plugin
diff --git a/paper-api/src/main/java/org/bukkit/Achievement.java b/paper-api/src/main/java/org/bukkit/Achievement.java
index edc388ffe1..0080e0fea2 100644
--- a/paper-api/src/main/java/org/bukkit/Achievement.java
+++ b/paper-api/src/main/java/org/bukkit/Achievement.java
@@ -56,7 +56,7 @@ public enum Achievement {
/**
* Returns whether or not this achievement has a parent achievement.
- *
+ *
* @return whether the achievement has a parent achievement
*/
public boolean hasParent() {
@@ -65,7 +65,7 @@ public enum Achievement {
/**
* Returns the parent achievement of this achievement, or null if none.
- *
+ *
* @return the parent achievement or null
*/
@Nullable
diff --git a/paper-api/src/main/java/org/bukkit/Bukkit.java b/paper-api/src/main/java/org/bukkit/Bukkit.java
index beca3b4954..b47cc31d80 100644
--- a/paper-api/src/main/java/org/bukkit/Bukkit.java
+++ b/paper-api/src/main/java/org/bukkit/Bukkit.java
@@ -1210,12 +1210,12 @@ public final class Bukkit {
/**
* Create a ChunkData for use in a generator.
- *
+ *
* See {@link ChunkGenerator#generateChunkData(org.bukkit.World, java.util.Random, int, int, org.bukkit.generator.ChunkGenerator.BiomeGrid)}
- *
+ *
* @param world the world to create the ChunkData for
* @return a new ChunkData for the world
- *
+ *
*/
@NotNull
public static ChunkGenerator.ChunkData createChunkData(@NotNull World world) {
diff --git a/paper-api/src/main/java/org/bukkit/ChatColor.java b/paper-api/src/main/java/org/bukkit/ChatColor.java
index de1c60a2f3..b8f4fcabf5 100644
--- a/paper-api/src/main/java/org/bukkit/ChatColor.java
+++ b/paper-api/src/main/java/org/bukkit/ChatColor.java
@@ -114,8 +114,8 @@ public enum ChatColor {
private final char code;
private final boolean isFormat;
private final String toString;
- private final static Map BY_ID = Maps.newHashMap();
- private final static Map BY_CHAR = Maps.newHashMap();
+ private static final Map BY_ID = Maps.newHashMap();
+ private static final Map BY_CHAR = Maps.newHashMap();
private ChatColor(char code, int intCode) {
this(code, intCode, false);
@@ -145,7 +145,7 @@ public enum ChatColor {
/**
* Checks if this code is a format code as opposed to a color code.
- *
+ *
* @return whether this ChatColor is a format code
*/
public boolean isFormat() {
@@ -154,7 +154,7 @@ public enum ChatColor {
/**
* Checks if this code is a color code as opposed to a format code.
- *
+ *
* @return whether this ChatColor is a color code
*/
public boolean isColor() {
diff --git a/paper-api/src/main/java/org/bukkit/CoalType.java b/paper-api/src/main/java/org/bukkit/CoalType.java
index 9e59a7ba18..c9fcc5dd48 100644
--- a/paper-api/src/main/java/org/bukkit/CoalType.java
+++ b/paper-api/src/main/java/org/bukkit/CoalType.java
@@ -13,7 +13,7 @@ public enum CoalType {
CHARCOAL(0x1);
private final byte data;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
private CoalType(final int data) {
this.data = (byte) data;
diff --git a/paper-api/src/main/java/org/bukkit/CropState.java b/paper-api/src/main/java/org/bukkit/CropState.java
index 9a3990dff7..8a9a36cf40 100644
--- a/paper-api/src/main/java/org/bukkit/CropState.java
+++ b/paper-api/src/main/java/org/bukkit/CropState.java
@@ -44,7 +44,7 @@ public enum CropState {
RIPE(0x7);
private final byte data;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
private CropState(final int data) {
this.data = (byte) data;
diff --git a/paper-api/src/main/java/org/bukkit/Difficulty.java b/paper-api/src/main/java/org/bukkit/Difficulty.java
index 19367a7001..9568207796 100644
--- a/paper-api/src/main/java/org/bukkit/Difficulty.java
+++ b/paper-api/src/main/java/org/bukkit/Difficulty.java
@@ -35,7 +35,7 @@ public enum Difficulty {
HARD(3);
private final int value;
- private final static Map BY_ID = Maps.newHashMap();
+ private static final Map BY_ID = Maps.newHashMap();
private Difficulty(final int value) {
this.value = value;
diff --git a/paper-api/src/main/java/org/bukkit/DyeColor.java b/paper-api/src/main/java/org/bukkit/DyeColor.java
index ac75be6577..d00c8f9135 100644
--- a/paper-api/src/main/java/org/bukkit/DyeColor.java
+++ b/paper-api/src/main/java/org/bukkit/DyeColor.java
@@ -80,10 +80,10 @@ public enum DyeColor {
private final byte dyeData;
private final Color color;
private final Color firework;
- private final static DyeColor[] BY_WOOL_DATA;
- private final static DyeColor[] BY_DYE_DATA;
- private final static Map BY_COLOR;
- private final static Map BY_FIREWORK;
+ private static final DyeColor[] BY_WOOL_DATA;
+ private static final DyeColor[] BY_DYE_DATA;
+ private static final Map BY_COLOR;
+ private static final Map BY_FIREWORK;
private DyeColor(final int woolData, final int dyeData, /*@NotNull*/ Color color, /*@NotNull*/ Color firework) {
this.woolData = (byte) woolData;
diff --git a/paper-api/src/main/java/org/bukkit/EntityEffect.java b/paper-api/src/main/java/org/bukkit/EntityEffect.java
index b7576f6811..c201a54b1b 100644
--- a/paper-api/src/main/java/org/bukkit/EntityEffect.java
+++ b/paper-api/src/main/java/org/bukkit/EntityEffect.java
@@ -153,7 +153,7 @@ public enum EntityEffect {
private final byte data;
private final Class extends Entity> applicable;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
EntityEffect(final int data, /*@NotNull*/ Class extends Entity> clazz) {
this.data = (byte) data;
diff --git a/paper-api/src/main/java/org/bukkit/GameMode.java b/paper-api/src/main/java/org/bukkit/GameMode.java
index 4cfc7762e4..168c4dc8eb 100644
--- a/paper-api/src/main/java/org/bukkit/GameMode.java
+++ b/paper-api/src/main/java/org/bukkit/GameMode.java
@@ -29,14 +29,14 @@ public enum GameMode {
ADVENTURE(2),
/**
- * Spectator mode cannot interact with the world in anyway and is
- * invisible to normal players. This grants the player the
+ * Spectator mode cannot interact with the world in anyway and is
+ * invisible to normal players. This grants the player the
* ability to no-clip through the world.
*/
SPECTATOR(3);
private final int value;
- private final static Map BY_ID = Maps.newHashMap();
+ private static final Map BY_ID = Maps.newHashMap();
private GameMode(final int value) {
this.value = value;
diff --git a/paper-api/src/main/java/org/bukkit/GrassSpecies.java b/paper-api/src/main/java/org/bukkit/GrassSpecies.java
index 5943eddd31..c178847e4e 100644
--- a/paper-api/src/main/java/org/bukkit/GrassSpecies.java
+++ b/paper-api/src/main/java/org/bukkit/GrassSpecies.java
@@ -24,7 +24,7 @@ public enum GrassSpecies {
FERN_LIKE(0x2);
private final byte data;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
private GrassSpecies(final int data) {
this.data = (byte) data;
diff --git a/paper-api/src/main/java/org/bukkit/Instrument.java b/paper-api/src/main/java/org/bukkit/Instrument.java
index ad9bfb577b..2a6dd05c1a 100644
--- a/paper-api/src/main/java/org/bukkit/Instrument.java
+++ b/paper-api/src/main/java/org/bukkit/Instrument.java
@@ -78,7 +78,7 @@ public enum Instrument {
PLING(0xF);
private final byte type;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
private Instrument(final int type) {
this.type = (byte) type;
diff --git a/paper-api/src/main/java/org/bukkit/Location.java b/paper-api/src/main/java/org/bukkit/Location.java
index f55ff74286..19b23e8ec9 100644
--- a/paper-api/src/main/java/org/bukkit/Location.java
+++ b/paper-api/src/main/java/org/bukkit/Location.java
@@ -275,7 +275,7 @@ public class Location implements Cloneable, ConfigurationSerializable {
/**
* Sets the {@link #getYaw() yaw} and {@link #getPitch() pitch} to point
* in the direction of the vector.
- *
+ *
* @param vector the direction vector
* @return the same location
*/
diff --git a/paper-api/src/main/java/org/bukkit/Material.java b/paper-api/src/main/java/org/bukkit/Material.java
index c4f7dc98fa..bafc41ecf2 100644
--- a/paper-api/src/main/java/org/bukkit/Material.java
+++ b/paper-api/src/main/java/org/bukkit/Material.java
@@ -3243,7 +3243,7 @@ public enum Material implements Keyed {
private final int id;
private final Constructor extends MaterialData> ctor;
- private final static Map BY_NAME = Maps.newHashMap();
+ private static final Map BY_NAME = Maps.newHashMap();
private final int maxStack;
private final short durability;
public final Class> data;
diff --git a/paper-api/src/main/java/org/bukkit/Registry.java b/paper-api/src/main/java/org/bukkit/Registry.java
index e1d0252bff..433bf79d82 100644
--- a/paper-api/src/main/java/org/bukkit/Registry.java
+++ b/paper-api/src/main/java/org/bukkit/Registry.java
@@ -126,7 +126,7 @@ public interface Registry extends Iterable {
@Nullable
T get(@NotNull NamespacedKey key);
- final static class SimpleRegistry & Keyed> implements Registry {
+ static final class SimpleRegistry & Keyed> implements Registry {
private final Map map;
diff --git a/paper-api/src/main/java/org/bukkit/SandstoneType.java b/paper-api/src/main/java/org/bukkit/SandstoneType.java
index 3b3a4a7cc8..8f859ac10a 100644
--- a/paper-api/src/main/java/org/bukkit/SandstoneType.java
+++ b/paper-api/src/main/java/org/bukkit/SandstoneType.java
@@ -14,7 +14,7 @@ public enum SandstoneType {
SMOOTH(0x2);
private final byte data;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
private SandstoneType(final int data) {
this.data = (byte) data;
diff --git a/paper-api/src/main/java/org/bukkit/Server.java b/paper-api/src/main/java/org/bukkit/Server.java
index f3aa7aef83..c7e64545cf 100644
--- a/paper-api/src/main/java/org/bukkit/Server.java
+++ b/paper-api/src/main/java/org/bukkit/Server.java
@@ -1009,12 +1009,12 @@ public interface Server extends PluginMessageRecipient {
/**
* Create a ChunkData for use in a generator.
- *
+ *
* See {@link ChunkGenerator#generateChunkData(org.bukkit.World, java.util.Random, int, int, org.bukkit.generator.ChunkGenerator.BiomeGrid)}
- *
+ *
* @param world the world to create the ChunkData for
* @return a new ChunkData for the world
- *
+ *
*/
@NotNull
public ChunkGenerator.ChunkData createChunkData(@NotNull World world);
diff --git a/paper-api/src/main/java/org/bukkit/StructureType.java b/paper-api/src/main/java/org/bukkit/StructureType.java
index a99c811514..5c2e69772e 100644
--- a/paper-api/src/main/java/org/bukkit/StructureType.java
+++ b/paper-api/src/main/java/org/bukkit/StructureType.java
@@ -20,7 +20,7 @@ import java.util.Objects;
* The registration of new {@link StructureType}s is case-sensitive.
*/
// Order is retrieved from WorldGenFactory
-public class StructureType {
+public final class StructureType {
private static final Map structureTypeMap = new HashMap<>();
diff --git a/paper-api/src/main/java/org/bukkit/TreeSpecies.java b/paper-api/src/main/java/org/bukkit/TreeSpecies.java
index a18e23a4dc..d3a15d1983 100644
--- a/paper-api/src/main/java/org/bukkit/TreeSpecies.java
+++ b/paper-api/src/main/java/org/bukkit/TreeSpecies.java
@@ -37,7 +37,7 @@ public enum TreeSpecies {
;
private final byte data;
- private final static Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
private TreeSpecies(final int data) {
this.data = (byte) data;
diff --git a/paper-api/src/main/java/org/bukkit/World.java b/paper-api/src/main/java/org/bukkit/World.java
index 3abeab0923..28cc16199d 100644
--- a/paper-api/src/main/java/org/bukkit/World.java
+++ b/paper-api/src/main/java/org/bukkit/World.java
@@ -264,7 +264,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
* @param x X-coordinate of the chunk
* @param z Z-coordinate of the chunk
* @return Whether the chunk was actually refreshed
- *
+ *
* @deprecated This method is not guaranteed to work suitably across all client implementations.
*/
@Deprecated
@@ -431,7 +431,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
/**
* Get a collection of all entities in this World matching the given
* class/interface
- *
+ *
* @param an entity subclass
* @param cls The class representing the type of entity to match
* @return A List of all Entities currently residing in this world that
@@ -1378,7 +1378,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
*
* Note: If set to a negative number the world will use the
* server-wide spawn limit instead.
- *
+ *
* @param limit the new mob limit
*/
void setMonsterSpawnLimit(int limit);
@@ -1397,7 +1397,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
*
* Note: If set to a negative number the world will use the
* server-wide spawn limit instead.
- *
+ *
* @param limit the new mob limit
*/
void setAnimalSpawnLimit(int limit);
@@ -1416,7 +1416,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
*
* Note: If set to a negative number the world will use the
* server-wide spawn limit instead.
- *
+ *
* @param limit the new mob limit
*/
void setWaterAnimalSpawnLimit(int limit);
@@ -1435,7 +1435,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
*
* Note: If set to a negative number the world will use the
* server-wide spawn limit instead.
- *
+ *
* @param limit the new mob limit
*/
void setAmbientSpawnLimit(int limit);
diff --git a/paper-api/src/main/java/org/bukkit/WorldType.java b/paper-api/src/main/java/org/bukkit/WorldType.java
index e82fe0767a..8052a49c79 100644
--- a/paper-api/src/main/java/org/bukkit/WorldType.java
+++ b/paper-api/src/main/java/org/bukkit/WorldType.java
@@ -18,7 +18,7 @@ public enum WorldType {
CUSTOMIZED("CUSTOMIZED"),
BUFFET("BUFFET");
- private final static Map BY_NAME = Maps.newHashMap();
+ private static final Map BY_NAME = Maps.newHashMap();
private final String name;
private WorldType(/*@NotNull*/ String name) {
diff --git a/paper-api/src/main/java/org/bukkit/block/Block.java b/paper-api/src/main/java/org/bukkit/block/Block.java
index c88088c0fe..323767d621 100644
--- a/paper-api/src/main/java/org/bukkit/block/Block.java
+++ b/paper-api/src/main/java/org/bukkit/block/Block.java
@@ -241,7 +241,7 @@ public interface Block extends Metadatable {
/**
* Gets the face relation of this block compared to the given block.
*
- * For example:
+ * For example:
*
{@code
* Block current = world.getBlockAt(100, 100, 100);
* Block target = world.getBlockAt(100, 101, 100);
diff --git a/paper-api/src/main/java/org/bukkit/block/Dropper.java b/paper-api/src/main/java/org/bukkit/block/Dropper.java
index d68401b736..424392fb5e 100644
--- a/paper-api/src/main/java/org/bukkit/block/Dropper.java
+++ b/paper-api/src/main/java/org/bukkit/block/Dropper.java
@@ -14,7 +14,7 @@ public interface Dropper extends Container, Lootable {
* Normal behavior of a dropper is as follows:
*
* If the block that the dropper is facing is an InventoryHolder,
- * the randomly selected ItemStack is placed within that
+ * the randomly selected ItemStack is placed within that
* Inventory in the first slot that's available, starting with 0 and
* counting up. If the inventory is full, nothing happens.
*
* If the block represented by this state is no longer a dropper, this will
* do nothing.
- *
+ *
* @throws IllegalStateException if this block state is not placed
*/
public void drop();
diff --git a/paper-api/src/main/java/org/bukkit/block/EndGateway.java b/paper-api/src/main/java/org/bukkit/block/EndGateway.java
index e737f2db20..4cf5be6ee8 100644
--- a/paper-api/src/main/java/org/bukkit/block/EndGateway.java
+++ b/paper-api/src/main/java/org/bukkit/block/EndGateway.java
@@ -9,11 +9,11 @@ import org.jetbrains.annotations.Nullable;
public interface EndGateway extends BlockState {
/**
- * Gets the location that entities are teleported to when
+ * Gets the location that entities are teleported to when
* entering the gateway portal.
*
* If this block state is not placed the location's world will be null.
- *
+ *
* @return the gateway exit location
*/
@Nullable
@@ -24,7 +24,7 @@ public interface EndGateway extends BlockState {
* they enter the gateway portal.
*
* If this block state is not placed the location's world has to be null.
- *
+ *
* @param location the new exit location
* @throws IllegalArgumentException for differing worlds
*/
@@ -33,7 +33,7 @@ public interface EndGateway extends BlockState {
/**
* Gets whether this gateway will teleport entities directly to
* the exit location instead of finding a nearby location.
- *
+ *
* @return true if the gateway is teleporting to the exact location
*/
boolean isExactTeleport();
@@ -41,7 +41,7 @@ public interface EndGateway extends BlockState {
/**
* Sets whether this gateway will teleport entities directly to
* the exit location instead of finding a nearby location.
- *
+ *
* @param exact whether to teleport to the exact location
*/
void setExactTeleport(boolean exact);
diff --git a/paper-api/src/main/java/org/bukkit/command/TabCompleter.java b/paper-api/src/main/java/org/bukkit/command/TabCompleter.java
index 04c0e87495..80127fda31 100644
--- a/paper-api/src/main/java/org/bukkit/command/TabCompleter.java
+++ b/paper-api/src/main/java/org/bukkit/command/TabCompleter.java
@@ -15,7 +15,7 @@ public interface TabCompleter {
*
* @param sender Source of the command. For players tab-completing a
* command inside of a command block, this will be the player, not
- * the command block.
+ * the command block.
* @param command Command which was executed
* @param alias The alias used
* @param args The arguments passed to the command, including final
diff --git a/paper-api/src/main/java/org/bukkit/configuration/file/FileConfiguration.java b/paper-api/src/main/java/org/bukkit/configuration/file/FileConfiguration.java
index ba3c93fe48..82746d71f7 100644
--- a/paper-api/src/main/java/org/bukkit/configuration/file/FileConfiguration.java
+++ b/paper-api/src/main/java/org/bukkit/configuration/file/FileConfiguration.java
@@ -226,4 +226,4 @@ public abstract class FileConfiguration extends MemoryConfiguration {
return (FileConfigurationOptions) options;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/conversations/ExactMatchConversationCanceller.java b/paper-api/src/main/java/org/bukkit/conversations/ExactMatchConversationCanceller.java
index 9a30914b60..2eeae26b36 100644
--- a/paper-api/src/main/java/org/bukkit/conversations/ExactMatchConversationCanceller.java
+++ b/paper-api/src/main/java/org/bukkit/conversations/ExactMatchConversationCanceller.java
@@ -18,7 +18,7 @@ public class ExactMatchConversationCanceller implements ConversationCanceller {
public ExactMatchConversationCanceller(@NotNull String escapeSequence) {
this.escapeSequence = escapeSequence;
}
-
+
public void setConversation(@NotNull Conversation conversation) {}
public boolean cancelBasedOnInput(@NotNull ConversationContext context, @NotNull String input) {
diff --git a/paper-api/src/main/java/org/bukkit/conversations/FixedSetPrompt.java b/paper-api/src/main/java/org/bukkit/conversations/FixedSetPrompt.java
index a1dd102856..bd3a8b400a 100644
--- a/paper-api/src/main/java/org/bukkit/conversations/FixedSetPrompt.java
+++ b/paper-api/src/main/java/org/bukkit/conversations/FixedSetPrompt.java
@@ -12,7 +12,7 @@ import java.util.List;
* response from the user.
*/
public abstract class FixedSetPrompt extends ValidatingPrompt {
-
+
protected List fixedSet;
/**
diff --git a/paper-api/src/main/java/org/bukkit/conversations/PluginNameConversationPrefix.java b/paper-api/src/main/java/org/bukkit/conversations/PluginNameConversationPrefix.java
index ed1f3b6860..28443b6abe 100644
--- a/paper-api/src/main/java/org/bukkit/conversations/PluginNameConversationPrefix.java
+++ b/paper-api/src/main/java/org/bukkit/conversations/PluginNameConversationPrefix.java
@@ -9,17 +9,17 @@ import org.jetbrains.annotations.NotNull;
* that displays the plugin name in front of conversation output.
*/
public class PluginNameConversationPrefix implements ConversationPrefix {
-
+
protected String separator;
protected ChatColor prefixColor;
protected Plugin plugin;
-
+
private String cachedPrefix;
-
+
public PluginNameConversationPrefix(@NotNull Plugin plugin) {
this(plugin, " > ", ChatColor.LIGHT_PURPLE);
}
-
+
public PluginNameConversationPrefix(@NotNull Plugin plugin, @NotNull String separator, @NotNull ChatColor prefixColor) {
this.separator = separator;
this.prefixColor = prefixColor;
diff --git a/paper-api/src/main/java/org/bukkit/entity/Ageable.java b/paper-api/src/main/java/org/bukkit/entity/Ageable.java
index e9fccb294a..3756a97301 100644
--- a/paper-api/src/main/java/org/bukkit/entity/Ageable.java
+++ b/paper-api/src/main/java/org/bukkit/entity/Ageable.java
@@ -3,7 +3,7 @@ package org.bukkit.entity;
/**
* Represents an entity that can age and breed.
*/
-public interface Ageable extends Creature {
+public interface Ageable extends Creature {
/**
* Gets the age of this animal.
*
@@ -49,7 +49,7 @@ public interface Ageable extends Creature {
* @return return true if the animal is an adult
*/
public boolean isAdult();
-
+
/**
* Return the ability to breed of the animal.
*
diff --git a/paper-api/src/main/java/org/bukkit/entity/AreaEffectCloud.java b/paper-api/src/main/java/org/bukkit/entity/AreaEffectCloud.java
index d258e734ec..290aff2831 100644
--- a/paper-api/src/main/java/org/bukkit/entity/AreaEffectCloud.java
+++ b/paper-api/src/main/java/org/bukkit/entity/AreaEffectCloud.java
@@ -226,7 +226,7 @@ public interface AreaEffectCloud extends Entity {
/**
* Retrieve the original source of this cloud.
- *
+ *
* @return the {@link ProjectileSource} that threw the LingeringPotion
*/
@Nullable
diff --git a/paper-api/src/main/java/org/bukkit/entity/Boat.java b/paper-api/src/main/java/org/bukkit/entity/Boat.java
index 00001621b4..24751b5c4e 100644
--- a/paper-api/src/main/java/org/bukkit/entity/Boat.java
+++ b/paper-api/src/main/java/org/bukkit/entity/Boat.java
@@ -10,7 +10,7 @@ public interface Boat extends Vehicle {
/**
* Gets the wood type of the boat.
- *
+ *
* @return the wood type
*/
@NotNull
@@ -18,7 +18,7 @@ public interface Boat extends Vehicle {
/**
* Sets the wood type of the boat.
- *
+ *
* @param species the new wood type
*/
void setWoodType(@NotNull TreeSpecies species);
diff --git a/paper-api/src/main/java/org/bukkit/entity/Creeper.java b/paper-api/src/main/java/org/bukkit/entity/Creeper.java
index f957d83684..32f18a3ae4 100644
--- a/paper-api/src/main/java/org/bukkit/entity/Creeper.java
+++ b/paper-api/src/main/java/org/bukkit/entity/Creeper.java
@@ -20,8 +20,8 @@ public interface Creeper extends Monster {
public void setPowered(boolean value);
/**
- * Set the maximum fuse ticks for this Creeper, where the maximum ticks
- * is the amount of time in which a creeper is allowed to be in the
+ * Set the maximum fuse ticks for this Creeper, where the maximum ticks
+ * is the amount of time in which a creeper is allowed to be in the
* primed state before exploding.
*
* @param ticks the new maximum fuse ticks
@@ -29,8 +29,8 @@ public interface Creeper extends Monster {
public void setMaxFuseTicks(int ticks);
/**
- * Get the maximum fuse ticks for this Creeper, where the maximum ticks
- * is the amount of time in which a creeper is allowed to be in the
+ * Get the maximum fuse ticks for this Creeper, where the maximum ticks
+ * is the amount of time in which a creeper is allowed to be in the
* primed state before exploding.
*
* @return the maximum fuse ticks
diff --git a/paper-api/src/main/java/org/bukkit/entity/EnderDragon.java b/paper-api/src/main/java/org/bukkit/entity/EnderDragon.java
index fa13b38d36..16199b3e90 100644
--- a/paper-api/src/main/java/org/bukkit/entity/EnderDragon.java
+++ b/paper-api/src/main/java/org/bukkit/entity/EnderDragon.java
@@ -41,8 +41,8 @@ public interface EnderDragon extends ComplexLivingEntity, Boss {
BREATH_ATTACK,
/**
* The dragon will search for a player to attack with dragon breath.
- * If no player is close enough to the dragon for 5 seconds, the
- * dragon will charge at a player within 150 blocks or will take off
+ * If no player is close enough to the dragon for 5 seconds, the
+ * dragon will charge at a player within 150 blocks or will take off
* and begin circling if no player is found.
*/
SEARCH_FOR_BREATH_ATTACK_TARGET,
diff --git a/paper-api/src/main/java/org/bukkit/entity/EntityType.java b/paper-api/src/main/java/org/bukkit/entity/EntityType.java
index ea342b2810..3873503032 100644
--- a/paper-api/src/main/java/org/bukkit/entity/EntityType.java
+++ b/paper-api/src/main/java/org/bukkit/entity/EntityType.java
@@ -350,7 +350,7 @@ public enum EntityType implements Keyed {
/**
*
- * @return the raw type id
+ * @return the raw type id
* @deprecated Magic value
*/
@Deprecated
diff --git a/paper-api/src/main/java/org/bukkit/entity/Golem.java b/paper-api/src/main/java/org/bukkit/entity/Golem.java
index 4165977e78..4b43c36316 100644
--- a/paper-api/src/main/java/org/bukkit/entity/Golem.java
+++ b/paper-api/src/main/java/org/bukkit/entity/Golem.java
@@ -4,5 +4,5 @@ package org.bukkit.entity;
* A mechanical creature that may harm enemies.
*/
public interface Golem extends Creature {
-
+
}
diff --git a/paper-api/src/main/java/org/bukkit/entity/Guardian.java b/paper-api/src/main/java/org/bukkit/entity/Guardian.java
index 98af0563c6..5d9698dc65 100644
--- a/paper-api/src/main/java/org/bukkit/entity/Guardian.java
+++ b/paper-api/src/main/java/org/bukkit/entity/Guardian.java
@@ -4,7 +4,7 @@ public interface Guardian extends Monster {
/**
* Check if the Guardian is an elder Guardian
- *
+ *
* @return true if the Guardian is an Elder Guardian, false if not
* @deprecated should check if instance of {@link ElderGuardian}.
*/
diff --git a/paper-api/src/main/java/org/bukkit/entity/Minecart.java b/paper-api/src/main/java/org/bukkit/entity/Minecart.java
index 5a07493ad8..95c79c5fa0 100644
--- a/paper-api/src/main/java/org/bukkit/entity/Minecart.java
+++ b/paper-api/src/main/java/org/bukkit/entity/Minecart.java
@@ -139,7 +139,7 @@ public interface Minecart extends Vehicle {
/**
* Gets the offset of the display block.
- *
+ *
* @return the current block offset for this minecart.
*/
public int getDisplayBlockOffset();
diff --git a/paper-api/src/main/java/org/bukkit/entity/SpectralArrow.java b/paper-api/src/main/java/org/bukkit/entity/SpectralArrow.java
index 1a32341c3f..274c7304aa 100644
--- a/paper-api/src/main/java/org/bukkit/entity/SpectralArrow.java
+++ b/paper-api/src/main/java/org/bukkit/entity/SpectralArrow.java
@@ -8,14 +8,14 @@ public interface SpectralArrow extends Arrow {
/**
* Returns the amount of time that this arrow will apply
* the glowing effect for.
- *
+ *
* @return the glowing effect ticks
*/
int getGlowingTicks();
/**
* Sets the amount of time to apply the glowing effect for.
- *
+ *
* @param duration the glowing effect ticks
*/
void setGlowingTicks(int duration);
diff --git a/paper-api/src/main/java/org/bukkit/entity/minecart/HopperMinecart.java b/paper-api/src/main/java/org/bukkit/entity/minecart/HopperMinecart.java
index 8ced540398..937b99f873 100644
--- a/paper-api/src/main/java/org/bukkit/entity/minecart/HopperMinecart.java
+++ b/paper-api/src/main/java/org/bukkit/entity/minecart/HopperMinecart.java
@@ -10,16 +10,16 @@ import org.bukkit.loot.Lootable;
public interface HopperMinecart extends Minecart, InventoryHolder, Lootable {
/**
- * Checks whether or not this Minecart will pick up
+ * Checks whether or not this Minecart will pick up
* items into its inventory.
- *
+ *
* @return true if the Minecart will pick up items
*/
boolean isEnabled();
/**
* Sets whether this Minecart will pick up items.
- *
+ *
* @param enabled new enabled state
*/
void setEnabled(boolean enabled);
diff --git a/paper-api/src/main/java/org/bukkit/event/EventHandler.java b/paper-api/src/main/java/org/bukkit/event/EventHandler.java
index 4c9fb3cde6..cc06f480b7 100644
--- a/paper-api/src/main/java/org/bukkit/event/EventHandler.java
+++ b/paper-api/src/main/java/org/bukkit/event/EventHandler.java
@@ -24,7 +24,7 @@ public @interface EventHandler {
*
* If ignoreCancelled is true and the event is cancelled, the method is
* not called. Otherwise, the method is always called.
- *
+ *
* @return whether cancelled events should be ignored
*/
boolean ignoreCancelled() default false;
diff --git a/paper-api/src/main/java/org/bukkit/event/block/BlockPhysicsEvent.java b/paper-api/src/main/java/org/bukkit/event/block/BlockPhysicsEvent.java
index 75d4e70f5e..026ca7f1cf 100644
--- a/paper-api/src/main/java/org/bukkit/event/block/BlockPhysicsEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/block/BlockPhysicsEvent.java
@@ -44,7 +44,7 @@ public class BlockPhysicsEvent extends BlockEvent implements Cancellable {
/**
* Gets the source block that triggered this event.
- *
+ *
* Note: This will default to block if not set.
*
* @return The source block
diff --git a/paper-api/src/main/java/org/bukkit/event/block/BlockPistonRetractEvent.java b/paper-api/src/main/java/org/bukkit/event/block/BlockPistonRetractEvent.java
index 4744e0fa59..340fa397e6 100644
--- a/paper-api/src/main/java/org/bukkit/event/block/BlockPistonRetractEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/block/BlockPistonRetractEvent.java
@@ -13,10 +13,10 @@ import org.jetbrains.annotations.NotNull;
public class BlockPistonRetractEvent extends BlockPistonEvent {
private static final HandlerList handlers = new HandlerList();
private List blocks;
-
+
public BlockPistonRetractEvent(@NotNull final Block block, @NotNull final List blocks, @NotNull final BlockFace direction) {
super(block, direction);
-
+
this.blocks = blocks;
}
@@ -31,7 +31,7 @@ public class BlockPistonRetractEvent extends BlockPistonEvent {
public Location getRetractLocation() {
return getBlock().getRelative(getDirection(), 2).getLocation();
}
-
+
/**
* Get an immutable list of the blocks which will be moved by the
* extending.
diff --git a/paper-api/src/main/java/org/bukkit/event/block/EntityBlockFormEvent.java b/paper-api/src/main/java/org/bukkit/event/block/EntityBlockFormEvent.java
index 741aead8b7..3baed1c43b 100644
--- a/paper-api/src/main/java/org/bukkit/event/block/EntityBlockFormEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/block/EntityBlockFormEvent.java
@@ -32,4 +32,4 @@ public class EntityBlockFormEvent extends BlockFormEvent {
public Entity getEntity() {
return entity;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/event/entity/EnderDragonChangePhaseEvent.java b/paper-api/src/main/java/org/bukkit/event/entity/EnderDragonChangePhaseEvent.java
index 1b654fa990..631ca54dc9 100644
--- a/paper-api/src/main/java/org/bukkit/event/entity/EnderDragonChangePhaseEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/entity/EnderDragonChangePhaseEvent.java
@@ -30,9 +30,9 @@ public class EnderDragonChangePhaseEvent extends EntityEvent implements Cancella
}
/**
- * Gets the current phase that the dragon is in. This method will return null
+ * Gets the current phase that the dragon is in. This method will return null
* when a dragon is first spawned and hasn't yet been assigned a phase.
- *
+ *
* @return the current dragon phase
*/
@Nullable
@@ -42,7 +42,7 @@ public class EnderDragonChangePhaseEvent extends EntityEvent implements Cancella
/**
* Gets the new phase that the dragon will switch to.
- *
+ *
* @return the new dragon phase
*/
@NotNull
@@ -52,7 +52,7 @@ public class EnderDragonChangePhaseEvent extends EntityEvent implements Cancella
/**
* Sets the new phase for the ender dragon.
- *
+ *
* @param newPhase the new dragon phase
*/
public void setNewPhase(@NotNull EnderDragon.Phase newPhase) {
diff --git a/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalEvent.java b/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalEvent.java
index 153bcf1bf2..7fdfe3c5a3 100644
--- a/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalEvent.java
@@ -29,4 +29,4 @@ public class EntityPortalEvent extends EntityTeleportEvent {
public static HandlerList getHandlerList() {
return handlers;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalExitEvent.java b/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalExitEvent.java
index f124d43f07..869ad3b12e 100644
--- a/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalExitEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/entity/EntityPortalExitEvent.java
@@ -47,7 +47,7 @@ public class EntityPortalExitEvent extends EntityTeleportEvent {
/**
* Sets the velocity that the entity will have after exiting the portal.
- *
+ *
* @param after the velocity after exiting the portal
*/
public void setAfter(@NotNull Vector after) {
@@ -64,4 +64,4 @@ public class EntityPortalExitEvent extends EntityTeleportEvent {
public static HandlerList getHandlerList() {
return handlers;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/event/entity/EntityTeleportEvent.java b/paper-api/src/main/java/org/bukkit/event/entity/EntityTeleportEvent.java
index 310259fe89..6d62a03f21 100644
--- a/paper-api/src/main/java/org/bukkit/event/entity/EntityTeleportEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/entity/EntityTeleportEvent.java
@@ -82,4 +82,4 @@ public class EntityTeleportEvent extends EntityEvent implements Cancellable {
public static HandlerList getHandlerList() {
return handlers;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/event/entity/SlimeSplitEvent.java b/paper-api/src/main/java/org/bukkit/event/entity/SlimeSplitEvent.java
index 6e634dd7fe..ea69522667 100644
--- a/paper-api/src/main/java/org/bukkit/event/entity/SlimeSplitEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/entity/SlimeSplitEvent.java
@@ -60,4 +60,4 @@ public class SlimeSplitEvent extends EntityEvent implements Cancellable {
public static HandlerList getHandlerList() {
return handlers;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/event/inventory/InventoryClickEvent.java b/paper-api/src/main/java/org/bukkit/event/inventory/InventoryClickEvent.java
index 5aec15a903..f8dde282c8 100644
--- a/paper-api/src/main/java/org/bukkit/event/inventory/InventoryClickEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/inventory/InventoryClickEvent.java
@@ -29,7 +29,7 @@ import org.jetbrains.annotations.Nullable;
*
{@link InventoryView#close()}
*
- * To invoke one of these methods, schedule a task using
+ * To invoke one of these methods, schedule a task using
* {@link BukkitScheduler#runTask(Plugin, Runnable)}, which will run the task
* on the next tick. Also be aware that this is not an exhaustive list, and
* other methods could potentially create issues as well.
diff --git a/paper-api/src/main/java/org/bukkit/event/inventory/InventoryDragEvent.java b/paper-api/src/main/java/org/bukkit/event/inventory/InventoryDragEvent.java
index 1716369a77..67409477ca 100644
--- a/paper-api/src/main/java/org/bukkit/event/inventory/InventoryDragEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/inventory/InventoryDragEvent.java
@@ -22,7 +22,7 @@ import org.jetbrains.annotations.Nullable;
/**
* This event is called when the player drags an item in their cursor across
* the inventory. The ItemStack is distributed across the slots the
- * HumanEntity dragged over. The method of distribution is described by the
+ * HumanEntity dragged over. The method of distribution is described by the
* DragType returned by {@link #getType()}.
*
* Canceling this event will result in none of the changes described in
@@ -41,7 +41,7 @@ import org.jetbrains.annotations.Nullable;
*
{@link InventoryView#close()}
*
- * To invoke one of these methods, schedule a task using
+ * To invoke one of these methods, schedule a task using
* {@link BukkitScheduler#runTask(Plugin, Runnable)}, which will run the task
* on the next tick. Also be aware that this is not an exhaustive list, and
* other methods could potentially create issues as well.
diff --git a/paper-api/src/main/java/org/bukkit/event/server/ServerListPingEvent.java b/paper-api/src/main/java/org/bukkit/event/server/ServerListPingEvent.java
index f8c89ccaf7..de940f6e9a 100644
--- a/paper-api/src/main/java/org/bukkit/event/server/ServerListPingEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/server/ServerListPingEvent.java
@@ -35,7 +35,7 @@ public class ServerListPingEvent extends ServerEvent implements Iterable
* This constructor is intended for implementations that provide the
* {@link #iterator()} method, thus provided the {@link #getNumPlayers()}
* count.
- *
+ *
* @param address the address of the pinger
* @param motd the message of the day
* @param maxPlayers the max number of players
diff --git a/paper-api/src/main/java/org/bukkit/event/server/ServiceEvent.java b/paper-api/src/main/java/org/bukkit/event/server/ServiceEvent.java
index bbc2de5048..55e278cd06 100644
--- a/paper-api/src/main/java/org/bukkit/event/server/ServiceEvent.java
+++ b/paper-api/src/main/java/org/bukkit/event/server/ServiceEvent.java
@@ -18,4 +18,4 @@ public abstract class ServiceEvent extends ServerEvent {
public RegisteredServiceProvider> getProvider() {
return provider;
}
-}
\ No newline at end of file
+}
diff --git a/paper-api/src/main/java/org/bukkit/generator/ChunkGenerator.java b/paper-api/src/main/java/org/bukkit/generator/ChunkGenerator.java
index 9a18a05bb3..629d937602 100644
--- a/paper-api/src/main/java/org/bukkit/generator/ChunkGenerator.java
+++ b/paper-api/src/main/java/org/bukkit/generator/ChunkGenerator.java
@@ -52,7 +52,7 @@ public abstract class ChunkGenerator {
/**
* Shapes the chunk for the given coordinates.
- *
+ *
* This method must return a ChunkData.
*
* Notes:
@@ -64,7 +64,7 @@ public abstract class ChunkGenerator {
* been returned.
*
* This method must return a ChunkData returned by {@link ChunkGenerator#createChunkData(org.bukkit.World)}
- *
+ *
* @param world The world this chunk will be used for
* @param random The random generator to use
* @param x The X-coordinate of the chunk
@@ -144,9 +144,9 @@ public abstract class ChunkGenerator {
public static interface ChunkData {
/**
* Get the maximum height for the chunk.
- *
+ *
* Setting blocks at or above this height will do nothing.
- *
+ *
* @return the maximum height
*/
public int getMaxHeight();
@@ -174,7 +174,7 @@ public abstract class ChunkGenerator {
* @param material the type to set the block to
*/
public void setBlock(int x, int y, int z, @NotNull MaterialData material);
-
+
/**
* Set the block at x,y,z in the chunk data to material.
*
@@ -202,7 +202,7 @@ public abstract class ChunkGenerator {
* @param material the type to set the blocks to
*/
public void setRegion(int xMin, int yMin, int zMin, int xMax, int yMax, int zMax, @NotNull Material material);
-
+
/**
* Set a region of this chunk from xMin, yMin, zMin (inclusive)
* to xMax, yMax, zMax (exclusive) to material.
@@ -218,7 +218,7 @@ public abstract class ChunkGenerator {
* @param material the type to set the blocks to
*/
public void setRegion(int xMin, int yMin, int zMin, int xMax, int yMax, int zMax, @NotNull MaterialData material);
-
+
/**
* Set a region of this chunk from xMin, yMin, zMin (inclusive) to xMax,
* yMax, zMax (exclusive) to material.
@@ -247,7 +247,7 @@ public abstract class ChunkGenerator {
*/
@NotNull
public Material getType(int x, int y, int z);
-
+
/**
* Get the type and data of the block at x, y, z.
*
@@ -260,7 +260,7 @@ public abstract class ChunkGenerator {
*/
@NotNull
public MaterialData getTypeAndData(int x, int y, int z);
-
+
/**
* Get the type and data of the block at x, y, z.
*
@@ -273,7 +273,7 @@ public abstract class ChunkGenerator {
*/
@NotNull
public BlockData getBlockData(int x, int y, int z);
-
+
/**
* Get the block data at x,y,z in the chunk data.
*
diff --git a/paper-api/src/main/java/org/bukkit/help/HelpMap.java b/paper-api/src/main/java/org/bukkit/help/HelpMap.java
index 45845238e4..7a8795f80d 100644
--- a/paper-api/src/main/java/org/bukkit/help/HelpMap.java
+++ b/paper-api/src/main/java/org/bukkit/help/HelpMap.java
@@ -10,7 +10,7 @@ import java.util.List;
* The HelpMap tracks all help topics registered in a Bukkit server. When the
* server starts up or is reloaded, help is processed and topics are added in
* the following order:
- *
+ *
*
*
General topics are loaded from the help.yml
*
Plugins load and optionally call {@code addTopic()}
@@ -37,7 +37,7 @@ public interface HelpMap {
*/
@NotNull
public Collection getHelpTopics();
-
+
/**
* Adds a topic to the server's help index.
*
diff --git a/paper-api/src/main/java/org/bukkit/help/HelpTopicComparator.java b/paper-api/src/main/java/org/bukkit/help/HelpTopicComparator.java
index e586826d90..dee86aefb6 100644
--- a/paper-api/src/main/java/org/bukkit/help/HelpTopicComparator.java
+++ b/paper-api/src/main/java/org/bukkit/help/HelpTopicComparator.java
@@ -10,7 +10,7 @@ import java.util.Comparator;
* All topics are listed in alphabetic order, but topics that start with a
* slash come after topics that don't.
*/
-public class HelpTopicComparator implements Comparator {
+public final class HelpTopicComparator implements Comparator {
// Singleton implementations
private static final TopicNameComparator tnc = new TopicNameComparator();
@@ -31,7 +31,7 @@ public class HelpTopicComparator implements Comparator {
return tnc.compare(lhs.getName(), rhs.getName());
}
- public static class TopicNameComparator implements Comparator {
+ public static final class TopicNameComparator implements Comparator {
private TopicNameComparator(){}
public int compare(@NotNull String lhs, @NotNull String rhs) {
diff --git a/paper-api/src/main/java/org/bukkit/inventory/EntityEquipment.java b/paper-api/src/main/java/org/bukkit/inventory/EntityEquipment.java
index 6875dbc725..1fd9f79de8 100644
--- a/paper-api/src/main/java/org/bukkit/inventory/EntityEquipment.java
+++ b/paper-api/src/main/java/org/bukkit/inventory/EntityEquipment.java
@@ -234,7 +234,7 @@ public interface EntityEquipment {
/**
* Sets the chance of the helmet being dropped upon this creature's death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
@@ -248,7 +248,7 @@ public interface EntityEquipment {
/**
* Gets the chance of the chest plate being dropped upon this creature's
* death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
@@ -261,7 +261,7 @@ public interface EntityEquipment {
/**
* Sets the chance of the chest plate being dropped upon this creature's
* death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
@@ -275,7 +275,7 @@ public interface EntityEquipment {
/**
* Gets the chance of the leggings being dropped upon this creature's
* death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
@@ -288,7 +288,7 @@ public interface EntityEquipment {
/**
* Sets the chance of the leggings being dropped upon this creature's
* death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
@@ -301,7 +301,7 @@ public interface EntityEquipment {
/**
* Gets the chance of the boots being dropped upon this creature's death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
@@ -313,7 +313,7 @@ public interface EntityEquipment {
/**
* Sets the chance of the boots being dropped upon this creature's death.
- *
+ *
*
*
A drop chance of 0.0F will never drop
*
A drop chance of 1.0F will always drop
diff --git a/paper-api/src/main/java/org/bukkit/inventory/InventoryView.java b/paper-api/src/main/java/org/bukkit/inventory/InventoryView.java
index b777bec711..d4135976bc 100644
--- a/paper-api/src/main/java/org/bukkit/inventory/InventoryView.java
+++ b/paper-api/src/main/java/org/bukkit/inventory/InventoryView.java
@@ -15,7 +15,7 @@ import org.jetbrains.annotations.Nullable;
* as it should.
*/
public abstract class InventoryView {
- public final static int OUTSIDE = -999;
+ public static final int OUTSIDE = -999;
/**
* Represents various extra properties of certain inventory windows.
*/
diff --git a/paper-api/src/main/java/org/bukkit/inventory/meta/BlockStateMeta.java b/paper-api/src/main/java/org/bukkit/inventory/meta/BlockStateMeta.java
index d71a4eaf12..e7d905b114 100644
--- a/paper-api/src/main/java/org/bukkit/inventory/meta/BlockStateMeta.java
+++ b/paper-api/src/main/java/org/bukkit/inventory/meta/BlockStateMeta.java
@@ -9,7 +9,7 @@ public interface BlockStateMeta extends ItemMeta {
/**
* Returns whether the item has a block state currently
* attached to it.
- *
+ *
* @return whether a block state is already attached
*/
boolean hasBlockState();
diff --git a/paper-api/src/main/java/org/bukkit/inventory/meta/ItemMeta.java b/paper-api/src/main/java/org/bukkit/inventory/meta/ItemMeta.java
index 4cd8a941ed..d1cd8dfde6 100644
--- a/paper-api/src/main/java/org/bukkit/inventory/meta/ItemMeta.java
+++ b/paper-api/src/main/java/org/bukkit/inventory/meta/ItemMeta.java
@@ -86,14 +86,14 @@ public interface ItemMeta extends Cloneable, ConfigurationSerializable {
*
* Plugins should check if hasLore() returns true before
* calling this method.
- *
+ *
* @return a list of lore that is set
*/
@Nullable
List getLore();
/**
- * Sets the lore for this item.
+ * Sets the lore for this item.
* Removes lore when given null.
*
* @param lore the lore that will be set
@@ -157,7 +157,7 @@ public interface ItemMeta extends Cloneable, ConfigurationSerializable {
int getEnchantLevel(@NotNull Enchantment ench);
/**
- * Returns a copy the enchantments in this ItemMeta.
+ * Returns a copy the enchantments in this ItemMeta.
* Returns an empty map if none.
*
* @return An immutable copy of the enchantments
diff --git a/paper-api/src/main/java/org/bukkit/map/MapCursor.java b/paper-api/src/main/java/org/bukkit/map/MapCursor.java
index 264c17820e..29f979945a 100644
--- a/paper-api/src/main/java/org/bukkit/map/MapCursor.java
+++ b/paper-api/src/main/java/org/bukkit/map/MapCursor.java
@@ -262,7 +262,7 @@ public final class MapCursor {
/**
*
- * @return the value
+ * @return the value
* @deprecated Magic value
*/
@Deprecated
diff --git a/paper-api/src/main/java/org/bukkit/map/MapRenderer.java b/paper-api/src/main/java/org/bukkit/map/MapRenderer.java
index 93aeaf7e59..cb7040876a 100644
--- a/paper-api/src/main/java/org/bukkit/map/MapRenderer.java
+++ b/paper-api/src/main/java/org/bukkit/map/MapRenderer.java
@@ -34,7 +34,7 @@ public abstract class MapRenderer {
*
* @return True if contextual, false otherwise.
*/
- final public boolean isContextual() {
+ public final boolean isContextual() {
return contextual;
}
@@ -52,6 +52,6 @@ public abstract class MapRenderer {
* @param canvas The canvas to use for rendering.
* @param player The player who triggered the rendering.
*/
- abstract public void render(@NotNull MapView map, @NotNull MapCanvas canvas, @NotNull Player player);
+ public abstract void render(@NotNull MapView map, @NotNull MapCanvas canvas, @NotNull Player player);
}
diff --git a/paper-api/src/main/java/org/bukkit/material/PistonBaseMaterial.java b/paper-api/src/main/java/org/bukkit/material/PistonBaseMaterial.java
index 805f9e57cf..0f985e0633 100644
--- a/paper-api/src/main/java/org/bukkit/material/PistonBaseMaterial.java
+++ b/paper-api/src/main/java/org/bukkit/material/PistonBaseMaterial.java
@@ -7,16 +7,16 @@ import org.bukkit.block.BlockFace;
* Material data for the piston base block
*/
public class PistonBaseMaterial extends MaterialData implements Directional, Redstone {
-
+
public PistonBaseMaterial(final Material type) {
super(type);
}
/**
* Constructs a PistonBaseMaterial.
- *
+ *
* @param type the material type to use
- * @param data the raw data value
+ * @param data the raw data value
* @deprecated Magic value
*/
@Deprecated
diff --git a/paper-api/src/main/java/org/bukkit/material/Wood.java b/paper-api/src/main/java/org/bukkit/material/Wood.java
index c77664ee83..b020847357 100644
--- a/paper-api/src/main/java/org/bukkit/material/Wood.java
+++ b/paper-api/src/main/java/org/bukkit/material/Wood.java
@@ -23,7 +23,7 @@ public class Wood extends MaterialData {
/**
* Constructs a wood block of the given tree species.
- *
+ *
* @param species the species of the wood block
*/
public Wood(TreeSpecies species) {
diff --git a/paper-api/src/main/java/org/bukkit/material/types/MushroomBlockTexture.java b/paper-api/src/main/java/org/bukkit/material/types/MushroomBlockTexture.java
index b36a10bfbf..f7e85d3183 100644
--- a/paper-api/src/main/java/org/bukkit/material/types/MushroomBlockTexture.java
+++ b/paper-api/src/main/java/org/bukkit/material/types/MushroomBlockTexture.java
@@ -66,8 +66,8 @@ public enum MushroomBlockTexture {
* Stem texture on all faces.
*/
ALL_STEM(15, null);
- private final static Map BY_DATA = Maps.newHashMap();
- private final static Map BY_BLOCKFACE = Maps.newHashMap();
+ private static final Map BY_DATA = Maps.newHashMap();
+ private static final Map BY_BLOCKFACE = Maps.newHashMap();
private final Byte data;
private final BlockFace capFace;
diff --git a/paper-api/src/main/java/org/bukkit/metadata/LazyMetadataValue.java b/paper-api/src/main/java/org/bukkit/metadata/LazyMetadataValue.java
index 820b22ca9f..eeb98c4c18 100644
--- a/paper-api/src/main/java/org/bukkit/metadata/LazyMetadataValue.java
+++ b/paper-api/src/main/java/org/bukkit/metadata/LazyMetadataValue.java
@@ -58,7 +58,7 @@ public class LazyMetadataValue extends MetadataValueAdapter {
/**
* Protected special constructor used by FixedMetadataValue to bypass
* standard setup.
- *
+ *
* @param owningPlugin the owning plugin
*/
protected LazyMetadataValue(@NotNull Plugin owningPlugin) {
diff --git a/paper-api/src/main/java/org/bukkit/permissions/PermissionDefault.java b/paper-api/src/main/java/org/bukkit/permissions/PermissionDefault.java
index c36f52f95d..3380f2f20f 100644
--- a/paper-api/src/main/java/org/bukkit/permissions/PermissionDefault.java
+++ b/paper-api/src/main/java/org/bukkit/permissions/PermissionDefault.java
@@ -16,7 +16,7 @@ public enum PermissionDefault {
NOT_OP("!op", "notop", "!operator", "notoperator", "!admin", "notadmin");
private final String[] names;
- private final static Map lookup = new HashMap();
+ private static final Map lookup = new HashMap();
private PermissionDefault(/*@NotNull*/ String... names) {
this.names = names;
diff --git a/paper-api/src/main/java/org/bukkit/plugin/PluginDescriptionFile.java b/paper-api/src/main/java/org/bukkit/plugin/PluginDescriptionFile.java
index 4574a965ee..6d3e9cc165 100644
--- a/paper-api/src/main/java/org/bukkit/plugin/PluginDescriptionFile.java
+++ b/paper-api/src/main/java/org/bukkit/plugin/PluginDescriptionFile.java
@@ -784,7 +784,7 @@ public final class PluginDescriptionFile {
*
* Another example, with nested definitions, can be found here.
- *
+ *
* @return the permissions this plugin will register
*/
@NotNull
@@ -829,7 +829,7 @@ public final class PluginDescriptionFile {
* not included in the API. Any unrecognized
* awareness (one unsupported or in a future version) will cause a dummy
* object to be created instead of failing.
- *
+ *
*
*
Currently only supports the enumerated values in {@link
* PluginAwareness.Flags}.
diff --git a/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java b/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java
index de68a03864..7b6aefa450 100644
--- a/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java
+++ b/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java
@@ -56,7 +56,7 @@ public final class JavaPluginLoader implements PluginLoader {
/**
* This class was not meant to be constructed explicitly
- *
+ *
* @param instance the server instance
*/
@Deprecated
diff --git a/paper-api/src/main/java/org/bukkit/potion/PotionType.java b/paper-api/src/main/java/org/bukkit/potion/PotionType.java
index 9b0fcf2dad..1952dd9c27 100644
--- a/paper-api/src/main/java/org/bukkit/potion/PotionType.java
+++ b/paper-api/src/main/java/org/bukkit/potion/PotionType.java
@@ -54,7 +54,7 @@ public enum PotionType {
* Checks if the potion type has an upgraded state.
* This refers to whether or not the potion type can be Tier 2,
* such as Potion of Fire Resistance II.
- *
+ *
* @return true if the potion type can be upgraded;
*/
public boolean isUpgradeable() {
@@ -64,7 +64,7 @@ public enum PotionType {
/**
* Checks if the potion type has an extended state.
* This refers to the extended duration potions
- *
+ *
* @return true if the potion type can be extended
*/
public boolean isExtendable() {
diff --git a/paper-api/src/main/java/org/bukkit/scoreboard/Criterias.java b/paper-api/src/main/java/org/bukkit/scoreboard/Criterias.java
index cd81c87f8a..413430928f 100644
--- a/paper-api/src/main/java/org/bukkit/scoreboard/Criterias.java
+++ b/paper-api/src/main/java/org/bukkit/scoreboard/Criterias.java
@@ -3,18 +3,12 @@ package org.bukkit.scoreboard;
/**
* Criteria names which trigger an objective to be modified by actions in-game
*/
-public class Criterias {
- public static final String HEALTH;
- public static final String PLAYER_KILLS;
- public static final String TOTAL_KILLS;
- public static final String DEATHS;
+public final class Criterias {
- static {
- HEALTH="health";
- PLAYER_KILLS="playerKillCount";
- TOTAL_KILLS="totalKillCount";
- DEATHS="deathCount";
- }
+ public static final String HEALTH = "health";
+ public static final String PLAYER_KILLS = "playerKillCount";
+ public static final String TOTAL_KILLS = "totalKillCount";
+ public static final String DEATHS = "deathCount";
private Criterias() {}
}
diff --git a/paper-api/src/main/java/org/bukkit/util/io/Wrapper.java b/paper-api/src/main/java/org/bukkit/util/io/Wrapper.java
index 51dd951b07..1961370e55 100644
--- a/paper-api/src/main/java/org/bukkit/util/io/Wrapper.java
+++ b/paper-api/src/main/java/org/bukkit/util/io/Wrapper.java
@@ -9,7 +9,7 @@ import org.bukkit.configuration.serialization.ConfigurationSerialization;
import com.google.common.collect.ImmutableMap;
import org.jetbrains.annotations.NotNull;
-class Wrapper & Serializable> implements Serializable {
+final class Wrapper & Serializable> implements Serializable {
private static final long serialVersionUID = -986209235411767547L;
final T map;
diff --git a/paper-api/src/main/java/org/bukkit/util/noise/NoiseGenerator.java b/paper-api/src/main/java/org/bukkit/util/noise/NoiseGenerator.java
index 72c92f33cc..aa2d70414d 100644
--- a/paper-api/src/main/java/org/bukkit/util/noise/NoiseGenerator.java
+++ b/paper-api/src/main/java/org/bukkit/util/noise/NoiseGenerator.java
@@ -4,7 +4,7 @@ package org.bukkit.util.noise;
* Base class for all noise generators
*/
public abstract class NoiseGenerator {
- protected final int perm[] = new int[512];
+ protected final int[] perm= new int[512];
protected double offsetX;
protected double offsetY;
protected double offsetZ;
diff --git a/paper-api/src/main/java/org/bukkit/util/noise/PerlinNoiseGenerator.java b/paper-api/src/main/java/org/bukkit/util/noise/PerlinNoiseGenerator.java
index f481286b85..520b65f9e6 100644
--- a/paper-api/src/main/java/org/bukkit/util/noise/PerlinNoiseGenerator.java
+++ b/paper-api/src/main/java/org/bukkit/util/noise/PerlinNoiseGenerator.java
@@ -11,13 +11,13 @@ import org.jetbrains.annotations.NotNull;
* different results
*/
public class PerlinNoiseGenerator extends NoiseGenerator {
- protected static final int grad3[][] = {{1, 1, 0}, {-1, 1, 0}, {1, -1, 0}, {-1, -1, 0},
+ protected static final int[][] grad3 = {{1, 1, 0}, {-1, 1, 0}, {1, -1, 0}, {-1, -1, 0},
{1, 0, 1}, {-1, 0, 1}, {1, 0, -1}, {-1, 0, -1},
{0, 1, 1}, {0, -1, 1}, {0, 1, -1}, {0, -1, -1}};
private static final PerlinNoiseGenerator instance = new PerlinNoiseGenerator();
protected PerlinNoiseGenerator() {
- int p[] = {151, 160, 137, 91, 90, 15, 131, 13, 201,
+ int[] p = {151, 160, 137, 91, 90, 15, 131, 13, 201,
95, 96, 53, 194, 233, 7, 225, 140, 36, 103, 30, 69, 142, 8, 99, 37,
240, 21, 10, 23, 190, 6, 148, 247, 120, 234, 75, 0, 26, 197, 62,
94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, 88, 237, 149, 56,
diff --git a/paper-api/src/main/java/org/bukkit/util/noise/SimplexNoiseGenerator.java b/paper-api/src/main/java/org/bukkit/util/noise/SimplexNoiseGenerator.java
index 850604a4de..afe8fa9545 100644
--- a/paper-api/src/main/java/org/bukkit/util/noise/SimplexNoiseGenerator.java
+++ b/paper-api/src/main/java/org/bukkit/util/noise/SimplexNoiseGenerator.java
@@ -25,7 +25,7 @@ public class SimplexNoiseGenerator extends PerlinNoiseGenerator {
protected static final double G42 = G4 * 2.0;
protected static final double G43 = G4 * 3.0;
protected static final double G44 = G4 * 4.0 - 1.0;
- protected static final int grad4[][] = {{0, 1, 1, 1}, {0, 1, 1, -1}, {0, 1, -1, 1}, {0, 1, -1, -1},
+ protected static final int[][] grad4 = {{0, 1, 1, 1}, {0, 1, 1, -1}, {0, 1, -1, 1}, {0, 1, -1, -1},
{0, -1, 1, 1}, {0, -1, 1, -1}, {0, -1, -1, 1}, {0, -1, -1, -1},
{1, 0, 1, 1}, {1, 0, 1, -1}, {1, 0, -1, 1}, {1, 0, -1, -1},
{-1, 0, 1, 1}, {-1, 0, 1, -1}, {-1, 0, -1, 1}, {-1, 0, -1, -1},
@@ -33,7 +33,7 @@ public class SimplexNoiseGenerator extends PerlinNoiseGenerator {
{-1, 1, 0, 1}, {-1, 1, 0, -1}, {-1, -1, 0, 1}, {-1, -1, 0, -1},
{1, 1, 1, 0}, {1, 1, -1, 0}, {1, -1, 1, 0}, {1, -1, -1, 0},
{-1, 1, 1, 0}, {-1, 1, -1, 0}, {-1, -1, 1, 0}, {-1, -1, -1, 0}};
- protected static final int simplex[][] = {
+ protected static final int[][] simplex = {
{0, 1, 2, 3}, {0, 1, 3, 2}, {0, 0, 0, 0}, {0, 2, 3, 1}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {1, 2, 3, 0},
{0, 2, 1, 3}, {0, 0, 0, 0}, {0, 3, 1, 2}, {0, 3, 2, 1}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {1, 3, 2, 0},
{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0},
diff --git a/paper-api/src/test/java/org/bukkit/ChatColorTest.java b/paper-api/src/test/java/org/bukkit/ChatColorTest.java
index 80108a5d3a..523399a997 100644
--- a/paper-api/src/test/java/org/bukkit/ChatColorTest.java
+++ b/paper-api/src/test/java/org/bukkit/ChatColorTest.java
@@ -62,7 +62,7 @@ public class ChatColorTest {
assertThat(String.format("%c%c", ChatColor.COLOR_CHAR, color.getChar()), is(color.toString()));
}
}
-
+
@Test
public void translateAlternateColorCodes() {
String s = "&0&1&2&3&4&5&6&7&8&9&A&a&B&b&C&c&D&d&E&e&F&f&K&k & more";
diff --git a/paper-api/src/test/java/org/bukkit/LocationTest.java b/paper-api/src/test/java/org/bukkit/LocationTest.java
index 48d20761bb..c288e411e0 100644
--- a/paper-api/src/test/java/org/bukkit/LocationTest.java
+++ b/paper-api/src/test/java/org/bukkit/LocationTest.java
@@ -41,7 +41,7 @@ public class LocationTest {
@Parameters(name= "{index}: {0}")
public static List