Record Class RecipeSchemaData
java.lang.Object
java.lang.Record
dev.latvian.mods.kubejs.recipe.schema.RecipeSchemaData
public record RecipeSchemaData(Optional<net.minecraft.resources.ResourceLocation> parent, Optional<net.minecraft.resources.ResourceLocation> overrideType, Optional<net.minecraft.resources.ResourceLocation> recipeFactory, Optional<List<RecipeSchemaData.RecipeKeyData>> keys, Optional<List<RecipeSchemaData.ConstructorData>> constructors, Optional<Map<String,RecipeSchemaFunction>> functions, Map<String,com.google.gson.JsonElement> overrideKeys, Optional<Boolean> hidden, List<String> mappings, Optional<List<String>> unique, Optional<List<RecipePostProcessor>> postProcessors, RecipeSchemaData.MergeData merge)
extends Record
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordstatic final record -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic Function<RecipeTypeRegistryContext, com.mojang.serialization.Codec<RecipeSchemaData>> -
Constructor Summary
ConstructorsConstructorDescriptionRecipeSchemaData(Optional<net.minecraft.resources.ResourceLocation> parent, Optional<net.minecraft.resources.ResourceLocation> overrideType, Optional<net.minecraft.resources.ResourceLocation> recipeFactory, Optional<List<RecipeSchemaData.RecipeKeyData>> keys, Optional<List<RecipeSchemaData.ConstructorData>> constructors, Optional<Map<String, RecipeSchemaFunction>> functions, Map<String, com.google.gson.JsonElement> overrideKeys, Optional<Boolean> hidden, List<String> mappings, Optional<List<String>> unique, Optional<List<RecipePostProcessor>> postProcessors, RecipeSchemaData.MergeData merge) Creates an instance of aRecipeSchemaDatarecord class.RecipeSchemaData(net.minecraft.resources.ResourceLocation parent, net.minecraft.resources.ResourceLocation overrideType, net.minecraft.resources.ResourceLocation recipeFactory, List<RecipeSchemaData.RecipeKeyData> keys, List<RecipeSchemaData.ConstructorData> constructors, Map<String, RecipeSchemaFunction> functions, Map<String, com.google.gson.JsonElement> overrideKeys, boolean hidden, List<String> mappings, List<String> unique, List<RecipePostProcessor> postProcessors, RecipeSchemaData.MergeData merge) -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theconstructorsrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefunctionsrecord component.final inthashCode()Returns a hash code value for this object.hidden()Returns the value of thehiddenrecord component.keys()Returns the value of thekeysrecord component.mappings()Returns the value of themappingsrecord component.merge()Returns the value of themergerecord component.booleanbooleanbooleanbooleanReturns the value of theoverrideKeysrecord component.Optional<net.minecraft.resources.ResourceLocation> Returns the value of theoverrideTyperecord component.Optional<net.minecraft.resources.ResourceLocation> parent()Returns the value of theparentrecord component.Returns the value of thepostProcessorsrecord component.Optional<net.minecraft.resources.ResourceLocation> Returns the value of therecipeFactoryrecord component.final StringtoString()Returns a string representation of this record class.unique()Returns the value of theuniquerecord component.
-
Field Details
-
CODEC
public static Function<RecipeTypeRegistryContext,com.mojang.serialization.Codec<RecipeSchemaData>> CODEC
-
-
Constructor Details
-
RecipeSchemaData
public RecipeSchemaData(net.minecraft.resources.ResourceLocation parent, net.minecraft.resources.ResourceLocation overrideType, net.minecraft.resources.ResourceLocation recipeFactory, List<RecipeSchemaData.RecipeKeyData> keys, List<RecipeSchemaData.ConstructorData> constructors, Map<String, RecipeSchemaFunction> functions, Map<String, com.google.gson.JsonElement> overrideKeys, boolean hidden, List<String> mappings, List<String> unique, List<RecipePostProcessor> postProcessors, RecipeSchemaData.MergeData merge) -
RecipeSchemaData
public RecipeSchemaData(Optional<net.minecraft.resources.ResourceLocation> parent, Optional<net.minecraft.resources.ResourceLocation> overrideType, Optional<net.minecraft.resources.ResourceLocation> recipeFactory, Optional<List<RecipeSchemaData.RecipeKeyData>> keys, Optional<List<RecipeSchemaData.ConstructorData>> constructors, Optional<Map<String, RecipeSchemaFunction>> functions, Map<String, com.google.gson.JsonElement> overrideKeys, Optional<Boolean> hidden, List<String> mappings, Optional<List<String>> unique, Optional<List<RecipePostProcessor>> postProcessors, RecipeSchemaData.MergeData merge) Creates an instance of aRecipeSchemaDatarecord class.- Parameters:
parent- the value for theparentrecord componentoverrideType- the value for theoverrideTyperecord componentrecipeFactory- the value for therecipeFactoryrecord componentkeys- the value for thekeysrecord componentconstructors- the value for theconstructorsrecord componentfunctions- the value for thefunctionsrecord componentoverrideKeys- the value for theoverrideKeysrecord componenthidden- the value for thehiddenrecord componentmappings- the value for themappingsrecord componentunique- the value for theuniquerecord componentpostProcessors- the value for thepostProcessorsrecord componentmerge- the value for themergerecord component
-
-
Method Details
-
mergeKeys
public boolean mergeKeys() -
mergeConstructors
public boolean mergeConstructors() -
mergeUnique
public boolean mergeUnique() -
mergePostProcessors
public boolean mergePostProcessors() -
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). -
parent
Returns the value of theparentrecord component.- Returns:
- the value of the
parentrecord component
-
overrideType
Returns the value of theoverrideTyperecord component.- Returns:
- the value of the
overrideTyperecord component
-
recipeFactory
Returns the value of therecipeFactoryrecord component.- Returns:
- the value of the
recipeFactoryrecord component
-
keys
Returns the value of thekeysrecord component.- Returns:
- the value of the
keysrecord component
-
constructors
Returns the value of theconstructorsrecord component.- Returns:
- the value of the
constructorsrecord component
-
functions
Returns the value of thefunctionsrecord component.- Returns:
- the value of the
functionsrecord component
-
overrideKeys
Returns the value of theoverrideKeysrecord component.- Returns:
- the value of the
overrideKeysrecord component
-
mappings
Returns the value of themappingsrecord component.- Returns:
- the value of the
mappingsrecord component
-
unique
Returns the value of theuniquerecord component.- Returns:
- the value of the
uniquerecord component
-
postProcessors
Returns the value of thepostProcessorsrecord component.- Returns:
- the value of the
postProcessorsrecord component
-
merge
Returns the value of themergerecord component.- Returns:
- the value of the
mergerecord component
-