Class ItemsAdderProvider
java.lang.Object
studio.magemonkey.codex.api.items.providers.ItemsAdderProvider
- All Implemented Interfaces:
ICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>
public class ItemsAdderProvider
extends Object
implements ICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface studio.magemonkey.codex.api.items.providers.ICodexItemProvider
ICodexItemProvider.Category -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet an item from the provider.getItem(org.bukkit.inventory.ItemStack itemStack) Get the ItemType of this provider corresponding to the provided ItemStack.booleanisCustomItem(org.bukkit.inventory.ItemStack item) Check if the given item is from this provider.booleanisCustomItemOfId(org.bukkit.inventory.ItemStack item, String id) Check if the given item is from this provider and has the given id.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface studio.magemonkey.codex.api.items.providers.ICodexItemProvider
assertEnabled
-
Field Details
-
NAMESPACE
- See Also:
-
-
Constructor Details
-
ItemsAdderProvider
public ItemsAdderProvider()
-
-
Method Details
-
pluginName
- Specified by:
pluginNamein interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>
-
getNamespace
- Specified by:
getNamespacein interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>
-
getCategory
- Specified by:
getCategoryin interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>
-
getItem
Description copied from interface:ICodexItemProviderGet an item from the provider.- Specified by:
getItemin interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>- Parameters:
id- The id of the item.- Returns:
- The item with the given id.
-
getItem
@Nullable public ItemsAdderProvider.ItemsAdderItemType getItem(org.bukkit.inventory.ItemStack itemStack) Description copied from interface:ICodexItemProviderGet the ItemType of this provider corresponding to the provided ItemStack.- Specified by:
getItemin interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>- Parameters:
itemStack- The item to get the ItemType from.- Returns:
- the ItemType associated to the provided ItemStack, or null if not found.
-
isCustomItem
public boolean isCustomItem(org.bukkit.inventory.ItemStack item) Description copied from interface:ICodexItemProviderCheck if the given item is from this provider.- Specified by:
isCustomItemin interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>- Parameters:
item- The item to check.- Returns:
- Whether the item is from this provider.
-
isCustomItemOfId
Description copied from interface:ICodexItemProviderCheck if the given item is from this provider and has the given id.- Specified by:
isCustomItemOfIdin interfaceICodexItemProvider<ItemsAdderProvider.ItemsAdderItemType>- Parameters:
item- The item to check.id- The id to check.- Returns:
- Whether the item is from this provider and has the given id.
-