Cloneable, ConfigurationSerializable, ItemMeta, PersistentDataHolderpublic interface EnchantmentStorageMeta extends ItemMeta
Material.ENCHANTED_BOOK is an example
 of an item with enchantment storage.| Modifier and Type | Method | Description | 
|---|---|---|
boolean | 
addStoredEnchant(Enchantment ench,
                int level,
                boolean ignoreLevelRestriction) | 
 Stores the specified enchantment in this item meta. 
 | 
EnchantmentStorageMeta | 
clone() | 
|
int | 
getStoredEnchantLevel(Enchantment ench) | 
 Checks for the level of the stored enchantment. 
 | 
Map<Enchantment,Integer> | 
getStoredEnchants() | 
 Gets a copy the stored enchantments in this ItemMeta. 
 | 
boolean | 
hasConflictingStoredEnchant(Enchantment ench) | 
 Checks if the specified enchantment conflicts with any enchantments in
 this ItemMeta. 
 | 
boolean | 
hasStoredEnchant(Enchantment ench) | 
 Checks for storage of the specified enchantment. 
 | 
boolean | 
hasStoredEnchants() | 
 Checks for the existence of any stored enchantments. 
 | 
boolean | 
removeStoredEnchant(Enchantment ench) | 
 Remove the specified stored enchantment from this item meta. 
 | 
serializeaddAttributeModifier, addEnchant, addItemFlags, getAttributeModifiers, getAttributeModifiers, getAttributeModifiers, getCustomModelData, getCustomTagContainer, getDisplayName, getEnchantLevel, getEnchants, getItemFlags, getLocalizedName, getLore, hasAttributeModifiers, hasConflictingEnchant, hasCustomModelData, hasDisplayName, hasEnchant, hasEnchants, hasItemFlag, hasLocalizedName, hasLore, isUnbreakable, removeAttributeModifier, removeAttributeModifier, removeAttributeModifier, removeEnchant, removeItemFlags, setAttributeModifiers, setCustomModelData, setDisplayName, setLocalizedName, setLore, setUnbreakable, setVersiongetPersistentDataContainerboolean hasStoredEnchants()
boolean hasStoredEnchant(@NotNull
                         Enchantment ench)
ench - enchantment to checkint getStoredEnchantLevel(@NotNull
                          Enchantment ench)
ench - enchantment to check@NotNull Map<Enchantment,Integer> getStoredEnchants()
boolean addStoredEnchant(@NotNull
                         Enchantment ench,
                         int level,
                         boolean ignoreLevelRestriction)
ench - Enchantment to storelevel - Level for the enchantmentignoreLevelRestriction - this indicates the enchantment should be
     applied, ignoring the level limitIllegalArgumentException - if enchantment is nullboolean removeStoredEnchant(@NotNull
                            Enchantment ench)
                     throws IllegalArgumentException
ench - Enchantment to removeIllegalArgumentException - if enchantment is nullboolean hasConflictingStoredEnchant(@NotNull
                                    Enchantment ench)
ench - enchantment to test@NotNull EnchantmentStorageMeta clone()
Copyright © 2019. All rights reserved.