public class ServerLatencyComparator extends Object implements Comparator<ServerState>, Serializable
ServerStates based on the latency of the servers.| Modifier and Type | Field and Description |
|---|---|
static Comparator<ServerState> |
COMPARATOR
A singleton instance of the comparator.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compare(ServerState o1,
ServerState o2) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequalspublic static final Comparator<ServerState> COMPARATOR
public int compare(ServerState o1, ServerState o2)
Compares the servers based on their respective average latencies.
compare in interface Comparator<ServerState>Comparator.compare(T, T)Copyright © 2011-2013 Allanbank Consulting, Inc.. All Rights Reserved.