ref #6630 and ref #6368 remove generics from TaxonName
authorAndreas Müller <a.mueller@bgbm.org>
Mon, 22 May 2017 21:50:56 +0000 (23:50 +0200)
committerAndreas Müller <a.mueller@bgbm.org>
Sat, 3 Jun 2017 17:18:56 +0000 (19:18 +0200)
68 files changed:
cdmlib-ext/src/main/java/eu/etaxonomy/cdm/ext/ipni/IpniService.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/common/CdmImportBase.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/common/mapping/out/DbDescriptionElementTaxonMapper.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/common/mapping/out/DbOriginalNameMapper.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/common/utils/ImportDeduplicationHelper.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/dwca/in/DwcTaxonStreamItem2CdmTaxonConverter.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/dwca/out/DwcaTypesExport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/excel/distribution/DistributionImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/excel/taxa/NormalExplicitImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/markup/MarkupNomenclatureImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/outputmodel/OutputModelClassificationExport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/specimen/SpecimenImportBase.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/specimen/excel/in/SpecimenCdmExcelImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/specimen/excel/in/SpecimenSythesysExcelImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/taxonx/SimpleSpecimen.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/taxonx/TaxonXNomenclatureImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/tcsxml/in/TcsXmlTaxonImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/tcsxml/in/TcsXmlTaxonNameRelationsImport.java
cdmlib-io/src/main/java/eu/etaxonomy/cdm/io/tcsxml/in/TcsXmlTaxonRelationsImport.java
cdmlib-io/src/test/java/eu/etaxonomy/cdm/io/dwca/in/DatabaseMappingTest.java
cdmlib-io/src/test/java/eu/etaxonomy/cdm/io/specimen/abcd206/in/SpecimenImportConfiguratorTest.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/common/IntextReference.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/description/DescriptionElementSource.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/description/TaxonNameDescription.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/HomotypicalGroup.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/HomotypicalGroupComparator.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/HomotypicalGroupNameComparator.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/HybridRelationship.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/ITaxonNameBase.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/TaxonName.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/name/TaxonNameFactory.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/occurrence/DeterminationEvent.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/taxon/HomotypicGroupTaxonComparator.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/taxon/TaxonBase.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/strategy/cache/taxon/TaxonBaseDefaultCacheStrategy.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/strategy/homotypicgroup/BasionymRelationCreator.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/validation/constraint/BasionymsMustShareEpithetsAndAuthorsValidator.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/validation/constraint/ChildTaxaMustDeriveNameFromParentValidator.java
cdmlib-model/src/main/java/eu/etaxonomy/cdm/validation/constraint/NameMustFollowCodeValidator.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/aspectj/PropertyChangeTest.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/model/name/TaxonNameTest.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/model/taxon/ClassificationTest.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/model/taxon/TaxonBaseTest.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/strategy/cache/name/NonViralNameDefaultCacheStrategyTest.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/strategy/homotypicgroup/BasionymRelationCreatorTest.java
cdmlib-model/src/test/java/eu/etaxonomy/cdm/validation/NameMustFollowCodeTest.java
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/persistence/dao/hibernate/common/DeduplicationHelper.java
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/persistence/dao/hibernate/name/TaxonNameDaoHibernateImpl.java
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/persistence/dao/hibernate/taxon/TaxonDaoHibernateImpl.java
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/persistence/dao/initializer/TitleAndNameCacheAutoInitializer.java
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/persistence/dao/name/ITaxonNameDao.java
cdmlib-persistence/src/test/java/eu/etaxonomy/cdm/persistence/dao/BeanInitializerIntegration.java
cdmlib-persistence/src/test/java/eu/etaxonomy/cdm/persistence/dao/hibernate/common/CdmGenericDaoImplTest.java
cdmlib-persistence/src/test/java/eu/etaxonomy/cdm/persistence/hibernate/CacheStrategyGeneratorTest.java
cdmlib-persistence/src/test/java/eu/etaxonomy/cdm/persistence/hibernate/CdmDeleteListenerTest.java
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/ClassificationServiceImpl.java
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/IdentifiableServiceBase.java
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/NameServiceImpl.java
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/OccurrenceServiceImpl.java
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/TaxonServiceImpl.java
cdmlib-services/src/main/java/eu/etaxonomy/cdm/validation/constraint/NoDuplicateNamesValidator.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/api/facade/DerivedUnitFacadeCacheStrategyInjectionTest.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/api/facade/DerivedUnitFacadeCacheStrategyTest.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/api/service/AgentServiceImplTest.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/api/service/ClassificationServiceDeepTest.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/api/service/NameServiceImplTest.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/api/service/OccurrenceServiceTest.java
cdmlib-services/src/test/java/eu/etaxonomy/cdm/test/function/Datasource.java

index 711a9146ea1b2c9aa1ecfde4de49ccf4ff8220f0..0813391a0d31dfaeda35f3ec2469d22419583ebf 100644 (file)
@@ -449,9 +449,9 @@ public class IpniService  implements IIpniService{
        }
 
 
