2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
10 package eu
.etaxonomy
.cdm
.app
.wp6
.palmae
;
13 import java
.util
.UUID
;
15 import org
.apache
.log4j
.Logger
;
17 import eu
.etaxonomy
.cdm
.app
.common
.CdmDestinations
;
18 import eu
.etaxonomy
.cdm
.app
.images
.ImageImportConfigurator
;
19 import eu
.etaxonomy
.cdm
.database
.ICdmDataSource
;
20 import eu
.etaxonomy
.cdm
.io
.PalmaeImageImport
;
21 import eu
.etaxonomy
.cdm
.io
.common
.CdmDefaultImport
;
22 import eu
.etaxonomy
.cdm
.io
.common
.IImportConfigurator
;
25 * TODO not working at the moment
31 public class PalmaeImageActivator
{
32 @SuppressWarnings("unused")
33 private static final Logger logger
= Logger
.getLogger(PalmaeImageActivator
.class);
35 public static final File sourceFolder
= new File("src/main/resources/images/palmae");
36 private static final ICdmDataSource cdmDestination
= CdmDestinations
.localH2();
38 // set the webserver path to the images
39 private static final String urlString
= "http://wp5.e-taxonomy.eu/media/palmae/images/";
41 static final UUID secUuid
= UUID
.fromString("5f32b8af-0c97-48ac-8d33-6099ed68c625");
43 public static void main (String
[] cowabunga
){
44 ImageImportConfigurator imageConfigurator
= ImageImportConfigurator
.NewInstance(sourceFolder
, cdmDestination
, PalmaeImageImport
.class);
45 imageConfigurator
.setSecUuid(secUuid
);
46 imageConfigurator
.setMediaUrlString(urlString
);
48 CdmDefaultImport
<IImportConfigurator
> importer
= new CdmDefaultImport
<IImportConfigurator
>();
49 //AbstractImageImporter imageImporter = new PalmaeImageActivator();
50 importer
.invoke(imageConfigurator
);