static <T> void collectByPrefix(@NotNull NavigableMap<String, T> paths,
                                  @NotNull String prefix,
                                  @NotNull Consumer<? super Map.Entry<String, T>> collector) {
    for (Map.Entry<String, T> entry : paths.tailMap(prefix, false).entrySet()) {
      if (OSAgnosticPathUtil.startsWith(entry.getKey(), prefix)) {
        collector.accept(entry);
      }
      else {
        break;
      }
    }
  }
static <T> void collectByPrefix(@NotNull NavigableMap<String, T> paths,
                                  @NotNull String prefix,
                                  @NotNull Consumer<? super Map.Entry<String, T>> collector)