code: protected List<String> getAllUsersWithTrash() throws IOException {
      Path trashLocationGlob = new Path(this.properties.getProperty(TRASH_LOCATION_KEY).replaceAll("\\$USER", "*"));
      Pattern userPattern =
          Pattern.compile(this.properties.getProperty(TRASH_LOCATION_KEY).replaceAll("\\$USER", "([^/])"));
  
      List<String> users = Lists.newArrayList();
      for (FileStatus fileStatus : this.fs.globStatus(trashLocationGlob)) {
        Matcher matcher = userPattern.matcher(fileStatus.getPath().toString());
        if (matcher.find()) {
          users.add(matcher.group(1));
        }
      }
  
      return users;
    }
docs: Find all users with trash directories by listing all directories in
  the file system matching the trash pattern given by {@link #TRASH_LOCATION_KEY}.
  @return List of users with trash directory.
  @throws IOException