*/
@Override
public void doImport(Site site, String importer, Map<String, Object> params) throws Exception {
@SuppressWarnings("unchecked")
Map<String,String> importers = (Map<String, String>) site.getConfig().get("importers");
Importer importerInstance = null;
if(importers != null){
String className = importers.get(importer);
if(className != null){
importerInstance = (Importer) ClassUtils.newInstance(className, site);
}
}
if(importerInstance == null){
throw new Exception("No valid importer: " + importer);
}
importerInstance.doImport(site, params);
}