I am trying to store the Color values in Java Array but I know that these values are stored as strings,
String[] colorarray = {"Color.yellow","Color.red","Color.blue"};
Now, I couldn't access this array element to set the color, i.e
g.setColor(colorarray[0]);
Because all the values in the array are strings. How could I convert these values to the constants ?