Class TagEntry
java.lang.Object
net.minecraft.tags.TagEntry
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<TagEntry> private static final com.mojang.serialization.Codec<TagEntry> private final Identifierprivate final booleanprivate final boolean -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateTagEntry(Identifier id, boolean tag, boolean required) privateTagEntry(ExtraCodecs.TagOrElementLocation elementOrTag, boolean required) -
Method Summary
Modifier and TypeMethodDescription<T> booleanbuild(TagEntry.Lookup<T> lookup, Consumer<T> output) static TagEntryelement(Identifier id) private ExtraCodecs.TagOrElementLocationgetId()booleanbooleanisTag()static TagEntrystatic TagEntrystatic TagEntrytag(Identifier id) toString()booleanverifyIfPresent(Predicate<Identifier> elementCheck, Predicate<Identifier> tagCheck) voidvisitOptionalDependencies(Consumer<Identifier> output) voidvisitRequiredDependencies(Consumer<Identifier> output) (package private) TagEntrywithRequired(boolean required) Returns a copy of this entry with the required flag set to the given parameter.
-
Field Details
-
FULL_CODEC
-
CODEC
-
id
-
tag
private final boolean tag -
required
private final boolean required
-
-
Constructor Details
-
TagEntry
-
TagEntry
-
-
Method Details
-
elementOrTag
-
withRequired
Returns a copy of this entry with the required flag set to the given parameter.- Parameters:
required- whether the new entry is required- Returns:
- a copy of this entry with the required flag set to the given parameter
-
element
-
optionalElement
-
tag
-
optionalTag
-
build
-
visitRequiredDependencies
-
visitOptionalDependencies
-
verifyIfPresent
-
toString
-
getId
-
isRequired
public boolean isRequired() -
isTag
public boolean isTag()
-