Can Golang enum do same behavior like Java's enum?
<p>Java's enums have usefull method 'valueOf(string)' what return const enum member by it name.
Ex.</p>

<pre><code>enum ROLE {
  FIRST("First role"),
  SECOND("Second role")

  private final String label;

  private ROLE(label String) {
    this.label = label;
  }

  public String getLabel() {
    return label;
  }
}
// in other place of code we can do:
ROLE.valueOf("FIRST").getLabel(); // get's "First role"
</code></pre>

<p>This behavior usefull for, for example, after html form's select submits to server. We have string representation what need to convert into real enum.</p>

<p>Can someone tell, can golang do same behavior? Code examples are welcome.</p>