48 lines
1014 B
Java
48 lines
1014 B
Java
package pw.yumc.BukkitInjectedTools.event;
|
|
|
|
import org.bukkit.event.Cancellable;
|
|
import org.bukkit.event.Event;
|
|
import org.bukkit.event.HandlerList;
|
|
|
|
/**
|
|
* Yum事件测试类
|
|
*
|
|
* @since 2016年7月18日 下午7:07:37
|
|
* @author 喵♂呜
|
|
*/
|
|
public class YumTestEvent extends Event implements Cancellable {
|
|
private static final HandlerList handlers = new HandlerList();
|
|
private final boolean value;
|
|
private boolean cancel = false;
|
|
|
|
public YumTestEvent(final boolean value) {
|
|
this.value = value;
|
|
}
|
|
|
|
public static HandlerList getHandlerList() {
|
|
return handlers;
|
|
}
|
|
|
|
@Override
|
|
public HandlerList getHandlers() {
|
|
return handlers;
|
|
}
|
|
|
|
@Override
|
|
public boolean isCancelled() {
|
|
return cancel;
|
|
}
|
|
|
|
/**
|
|
* @return value
|
|
*/
|
|
public boolean isValue() {
|
|
return value;
|
|
}
|
|
|
|
@Override
|
|
public void setCancelled(final boolean arg0) {
|
|
cancel = arg0;
|
|
}
|
|
}
|