Package org.bukkit.inventory
Class StonecuttingRecipe
- java.lang.Object
-
- org.bukkit.inventory.StonecuttingRecipe
-
-
Constructor Summary
Constructors Constructor Description StonecuttingRecipe(@NotNull NamespacedKey key, @NotNull ItemStack result, @NotNull RecipeChoice input)
Create a cooking recipe to craft the specified ItemStack.StonecuttingRecipe(@NotNull NamespacedKey key, @NotNull ItemStack result, @NotNull Material source)
Create a Stonecutting recipe to craft the specified ItemStack.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull String
getGroup()
Get the group of this recipe.@NotNull ItemStack
getInput()
Get the input material.@NotNull RecipeChoice
getInputChoice()
Get the input choice.@NotNull NamespacedKey
getKey()
Return the namespaced identifier for this object.@NotNull ItemStack
getResult()
Get the result of this recipe.void
setGroup(@NotNull String group)
Set the group of this recipe.@NotNull StonecuttingRecipe
setInput(@NotNull Material input)
Sets the input of this cooking recipe.@NotNull StonecuttingRecipe
setInputChoice(@NotNull RecipeChoice input)
Sets the input of this cooking recipe.
-
-
-
Constructor Detail
-
StonecuttingRecipe
public StonecuttingRecipe(@NotNull @NotNull NamespacedKey key, @NotNull @NotNull ItemStack result, @NotNull @NotNull Material source)
Create a Stonecutting recipe to craft the specified ItemStack.- Parameters:
key
- The unique recipe keyresult
- The item you want the recipe to create.source
- The input material.
-
StonecuttingRecipe
public StonecuttingRecipe(@NotNull @NotNull NamespacedKey key, @NotNull @NotNull ItemStack result, @NotNull @NotNull RecipeChoice input)
Create a cooking recipe to craft the specified ItemStack.- Parameters:
key
- The unique recipe keyresult
- The item you want the recipe to create.input
- The input choices.
-
-
Method Detail
-
setInput
@NotNull public @NotNull StonecuttingRecipe setInput(@NotNull @NotNull Material input)
Sets the input of this cooking recipe.- Parameters:
input
- The input material.- Returns:
- The changed recipe, so you can chain calls.
-
getInput
@NotNull public @NotNull ItemStack getInput()
Get the input material.- Returns:
- The input material.
-
setInputChoice
@NotNull public @NotNull StonecuttingRecipe setInputChoice(@NotNull @NotNull RecipeChoice input)
Sets the input of this cooking recipe.- Parameters:
input
- The input choice.- Returns:
- The changed recipe, so you can chain calls.
-
getInputChoice
@NotNull public @NotNull RecipeChoice getInputChoice()
Get the input choice.- Returns:
- The input choice.
-
getResult
@NotNull public @NotNull ItemStack getResult()
Get the result of this recipe.
-
getKey
@NotNull public @NotNull NamespacedKey getKey()
Description copied from interface:Keyed
Return the namespaced identifier for this object.
-
getGroup
@NotNull public @NotNull String getGroup()
Get the group of this recipe. Recipes with the same group may be grouped together when displayed in the client.- Returns:
- recipe group. An empty string denotes no group. May not be null.
-
setGroup
public void setGroup(@NotNull @NotNull String group)
Set the group of this recipe. Recipes with the same group may be grouped together when displayed in the client.- Parameters:
group
- recipe group. An empty string denotes no group. May not be null.
-
-