org.fao.geonet.services.metadata
Class ImportFromDir

java.lang.Object
  extended by org.fao.geonet.services.NotInReadOnlyModeService
      extended by org.fao.geonet.services.metadata.ImportFromDir
All Implemented Interfaces:
Service

public class ImportFromDir
extends NotInReadOnlyModeService

Import all metadata found inside a given directory.


Nested Class Summary
 class ImportFromDir.ImportCallable
           
 class ImportFromDir.ImportMetadataReindexer
           
 
Constructor Summary
ImportFromDir()
           
 
Method Summary
 void init(String appPath, ServiceConfig params)
           
 org.jdom.Element serviceSpecificExec(org.jdom.Element params, ServiceContext context)
          util.import service allow to import metadata in batch mode using 2 different mode: Search for all xml file in given directory and load them Search for a file named import-config.xml in given directory and the import as described in that file. Fail on error parameter is available for directory batch mode.
 
Methods inherited from class org.fao.geonet.services.NotInReadOnlyModeService
exec
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ImportFromDir

public ImportFromDir()
Method Detail

init

public void init(String appPath,
                 ServiceConfig params)
          throws Exception
Specified by:
init in interface Service
Overrides:
init in class NotInReadOnlyModeService
Throws:
Exception

serviceSpecificExec

public org.jdom.Element serviceSpecificExec(org.jdom.Element params,
                                            ServiceContext context)
                                     throws Exception
util.import service allow to import metadata in batch mode using 2 different mode: Fail on error parameter is available for directory batch mode. If true, import stop on first error. Return the number of record inserted and the list of exceptions.

Specified by:
serviceSpecificExec in class NotInReadOnlyModeService
Returns:
Throws:
Exception


Copyright © 2003-2013. All Rights Reserved.