@NotExtensible @ThreadSafety(level=INTERFACE_NOT_THREADSAFE) public interface HealthCheckResult extends java.lang.Comparable<HealthCheckResult>, java.util.Comparator<HealthCheckResult>, java.io.Serializable
Modifier and Type | Method and Description |
---|---|
boolean |
betterThan(HealthCheckResult r)
Indicates whether this health check result is considered better than the
provided result.
|
int |
compare(HealthCheckResult r1,
HealthCheckResult r2)
Compares the provided health check results to determine their relative
order in a sorted list.
|
int |
compareTo(HealthCheckResult r)
Compares the provided health check result with this health check result to
determine their relative order in a sorted list.
|
boolean |
equals(java.lang.Object o)
Indicates whether the provided object may be considered equal to this
health check result.
|
java.util.List<java.lang.String> |
getMessages()
Retrieves a list of messages providing additional information about the
reason for the associated state and score.
|
int |
getScore()
Retrieves the numeric score for the associated server, which may be used to
help differentiate the server from other servers with the same state.
|
HealthCheckState |
getState()
Retrieves the health check state for the associated server.
|
long |
getTime()
Retrieves the time that this health check result was created.
|
int |
hashCode()
Retrieves a hash code for this health check result.
|
java.lang.String |
toString()
Retrieves a string representation of this health check result.
|
boolean |
worseThan(HealthCheckResult r)
Indicates whether this health check result is considered worse than the
provided result.
|
HealthCheckState getState()
int getScore()
java.util.List<java.lang.String> getMessages()
long getTime()
int hashCode()
hashCode
in class java.lang.Object
boolean equals(java.lang.Object o)
equals
in interface java.util.Comparator<HealthCheckResult>
equals
in class java.lang.Object
o
- The object for which to make the determination.true
if the provided object may be considered equal to
this health check result, or false
if not.int compareTo(HealthCheckResult r)
compareTo
in interface java.lang.Comparable<HealthCheckResult>
r
- The health check result to be compared with this health check
result. It must not be null
.int compare(HealthCheckResult r1, HealthCheckResult r2)
compare
in interface java.util.Comparator<HealthCheckResult>
r1
- The first health check result to be compared. It must not be
null
.r2
- The second health check result to be compared. It must not be
null
.boolean betterThan(HealthCheckResult r)
r
- The result for which to make the determination. It must not be
null
.true
if this health check result is considered better than
the provided result, or false
if this health check result
is worse than or equivalent to the provided result.boolean worseThan(HealthCheckResult r)
r
- The result for which to make the determination. It must not be
null
.true
if this health check result is considered worse than
the provided result, or false
if this health check result
is better than or equivalent to the provided result.java.lang.String toString()
toString
in class java.lang.Object