public class IOUtil extends Object
| 限定符和类型 | 字段和说明 |
|---|---|
static int |
BUFFER_SIZE
IO缓冲区大小
|
| 构造器和说明 |
|---|
IOUtil() |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
closeQuietly(Closeable closeable)
安静的关闭
|
static void |
closeQuietly(Connection connection) |
static void |
closeQuietly(ResultSet rs) |
static void |
closeQuietly(Socket socket) |
static void |
closeQuietly(Statement stmt) |
static void |
closeQuietly(ZipFile zip) |
static byte[] |
toBytes(InputStream in)
输入流转字节数组
|
static void |
writeFile(File file,
byte[] data,
boolean append) |
public static void writeFile(File file, byte[] data, boolean append) throws IOException
IOExceptionpublic static byte[] toBytes(InputStream in) throws IOException
in - 输入流IOException - IOExceptionpublic static void closeQuietly(Closeable closeable)
closeable - Closeablepublic static void closeQuietly(ZipFile zip)
public static void closeQuietly(Socket socket)
public static void closeQuietly(Connection connection)
public static void closeQuietly(ResultSet rs)
public static void closeQuietly(Statement stmt)
Copyright © 2023. All Rights Reserved.