Record Class Entity.EntityPathElement
java.lang.Object
java.lang.Record
net.minecraft.world.entity.Entity.EntityPathElement
- All Implemented Interfaces:
ProblemReporter.PathElement
- Enclosing class:
Entity
private static record Entity.EntityPathElement(Entity entity)
extends Record
implements ProblemReporter.PathElement
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateEntityPathElement(Entity entity) Creates an instance of aEntityPathElementrecord class. -
Method Summary
Modifier and TypeMethodDescriptionentity()Returns the value of theentityrecord component.final booleanIndicates whether some other object is "equal to" this one.get()final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
entity
The field for theentityrecord component.
-
-
Constructor Details
-
EntityPathElement
Creates an instance of aEntityPathElementrecord class.- Parameters:
entity- the value for theentityrecord component
-
-
Method Details
-
get
- Specified by:
getin interfaceProblemReporter.PathElement
-
toString
-
hashCode
-
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). -
entity
Returns the value of theentityrecord component.- Returns:
- the value of the
entityrecord component
-