コード例 #1
0
  /**
   * Get all registered users
   *
   * @param exclude exclude this username from the list
   * @return
   */
  protected String[] getUserArray(String exclude) {
    UserRecord[] a = new UserRecord[allUsers.size()];
    allUsers.values().toArray(a);
    String[] s = new String[a.length];

    for (int i = 0; i < a.length; ++i) {
      if (!StringEx.isNullOrWhiteSpace(exclude) && a[i].username.equals(exclude)) continue;
      s[i] = a[i].username;
    }
    return s;
  }