static class NettyRuntime.AvailableProcessorsHolder
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private int |
availableProcessors |
| Constructor and Description |
|---|
AvailableProcessorsHolder() |
| Modifier and Type | Method and Description |
|---|---|
(package private) int |
availableProcessors()
Get the configured number of available processors.
|
(package private) void |
setAvailableProcessors(int availableProcessors)
Set the number of available processors.
|
void setAvailableProcessors(int availableProcessors)
availableProcessors - the number of available processorsjava.lang.IllegalArgumentException - if the specified number of available processors is non-positivejava.lang.IllegalStateException - if the number of available processors is already configuredint availableProcessors()
Runtime.availableProcessors().
This can be overridden by setting the system property "io.netty.availableProcessors" or by invoking
setAvailableProcessors(int) before any calls to this method.