textractor.chain
Class TextractorContext
java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap
org.apache.commons.chain.impl.ContextBase
textractor.chain.TextractorContext
- All Implemented Interfaces:
- Serializable, Cloneable, Map, Context
public class TextractorContext
- extends ContextBase
Defines a Context used in a chain of
sentence processing commands.
- See Also:
- Serialized Form
| Nested classes/interfaces inherited from interface java.util.Map |
Map.Entry<K,V> |
TextractorContext
public TextractorContext()
- Create a new
Context.
getWorkQueue
public final BlockingQueue<ArticleSentencesPair> getWorkQueue(Command command)
- Get the queue to process work from.
- Parameters:
command - Command to get the queue for
- Returns:
- A queue of
ArticleSentencesPair objects.
setWorkQueue
public final void setWorkQueue(Command command,
BlockingQueue<ArticleSentencesPair> queue)
- Set the queue to process work from.
- Parameters:
command - Command to set the queue forqueue - the queue to set
getWorkThreads
public List<Future<Boolean>> getWorkThreads()
- Returns:
- the workThreads
setWorkThreads
public void setWorkThreads(List<Future<Boolean>> threads)
- Parameters:
threads - the workThreads to set
getThreadPool
public final ExecutorService getThreadPool()
- An
ExecutorService that can be used to start new threads.
- Returns:
- The thread pool for this chain.
setThreadPool
public final void setThreadPool(ExecutorService pool)
- Define the
ExecutorService that can be used to start new threads.
- Parameters:
pool - The thread pool for this chain.
Copyright © 2003-2008 Institute for Computational Biomedicine, All Rights Reserved.