Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » manipulate textual model
manipulate textual model [message #631246] Wed, 06 October 2010 16:28 Go to next message
chuck  is currently offline chuck Friend
Messages: 160
Registered: July 2010
Senior Member
when i define an element in grammar like this:

container: "container{"
elements+=el*
"}";

el: "element" name=ID opposite=[el];

is possible to generate automatically the opposite element without typing the other element?

i mean...in model i will have:

container{

element el1 opposite el2

element el2 opposite el1

....i would set the opposite automatically or if the opposite not exist to create it,,,
=====================
another problem i have:

is possible to set the opposite for example without show it? i mean without showing the opposite text in model?

thx !!
Re: manipulate textual model [message #631626 is a reply to message #631246] Fri, 08 October 2010 08:59 Go to previous message
Jan Koehnlein is currently offline Jan KoehnleinFriend
Messages: 760
Registered: July 2009
Location: Hamburg
Senior Member
1) I'd rather use a quickfix than automatically adding the other side.
Feels more Eclipse-like and less magical. See docs on quickfixes for
details.

2) As we consider the textual format the primary persistence format, all
information about the model has to be in there or to be automatically
derivable. So I guess the answer is no.

Am 06.10.10 18:28, schrieb chuck:
> when i define an element in grammar like this:
>
> container: "container{"
> elements+=el*
> "}";
>
> el: "element" name=ID opposite=[el];
>
> is possible to generate automatically the opposite element without
> typing the other element?
>
> i mean...in model i will have:
>
> container{
>
> element el1 opposite el2
>
> element el2 opposite el1
> ...i would set the opposite automatically or if the opposite not exist
> to create it,,,
> =====================
> another problem i have:
>
> is possible to set the opposite for example without show it? i mean
> without showing the opposite text in model?
>
> thx !!


--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com


---
Get professional support from the Xtext committers at www.typefox.io
Previous Topic:Providing content/input assist via a table editor?
Next Topic:Scoping: merge elements in logical groups
Goto Forum:
  


Current Time: Thu Sep 26 10:55:31 GMT 2024

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

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

Back to the top