Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » EGL: Sending the generated text to an output file
EGL: Sending the generated text to an output file [message #1720069] Thu, 14 January 2016 08:55 Go to next message
Alireza Rouhi is currently offline Alireza RouhiFriend
Messages: 148
Registered: December 2015
Senior Member
Hi,

I have a problem with the generation of an output file from the EGL generated text.
When I choose the console as the target of the text generation, everything is go well. But, I want to store the generated text in an output file. So, when I choose a file named foo.txt, for example, in the launch configuration, the following message is displayed and there is nothing in my specified file as the output target!

Output generated to /.../foo.txt
Content unchanged for ...:/.../foo.txt


Have you experienced such a situation?

And one more thing,
If I had a common text which must be copied to more than one output file from an EGL text generation, how can I configure and code this situation?
I mean, how to write a code similar to the following in EGL?
if (Case 1 is satisfied) {
		// generated text in Case 1
		// output the text to the file1.txt
	}
	
if (Case 2 is satisfied) {
		// generated text in Case 2
		// output the text to the file2.txt
	}
	
	.
	.
	.
if (Case m is satisfied) {
		// generated text in Case m
		// output the text to the file1.txt
	}
	
if (Case n is satisfied) {
		// generated text in Case n
		// output the text to the file2.txt
	}
.
.
.


Best regards,
Alireza

[Updated on: Thu, 14 January 2016 09:32]

Report message to a moderator

Re: EGL: Sending the generated text to an output file [message #1720076 is a reply to message #1720069] Thu, 14 January 2016 09:32 Go to previous messageGo to next message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 2163
Registered: July 2009
Location: York, UK
Senior Member

Hi Alireza,

Regarding your first question, could you please provide a minimal example [1] that we can use to reproduce this?

To conditionally redirect the output of EGL templates to different files I'd suggest using EGX [2].

Cheers,
Dimitris

[1] https://www.eclipse.org/epsilon/doc/articles/minimal-examples/
[2] http://www.eclipse.org/epsilon/doc/articles/code-generation-tutorial-egl/
Re: EGL: Sending the generated text to an output file [message #1720081 is a reply to message #1720076] Thu, 14 January 2016 10:07 Go to previous messageGo to next message
Alireza Rouhi is currently offline Alireza RouhiFriend
Messages: 148
Registered: December 2015
Senior Member
Hi Dimitris,

Thanks a lot for your quick reply.
I have attached the minExample. Of course, I must mention that I have not this problem previously at all.

Kind regards,
Alireza


Re: EGL: Sending the generated text to an output file [message #1720113 is a reply to message #1720081] Thu, 14 January 2016 14:02 Go to previous messageGo to next message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 2163
Registered: July 2009
Location: York, UK
Senior Member

Hi Alireza,

Does updating to the latest interim version of Epsilon help?

Cheers,
Dimitris
Re: EGL: Sending the generated text to an output file [message #1720122 is a reply to message #1720113] Thu, 14 January 2016 14:59 Go to previous message
Alireza Rouhi is currently offline Alireza RouhiFriend
Messages: 148
Registered: December 2015
Senior Member
Dear Dimitris,

Hi,

Great. Thank you very much.
As you said, updating to the Epsilon interim release resolved my problem.

Best regards,
Alireza
Previous Topic:EGL: Setting-up an ecore model features
Next Topic:EGL: How to import an egl file
Goto Forum:
  


Current Time: Thu Apr 25 09:00:14 GMT 2024

Powered by FUDForum. Page generated in 0.03169 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top