Package org.xnio

# Class XnioWorker.Builder

java.lang.Object
org.xnio.XnioWorker.Builder

Enclosing class:
  `XnioWorker`

public static class XnioWorker.Builder extends Object
A builder which allows workers to be programmatically configured.

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`Builder(Xnio xnio)`
Construct a new instance.

## Method Summary

Modifier and Type
Method
Description
`XnioWorker.Builder`
`addBindAddressConfiguration(org.wildfly.common.net.CidrAddress cidrAddress, InetAddress bindAddress)`
`XnioWorker.Builder`
`addBindAddressConfiguration(org.wildfly.common.net.CidrAddress cidrAddress, InetSocketAddress bindAddress)`
`XnioWorker`
`build()`
`org.wildfly.common.net.CidrAddressTable<InetSocketAddress>`
`getBindAddressConfigurations()`
`int`
`getCoreWorkerPoolSize()`
`ExecutorService`
`getExternalExecutorService()`
`int`
`getMaxWorkerPoolSize()`
`Runnable`
`getTerminationTask()`
`ThreadGroup`
`getThreadGroup()`
`int`
`getWorkerIoThreads()`
`long`
`getWorkerKeepAlive()`
`String`
`getWorkerName()`
`long`
`getWorkerStackSize()`
`Xnio`
`getXnio()`
`boolean`
`isDaemon()`
`XnioWorker.Builder`
`populateFromOptions(OptionMap optionMap)`
`XnioWorker.Builder`
`setBindAddressConfigurations(org.wildfly.common.net.CidrAddressTable<InetSocketAddress> newTable)`
`XnioWorker.Builder`
`setCoreWorkerPoolSize(int coreWorkerPoolSize)`
`XnioWorker.Builder`
`setDaemon(boolean daemon)`
`XnioWorker.Builder`
`setExternalExecutorService(ExecutorService executorService)`
`XnioWorker.Builder`
`setMaxWorkerPoolSize(int maxWorkerPoolSize)`
`XnioWorker.Builder`
`setTerminationTask(Runnable terminationTask)`
`XnioWorker.Builder`
`setThreadGroup(ThreadGroup threadGroup)`
`XnioWorker.Builder`
`setWorkerIoThreads(int workerIoThreads)`
`XnioWorker.Builder`
`setWorkerKeepAlive(int workerKeepAlive)`
`XnioWorker.Builder`
`setWorkerName(String workerName)`
`XnioWorker.Builder`
`setWorkerStackSize(long workerStackSize)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### Builder

protected Builder(Xnio xnio)
Construct a new instance.

Parameters:
  `xnio` - the XNIO instance (must not be `null`)

## Method Details

### getXnio

public Xnio getXnio()

### populateFromOptions

public XnioWorker.Builder populateFromOptions(OptionMap optionMap)

### addBindAddressConfiguration

public XnioWorker.Builder addBindAddressConfiguration(org.wildfly.common.net.CidrAddress cidrAddress, InetAddress bindAddress)

### addBindAddressConfiguration

public XnioWorker.Builder addBindAddressConfiguration(org.wildfly.common.net.CidrAddress cidrAddress, InetSocketAddress bindAddress)

### setBindAddressConfigurations

public XnioWorker.Builder setBindAddressConfigurations(org.wildfly.common.net.CidrAddressTable<InetSocketAddress> newTable)

### getBindAddressConfigurations

public org.wildfly.common.net.CidrAddressTable<InetSocketAddress> getBindAddressConfigurations()

### getTerminationTask

public Runnable getTerminationTask()

### setTerminationTask

public XnioWorker.Builder setTerminationTask(Runnable terminationTask)

### getWorkerName

public String getWorkerName()

### setWorkerName

public XnioWorker.Builder setWorkerName(String workerName)

### getCoreWorkerPoolSize

public int getCoreWorkerPoolSize()

### setCoreWorkerPoolSize

public XnioWorker.Builder setCoreWorkerPoolSize(int coreWorkerPoolSize)

### getMaxWorkerPoolSize

public int getMaxWorkerPoolSize()

### setMaxWorkerPoolSize

public XnioWorker.Builder setMaxWorkerPoolSize(int maxWorkerPoolSize)

### getThreadGroup

public ThreadGroup getThreadGroup()

### setThreadGroup

public XnioWorker.Builder setThreadGroup(ThreadGroup threadGroup)

### isDaemon

public boolean isDaemon()

### setDaemon

public XnioWorker.Builder setDaemon(boolean daemon)

### getWorkerKeepAlive

public long getWorkerKeepAlive()

### setWorkerKeepAlive

public XnioWorker.Builder setWorkerKeepAlive(int workerKeepAlive)

### getWorkerIoThreads

public int getWorkerIoThreads()

### setWorkerIoThreads

public XnioWorker.Builder setWorkerIoThreads(int workerIoThreads)

### getWorkerStackSize

public long getWorkerStackSize()

### setWorkerStackSize

public XnioWorker.Builder setWorkerStackSize(long workerStackSize)

### getExternalExecutorService

public ExecutorService getExternalExecutorService()

### setExternalExecutorService

public XnioWorker.Builder setExternalExecutorService(ExecutorService executorService)

### build

public XnioWorker build()