Bukkit-API  1.7.9-R0.2
The inofficial Bukkit-API
org.bukkit.material.Crops Class Reference
Inheritance diagram for org.bukkit.material.Crops:
org.bukkit.material.MaterialData

Public Member Functions

 Crops (CropState state)
 
 Crops (final int type)
 
 Crops (final Material type)
 
 Crops (final int type, final byte data)
 
 Crops (final Material type, final byte data)
 
CropState getState ()
 
void setState (CropState state)
 
String toString ()
 
Crops clone ()
 
- Public Member Functions inherited from org.bukkit.material.MaterialData
 MaterialData (final int type)
 
 MaterialData (final Material type)
 
 MaterialData (final int type, final byte data)
 
 MaterialData (final Material type, final byte data)
 
byte getData ()
 
void setData (byte data)
 
Material getItemType ()
 
int getItemTypeId ()
 
ItemStack toItemStack ()
 
ItemStack toItemStack (int amount)
 
String toString ()
 
int hashCode ()
 
boolean equals (Object obj)
 
MaterialData clone ()
 

Detailed Description

Represents the different types of crops.

Definition at line 9 of file Crops.java.

Constructor & Destructor Documentation

org.bukkit.material.Crops.Crops ( final int  type)
Deprecated:
Magic value

Definition at line 24 of file Crops.java.

24  {
25  super(type);
26  }
org.bukkit.material.Crops.Crops ( final int  type,
final byte  data 
)
Deprecated:
Magic value

Definition at line 37 of file Crops.java.

37  {
38  super(type, data);
39  }
org.bukkit.material.Crops.Crops ( final Material  type,
final byte  data 
)
Deprecated:
Magic value

Definition at line 46 of file Crops.java.

46  {
47  super(type, data);
48  }

Member Function Documentation

CropState org.bukkit.material.Crops.getState ( )

Gets the current growth state of this crop

Returns
CropState of this crop

Definition at line 55 of file Crops.java.

References org.bukkit.CropState.getByData(), and org.bukkit.material.MaterialData.getData().

55  {
56  return CropState.getByData(getData());
57  }
void org.bukkit.material.Crops.setState ( CropState  state)

Sets the growth state of this crop

Parameters
stateNew growth state of this crop

Definition at line 64 of file Crops.java.

References org.bukkit.CropState.getData(), and org.bukkit.material.MaterialData.setData().

64  {
65  setData(state.getData());
66  }

The documentation for this class was generated from the following file: