Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Create simple standalone application with generator
Create simple standalone application with generator [message #884000] Sat, 09 June 2012 21:47 Go to next message
egger is currently offline eggerFriend
Messages: 13
Registered: November 2011
Junior Member
Good evening everyone Smile

I'm currently trying to get a standalone application, which uses my parser and generator to generate a file, working. I would like to have a simple application.jar file, which expects the language file as the first argument.

i found different solutions on the internet but none worked with my project setup (xtext 2.2.1 and xtend 2.2.1).

maybe someone can give me a hint, how to read the file, parse it and fire the generator maybe out of an java application?

best regards,
egger
Re: Create simple standalone application with generator [message #884137 is a reply to message #884000] Sun, 10 June 2012 07:46 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14665
Registered: July 2009
Senior Member
Hi,

where is the problem?
(1) create new Xtext project
(2) change workflow to
 fragment = generator.GeneratorFragment {
                generateMwe = false
                generateJavaMain = true
            }

(3) Generate Language
(4) Implement Generator
(5) Run the org.xtext.example.mydsl.generator.Main once
(6) use the Export -> Java -> Runnable Jar File Wizard

~Christian


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: Create simple standalone application with generator [message #884499 is a reply to message #884137] Mon, 11 June 2012 07:44 Go to previous message
egger is currently offline eggerFriend
Messages: 13
Registered: November 2011
Junior Member
hello christian,

thanks for your help. perfect and compact solution Smile

i didn't know these steps. i tried a solution with a wrapper class and so on ...

best regards,
norbert
Previous Topic:Attribute of type XMLGregorianCalendar
Next Topic:Xtend 2.3 may has a bug for generic type support
Goto Forum:
  


Current Time: Fri Apr 19 23:20:00 GMT 2024

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

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

Back to the top