public final class ServerAffinity extends java.lang.Object
Constructor and Description |
---|
ServerAffinity(BackendServer backendServer)
Creates a server affinity for the provided backend server.
|
Modifier and Type | Method and Description |
---|---|
long |
getAffinityEstablishedTime()
Retrieves a timestamp indicating when the affinity was established.
|
BackendServer |
getBackendServer()
Retrieves the backend server to which the affinity is established.
|
java.lang.String |
toString()
Retrieves a string representation of this server affinity object.
|
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this server affinity object to the
provided buffer.
|
public ServerAffinity(BackendServer backendServer)
backendServer
- The backend server with which the affinity is to be
associated.public BackendServer getBackendServer()
public long getAffinityEstablishedTime()
System.currentTimeMillis
or
Date.getTime
.public java.lang.String toString()
toString
in class java.lang.Object
public void toString(java.lang.StringBuilder buffer)
buffer
- The buffer to which the information should be appended.