From c0827f5df70b84ed701663598a2c4accc4bbf075 Mon Sep 17 00:00:00 2001 From: md_5 Date: Thu, 16 Feb 2017 11:49:26 +1100 Subject: SPIGOT-3068: API for localized item names --- .../java/org/bukkit/inventory/meta/ItemMeta.java | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'src/main') diff --git a/src/main/java/org/bukkit/inventory/meta/ItemMeta.java b/src/main/java/org/bukkit/inventory/meta/ItemMeta.java index fa3efe36..37d2e49e 100644 --- a/src/main/java/org/bukkit/inventory/meta/ItemMeta.java +++ b/src/main/java/org/bukkit/inventory/meta/ItemMeta.java @@ -40,6 +40,30 @@ public interface ItemMeta extends Cloneable, ConfigurationSerializable { */ void setDisplayName(String name); + /** + * Checks for existence of a localized name. + * + * @return true if this has a localized name + */ + boolean hasLocalizedName(); + + /** + * Gets the localized display name that is set. + *

+ * Plugins should check that hasLocalizedName() returns true + * before calling this method. + * + * @return the localized name that is set + */ + String getLocalizedName(); + + /** + * Sets the localized name. + * + * @param name the name to set + */ + void setLocalizedName(String name); + /** * Checks for existence of lore. * -- cgit v1.2.3