AsyncPlayerPreLoginEvent, AsyncTabCompleteEvent, BlockEvent, EntityEvent, FillProfileEvent, HangingEvent, InventoryEvent, InventoryMoveItemEvent, InventoryPickupItemEvent, LookupProfileEvent, PlayerEvent, PlayerHandshakeEvent, PlayerLeashEntityEvent, PlayerPreLoginEvent, PreCreatureSpawnEvent, PreFillProfileEvent, PreLookupProfileEvent, ProfileWhitelistVerifyEvent, ServerEvent, ServerExceptionEvent, TabCompleteEvent, UnknownCommandEvent, VehicleEvent, WeatherEvent, WorldEventpublic abstract class Event
extends java.lang.Object
HandlerList as getHandlers().| Modifier and Type | Class | Description |
|---|---|---|
static class |
Event.Result |
| Constructor | Description |
|---|---|
Event() |
The default constructor is defined for cleaner code.
|
Event(boolean isAsync) |
This constructor is used to explicitly declare an event as synchronous
or asynchronous.
|
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
callEvent() |
Calls the event and tests if cancelled.
|
java.lang.String |
getEventName() |
Convenience method for providing a user-friendly identifier.
|
abstract HandlerList |
getHandlers() |
|
boolean |
isAsynchronous() |
Any custom event that should not by synchronized with other events must
use the specific constructor.
|
public Event()
public Event(boolean isAsync)
isAsync - true indicates the event will fire asynchronously, false
by default from default constructorpublic boolean callEvent()
public java.lang.String getEventName()
public abstract HandlerList getHandlers()
public final boolean isAsynchronous()
IllegalStateException.
Copyright © 2018. All rights reserved.