程序包 org.bukkit.material

# 类 Crops

java.lang.Object
org.bukkit.material.MaterialData
org.bukkit.material.Crops

所有已实现的接口:
  `Cloneable`

@Deprecated public class Crops extends MaterialData
已过时。
all usage of MaterialData is deprecated and subject to removal. Use `BlockData`.
Represents the different types of crops in different states of growth.

另请参阅:
  - `Material.LEGACY_CROPS`
  - `Material.LEGACY_CARROT`
  - `Material.LEGACY_POTATO`
  - `Material.LEGACY_BEETROOT_BLOCK`
  - `Material.LEGACY_NETHER_WARTS`

- ## 字段概要

  字段
  修饰符和类型
  字段
  说明
  `protected static final CropState`
  `DEFAULT_STATE`
  已过时。
  `protected static final Material`
  `DEFAULT_TYPE`
  已过时。

- ## 构造器概要

  构造器
  构造器
  说明
  `Crops()`
  已过时。
  Constructs a wheat crop block in the seeded state.
  `Crops(CropState state)`
  已过时。
  Constructs a wheat crop block in the given growth state
  `Crops(Material type)`
  已过时。
  Constructs a crop block of the given type and in the seeded state
  `Crops(Material type, byte data)`
  已过时。
  Magic value
  `Crops(Material type, CropState state)`
  已过时。
  Constructs a crop block of the given type and in the given growth state

- ## 方法概要

  修饰符和类型
  方法
  说明
  `Crops`
  `clone()`
  已过时。
  `CropState`
  `getState()`
  已过时。
  Gets the current growth state of this crop For crops with only four growth states such as beetroot, only the values SEEDED, SMALL, TALL and RIPE will be returned.
  `void`
  `setState(CropState state)`
  已过时。
  Sets the growth state of this crop For crops with only four growth states such as beetroot, the 8 CropStates are mapped into four states: SEEDED, SMALL, TALL and RIPE GERMINATED will change to SEEDED VERY_SMALL will change to SMALL MEDIUM will change to TALL VERY_TALL will change to RIPE
  `String`
  `toString()`
  已过时。

  ### 从类继承的方法 org.bukkit.material.MaterialData

  `equals, getData, getItemType, hashCode, setData, toItemStack, toItemStack`

  ### 从类继承的方法 java.lang.Object

  `finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## 字段详细资料

  - ### DEFAULT_TYPE

    protected static final Material DEFAULT_TYPE
    已过时。

  - ### DEFAULT_STATE

    protected static final CropState DEFAULT_STATE
    已过时。

- ## 构造器详细资料

  - ### Crops

    public Crops()
    已过时。
    Constructs a wheat crop block in the seeded state.

  - ### Crops

    public Crops(CropState state)
    已过时。
    Constructs a wheat crop block in the given growth state
    参数:
      `state` - The growth state of the crops

  - ### Crops

    public Crops(Material type, CropState state)
    已过时。
    Constructs a crop block of the given type and in the given growth state
    参数:
      `type` - The type of crops
      `state` - The growth state of the crops

  - ### Crops

    public Crops(Material type)
    已过时。
    Constructs a crop block of the given type and in the seeded state
    参数:
      `type` - The type of crops

  - ### Crops

    @Deprecated public Crops(Material type, byte data)
    已过时。
    Magic value
    参数:
      `type` - the type
      `data` - the raw data value

- ## 方法详细资料

  - ### getState

    public CropState getState()
    已过时。
    Gets the current growth state of this crop For crops with only four growth states such as beetroot, only the values SEEDED, SMALL, TALL and RIPE will be returned.
    返回:
      CropState of this crop

  - ### setState

    public void setState(CropState state)
    已过时。
    Sets the growth state of this crop For crops with only four growth states such as beetroot, the 8 CropStates are mapped into four states: SEEDED, SMALL, TALL and RIPE GERMINATED will change to SEEDED VERY_SMALL will change to SMALL MEDIUM will change to TALL VERY_TALL will change to RIPE
    参数:
      `state` - New growth state of this crop

  - ### toString

    public String toString()
    已过时。
    覆盖:
      `toString` 在类中 `MaterialData`

  - ### clone

    public Crops clone()
    已过时。
    覆盖:
      `clone` 在类中 `MaterialData`