All Superinterfaces:
AutoCloseable , Closeable , Iterable <T>
All Known Implementing Classes:
DataReader , TextLineReader
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Essentially just a
Supplier, but assumed to be reading from a file or some other source of data,
and therefore extends
Closeable.
Nested Class Summary
Nested Classes
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods
default void
static void
Read the properties file and copy the entries to the supplied destination
Properties instance.
static void
Delete this file or directory (does not need to be empty).
default int
default void
Returning null indicates that there are no more items to read.
Method Details
copy
Read the properties file and copy the entries to the supplied destination
Properties instance.
Parameters:
sourceFile - Source properties file
destinationMap - Destination properties map
delete
static void delete (File file)
Delete this file or directory (does not need to be empty).
Parameters:
file - Path to a file or directory to be deleted
deserializeObjectFromFile
drainTo
default int drainTo (Collection <? super T > container,
int maxElements)
forEachInBacthes
default void forEachInBacthes (int batchSize,
Consumer <? super T > action)
Similar to
Iterable.forEach(Consumer) but processes items in batches. Will extract up to batchSize
items before calling the action, and then repeat until no more items are available.
read
Returning null indicates that there are no more items to read. That's the same behaviour as
BufferedReader.readLine(). All implementations must return null precisely once.