-       private List<TaxonName<?,?>> buildNameList( InputStream content, ICdmRepository repository, IIpniServiceConfigurator iConfig) throws IOException {
+       private List<TaxonName> buildNameList( InputStream content, ICdmRepository repository, IIpniServiceConfigurator iConfig) throws IOException {
                IpniServiceNamesConfigurator config = (IpniServiceNamesConfigurator)iConfig;
-               List<TaxonName<?,?>> result = new ArrayList<>();
+               List<TaxonName> result = new ArrayList<>();
                BufferedReader reader = new BufferedReader (new InputStreamReader(content));
 
                String headerLine = reader.readLine();
index 3f718b411d0b8a03c243778f5c8db2023e8d0967..a242bd36864adfbb811f6c8170290d1cc205c9a7 100644 (file)
@@ -1038,7 +1038,7 @@ public abstract class CdmImportBase<CONFIG extends IImportConfigurator, STATE ex
         *
         * @see #getTaxonDescription(Taxon, boolean, boolean)
         */
-       public TaxonNameDescription getTaxonNameDescription(TaxonName<?,?> name, Reference ref, boolean isImageGallery, boolean createNewIfNotExists) {
+       public TaxonNameDescription getTaxonNameDescription(TaxonName name, Reference ref, boolean isImageGallery, boolean createNewIfNotExists) {
                TaxonNameDescription result = null;
                Set<TaxonNameDescription> descriptions= name.getDescriptions();
                for (TaxonNameDescription description : descriptions){
index 58f8963867b37a0f0b467b45bf95c5ac97a3ae99..cec56a5e5f09f302df8fc9c4ab71b523c7f0dc93 100644 (file)
@@ -76,7 +76,7 @@ public class DbDescriptionElementTaxonMapper extends DbSingleAttributeExportMapp
                                        }
                                }else if (inDescription.isInstanceOf(TaxonNameDescription.class)){
                                        TaxonNameDescription nameDescription = CdmBase.deproxy(inDescription, TaxonNameDescription.class);
-                                       TaxonName<?,?> taxonName = nameDescription.getTaxonName();
+                                       TaxonName taxonName = nameDescription.getTaxonName();
                                        if (isCache){
                                                return taxonName.getTitleCache();
                                        }else{
index 2d63f5ffeb40095fe17a1979c010596f5b263ef8..3120807399b08db608c2df4e9d0b2a92a7fed6f3 100644 (file)
@@ -52,7 +52,7 @@ public class DbOriginalNameMapper extends DbSingleAttributeExportMapperBase<DbEx
                if (cdmBase.isInstanceOf(OriginalSourceBase.class)){
                        OriginalSourceBase<?> source = CdmBase.deproxy(cdmBase, OriginalSourceBase.class);
                        String nameString = source.getOriginalNameString();
-                       TaxonName<?,?> name = null;
+                       TaxonName name = null;
                        if (source.isInstanceOf(DescriptionElementSource.class)){
                                DescriptionElementSource descSource = CdmBase.deproxy(source, DescriptionElementSource.class);
                                name = descSource.getNameUsedInSource();
index 840c17386ff26afc0f65de73867ff8c3316f7ff3..810a1db40db9b590297a67eac4e2094260c79e84 100644 (file)
@@ -364,8 +364,8 @@ public class ImportDeduplicationHelper<STATE extends ImportStateBase<?,?>> {
    private void initNameMap(STATE state) {
        if (!nameMapIsInitialized && repository != null){
            List<String> propertyPaths = Arrays.asList("");
-           List<TaxonName<?,?>> existingNames = repository.getNameService().list(null, null, null, null, propertyPaths);
-           for (TaxonName<?,?> name : existingNames){
+           List<TaxonName> existingNames = repository.getNameService().list(null, null, null, null, propertyPaths);
+           for (TaxonName name : existingNames){
                putName(name.getTitleCache(), name);
            }
           nameMapIsInitialized = true;
index 22fa6622ec42e3e9b11c31e81ead12aaa160439a..08b44920060470830be9e37b90094440ce3876b9 100644 (file)
@@ -133,7 +133,7 @@ public class  DwcTaxonStreamItem2CdmTaxonConverter<CONFIG extends DwcaDataImport
                Rank rank = getRank(csvTaxonRecord, nomCode);
 
                //name && name published in
-               TaxonName<?,?> name = getScientificName(csvTaxonRecord, nomCode, rank, resultList, sourceReference);
+               TaxonName name = getScientificName(csvTaxonRecord, nomCode, rank, resultList, sourceReference);
                taxonBase.setName(name);
 
                //nameAccordingTo
@@ -500,12 +500,12 @@ public class  DwcTaxonStreamItem2CdmTaxonConverter<CONFIG extends DwcaDataImport
        }
 
 
-       private TaxonName<?,?> getScientificName(StreamItem item, NomenclaturalCode nomCode, Rank rank, List<MappedCdmBase> resultList, Reference sourceReference) {
-               TaxonName<?,?> name = null;
+       private TaxonName getScientificName(StreamItem item, NomenclaturalCode nomCode, Rank rank, List<MappedCdmBase> resultList, Reference sourceReference) {
+               TaxonName name = null;
                String strScientificName = getValue(item, TermUri.DWC_SCIENTIFIC_NAME);
                //Name
                if (strScientificName != null){
-                       name = (TaxonName<?,?>)parser.parseFullName(strScientificName, nomCode, rank);
+                       name = (TaxonName)parser.parseFullName(strScientificName, nomCode, rank);
                        if ( rank != null && name != null && name.getRank() != null &&  ! rank.equals(name.getRank())){
                                if (config.isValidateRankConsistency()){
                                        String message = "Parsed rank %s (%s) differs from rank %s given by fields 'taxonRank' or 'verbatimTaxonRank'";
@@ -607,7 +607,7 @@ public class  DwcTaxonStreamItem2CdmTaxonConverter<CONFIG extends DwcaDataImport
 
 
        //TODO we may configure in configuration that scientific name never includes Authorship
-       private void checkAuthorship(TaxonName<?,?> nameBase, StreamItem item) {
+       private void checkAuthorship(TaxonName nameBase, StreamItem item) {
                if (!nameBase.isNonViral()){
                        return;
                }
@@ -677,7 +677,7 @@ public class  DwcTaxonStreamItem2CdmTaxonConverter<CONFIG extends DwcaDataImport
         * @return
         */
        private TaxonBase<?> getTaxonBase(StreamItem item) {
-               TaxonName<?,?> name = null;
+               TaxonName name = null;
                Reference sec = null;
                TaxonBase<?> result;
                String taxStatus = item.get(TermUri.DWC_TAXONOMIC_STATUS);
index 4a566154b82982a0a269b396b584767cd1597853..aed5b7ef48ecb956c17464f9bb933ee3c25c7b66 100644 (file)
@@ -241,7 +241,7 @@ public class DwcaTypesExport extends DwcaExportBase {
                return true;\r
        }\r
 \r
-       private TaxonName<?,?> getScientificName(DerivedUnitFacade facade) {\r
+       private TaxonName getScientificName(DerivedUnitFacade facade) {\r
                Set<DeterminationEvent> detEvents = facade.getDeterminations();\r
                for (DeterminationEvent detEvent : detEvents){\r
                        if (detEvent.getPreferredFlag()== true || detEvents.size()==1){\r
index e60feb60d2da92bb8c48c668e893837998cb82fc..0c260622140a050c6437c29999a015830f2fd913 100644 (file)
@@ -186,7 +186,7 @@ public class DistributionImport
                }\r
 \r
                // get the taxa for the matching names\r
-               for(TaxonName<?,?> dbTaxonName: taxonNames) {\r
+               for(TaxonName dbTaxonName: taxonNames) {\r
 \r
                        Set<Taxon> taxa = dbTaxonName.getTaxa();\r
                        if (taxa.isEmpty()) {\r
index fba5af8948c496f9701ce7d7a6dc044e52101b78..e02ced73286fa881daf1bb6bf5168b44e69a13fc 100644 (file)
@@ -838,7 +838,7 @@ public class NormalExplicitImport extends TaxonExcelImporterBase {
        //TODO implementation must be improved when matching of taxon names with existing names is implemented
        //=> the assumption that the only description is the description added by this import
        //is wrong then
-       private TaxonNameDescription getNameDescription(TaxonName<?,?> name) {
+       private TaxonNameDescription getNameDescription(TaxonName name) {
                Set<TaxonNameDescription> descriptions = name.getDescriptions();
                if (descriptions.size()>1){
                        throw new IllegalStateException("Implementation does not yet support names with multiple descriptions");
index 0b25a6c35fd0b81043ccefbfd80097b0d55b13e3..f8ed9153013cadba465345a5a704ccc186e3c856 100644 (file)
@@ -164,7 +164,7 @@ public class MarkupNomenclatureImport extends MarkupImportBase {
                                        // this a rule?
                                        TaxonName speciesName = TaxonName.castAndDeproxy(
                                                handleNom(state, reader, next, null));
-                                       for (TaxonName<?, ?> name : homotypicalGroup
+                                       for (TaxonName name : homotypicalGroup
                                                        .getTypifiedNames()) {
                                                name.addNameTypeDesignation(speciesName, null, null,
                                                                null, status, false, false, false, false);
index 93dea5457ebc7a0e831067118694c5f66bc0e85d..670b75b8748b498e7c78b1e27af7d40a21cee09d 100755 (executable)
@@ -1074,8 +1074,8 @@ HomotypicGroupSequenceNumber
      *   TypeDesignatedByRef_Fk
      */
 
-    private void handleTypeDesignations(OutputModelExportState state, TaxonName name){
-       Set<SpecimenTypeDesignation> typeDesignations = name.getTypeDesignations();
+    private void handleSpecimenTypeDesignations(OutputModelExportState state, TaxonName name){
+       Set<SpecimenTypeDesignation> typeDesignations = name.getSpecimenTypeDesignations();
        OutputModelTable table = OutputModelTable.TYPE_DESIGNATION;
        String nameId = getId(state, name);
        String[] csvLine = new String[table.getSize()];
index 6b09890c82846fb6b2e157c6513e3cab8b022839..9d980c2d65adb1e9b8b0d08fbb06af0917370d74 100755 (executable)
@@ -150,7 +150,7 @@ public abstract class SpecimenImportBase<CONFIG extends IImportConfigurator, STA
         }
 
         if(taxonName==null && atomisedTaxonName!=null){
-            taxonName = (TaxonName<?, ?>) atomisedTaxonName;
+            taxonName = (TaxonName) atomisedTaxonName;
             state.getReport().addName(taxonName);
             logger.info("Created new taxon name "+taxonName);
             if(taxonName.hasProblem()){
index 5baf2bb809a50e044ef6710683bb3f3f103d2b5d..5240479e3e8a2b6b0dbae41272240787a1646ab1 100644 (file)
@@ -845,7 +845,7 @@ public class SpecimenCdmExcelImport  extends ExcelTaxonOrSpecimenImportBase<Spec
                if (result == null){
                        NonViralNameParserImpl parser = NonViralNameParserImpl.NewInstance();
                        NomenclaturalCode code = state.getConfig().getNomenclaturalCode();
-                       result = (TaxonName<?,?>)parser.parseFullName(name, code, null);
+                       result = (TaxonName)parser.parseFullName(name, code, null);
 
                }
                if (result != null){
index 54b5faeafc23ff5945be9c03b59517da0cd4daf3..cd6e076580bb4b4307f8d6eafd1b642e03b17697 100644 (file)
@@ -455,7 +455,7 @@ public class SpecimenSythesysExcelImport  extends CdmImportBase<SpecimenSynthesy
                     taxonName = TaxonNameFactory.NewNonViralInstance(null);
                     taxonName.setTitleCache(scientificName, true);
                 }
-                getNameService().save((TaxonName<?,?>)taxonName);
+                getNameService().save((TaxonName)taxonName);
                 taxon = Taxon.NewInstance(taxonName, ref); //sec set null
                 getTaxonService().save(taxon);
                 //   refreshTransaction();
index 4ce63d25548553fa8080f19db0e3f6de2fa6d2cd..415a011b6e426b5bd27519c850643c4088c9b07a 100644 (file)
@@ -35,7 +35,7 @@ public class SimpleSpecimen {
        private DerivationEvent derivationEvent;\r
        private DerivedUnit specimen;\r
        private Collection collection;\r
-       private TaxonName<?, ?> storedUnderName;\r
+       private TaxonName storedUnderName;\r
        private String titleCache;\r
 \r
 \r
@@ -95,14 +95,14 @@ public class SimpleSpecimen {
                /**\r
         * @return the storedUnderName\r
         */\r
-       public TaxonName<?, ?> getStoredUnderName() {\r
+       public TaxonName getStoredUnderName() {\r
                return storedUnderName;\r
        }\r
 \r
        /**\r
         * @param storedUnderName the storedUnderName to set\r
         */\r
-       public void setStoredUnderName(TaxonName<?, ?> storedUnderName) {\r
+       public void setStoredUnderName(TaxonName storedUnderName) {\r
                this.storedUnderName = storedUnderName;\r
        }\r
 \r
index a168c9e4dbcfa21166b5b15857b3797a900bbe90..1b282242a33234a5e65cfb3b96303b9d79b5b3a3 100644 (file)
@@ -512,7 +512,7 @@ public class TaxonXNomenclatureImport
                                String[] collectionStrings = typeLocStatus.substring(pos).split(",");\r
                                for(String collectionString : collectionStrings){\r
                                        if (taxonBase != null){\r
-                                               TaxonName<?,?> taxonName = taxonBase.getName();\r
+                                               TaxonName taxonName = taxonBase.getName();\r
                                                if (taxonName != null){\r
                                                        Reference citation = null;\r
                                                        String citationMicroReference = null;\r
index 1807190ebc044e820f4eb44892022dd6b10cce57..6be1640d063b2e054dd87fd3a82326b8b9afd275 100644 (file)
@@ -122,7 +122,7 @@ public class TcsXmlTaxonImport  extends TcsXmlImportBase implements ICdmIO<TcsXm
 \r
                logger.info("start make TaxonConcepts ...");\r
                MapWrapper<TaxonBase> taxonMap = (MapWrapper<TaxonBase>)state.getStore(ICdmIO.TAXON_STORE);\r
-               MapWrapper<TaxonName<?,?>> taxonNameMap = (MapWrapper<TaxonName<?,?>>)state.getStore(ICdmIO.TAXONNAME_STORE);\r
+               MapWrapper<TaxonName> taxonNameMap = (MapWrapper<TaxonName>)state.getStore(ICdmIO.TAXONNAME_STORE);\r
                MapWrapper<Reference> referenceMap = (MapWrapper<Reference>)state.getStore(ICdmIO.REFERENCE_STORE);\r
                Map<String, CommonTaxonName> commonNameMap = new HashMap<String, CommonTaxonName>();\r
 \r
@@ -311,8 +311,8 @@ public class TcsXmlTaxonImport  extends TcsXmlImportBase implements ICdmIO<TcsXm
         * @param elTaxonRelationships\r
         * @param success\r
         */\r
-       private TaxonName<?, ?> makeScientificName(Element elName, NomenclaturalCode code, MapWrapper<? extends TaxonName<?,?>> objectMap, ResultWrapper<Boolean> success){\r
-               TaxonName<?,?> result = null;\r
+       private TaxonName makeScientificName(Element elName, NomenclaturalCode code, MapWrapper<? extends TaxonName> objectMap, ResultWrapper<Boolean> success){\r
+               TaxonName result = null;\r
                if (elName != null){\r
                        String language = elName.getAttributeValue("language");\r
                        //Language\r
@@ -320,7 +320,7 @@ public class TcsXmlTaxonImport  extends TcsXmlImportBase implements ICdmIO<TcsXm
                                logger.warn("language for name not yet implemented. Language for scientific name should always be Latin");\r
                        }\r
                        Class<? extends IdentifiableEntity> clazz = TaxonName.class;\r
-                       result = (TaxonName<?,?>)makeReferenceType (elName, clazz , objectMap, success);\r
+                       result = (TaxonName)makeReferenceType (elName, clazz , objectMap, success);\r
                        if(result == null){\r
                                logger.warn("Name not found");\r
                                success.setValue(false);\r
index d9665dfb08d852689691d89fffbb419a832fca6a..e2417abf0c3f4964c1634ac1420592b3ab053eb5 100644 (file)
@@ -59,7 +59,7 @@ public class TcsXmlTaxonNameRelationsImport extends TcsXmlImportBase implements
 \r
 \r
                logger.info("start make taxon name relations ...");\r
-               MapWrapper<TaxonName<?,?>> taxonNameMap = (MapWrapper<TaxonName<?,?>>)state.getStore(ICdmIO.TAXONNAME_STORE);\r
+               MapWrapper<TaxonName> taxonNameMap = (MapWrapper<TaxonName>)state.getStore(ICdmIO.TAXONNAME_STORE);\r
                MapWrapper<Reference> referenceMap = (MapWrapper<Reference>)state.getStore(ICdmIO.REFERENCE_STORE);\r
 \r
                Set<TaxonName> nameStore = new HashSet<TaxonName>();\r
@@ -309,7 +309,7 @@ public class TcsXmlTaxonNameRelationsImport extends TcsXmlImportBase implements
        }\r
 \r
 \r
-       private  boolean makeNomenclaturalNoteType(TcsXmlImportConfigurator tcsConfig, Element elRelation, NameRelationshipType relType, MapWrapper<TaxonName<?,?>> taxonNameMap, Set<TaxonName> nameStore, String id, boolean inverse){\r
+       private  boolean makeNomenclaturalNoteType(TcsXmlImportConfigurator tcsConfig, Element elRelation, NameRelationshipType relType, MapWrapper<TaxonName> taxonNameMap, Set<TaxonName> nameStore, String id, boolean inverse){\r
                if (elRelation == null){\r
                        return false;\r
                }\r
index 0b52cf73b73eddf81901221e23cb46e64d91768b..0ce3855fcb619aaae1aef4924ee5bec679c3ad85 100644 (file)
@@ -574,7 +574,7 @@ public class TcsXmlTaxonRelationsImport extends TcsXmlImportBase implements ICdm
                TaxonName aboutName = aboutTaxon.getName();\r
                if (aboutName != null){\r
                        Set<TaxonName> typifiedNames = aboutName.getHomotypicalGroup().getTypifiedNames();\r
-                       for (TaxonName<?,?> typifiedName : typifiedNames){\r
+                       for (TaxonName typifiedName : typifiedNames){\r
                                //TODO check if name is part of this tcs file\r
                                if (typifiedName.equals(aboutName)){\r
                                        continue;\r
index c22c78c2599c2bb922d1d447b5dedb3801dcf3e5..3df7be64e60b113fa61c1ed59455b0bac87d60d3 100644 (file)
@@ -77,7 +77,7 @@ public class DatabaseMappingTest {
                ICdmDataSource datasource = mapping.getDatabase();
                Assert.assertNotNull("Datasource should not be null", datasource);
 
-               TaxonName<?,?> botName1 = TaxonNameFactory.NewBotanicalInstance(null);
+               TaxonName botName1 = TaxonNameFactory.NewBotanicalInstance(null);
                int id = 23;
                botName1.setId(id);
                String sourceNS = "sourceNS";
index 483d091387f00b271c6924d08b3ffd223f37b045..6ae07b2421505b0dd0cb9ce3aecd7a5dc763142a 100644 (file)
@@ -250,7 +250,7 @@ public class SpecimenImportConfiguratorTest extends CdmTransactionalIntegrationT
            assertEquals(3, nameService.count(TaxonName.class));
            assertEquals(1, occurrenceService.count(DerivedUnit.class));
            boolean varietyFound = false;
-           for(TaxonName<?, ?> name:nameService.list(TaxonName.class, null, null, null, null)){
+           for(TaxonName name:nameService.list(TaxonName.class, null, null, null, null)){
                if(name.getRank().equals(Rank.VARIETY())){
                    varietyFound = true;
                }
index a2c6e4a3c63071cb35abb15980fd13478995a984..5d26f3a0a3c9c551152ef1c09978e4e9dc9c872a 100644 (file)
@@ -276,7 +276,7 @@ public class IntextReference extends VersionableEntity {
     private void setTarget(IIntextReferenceTarget target) {\r
         target = CdmBase.deproxy(target);\r
         if (target instanceof TaxonName){\r
-            this.taxonName = (TaxonName<?,?>)target;\r
+            this.taxonName = (TaxonName)target;\r
         }else if (target instanceof TaxonBase){\r
             this.taxon = (TaxonBase<?>)target;\r
         }else if (target instanceof SpecimenOrObservationBase){\r
index 1a9dbbafb78fc15eeefa9ae61b43ce9dc50b4021..a4ab3bb2298c088829661f4927252d4640106386 100644 (file)
@@ -122,7 +122,7 @@ public class DescriptionElementSource extends OriginalSourceBase<DescriptionElem
        @XmlSchemaType(name = "IDREF")
        @ManyToOne(fetch = FetchType.LAZY)
        @Cascade({CascadeType.SAVE_UPDATE,CascadeType.MERGE})
-       private TaxonName<?,?> nameUsedInSource;
+       private TaxonName nameUsedInSource;
 
 //*********************** CONSTRUCTOR ******************************/
 
index 06877b14d1d0ffc8d3dd47ae6de0697f5e560e8f..43d6e9279667918a5ae6d072bbbb1e64899e734e 100644 (file)
@@ -62,7 +62,7 @@ public class TaxonNameDescription extends DescriptionBase<IIdentifiableEntityCac
     @ManyToOne(fetch = FetchType.LAZY)
     @Cascade({CascadeType.SAVE_UPDATE,CascadeType.MERGE})
     @FieldBridge(impl=NotNullAwareIdBridge.class)
-    private TaxonName<?,?> taxonName;
+    private TaxonName taxonName;
 
 //******************* FACTORY ********************************************/
 
@@ -103,7 +103,7 @@ public class TaxonNameDescription extends DescriptionBase<IIdentifiableEntityCac
      * Returns the {@link TaxonName taxon name} to which <i>this</i> taxon name description
      * provides additional information not ruled by a {@link NomenclaturalCode nomenclatural code}.
      */
-    public TaxonName<?,?> getTaxonName() {
+    public TaxonName getTaxonName() {
         return taxonName;
     }
 
index 042a986c32d61a1a6722bae3e570c364eb96b4d8..9196342f2d2bf7d52501a430a53d33f8070084fd 100644 (file)
@@ -309,13 +309,13 @@ public class HomotypicalGroup extends AnnotatableEntity {
 //     */
 //    public void guessAndSetBasionym(){
 //         Map<String, INonViralName> candidates = new HashMap<>();
-//         for (TaxonName<?,?> typifiedName : this.typifiedNames){
+//         for (TaxonName typifiedName : this.typifiedNames){
 //             if (! typifiedName.protectedAuthorshipCache && nvn.getBasionymAuthorship() == null){
 //                 candidates.add(typifiedName);
 //             }
 //         }
 //         if (candidates.size() == 1){
-//             for (TaxonName<?,?> typifiedName : this.typifiedNames){
+//             for (TaxonName typifiedName : this.typifiedNames){
 //                 removeGroupBasionym(typifiedName);
 //             }
 //             this.setGroupBasionym(candidates.iterator().next());
index 5ffdde6f969d96d40f330834cb4b1e22cd7a0c0f..157ace3f0f7577573b8c483370696b024633cc77 100644 (file)
@@ -33,7 +33,7 @@ public class HomotypicalGroupComparator implements
                TaxonComparator taxComparator = new HomotypicGroupTaxonComparator(null);
                Set<TaxonName> typifiedNames1 = group1.getTypifiedNames();
                List<TaxonBase> taxonBasesOfTypifiedNames = new ArrayList<>();
-               for (TaxonName<?,?> typifiedName:typifiedNames1){
+               for (TaxonName typifiedName:typifiedNames1){
                        if (!typifiedName.getTaxonBases().isEmpty()){
                                taxonBasesOfTypifiedNames.add(typifiedName.getTaxonBases().iterator().next());
                        }
@@ -43,7 +43,7 @@ public class HomotypicalGroupComparator implements
 
                Set<TaxonName> typifiedNames2 = group2.getTypifiedNames();
                taxonBasesOfTypifiedNames = new ArrayList<TaxonBase>();
-               for (TaxonName<?,?> typifiedName:typifiedNames2){
+               for (TaxonName typifiedName:typifiedNames2){
                        if (!typifiedName.getTaxonBases().isEmpty()){
                                taxonBasesOfTypifiedNames.add(typifiedName.getTaxonBases().iterator().next());
                        }
index efe54b761815b66224bb284d4a6a4bbc0eb189a6..e6619f5805b55075f9f1f7171ce7c4beb12b7a77 100755 (executable)
@@ -130,9 +130,9 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
          * @param name2 second name to compare
          * @return compare value according to the {@link Comparator#compare(Object, Object)} contract.
          */
-        private int handleSameBasionym(TaxonName<?, ?> basionym,
-                TaxonName<?, ?> name1,
-                TaxonName<?, ?> name2) {
+        private int handleSameBasionym(TaxonName basionym,
+                TaxonName name1,
+                TaxonName name2) {
 
             if (basionym.equals(name1)){
                 return -1;
@@ -149,7 +149,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
          * @param basionym2
          * @return
          */
-        private int compareBasionyms(TaxonName<?,?> basionym1Orig, TaxonName basionym2Orig) {
+        private int compareBasionyms(TaxonName basionym1Orig, TaxonName basionym2Orig) {
             //one taxon is first in group
             TaxonName basionym1 = getFirstNameInGroup(basionym1Orig);
             TaxonName basionym2 = getFirstNameInGroup(basionym2Orig);
@@ -180,7 +180,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
          * @param basionym
          * @return
          */
-        private TaxonName<?, ?> getFirstNameInGroup(TaxonName<?, ?> basionym) {
+        private TaxonName getFirstNameInGroup(TaxonName basionym) {
             for (NameRelationship nameRel : basionym.getRelationsFromThisName()){
                 if (nameRel.getType() != null && nameRel.getType().equals(NameRelationshipType.BASIONYM())){
                     if (nameRel.getToName().equals(firstNameInGroup)){
@@ -196,13 +196,13 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
          * @return
          */
         @SuppressWarnings("rawtypes")
-        private Set<TaxonName> getReplacedSynonymClosure(TaxonName<?, ?> name) {
+        private Set<TaxonName> getReplacedSynonymClosure(TaxonName name) {
             Set<TaxonName> set = name.getReplacedSynonyms();
             if (set.isEmpty()){
                 return set;
             }
             Set<TaxonName> result = new HashSet<TaxonName>();
-            for (TaxonName<?,?> replSyn : set){
+            for (TaxonName replSyn : set){
                 boolean notYetContained = result.add(replSyn);
                 if (notYetContained){
                     result.addAll(replSyn.getReplacedSynonyms());
@@ -215,10 +215,10 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
          * @param name
          * @return
          */
-        private TaxonName getPreferredInBasionymGroup(TaxonName<?,?> name) {
+        private TaxonName getPreferredInBasionymGroup(TaxonName name) {
             Set<TaxonName> candidates = new HashSet<>();
             //get all final basionyms, except for those being part of a basionym circle
-            for (TaxonName<?,?> candidate : name.getBasionyms()){
+            for (TaxonName candidate : name.getBasionyms()){
                 if (candidate != null
                         && candidate.getHomotypicalGroup().equals(name.getHomotypicalGroup())
                         && !hasBasionymCircle(candidate, null)){
@@ -234,7 +234,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
             }else{
                 TaxonName result = candidates.iterator().next();
                 candidates.remove(result);
-                for(TaxonName<?,?> candidate : candidates){
+                for(TaxonName candidate : candidates){
                     if (this.compare(result, candidate) > 0){
                         result = candidate;
                     }
@@ -247,7 +247,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
          * @param candidate
          * @return
          */
-        private boolean hasBasionymCircle(TaxonName<?, ?> name, Set<TaxonName<?,?>> existing) {
+        private boolean hasBasionymCircle(TaxonName name, Set<TaxonName> existing) {
             if (existing == null){
                 existing = new HashSet<>();
             }
@@ -336,7 +336,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
         * without status nom. illeg.
         * @return
         */
-       protected int compare(TaxonName<?,?> name1, TaxonName name2, boolean includeNomIlleg) {
+       protected int compare(TaxonName name1, TaxonName name2, boolean includeNomIlleg) {
            int result;
 
            //dates
@@ -386,7 +386,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
            return result;
        }
 
-       private Integer getIntegerDate(TaxonName<?,?> name){
+       private Integer getIntegerDate(TaxonName name){
            Integer result;
 
           if (name == null){
@@ -420,7 +420,7 @@ public class HomotypicalGroupNameComparator implements Comparator<TaxonName>, Se
            return result;
        }
 
-       protected int compareNomIlleg(TaxonName<?,?> taxonName1, TaxonName taxonName2) {
+       protected int compareNomIlleg(TaxonName taxonName1, TaxonName taxonName2) {
            int isNomIlleg1 = isNomIlleg(taxonName1);
            int isNomIlleg2 = isNomIlleg(taxonName2);
            return isNomIlleg1 - isNomIlleg2;
index d930eee16f5c6cb5afe3ca0a0c332c5dada1bb95..aa27031b1fee8905b98a331688af3ca4fe1ef79a 100644 (file)
@@ -68,14 +68,14 @@ public class HybridRelationship extends RelationshipBase<INonViralName, INonVira
     @XmlSchemaType(name = "IDREF")
     @ManyToOne(fetch=FetchType.LAZY)
     @Cascade({CascadeType.SAVE_UPDATE,CascadeType.MERGE})
-       private TaxonName<?,?> relatedFrom;
+       private TaxonName relatedFrom;
 
        @XmlElement(name = "RelatedTo")
     @XmlIDREF
     @XmlSchemaType(name = "IDREF")
     @ManyToOne(fetch=FetchType.LAZY)
     @Cascade({CascadeType.SAVE_UPDATE,CascadeType.MERGE})
-       private TaxonName<?,?> relatedTo;
+       private TaxonName relatedTo;
 
     @XmlElement(name = "Type")
     @XmlIDREF
@@ -222,8 +222,8 @@ public class HybridRelationship extends RelationshipBase<INonViralName, INonVira
                if (compareType != 0){
                        return compareType;
                }else{
-                   TaxonName<?,?> related1 = this.getRelatedFrom();
-                   TaxonName<?,?> related2 = rel2.getRelatedFrom();
+                   TaxonName related1 = this.getRelatedFrom();
+                   TaxonName related2 = rel2.getRelatedFrom();
                        if (related1 != related2){
                                related1 = this.getRelatedTo();
                                related2 = rel2.getRelatedTo();
index 7461bd301073438b8942c44f41dee3c4fdbcdc87..f59f365a5d4d1ed2f1e4c1b63b4d25c162c3375a 100644 (file)
@@ -828,7 +828,7 @@ public interface ITaxonNameBase
      * @return the compareTo result similar to {@link Comparable#compareTo(Object)}
      * @throws NullPointerException if otherTaxon is <code>null</code>
      */
-    public int compareToName(TaxonName<?,?> otherName);
+    public int compareToName(TaxonName otherName);
 
     /**
      * This method returns als {@link Registration registrations} for the given name.
index 628d6a9c8cabf11acc62bc78683e4e18f6ccbfa1..551cfedf1df0c5cbbe6ee699b6511dad743abfe4 100644 (file)
@@ -182,8 +182,8 @@ import eu.etaxonomy.cdm.validation.annotation.ValidTaxonomicYear;
 @NameMustHaveAuthority(groups = Level2.class)
 @NoDuplicateNames(groups = Level3.class)
 @Indexed(index = "eu.etaxonomy.cdm.model.name.TaxonName")
-public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
-            extends IdentifiableEntity<S>
+public class TaxonName
+            extends IdentifiableEntity<INameCacheStrategy>
             implements ITaxonNameBase, INonViralName, IViralName, IBacterialName, IZoologicalName,
                 IBotanicalName, ICultivarPlantName, IFungusName,
                 IParsable, IRelated, IMatchable, IIntextReferenceTarget, Cloneable {
@@ -561,7 +561,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
      */
     protected static TaxonName NewInstance(NomenclaturalCode code, Rank rank,
             HomotypicalGroup homotypicalGroup) {
-        TaxonName<?,?> result = new TaxonName<>(code, rank, homotypicalGroup);
+        TaxonName result = new TaxonName(code, rank, homotypicalGroup);
         return result;
     }
 
@@ -583,7 +583,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
             String infraGenericEpithet, String specificEpithet, String infraSpecificEpithet,
             TeamOrPersonBase combinationAuthorship, Reference nomenclaturalReference,
             String nomenclMicroRef, HomotypicalGroup homotypicalGroup) {
-        TaxonName result = new TaxonName<>(code, rank, genusOrUninomial, infraGenericEpithet, specificEpithet, infraSpecificEpithet, combinationAuthorship, nomenclaturalReference, nomenclMicroRef, homotypicalGroup);
+        TaxonName result = new TaxonName(code, rank, genusOrUninomial, infraGenericEpithet, specificEpithet, infraSpecificEpithet, combinationAuthorship, nomenclaturalReference, nomenclMicroRef, homotypicalGroup);
         return result;
     }
 
@@ -679,15 +679,15 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
         }else if (this.cacheStrategy != null){
            //
         }else if (getNameType() == NomenclaturalCode.NonViral){
-            this.cacheStrategy = (S)NonViralNameDefaultCacheStrategy.NewInstance();
+            this.cacheStrategy = NonViralNameDefaultCacheStrategy.NewInstance();
         }else if (getNameType().isBotanical()){
-            this.cacheStrategy = (S)NonViralNameDefaultCacheStrategy.NewInstance();
+            this.cacheStrategy = NonViralNameDefaultCacheStrategy.NewInstance();
         }else if (getNameType() == NomenclaturalCode.ICZN){
-            this.cacheStrategy = (S)NonViralNameDefaultCacheStrategy.NewInstance();
+            this.cacheStrategy = NonViralNameDefaultCacheStrategy.NewInstance();
         }else if (getNameType() == NomenclaturalCode.ICNB){
-            this.cacheStrategy = (S)NonViralNameDefaultCacheStrategy.NewInstance();;
+            this.cacheStrategy = NonViralNameDefaultCacheStrategy.NewInstance();;
         }else if (getNameType() == NomenclaturalCode.ICVCN){
-            this.cacheStrategy = (S) ViralNameDefaultCacheStrategy.NewInstance();
+            this.cacheStrategy = ViralNameDefaultCacheStrategy.NewInstance();
         }
     }
 
@@ -1354,8 +1354,8 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
             return;
         }
 
-        TaxonName<?,?> parent = hybridRelation.getParentName();
-        TaxonName<?,?> child = hybridRelation.getHybridName();
+        TaxonName parent = hybridRelation.getParentName();
+        TaxonName child = hybridRelation.getHybridName();
         if (this.equals(parent)){
             this.hybridParentRelations.remove(hybridRelation);
             child.hybridChildRelations.remove(hybridRelation);
@@ -1373,7 +1373,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
 //********* METHODS **************************************/
 
     @Override
-    public S getCacheStrategy() {
+    public INameCacheStrategy getCacheStrategy() {
         rectifyNameCacheStrategy();
         return this.cacheStrategy;
     }
@@ -1430,7 +1430,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
     @Override
     @Transient
     public List<TaggedText> getTaggedName(){
-        S strat = getCacheStrategy();
+        INameCacheStrategy strat = getCacheStrategy();
         return strat.getTaggedTitle(this);
     }
 
@@ -2046,7 +2046,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
         Set<NameRelationship> rels = this.getRelationsToThisName();
         for (NameRelationship rel : rels){
             if (rel.getType()!= null && rel.getType().isBasionymRelation()){
-                TaxonName<?,?> basionym = rel.getFromName();
+                TaxonName basionym = rel.getFromName();
                 result.add(basionym);
             }
         }
@@ -2934,7 +2934,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
                 return false;
         }
 
-        for (TaxonName<?,?> taxonName : typifiedNames) {
+        for (TaxonName taxonName : typifiedNames) {
                 if (!taxonName.equals(this)) {
                         if (! isBasionymFor(taxonName)) {
                                 return false;
@@ -3175,7 +3175,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
         Set<NameRelationship> relations = new HashSet<NameRelationship>();
         Set<NameRelationship> removeRelations = new HashSet<NameRelationship>();
 
-        for(TaxonName<?, ?> typifiedName : homotypicalGroup.getTypifiedNames()){
+        for(TaxonName typifiedName : homotypicalGroup.getTypifiedNames()){
 
             Set<NameRelationship> nameRelations = typifiedName.getRelationsFromThisName();
 
@@ -3201,7 +3201,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
             this.removeNameRelationship(relation);
         }
 
-        for (TaxonName<?, ?> name : homotypicalGroup.getTypifiedNames()) {
+        for (TaxonName name : homotypicalGroup.getTypifiedNames()) {
             if (!name.equals(this)) {
 
                 // First check whether the relationship already exists
@@ -3234,7 +3234,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
         Set<NameRelationship> relations = new HashSet<NameRelationship>();
         Set<NameRelationship> removeRelations = new HashSet<NameRelationship>();
 
-        for(TaxonName<?, ?> typifiedName : homotypicalGroup.getTypifiedNames()){
+        for(TaxonName typifiedName : homotypicalGroup.getTypifiedNames()){
 
             Set<NameRelationship> nameRelations = typifiedName.getRelationsFromThisName();
 
@@ -3305,7 +3305,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
 // ***************** COMPARE ********************************/
 
     @Override
-    public int compareToName(TaxonName<?,?> otherName){
+    public int compareToName(TaxonName otherName){
 
         int result = 0;
 
@@ -3425,7 +3425,7 @@ public class TaxonName<T extends TaxonName<?,?>, S extends INameCacheStrategy>
      */
     @Override
     public Object clone() {
-        TaxonName<?,?> result;
+        TaxonName result;
         try {
             result = (TaxonName)super.clone();
 
index f5b8bef575c82f1219f0cfc52d852a263a05e0bb..be560f4eef857c6420c160cbb47b242bef793058 100644 (file)
@@ -425,7 +425,7 @@ public class TaxonNameFactory {
      * @param rank
      * @return
      */
-    public static TaxonName<?, ?> NewFungusInstance(Rank rank) {
+    public static TaxonName NewFungusInstance(Rank rank) {
         return TaxonName.NewInstance(NomenclaturalCode.Fungi, rank, null);
     }
 
index ddfaacc1611f8043044fdfe5b36be51684281ff6..aeb8d0c1d93ed1a949408750a1b04098a0ed9cfc 100644 (file)
@@ -89,7 +89,7 @@ public class DeterminationEvent extends EventBase {
        @ManyToOne(fetch = FetchType.LAZY)
        @IndexedEmbedded(includeEmbeddedObjectId=true)
     @Cascade({CascadeType.SAVE_UPDATE,CascadeType.MERGE})
-    private TaxonName<?,?> taxonName;
+    private TaxonName taxonName;
 
        @XmlElement(name = "Modifier")
        @XmlIDREF
index 4f2ae418070eca2a88ac62fa8bf463adce52e235..0e873fe524c9ba9f6cbca35a583f25b4a94b0bf2 100644 (file)
@@ -201,7 +201,7 @@ public class HomotypicGroupTaxonComparator extends TaxonComparator {
      * @param basionym
      * @return
      */
-    private TaxonName getFirstNameInGroup(TaxonName<?,?> basionym) {
+    private TaxonName getFirstNameInGroup(TaxonName basionym) {
         for (NameRelationship nameRel : basionym.getRelationsFromThisName()){
             if (nameRel.getType() != null && nameRel.getType().equals(NameRelationshipType.BASIONYM())){
                 if (nameRel.getToName().equals(firstNameInGroup)){
@@ -217,13 +217,13 @@ public class HomotypicGroupTaxonComparator extends TaxonComparator {
      * @return
      */
     @SuppressWarnings("rawtypes")
-    private Set<TaxonName> getReplacedSynonymClosure(TaxonName<?, ?> name) {
+    private Set<TaxonName> getReplacedSynonymClosure(TaxonName name) {
         Set<TaxonName> set = name.getReplacedSynonyms();
         if (set.isEmpty()){
             return set;
         }
         Set<TaxonName> result = new HashSet<>();
-        for (TaxonName<?,?> replSyn : set){
+        for (TaxonName replSyn : set){
             boolean notYetContained = result.add(replSyn);
             if (notYetContained){
                 result.addAll(replSyn.getReplacedSynonyms());
@@ -236,10 +236,10 @@ public class HomotypicGroupTaxonComparator extends TaxonComparator {
      * @param name
      * @return
      */
-    private TaxonName getPreferredInBasionymGroup(TaxonName<?,?> name) {
-        Set<TaxonName<?,?>> candidates = new HashSet<>();
+    private TaxonName getPreferredInBasionymGroup(TaxonName name) {
+        Set<TaxonName> candidates = new HashSet<>();
         //get all final basionyms, except for those being part of a basionym circle
-        for (TaxonName<?,?> candidate : name.getBasionyms()){
+        for (TaxonName candidate : name.getBasionyms()){
             if (candidate != null
                     && candidate.getHomotypicalGroup().equals(name.getHomotypicalGroup())
                     && !hasBasionymCircle(candidate, null)){
@@ -255,7 +255,7 @@ public class HomotypicGroupTaxonComparator extends TaxonComparator {
         }else{
             TaxonName result = candidates.iterator().next();
             candidates.remove(result);
-            for (TaxonName<?,?> candidate : candidates){
+            for (TaxonName candidate : candidates){
                 if (super.compare(result, candidate, false) > 0){
                     result = candidate;
                 }
@@ -268,7 +268,7 @@ public class HomotypicGroupTaxonComparator extends TaxonComparator {
      * @param candidate
      * @return
      */
-    private boolean hasBasionymCircle(TaxonName<?, ?> name, Set<TaxonName> existing) {
+    private boolean hasBasionymCircle(TaxonName name, Set<TaxonName> existing) {
         if (existing == null){
             existing = new HashSet<>();
         }
index 71ae8190d4939fada374628a4f4c302fed27e613..312191dc715c576ff51f61b2e7d067ea40e1e166 100644 (file)
@@ -128,7 +128,7 @@ public abstract class TaxonBase<S extends ITaxonCacheStrategy> extends Identifia
     @IndexedEmbedded(includeEmbeddedObjectId=true)
     @Cascade({CascadeType.SAVE_UPDATE,CascadeType.MERGE})
     @NotNull(groups = Level2.class)
-    private TaxonName<?,?> name;
+    private TaxonName name;
 
     // The concept reference
     @XmlElement(name = "Sec")
@@ -404,7 +404,7 @@ public abstract class TaxonBase<S extends ITaxonCacheStrategy> extends Identifia
 
         otherTaxon = deproxy(otherTaxon);
 
-        TaxonName<?,?> otherName = deproxy(otherTaxon.getName());
+        TaxonName otherName = deproxy(otherTaxon.getName());
         ITaxonNameBase thisName = this.getName();
         if ((otherName == null || thisName == null)){
             if (otherName != thisName){
index 5197585a16e4dda7b9fad30d7e506219c70c1223..d425c54605b1165033745f4a87821fb8c0e90761 100644 (file)
@@ -93,7 +93,7 @@ public class TaxonBaseDefaultCacheStrategy<T extends TaxonBase>
 
     private <X extends ITaxonNameBase> List<TaggedText> getNameTags(T taxonBase) {
         List<TaggedText> tags = new ArrayList<>();
-        TaxonName<?, INameCacheStrategy> name = CdmBase.deproxy(taxonBase.getName());
+        TaxonName name = CdmBase.deproxy(taxonBase.getName());
 
         if (name != null){
             INameCacheStrategy nameCacheStrategy = name.getCacheStrategy();
index 0315f02fabfbde1fda07b36da18b6d7c83ea5692..9bd58c9384fd54ee225db0b10b3e325f3c7acbee 100644 (file)
@@ -62,7 +62,7 @@ public class BasionymRelationCreator extends StrategyBase {
 
         //compare accepted against synonyms
         for (Synonym synonym: synonyms){
-            TaxonName<?, ?> basionym = compareHomotypic(taxon.getName(), synonym.getName());
+            TaxonName basionym = compareHomotypic(taxon.getName(), synonym.getName());
             if (basionym != null){
                 synonym.setType(SynonymType.HOMOTYPIC_SYNONYM_OF());
                 adaptHomotypicGroup(basionym, taxon.getName(), synonym.getName());
@@ -75,7 +75,7 @@ public class BasionymRelationCreator extends StrategyBase {
             for (int j = i + 1; j < synonymList.size(); j++){
                 Synonym syn1 = synonymList.get(i);
                 Synonym syn2 = synonymList.get(j);
-                TaxonName<?, ?> basionym = compareHomotypic(syn1.getName(), syn2.getName());
+                TaxonName basionym = compareHomotypic(syn1.getName(), syn2.getName());
                 if (basionym != null){
                     adaptHomotypicGroup(basionym, syn1.getName(), syn2.getName());
                     if (taxon.getName().getBasionyms().contains(basionym)){
@@ -92,8 +92,8 @@ public class BasionymRelationCreator extends StrategyBase {
      * @param name
      * @param name2
      */
-    private void adaptHomotypicGroup(TaxonName<?, ?> basionym,
-            TaxonName<?,?> name1, TaxonName<?,?> name2) {
+    private void adaptHomotypicGroup(TaxonName basionym,
+            TaxonName name1, TaxonName name2) {
         if (basionym.equals(name1)){
             if (!name2.getBasionyms().contains(name1)){
                 name2.addBasionym(name1);
@@ -109,15 +109,15 @@ public class BasionymRelationCreator extends StrategyBase {
      * @param name
      * @param name2
      */
-    private TaxonName<?,?> compareHomotypic(TaxonName<?,?> name1, TaxonName<?,?> name2) {
+    private TaxonName compareHomotypic(TaxonName name1, TaxonName name2) {
         if (name1 == null || name2 == null){
             return null;
         }
-        TaxonName<?,?> basionymCandidate = checkAuthors(name1, name2);
+        TaxonName basionymCandidate = checkAuthors(name1, name2);
         if (basionymCandidate == null){
             return null;
         }else{
-            TaxonName<?,?> newCombinationCandidate
+            TaxonName newCombinationCandidate
                 = basionymCandidate == name1? name2: name1;
             boolean isBasionym = compareNameParts(basionymCandidate, newCombinationCandidate);
             if (isBasionym){
@@ -132,8 +132,8 @@ public class BasionymRelationCreator extends StrategyBase {
      * @param basionymCandiate
      * @param newCombinationCandidate
      */
-    private boolean compareNameParts(TaxonName<?, ?> basionymCandidate,
-            TaxonName<?, ?> newCombinationCandidate) {
+    private boolean compareNameParts(TaxonName basionymCandidate,
+            TaxonName newCombinationCandidate) {
         if (basionymCandidate.isGenusOrSupraGeneric() || newCombinationCandidate.isGenusOrSupraGeneric()){
             return false;
         }else if (matchLastNamePart(basionymCandidate, newCombinationCandidate)){
@@ -147,7 +147,7 @@ public class BasionymRelationCreator extends StrategyBase {
      * @param name2
      * @return
      */
-    private TaxonName<?,?> checkAuthors(TaxonName<?, ?> name1, TaxonName<?, ?> name2) {
+    private TaxonName checkAuthors(TaxonName name1, TaxonName name2) {
         if (hasBasionymAuthorOf(name1, name2)){
             return name1;
         }else if (hasBasionymAuthorOf(name2, name1)){
@@ -162,7 +162,7 @@ public class BasionymRelationCreator extends StrategyBase {
      * @param name2
      * @return
      */
-    private boolean hasBasionymAuthorOf(TaxonName<?,?> name1, TaxonName<?,?> name2) {
+    private boolean hasBasionymAuthorOf(TaxonName name1, TaxonName name2) {
         TeamOrPersonBase<?> basAuthor2 = name2.getBasionymAuthorship();
         TeamOrPersonBase<?> combinationAuthor = name1.getCombinationAuthorship();
         TeamOrPersonBase<?> basAuthor1 = name1.getBasionymAuthorship();
@@ -198,7 +198,7 @@ public class BasionymRelationCreator extends StrategyBase {
      * @param newCombination
      * @return
      */
-    public static boolean matchLastNamePart(TaxonName<?,?> name1, TaxonName<?,?> name2) {
+    public static boolean matchLastNamePart(TaxonName name1, TaxonName name2) {
         String lastNamePart1 = name1.getLastNamePart();
         String lastNamePart2 = name2.getLastNamePart();
         if (lastNamePart1 != null && lastNamePart2 != null){
index df7d8583cbdb8171f5067f7b2794d1550f1903e8..c4c0852941c27dfe7bfd6949b602b32ab7cf7b89 100644 (file)
@@ -30,8 +30,8 @@ public class BasionymsMustShareEpithetsAndAuthorsValidator implements
        public boolean isValid(NameRelationship nameRelationship, ConstraintValidatorContext constraintContext) {
                boolean valid = true;
                if(nameRelationship.getType() != null && nameRelationship.getType().equals(NameRelationshipType.BASIONYM())) {
-                       TaxonName<?,?> from = CdmBase.deproxy(nameRelationship.getFromName(), TaxonName.class);
-                       TaxonName<?,?> to = CdmBase.deproxy(nameRelationship.getToName(), TaxonName.class);
+                       TaxonName from = CdmBase.deproxy(nameRelationship.getFromName(), TaxonName.class);
+                       TaxonName to = CdmBase.deproxy(nameRelationship.getToName(), TaxonName.class);
 
                        if(from.isNonViral() && to.isNonViral()) {
                                INonViralName fromName =  from;
index 0cd84a42fe3284d65e3dd32bc3cc80c7b5999166..2515f130aaecfd89c0ec4f8e0c525dd1137a9ca3 100644 (file)
@@ -35,8 +35,8 @@ public class ChildTaxaMustDeriveNameFromParentValidator implements
         Taxon child = taxonNode.getTaxon();\r
 \r
         if (parent != null && child != null && parent.getName() != null && child.getName() != null){\r
-            TaxonName<?,?> parentNameBase = CdmBase.deproxy(parent.getName(), TaxonName.class);\r
-            TaxonName<?,?> childNameBase = CdmBase.deproxy(child.getName(), TaxonName.class);\r
+            TaxonName parentNameBase = CdmBase.deproxy(parent.getName(), TaxonName.class);\r
+            TaxonName childNameBase = CdmBase.deproxy(child.getName(), TaxonName.class);\r
             if(parentNameBase.isNonViral() && childNameBase.isNonViral()) {\r
                 INonViralName parentName = parentNameBase;\r
                 INonViralName childName = childNameBase;\r
index c8aaf94a7ee8c3f6344491358e5cfd5b8fa7cb4e..8f134157d6579a93a8171e19eec7f6f8c5c6da04 100644 (file)
@@ -31,13 +31,13 @@ import eu.etaxonomy.cdm.validation.annotation.NameMustFollowCode;
  *
  */
 public class NameMustFollowCodeValidator implements
-        ConstraintValidator<NameMustFollowCode, TaxonName<?,?>> {
+        ConstraintValidator<NameMustFollowCode, TaxonName> {
 
     @Override
     public void initialize(NameMustFollowCode nameMustFollowTheirCode) { }
 
     @Override
-    public boolean isValid(TaxonName<?,?> name, ConstraintValidatorContext constraintContext) {
+    public boolean isValid(TaxonName name, ConstraintValidatorContext constraintContext) {
         name = CdmBase.deproxy(name);
         boolean valid = true;
 
index cdfd21d8b6f4f345764e9b2cf4bdad622740400c..534267ecd4772991f18e0f7d6197e5d30848b4df 100644 (file)
@@ -39,7 +39,7 @@ import eu.etaxonomy.cdm.model.name.TaxonNameFactory;
                @Test
                public void testPropertyChange() {
                    INonViralName b = TaxonNameFactory.NewNonViralInstance(Rank.SPECIES());
-                       ((TaxonName<?,?>)b).addPropertyChangeListener(this);
+                       ((TaxonName)b).addPropertyChangeListener(this);
                        b.setGenusOrUninomial("Abies");
                                assertEquals(b.getGenusOrUninomial(), lastPropValue);
                        b.setGenusOrUninomial("Picea");
index 8179715d49c15705a731291b9bd57a55ceccf869..8c4ab6a4ff345d0b3214d65eeee44aa7f3a9d1d2 100644 (file)
@@ -61,7 +61,7 @@ public class TaxonNameTest {
        }
 
 
-       private class TaxonNameTestClass extends TaxonName<TaxonNameTestClass, INameCacheStrategy>{
+       private class TaxonNameTestClass extends TaxonName{
                public TaxonNameTestClass(Rank rank, HomotypicalGroup hg){super(null, rank, hg);}
                @Override
                public void setCacheStrategy(INameCacheStrategy strategy){}
@@ -822,7 +822,7 @@ public class TaxonNameTest {
                description.addElement(textData);
 
                //CLONE
-               TaxonName<?,?> clone = (TaxonName)taxonName1.clone();
+               TaxonName clone = (TaxonName)taxonName1.clone();
                TaxonName genusClone = (TaxonName)genusName.clone();
                assertSame("Rank should be same", taxonName1.getRank(), clone.getRank());
                assertTrue("TaxonBases should not be cloned", clone.getTaxonBases().isEmpty());
index aa541455f9d5e1c6230680643a853ea9111d4c41..c7022ca29c8da551032b8601017c0dff36f51af3 100644 (file)
@@ -64,11 +64,11 @@ public class ClassificationTest {
        private static Taxon taxon3;
        private static Taxon taxon12;
        private static Taxon taxon121;
-       private static TaxonName<?,?> taxonName1;
-       private static TaxonName<?,?> taxonName2;
-       private static TaxonName<?,?> taxonName3;
-       private static TaxonName<?,?> taxonName12;
-       private static TaxonName<?,?> taxonName121;
+       private static TaxonName taxonName1;
+       private static TaxonName taxonName2;
+       private static TaxonName taxonName3;
+       private static TaxonName taxonName12;
+       private static TaxonName taxonName121;
        private static Reference ref1;
        private static Reference ref2;
        private static Reference ref3;
@@ -129,7 +129,7 @@ public class ClassificationTest {
         */
        @Test
        public void testAddRoot() {
-               TaxonName<?,?> synonymName = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+               TaxonName synonymName = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                Synonym synonym = Synonym.NewInstance(synonymName, ref1);
                TaxonNode taxonNode1 = classification1.addChildTaxon(taxon1, null, null);
                taxonNode1.setSynonymToBeUsed(synonym);
@@ -230,7 +230,7 @@ public class ClassificationTest {
        @Test
        public void testAddParentChild() {
 
-               TaxonName<?,?> synonymName = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+               TaxonName synonymName = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                Synonym synonym = Synonym.NewInstance(synonymName, ref1);
                TaxonNode rootNode = classification1.addChildTaxon(taxon1, null, null);
                rootNode.setSynonymToBeUsed(synonym);
@@ -346,7 +346,7 @@ public class ClassificationTest {
                //genericDao.getCdmBasesByFieldAndClass(clazz, field.getName(), value);
 
 
-               TaxonName<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
+               TaxonName name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
                name.setTitleCache("A dummy name", true);
                result.add(name);
                Reference ref = ReferenceFactory.newBook();
index eb3b775c6e59461fe2686495a476762b67ea4e50..053bbbfbbc8f84e20190f87ba75044a783c3500a 100644 (file)
@@ -166,7 +166,7 @@ public class TaxonBaseTest extends EntityTestBase {
           @Test\r
           public void testCompareTo() {\r
 \r
-              TaxonName<?,?> abies = TaxonNameFactory.NewNonViralInstance(Rank.GENUS(), null);\r
+              TaxonName abies = TaxonNameFactory.NewNonViralInstance(Rank.GENUS(), null);\r
               abies.setNameCache("Abies");\r
               abies.setTitleCache("Abies", true);\r
               Reference sec = ReferenceFactory.newArticle();\r
index 2d36c9f3bb073b8711f5a56c0621e29e5fbca260..754c5775d53c6fc89840a9b83e8d6e62d03a3d0c 100644 (file)
@@ -312,7 +312,7 @@ public class NonViralNameDefaultCacheStrategyTest extends NameCacheStrategyTestB
     @Test
     public void testOriginalSpelling() {
        NameRelationshipType origSpellingType = NameRelationshipType.ORIGINAL_SPELLING();
-       TaxonName originalName = (TaxonName<?,?>)speciesName.clone();
+       TaxonName originalName = (TaxonName)speciesName.clone();
        originalName.setSpecificEpithet("alpa");
        Assert.assertEquals("Preconditions are wrong", "Abies alpa", originalName.getTitleCache());
         Assert.assertEquals("Name cache should not show original spelling", "Abies alpa", originalName.getNameCache());
@@ -331,7 +331,7 @@ public class NonViralNameDefaultCacheStrategyTest extends NameCacheStrategyTestB
 
        //#3665
        INonViralName correctName = NonViralNameParserImpl.NewInstance().parseFullName("Nepenthes glabrata J.R.Turnbull & A.T.Middleton");
-       TaxonName originalSpelling = (TaxonName<?,?>)NonViralNameParserImpl.NewInstance().parseFullName("Nepenthes glabratus");
+       TaxonName originalSpelling = (TaxonName)NonViralNameParserImpl.NewInstance().parseFullName("Nepenthes glabratus");
        correctName.addRelationshipFromName(originalSpelling, origSpellingType, null);
        Assert.assertEquals("Nepenthes glabrata", correctName.getNameCache());
        Assert.assertEquals("Nepenthes glabrata J.R.Turnbull & A.T.Middleton", correctName.getTitleCache());
index ea83c519016a9cfbc7568a028d2b6149d8f86e7d..4c15d4a6e4f640854a25bcc671d93472c031e843 100644 (file)
@@ -40,10 +40,10 @@ public class BasionymRelationCreatorTest {
     private Synonym synonym1;
     private Synonym synonym2;
     private Synonym synonym3;
-    private TaxonName<?,?> accName1;
-    private TaxonName<?,?> synName1;
-    private TaxonName<?,?> synName2;
-    private TaxonName<?,?> synName3;
+    private TaxonName accName1;
+    private TaxonName synName1;
+    private TaxonName synName2;
+    private TaxonName synName3;
     private Person person1;
     private Person person2;
     private Person person3;
index 300c8ef44541e0f1e2066cf046b0a2be8a4b0896..f502583c329b06336ac94e1a7e409b3926cf5195 100644 (file)
@@ -62,7 +62,7 @@ public class NameMustFollowCodeTest extends ValidationTestBase {
 
     @Test
     public void testValidEmptyNames() {
-        Set<ConstraintViolation<TaxonName<?,?>>> constraintViolations
+        Set<ConstraintViolation<TaxonName>> constraintViolations
                             = validator.validate(cultivarName);
         assertTrue("There should be no constraint violations as this name has data set and therefore no unvalid attributes set", constraintViolations.isEmpty());
 
@@ -82,7 +82,7 @@ public class NameMustFollowCodeTest extends ValidationTestBase {
     @Test
     public void testMessage() {
         nonViralName.setAcronym("acronym");
-        Set<ConstraintViolation<TaxonName<?,?>>> constraintViolations  = validator.validate(nonViralName);
+        Set<ConstraintViolation<TaxonName>> constraintViolations  = validator.validate(nonViralName);
         assertFalse("There should be a constraint violation as a nonViralName must not have an acronym", constraintViolations.isEmpty());
         String message = constraintViolations.iterator().next().getMessage();
         String expected = "Taxon name must only have attributes set that are available according to their code. E.g. 'acronym name' should only be available for viral names.";
@@ -92,7 +92,7 @@ public class NameMustFollowCodeTest extends ValidationTestBase {
        @Test
        public void testValidNonViralName() {
            nonViralName.setAcronym("acronym");
-           Set<ConstraintViolation<TaxonName<?,?>>> constraintViolations  = validator.validate(nonViralName);
+           Set<ConstraintViolation<TaxonName>> constraintViolations  = validator.validate(nonViralName);
         assertFalse("There should be a constraint violation as a nonViralName must not have an acronym", constraintViolations.isEmpty());
 
         nonViralName = TaxonNameFactory.NewNonViralInstance(Rank.SPECIES());
@@ -148,7 +148,7 @@ public class NameMustFollowCodeTest extends ValidationTestBase {
     @Test
     public void testValidViralName() {
         viralName.setAcronym("acronym");
-        Set<ConstraintViolation<TaxonName<?,?>>> constraintViolations  = validator.validate(viralName);
+        Set<ConstraintViolation<TaxonName>> constraintViolations  = validator.validate(viralName);
         assertTrue("There should be no constraint violation as a viral name may have acronym set", constraintViolations.isEmpty());
 
         //Invalid
@@ -183,7 +183,7 @@ public class NameMustFollowCodeTest extends ValidationTestBase {
         zoologicalName.setOriginalPublicationYear(1987);
         zoologicalName.setPublicationYear(2001);
 
-        Set<ConstraintViolation<TaxonName<?,?>>> constraintViolations  = validator.validate(zoologicalName);
+        Set<ConstraintViolation<TaxonName>> constraintViolations  = validator.validate(zoologicalName);
         assertTrue("There should be no constraint violation as a zoological name may have breed and years set", constraintViolations.isEmpty());
     }
 
@@ -192,7 +192,7 @@ public class NameMustFollowCodeTest extends ValidationTestBase {
         bacterialName.setSubGenusAuthorship("Subgenus author");
         bacterialName.setNameApprobation("Name approbation");
 
-        Set<ConstraintViolation<TaxonName<?,?>>> constraintViolations  = validator.validate(bacterialName);
+        Set<ConstraintViolation<TaxonName>> constraintViolations  = validator.validate(bacterialName);
         assertTrue("There should be no constraint violation as a bacterial name may have subgenus authorship or name approbation set", constraintViolations.isEmpty());
     }
 
index 01249ba5da0407708338fa3df01e6bc29e843eb1..c9daa1a0d17b3f36e3889fcf5dd833b49eaa0239 100644 (file)
@@ -265,7 +265,7 @@ public class DeduplicationHelper {
                //TODO cast
                getCollectionRoles(clazz, sessionFactory);
 
-               TaxonName<?,?> name1 = TaxonNameFactory.NewBotanicalInstance(null);
+               TaxonName name1 = TaxonNameFactory.NewBotanicalInstance(null);
                name1.getTaxonBases();
 
                Type propType = sessionFactory.getReferencedPropertyType(TaxonName.class.getCanonicalName(), "taxonBases");
index 618605555377f3104b30dd93c4381624b11f2e64..bf42354ca100e93cc59cfffe84637731154bf010 100644 (file)
@@ -395,7 +395,7 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
     }
 
 
-    public List<TaxonName<?,?>> searchNames(String queryString, MatchMode matchMode, Integer pageSize, Integer pageNumber) {
+    public List<TaxonName> searchNames(String queryString, MatchMode matchMode, Integer pageSize, Integer pageNumber) {
         checkNotInPriorView("TaxonNameDaoHibernateImpl.searchNames(String queryString, Integer pageSize, Integer pageNumber)");
         Criteria criteria = getSession().createCriteria(TaxonName.class);
 
@@ -410,13 +410,13 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
                 criteria.setFirstResult(0);
             }
         }
-        List<TaxonName<?,?>> results = criteria.list();
+        List<TaxonName> results = criteria.list();
         return results;
     }
 
 
     @Override
-    public List<TaxonName<?,?>> searchNames(String queryString, Integer pageSize, Integer pageNumber) {
+    public List<TaxonName> searchNames(String queryString, Integer pageSize, Integer pageNumber) {
         return searchNames(queryString, MatchMode.BEGINNING, pageSize, pageNumber);
     }
 
@@ -521,7 +521,7 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
     }
 
     @Override
-    public List<? extends TaxonName<?,?>> findByName(boolean doIncludeAuthors,
+    public List<? extends TaxonName> findByName(boolean doIncludeAuthors,
             String queryString, MatchMode matchmode, Integer pageSize,
             Integer pageNumber, List<Criterion> criteria, List<String> propertyPaths) {
 
@@ -564,14 +564,14 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
         }
 
         @SuppressWarnings("unchecked")
-        List<? extends TaxonName<?,?>> results = crit.list();
+        List<? extends TaxonName> results = crit.list();
         defaultBeanInitializer.initializeAll(results, propertyPaths);
 
         return results;
     }
 
     @Override
-    public List<? extends TaxonName<?,?>> findByTitle(String queryString,
+    public List<? extends TaxonName> findByTitle(String queryString,
             MatchMode matchmode, Integer pageSize, Integer pageNumber, List<Criterion> criteria, List<String> propertyPaths) {
 
         Criteria crit = getSession().createCriteria(type);
@@ -594,7 +594,7 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
             }
         }
 
-        List<? extends TaxonName<?,?>> results = crit.list();
+        List<? extends TaxonName> results = crit.list();
         defaultBeanInitializer.initializeAll(results, propertyPaths);
 
         return results;
@@ -619,10 +619,10 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
         }
         crit.addOrder(Order.asc("uuid"));
 
-        List<? extends TaxonName<?,?>> results = crit.list();
+        List<? extends TaxonName> results = crit.list();
         if (results.size() == 1) {
             defaultBeanInitializer.initializeAll(results, propertyPaths);
-            TaxonName<?, ?> taxonName = results.iterator().next();
+            TaxonName taxonName = results.iterator().next();
             return taxonName;
         } else if (results.size() > 1) {
             logger.error("Multiple results for UUID: " + uuid);
@@ -701,7 +701,7 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
     public Integer countByName(String queryString, MatchMode matchmode, List<Criterion> criteria) {
         //TODO improve performance
         boolean includeAuthors = false;
-        List<? extends TaxonName<?,?>> results = findByName(
+        List<? extends TaxonName> results = findByName(
                 includeAuthors,queryString, matchmode, null, null, criteria, null);
         return results.size();
 
@@ -791,10 +791,10 @@ public class TaxonNameDaoHibernateImpl extends IdentifiableDaoBase<TaxonName> im
         }
 
         @SuppressWarnings("unchecked")
-        List<? extends TaxonName<?,?>> results = criteria.list();
+        List<? extends TaxonName> results = criteria.list();
         if (results.size() == 1) {
             defaultBeanInitializer.initializeAll(results, null);
-            TaxonName<?, ?> taxonName = results.iterator().next();
+            TaxonName taxonName = results.iterator().next();
             if (taxonName.isZoological()) {
                 IZoologicalName zoologicalName = taxonName;
                 return zoologicalName;
index 0eb1e7e9dd76e200583de8657a7b8866f7cbed7b..9b1d0eae633f9b1f136b373fbd6b1382d90dd0a0 100644 (file)
@@ -42,9 +42,9 @@ import org.springframework.stereotype.Repository;
 
 import eu.etaxonomy.cdm.model.common.DefinedTerm;
 import eu.etaxonomy.cdm.model.common.IdentifiableEntity;
+import eu.etaxonomy.cdm.model.common.IdentifiableSource;
 import eu.etaxonomy.cdm.model.common.LSID;
 import eu.etaxonomy.cdm.model.common.MarkerType;
-import eu.etaxonomy.cdm.model.common.OriginalSourceBase;
 import eu.etaxonomy.cdm.model.common.RelationshipBase.Direction;
 import eu.etaxonomy.cdm.model.location.NamedArea;
 import eu.etaxonomy.cdm.model.name.Rank;
@@ -192,7 +192,7 @@ public class TaxonDaoHibernateImpl extends IdentifiableDaoBase<TaxonBase> implem
         boolean includeAuthors = false;
         List<UuidAndTitleCache<IdentifiableEntity>> resultObjects = new ArrayList<UuidAndTitleCache<IdentifiableEntity>>();
         if (doNamesWithoutTaxa){
-               List<? extends TaxonName<?,?>> nameResult = taxonNameDao.findByName(
+               List<? extends TaxonName> nameResult = taxonNameDao.findByName(
                        includeAuthors, queryString, matchMode, null, null, null, null);
 
                for (TaxonName name: nameResult){
@@ -1357,9 +1357,9 @@ public class TaxonDaoHibernateImpl extends IdentifiableDaoBase<TaxonBase> implem
         query = getSession().createQuery("from ZoologicalName zn where zn.nameCache IN (:identicalNames)");
         query.setParameterList("identicalNames", identicalNames);
         List<TaxonName> result = query.list();
-        TaxonName temp = result.get(0);
+        TaxonName tempName = result.get(0);
 
-        Iterator<OriginalSourceBase> sources = temp.getSources().iterator();
+        Iterator<IdentifiableSource> sources = tempName.getSources().iterator();
 
         TaxonNameComparator taxComp = new TaxonNameComparator();
         Collections.sort(result, taxComp);
index e56aadb1cb4314281034b3da2f3ff4764dfa8d57..0653fb2f3aa67c387e762d886a79d6b3ac1840c1 100644 (file)
@@ -72,7 +72,7 @@ public class TitleAndNameCacheAutoInitializer extends AutoPropertyInitializer<Id
             }
         } else if(bean instanceof TaxonName) {
              // ---> TaxonName
-            TaxonName n = (TaxonName<?,?>)bean;
+            TaxonName n = (TaxonName)bean;
             if(!n.isProtectedFullTitleCache())  {
                 n.getFullTitleCache();
             } else if(!bean.isProtectedTitleCache()){
index c3a899eb7f7d908533896f3f6110388cce8a31fc..6633135b20e848b9f57b7a28674c3475f3eaeac8 100644 (file)
@@ -229,7 +229,7 @@ public interface ITaxonNameDao extends IIdentifiableDao<TaxonName> {
         *            set (0 - based)\r
         * @return a List of TaxonName instances\r
         */\r
-       public List<TaxonName<?, ?>> searchNames(String queryString,\r
+       public List<TaxonName> searchNames(String queryString,\r
                        Integer pageSize, Integer pageNumber);\r
 \r
 \r
@@ -252,7 +252,7 @@ public interface ITaxonNameDao extends IIdentifiableDao<TaxonName> {
         * @param propertyPaths TODO\r
         * @return\r
         */\r
-       public List<? extends TaxonName<?, ?>> findByName(boolean doIncludeAuthors,\r
+       public List<? extends TaxonName> findByName(boolean doIncludeAuthors,\r
                String queryString,\r
                        MatchMode matchmode, Integer pageSize, Integer pageNumber,\r
                        List<Criterion> criteria, List<String> propertyPaths);\r
@@ -266,7 +266,7 @@ public interface ITaxonNameDao extends IIdentifiableDao<TaxonName> {
         * @param propertyPaths TODO\r
         * @return\r
         */\r
-       public List<? extends TaxonName<?, ?>> findByTitle(String queryString,\r
+       public List<? extends TaxonName> findByTitle(String queryString,\r
                        MatchMode matchmode, Integer pageSize, Integer pageNumber,\r
                        List<Criterion> criteria, List<String> propertyPaths);\r
 \r
@@ -281,7 +281,7 @@ public interface ITaxonNameDao extends IIdentifiableDao<TaxonName> {
         *\r
         * @return\r
         */\r
-       public TaxonName<?, ?> findByUuid(UUID uuid, List<Criterion> criteria, List<String> propertyPaths);\r
+       public TaxonName findByUuid(UUID uuid, List<Criterion> criteria, List<String> propertyPaths);\r
 \r
        /**\r
         * @param queryString\r
index e6a9684f61fdb65dcb82c54a6d5b93ba24b1d958..5134973064c28f63e70867e8e20ba392bdb09e92 100644 (file)
@@ -98,7 +98,7 @@ public class BeanInitializerIntegration extends CdmTransactionalIntegrationTest
                propertyPaths.add("combinationAuthorship");
                propertyPaths.add("hybridRelationships");
 
-               TaxonName<?,?> sphingidae = taxonNameDao.load(sphingidaeUuid, propertyPaths);
+               TaxonName sphingidae = taxonNameDao.load(sphingidaeUuid, propertyPaths);
                setComplete();
                endTransaction();
 
index ab1e08ffc3d3ab4852bb34a3983ce98ea1ebe229..a8ad4007acec9587a2ea9371272a6d112830c7c4 100644 (file)
@@ -492,10 +492,10 @@ public class CdmGenericDaoImplTest extends CdmTransactionalIntegrationTest {
 //     @Ignore
        public void testMergeCdmBaseReferenceAndIdentifiable() throws MergeException {
 
-               TaxonName<?,?> name1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+               TaxonName name1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                name1.setTitleCache("BotanicalName1", true);
 
-               TaxonName<?,?> name2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+               TaxonName name2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                name2.setTitleCache("BotanicalName2", true);
 
                TaxonName zooName1 = TaxonNameFactory.NewZoologicalInstance(Rank.SPECIES());
@@ -622,10 +622,10 @@ public class CdmGenericDaoImplTest extends CdmTransactionalIntegrationTest {
        @Test
 //     @Ignore
        public void testMergeTaxonNameAndTaxon() throws MergeException {
-           TaxonName<?,?> name1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+           TaxonName name1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                name1.setTitleCache("BotanicalName1", true);
 
-               TaxonName<?,?> name2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+               TaxonName name2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                name2.setTitleCache("BotanicalName2", true);
 
                IBotanicalName name3 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
@@ -869,11 +869,11 @@ public class CdmGenericDaoImplTest extends CdmTransactionalIntegrationTest {
         UUID uuidAbiesAlba = UUID.fromString("6ed56b43-7cca-4c3b-bb90-7576da81c072");
 
         // CREATE DATA
-        TaxonName<?,?> pinusAlba = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+        TaxonName pinusAlba = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
         pinusAlba.setTitleCache("BotanicalName1", true);
         pinusAlba.setUuid(uuidPinusAlba);
 
-        TaxonName<?,?> abiesAlba = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+        TaxonName abiesAlba = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
         abiesAlba.setTitleCache("Abies alba", true);
         abiesAlba.setUuid(uuidAbiesAlba);
 
@@ -912,7 +912,7 @@ public class CdmGenericDaoImplTest extends CdmTransactionalIntegrationTest {
        @Test
        public void testReallocatePersonTeam() throws MergeException {
 
-           TaxonName<?,?> name1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+           TaxonName name1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                name1.setTitleCache("BotanicalName1", true);
 
                IBook book1 = ReferenceFactory.newBook();
index 79dd99e37df296e03365a8ef3b9fc64040348fd6..26ecc48ec1c8313a993613dddaea092284fdb316 100644 (file)
@@ -101,13 +101,13 @@ public class CacheStrategyGeneratorTest extends CdmTransactionalIntegrationTest
        @ExpectedDataSet
        public void testOnSaveOrUpdateNames() {
                //names
-           TaxonName<?,?> name =  cdmEntityDaoBase.findByUuid(UUID.fromString("a49a3963-c4ea-4047-8588-2f8f15352730"));
+           TaxonName name =  cdmEntityDaoBase.findByUuid(UUID.fromString("a49a3963-c4ea-4047-8588-2f8f15352730"));
                name.setTitleCache(null, false);
                name.setNameCache(null, false);
                name.setGenusOrUninomial("Abies");
                name.setAuthorshipCache("Mill.", true);
                cdmEntityDaoBase.saveOrUpdate(name);
-               TaxonName<?,?> name2 =  cdmEntityDaoBase.findByUuid(UUID.fromString("05a438d6-065f-49ef-84db-c7dc2c259975"));
+               TaxonName name2 =  cdmEntityDaoBase.findByUuid(UUID.fromString("05a438d6-065f-49ef-84db-c7dc2c259975"));
                name2.setProtectedFullTitleCache(false);
                name2.setProtectedTitleCache(false);
                name2.setProtectedNameCache(false);
@@ -127,13 +127,13 @@ public class CacheStrategyGeneratorTest extends CdmTransactionalIntegrationTest
                Assert.assertEquals(name2, cdmEntityDaoBase.findByUuid(name2.getUuid()));
                logger.debug("FulltitleCache: "+ cdmEntityDaoBase.findByUuid(name2.getUuid()).getFullTitleCache());
                logger.debug("updated: " + cdmEntityDaoBase.findByUuid(name2.getUuid()).getUpdated());
-               TaxonName<?,?> name3 = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
+               TaxonName name3 = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
                name3.setFullTitleCache("Test: MyBook");
                name3.setTitleCache("Test", true);
                cdmEntityDaoBase.saveOrUpdate(name3);
                List<TaxonName> taxa = cdmEntityDaoBase.findByTitle("Test");
 
-               TaxonName<?,?> nameBase = taxa.get (0);
+               TaxonName nameBase = taxa.get (0);
                IBotanicalName botName = nameBase;
 
                logger.debug("created "+botName.getCreated());
index eeeca8b0c0e1e4c9d7e6bc3081962ca352f0700b..17e9de8e0770d91227efe7273da981a5d6f96dea 100644 (file)
@@ -59,7 +59,7 @@ public class CdmDeleteListenerTest extends CdmTransactionalIntegrationTest {
        @DataSet("CdmDeleteListenerTest.xml")
        @ExpectedDataSet
        public void testOnDelete() throws Exception {
-               TaxonName<?,?> name = taxonNameDao.findByUuid(uuid);
+               TaxonName name = taxonNameDao.findByUuid(uuid);
                /**
                 * Ended up with some horrible hibernate errors otherwise
                 */
index c0bc03b6dc2a4141578719ccf74ac2d8456d2120..d718cf5181fc7a9cd8c2e90e5ecc659778f91de5 100644 (file)
@@ -598,7 +598,7 @@ public class ClassificationServiceImpl extends IdentifiableServiceBase<Classific
                if(parentNode == null){
                        //if no match found in list, create parentNode
                        NonViralNameParserImpl parser = NonViralNameParserImpl.NewInstance();
-                       TaxonName<?,?> TaxonName = (TaxonName<?,?>)parser.parseFullName(genus);
+                       TaxonName TaxonName = (TaxonName)parser.parseFullName(genus);
                        //TODO Sec via configurator
                        Taxon taxon = Taxon.NewInstance(TaxonName, null);
                        parentNode = newClassification.addChildTaxon(taxon, 0, null, null);
@@ -877,7 +877,7 @@ public class ClassificationServiceImpl extends IdentifiableServiceBase<Classific
         }
         result.setTaxonLabel(taxonBase.getTitleCache());
 
-        TaxonName<?,?> name = taxonBase.getName();
+        TaxonName name = taxonBase.getName();
         result.setNameUuid(name.getUuid());
         result.setNameLabel(name.getTitleCache());
         result.setNameWithoutAuthor(name.getNameCache());
index aecff2c473d994196e2ed68f2b46f8063c9ae817..3ddbfb63dda27d347538761de97c2cacf6e5d478 100644 (file)
@@ -273,7 +273,7 @@ public abstract class IdentifiableServiceBase<T extends IdentifiableEntity, DAO
                                if (entity.getTitleCache() != null){
                                        //System.err.println(entity.getTitleCache());
                                }else{
-                                   //System.err.println("no titleCache" + ((TaxonName<?,?>)entity).getNameCache());
+                                   //System.err.println("no titleCache" + ((TaxonName)entity).getNameCache());
                                }
                        }
                        saveOrUpdate(entitiesToUpdate);
index 4de15a857b8b022ea5fd13f513e5d855a7736de0..7540b9aa5e8b82ce3b56e8a6df7873c8b9e2b1d4 100644 (file)
@@ -251,7 +251,7 @@ public class NameServiceImpl extends IdentifiableServiceBase<TaxonName,ITaxonNam
      * @param name
      * @param config
      */
-    private void removeNameRelationshipsByDeleteConfig(TaxonName<?,?> name, NameDeletionConfigurator config) {
+    private void removeNameRelationshipsByDeleteConfig(TaxonName name, NameDeletionConfigurator config) {
         try {
             if (config.isRemoveAllNameRelationships()){
                 Set<NameRelationship> rels = getModifiableSet(name.getNameRelations());
index bddd4116de388a222be7a68662be1360f80a9371..bc42e6d1b80ea2dc995a10e5fa1358b1074c3a09 100644 (file)
@@ -1344,7 +1344,7 @@ public class OccurrenceServiceImpl extends IdentifiableServiceBase<SpecimenOrObs
                     associatedTaxa.add(determinationEvent.getTaxon());
                 }
                 if(determinationEvent.getTaxonName()!=null){
-                    associatedTaxa.addAll(determinationEvent.getTaxonName().getTaxonBases());
+                    associatedTaxa.addAll((Collection)determinationEvent.getTaxonName().getTaxonBases());
                 }
             }
         }
index 8d9c9c3367670b086d4e2f3877cf5555f2abcdc2..f600a7177cd89d3e8d58b9078d6d8170ab546e5a 100644 (file)
@@ -315,7 +315,7 @@ public class TaxonServiceImpl extends IdentifiableServiceBase<TaxonBase,ITaxonDa
         if (synonym == null){
             return null;
         }
-        TaxonName<?, ?> synonymName = synonym.getName();
+        TaxonName synonymName = synonym.getName();
 
       /*  // remove synonym from taxon
         toTaxon.removeSynonym(synonym);
@@ -703,12 +703,12 @@ public class TaxonServiceImpl extends IdentifiableServiceBase<TaxonBase,ITaxonDa
         if (configurator.isDoNamesWithoutTaxa()) {
             int numberNameResults = 0;
 
-            List<? extends TaxonName<?,?>> names =
+            List<? extends TaxonName> names =
                 nameDao.findByName(configurator.isDoIncludeAuthors(), configurator.getTitleSearchStringSqlized(), configurator.getMatchMode(),
                         configurator.getPageSize(), configurator.getPageNumber(), null, configurator.getTaxonNamePropertyPath());
             if (logger.isDebugEnabled()) { logger.debug(names.size() + " matching name(s) found"); }
             if (names.size() > 0) {
-                for (TaxonName<?,?> taxonName : names) {
+                for (TaxonName taxonName : names) {
                     if (taxonName.getTaxonBases().size() == 0) {
                         results.add(taxonName);
                         numberNameResults++;
@@ -2851,7 +2851,7 @@ public class TaxonServiceImpl extends IdentifiableServiceBase<TaxonBase,ITaxonDa
 
         UpdateResult result = new UpdateResult();
         // Create new synonym using concept name
-        TaxonName<?, ?> synonymName = fromTaxon.getName();
+        TaxonName synonymName = fromTaxon.getName();
 
         // Remove concept relation from taxon
         toTaxon.removeTaxon(fromTaxon, oldRelationshipType);
index 6b6be07d1a761d16b9a82ab47a81a1e4f85fbfcd..daa9880820f042efdedc7f275f30dbab9db92fa7 100644 (file)
@@ -23,7 +23,7 @@ import eu.etaxonomy.cdm.model.name.TaxonName;
 import eu.etaxonomy.cdm.validation.annotation.NoDuplicateNames;
 
 public class NoDuplicateNamesValidator implements
-               ConstraintValidator<NoDuplicateNames,TaxonName<?,?>> {
+               ConstraintValidator<NoDuplicateNames,TaxonName> {
 
        private static Set<String> includeProperties;
 
@@ -53,7 +53,7 @@ public class NoDuplicateNamesValidator implements
        public void initialize(NoDuplicateNames noDuplicateNames) { }
 
     @Override
-       public boolean isValid(TaxonName<?,?> name, ConstraintValidatorContext constraintContext) {
+       public boolean isValid(TaxonName name, ConstraintValidatorContext constraintContext) {
                if(name == null) {
                        return true;
                } else {
index 796e0a661b3cffe17944606689d92688926d262f..cb80af4307b3e452c99eb82610bad26c6a2a5dcc 100644 (file)
@@ -105,7 +105,7 @@ public class DerivedUnitFacadeCacheStrategyInjectionTest extends CdmTransactiona
     private final String exsiccatum = "Greuter, Pl. Dahlem. 456";
     private final String accessionNumber = "8909756";
     private final String catalogNumber = "UU879873590";
-    private final TaxonName<?,?> taxonName = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS(), "Abies", null, null, null, null, null, null, null);
+    private final TaxonName taxonName = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS(), "Abies", null, null, null, null, null, null, null);
     private final String collectorsNumber = "234589913A34";
     private final Collection collection = Collection.NewInstance();
 
index a29cf31fcae820492c421822cc6cf28a85f9b3f9..8b00ac36612185cebf55efcd415425f7053423af 100644 (file)
@@ -79,7 +79,7 @@ public class DerivedUnitFacadeCacheStrategyTest extends CdmIntegrationTest {
        String accessionNumber = "8909756";
        String catalogNumber = "UU879873590";
        String barcode = "B12345678";
-       TaxonName<?,?> taxonName = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS(), "Abies", null, null, null, null, null, null, null);
+       TaxonName taxonName = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS(), "Abies", null, null, null, null, null, null, null);
        String collectorsNumber = "234589913A34";
        Collection collection = Collection.NewInstance();
 
index c72b070ca41ea03c3ff9c4afb9065e92093bcf24..2e6cf6553983174ab3e6e3beeb1002a2700639c6 100644 (file)
@@ -59,7 +59,7 @@ public class AgentServiceImplTest extends CdmTransactionalIntegrationTest{
        person.setNomenclaturalTitle(nomTitle);
        Annotation annotation = Annotation.NewDefaultLanguageInstance("Meine annotation");
        person.setContact(getContact());
-       TaxonName<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+       TaxonName name = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
        name.setCombinationAuthorship(person);
        person.addAnnotation(annotation);
 
@@ -102,7 +102,7 @@ public class AgentServiceImplTest extends CdmTransactionalIntegrationTest{
        Annotation annotation = Annotation.NewDefaultLanguageInstance("Meine annotation");
        team.addAnnotation(annotation);
        team.setContact(getContact());
-       TaxonName<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+       TaxonName name = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
        name.setCombinationAuthorship(team);
 
        service.save(team);
@@ -141,7 +141,7 @@ public class AgentServiceImplTest extends CdmTransactionalIntegrationTest{
        Annotation annotation2 = Annotation.NewDefaultLanguageInstance("Meine annotation2");
        team.addAnnotation(annotation2);
        team.setContact(getContact());
-       TaxonName<?,?> name = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+       TaxonName name = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
        name.setCombinationAuthorship(team);
        Person member = Person.NewTitledInstance("Member person");
        member.setNomenclaturalTitle("Memb. pers.");
index 939cbd0a06b803e120f55735898a0fe95664618c..d813bd9f1acfd75b5f6e74500aff2998192fe859 100644 (file)
@@ -111,7 +111,7 @@ public class ClassificationServiceDeepTest extends CdmTransactionalIntegrationTe
        Map<String, Taxon> map = new HashMap<String, Taxon>();
        for(String strName : stringTaxonNames){
                NonViralNameParserImpl parser = NonViralNameParserImpl.NewInstance();
-               TaxonName<?,?> nameBase = (TaxonName<?,?>)parser.parseFullName(strName);
+               TaxonName nameBase = (TaxonName)parser.parseFullName(strName);
                Taxon taxon = Taxon.NewInstance(nameBase, null);
                map.put(strName, taxon);
        }
index fae5709aeb274cb43305efacbf5553c2575eda7d..f0c9fbdf9eebee650ad4303f38f133344525c01a 100644 (file)
@@ -120,9 +120,9 @@ public class NameServiceImplTest extends CdmTransactionalIntegrationTest {
         final String[] tableNames = new String[]{"USERACCOUNT", "TaxonName","NameRelationship","HybridRelationship","DescriptionBase","NomenclaturalStatus","TaxonBase","SpecimenOrObservationBase","OriginalSourceBase","DescriptionElementBase"};
 //        printDataSetWithNull(System.err, true, null);
 
-        TaxonName<?,?> name1 = TaxonNameFactory.NewBotanicalInstance(getSpeciesRank());
+        TaxonName name1 = TaxonNameFactory.NewBotanicalInstance(getSpeciesRank());
         name1.setTitleCache("Name1", true);
-        TaxonName<?,?> nameWithBasionym = TaxonNameFactory.NewBotanicalInstance(getSpeciesRank());
+        TaxonName nameWithBasionym = TaxonNameFactory.NewBotanicalInstance(getSpeciesRank());
         nameWithBasionym.setTitleCache("nameWithBasionym", true);
 
         NameRelationshipType nameRelType = (NameRelationshipType)termService.find(NameRelationshipType.BASIONYM().getUuid());
@@ -502,7 +502,7 @@ public class NameServiceImplTest extends CdmTransactionalIntegrationTest {
         TaxonName name1 = TaxonNameFactory.NewBotanicalInstance(getSpeciesRank());
         name1.setTitleCache("Name used as type", true);
 
-        TaxonName<?,?> higherName = TaxonNameFactory.NewBotanicalInstance(getGenusRank());
+        TaxonName higherName = TaxonNameFactory.NewBotanicalInstance(getGenusRank());
         higherName.setTitleCache("genus name", true);
         NameTypeDesignationStatus typeStatus = (NameTypeDesignationStatus)termService.find(NameTypeDesignationStatus.AUTOMATIC().getUuid());
         boolean addToAllHomotypicNames = true;
index 50b8ff1901e493c76435fce881ec2507d694713c..98f6adb48f893bd1bc76ffc36796e96d9fdf06c3 100644 (file)
@@ -188,7 +188,7 @@ public class OccurrenceServiceTest extends CdmTransactionalIntegrationTest {
 
     private Taxon getTaxon() {
         Reference sec = getReference();
-        TaxonName<?, ?> name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
+        TaxonName name = TaxonNameFactory.NewBotanicalInstance(Rank.GENUS());
         Taxon taxon = Taxon.NewInstance(name, sec);
         return taxon;
 
index 64f5d6137053c90fe6a79cbc00eabf45039ad781..469ef5c9e8dd983c115b6c9bddaf26ba9fe4cd18 100644 (file)
@@ -293,7 +293,7 @@ public class Datasource {
                CdmApplicationController appCtr = CdmApplicationController.NewInstance(ds);
                Person agent = Person.NewInstance();
                appCtr.getAgentService().save(agent);
-               TaxonName<?,?> tn = TaxonNameFactory.NewBotanicalInstance(null);
+               TaxonName tn = TaxonNameFactory.NewBotanicalInstance(null);
                appCtr.getNameService().save(tn);
                appCtr.close();
 
@@ -313,7 +313,7 @@ public class Datasource {
                CdmApplicationController appCtr = CdmApplicationController.NewInstance(ds);
                Person agent = Person.NewInstance();
                appCtr.getAgentService().save(agent);
-               TaxonName<?,?> tn = TaxonNameFactory.NewBotanicalInstance(null);
+               TaxonName tn = TaxonNameFactory.NewBotanicalInstance(null);
                appCtr.getNameService().save(tn);
                appCtr.close();
 
@@ -429,8 +429,8 @@ public class Datasource {
 //                      CdmPersistentDataSource.NewInstance("localH2");
                CdmApplicationController appCtr = CdmApplicationController.NewInstance(ds, validation);
                try {
-                   TaxonName<?,?> botName1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
-                       TaxonName<?,?> botName2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+                   TaxonName botName1 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
+                       TaxonName botName2 = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                        IBotanicalName hybridName = TaxonNameFactory.NewBotanicalInstance(Rank.SPECIES());
                        botName1.addRelationshipToName(botName2, NameRelationshipType.ORTHOGRAPHIC_VARIANT(), null);
                        UUID uuid1 = botName1.getUuid();