Closed reteprelief closed 11 years ago
Hi Dominique,
If you need to modify the model in a transaction, you can do it using an EMF transaction or a ligherweight Xtext transaction (http://koehnlein.blogspot.com/2010/06/semantic-model-access-in-xtext.html). We use it when instantiating a model (InstantiateHandler).
The subprogram call reference is tricky because it can be a reference to a Subprogram type (qualified name), subprogram implementation (qualified subprogram type
In your code below we could probably leave out the setContext(null); since the value is already null.
However, in the subcomponent
Alternatively, I could have the parser fill in both when there is a
Peter
Hi all,
It appears to be related to the bug I got previously with Eclipse hanging while instantiating models. Dominique, could you tell us what the bug looks like and what are the effects of the bug ? Anyway, we should have a look at it and make OSATE resilient to all kind of bugs, so, let's look at how we can fix that issue !
From Dominique:
I am having some errors (cannot modify without a transaction) with our tools and OSATE. The error hapens when our tools read AADL models, even though they are not modifying the models at all. This seems to be due to the following line of code (line 305, in bold font) in the Aadl2LinkingService class, which is setting the context of subprogram calls to null.
Is this line really needed? If so, I will need to modify the code in my tools to manage a transaction which may be tedious.