| 限定符和类型 | 方法和说明 |
|---|---|
static byte[] |
toByteArray(InputStream is) |
static String |
toString(InputStream is,
String charsetName) |
static void |
transfer(File sourceFile,
OutputStream targetOs,
boolean snapshoot)
将文件输出到输出流中
|
public static void transfer(File sourceFile, OutputStream targetOs, boolean snapshoot) throws Exception
sourceFile - targetOs - snapshoot - 如果文件正在做追加操作,为 true 时只输出操作时的快照内容Exceptionpublic static byte[] toByteArray(InputStream is) throws IOException
IOExceptionpublic static String toString(InputStream is, String charsetName) throws IOException
IOExceptionCopyright © 2020. All rights reserved.