Package org.apache.hc.core5.reactor
Class IOSessionRequest
- java.lang.Object
-
- org.apache.hc.core5.reactor.IOSessionRequest
-
-
Field Summary
Fields Modifier and Type Field Description (package private) java.lang.Object
attachment
private java.util.concurrent.atomic.AtomicReference<ModalCloseable>
closeableRef
(package private) BasicFuture<IOSession>
future
(package private) java.net.SocketAddress
localAddress
(package private) java.net.SocketAddress
remoteAddress
(package private) NamedEndpoint
remoteEndpoint
(package private) Timeout
timeout
-
Constructor Summary
Constructors Constructor Description IOSessionRequest(NamedEndpoint remoteEndpoint, java.net.SocketAddress remoteAddress, java.net.SocketAddress localAddress, Timeout timeout, java.lang.Object attachment, FutureCallback<IOSession> callback)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
assign(ModalCloseable closeable)
boolean
cancel()
boolean
cancel(boolean mayInterruptIfRunning)
void
completed(ProtocolIOSession ioSession)
void
failed(java.lang.Exception cause)
IOSession
get()
IOSession
get(long timeout, java.util.concurrent.TimeUnit unit)
boolean
isCancelled()
boolean
isDone()
java.lang.String
toString()
-
-
-
Field Detail
-
remoteEndpoint
final NamedEndpoint remoteEndpoint
-
remoteAddress
final java.net.SocketAddress remoteAddress
-
localAddress
final java.net.SocketAddress localAddress
-
timeout
final Timeout timeout
-
attachment
final java.lang.Object attachment
-
future
final BasicFuture<IOSession> future
-
closeableRef
private final java.util.concurrent.atomic.AtomicReference<ModalCloseable> closeableRef
-
-
Constructor Detail
-
IOSessionRequest
public IOSessionRequest(NamedEndpoint remoteEndpoint, java.net.SocketAddress remoteAddress, java.net.SocketAddress localAddress, Timeout timeout, java.lang.Object attachment, FutureCallback<IOSession> callback)
-
-
Method Detail
-
completed
public void completed(ProtocolIOSession ioSession)
-
failed
public void failed(java.lang.Exception cause)
-
cancel
public boolean cancel()
-
cancel
public boolean cancel(boolean mayInterruptIfRunning)
- Specified by:
cancel
in interfacejava.util.concurrent.Future<IOSession>
-
isCancelled
public boolean isCancelled()
- Specified by:
isCancelled
in interfacejava.util.concurrent.Future<IOSession>
-
assign
public void assign(ModalCloseable closeable)
-
isDone
public boolean isDone()
- Specified by:
isDone
in interfacejava.util.concurrent.Future<IOSession>
-
get
public IOSession get() throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
- Specified by:
get
in interfacejava.util.concurrent.Future<IOSession>
- Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
-
get
public IOSession get(long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException, java.util.concurrent.TimeoutException
- Specified by:
get
in interfacejava.util.concurrent.Future<IOSession>
- Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
java.util.concurrent.TimeoutException
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-