Depending on the chosen factory method, the information
can be retrieved directly from the channel or additionally
using the "Forwarded", or "X-Forwarded-*"
HTTP request headers.
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final InetSocketAddress | |
| pack-priv final InetSocketAddress | |
| pack-priv final String |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv static ConnectionInfo | from(Channel channel, HttpRequest request, boolean secured, SocketAddress remoteAddress, BiFunction<ConnectionInfo, HttpRequest, ConnectionInfo> forwardedHeaderHandler)
|
| public InetSocketAddress | |
| public InetSocketAddress | |
| public String | |
| pack-priv static ConnectionInfo | Returns: the connection informationthe current channel c, boolean is transport secure (SSL) secured, InetSocketAddress remoteAddress)Retrieve the connection information from the current connection directly |
| public ConnectionInfo | Returns: a newConnectionInfothe host address hostAddress)Return a new |
| public ConnectionInfo | Returns: a newConnectionInfothe remote address remoteAddress)Return a new |
| public ConnectionInfo | Returns: a newConnectionInfothe connection scheme scheme)Return a new |
| hostAddress | back to summary |
|---|---|
| pack-priv final InetSocketAddress hostAddress | |
| remoteAddress | back to summary |
|---|---|
| pack-priv final InetSocketAddress remoteAddress | |
| scheme | back to summary |
|---|---|
| pack-priv final String scheme | |
| ConnectionInfo | back to summary |
|---|---|
| pack-priv ConnectionInfo(InetSocketAddress hostAddress, InetSocketAddress remoteAddress, String scheme) | |
| from | back to summary |
|---|---|
pack-priv static ConnectionInfo from(Channel channel, HttpRequest request, boolean secured, SocketAddress remoteAddress, BiFunction<ConnectionInfo, HttpRequest, ConnectionInfo> forwardedHeaderHandler)
| |
| getHostAddress | back to summary |
|---|---|
| public InetSocketAddress getHostAddress() Return the host address of the connection.
| |
| getRemoteAddress | back to summary |
|---|---|
| public InetSocketAddress getRemoteAddress() Return the remote address of the connection.
| |
| getScheme | back to summary |
|---|---|
| public String getScheme() Return the connection scheme.
| |
| newConnectionInfo | back to summary |
|---|---|
| pack-priv static ConnectionInfo newConnectionInfo(Channel c, boolean secured, InetSocketAddress remoteAddress) Retrieve the connection information from the current connection directly
| |
| withHostAddress | back to summary |
|---|---|
| public ConnectionInfo withHostAddress(InetSocketAddress hostAddress) Return a new
| |
| withRemoteAddress | back to summary |
|---|---|
| public ConnectionInfo withRemoteAddress(InetSocketAddress remoteAddress) Return a new
| |
| withScheme | back to summary |
|---|---|
| public ConnectionInfo withScheme(String scheme) Return a new
| |