public final class Streams extends Object
Modifier and Type | Method and Description |
---|---|
static Writer |
asWriter(Appendable appendable)
faster variant than guava CharStreams.asWriter.
|
static long |
copy(InputStream is,
OutputStream os)
see copy(final InputStream is, final OutputStream os, final int buffSize) for detail.
|
static long |
copy(InputStream is,
OutputStream os,
int buffSize)
Equivalent to guava ByteStreams.copy, with one special behavior: if is has no bytes immediately available for
read, the os is flushed prior to the next read that will probably block.
|
public static long copy(InputStream is, OutputStream os) throws IOException
is
- os
- IOException
public static long copy(InputStream is, OutputStream os, int buffSize) throws IOException
is
- os
- buffSize
- IOException
public static Writer asWriter(Appendable appendable)
appendable
- - the appendable to transform.Copyright © 2018 SPF4J. All rights reserved.