Package com.sk89q.worldedit.bukkit
Enum Class BukkitAdapter
- All Implemented Interfaces:
Serializable
,Comparable<BukkitAdapter>
,Constable
Adapts between Bukkit and WorldEdit equivalent objects.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic ItemStack
adapt
(BaseItemStack item) Create a Bukkit ItemStack from a WorldEdit BaseItemStack.static Player
Create a Bukkit Player from a WorldEdit Player.static CommandSender
Create a Bukkit CommandSender from a WorldEdit Actor.static Location
Create a Bukkit location from a WorldEdit location.static Biome
static BlockData
adapt
(BlockStateHolder block) Create a Bukkit BlockData from a WorldEdit BlockStateHolder.static Material
Create a Bukkit Material form a WorldEdit BlockType.static EntityType
adapt
(EntityType entityType) static Material
Create a Bukkit Material form a WorldEdit ItemType.static World
Create a Bukkit world from a WorldEdit world.static BiomeType
Create a WorldEdit BiomeType from a Bukkit one.static Direction
Create a WorldEdit Direction from a Bukkit BlockFace.static BlockState
Create a WorldEdit BlockState from a Bukkit BlockData.static Actor
adapt
(CommandSender sender) Create a WorldEdit Actor from a Bukkit CommandSender.static Entity
Create a WorldEdit entity from a Bukkit entity.static EntityType
adapt
(EntityType entityType) Create a WorldEdit EntityType from a Bukkit one.static BukkitPlayer
Create a WorldEdit Player from a Bukkit Player.static GameMode
Create a WorldEdit GameMode from a Bukkit one.static BaseItemStack
Create a WorldEdit BaseItemStack from a Bukkit ItemStack.static Location
Create a WorldEdit location from a Bukkit location.static World
Create a WorldEdit world from a Bukkit world.static Location
adapt
(World world, BlockVector3 position) Create a Bukkit location from a WorldEdit position with a Bukkit world.static Location
Create a Bukkit location from a WorldEdit position with a Bukkit world.static Location
Create a Bukkit location from a WorldEdit location with a Bukkit world.static BlockState
asBlockState
(ItemStack itemStack) Create a WorldEdit BlockState from a Bukkit ItemStack.static BlockType
asBlockType
(Material material) Converts a Material to a BlockType.static BlockVector3
asBlockVector
(Location location) Create a WorldEdit BlockVector from a Bukkit location.static BukkitWorld
asBukkitWorld
(World world) Convert any WorldEdit world into an equivalent wrapped Bukkit world.static ItemType
asItemType
(Material material) Converts a Material to a ItemType.static Vector3
Create a WorldEdit Vector from a Bukkit location.static boolean
Checks equality between a WorldEdit BlockType and a Bukkit Material.static BukkitAdapter
Returns the enum constant of this class with the specified name.static BukkitAdapter[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
INSTANCE
-
-
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
-
equals
Checks equality between a WorldEdit BlockType and a Bukkit Material.- Parameters:
blockType
- The WorldEdit BlockTypetype
- The Bukkit Material- Returns:
- If they are equal
-
asBukkitWorld
Convert any WorldEdit world into an equivalent wrapped Bukkit world.If a matching world cannot be found, a
RuntimeException
will be thrown.- Parameters:
world
- the world- Returns:
- a wrapped Bukkit world
-
adapt
Create a WorldEdit world from a Bukkit world.- Parameters:
world
- the Bukkit world- Returns:
- a WorldEdit world
-
adapt
Create a WorldEdit Actor from a Bukkit CommandSender.- Parameters:
sender
- The Bukkit CommandSender- Returns:
- The WorldEdit Actor
-
adapt
Create a WorldEdit Player from a Bukkit Player.- Parameters:
player
- The Bukkit player- Returns:
- The WorldEdit player
-
adapt
Create a Bukkit CommandSender from a WorldEdit Actor.- Parameters:
actor
- The WorldEdit actor- Returns:
- The Bukkit command sender
-
adapt
Create a Bukkit Player from a WorldEdit Player.- Parameters:
player
- The WorldEdit player- Returns:
- The Bukkit player
-
adapt
Create a WorldEdit Direction from a Bukkit BlockFace.- Parameters:
face
- the Bukkit BlockFace- Returns:
- a WorldEdit direction
-
adapt
Create a Bukkit world from a WorldEdit world.- Parameters:
world
- the WorldEdit world- Returns:
- a Bukkit world
-
adapt
Create a WorldEdit location from a Bukkit location.- Parameters:
location
- the Bukkit location- Returns:
- a WorldEdit location
-
adapt
Create a Bukkit location from a WorldEdit location.- Parameters:
location
- the WorldEdit location- Returns:
- a Bukkit location
-
adapt
Create a Bukkit location from a WorldEdit position with a Bukkit world.- Parameters:
world
- the Bukkit worldposition
- the WorldEdit position- Returns:
- a Bukkit location
-
adapt
Create a Bukkit location from a WorldEdit position with a Bukkit world.- Parameters:
world
- the Bukkit worldposition
- the WorldEdit position- Returns:
- a Bukkit location
-
adapt
Create a Bukkit location from a WorldEdit location with a Bukkit world.- Parameters:
world
- the Bukkit worldlocation
- the WorldEdit location- Returns:
- a Bukkit location
-
asVector
Create a WorldEdit Vector from a Bukkit location.- Parameters:
location
- The Bukkit location- Returns:
- a WorldEdit vector
-
asBlockVector
Create a WorldEdit BlockVector from a Bukkit location.- Parameters:
location
- The Bukkit location- Returns:
- a WorldEdit vector
-
adapt
Create a WorldEdit entity from a Bukkit entity.- Parameters:
entity
- the Bukkit entity- Returns:
- a WorldEdit entity
-
adapt
Create a Bukkit Material form a WorldEdit ItemType.- Parameters:
itemType
- The WorldEdit ItemType- Returns:
- The Bukkit Material
-
adapt
Create a Bukkit Material form a WorldEdit BlockType.- Parameters:
blockType
- The WorldEdit BlockType- Returns:
- The Bukkit Material
-
adapt
Create a WorldEdit GameMode from a Bukkit one.- Parameters:
gameMode
- Bukkit GameMode- Returns:
- WorldEdit GameMode
-
adapt
Create a WorldEdit BiomeType from a Bukkit one.- Parameters:
biome
- Bukkit Biome- Returns:
- WorldEdit BiomeType
-
adapt
-
adapt
Create a WorldEdit EntityType from a Bukkit one.- Parameters:
entityType
- Bukkit EntityType- Returns:
- WorldEdit EntityType
-
adapt
-
asBlockType
Converts a Material to a BlockType.- Parameters:
material
- The material- Returns:
- The blocktype
-
asItemType
Converts a Material to a ItemType.- Parameters:
material
- The material- Returns:
- The itemtype
-
adapt
Create a WorldEdit BlockState from a Bukkit BlockData.- Parameters:
blockData
- The Bukkit BlockData- Returns:
- The WorldEdit BlockState
-
adapt
Create a Bukkit BlockData from a WorldEdit BlockStateHolder.- Parameters:
block
- The WorldEdit BlockStateHolder- Returns:
- The Bukkit BlockData
-
asBlockState
Create a WorldEdit BlockState from a Bukkit ItemStack.- Parameters:
itemStack
- The Bukkit ItemStack- Returns:
- The WorldEdit BlockState
- Throws:
WorldEditException
-
adapt
Create a WorldEdit BaseItemStack from a Bukkit ItemStack.- Parameters:
itemStack
- The Bukkit ItemStack- Returns:
- The WorldEdit BaseItemStack
-
adapt
Create a Bukkit ItemStack from a WorldEdit BaseItemStack.- Parameters:
item
- The WorldEdit BaseItemStack- Returns:
- The Bukkit ItemStack
-