Package net.minecraft.client.realms.dto
Record Class RegionPingResult
java.lang.Object
java.lang.Record
net.minecraft.client.realms.dto.RegionPingResult
- Record Components:
regionName-ping-
- All Implemented Interfaces:
RealmsSerializable
@Environment(CLIENT)
public record RegionPingResult(String regionName, int ping)
extends Record
implements RealmsSerializable
- Mappings:
Namespace Name named net/minecraft/client/realms/dto/RegionPingResultintermediary net/minecraft/class_4886official fzenamed regionNameintermediary comp_5028official anamed pingintermediary comp_5029official b
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final intThe field for thepingrecord component.private final StringThe field for theregionNamerecord component. -
Constructor Summary
ConstructorsConstructorDescriptionRegionPingResult(String regionName, int ping) Creates an instance of aRegionPingResultrecord 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.intping()Returns the value of thepingrecord component.Returns the value of theregionNamerecord component.toString()Returns a string representation of this record class.
-
Field Details
-
regionName
The field for theregionNamerecord component. -
ping
The field for thepingrecord component.
-
-
Constructor Details
-
RegionPingResult
Creates an instance of aRegionPingResultrecord class.- Parameters:
regionName- the value for theregionNamerecord componentping- the value for thepingrecord 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
regionName
Returns the value of theregionNamerecord component.- Returns:
- the value of the
regionNamerecord component
-
ping
Returns the value of thepingrecord component.- Returns:
- the value of the
pingrecord component
-