Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » IJvmModelInferrer and Generation of Java files outside of Eclipse model project
IJvmModelInferrer and Generation of Java files outside of Eclipse model project [message #893990] Fri, 06 July 2012 10:55 Go to next message
Maxim Frolov is currently offline Maxim FrolovFriend
Messages: 4
Registered: January 2012
Location: Aachen, Germany
Junior Member
My language is based on Xbase grammar and is similar to the Xtext domainmodel example.
I use an IJvmModelInferrer to generate two kinds of Java classes from the model:
* Java interface classes for entities
* and classes implementing these interfaces

Alle generated files are written by EclipseResourceFileSystemAccess2 to src-gen folder in the same Eclipse project (the project with the model file).

Is it possible to generate files to different Eclipse projects or even to a pre-configured file system locations outside of Eclipse workspace?

The following project structure is desired:


  • model-project/src/model.dsl
  • api-project/src-gen/x/y/z/Entity.java
  • impl-project/src-gen/x/y/z/EntityImpl.java

[Updated on: Fri, 06 July 2012 10:57]

Report message to a moderator

Re: Jvm [message #894015 is a reply to message #893990] Fri, 06 July 2012 12:04 Go to previous message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14669
Registered: July 2009
Senior Member
hi you would have to customize JvmModelGenerator to use different outlets + a custom IOutputConfigurationProvider to provide these different outlets

~Christian
--
Need training, onsite consulting or any other kind of help for Xtext?
Go visit http://xtext.itemis.com or send a mail to xtext@itemis.de


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de

[Updated on: Fri, 06 July 2012 12:49]

Report message to a moderator

Previous Topic:Reference to external project
Next Topic:XMLBeautifier uses wrong line separator
Goto Forum:
  


Current Time: Sat Apr 27 01:01:08 GMT 2024

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

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

Back to the top