public class IOUtils extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
closeQuietly(InputStream in) |
static void |
closeQuietly(OutputStream out) |
static void |
closeQuietly(Reader reader) |
static void |
closeQuietly(Writer writer) |
static long |
copyLarge(Reader input,
Writer output)
Copy chars from a large (over 2GB)
Reader to a
Writer. |
static byte[] |
readBytes(InputStream input) |
static String |
toString(InputStream in) |
static String |
toString(InputStream in,
String encoding) |
public static String toString(InputStream in)
public static String toString(InputStream in, String encoding)
public static void closeQuietly(Reader reader)
public static void closeQuietly(Writer writer)
public static void closeQuietly(InputStream in)
public static void closeQuietly(OutputStream out)
public static long copyLarge(Reader input, Writer output) throws IOException
Reader to a
Writer.
This method buffers the input internally, so there is no need to use a
BufferedReader.
input - the Reader to read fromoutput - the Writer to write toNullPointerException - if the input or output is nullIOException - if an I/O error occurspublic static byte[] readBytes(InputStream input)
Copyright © 2018. All rights reserved.