Hello Kina,
        
        Am 23.06.2017 um 12:06 schrieb
          Bojarczuk, Kinga:
        
        
          
          
            Hello,
            
            
            I'm working on this project on e-motions files so
              basically there's a .behavior file which is linked to .gcs
              which is linked to .ecore file and together they represent
              a graph transformation system. So what I'm trying to do is
              to delete EReference from .ecore file between the object
              that has some subclasses and another object. (First rule
              in my henshin file) This should find a match as it exists
              in a server2.ecore file however for some reason it
              doesn't.
           
        
        To understand why the rule cannot be applied, it's crucial to
        know that Henshin aims to ensure that output models of a
        transformation are well-formed: in particular, it aims to ensure
        that rule applications never leave behind "dangling edges". In
        your example rule, since you do not specify the deletion of the
        containment edge between the :EPackage and the :EReference, this
        edge would be left behind as dangling, so Henshin won't apply
        the rule.
        
        To make the rule applicable, it should be sufficient to specify
        the deletion of the aforementioned containment edge. (Another
        option is to the set the "checkDangling" attribute in the rule
        to "false", however, in this case, you may lose well-formedness
        guarantees.)
        
        
        
          
            When I run the code straight on the server2.ecore (by
              starting with EPackage in my rule) file or server2.gcs (by
              starting with MetamodelGD in my rule) file it works and
              finds a match but when running on server3.behavior file
              something suddenly prevents it from finding a match which
              is really weird as .behavior file just provides a
              reference to the other files so since it works when run
              straight on them it should work on the the behavior file
              as well.
              
            
           
        
        I can't find the code you mention in these statements. The zip
        file only contains the models and Henshin files.
        
        
        Best regards,
        Daniel
        
        
          
            The Second rule shows the solution that we thought might
              work as Links in .behavior file are linked to EReferences
              so we thought this might prevent deleting EReferences but
              it doesn't work either.
              
            
            The Third rule shows something that works but is a rather
              'unclean solution' as it only deletes all the edges and
              doesn't actually delete the node.
            So any idea why running my rule on .behavior file
              suddenly prevents it from finding a match? It seems really
              weird so I'd appreciate some help. I've included a zip
              file with my project.
            
            
            Thank you,
            Kinga
            
           
          
          
          
          _______________________________________________
henshin-user mailing list
henshin-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/henshin-user