Package net.minestom.server.recipe
Record Class Recipe.Blasting
java.lang.Object
java.lang.Record
net.minestom.server.recipe.Recipe.Blasting
- All Implemented Interfaces:
NetworkBuffer.Writer,Recipe
- Enclosing interface:
Recipe
public static record Recipe.Blasting(String id, String group, RecipeCategory.Cooking category, Recipe.Ingredient ingredient, ItemStack result, float experience, int cookingTime)
extends Record
implements Recipe
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minestom.server.recipe.Recipe
Recipe.Blasting, Recipe.CampfireCooking, Recipe.Ingredient, Recipe.Shaped, Recipe.Shapeless, Recipe.Smelting, Recipe.SmithingTransform, Recipe.SmithingTrim, Recipe.Smoking, Recipe.Stonecutting -
Field Summary
Fields inherited from interface net.minestom.server.recipe.Recipe
MAX_INGREDIENTS -
Constructor Summary
ConstructorsConstructorDescriptionBlasting(@NotNull String id, @NotNull NetworkBuffer reader) Blasting(String id, String group, RecipeCategory.Cooking category, Recipe.Ingredient ingredient, ItemStack result, float experience, int cookingTime) Creates an instance of aBlastingrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncategory()Returns the value of thecategoryrecord component.intReturns the value of thecookingTimerecord component.final booleanIndicates whether some other object is "equal to" this one.floatReturns the value of theexperiencerecord component.group()Returns the value of thegrouprecord component.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.Returns the value of theingredientrecord component.result()Returns the value of theresultrecord component.final StringtoString()Returns a string representation of this record class.@NotNull RecipeTypetype()voidwrite(@NotNull NetworkBuffer writer)
-
Constructor Details
-
Blasting
-
Blasting
public Blasting(String id, String group, RecipeCategory.Cooking category, Recipe.Ingredient ingredient, ItemStack result, float experience, int cookingTime) Creates an instance of aBlastingrecord class.- Parameters:
id- the value for theidrecord componentgroup- the value for thegrouprecord componentcategory- the value for thecategoryrecord componentingredient- the value for theingredientrecord componentresult- the value for theresultrecord componentexperience- the value for theexperiencerecord componentcookingTime- the value for thecookingTimerecord component
-
-
Method Details
-
write
- Specified by:
writein interfaceNetworkBuffer.Writer
-
type
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
id
Returns the value of theidrecord component. -
group
Returns the value of thegrouprecord component.- Returns:
- the value of the
grouprecord component
-
category
Returns the value of thecategoryrecord component.- Returns:
- the value of the
categoryrecord component
-
ingredient
Returns the value of theingredientrecord component.- Returns:
- the value of the
ingredientrecord component
-
result
Returns the value of theresultrecord component.- Returns:
- the value of the
resultrecord component
-
experience
public float experience()Returns the value of theexperiencerecord component.- Returns:
- the value of the
experiencerecord component
-
cookingTime
public int cookingTime()Returns the value of thecookingTimerecord component.- Returns:
- the value of the
cookingTimerecord component
-