public final class DefaultExecutionContext extends java.lang.Object implements ExecutionContext
ExecutionContext
.Constructor and Description |
---|
DefaultExecutionContext(BufferAllocator bufferAllocator,
IoExecutor ioExecutor,
Executor executor,
ExecutionStrategy executionStrategy)
Create a new instance.
|
Modifier and Type | Method and Description |
---|---|
BufferAllocator |
bufferAllocator()
Return the
BufferAllocator that can be used to allocate Buffer s if needed. |
boolean |
equals(java.lang.Object o) |
ExecutionStrategy |
executionStrategy()
Returns the
ExecutionStrategy associated with this context. |
Executor |
executor()
Get the
Executor that is used to create any asynchronous sources. |
int |
hashCode() |
IoExecutor |
ioExecutor()
Get the
IoExecutor that is used to handle the IO. |
public DefaultExecutionContext(BufferAllocator bufferAllocator, IoExecutor ioExecutor, Executor executor, ExecutionStrategy executionStrategy)
bufferAllocator
- The BufferAllocator
to use for bufferAllocator()
.ioExecutor
- The IoExecutor
to use for ioExecutor()
.executor
- The Executor
to use for executor()
.executionStrategy
- ExecutionStrategy
to use for executionStrategy()
.public BufferAllocator bufferAllocator()
ExecutionContext
BufferAllocator
that can be used to allocate Buffer
s if needed.bufferAllocator
in interface ExecutionContext
BufferAllocator
to usepublic IoExecutor ioExecutor()
ExecutionContext
IoExecutor
that is used to handle the IO.ioExecutor
in interface ExecutionContext
IoExecutor
that is used to handle the.public Executor executor()
ExecutionContext
Executor
that is used to create any asynchronous sources.executor
in interface ExecutionContext
Executor
that is used to create any asynchronous sources.public ExecutionStrategy executionStrategy()
ExecutionContext
ExecutionStrategy
associated with this context.executionStrategy
in interface ExecutionContext
ExecutionStrategy
associated with this context.public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object