Package com.foxinmy.weixin4j.util
Class IOUtil
- java.lang.Object
-
- com.foxinmy.weixin4j.util.IOUtil
-
public class IOUtil extends Object
IOUtil- Since:
- JDK 1.6
- Author:
- jinyu(foxinmy@gmail.com)
- See Also:
org.apache.commons.io.IOUtils
-
-
Constructor Summary
Constructors Constructor Description IOUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
close(Closeable stream)
static int
copy(InputStream input, OutputStream output)
static void
copy(Reader input, OutputStream output, Charset encoding)
static byte[]
toByteArray(InputStream input)
static byte[]
toByteArray(Reader input)
static byte[]
toByteArray(Reader input, Charset encoding)
-
-
-
Method Detail
-
toByteArray
public static byte[] toByteArray(Reader input) throws IOException
- Throws:
IOException
-
toByteArray
public static byte[] toByteArray(Reader input, Charset encoding) throws IOException
- Throws:
IOException
-
copy
public static void copy(Reader input, OutputStream output, Charset encoding) throws IOException
- Throws:
IOException
-
copy
public static int copy(InputStream input, OutputStream output) throws IOException
- Throws:
IOException
-
toByteArray
public static byte[] toByteArray(InputStream input) throws IOException
- Throws:
IOException
-
close
public static void close(Closeable stream)
-
-