org.wildfly.swarm.config.io

## Class Worker<T extends Worker<T>>

- java.lang.Object
- - java.util.AbstractMap<K,V>
  - - java.util.HashMap
    - - org.wildfly.swarm.config.io.Worker<T>

- All Implemented Interfaces:
    Serializable, Cloneable, Map

      public class Worker<T extends Worker<T>>
      extends HashMap

  Defines workers
  See Also:
    Serialized Form

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class java.util.AbstractMap

      `AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>`

    - ### Nested classes/interfaces inherited from interface java.util.Map

      `Map.Entry<K,V>`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Worker(String key)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addPropertyChangeListener(PropertyChangeListener listener)` Adds a property change listener
    `String` | `getKey()`
    `Integer` | `ioThreads()` Specify the number of I/O threads to create for the worker.
    `T` | `ioThreads(Integer value)` Specify the number of I/O threads to create for the worker.
    `void` | `removePropertyChangeListener(PropertyChangeListener listener)` Removes a property change listener
    `Long` | `stackSize()` The stack size (in bytes) to attempt to use for worker threads.
    `T` | `stackSize(Long value)` The stack size (in bytes) to attempt to use for worker threads.
    `Integer` | `taskKeepalive()` Specify the number of milliseconds to keep non-core task threads alive.
    `T` | `taskKeepalive(Integer value)` Specify the number of milliseconds to keep non-core task threads alive.
    `Integer` | `taskMaxThreads()` Specify the maximum number of threads for the worker task thread pool.If not set, default value used which is calculated by formula cpuCount * 16
    `T` | `taskMaxThreads(Integer value)` Specify the maximum number of threads for the worker task thread pool.If not set, default value used which is calculated by formula cpuCount * 16

    - ### Methods inherited from class java.util.HashMap

      `clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values`

    - ### Methods inherited from class java.util.AbstractMap

      `equals, hashCode, toString`

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

      `getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface java.util.Map

      `equals, hashCode`

- - ### Constructor Detail

    - #### Worker

          public Worker(String key)

  - ### Method Detail

    - #### getKey

          public String getKey()

    - #### addPropertyChangeListener

          public void addPropertyChangeListener(PropertyChangeListener listener)

      Adds a property change listener

    - #### removePropertyChangeListener

          public void removePropertyChangeListener(PropertyChangeListener listener)

      Removes a property change listener

    - #### ioThreads

          public Integer ioThreads()

      Specify the number of I/O threads to create for the worker. If not specified, a default will be chosen, which is calculated by cpuCount * 2

    - #### ioThreads

          public T ioThreads(Integer value)

      Specify the number of I/O threads to create for the worker. If not specified, a default will be chosen, which is calculated by cpuCount * 2

    - #### stackSize

          public Long stackSize()

      The stack size (in bytes) to attempt to use for worker threads.

    - #### stackSize

          public T stackSize(Long value)

      The stack size (in bytes) to attempt to use for worker threads.

    - #### taskKeepalive

          public Integer taskKeepalive()

      Specify the number of milliseconds to keep non-core task threads alive.

    - #### taskKeepalive

          public T taskKeepalive(Integer value)

      Specify the number of milliseconds to keep non-core task threads alive.

    - #### taskMaxThreads

          public Integer taskMaxThreads()

      Specify the maximum number of threads for the worker task thread pool.If not set, default value used which is calculated by formula cpuCount * 16

    - #### taskMaxThreads

          public T taskMaxThreads(Integer value)

      Specify the maximum number of threads for the worker task thread pool.If not set, default value used which is calculated by formula cpuCount * 16

Copyright © 2017 JBoss by Red Hat. All rights reserved.