org.apache.uima.internal.util
Class TextAnalysisEnginePool

java.lang.Object
  extended by org.apache.uima.internal.util.AnalysisEnginePool
      extended by org.apache.uima.internal.util.TextAnalysisEnginePool

Deprecated. As of v2.0, use AnalysisEnginePool instead.

@Deprecated
public class TextAnalysisEnginePool
extends AnalysisEnginePool

A pool of Text Analysis Engines, which supports reconfiguration. This is not part of the stable UIMA API and may change in future releases.


Constructor Summary
TextAnalysisEnginePool(java.lang.String aName, int aNumInstances, ResourceSpecifier aResourceSpecifier)
          Deprecated. Creates a new TextAnalysisEnginePool.
TextAnalysisEnginePool(java.lang.String aName, int aNumInstances, ResourceSpecifier aResourceSpecifier, java.util.Map<java.lang.String,java.lang.Object> aResourceInitParams)
          Deprecated. Creates a new TextAnalysisEnginePool.
 
Method Summary
protected  java.lang.Class getResourceClass()
          Deprecated. Gets the class of Resource contained in this pool - by default this is AnalysisEngine, but subclasses may override.
 TextAnalysisEngine getTAE()
          Deprecated. Checks out a TextAnalysisEngine from the pool.
 TextAnalysisEngine getTAE(long aTimeout)
          Deprecated. Checks out a TextAnalysisEngine from the pool.
 void releaseTAE(TextAnalysisEngine aTAE)
          Deprecated. Checks in a TAE to the pool.
 
Methods inherited from class org.apache.uima.internal.util.AnalysisEnginePool
batchProcessComplete, collectionProcessComplete, destroy, getAnalysisEngine, getAnalysisEngine, getMetaData, getSize, reconfigure, releaseAnalysisEngine, setLogger, setResultSpecification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TextAnalysisEnginePool

public TextAnalysisEnginePool(java.lang.String aName,
                              int aNumInstances,
                              ResourceSpecifier aResourceSpecifier)
                       throws ResourceInitializationException
Deprecated. 
Creates a new TextAnalysisEnginePool.

Parameters:
aName - the pool name
aNumInstances - the number of Resource instances in the pool
aResourceSpecifier - specifier that describes how to create the Resource instances for the pool
Throws:
ResourceInitializationException - if the Resource instances could not be created

TextAnalysisEnginePool

public TextAnalysisEnginePool(java.lang.String aName,
                              int aNumInstances,
                              ResourceSpecifier aResourceSpecifier,
                              java.util.Map<java.lang.String,java.lang.Object> aResourceInitParams)
                       throws ResourceInitializationException
Deprecated. 
Creates a new TextAnalysisEnginePool.

Parameters:
aName - the pool name
aNumInstances - the number of Resource instances in the pool
aResourceSpecifier - specifier that describes how to create the Resource instances for the pool
aResourceInitParams - additional parameters to be passed to Resource#initialize(ResourceSpecifier,Map) methods. May be null if there are no parameters.
Throws:
ResourceInitializationException - if the Resource instances could not be created
Method Detail

getTAE

public TextAnalysisEngine getTAE()
Deprecated. 
Checks out a TextAnalysisEngine from the pool.

Returns:
a TAE for use by the client. Returns null if none are available (in which case the client may wait on this object in order to be notified when an instance becomes available).

releaseTAE

public void releaseTAE(TextAnalysisEngine aTAE)
Deprecated. 
Checks in a TAE to the pool. Also notifies other Threads that may be waiting for a connection.

Parameters:
aResource - the resource to release

getTAE

public TextAnalysisEngine getTAE(long aTimeout)
Deprecated. 
Checks out a TextAnalysisEngine from the pool. If none is currently available, wait for the specified amount of time for one to be checked in.

Parameters:
aTimeout - the time to wait in milliseconds. A value of <=0 will wait forever.
Returns:
a TAE for use by the client. Returns null if none are available (in which case the client may wait on this object in order to be notified when an instance becomes available).

getResourceClass

protected java.lang.Class getResourceClass()
Deprecated. 
Description copied from class: AnalysisEnginePool
Gets the class of Resource contained in this pool - by default this is AnalysisEngine, but subclasses may override.

Overrides:
getResourceClass in class AnalysisEnginePool
Returns:
class of Resource contained in this pool
See Also:
AnalysisEnginePool.getResourceClass()


Copyright © 2011. All Rights Reserved.