1
|
/**
|
2
|
* Copyright (C) 2017 EDIT
|
3
|
* European Distributed Institute of Taxonomy
|
4
|
* http://www.e-taxonomy.eu
|
5
|
*
|
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.
|
8
|
*/
|
9
|
package eu.etaxonomy.cdm.io.euromed;
|
10
|
|
11
|
import eu.etaxonomy.cdm.common.URI;
|
12
|
|
13
|
import eu.etaxonomy.cdm.database.ICdmDataSource;
|
14
|
import eu.etaxonomy.cdm.io.common.ImportStateBase;
|
15
|
import eu.etaxonomy.cdm.io.excel.common.ExcelImportConfiguratorBase;
|
16
|
import eu.etaxonomy.cdm.io.mexico.SimpleExcelTaxonImportState;
|
17
|
import eu.etaxonomy.cdm.model.name.NomenclaturalCode;
|
18
|
|
19
|
/**
|
20
|
* @author a.mueller
|
21
|
* @since 23.10.2019
|
22
|
*/
|
23
|
public class IpniImportConfigurator extends ExcelImportConfiguratorBase {
|
24
|
|
25
|
private static final long serialVersionUID = -648787716062337242L;
|
26
|
|
27
|
private boolean addAuthorsToReference = true;
|
28
|
|
29
|
public static IpniImportConfigurator NewInstance(URI uri, ICdmDataSource cdmDestination) {
|
30
|
return new IpniImportConfigurator(uri, cdmDestination);
|
31
|
}
|
32
|
|
33
|
private IpniImportConfigurator(URI uri, ICdmDataSource cdmDestination) {
|
34
|
super(uri, cdmDestination, null);
|
35
|
this.setNomenclaturalCode(NomenclaturalCode.ICNAFP);
|
36
|
}
|
37
|
|
38
|
@SuppressWarnings("unchecked")
|
39
|
@Override
|
40
|
protected void makeIoClassList() {
|
41
|
ioClassList = new Class[]{
|
42
|
IpniImport.class
|
43
|
};
|
44
|
}
|
45
|
|
46
|
@Override
|
47
|
public ImportStateBase getNewState() {
|
48
|
return new SimpleExcelTaxonImportState<>(this);
|
49
|
}
|
50
|
//
|
51
|
// /**
|
52
|
// * If <code>true</code> the name authors will be added
|
53
|
// * to the nomenclatural reference (Book or Article) though
|
54
|
// * it might not be the exact same author.<BR>
|
55
|
// * Default is <code>true</code>
|
56
|
// */
|
57
|
// public boolean isAddAuthorsToReference() {
|
58
|
// return addAuthorsToReference;
|
59
|
// }
|
60
|
// /**
|
61
|
// * @see #isAddAuthorsToReference()
|
62
|
// */
|
63
|
// public void setAddAuthorsToReference(boolean addAuthorsToReference) {
|
64
|
// this.addAuthorsToReference = addAuthorsToReference;
|
65
|
// }
|
66
|
|
67
|
|
68
|
}
|