Package dev.aurelium.slate.info
Class PlaceholderInfo
java.lang.Object
dev.aurelium.slate.info.PlaceholderInfo
- Direct Known Subclasses:
TemplatePlaceholderInfo
Represents contextual information about a placeholder in a menu.
-
Constructor Summary
ConstructorsConstructorDescriptionPlaceholderInfo(Slate slate, org.bukkit.entity.Player player, String placeholder, ActiveMenu menu, PlaceholderData data) -
Method Summary
Modifier and TypeMethodDescriptiondata()Gets data about the specific placeholder, such as where it is located (display name or lore), the active style, and list data if applicable.locale()Gets the locale of the player viewing the menu as defined by theGlobalBehavior.localeProvider().menu()Gets theActiveMenuinstance of the menu.Gets the name of the placeholder string being replaced.org.bukkit.entity.Playerplayer()Gets the player viewing the menu.
-
Constructor Details
-
Method Details
-
player
public org.bukkit.entity.Player player()Gets the player viewing the menu.- Returns:
- the player
-
placeholder
Gets the name of the placeholder string being replaced. This is the placeholder string in the menu file without the curly braces.- Returns:
- the placeholder
-
data
Gets data about the specific placeholder, such as where it is located (display name or lore), the active style, and list data if applicable.- Returns:
- the placeholder data
-
locale
Gets the locale of the player viewing the menu as defined by theGlobalBehavior.localeProvider(). If the locale provider is not set, this will always returnLocale.ENGLISH. This is useful if you have player-dependent locales.- Returns:
- the locale of the player
-