@Override public String getAnnotator(SpanDeletedEvent aEvent) { return aEvent.getUser(); }
@Override public String getAnnotator(SpanDeletedEvent aEvent) { return aEvent.getUser(); }
/** * Listens to the user deleting an annotation in the main annotation editor. */ @OnEvent public void onAnnotationDeleted(SpanDeletedEvent aEvent) { AnnotatorState state = getModelObject(); ActiveLearningUserState alState = alStateModel.getObject(); // If the user creates a new annotation at the site of the suggestion that is currently // offered to the user, then the AL should move on to the next available suggestion if ( alState.isSessionActive() && (!alState.getSuggestion().isPresent() || ( aEvent.getUser().equals(state.getUser().getUsername()) && aEvent.getDocument().equals(state.getDocument()) && aEvent.getLayer().equals(alState.getLayer()))) ) { reactToAnnotationsBeingCreatedOrDeleted(aEvent.getRequestTarget(), aEvent.getLayer()); } }
/** * Listens to the user deleting an annotation in the main annotation editor. */ @OnEvent public void onAnnotationDeleted(SpanDeletedEvent aEvent) { AnnotatorState state = getModelObject(); ActiveLearningUserState alState = alStateModel.getObject(); // If the user creates a new annotation at the site of the suggestion that is currently // offered to the user, then the AL should move on to the next available suggestion if ( alState.isSessionActive() && (!alState.getSuggestion().isPresent() || ( aEvent.getUser().equals(state.getUser().getUsername()) && aEvent.getDocument().equals(state.getDocument()) && aEvent.getLayer().equals(alState.getLayer()))) ) { reactToAnnotationsBeingCreatedOrDeleted(aEvent.getRequestTarget(), aEvent.getLayer()); } }