public final class IOUtils extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
close(Closeable closeable)
Close InputStream, OutputStream, Reader, Writer, etc.
|
static void |
generateFile(byte[] bfile,
String filePath,
String fileName)
Description: 根据byte数组,生成文件
|
static byte[] |
getBytes(String filePath)
Description: 获得指定文件的byte数组
|
static String |
getResourcesString(Class clazz,
String filePath)
Description: 获得项目下指定文件的字符串
|
static String |
getString(String filePath)
Description: 获得指定文件的字符串
|
public static void close(Closeable closeable) throws IOException
closeable - InputStream, OutputStream, Reader, Writer, etcIOException - IO exceptionpublic static byte[] getBytes(String filePath)
filePath - public static void generateFile(byte[] bfile,
String filePath,
String fileName)
bfile - filePath - fileName - public static String getString(String filePath)
filePath - Copyright © 2020. All Rights Reserved.