Skip to content
Snippets Groups Projects
Commit 56040c40 authored by Sabine Teufl's avatar Sabine Teufl
Browse files

- Avoid NPE in getEStructuralFeature()

refs 2240
parent e279dcc6
No related branches found
No related tags found
No related merge requests found
......@@ -39,7 +39,7 @@ import org.fortiss.tooling.base.model.element.IModelElement;
* @author barner
* @author $Author$
* @version $Rev$
* @ConQAT.Rating YELLOW Hash: 0B98B87CEB9B2AC5940668F4DD147710
* @ConQAT.Rating YELLOW Hash: 484315167A409237789D478428543CAF
*/
public abstract class EStructuralFeatureValueProviderBase<T extends IAnnotatedSpecification>
extends ValueProviderBase<T> {
......@@ -169,8 +169,10 @@ public abstract class EStructuralFeatureValueProviderBase<T extends IAnnotatedSp
throws Exception {
EStructuralFeatureDescriptor eStructuralFeatureDescriptor =
structuralFeatureDescriptorMap.get(instanceKey);
EStructuralFeature structuralFeature =
eStructuralFeatureDescriptor.getEStructuralFeature(specification);
EStructuralFeature structuralFeature = null;
if(eStructuralFeatureDescriptor != null) {
structuralFeature = eStructuralFeatureDescriptor.getEStructuralFeature(specification);
}
if(structuralFeature == null) {
throw new Exception("Instance key " + instanceKey +
" is unknown for annotation provider " +
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment