Class InvalidEnchantment

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
valorless.rarespawns.exceptions.InvalidEnchantment
All Implemented Interfaces:
Serializable

public class InvalidEnchantment extends RuntimeException
Thrown when an enchantment identifier from configuration cannot be resolved.
See Also:
  • Constructor Details

    • InvalidEnchantment

      public InvalidEnchantment(String message)
      Creates a new InvalidEnchantment with the provided message.
      Parameters:
      message - details about the invalid enchantment
  • Method Details

    • Throw

      public static org.bukkit.enchantments.Enchantment Throw(String message)
      Convenience helper that always throws this exception. Declared return type enables fluent usage inside expressions.
      Parameters:
      message - details about the invalid enchantment
      Returns:
      never returns; always throws InvalidEnchantment
      Throws:
      InvalidEnchantment - always