Package org.bukkit.block

# Interface Bed

All Superinterfaces:
  `BlockState`, `Colorable`, `Metadatable`, `PersistentDataHolder`, `TileState`

public interface Bed extends TileState, Colorable
Represents a captured state of a bed.

## Method Summary

Modifier and Type
Method
Description
`DyeColor`
`getColor()`
Gets the color of this object.
`void`
`setColor(DyeColor color)`
Deprecated, for removal: This API element is subject to removal in a future version.

### Methods inherited from interface org.bukkit.block.BlockState

`getBlock, getBlockData, getChunk, getData, getDrops, getDrops, getDrops, getLightLevel, getLocation, getLocation, getRawData, getType, getWorld, getX, getY, getZ, isCollidable, isPlaced, setBlockData, setData, setRawData, setType, update, update, update`

### Methods inherited from interface org.bukkit.metadata.Metadatable

`getMetadata, hasMetadata, removeMetadata, setMetadata`

### Methods inherited from interface org.bukkit.block.TileState

`getPersistentDataContainer, isSnapshot`

## Method Details

### getColor

@NotNull DyeColor getColor()
Description copied from interface: `Colorable`
Gets the color of this object.
This may be null to represent the default color of an object, if the object has a special default color (e.g Shulkers).

Specified by:
  `getColor` in interface `Colorable`
Returns:
  The DyeColor of this object.

### setColor

@Contract("_ -> fail") @Deprecated(forRemoval=true) void setColor(@UndefinedNullability("not supported") DyeColor color)
Deprecated, for removal: This API element is subject to removal in a future version.
Unsupported

Specified by:
  `setColor` in interface `Colorable`
Parameters:
  `color` - The color of the object, as a DyeColor.
Throws:
  `UnsupportedOperationException` - not supported, set the block type