Bukkit-API  1.7.9-R0.2
The inofficial Bukkit-API
CraftingInventory.java
1 package org.bukkit.inventory;
2 
3 /**
4  * Interface to the crafting inventories
5  */
6 public interface CraftingInventory extends Inventory {
7 
8  /**
9  * Check what item is in the result slot of this crafting inventory.
10  *
11  * @return The result item.
12  */
14 
15  /**
16  * Get the contents of the crafting matrix.
17  *
18  * @return The contents.
19  */
20  ItemStack[] getMatrix();
21 
22  /**
23  * Set the item in the result slot of the crafting inventory.
24  *
25  * @param newResult The new result item.
26  */
27  void setResult(ItemStack newResult);
28 
29  /**
30  * Replace the contents of the crafting matrix
31  *
32  * @param contents The new contents.
33  * @throws IllegalArgumentException if the length of contents is greater
34  * than the size of the crafting matrix.
35  */
36  void setMatrix(ItemStack[] contents);
37 
38  /**
39  * Get the current recipe formed on the crafting inventory, if any.
40  *
41  * @return The recipe, or null if the current contents don't match any
42  * recipe.
43  */
44  Recipe getRecipe();
45 }
void setMatrix(ItemStack[] contents)
void setResult(ItemStack newResult)