Package com.enhancedechest.gui
Class LogMenu
java.lang.Object
com.enhancedechest.gui.LogMenu
Builds the
/ee log <player> viewer: a 54-slot inventory whose top 45 slots hold one ender
chest pane per visit, newest first, and whose bottom row is navigation. A pane's name is who did it
and when; its lore is the time it was open and the change summary (+ added to the chest,
− taken out) on the same tooltip. Clicking a pane opens that visit's snapshot.
All text is rendered eagerly with the viewer's Locale (the plugin's localisation invariant);
item names in the diff come from the client's own translations via Component.translatable().
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intEvent panes per page — the top five rows of a double chest.static final intstatic final intstatic final intBottom-row control slots the listener recognises.static final int -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
PAGE_SIZE
public static final int PAGE_SIZEEvent panes per page — the top five rows of a double chest.- See Also:
-
SLOT_PREV
public static final int SLOT_PREVBottom-row control slots the listener recognises.- See Also:
-
SLOT_SEARCH
public static final int SLOT_SEARCH- See Also:
-
SLOT_CLEAR
public static final int SLOT_CLEAR- See Also:
-
SLOT_NEXT
public static final int SLOT_NEXT- See Also:
-
-
Constructor Details
-
LogMenu
-
-
Method Details
-
build
public org.bukkit.inventory.Inventory build(Locale locale, UUID owner, String ownerName, List<LogEntry> entries, int page, int pageCount, String query) Builds one page of the log viewer.- Parameters:
entries- the page's visits, newest first (at mostPAGE_SIZE)page- 0-based page index (0 = most recent)pageCount- total pages
-