Package com.wdiscute.starcatcher.recipe
Record Class NetheriteUpgradeSmithingRecipeBuilder.Result
java.lang.Object
java.lang.Record
com.wdiscute.starcatcher.recipe.NetheriteUpgradeSmithingRecipeBuilder.Result
- All Implemented Interfaces:
net.minecraft.data.recipes.FinishedRecipe
- Enclosing class:
- NetheriteUpgradeSmithingRecipeBuilder
public static record NetheriteUpgradeSmithingRecipeBuilder.Result(net.minecraft.resources.ResourceLocation id, net.minecraft.world.item.crafting.RecipeSerializer<?> type, net.minecraft.world.item.crafting.Ingredient template, net.minecraft.world.item.crafting.Ingredient base, net.minecraft.world.item.crafting.Ingredient addition, net.minecraft.advancements.Advancement.Builder advancement, net.minecraft.resources.ResourceLocation advancementId)
extends Record
implements net.minecraft.data.recipes.FinishedRecipe
-
Constructor Summary
ConstructorsConstructorDescriptionResult(net.minecraft.resources.ResourceLocation id, net.minecraft.world.item.crafting.RecipeSerializer<?> type, net.minecraft.world.item.crafting.Ingredient template, net.minecraft.world.item.crafting.Ingredient base, net.minecraft.world.item.crafting.Ingredient addition, net.minecraft.advancements.Advancement.Builder advancement, net.minecraft.resources.ResourceLocation advancementId) Creates an instance of aResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.item.crafting.Ingredientaddition()Returns the value of theadditionrecord component.net.minecraft.advancements.Advancement.BuilderReturns the value of theadvancementrecord component.net.minecraft.resources.ResourceLocationReturns the value of theadvancementIdrecord component.net.minecraft.world.item.crafting.Ingredientbase()Returns the value of thebaserecord component.final booleanIndicates whether some other object is "equal to" this one.net.minecraft.resources.ResourceLocationnet.minecraft.resources.ResourceLocationgetId()net.minecraft.world.item.crafting.RecipeSerializer<?>getType()final inthashCode()Returns a hash code value for this object.net.minecraft.resources.ResourceLocationid()Returns the value of theidrecord component.com.google.gson.JsonObjectvoidserializeRecipeData(com.google.gson.JsonObject main) net.minecraft.world.item.crafting.Ingredienttemplate()Returns the value of thetemplaterecord component.final StringtoString()Returns a string representation of this record class.net.minecraft.world.item.crafting.RecipeSerializer<?>type()Returns the value of thetyperecord component.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.data.recipes.FinishedRecipe
serializeRecipe
-
Constructor Details
-
Result
public Result(net.minecraft.resources.ResourceLocation id, net.minecraft.world.item.crafting.RecipeSerializer<?> type, net.minecraft.world.item.crafting.Ingredient template, net.minecraft.world.item.crafting.Ingredient base, net.minecraft.world.item.crafting.Ingredient addition, net.minecraft.advancements.Advancement.Builder advancement, net.minecraft.resources.ResourceLocation advancementId) Creates an instance of aResultrecord class.- Parameters:
id- the value for theidrecord componenttype- the value for thetyperecord componenttemplate- the value for thetemplaterecord componentbase- the value for thebaserecord componentaddition- the value for theadditionrecord componentadvancement- the value for theadvancementrecord componentadvancementId- the value for theadvancementIdrecord component
-
-
Method Details
-
serializeRecipeData
public void serializeRecipeData(com.google.gson.JsonObject main) - Specified by:
serializeRecipeDatain interfacenet.minecraft.data.recipes.FinishedRecipe
-
getId
public net.minecraft.resources.ResourceLocation getId()- Specified by:
getIdin interfacenet.minecraft.data.recipes.FinishedRecipe
-
getType
public net.minecraft.world.item.crafting.RecipeSerializer<?> getType()- Specified by:
getTypein interfacenet.minecraft.data.recipes.FinishedRecipe
-
serializeAdvancement
@Nullable public com.google.gson.JsonObject serializeAdvancement()- Specified by:
serializeAdvancementin interfacenet.minecraft.data.recipes.FinishedRecipe
-
getAdvancementId
@Nullable public net.minecraft.resources.ResourceLocation getAdvancementId()- Specified by:
getAdvancementIdin interfacenet.minecraft.data.recipes.FinishedRecipe
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
id
public net.minecraft.resources.ResourceLocation id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
type
public net.minecraft.world.item.crafting.RecipeSerializer<?> type()Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-
template
public net.minecraft.world.item.crafting.Ingredient template()Returns the value of thetemplaterecord component.- Returns:
- the value of the
templaterecord component
-
base
public net.minecraft.world.item.crafting.Ingredient base()Returns the value of thebaserecord component.- Returns:
- the value of the
baserecord component
-
addition
public net.minecraft.world.item.crafting.Ingredient addition()Returns the value of theadditionrecord component.- Returns:
- the value of the
additionrecord component
-
advancement
public net.minecraft.advancements.Advancement.Builder advancement()Returns the value of theadvancementrecord component.- Returns:
- the value of the
advancementrecord component
-
advancementId
public net.minecraft.resources.ResourceLocation advancementId()Returns the value of theadvancementIdrecord component.- Returns:
- the value of the
advancementIdrecord component
-