public class IoUtilities extends Object
| Constructor and Description |
|---|
IoUtilities() |
| Modifier and Type | Method and Description |
|---|---|
static void |
close(Closeable closeable) |
static IOException |
close(Closeable closeable,
IOException exception) |
static ByteArrayInputStream |
copy(InputStream inputStream) |
static int |
maximumLimitOfBytes(int contentLength) |
static int |
maximumLimitOfBytes(long contentLength) |
static void |
pipe(InputStream inputStream,
File file) |
static void |
pipe(InputStream in,
OutputStream out) |
static void |
pipe(InputStream in,
OutputStream out,
int bufferSize) |
static void |
pipe(InputStream in,
OutputStream out,
int bufferSize,
long numberOfBytes) |
static void |
pipe(Readable reader,
Writer writer) |
static void |
pipe(Readable in,
Writer out,
int bufferSize) |
static byte[] |
toByteArray(InputStream inputStream) |
static void |
toss(IOException exception) |
static String |
toString(InputStream inputStream,
String contentEncoding) |
static String |
toString(InputStream inputStream,
String contentEncoding,
long numberOfBytes) |
static String |
toString(Reader reader) |
public static ByteArrayInputStream copy(InputStream inputStream) throws IOException
IOExceptionpublic static void pipe(InputStream in, OutputStream out) throws IOException
IOExceptionpublic static void pipe(InputStream in, OutputStream out, int bufferSize) throws IOException
IOExceptionpublic static void pipe(InputStream in, OutputStream out, int bufferSize, long numberOfBytes) throws IOException
IOExceptionpublic static void pipe(Readable reader, Writer writer) throws IOException
IOExceptionpublic static void pipe(Readable in, Writer out, int bufferSize) throws IOException
IOExceptionpublic static void close(Closeable closeable)
public static void toss(IOException exception) throws IOException
IOExceptionpublic static IOException close(Closeable closeable, IOException exception)
public static String toString(InputStream inputStream, String contentEncoding, long numberOfBytes) throws IOException
IOExceptionpublic static String toString(InputStream inputStream, String contentEncoding) throws IOException
IOExceptionpublic static byte[] toByteArray(InputStream inputStream) throws IOException
IOExceptionpublic static int maximumLimitOfBytes(long contentLength)
public static int maximumLimitOfBytes(int contentLength)
public static String toString(Reader reader) throws IOException
IOExceptionpublic static void pipe(InputStream inputStream, File file) throws IOException
IOExceptionCopyright © 2007–2019 Andreas W. Bartels. All rights reserved.