Mercurial > hg > openmind
changeset 28:bdba8c108183
clean up.
author | casties |
---|---|
date | Mon, 22 Aug 2016 19:42:34 +0200 |
parents | 8ea716da439f |
children | 5786aa6caeb3 |
files | src/main/java/org/mpi/openmind/batch/Test.java src/main/java/org/mpi/openmind/scripts/DivaImportHttp.java |
diffstat | 2 files changed, 16 insertions(+), 19 deletions(-) [+] |
line wrap: on
line diff
--- a/src/main/java/org/mpi/openmind/batch/Test.java Fri Aug 05 22:18:40 2016 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,17 +0,0 @@ -package org.mpi.openmind.batch; - -import org.mpi.openmind.repository.services.ServiceRegistry; - -public class Test { - - /** - * @param args - */ - public static void main(String[] args) { - // TODO Auto-generated method stub - ServiceRegistry services = new ServiceRegistry(); - services.getPS().dropAssertions(); - - } - -}
--- a/src/main/java/org/mpi/openmind/scripts/DivaImportHttp.java Fri Aug 05 22:18:40 2016 +0200 +++ b/src/main/java/org/mpi/openmind/scripts/DivaImportHttp.java Mon Aug 22 19:42:34 2016 +0200 @@ -42,11 +42,18 @@ public static void execute(){ ServiceRegistry services = new ServiceRegistry(); - createDataModel(services.getWrapper()); + //createDataModel(services.getWrapper()); importData(services.getWrapper()); } - private static void createDataModel(WrapperService ontology){ + /** + * Create and persist data model for DIGITALIZATION and the relation + * is_digitalization_of and the necessary attributes + * for CODEX and WITNESS. + * + * @param ontology + */ + private static void createDataModel(WrapperService ontology) { try { @@ -105,6 +112,13 @@ } + /** + * Downloads a list of Diva manifest files from the repository and checks if + * each manifest has a corresponding DIGITALIZATION object. Creates missing + * DIGITALIZATION objects. + * + * @param omService + */ private static void importData(WrapperService omService){ try { DefaultHttpClient httpclient = new DefaultHttpClient();