Cancellablepublic class PlayerLecternPageChangeEvent extends PlayerEvent implements Cancellable
| Modifier and Type | Class | Description |
|---|---|---|
static class |
PlayerLecternPageChangeEvent.PageChangeDirection |
Event.Resultplayer| Constructor | Description |
|---|---|
PlayerLecternPageChangeEvent(Player player,
Lectern lectern,
ItemStack book,
PlayerLecternPageChangeEvent.PageChangeDirection pageChangeDirection,
int oldPage,
int newPage) |
| Modifier and Type | Method | Description |
|---|---|---|
ItemStack |
getBook() |
Gets the current ItemStack on the lectern.
|
static HandlerList |
getHandlerList() |
|
HandlerList |
getHandlers() |
|
Lectern |
getLectern() |
Gets the lectern involved.
|
int |
getNewPage() |
Gets the page changed to.
|
int |
getOldPage() |
Gets the page changed from.
|
PlayerLecternPageChangeEvent.PageChangeDirection |
getPageChangeDirection() |
Gets the page change direction.
|
boolean |
isCancelled() |
Gets the cancellation state of this event.
|
void |
setCancelled(boolean cancel) |
Sets the cancellation state of this event.
|
void |
setNewPage(int newPage) |
Sets the page changed to.
|
callEvent, getEventName, isAsynchronousclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetPlayer@NotNull public ItemStack getBook()
@NotNull public PlayerLecternPageChangeEvent.PageChangeDirection getPageChangeDirection()
public int getOldPage()
public int getNewPage()
public void setNewPage(int newPage)
newPage - the new paged changed topublic boolean isCancelled()
CancellableisCancelled in interface Cancellablepublic void setCancelled(boolean cancel)
CancellablesetCancelled in interface Cancellablecancel - true if you wish to cancel this event@NotNull public HandlerList getHandlers()
getHandlers in class Event@NotNull public static HandlerList getHandlerList()
Copyright © 2021. All rights reserved.