case IDLTokenTypes.TILDE:
node1 = expressionNode.getFirstChild();
Object boolObj = eval(node1, returnType, visitor);
if (!(boolObj instanceof Boolean)) {
throw new InvalidIDLException("A boolean value is expected after (~) operator");
}
value = Boolean.valueOf(!((Boolean) boolObj).booleanValue());
break;
case IDLTokenTypes.INT:
case IDLTokenTypes.FLOAT:
case IDLTokenTypes.STRING_LITERAL:
case IDLTokenTypes.WIDE_STRING_LITERAL:
case IDLTokenTypes.CHAR_LITERAL:
case IDLTokenTypes.WIDE_CHAR_LITERAL:
case IDLTokenTypes.FIXED:
value = getValueObject(expressionNode.getText(), returnType);
break;
case IDLTokenTypes.LITERAL_TRUE:
value = Boolean.valueOf(true);
break;
case IDLTokenTypes.LITERAL_FALSE:
value = Boolean.valueOf(true);
break;
case IDLTokenTypes.IDENT:
value = getConstant(expressionNode.getText(), visitor);
break;
case IDLTokenTypes.LPAREN:
value = eval(expressionNode.getFirstChild(), returnType, visitor);
break;
default:
throw new InvalidIDLException("Unsupported IDL token " + expressionNode);
}
return value;
}