Package de.z0rdak.yawp.core.flag
Enum Class RegionFlag
- All Implemented Interfaces:
Serializable,Comparable<RegionFlag>,Constable
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescription -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanChecks if a flagIdentifier is defined within the RegionFlag enum.static RegionFlagstatic Optional<RegionFlag>fromString(String flagIdentifier) static Set<RegionFlag>Returns a set of all flags with their string representation defined within this enum.static Set<RegionFlag>getFlags()static Set<RegionFlag>static Set<RegionFlag>getFlagsMatchingCategory(FlagTag category) static booleanhasCategory(RegionFlag regionFlag, FlagTag category) static booleanhasPlayerCategory(IFlag flag) static booleanhasPlayerCategory(RegionFlag regionFlag) booleanstatic booleanmatchesCategory(RegionFlag regionFlag, Set<String> categories) toString()static RegionFlagReturns the enum constant of this class with the specified name.static RegionFlag[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ANIMAL_BREEDING
-
ANIMAL_MOUNTING
-
ANIMAL_TAMING
-
ANIMAL_UNMOUNTING
-
AXE_STRIP
-
BREAK_BLOCKS
-
CONTAINER_ACCESS
-
DRAGON_BLOCK_PROT
-
DROP_LOOT_ALL
-
DROP_LOOT_PLAYER
-
ENDERMAN_GRIEFING
-
ENDERMAN_TELEPORT_FROM_REGION
-
ENDER_CHEST_ACCESS
-
ENTER_DIM
-
EXECUTE_COMMAND
-
EXPLOSION_BLOCK
-
EXPLOSION_CREEPER_BLOCK
-
EXPLOSION_CREEPER_ENTITY
-
EXPLOSION_ENTITY
-
FALL_DAMAGE
-
FALL_DAMAGE_ANIMALS
-
FALL_DAMAGE_MONSTERS
-
FALL_DAMAGE_PLAYERS
-
FALL_DAMAGE_VILLAGERS
-
FLUID_FLOW
-
HOE_TILL
-
IGNITE_EXPLOSIVES
-
INVINCIBLE
-
ITEM_DROP
-
ITEM_PICKUP
-
KNOCKBACK_PLAYERS
-
LAVA_FLOW
-
LEVEL_FREEZE
-
LIGHTNING_PROT
-
NO_WALKER_FREEZE
-
LEAF_DECAY
-
FIRE_TICK
-
MELEE_ANIMALS
-
MELEE_MONSTERS
-
MELEE_PLAYERS
-
MELEE_VILLAGERS
-
MELEE_WANDERING_TRADER
-
MOB_GRIEFING
-
NO_FLIGHT
-
NO_ITEM_DESPAWN
-
NO_PVP
-
FIRE_BOW
-
NO_SIGN_EDIT
-
PLACE_BLOCKS
-
PLACE_FLUIDS
-
SCOOP_FLUIDS
-
SEND_MESSAGE
-
SET_SPAWN
-
SHOVEL_PATH
-
SHULKER_TELEPORT_FROM_REGION
-
SLEEP
-
SNOW_FALL
-
SNOW_MELTING
-
SPAWNING_ALL
-
SPAWNING_ANIMAL
-
SPAWNING_GOLEM
-
SPAWNING_MONSTER
-
SPAWNING_SLIME
-
SPAWNING_TRADER
-
SPAWNING_VILLAGER
-
SPAWNING_XP
-
SPAWN_PORTAL
-
TOOL_SECONDARY_USE
-
TRAMPLE_FARMLAND
-
TRAMPLE_FARMLAND_OTHER
-
TRAMPLE_FARMLAND_PLAYER
-
USE_BLOCKS
-
USE_BONEMEAL
-
USE_ELYTRA
-
USE_ENDERPEARL_FROM_REGION
-
USE_ENDERPEARL_TO_REGION
-
USE_ENTITIES
-
USE_ITEMS
-
USE_PORTAL
-
USE_PORTAL_ANIMALS
-
USE_PORTAL_ITEMS
-
USE_PORTAL_MINECARTS
-
USE_PORTAL_MONSTERS
-
USE_PORTAL_PLAYERS
-
USE_PORTAL_VILLAGERS
-
WATER_FLOW
-
WITHER_BLOCK_PROT
-
KEEP_XP
-
XP_DROP_ALL
-
XP_DROP_MONSTER
-
XP_DROP_OTHER
-
XP_DROP_PLAYER
-
XP_FREEZE
-
XP_PICKUP
-
ZOMBIE_DOOR_PROT
-
-
Field Details
-
name
-
type
-
categories
-
-
Method Details
-
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
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 nameNullPointerException- if the argument is null
-
contains
Checks if a flagIdentifier is defined within the RegionFlag enum. Replaces the check of FlagsList.VALID_FLAGS.contains(flag).- Parameters:
flagIdentifier- to be checked- Returns:
- true if flagIdentifier is defined within this enum, false otherwise
-
getFlagNames
Returns a set of all flags with their string representation defined within this enum.- Returns:
- a set of all flagIdentifiers defined within RegionFlag
-
getFlags
-
getFlags
-
fromString
-
getBoolFlags
-
getFlagsMatchingCategory
-
hasPlayerCategory
-
hasPlayerCategory
-
hasCategory
-
matchesCategory
-
fromId
- Throws:
IllegalArgumentException
-
toString
- Overrides:
toStringin classEnum<RegionFlag>
-
isBeneficial
public boolean isBeneficial()
-