public static Role valueOf(String name) {
    if (roles.containsKey(name)) {
      return roles.get(name);
    }

    Role role = new Role(name);
    roles.put(name, role);
    return role;
  }
@param name the role name
@return a Role instance, never <code>null</code>
ambari-server/src/main/java/org/apache/ambari/server/Role.java