I have a variable of type byte[]
, not Byte[]
.
I'm trying to use Arrays::stream
method to process this array with lambda.
However, there's no such reload of Arrays::stream
that takes byte[]
as parameter.
The reload Arrays::stream(T[] data)
also does not work.
I guess it's because byte[] is an array of java prime type byte, which cannot be treated as generic type parameter T
.
I tried to cast byte[]
to Byte[]
or int[]
, which all failed as well.