|
|
Re: commit in EOL [message #1758012 is a reply to message #1758001] |
Wed, 22 March 2017 18:15 |
taghreed altamimi Messages: 184 Registered: October 2014 |
Senior Member |
|
|
Hi Dimitris,
Unfortunately it didn't work
I don't know why,i am adding example1Trace .store() after call addTrace operation .
Below is part of the code
else{//else part when right is not defined
var LeftElementName=getName(UmlIdLeft);
if (isTraceExists(LeftElementName)=false){
var UmlType=getType(UmlIdLeft);
"yssssssssssssss".println();
if (TransferredElements.includes(UmlType)){
if (UmlType<>"ControlFlow"){
"no Trace for this left because no right(old)".println();
var DeviceParent=getDeviceForArtifact(LeftElementName).println();//first we need to add the parent
"DeviceParent".print()+DeviceParent.println();
addChild(Lqn!processor,DeviceParent.name,LeftElementName);//from mapping we are able to know that device is processor and parent for artifact
addTrace(LeftElementName,UmlType,"task");
example1Trace.store();
"pleaseeeeee".print()+isTraceExists(LeftElementName).println();
}else { for (flow in UML!ControlFlow) {
if (flow.name=LeftElementName){
if (guardForControlFlowToPrecedence(flow)=true){
"create new elemet its type = control flow".println();
addSyncall(flow.source,flow.target);
[b] addTrace(LeftElementName,UmlType,"synchcall");
example1Trace.store();[/b]
}else if(controlflowProcessingforSyncCall(flow)=true){
"create new elemet its type = control flow".println();
addSyncall(flow.source,flow.target.name);
addTrace(LeftElementName,UmlType,"synchcall");}else if(controlflowProcessingforASyncCall(flow)="true"){
"create new elemet its type = control flow".println();
addASyncall(flow.source,flow.target);
[b]addTrace(LeftElementName,UmlType,"Asynchcall");
example1Trace.store();[/b]}
}
[Updated on: Wed, 22 March 2017 18:18] Report message to a moderator
|
|
|
|
|
|
|
Re: commit in EOL [message #1758086 is a reply to message #1758049] |
Thu, 23 March 2017 12:00 |
|
Hi Taghreed,
I wasn't able to run your example as-is as a metamodel is missing. When I removed the metamodel-less model from the launch configuration, and set the content of queryETL.eol to "example1Trace.store();" the program ran without errors. I am not sure I understand the nature of the problem you're encountering.
Looking at your last few posts and at the example you shared I would like to encourage you to put additional effort in (1) explaining the precise nature of the problem you are facing and (2) making sure that the examples you share are self-contained and *genuinely* minimal. From my experience most Epsilon-related problems can be demonstrated with one model/metamodel and 4-5 lines of code.
Cheers,
Dimitris
[Updated on: Thu, 23 March 2017 12:02] Report message to a moderator
|
|
|
Re: commit in EOL [message #1758146 is a reply to message #1758086] |
Thu, 23 March 2017 20:49 |
taghreed altamimi Messages: 184 Registered: October 2014 |
Senior Member |
|
|
Hi Dimitris,
I am really sorry for sending incomplete example. I have attached more clear and complete minimal example. This example doesn't generate any errors but it represents different behaviour from what I am expecting.
I am expecting that isTraceExists(ElementName) operation to return true after updating example1Trace model by executing the operation addTrace .
To see this unexpected behaviour please run queryETL(1).lunch file ,you will see that isTraceExists(ElementName) returns false even though addTrace operation updated example1Trace model successfully and I used example1Trace.store();
I hope that I have explained the problem in a more clear way.
Thanks,
Taghreed
[Updated on: Thu, 23 March 2017 21:08] Report message to a moderator
|
|
|
Re: commit in EOL [message #1758346 is a reply to message #1758146] |
Mon, 27 March 2017 20:49 |
|
Hi Taghreed,
Looking at your attached archive, it contains an Eclipse project ("lqnmodel") and then two sibling folders ("evolving Source Model" and "TraceabilityExample"). I'm not sure what I need to do with these folders (do I need to import them as separate projects? copy them into the attached project?). Also, I can see an ETL transformation in the archive ("TraceabilityFeb3.etl"). Do I need to run it? If not, then it shouldn't be part of the archive. I'm sorry if I'm being pedantic but I'd appreciate it if you could have another go at this and attach one Eclipse project that contains *only* the files I need to reproduce the problem you're encountering.
Cheers,
Dimitris
|
|
|
Re: commit in EOL [message #1758351 is a reply to message #1758346] |
Tue, 28 March 2017 02:03 |
taghreed altamimi Messages: 184 Registered: October 2014 |
Senior Member |
|
|
Hi Dimitris,
I do really apologize for the inconvenience i made:( i do not know what is going with me .I have attached two folders (i exported them from eclipse as it is).
TraceabilityExamples folder has:
metamodels which has Lqn2umlTarce metamodel
Evolving Source Model folder has:
Example1Trace.ecore a model an instance of Lqn2umlTarce metamodel
queryETL(1).launch
queryETL.eol
To reproduce the problem :
1-run queryETL(1).launch
2- isTraceExists(ElementName) will return false even though addTrace operation updated example1Trace model successfully and I used example1Trace.store();
I hope this time my example is complete and sorry again for the inconvenience .
Cheers,
Taghreed
[Updated on: Tue, 28 March 2017 02:04] Report message to a moderator
|
|
|
Re: commit in EOL [message #1758362 is a reply to message #1758351] |
Tue, 28 March 2017 06:40 |
|
Hi Taghreed,
In line 14, you should replace
with
for(s in example1Trace!t_links.all) {
In the future, it'd be great if you could attach exported Eclipse projects which can imported directly into a new workspace as opposed to plain folders. Moreover, the TraceabilityExample folder doesn't seem to be necessary for this example (and thus should have been omitted). Finally, you appear to be querying and modifying an XMI model using the plain XML driver. Is there any particular reason why you're not treating it as a regular EMF model?
Cheers,
Dimitris
|
|
|
|
Powered by
FUDForum. Page generated in 0.04929 seconds