First of all, Java is not my usual language, so I\'m quite basic at it. I need to use it for this particular project, so please be patient, and if I have omitted any relevan
I am able to solve it by setting a blank output stream to system error stream.
System.setErr(new PrintStream(new BlankOutputStream())); // set blank error stream
// ... Add annotators ...
System.setErr(System.err); // Reset to default
Accompanying class is
public class BlankOutputStream extends OutputStream {
@Override
public void write(int b) throws IOException {
// Do nothing
}
}