Can I somehow use a text file with contents like this:
<comment> This is something like an XML file.
<action var="myInteger"> +50
<condition> stringVar == "sometext" <action var="boolVar"> = true
.. parse it and make my app perform some actions?
The idea is to make a user-friendly (example doesn't count) pseudocode that can change app's variables and run methods. Problem is I don't know how to change variables by their names.
Making a separate case for each variable name (explicitly supporting them) would be rather crazy:
switch(varName)
{
case "var1": {/* things */ break;}
case "var2": {/* things */ break;}
/* ... */
case "var9999": {/* things */ break;}
}
Edit: I think I asked the wrong question originally. (And it was Is there an easy way to work with application's variables by executing code from text file?)