code: @NotNull
      public static <T, R extends Collection<T>> Collector<T, ?, R> toCollection(
              @NotNull Supplier<R> collectionSupplier) {
          return new CollectorsImpl<T, R, R>(
  
                  collectionSupplier,
  
                  new BiConsumer<R, T>() {
                      @Override
                      public void accept(@NotNull R t, T u) {
                          t.add(u);
                      }
                  }
          );
      }
docs: Returns a {@code Collector} that fills new {@code Collection}, provided by {@code collectionSupplier},
  with input elements.
  
  @param <T> the type of the input elements
  @param <R> the type of the resulting collection
  @param collectionSupplier  a supplier function that provides new collection
  @return a {@code Collector}