gradle-josm-plugin / org.openstreetmap.josm.gradle.plugin.i18n.io / java.io.InputStream / readAllOrException

readAllOrException

fun InputStream.readAllOrException(b: ByteArray): Int

Read bytes from the input stream into the array. If there are not enough bytes to fill the array, an exception is thrown.

Exceptions

IOException - if reading from the InputStream fails (see InputStream.read) or if the number of bytes that can be read is lower than the length of the parameter b.