* Initializes this listener. Instantiates and links message handlers. O
*/
public void initialize(UimaAsContext context) throws Exception {
MetadataRequestHandler_impl metaRequestHandler = new MetadataRequestHandler_impl(
"MetadataRequestHandler");
ProcessRequestHandler_impl processRequestHandler = new ProcessRequestHandler_impl(
"ProcessRequestHandler");
metaRequestHandler.setController(controller);
processRequestHandler.setController(controller);
handler = processRequestHandler;
if (controller instanceof AggregateAnalysisEngineController) {
ProcessResponseHandler processResponseHandler = new ProcessResponseHandler(
"ProcessResponseHandler");
processResponseHandler.setController(controller);
processResponseHandler.setDelegate(metaRequestHandler);
processRequestHandler.setDelegate(processResponseHandler);
MetadataResponseHandler_impl metadataResponseHandler = new MetadataResponseHandler_impl(
"MetadataResponseHandler");
metadataResponseHandler.setController(controller);
metaRequestHandler.setDelegate(metadataResponseHandler);
} else {
processRequestHandler.setDelegate(metaRequestHandler);
}
latch.countDown();
}