| [Xpand] expand in a dynamic binding manner [message #643538] |
Tue, 07 December 2010 05:23  |
Stefan Jurack Messages: 24 Registered: February 2010 |
Junior Member |
|
|
Hi again,
is there a way to specify an EXPAND and let it related to different DEFINE sections due to dynamic binding? Consider the following grammar rule:
WebPage: 'page' name=ID '{' contents+=AbstractContent* '}';
AbstractContent: (Chapter | Image | Paragraph); ...etc.
I would like to do simething like:
«EXPAND content FOREACH this.contents»
«DEFINE content FOR Chapter» ... «ENDDEFINE»
«DEFINE content FOR Image» ... «ENDDEFINE»
«DEFINE content FOR Paragraph» ... «ENDDEFINE»
An alternative but quite ugly way is to check "this.eClass().name" on a content entry and to redirect to a certain DEFINE.
Thanks in advance,
Stefan
|
|
|
|
Powered by
FUDForum. Page generated in 0.02223 seconds