Class PoolingAsyncClientConnectionManager.InternalConnectionEndpoint
java.lang.Object
org.apache.hc.client5.http.nio.AsyncConnectionEndpoint
org.apache.hc.client5.http.impl.nio.PoolingAsyncClientConnectionManager.InternalConnectionEndpoint
- All Implemented Interfaces:
Closeable
,AutoCloseable
,org.apache.hc.core5.io.ModalCloseable
,org.apache.hc.core5.util.Identifiable
- Enclosing class:
PoolingAsyncClientConnectionManager
static class PoolingAsyncClientConnectionManager.InternalConnectionEndpoint
extends AsyncConnectionEndpoint
implements org.apache.hc.core5.util.Identifiable
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final String
private final AtomicReference
<org.apache.hc.core5.pool.PoolEntry<HttpRoute, ManagedAsyncClientConnection>> -
Constructor Summary
ConstructorsConstructorDescriptionInternalConnectionEndpoint
(org.apache.hc.core5.pool.PoolEntry<HttpRoute, ManagedAsyncClientConnection> poolEntry) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close
(org.apache.hc.core5.io.CloseMode closeMode) (package private) org.apache.hc.core5.pool.PoolEntry
<HttpRoute, ManagedAsyncClientConnection> detach()
void
execute
(String exchangeId, org.apache.hc.core5.http.nio.AsyncClientExchangeHandler exchangeHandler, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, org.apache.hc.core5.http.protocol.HttpContext context) Initiates a message exchange using the given handler.getId()
(package private) org.apache.hc.core5.pool.PoolEntry
<HttpRoute, ManagedAsyncClientConnection> (package private) org.apache.hc.core5.pool.PoolEntry
<HttpRoute, ManagedAsyncClientConnection> boolean
Determines if the connection to the remote endpoint is still open and valid.void
setSocketTimeout
(org.apache.hc.core5.util.Timeout timeout) Sets socket timeout.
-
Field Details
-
poolEntryRef
private final AtomicReference<org.apache.hc.core5.pool.PoolEntry<HttpRoute,ManagedAsyncClientConnection>> poolEntryRef -
id
-
-
Constructor Details
-
InternalConnectionEndpoint
InternalConnectionEndpoint(org.apache.hc.core5.pool.PoolEntry<HttpRoute, ManagedAsyncClientConnection> poolEntry)
-
-
Method Details
-
getId
- Specified by:
getId
in interfaceorg.apache.hc.core5.util.Identifiable
-
getPoolEntry
org.apache.hc.core5.pool.PoolEntry<HttpRoute,ManagedAsyncClientConnection> getPoolEntry() -
getValidatedPoolEntry
org.apache.hc.core5.pool.PoolEntry<HttpRoute,ManagedAsyncClientConnection> getValidatedPoolEntry() -
detach
org.apache.hc.core5.pool.PoolEntry<HttpRoute,ManagedAsyncClientConnection> detach() -
close
public void close(org.apache.hc.core5.io.CloseMode closeMode) - Specified by:
close
in interfaceorg.apache.hc.core5.io.ModalCloseable
-
isConnected
public boolean isConnected()Description copied from class:AsyncConnectionEndpoint
Determines if the connection to the remote endpoint is still open and valid.- Specified by:
isConnected
in classAsyncConnectionEndpoint
-
setSocketTimeout
public void setSocketTimeout(org.apache.hc.core5.util.Timeout timeout) Description copied from class:AsyncConnectionEndpoint
Sets socket timeout.- Specified by:
setSocketTimeout
in classAsyncConnectionEndpoint
- Parameters:
timeout
- the socket timeout.
-
execute
public void execute(String exchangeId, org.apache.hc.core5.http.nio.AsyncClientExchangeHandler exchangeHandler, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, org.apache.hc.core5.http.protocol.HttpContext context) Description copied from class:AsyncConnectionEndpoint
Initiates a message exchange using the given handler.- Specified by:
execute
in classAsyncConnectionEndpoint
- Parameters:
exchangeId
- unique operation ID ornull
.exchangeHandler
- the message exchange handler.pushHandlerFactory
- the push handler factory.context
- the execution context.
-