@Override
  public String toString() {
    if (!hasRequiredRoles()) {
      return "RequiredRoles(none)";
    } else {
      final StringBuilder sb = new StringBuilder();
      sb.append("RequiredRoles(");
      boolean comma = false;
      for (final Role requiredRole : requiredRoles) {
        if (comma) {
          sb.append(",");
        }
        Role role = requiredRole;
        sb.append(role.getName());
        comma = true;
      }
      sb.append("); Policy:");
      sb.append(lossAction.toString());
      sb.append("; Action:");
      sb.append(resumptionAction.toString());
      return sb.toString();
    }
  }
Returns a string representation of the object.

@return a string representation of the object
geode-core/src/main/java/org/apache/geode/cache/MembershipAttributes.java