Java object reference from string
Posted on 2006-07-17
In some languages you can use a string as an object reference.
For example, in ActionScript:
var foo = "bar";
_global[foo] = "baz";
Is the same as saying
_global.bar = "baz";
Is this possible in Java, and if so what's the syntax?