Package org.bukkit.inventory.meta
Interface KnowledgeBookMeta
-
- All Superinterfaces:
Cloneable,ConfigurationSerializable,ItemMeta
public interface KnowledgeBookMeta extends ItemMeta
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.bukkit.inventory.meta.ItemMeta
ItemMeta.Spigot
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddRecipe(NamespacedKey... recipes)Adds new recipe to the end of the book.KnowledgeBookMetaclone()List<NamespacedKey>getRecipes()Gets all the recipes in the book.booleanhasRecipes()Checks for the existence of recipes in the book.voidsetRecipes(List<NamespacedKey> recipes)Clears the existing book recipes, and sets the book to use the provided recipes.-
Methods inherited from interface org.bukkit.configuration.serialization.ConfigurationSerializable
serialize
-
Methods inherited from interface org.bukkit.inventory.meta.ItemMeta
addEnchant, addItemFlags, getDisplayName, getEnchantLevel, getEnchants, getItemFlags, getLocalizedName, getLore, hasConflictingEnchant, hasDisplayName, hasEnchant, hasEnchants, hasItemFlag, hasLocalizedName, hasLore, isUnbreakable, removeEnchant, removeItemFlags, setDisplayName, setLocalizedName, setLore, setUnbreakable, spigot
-
-
-
-
Method Detail
-
hasRecipes
boolean hasRecipes()
Checks for the existence of recipes in the book.- Returns:
- true if the book has recipes
-
getRecipes
List<NamespacedKey> getRecipes()
Gets all the recipes in the book.- Returns:
- list of all the recipes in the book
-
setRecipes
void setRecipes(List<NamespacedKey> recipes)
Clears the existing book recipes, and sets the book to use the provided recipes.- Parameters:
recipes- A list of recipes to set the book to use
-
addRecipe
void addRecipe(NamespacedKey... recipes)
Adds new recipe to the end of the book.- Parameters:
recipes- A list of recipe keys
-
clone
KnowledgeBookMeta clone()
-
-