Class BookFactory

java.lang.Object
io.artificial.enchantments.internal.book.BookFactory

public final class BookFactory extends Object
Factory for creating EnchantedBook instances.

This factory provides a centralized way to create EnchantedBook APIs bound to a specific ItemStorage implementation.

Since:
0.2.0
  • Method Details

    • create

      @NotNull public static @NotNull EnchantedBook create(@NotNull @NotNull ItemStorage itemStorage)
      Creates a new EnchantedBook API instance.

      The returned instance uses the provided ItemStorage for all enchantment storage operations.

      Parameters:
      itemStorage - the item storage to use (must not be null)
      Returns:
      a new EnchantedBook instance
      Throws:
      NullPointerException - if itemStorage is null
      Since:
      0.2.0