Echtzeitsysteme / java-refactoring-ttc

Object-oriented Refactoring of Java Programs using Graph Transformation (TTC'2015)
0 stars 0 forks source link

Java-to-PG: may I omit stuff that I don't need? #32

Closed tsdh closed 9 years ago

tsdh commented 9 years ago

Basically, I ask the question of #2 again, i.e., do I need to instantiate all PG classes and set all available references? E.g., the overridden/hidden/overloaded references are just derived information you can just query on the PG. Packages are also derived information when you use qualified names which I do.

In #2 you told me "Of course the dynamic calculation of these references is also possible. However, we decided to calculate them once at the creation of the program graph.". Does that mean that you decided that all solution devs must do it that way, or just that you do it that way in your own solution?

Basically, my step-1 jamopp-to-pg transformation currently does almost all that stuff, and now I noticed that I actually don't use TPackages and overrides/hidden/overloaded references in the refactorings at all but just query the PG dynamically. So I'd very much like to delete the rules creating/setting them in my step-1 transformation which would significantly reduce its size and complexity.

Is that ok or would that make my step-1 jamopp-to-pg transformation incomplete wrt evaluation?

gkulcsar commented 9 years ago

Yes, you can totally omit the static references you don't need. The meaning of the sentence above should have been: "You as a developer calculate and persist your things as you want, still, we decided to present a meta-model which provides a way to store the references statically." Basically, as stated elsewhere, it's about the transformation itself which has to have its means not to lose any crucial program parts.

tsdh commented 9 years ago

Ok, cool.