public class ThreadPoolManagerImpl extends Object implements ThreadPoolManager
Constructor and Description |
---|
ThreadPoolManagerImpl() |
Modifier and Type | Method and Description |
---|---|
void |
close() |
ThreadPool |
getDefaultThreadPool()
Returns the first instance of ThreadPool in the ThreadPoolManager
|
ThreadPool |
getThreadPool(int numericIdForThreadpool)
This method will return an instance of the threadpool given a numeric threadpoolId.
|
ThreadPool |
getThreadPool(String threadpoolId)
This method will return an instance of the threadpool given a threadpoolId,
that can be used by any component in the app.
|
ThreadPoolChooser |
getThreadPoolChooser(int componentIndex)
Return an instance of ThreadPoolChooser based on the componentIndex that was
passed as argument.
|
ThreadPoolChooser |
getThreadPoolChooser(String componentId)
Return an instance of ThreadPoolChooser based on the componentId that was
passed as argument
|
int |
getThreadPoolChooserNumericId(String componentId)
Gets the numeric index associated with the componentId specified for a
ThreadPoolChooser.
|
int |
getThreadPoolNumericId(String threadpoolId)
This method is used to return the numeric id of the threadpool, given a String
threadpoolId.
|
String |
getThreadPoolStringId(int numericIdForThreadpool)
Return a String Id for a numericId of a threadpool managed by the threadpool
manager
|
void |
setThreadPoolChooser(String componentId,
ThreadPoolChooser aThreadPoolChooser)
Sets a ThreadPoolChooser for a particular componentId in the ThreadPoolManager.
|
public void close()
close
in interface Closeable
close
in interface AutoCloseable
public ThreadPool getThreadPool(String threadpoolId) throws NoSuchThreadPoolException
getThreadPool
in interface ThreadPoolManager
NoSuchThreadPoolException
- thrown when invalid threadpoolId is passed
as a parameterpublic ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException
getThreadPool
in interface ThreadPoolManager
NoSuchThreadPoolException
- thrown when invalidnumericIdForThreadpool is passed
as a parameterpublic int getThreadPoolNumericId(String threadpoolId)
getThreadPoolNumericId
in interface ThreadPoolManager
public String getThreadPoolStringId(int numericIdForThreadpool)
getThreadPoolStringId
in interface ThreadPoolManager
public ThreadPool getDefaultThreadPool()
getDefaultThreadPool
in interface ThreadPoolManager
public ThreadPoolChooser getThreadPoolChooser(String componentId)
getThreadPoolChooser
in interface ThreadPoolManager
public ThreadPoolChooser getThreadPoolChooser(int componentIndex)
getThreadPoolChooser
in interface ThreadPoolManager
public void setThreadPoolChooser(String componentId, ThreadPoolChooser aThreadPoolChooser)
setThreadPoolChooser
in interface ThreadPoolManager
public int getThreadPoolChooserNumericId(String componentId)
getThreadPoolChooserNumericId
in interface ThreadPoolManager
Copyright © 2019 JBoss by Red Hat. All rights reserved.