Here you can find the source of concat(IntStream... streams)
public static IntStream concat(IntStream... streams)
//package com.java2s; //License from project: Open Source License import java.util.Arrays; import java.util.stream.DoubleStream; import java.util.stream.IntStream; import java.util.stream.Stream; public class Main { public static IntStream concat(IntStream... streams) { return Arrays.stream(streams).reduce(IntStream::concat).orElse(IntStream.empty()); }//from ww w . ja v a 2 s .c o m public static DoubleStream concat(DoubleStream... streams) { return Arrays.stream(streams).reduce(DoubleStream::concat).orElse(DoubleStream.empty()); } public static <T> Stream<T> concat(Stream<? extends T>... streams) { return (Stream<T>) Arrays.stream(streams).reduce(Stream::concat).orElse(Stream.empty()); } }