More JavaDoc improvements.

By: EvilSeph <evilseph@unaligned.org>
This commit is contained in:
Bukkit/Spigot
2011-06-24 02:32:04 -04:00
parent 0630db640b
commit c54128077a
56 changed files with 435 additions and 139 deletions

View File

@@ -19,9 +19,9 @@ public class BlockBreakEvent extends BlockEvent implements Cancellable {
}
/**
* Returns the player doing the damage
* Gets the Player that is breaking the block
*
* @return the Player doing the damage
* @return the Player that is breaking the block
*/
public Player getPlayer() {
return player;

View File

@@ -6,7 +6,7 @@ import org.bukkit.event.Cancellable;
import org.bukkit.inventory.ItemStack;
/**
* Called when a block is damaged by a player
* Called when a block is damaged (hit by a player)
*/
public class BlockDamageEvent extends BlockEvent implements Cancellable {
private Player player;

View File

@@ -59,14 +59,20 @@ public class BlockDispenseEvent extends BlockEvent implements Cancellable {
}
/**
* Check to see if the event was cancelled.
* Gets the cancellation state of this event. A cancelled event will not
* be executed in the server, but will still pass to other plugins
*
* @return true if this event is cancelled
*/
public boolean isCancelled() {
return cancelled;
}
/**
* Prevent dispensing.
* Sets the cancellation state of this event. A cancelled event will not
* be executed in the server, but will still pass to other plugins
*
* @param cancel true if you wish to cancel this event
*/
public void setCancelled(boolean cancel) {
cancelled = cancel;

View File

@@ -41,6 +41,7 @@ public class SignChangeEvent extends BlockEvent implements Cancellable {
*
* @param index index of the line to get
* @return String line
* @throws IndexOutOfBoundsException
*/
public String getLine(int index) throws IndexOutOfBoundsException {
return lines[index];
@@ -51,6 +52,7 @@ public class SignChangeEvent extends BlockEvent implements Cancellable {
*
* @param index index of the line to set
* @param line text to set
* @throws IndexOutOfBoundsException
*/
public void setLine(int index, String line) throws IndexOutOfBoundsException {
lines[index] = line;