Class OnyxNamespaceImpl

java.lang.Object
com.zombienw.onyxlib.impl.registry.OnyxNamespaceImpl
All Implemented Interfaces:
OnyxNamespace

public class OnyxNamespaceImpl extends Object implements OnyxNamespace
  • Constructor Details

    • OnyxNamespaceImpl

      public OnyxNamespaceImpl(Plugin plugin, String namespaceId)
  • Method Details

    • getKey

      public NamespacedKey getKey()
      Description copied from interface: OnyxNamespace
      Gets the key associated with this namespace.
      Specified by:
      getKey in interface OnyxNamespace
      Returns:
      The underlying Bukkit NamespacedKey.
    • getPlugin

      public Plugin getPlugin()
    • item

      public OnyxItem item(String id)
      Description copied from interface: OnyxNamespace
      Retrieves an existing OnyxItem or creates a new one if it doesn't exist.
      Specified by:
      item in interface OnyxNamespace
      Parameters:
      id - The unique identifier for the item (e.g., "strawberry").
      Returns:
      The OnyxItem configuration and creation wrapper.
    • lock

      public void lock()
    • getItems

      public Collection<OnyxItemImpl> getItems()
      Used for pack generation
    • getItem

      public OnyxItemImpl getItem(String id)
      Used for item search