Record Class Inventory.InstanceHealth
java.lang.Object
java.lang.Record
io.agentscope.extensions.aistio.model.Inventory.InstanceHealth
- Enclosing class:
- Inventory
public static record Inventory.InstanceHealth(boolean healthy, String reason, int activeSessions)
extends Record
Liveness of this data plane instance.
-
Constructor Summary
ConstructorsConstructorDescriptionInstanceHealth(boolean healthy, String reason, int activeSessions) Creates an instance of aInstanceHealthrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of theactiveSessionsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanhealthy()Returns the value of thehealthyrecord component.reason()Returns the value of thereasonrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
InstanceHealth
Creates an instance of aInstanceHealthrecord class.- Parameters:
healthy- the value for thehealthyrecord componentreason- the value for thereasonrecord componentactiveSessions- the value for theactiveSessionsrecord 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 '=='. -
healthy
public boolean healthy()Returns the value of thehealthyrecord component.- Returns:
- the value of the
healthyrecord component
-
reason
Returns the value of thereasonrecord component.- Returns:
- the value of the
reasonrecord component
-
activeSessions
public int activeSessions()Returns the value of theactiveSessionsrecord component.- Returns:
- the value of the
activeSessionsrecord component
-