Java awt converting a string to color in java

h‮‬ttps://www.lautturi.com
Java awt converting a string to color in java
Color color;
try {
    Field field = Class.forName("java.awt.Color").getField("yellow");
    color = (Color)field.get(null);
} catch (Exception e) {
    color = null; // Not defined
}
Created Time:2017-09-23 23:06:05  Author:lautturi