Beispiel #1
0
 /**
  * Convenient implementation of the {@link #getLinkElements(InternalProject, EObject, EReference)}
  * method to use the {@link ItemPropertyDescriptor} to get all object of an object.
  *
  * @param project the project the call is from
  * @param modelElement {@link EObject} to add the {@link EReference} to
  * @param eReference the {@link EReference} to add
  * @return {@link Iterator} of {@link EObject} that can be linked
  */
 @Override
 public Iterator<EObject> getLinkElements(
     InternalProject project, EObject modelElement, EReference eReference) {
   final EClass elementClass = modelElement.eClass();
   EClassifier type =
       EcoreUtil.getReifiedType(elementClass, eReference.getEGenericType()).getEClassifier();
   if (type == null) {
     type = eReference.getEType();
   }
   return ItemPropertyDescriptor.getReachableObjectsOfType(modelElement, type).iterator();
 }