Package com.plotsquared.core.plot
Class PlotInventory
java.lang.Object
com.plotsquared.core.plot.PlotInventory
-
Constructor Summary
ConstructorsConstructorDescriptionPlotInventory(@NonNull InventoryUtil inventoryUtil, PlotPlayer<?> player, int lines, String name) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()getItem(int index) getItems()intgetLines()static PlotInventorygetOpenPlotInventory(@NonNull PlotPlayer<?> plotPlayer) PlotPlayer<?>getTitle()static booleanhasPlotInventoryOpen(@NonNull PlotPlayer<?> plotPlayer) booleanisOpen()booleanonClick(int index) voidstatic voidremovePlotInventoryOpen(@NonNull PlotPlayer<?> plotPlayer) voidsetItem(int index, PlotItemStack item) Put an item into this inventorybooleansetItemChecked(int index, PlotItemStack item) Put an item into this inventory, while also checking the existence of the material in the current versionstatic voidsetPlotInventoryOpen(@NonNull PlotPlayer<?> plotPlayer, @NonNull PlotInventory plotInventory) void
-
Constructor Details
-
PlotInventory
public PlotInventory(@NonNull InventoryUtil inventoryUtil, PlotPlayer<?> player, int lines, String name)
-
-
Method Details
-
hasPlotInventoryOpen
-
getOpenPlotInventory
-
setPlotInventoryOpen
public static void setPlotInventoryOpen(@NonNull PlotPlayer<?> plotPlayer, @NonNull PlotInventory plotInventory) -
removePlotInventoryOpen
-
onClick
public boolean onClick(int index) -
openInventory
public void openInventory() -
close
public void close() -
setItem
Put an item into this inventory- Parameters:
index- the index (= slot) where to place the itemitem- the item to place- See Also:
-
setItemChecked
Put an item into this inventory, while also checking the existence of the material in the current version- Parameters:
index- the index (= slot) where to place the itemitem- the item to place- Returns:
trueif the item could be placed, otherwisefalse- Since:
- 6.5.0
- See Also:
-
getItem
-
getItems
-
getTitle
-
setTitle
-
isOpen
public boolean isOpen() -
getPlayer
-
getLines
public int getLines()
-