Exemplo n.º 1
0
 private boolean removeAnnotation(EOperation existingOperation) {
   List<EAnnotation> annotations = existingOperation.getEAnnotations();
   EAnnotation annotationToRemove = null;
   for (EAnnotation annotation : annotations) {
     if (annotation.getSource().equals(EcoreModelRefactorer.class.getName())) {
       annotationToRemove = annotation;
     }
   }
   if (annotationToRemove != null) {
     return annotations.remove(annotationToRemove);
   }
   return false;
 }
Exemplo n.º 2
0
 private void annotateAsGenerated(EOperation newEOperation) {
   EAnnotation eAnnotation = EcoreFactory.eINSTANCE.createEAnnotation();
   eAnnotation.setSource(EcoreModelRefactorer.class.getName());
   newEOperation.getEAnnotations().add(eAnnotation);
 }