}
return null;
}
protected JavaElement ensureJavaElement(String name, Collection javaElements, EClass eClass) {
JavaElement javaElement = findJavaElement(name, javaElements, eClass);
if (javaElement == null) {
javaElement = (JavaElement) JexFactory.eINSTANCE.create(eClass);
EStructuralFeature nameFeature = eClass.getEStructuralFeature("name");
if (nameFeature != null) {
javaElement.eSet(nameFeature, name);
}
javaElements.add(javaElement);
}
return javaElement;
}