@Override public String getAnnotator(AfterAnnotationUpdateEvent aEvent) { return aEvent.getDocument().getUser(); } }
@TransactionalEventListener(fallbackExecution = true) @Transactional public void afterAnnotationUpdate(AfterAnnotationUpdateEvent aEvent) throws Exception { log.trace("Starting afterAnnotationUpdate"); // Schedule new document index process indexScheduler.enqueueIndexDocument(aEvent.getDocument(), aEvent.getJCas()); }
@Override @Transactional public void writeAnnotationCas(JCas aJCas, AnnotationDocument aAnnotationDocument, boolean aUpdateTimestamp) throws IOException { casStorageService.writeCas(aAnnotationDocument.getDocument(), aJCas, aAnnotationDocument.getUser()); if (aUpdateTimestamp) { // FIXME REC Does it really make sense to set the accessed sentence from the source // document?! aAnnotationDocument.setSentenceAccessed( aAnnotationDocument.getDocument().getSentenceAccessed()); aAnnotationDocument.setTimestamp(new Timestamp(new Date().getTime())); setAnnotationDocumentState(aAnnotationDocument, AnnotationDocumentState.IN_PROGRESS); } applicationEventPublisher .publishEvent(new AfterAnnotationUpdateEvent(this, aAnnotationDocument, aJCas)); }
@Override @Transactional public void writeAnnotationCas(JCas aJCas, AnnotationDocument aAnnotationDocument, boolean aUpdateTimestamp) throws IOException { casStorageService.writeCas(aAnnotationDocument.getDocument(), aJCas, aAnnotationDocument.getUser()); if (aUpdateTimestamp) { // FIXME REC Does it really make sense to set the accessed sentence from the source // document?! aAnnotationDocument.setSentenceAccessed( aAnnotationDocument.getDocument().getSentenceAccessed()); aAnnotationDocument.setTimestamp(new Timestamp(new Date().getTime())); setAnnotationDocumentState(aAnnotationDocument, AnnotationDocumentState.IN_PROGRESS); } applicationEventPublisher .publishEvent(new AfterAnnotationUpdateEvent(this, aAnnotationDocument, aJCas)); }
@Override public String getAnnotator(AfterAnnotationUpdateEvent aEvent) { return aEvent.getDocument().getUser(); } }
@TransactionalEventListener(fallbackExecution = true) @Transactional public void afterAnnotationUpdate(AfterAnnotationUpdateEvent aEvent) throws Exception { log.trace("Starting afterAnnotationUpdate"); // Schedule new document index process indexScheduler.enqueueIndexDocument(aEvent.getDocument(), aEvent.getJCas()); }
@EventListener public void afterAnnotationUpdate(AfterAnnotationUpdateEvent aEvent) { triggerTrainingAndClassification(aEvent.getDocument().getUser(), aEvent.getDocument().getProject()); }
@Override public long getDocument(AfterAnnotationUpdateEvent aEvent) { return aEvent.getDocument().getDocument().getId(); }
@Override public long getDocument(AfterAnnotationUpdateEvent aEvent) { return aEvent.getDocument().getDocument().getId(); }
@Override public long getProject(AfterAnnotationUpdateEvent aEvent) { return aEvent.getDocument().getProject().getId(); }
@Override public long getProject(AfterAnnotationUpdateEvent aEvent) { return aEvent.getDocument().getProject().getId(); }