Package net.staticstudios.menus.menu
Class PagedMenu
java.lang.Object
net.staticstudios.menus.menu.PagedMenu
- All Implemented Interfaces:
Menu,org.bukkit.inventory.InventoryHolder
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.staticstudios.menus.menu.Menu
Menu.Action -
Constructor Summary
ConstructorsConstructorDescriptionPagedMenu(String id, MenuViewer viewer, net.kyori.adventure.text.Component inventoryTitle, @NotNull Map<Menu.Action, List<MenuAction>> actions, String template, char marker, Button fallback, boolean shrinkToFit, List<Button> buttons, @NotNull Map<Character, Button> buttonMappings, @NotNull MenuOptions options) -
Method Summary
Modifier and TypeMethodDescriptionvoid@NotNull ButtongetButton(int slot) Get the button at the given slotgetId()Get the ID of the menu@NotNull org.bukkit.inventory.InventoryGet the options of the menuintgetPage()@NotNull MenuViewerGet the viewer of the menuvoidnextPage()voidopen(boolean clearHistory, boolean pushToHistory) Open the menuvoidvoidrunActions(@NotNull Menu.Action action, @NotNull MenuViewer viewer) Run the actions associated with the given action (type)voidSet the button at the given slotMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.staticstudios.menus.menu.Menu
close, open, updateButton
-
Constructor Details
-
Method Details
-
getButton
Description copied from interface:MenuGet the button at the given slot -
open
public void open(boolean clearHistory, boolean pushToHistory) Description copied from interface:MenuOpen the menu -
getViewer
Description copied from interface:MenuGet the viewer of the menu -
getId
Description copied from interface:MenuGet the ID of the menu -
getOptions
Description copied from interface:MenuGet the options of the menu- Specified by:
getOptionsin interfaceMenu- Returns:
- the options of the menu
-
getPage
public int getPage() -
previousPage
public void previousPage() -
nextPage
public void nextPage() -
getInventory
@NotNull public @NotNull org.bukkit.inventory.Inventory getInventory()- Specified by:
getInventoryin interfaceorg.bukkit.inventory.InventoryHolder