Bukkit-API  1.7.9-R0.2
The inofficial Bukkit-API
org.bukkit.event.inventory.InventoryOpenEvent Class Reference
Inheritance diagram for org.bukkit.event.inventory.InventoryOpenEvent:
org.bukkit.event.inventory.InventoryEvent org.bukkit.event.Cancellable org.bukkit.event.Event

Public Member Functions

 InventoryOpenEvent (InventoryView transaction)
 
final HumanEntity getPlayer ()
 
boolean isCancelled ()
 
void setCancelled (boolean cancel)
 
HandlerList getHandlers ()
 
- Public Member Functions inherited from org.bukkit.event.inventory.InventoryEvent
 InventoryEvent (InventoryView transaction)
 
Inventory getInventory ()
 
List< HumanEntitygetViewers ()
 
InventoryView getView ()
 
HandlerList getHandlers ()
 
- Public Member Functions inherited from org.bukkit.event.Event
 Event ()
 
 Event (boolean isAsync)
 
String getEventName ()
 
abstract HandlerList getHandlers ()
 
final boolean isAsynchronous ()
 

Static Public Member Functions

static HandlerList getHandlerList ()
 
- Static Public Member Functions inherited from org.bukkit.event.inventory.InventoryEvent
static HandlerList getHandlerList ()
 

Additional Inherited Members

- Protected Attributes inherited from org.bukkit.event.inventory.InventoryEvent
InventoryView transaction
 

Detailed Description

Represents a player related inventory event

Definition at line 11 of file InventoryOpenEvent.java.

Member Function Documentation

final HumanEntity org.bukkit.event.inventory.InventoryOpenEvent.getPlayer ( )

Returns the player involved in this event

Returns
Player who is involved in this event

Definition at line 25 of file InventoryOpenEvent.java.

References org.bukkit.inventory.InventoryView.getPlayer().

25  {
26  return transaction.getPlayer();
27  }
abstract HumanEntity getPlayer()
boolean org.bukkit.event.inventory.InventoryOpenEvent.isCancelled ( )

Gets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.

If an inventory open event is cancelled, the inventory screen will not show.

Returns
true if this event is cancelled

Implements org.bukkit.event.Cancellable.

Definition at line 38 of file InventoryOpenEvent.java.

38  {
39  return cancelled;
40  }
void org.bukkit.event.inventory.InventoryOpenEvent.setCancelled ( boolean  cancel)

Sets the cancellation state of this event. A cancelled event will not be executed in the server, but will still pass to other plugins.

If an inventory open event is cancelled, the inventory screen will not show.

Parameters
canceltrue if you wish to cancel this event

Implements org.bukkit.event.Cancellable.

Definition at line 51 of file InventoryOpenEvent.java.

51  {
52  cancelled = cancel;
53  }

The documentation for this class was generated from the following file: