Project

General

Profile

Revision 3581c717

ID3581c717605d8c0074f59a2c0c938d5056a5973f
Parent 2b21cb88
Child 519ba447

Added by Andreas Müller 4 months ago

fix some compile errors in eflora

View differences:

cdm-eflora/src/main/java/eu/etaxonomy/cdm/app/eflora/CentralAfricaEricaceaeActivator.java
154 154
			if (app == null){
155 155
				app = CdmApplicationController.NewInstance(cdmDestination, hbm2dll, false);
156 156
			}
157
			app.getAgentService().updateTitleCache(Team.class, null, null, null);
157
			app.getAgentService().updateCaches(Team.class, null, null, null);
158 158
			return;
159 159
//			int count = app.getAgentService().deduplicate(Person.class, null, null);
160 160
//
cdm-eflora/src/main/java/eu/etaxonomy/cdm/io/eflora/EfloraTaxonImport.java
1324 1324
			}
1325 1325
		}
1326 1326
		if (homonymIsLater){
1327
			homonymName.addRelationshipToName(upperName, relType, null);
1327
			homonymName.addRelationshipToName(upperName, relType, null, null);
1328 1328
		}else{
1329
			upperName.addRelationshipToName(homonymName, relType, null);
1329
			upperName.addRelationshipToName(homonymName, relType, null, null);
1330 1330
		}
1331 1331
	}
1332 1332

  
......
1497 1497
			return detail;
1498 1498
		}
1499 1499

  
1500

  
1501 1500
		//non RE
1502 1501
		String reNon = "(\\s|,)non\\s";
1503 1502
		Pattern patReference = Pattern.compile(reNon);
......
1543 1542
				logger.warn("Classification name has no nomenclatural reference");
1544 1543
			}
1545 1544
			if (homonymIsLater){
1546
				homonymName.addRelationshipToName(name, relType, null);
1545
				homonymName.addRelationshipToName(name, relType, null, null);
1547 1546
			}else{
1548
				name.addRelationshipToName(homonymName, relType, null);
1547
				name.addRelationshipToName(homonymName, relType, null, null);
1549 1548
			}
1550 1549

  
1551 1550
		}else{
......
1665 1664
		return name;
1666 1665
	}
1667 1666

  
1668

  
1669
	/**
1670
	 * @param element
1671
	 * @param taxon
1672
	 */
1673 1667
	private void handleInfraspecificEpithet(Element element, String attrValue, INonViralName name) {
1674 1668
		String value = element.getTextNormalize();
1675 1669
		if (value.indexOf("subsp.") != -1){
......
1687 1681
		}
1688 1682
	}
1689 1683

  
1690

  
1691 1684
	/**
1692 1685
	 * @param state
1693 1686
	 * @param element
cdm-eflora/src/main/java/eu/etaxonomy/cdm/io/eflora/centralAfrica/checklist/CentralAfricaChecklistSynonymImport.java
29 29
import eu.etaxonomy.cdm.model.name.IBotanicalName;
30 30
import eu.etaxonomy.cdm.model.name.Rank;
31 31
import eu.etaxonomy.cdm.model.name.TaxonNameFactory;
32
import eu.etaxonomy.cdm.model.reference.ISourceable;
32 33
import eu.etaxonomy.cdm.model.reference.Reference;
33 34
import eu.etaxonomy.cdm.model.taxon.Synonym;
34 35
import eu.etaxonomy.cdm.model.taxon.SynonymType;
......
96 97
	@Override
97 98
	public Map<Object, Map<String, ? extends CdmBase>> getRelatedObjectsForPartition(ResultSet rs, CentralAfricaChecklistImportState state) {
98 99
		String nameSpace;
99
		Class<?> cdmClass;
100
		Class<? extends ISourceable> cdmClass;
100 101
		Set<String> idSet;
101 102
		Map<Object, Map<String, ? extends CdmBase>> result = new HashMap<Object, Map<String, ? extends CdmBase>>();
102 103

  
......
110 111
			nameSpace = TAXON_NAMESPACE;
111 112
			cdmClass = Taxon.class;
112 113
			idSet = taxonIdSet;
113
			Map<String, Taxon> taxonMap = (Map<String, Taxon>)getCommonService().getSourcedObjectsByIdInSource(cdmClass, idSet, nameSpace);
114
			Map<String, Taxon> taxonMap = (Map<String, Taxon>)getCommonService().getSourcedObjectsByIdInSourceC(cdmClass, idSet, nameSpace);
114 115
			result.put(nameSpace, taxonMap);
115 116

  
116 117
		} catch (SQLException e) {
cdm-eflora/src/main/java/eu/etaxonomy/cdm/io/eflora/centralAfrica/ferns/CentralAfricaFernsTaxonImport.java
102 102
	@Override
103 103
	protected DbImportMapping<?,?> getMapping() {
104 104
		if (mapping == null){
105
			mapping = new DbImportMapping();
105
			mapping = new DbImportMapping<>();
106 106

  
107 107
			mapping.addMapper(DbImportObjectCreationMapper.NewInstance(this, "Taxon number", TAXON_NAMESPACE)); //id + tu_status
108 108

  
cdm-eflora/src/main/java/eu/etaxonomy/cdm/io/eflora/centralAfrica/ferns/CentralAfricaFernsTaxonRelationImport.java
172 172
			//taxon map
173 173
			nameSpace = TAXON_NAMESPACE;
174 174
			cdmClass = TaxonBase.class;
175
			Map<String, TaxonBase> taxonMap = (Map<String, TaxonBase>)getCommonService().getSourcedObjectsByIdInSource(cdmClass, taxonIdSet, nameSpace);
175
			Map<String, TaxonBase> taxonMap = getCommonService().getSourcedObjectsByIdInSourceC((Class<TaxonBase>) cdmClass, taxonIdSet, nameSpace);
176 176
			result.put(nameSpace, taxonMap);
177 177

  
178 178

  

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)