Begin implementation of CheckStyle style checking

By: md_5 <git@md-5.net>
This commit is contained in:
Bukkit/Spigot
2019-04-23 14:00:20 +10:00
parent 30a442aef7
commit c240b58f66
88 changed files with 246 additions and 192 deletions

View File

@@ -24,7 +24,7 @@ public @interface EventHandler {
* <li>HIGHEST
* <li>MONITOR
* </ol>
*
*
* @return the priority
*/
EventPriority priority() default EventPriority.NORMAL;
@@ -34,7 +34,7 @@ public @interface EventHandler {
* <p>
* 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;

View File

@@ -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

View File

@@ -13,10 +13,10 @@ import org.jetbrains.annotations.NotNull;
public class BlockPistonRetractEvent extends BlockPistonEvent {
private static final HandlerList handlers = new HandlerList();
private List<Block> blocks;
public BlockPistonRetractEvent(@NotNull final Block block, @NotNull final List<Block> 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.

View File

@@ -32,4 +32,4 @@ public class EntityBlockFormEvent extends BlockFormEvent {
public Entity getEntity() {
return entity;
}
}
}

View File

@@ -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) {

View File

@@ -29,4 +29,4 @@ public class EntityPortalEvent extends EntityTeleportEvent {
public static HandlerList getHandlerList() {
return handlers;
}
}
}

View File

@@ -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;
}
}
}

View File

@@ -82,4 +82,4 @@ public class EntityTeleportEvent extends EntityEvent implements Cancellable {
public static HandlerList getHandlerList() {
return handlers;
}
}
}

View File

@@ -60,4 +60,4 @@ public class SlimeSplitEvent extends EntityEvent implements Cancellable {
public static HandlerList getHandlerList() {
return handlers;
}
}
}

View File

@@ -29,7 +29,7 @@ import org.jetbrains.annotations.Nullable;
* <li>{@link HumanEntity#openEnchanting(Location, boolean)}
* <li>{@link InventoryView#close()}
* </ul>
* 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.

View File

@@ -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()}.
* <p>
* Canceling this event will result in none of the changes described in
@@ -41,7 +41,7 @@ import org.jetbrains.annotations.Nullable;
* <li>{@link HumanEntity#openEnchanting(Location, boolean)}
* <li>{@link InventoryView#close()}
* </ul>
* 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.

View File

@@ -35,7 +35,7 @@ public class ServerListPingEvent extends ServerEvent implements Iterable<Player>
* 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

View File

@@ -18,4 +18,4 @@ public abstract class ServiceEvent extends ServerEvent {
public RegisteredServiceProvider<?> getProvider() {
return provider;
}
}
}