return null; // oneway method call; do NOT return anythingl
// not even an empty frame
} else if (Constants.COLLECTION_PROCESS_COMPLETE.equals(op)) {
ct.cleanup();
mAE.collectionProcessComplete();
return new VinciFrame(); // no return value - return empty
// frame
} else if (Constants.IS_STATELESS.equals(op)) {
ct.cleanup();
return new AFrame().fadd("Result", mAE.isStateless());
} else if (Constants.IS_READONLY.equals(op)) {
ct.cleanup();
return new AFrame().fadd("Result", mAE.isReadOnly());
} else if (Constants.GET_SUPPORTED_XCAS_VERSIONS.equals(op)) {
return new AFrame().fadd("Result", Constants.SUPPORTED_XCAS_VERSIONS_RESPONSE);
} else if (Constants.SHUTDOWN.equals(op)) {
stop();
System.exit(1);
}
ct.cleanup();
return new VinciFrame().fadd("Error", "Invalid Operation:" + op);
} catch (Exception e) {
e.printStackTrace();
UIMAFramework.getLogger().log(Level.WARNING, e.getMessage(), e);
// send back a Vinci frame with an Error key, whose value is the
// exception message. Be careful not to try to send a null message,
// since VinciFrame.fadd(key,null) does not add the key at all.
String msg = e.getMessage();
if (msg == null) {
msg = "Error Processing Request";
}
return new VinciFrame().fadd("Error", msg);
}
}