Record Class FD_HOST.ExternalPingCommand
java.lang.Object
java.lang.Record
org.jgroups.protocols.FD_HOST.ExternalPingCommand
- All Implemented Interfaces:
FD_HOST.PingCommand
- Enclosing class:
FD_HOST
protected static record FD_HOST.ExternalPingCommand(String cmd)
extends Record
implements FD_HOST.PingCommand
- Version:
- 3.5, 3.4.5
- Author:
- Bela Ban
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCreates an instance of aExternalPingCommandrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncmd()Returns the value of thecmdrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanisAlive(InetAddress host, long timeout) Checks whether a given host is alivefinal StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ExternalPingCommand
Creates an instance of aExternalPingCommandrecord class.- Parameters:
cmd- the value for thecmdrecord component
-
-
Method Details
-
isAlive
Description copied from interface:FD_HOST.PingCommandChecks whether a given host is alive- Specified by:
isAlivein interfaceFD_HOST.PingCommand- Parameters:
host- The host to be checked for livenesstimeout- Number of milliseconds to wait for the check to complete- Returns:
- true if the host is alive, else false
- Throws:
Exception
-
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). -
cmd
Returns the value of thecmdrecord component.- Returns:
- the value of the
cmdrecord component
-