Record Class ConditionalAdvancement.Adv
java.lang.Object
java.lang.Record
net.minecraftforge.common.crafting.ConditionalAdvancement.Adv
- Enclosing class:
ConditionalAdvancement
private static record ConditionalAdvancement.Adv(ICondition condition, Advancement adv, com.google.gson.JsonObject json)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AdvancementThe field for theadvrecord component.private final IConditionThe field for theconditionrecord component.private final com.google.gson.JsonObjectThe field for thejsonrecord component. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateAdv(ICondition condition, Advancement adv, com.google.gson.JsonObject json) Creates an instance of aAdvrecord class. -
Method Summary
Modifier and TypeMethodDescriptionadv()Returns the value of theadvrecord component.Returns the value of theconditionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.com.google.gson.JsonObjectjson()Returns the value of thejsonrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
condition
The field for theconditionrecord component. -
adv
The field for theadvrecord component. -
json
private final com.google.gson.JsonObject jsonThe field for thejsonrecord component.
-
-
Constructor Details
-
Adv
Creates an instance of aAdvrecord class.- Parameters:
condition- the value for theconditionrecord componentadv- the value for theadvrecord componentjson- the value for thejsonrecord component
-
-
Method Details
-
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). -
condition
Returns the value of theconditionrecord component.- Returns:
- the value of the
conditionrecord component
-
adv
Returns the value of theadvrecord component.- Returns:
- the value of the
advrecord component
-
json
public com.google.gson.JsonObject json()Returns the value of thejsonrecord component.- Returns:
- the value of the
jsonrecord component
-