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

readTwoBytesAsInt

fun InputStream.readTwoBytesAsInt(): Int

Read the next two bytes from the InputStream, interpret them as a big-endian number (first byte most significant). This number is then returned.

Exceptions

IOException - if only one byte can be read from the InputStream

Return
-1 if no bytes can be read, otherwise the number that