1
|
/**
|
2
|
* Copyright (C) 2007 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
|
|
10
|
package eu.etaxonomy.cdm.test.function;
|
11
|
|
12
|
import org.apache.log4j.Logger;
|
13
|
|
14
|
import eu.etaxonomy.cdm.model.name.Rank;
|
15
|
import eu.etaxonomy.cdm.model.name.TaxonNameBase;
|
16
|
import eu.etaxonomy.cdm.model.name.TaxonNameFactory;
|
17
|
import eu.etaxonomy.cdm.strategy.parser.INonViralNameParser;
|
18
|
import eu.etaxonomy.cdm.strategy.parser.NonViralNameParserImpl;
|
19
|
|
20
|
/**
|
21
|
* @author a.mueller
|
22
|
* @created 21.11.2008
|
23
|
*/
|
24
|
public class TestFullReferenceParser {
|
25
|
private static final Logger logger = Logger.getLogger(TestFullReferenceParser.class);
|
26
|
|
27
|
|
28
|
private boolean test(){
|
29
|
INonViralNameParser parser = NonViralNameParserImpl.NewInstance();
|
30
|
TaxonNameBase nameToBeFilled = TaxonNameFactory.NewBotanicalInstance(null);
|
31
|
String fullReference = "Abies alba Mill., Sp. Pl. 4: 455. 1987.";
|
32
|
boolean makeEmpty = false;
|
33
|
Rank rank = null;
|
34
|
parser.parseReferencedName(nameToBeFilled, fullReference, rank, makeEmpty);
|
35
|
return true;
|
36
|
}
|
37
|
|
38
|
/**
|
39
|
* @param args
|
40
|
*/
|
41
|
public static void main(String[] args) {
|
42
|
TestFullReferenceParser test = new TestFullReferenceParser();
|
43
|
test.test();
|
44
|
|
45
|
}
|
46
|
}
|