Package net.tnemc.item.paper.platform
Class PaperItemPlatform
java.lang.Object
net.tnemc.item.platform.ItemPlatform<PaperItemStack,org.bukkit.inventory.ItemStack,org.bukkit.inventory.Inventory>
net.tnemc.item.paper.platform.PaperItemPlatform
public class PaperItemPlatform
extends ItemPlatform<PaperItemStack,org.bukkit.inventory.ItemStack,org.bukkit.inventory.Inventory>
PaperItemPlatform
- Since:
- 0.1.7.7
- Author:
- creatorfromhell
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds default configurations or settings to be used by the implementing class.Provides access to the calculations provider for performing various platform-specific operations.createStack
(String material) Creates a new stack based on the given material.@NotNull ItemProvider
<org.bukkit.inventory.ItemStack> Retrieves the default provider for the item stack comparison.@NotNull String
Retrieves the identifier of the default provider for the item stack comparison.initSerialized
(org.json.simple.JSONObject object) Initializes and returns an AbstractItemStack object by deserializing the provided JSON object.static PaperItemPlatform
instance()
locale
(org.bukkit.inventory.ItemStack locale) Converts the given locale stack to an instance ofAbstractItemStack
version()
Methods inherited from class net.tnemc.item.platform.ItemPlatform
addApplicator, addCheck, addEffect, addItemProvider, addMulti, addPersistentDataType, addSerializer, apply, check, check, checkOrder, checkOrder, componentString, converter, effects, getClasses, provider, providerApplies, serializer
-
Method Details
-
createStack
Description copied from class:ItemPlatform
Creates a new stack based on the given material.- Specified by:
createStack
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Parameters:
material
- The material used for creating the stack.- Returns:
- The newly created stack.
-
instance
-
version
- Specified by:
version
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Returns:
- the version that is being used currently
- Since:
- 0.2.0.0
-
addDefaults
Description copied from class:ItemPlatform
Adds default configurations or settings to be used by the implementing class.- Specified by:
addDefaults
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory>
-
defaultProvider
Retrieves the default provider for the item stack comparison.- Specified by:
defaultProvider
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Returns:
- the default provider for the item stack comparison.
- Since:
- 0.2.0.0
-
defaultProviderIdentifier
Retrieves the identifier of the default provider for the item stack comparison.- Specified by:
defaultProviderIdentifier
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Returns:
- The identifier of the default provider for the item stack comparison.
- Since:
- 0.2.0.0
-
calculations
Description copied from class:ItemPlatform
Provides access to the calculations provider for performing various platform-specific operations.- Specified by:
calculations
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Returns:
- An instance of
CalculationsProvider
that handles calculations related to the item platform.
-
locale
Converts the given locale stack to an instance ofAbstractItemStack
- Specified by:
locale
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Parameters:
locale
- the locale to convert- Returns:
- the converted locale of type I
- Since:
- 0.2.0.0
-
initSerialized
Initializes and returns an AbstractItemStack object by deserializing the provided JSON object.- Specified by:
initSerialized
in classItemPlatform<PaperItemStack,
org.bukkit.inventory.ItemStack, org.bukkit.inventory.Inventory> - Parameters:
object
- the JSON object to deserialize- Returns:
- an initialized AbstractItemStack object
- Since:
- 0.2.0.0
-