Package | Description |
---|---|
com.google.common.io |
This package contains utility methods and classes for working with Java I/O,
for example input streams, output streams, readers, writers, and files.
|
Modifier and Type | Class and Description |
---|---|
class |
ByteSource
A readable source of bytes, such as a file.
|
class |
CharSource
A readable source of characters, such as a text file.
|
Modifier and Type | Method and Description |
---|---|
static InputSupplier<InputStream> |
ByteStreams.join(InputSupplier<? extends InputStream>... suppliers)
Deprecated.
Use
ByteSource.concat(ByteSource[]) instead. This
method is scheduled for removal in Guava 18.0. |
static InputSupplier<Reader> |
CharStreams.join(InputSupplier<? extends Reader>... suppliers)
Deprecated.
Use
CharSource.concat(CharSource[]) instead. This
method is scheduled for removal in Guava 18.0. |
static InputSupplier<InputStream> |
ByteStreams.join(Iterable<? extends InputSupplier<? extends InputStream>> suppliers)
Deprecated.
Use
ByteSource.concat(Iterable) instead. This method
is scheduled for removal in Guava 18.0. |
static InputSupplier<Reader> |
CharStreams.join(Iterable<? extends InputSupplier<? extends Reader>> suppliers)
Deprecated.
Use
CharSource.concat(Iterable) instead. This method
is scheduled for removal in Guava 18.0. |
static InputSupplier<ByteArrayInputStream> |
ByteStreams.newInputStreamSupplier(byte[] b)
Deprecated.
Use
ByteSource.wrap(byte[]) instead. This method is
scheduled for removal in Guava 18.0. |
static InputSupplier<ByteArrayInputStream> |
ByteStreams.newInputStreamSupplier(byte[] b,
int off,
int len)
Deprecated.
Use
ByteSource.wrap(b).slice(off, len) instead. This
method is scheduled for removal in Guava 18.0. |
static InputSupplier<FileInputStream> |
Files.newInputStreamSupplier(File file)
Deprecated.
Use
Files.asByteSource(File) . This method is scheduled for
removal in Guava 18.0. |
static InputSupplier<InputStream> |
Resources.newInputStreamSupplier(URL url)
Deprecated.
Use
Resources.asByteSource(URL) instead. This method is
scheduled for removal in Guava 18.0. |
static InputSupplier<InputStreamReader> |
Files.newReaderSupplier(File file,
Charset charset)
Deprecated.
Use
Files.asCharSource(File, Charset) . This method is
scheduled for removal in Guava 18.0. |
static InputSupplier<InputStreamReader> |
CharStreams.newReaderSupplier(InputSupplier<? extends InputStream> in,
Charset charset)
Deprecated.
Use
ByteSource.asCharSource(Charset) instead. This
method is scheduled for removal in Guava 18.0. |
static InputSupplier<StringReader> |
CharStreams.newReaderSupplier(String value)
Deprecated.
Use
CharSource#wrap(CharSequence } instead. This method
is scheduled for removal in Guava 18.0. |
static InputSupplier<InputStreamReader> |
Resources.newReaderSupplier(URL url,
Charset charset)
Deprecated.
Use
Resources.asCharSource(URL, Charset) instead. This method
is scheduled for removal in Guava 18.0. |
static InputSupplier<InputStream> |
ByteStreams.slice(InputSupplier<? extends InputStream> supplier,
long offset,
long length)
Deprecated.
Use
ByteSource#slice(int, int) instead. This method is
scheduled for removal in Guava 18.0. |
Modifier and Type | Method and Description |
---|---|
static ByteSource |
ByteStreams.asByteSource(InputSupplier<? extends InputStream> supplier)
Deprecated.
Convert all
InputSupplier<? extends InputStream>
implementations to extend ByteSource or provide a method for
viewing the object as a ByteSource . This method is scheduled
for removal in Guava 18.0. |
static CharSource |
CharStreams.asCharSource(InputSupplier<? extends Readable> supplier)
Deprecated.
Convert all
InputSupplier<? extends Readable>
implementations to extend CharSource or provide a method for
viewing the object as a CharSource . This method is scheduled
for removal in Guava 18.0. |
static void |
Files.copy(InputSupplier<? extends InputStream> from,
File to)
Deprecated.
Use
from.copyTo(Files.asByteSink(to)) after changing
from to a ByteSource if necessary. This method is
scheduled to be removed in Guava 18.0. |
static long |
ByteStreams.copy(InputSupplier<? extends InputStream> from,
OutputStream to)
Deprecated.
Use
ByteSource.copyTo(OutputStream) instead. This
method is scheduled for removal in Guava 18.0. |
static long |
ByteStreams.copy(InputSupplier<? extends InputStream> from,
OutputSupplier<? extends OutputStream> to)
Deprecated.
Use
ByteSource.copyTo(ByteSink) instead. This method
is scheduled for removal in Guava 18.0. |
static <R extends Readable & Closeable> |
CharStreams.copy(InputSupplier<R> from,
Appendable to)
Deprecated.
Use
CharSource.copyTo(Appendable) instead. This method
is scheduled for removal in Guava 18.0. |
static <R extends Readable & Closeable> |
Files.copy(InputSupplier<R> from,
File to,
Charset charset)
Deprecated.
Use
from.copyTo(Files.asCharSink(to, charset)) after
changing from to a CharSource if necessary. This
method is scheduled to be removed in Guava 18.0. |
static <R extends Readable & Closeable,W extends Appendable & Closeable> |
CharStreams.copy(InputSupplier<R> from,
OutputSupplier<W> to)
Deprecated.
Use {@link CharSource#copyTo(CharSink) instead. This method is
scheduled for removal in Guava 18.0.
|
static boolean |
ByteStreams.equal(InputSupplier<? extends InputStream> supplier1,
InputSupplier<? extends InputStream> supplier2)
Deprecated.
Use
ByteSource.contentEquals(ByteSource) instead. This
method is scheduled for removal in Guava 18.0. |
static boolean |
ByteStreams.equal(InputSupplier<? extends InputStream> supplier1,
InputSupplier<? extends InputStream> supplier2)
Deprecated.
Use
ByteSource.contentEquals(ByteSource) instead. This
method is scheduled for removal in Guava 18.0. |
static HashCode |
ByteStreams.hash(InputSupplier<? extends InputStream> supplier,
HashFunction hashFunction)
Deprecated.
Use
ByteSource.hash(HashFunction) instead. This method
is scheduled for removal in Guava 18.0. |
static InputSupplier<InputStream> |
ByteStreams.join(InputSupplier<? extends InputStream>... suppliers)
Deprecated.
Use
ByteSource.concat(ByteSource[]) instead. This
method is scheduled for removal in Guava 18.0. |
static InputSupplier<Reader> |
CharStreams.join(InputSupplier<? extends Reader>... suppliers)
Deprecated.
Use
CharSource.concat(CharSource[]) instead. This
method is scheduled for removal in Guava 18.0. |
static long |
ByteStreams.length(InputSupplier<? extends InputStream> supplier)
Deprecated.
Use
ByteSource.size() instead. This method is
scheduled for removal in Guava 18.0. |
static InputSupplier<InputStreamReader> |
CharStreams.newReaderSupplier(InputSupplier<? extends InputStream> in,
Charset charset)
Deprecated.
Use
ByteSource.asCharSource(Charset) instead. This
method is scheduled for removal in Guava 18.0. |
static <T> T |
ByteStreams.readBytes(InputSupplier<? extends InputStream> supplier,
ByteProcessor<T> processor)
Deprecated.
Use
ByteSource.read(ByteProcessor) instead. This
method is scheduled for removal in Guava 18.0. |
static <R extends Readable & Closeable> |
CharStreams.readFirstLine(InputSupplier<R> supplier)
Deprecated.
Use
CharSource.readFirstLine() instead. This method is
scheduled for removal in Guava 18.0. |
static <R extends Readable & Closeable> |
CharStreams.readLines(InputSupplier<R> supplier)
Deprecated.
Use
CharSource.readLines() instead, but note that it
returns an ImmutableList . This method is scheduled for removal
in Guava 18.0. |
static <R extends Readable & Closeable,T> |
CharStreams.readLines(InputSupplier<R> supplier,
LineProcessor<T> callback)
Deprecated.
Use
CharSource.readLines(LineProcessor) instead. This
method is scheduled for removal in Guava 18.0. |
static InputSupplier<InputStream> |
ByteStreams.slice(InputSupplier<? extends InputStream> supplier,
long offset,
long length)
Deprecated.
Use
ByteSource#slice(int, int) instead. This method is
scheduled for removal in Guava 18.0. |
static byte[] |
ByteStreams.toByteArray(InputSupplier<? extends InputStream> supplier)
Deprecated.
Use
ByteSource.read() instead. This method is
scheduled for removal in Guava 18.0. |
static <R extends Readable & Closeable> |
CharStreams.toString(InputSupplier<R> supplier)
Deprecated.
Use
CharSource.read() instead. This method is
scheduled for removal in Guava 18.0. |
Modifier and Type | Method and Description |
---|---|
static InputSupplier<InputStream> |
ByteStreams.join(Iterable<? extends InputSupplier<? extends InputStream>> suppliers)
Deprecated.
Use
ByteSource.concat(Iterable) instead. This method
is scheduled for removal in Guava 18.0. |
static InputSupplier<Reader> |
CharStreams.join(Iterable<? extends InputSupplier<? extends Reader>> suppliers)
Deprecated.
Use
CharSource.concat(Iterable) instead. This method
is scheduled for removal in Guava 18.0. |
Copyright © 2010-2014. All Rights Reserved.