try {
if (coder == null) {
openNobleCoder();
}
} catch (Exception e) {
throw (new GateRuntimeException(e));
}
inputAnnotSet = document.getAnnotations(getInputAS());
document.getAnnotations(getOutputAS());
if (inputAnnotSet == null || inputAnnotSet.isEmpty()) {
System.err.println("Null or empty input annotations.");
} else {
AnnotationSet codableSpanAnnotations = inputAnnotSet.get(getInputAnnotationType());
if (codableSpanAnnotations == null || codableSpanAnnotations.size() == 0) {
codableSpanAnnotations = deriveCodableSpansFromDocumentLines();
}
if (codableSpanAnnotations == null || codableSpanAnnotations.isEmpty()) {
throw new GateRuntimeException("NobleCoder Warning:"
+ "No codable spans found for processing!");
}
for (gate.Annotation codableSpanAnnotation : codableSpanAnnotations) {
currentCodableSpanAnnotation = codableSpanAnnotation;
processCodableSpanAnnotation();