public final class IoUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
readAllToBytes(InputStream in)
Reads the entire
InputStream to EOF and returns the data as bytes. |
static String |
readAllToString(InputStream in)
Reads the entire
InputStream to EOF and returns the data as a string. |
public static byte[] readAllToBytes(InputStream in) throws IOException
InputStream to EOF and returns the data as bytes.in - the stream to read.IOException - in the event the data cannot be read.public static String readAllToString(InputStream in) throws IOException
InputStream to EOF and returns the data as a string.in - the stream to read.IOException - in the event the data cannot be read.