Xtend - access the EnumLiterals - not possible [message #947495] |
Wed, 17 October 2012 06:15 |
|
Hello all,
I have this following issue into one file.ext that I created to generate some code out of the ecore.
String getString(Type type):
switch (type) {
case Type::Running : "Running_type"
case Type::Waiting : "Waiting_type"
default : "default"
};
Type is an Enum in my ecore and has the EnumLiterals Running and Waiting. I receive the error in the editor : Callable not found:Unknown variable, type or enumeration literal
'Type::Running'.
I have added also the check for the JavaBeansMetamodel to have it activated.
When I access this getString from the Xpand, it always takes the default case, meaning the evaluation was not done for Running or Waiting.
Maybe someone has a clue what else should I do or what should I change in the above syntax.
I add also that I don't want the getType to have it used, because I want to customize the text that I generate.
[Updated on: Wed, 17 October 2012 06:34] Report message to a moderator
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03288 seconds