@SafeVarargs public static <T>T[] join(IntFunction<T[]> arrayFunction,T[] arrayA,T... arrayB){
  if ((arrayB == null) || (arrayB.length == 0)) {
    return arrayA;
  }
  if ((arrayA == null) || (arrayA.length == 0)) {
    return arrayB;
  }
  T[] array=arrayFunction.apply(arrayA.length + arrayB.length);
  System.arraycopy(arrayA,0,array,0,arrayA.length);
  System.arraycopy(arrayB,0,array,arrayA.length,arrayB.length);
  return array;
}

@ SafeVarargs public static < T > T [ ] join ( IntFunction < T [ ] > arrayFunction , T [ ] arrayA , T ... arrayB ) { if ( ( arrayB == null ) || ( arrayB . length == 0 ) ) { return arrayA ; } if ( ( arrayA == null ) || ( arrayA . length == 0 ) ) { return arrayB ; } T [ ] array = arrayFunction . apply ( arrayA . length + arrayB . length ) ; System . arraycopy ( arrayA , 0 , array , 0 , arrayA . length ) ; System . arraycopy ( arrayB , 0 , array , arrayA . length , arrayB . length ) ; return array ; }
joins 2 arrays together , if any array is null or empty then other array will be retuned without coping anything .
