private static Function<? super AnAction, String> createProjectNameFunction() {
    return o -> {
      if (o instanceof ReopenProjectAction) {
        return getProjectName((ReopenProjectAction)o);
      }
      else if (o instanceof ProjectGroupActionGroup) {
        return ((ProjectGroupActionGroup)o).getGroup().getName();
      }
      return o.toString();
    };
  }
private static Function<? super AnAction, String> createProjectNameFunction()