azazali30 commented on issue #314:
URL: https://github.com/apache/uima-uimaj/issues/314#issuecomment-1557071459
below is a jist of main cade i have extracted from my code base
org.apache.uima.util.JCasPool jCasPool = new JCasPool(poolSize, aae)
List<AnalysisEngineDescription> extractors = //list of Annotators
final AnalysisEngineDescription aaeDesc =
org.apache.uima.fit.factory.AnalysisEngineFactory
.createEngineDescription(extractors.toArray(new
AnalysisEngineDescription[extractors.size()]));
AnalysisEngine engine =
org.apache.uima.fit.factory.AnalysisEngineFactory.createEngine(aaeDesc);
for(String text : textsArray) {
try {
//update jcas with text
JCas jcas = jCasPool.getJCas()
engine.process(jCas)
} finally {
jCasPool.releaseJCas(jCas)
}
}``
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]