Package org.cloudburstmc.netty.signaling
Record Class ProviderClient.Health
java.lang.Object
java.lang.Record
org.cloudburstmc.netty.signaling.ProviderClient.Health
- Enclosing class:
- ProviderClient
public static record ProviderClient.Health(boolean acceptingPlayers, int capacity, ProviderClient.Software software, ProviderClient.ConnectedPlayers connectedPlayers)
extends Record
Capacity and connectedPlayers describe the same observation.
-
Constructor Summary
ConstructorsConstructorDescriptionHealth(boolean acceptingPlayers, int capacity, ProviderClient.Software software, ProviderClient.ConnectedPlayers connectedPlayers) Creates an instance of aHealthrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of theacceptingPlayersrecord component.intcapacity()Returns the value of thecapacityrecord component.Returns the value of theconnectedPlayersrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.software()Returns the value of thesoftwarerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Health
public Health(boolean acceptingPlayers, int capacity, ProviderClient.Software software, ProviderClient.ConnectedPlayers connectedPlayers) Creates an instance of aHealthrecord class.- Parameters:
acceptingPlayers- the value for theacceptingPlayersrecord componentcapacity- the value for thecapacityrecord componentsoftware- the value for thesoftwarerecord componentconnectedPlayers- the value for theconnectedPlayersrecord 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 '=='. -
acceptingPlayers
public boolean acceptingPlayers()Returns the value of theacceptingPlayersrecord component.- Returns:
- the value of the
acceptingPlayersrecord component
-
capacity
public int capacity()Returns the value of thecapacityrecord component.- Returns:
- the value of the
capacityrecord component
-
software
Returns the value of thesoftwarerecord component.- Returns:
- the value of the
softwarerecord component
-
connectedPlayers
Returns the value of theconnectedPlayersrecord component.- Returns:
- the value of the
connectedPlayersrecord component
-