This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-io.git
commit 5444ad3de9d01d8a7f6999472f9b973ebba02acf Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Tue Jan 11 08:52:31 2022 -0500 Sort members. --- .../org/apache/commons/io/function/IOStreams.java | 28 +++++++++++----------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/main/java/org/apache/commons/io/function/IOStreams.java b/src/main/java/org/apache/commons/io/function/IOStreams.java index 7437ec3..74581c0 100644 --- a/src/main/java/org/apache/commons/io/function/IOStreams.java +++ b/src/main/java/org/apache/commons/io/function/IOStreams.java @@ -32,20 +32,6 @@ import org.apache.commons.io.IOExceptionList; */ class IOStreams { - /** - * Null-safe version of {@link Stream#of(Object[])}. - * - * Copied from Apache Commons Lang. - * - * @param <T> the type of stream elements. - * @param values the elements of the new stream, may be {@code null}. - * @return the new stream on {@code values} or {@link Stream#empty()}. - */ - @SafeVarargs // Creating a stream from an array is safe - static <T> Stream<T> of(final T... values) { - return values == null ? Stream.empty() : Stream.of(values); - } - static <T> void forEach(final Stream<T> stream, final IOConsumer<T> action) throws IOException { forEachIndexed(stream, action, (i, e) -> e); } @@ -68,4 +54,18 @@ class IOStreams { IOExceptionList.checkEmpty(causeList.get(), null); } + /** + * Null-safe version of {@link Stream#of(Object[])}. + * + * Copied from Apache Commons Lang. + * + * @param <T> the type of stream elements. + * @param values the elements of the new stream, may be {@code null}. + * @return the new stream on {@code values} or {@link Stream#empty()}. + */ + @SafeVarargs // Creating a stream from an array is safe + static <T> Stream<T> of(final T... values) { + return values == null ? Stream.empty() : Stream.of(values); + } + }