@Override public void upgradeCorrectionCas(CAS aCas, SourceDocument aDocument) throws UIMAException, IOException { annotationService.upgradeCas(aCas, aDocument, CORRECTION_USER); }
@Override public JCas readCorrectionCas(SourceDocument aDocument) throws IOException { return casStorageService.readCas(aDocument, CORRECTION_USER); }
@Override public File getCasFile(SourceDocument aDocument, String aUser) throws IOException { return casStorageService.getCasFile(aDocument, aUser); }
private JCas getJCas(AnnotatorState aState, AnnotationDocument aDocument) throws IOException { if (aState.getMode().equals(Mode.AUTOMATION) || aState.getMode().equals(Mode.CORRECTION)) { return correctionDocumentService.readCorrectionCas(aState.getDocument()); } else { return documentService.readAnnotationCas(aDocument); } }
public static boolean monitoringEnabeled(ProjectService repository, User user) { for (Project project : repository.listProjects()) { if (repository.isCurator(project, user) || repository.isManager(project, user)) { return true; } } return false; }
/** * change the state of an annotation document. used to re-open closed documents */ private void changeAnnotationDocumentState(SourceDocument aSourceDocument, User aUser, AnnotationDocumentStateTransition aAnnotationDocumentStateTransition) { AnnotationDocument annotationDocument = documentService .getAnnotationDocument(aSourceDocument, aUser); documentService.transitionAnnotationDocumentState(annotationDocument, aAnnotationDocumentStateTransition); } }
public static boolean curationEnabeled(ProjectService repository, User user) { for (Project project : repository.listProjects()) { if (repository.isCurator(project, user)) { return true; } } return false; }
@Override public void deleteCurationCas(SourceDocument aDocument) throws IOException { casStorageService.deleteCas(aDocument, CURATION_USER); }
@Override protected ArrayList<Project> load() { ArrayList<Project> projects; // Load user's projects projects = (ArrayList<Project>) projectService.listAccessibleProjects(currentUser); return projects; } };
/** * @deprecated Use {@link ProjectService#managesAnyProject(User)} */ @Deprecated public static boolean projectSettingsEnabeled(ProjectService repository, User user) { return repository.managesAnyProject(user); }
@Override public void performExclusiveBulkOperation(CasStorageOperation aOperation) throws UIMAException, IOException { synchronized (lock) { aOperation.execute(); } }
private JCas getJCas(AnnotatorState aState, AnnotationDocument aDocument) throws IOException { if (aState.getMode().equals(Mode.AUTOMATION) || aState.getMode().equals(Mode.CORRECTION)) { return correctionDocumentService.readCorrectionCas(aState.getDocument()); } else { return documentService.readAnnotationCas(aDocument); } }
public static boolean monitoringEnabeled(ProjectService repository, User user) { for (Project project : repository.listProjects()) { if (repository.isCurator(project, user) || repository.isManager(project, user)) { return true; } } return false; }
public static boolean curationEnabeled(ProjectService repository, User user) { for (Project project : repository.listProjects()) { if (repository.isCurator(project, user)) { return true; } } return false; }
@Override public void upgradeCorrectionCas(CAS aCas, SourceDocument aDocument) throws UIMAException, IOException { annotationService.upgradeCas(aCas, aDocument, CORRECTION_USER); }
@Override public JCas readCurationCas(SourceDocument aDocument) throws IOException { return casStorageService.readCas(aDocument, CURATION_USER); }
@Override public File getCasFile(SourceDocument aDocument, String aUser) throws IOException { return casStorageService.getCasFile(aDocument, aUser); }
@Override public void performExclusiveBulkOperation(CasStorageOperation aOperation) throws UIMAException, IOException { synchronized (lock) { aOperation.execute(); } }
@Override public void upgradeCurationCas(CAS aCas, SourceDocument aDocument) throws UIMAException, IOException { annotationService.upgradeCas(aCas, aDocument, CURATION_USER); }
@Override public JCas readCorrectionCas(SourceDocument aDocument) throws IOException { return casStorageService.readCas(aDocument, CORRECTION_USER); }