private void mergeSpan(IRequestParameters aRequest, UserAnnotationSegment aCurationUserSegment, JCas aJcas) throws AnnotationException, UIMAException, ClassNotFoundException, IOException { AnnotationDocument clickedAnnotationDocument; AnnotatorState state = aCurationUserSegment.getAnnotatorState(); if (state.getMode().equals(Mode.AUTOMATION) || state.getMode().equals(Mode.CORRECTION)) { // createSpan / getJCas do not require an annotation document in this mode clickedAnnotationDocument = null; } else { SourceDocument sourceDocument = aCurationUserSegment.getAnnotatorState().getDocument(); clickedAnnotationDocument = documentService.getAnnotationDocument(sourceDocument, aCurationUserSegment.getUsername()); } int address = aRequest.getParameterValue(PARAM_ID).toInt(); String spanType = removePrefix(aRequest.getParameterValue(PARAM_TYPE).toString()); createSpan(spanType, state, aJcas, clickedAnnotationDocument, address); }
private void mergeSpan(IRequestParameters aRequest, UserAnnotationSegment aCurationUserSegment, JCas aJcas) throws AnnotationException, UIMAException, ClassNotFoundException, IOException { AnnotationDocument clickedAnnotationDocument; AnnotatorState state = aCurationUserSegment.getAnnotatorState(); if (state.getMode().equals(Mode.AUTOMATION) || state.getMode().equals(Mode.CORRECTION)) { // createSpan / getJCas do not require an annotation document in this mode clickedAnnotationDocument = null; } else { SourceDocument sourceDocument = aCurationUserSegment.getAnnotatorState().getDocument(); clickedAnnotationDocument = documentService.getAnnotationDocument(sourceDocument, aCurationUserSegment.getUsername()); } int address = aRequest.getParameterValue(PARAM_ID).toInt(); String spanType = removePrefix(aRequest.getParameterValue(PARAM_TYPE).toString()); createSpan(spanType, state, aJcas, clickedAnnotationDocument, address); }