Searched refs:inputStreamSize (Results 1 – 1 of 1) sorted by relevance
39 …public static byte[] toByteArray(InputStream inputStream, int inputStreamSize) throws IOException { in toByteArray() argument40 if (inputStreamSize == 0) { in toByteArray()43 if (inputStreamSize < 0) { in toByteArray()44 … throw new IllegalArgumentException("inputStreamSize: " + inputStreamSize + "is less than zero: "); in toByteArray()47 copy(inputStream, inputStreamSize, output); in toByteArray()51 …private static int copy(InputStream inputStream, int inputStreamSize, OutputStream output) throws … in copy() argument55 while (readSize < inputStreamSize && (readSize = inputStream.read(buffer)) != -1) { in copy()59 if (count != inputStreamSize) { in copy()60 …ew IOException("read size err. readSizeCount: " + count + ", inputStreamSize: " + inputStreamSize); in copy()