Record Class EntityAttachment
java.lang.Object
java.lang.Record
com.zenith.mc.entity.EntityAttachment
-
Constructor Summary
ConstructorsConstructorDescriptionEntityAttachment(double passenger, double vehicle) Creates an instance of aEntityAttachmentrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.doubleReturns the value of thepassengerrecord component.final StringtoString()Returns a string representation of this record class.doublevehicle()Returns the value of thevehiclerecord component.
-
Constructor Details
-
EntityAttachment
public EntityAttachment(double passenger, double vehicle) Creates an instance of aEntityAttachmentrecord class.- Parameters:
passenger- the value for thepassengerrecord componentvehicle- the value for thevehiclerecord component
-
-
Method Details
-
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 with thecomparemethod from their corresponding wrapper classes. -
passenger
public double passenger()Returns the value of thepassengerrecord component.- Returns:
- the value of the
passengerrecord component
-
vehicle
public double vehicle()Returns the value of thevehiclerecord component.- Returns:
- the value of the
vehiclerecord component
-