Enum Class ResourcePackActivationType

java.lang.Object
java.lang.Enum<ResourcePackActivationType>
net.fabricmc.fabric.api.resource.ResourcePackActivationType
All Implemented Interfaces:
Serializable, Comparable<ResourcePackActivationType>, Constable

public enum ResourcePackActivationType extends Enum<ResourcePackActivationType>
Represents the resource pack activation type.
  • Enum Constant Details

    • NORMAL

      public static final ResourcePackActivationType NORMAL
      Normal activation. The user has full control over the activation of the resource pack.
    • DEFAULT_ENABLED

      public static final ResourcePackActivationType DEFAULT_ENABLED
      Enabled by default. The user has still full control over the activation of the resource pack.
    • ALWAYS_ENABLED

      public static final ResourcePackActivationType ALWAYS_ENABLED
      Always enabled. The user cannot disable the resource pack.
  • Method Details

    • values

      public static ResourcePackActivationType[] 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 ResourcePackActivationType 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
    • isEnabledByDefault

      public boolean isEnabledByDefault()
      Returns whether this resource pack will be enabled by default or not.
      Returns:
      true if enabled by default, else false