Revision e0f895eb
Added by Patrick Plitzner almost 6 years ago
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/workingSet/matrix/CharacterMatrix.java | ||
---|---|---|
949 | 949 |
MessagingUtils.error(CharacterMatrix.class, e); |
950 | 950 |
} |
951 | 951 |
} |
952 |
|
|
953 |
//add all remaining description elements to the new description |
|
954 |
for(Feature wsFeature:wsFeatures){ |
|
955 |
boolean featureFound = false; |
|
956 |
for(DescriptionElementBase element:newDesription.getElements()){ |
|
957 |
if(element.getFeature().equals(wsFeature)){ |
|
958 |
featureFound = true; |
|
959 |
break; |
|
960 |
} |
|
961 |
} |
|
962 |
if(!featureFound){ |
|
963 |
if(wsFeature.isSupportsCategoricalData()){ |
|
964 |
newDesription.addElement(CategoricalData.NewInstance(wsFeature)); |
|
965 |
} |
|
966 |
else if(wsFeature.isSupportsQuantitativeData()){ |
|
967 |
newDesription.addElement(QuantitativeData.NewInstance(wsFeature)); |
|
968 |
} |
|
969 |
} |
|
970 |
} |
|
952 | 971 |
return newDesription; |
953 | 972 |
|
954 | 973 |
} |
Also available in: Unified diff
ref #7095 Add empty desc elements when adding a new specimen