public interface ClientConnection
Client connection.
This allows usage of a custom connection for testing - see
DirectClient class.-
Method Summary
Modifier and TypeMethodDescriptionChannel id, mostly used in logs.voidclose()Close the connection.reader()Data reader providing response bytes.voidrelease()Release this connection (for keep-alive, this would return the connection to pool).writer()Data writer the client request writes to.
-
Method Details
-
reader
DataReader reader()Data reader providing response bytes.- Returns:
- reader to read from this connection
-
writer
DataWriter writer()Data writer the client request writes to.- Returns:
- writer to write to this connection
-
release
void release()Release this connection (for keep-alive, this would return the connection to pool). -
close
void close()Close the connection. -
channelId
String channelId()Channel id, mostly used in logs.- Returns:
- id of this channel (connection)
-