Package org.bukkit.event.inventory

# Class InventoryEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.inventory.InventoryEvent

Direct Known Subclasses:
  `AnvilDamagedEvent`, `EnchantItemEvent`, `InventoryCloseEvent`, `InventoryInteractEvent`, `InventoryOpenEvent`, `PrepareItemCraftEvent`, `PrepareItemEnchantEvent`, `PrepareResultEvent`

public class InventoryEvent extends Event
Represents a player related inventory event

## Nested Class Summary

## Nested classes/interfaces inherited from class org.bukkit.event.Event

`Event.Result`

## Field Summary

Fields
Modifier and Type
Field
Description
`protected InventoryView`
`transaction`

## Constructor Summary

Constructors
Constructor
Description
`InventoryEvent(@NotNull InventoryView transaction)`

## Method Summary

Modifier and Type
Method
Description
`static @NotNull HandlerList`
`getHandlerList()`
`@NotNull HandlerList`
`getHandlers()`
`@NotNull Inventory`
`getInventory()`
Gets the primary Inventory involved in this transaction
`@NotNull InventoryView`
`getView()`
Gets the view object itself
`@NotNull List<HumanEntity>`
`getViewers()`
Gets the list of players viewing the primary (upper) inventory involved in this event

### Methods inherited from class org.bukkit.event.Event

`callEvent, getEventName, isAsynchronous`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### transaction

protected InventoryView transaction

## Constructor Details

### InventoryEvent

public InventoryEvent(@NotNull @NotNull InventoryView transaction)

## Method Details

### getInventory

@NotNull public @NotNull Inventory getInventory()
Gets the primary Inventory involved in this transaction

Returns:
  The upper inventory.

### getViewers

@NotNull public @NotNull List<HumanEntity> getViewers()
Gets the list of players viewing the primary (upper) inventory involved in this event

Returns:
  A list of people viewing.

### getView

@NotNull public @NotNull InventoryView getView()
Gets the view object itself

Returns:
  InventoryView

### getHandlers

@NotNull public @NotNull HandlerList getHandlers()

Specified by:
  `getHandlers` in class `Event`

### getHandlerList

@NotNull public static @NotNull HandlerList getHandlerList()