|[Xpand] Error "Couldn't find property 'a' for type 'b::c'" when "a" is EDataType [message #662163]
||Tue, 29 March 2011 15:02
| Christoph Wienands
Registered: July 2009
I'm pulling my hair trying to figure out what is going on. We have a number of Xpand templates that operate on a metamodel. This metamodel was imported from an XSD and we can't really change it for compatibility.
In the .xpt files we are seeing a lot of error messages like "Couldn't find property 'a' for type 'b::c'". We found out that this only happens for properties that are of EDataType. Now, all these EDataType have "float" or other simple data types set. The EMF genmodel generator is smart enough to map this to "short" or other simple datatypes without the need for an intermediate class. However, Xpand does not seem smart enough to do that.
Previously with the Galileo version we would see error messages in the editor but the templates still were executed properly. So for that time we simply ignored the errors. However, we recently upgraded to Helios and switched to "org.eclipse.xpand2", and now even the template expansion does not work anymore.
I have done some research and found this bug report: https://bugs.eclipse.org/bugs/show_bug.cgi?id=281269 that seems related even though it is about Xtend.
Unfortunately, I don't understand how the workaround can be implemented, particularly for Xpand templates. All I found when searching for "JavaBeansMetaModel" were statements like "you need to use this" but never how this is done.
Could someone tell me how I can work with attributes of EDataType in Xpand templates, using the "JavaBeansMetaModel" workaround or any other way?
Thanks a lot, Christoph
[Updated on: Tue, 29 March 2011 15:07]
Report message to a moderator
Powered by FUDForum
. Page generated in 0.03506 seconds