Revision fe34a9eb
Added by Andreas Müller about 7 years ago
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/database/data/FullCoverageDataGenerator.java | ||
---|---|---|
389 | 389 |
textData.setTimeperiod(TimePeriodParser.parseString("1970-1980")); |
390 | 390 |
Reference ref = ReferenceFactory.newArticle(); |
391 | 391 |
DescriptionElementSource source = textData.addSource(OriginalSourceType.Import, "22", "taxon description table", ref, "detail"); |
392 |
source.setNameUsedInSource(TaxonNameBase.NewBotanicalInstance(Rank.GENUS()));
|
|
392 |
source.setNameUsedInSource(TaxonNameFactory.NewBotanicalInstance(Rank.GENUS()));
|
|
393 | 393 |
handleAnnotatableEntity(source); |
394 | 394 |
|
395 | 395 |
taxonDescription.addDescriptionSource(ref); |
... | ... | |
402 | 402 |
handleAnnotatableEntity(specDesc); |
403 | 403 |
|
404 | 404 |
//Name description |
405 |
TaxonNameBase<?,?> name = TaxonNameBase.NewBotanicalInstance(Rank.GENUS());
|
|
405 |
TaxonNameBase<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
|
|
406 | 406 |
TaxonNameDescription nameDesc = TaxonNameDescription.NewInstance(name); |
407 | 407 |
cdmBases.add(name); |
408 | 408 |
handleAnnotatableEntity(nameDesc); |
... | ... | |
627 | 627 |
|
628 | 628 |
private void createTaxon(List<CdmBase> cdmBases) { |
629 | 629 |
Reference sec = getReference(); |
630 |
TaxonNameBase<?,?> name = TaxonNameBase.NewBotanicalInstance(Rank.GENUS());
|
|
630 |
TaxonNameBase<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
|
|
631 | 631 |
Taxon taxon = Taxon.NewInstance(name, sec); |
632 | 632 |
handleIdentifiableEntity(taxon); |
633 | 633 |
|
634 |
TaxonNameBase<?,?> synName = TaxonNameBase.NewBotanicalInstance(Rank.GENUS());
|
|
634 |
TaxonNameBase<?,?> synName = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
|
|
635 | 635 |
Synonym syn = Synonym.NewInstance(synName, sec, "123"); |
636 | 636 |
taxon.addSynonym(syn, SynonymType.HETEROTYPIC_SYNONYM_OF()); |
637 | 637 |
taxon.setDoubtful(true); |
... | ... | |
765 | 765 |
mediaSpecimen.setAccessionNumber("accessionNumber"); |
766 | 766 |
// mediaSpecimen.setCollectorsNumber("collectorsNumber"); |
767 | 767 |
mediaSpecimen.setBarcode("barcode"); |
768 |
BotanicalName storedUnder = TaxonNameBase.NewBotanicalInstance(Rank.SPECIES());
|
|
768 |
BotanicalName storedUnder = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
|
|
769 | 769 |
storedUnder.setTitleCache("Stored under", true); |
770 | 770 |
mediaSpecimen.setStoredUnder(storedUnder); |
771 | 771 |
mediaSpecimen.setExsiccatum("exsiccatum"); |
... | ... | |
834 | 834 |
botName.setExBasionymAuthorship(exBasionymAuthorship); |
835 | 835 |
handleIdentifiableEntity(botName); |
836 | 836 |
handleAnnotatableEntity(botName.getHomotypicalGroup()); |
837 |
BotanicalName botName2 = TaxonNameBase.NewBotanicalInstance(Rank.SPECIES());
|
|
837 |
BotanicalName botName2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
|
|
838 | 838 |
HybridRelationship hybridRel = botName2.addHybridChild(botName, HybridRelationshipType.FIRST_PARENT(), "Rule 1.2.3"); |
839 | 839 |
hybridRel.setCitation(ReferenceFactory.newBook()); |
840 | 840 |
hybridRel.setCitationMicroReference("p. 123"); |
... | ... | |
951 | 951 |
|
952 | 952 |
private Taxon getTaxon() { |
953 | 953 |
Reference sec = getReference(); |
954 |
TaxonNameBase<?,?> name = TaxonNameBase.NewBotanicalInstance(Rank.GENUS());
|
|
954 |
TaxonNameBase<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
|
|
955 | 955 |
Taxon taxon = Taxon.NewInstance(name, sec); |
956 | 956 |
return taxon; |
957 | 957 |
|
Also available in: Unified diff
ref #6365 use TaxonNameFactory for botanical names