Enum Class CustomBlock

java.lang.Object
java.lang.Enum<CustomBlock>
org.strassburger.lifestealz.util.customblocks.CustomBlock
All Implemented Interfaces:
Serializable, Comparable<CustomBlock>, Constable

public enum CustomBlock extends Enum<CustomBlock>
  • Enum Constant Details

    • REVIVE_BEACON

      public static final CustomBlock REVIVE_BEACON
  • Method Details

    • values

      public static CustomBlock[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static CustomBlock valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getKey

      public String getKey()
    • make

      public void make(org.bukkit.block.Block block)
      Tags a block with the custom block key
      Parameters:
      block - The block to tag
    • make

      public void make(org.bukkit.block.Block block, String customItemId)
      Tags a block with the custom block key and a custom item ID
      Parameters:
      block - The block to tag
      customItemId - The custom item ID to associate with the block
    • is

      public boolean is(org.bukkit.block.Block block)
      Checks if a block is tagged with this custom block key
      Parameters:
      block - The block to check
      Returns:
      true if the block is tagged with this custom block key, false otherwise
    • getCustomItemId

      public String getCustomItemId(org.bukkit.block.Block block)
      Retrieves the custom item ID associated with a block
      Parameters:
      block - The block to retrieve the custom item ID from
      Returns:
      The custom item ID, or null if not found
    • fromKey

      public static CustomBlock fromKey(String key)
      Retrieves a CustomBlock from its key
      Parameters:
      key - The key of the custom block to retrieve
      Returns:
      The CustomBlock associated with the key, or null if not found