AnalysisEnginePool
instead.@Deprecated public class TextAnalysisEnginePool extends AnalysisEnginePool
Constructor and Description |
---|
TextAnalysisEnginePool(String aName,
int aNumInstances,
ResourceSpecifier aResourceSpecifier)
Deprecated.
Creates a new TextAnalysisEnginePool.
|
TextAnalysisEnginePool(String aName,
int aNumInstances,
ResourceSpecifier aResourceSpecifier,
Map<String,Object> aResourceInitParams)
Deprecated.
Creates a new TextAnalysisEnginePool.
|
Modifier and Type | Method and Description |
---|---|
protected 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.
|
batchProcessComplete, collectionProcessComplete, destroy, getAnalysisEngine, getAnalysisEngine, getMetaData, getSize, reconfigure, releaseAnalysisEngine, setLogger, setResultSpecification
public TextAnalysisEnginePool(String aName, int aNumInstances, ResourceSpecifier aResourceSpecifier) throws ResourceInitializationException
aName
- the pool nameaNumInstances
- the number of Resource instances in the poolaResourceSpecifier
- specifier that describes how to create the Resource instances for the poolResourceInitializationException
- if the Resource instances could not be createdpublic TextAnalysisEnginePool(String aName, int aNumInstances, ResourceSpecifier aResourceSpecifier, Map<String,Object> aResourceInitParams) throws ResourceInitializationException
aName
- the pool nameaNumInstances
- the number of Resource instances in the poolaResourceSpecifier
- specifier that describes how to create the Resource instances for the poolaResourceInitParams
- additional parameters to be passed to
Resource.initialize(ResourceSpecifier, Map)
methods. May be null if there are
no parameters.ResourceInitializationException
- if the Resource instances could not be createdpublic TextAnalysisEngine getTAE()
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).public void releaseTAE(TextAnalysisEngine aTAE)
aTAE
- the resource to releasepublic TextAnalysisEngine getTAE(long aTimeout)
aTimeout
- the time to wait in milliseconds. A value of <=0 will wait forever.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).protected Class getResourceClass()
AnalysisEnginePool
AnalysisEngine
, but subclasses may override.getResourceClass
in class AnalysisEnginePool
AnalysisEnginePool.getResourceClass()
Copyright © 2006–2022 The Apache Software Foundation. All rights reserved.