public final class FileStreamProvider extends Object implements Provider<SeekableInputStream,IOException>
Provider
which may be used to access a local file. This class may be used in
conjunction with the Reader and Read APIs to provide the input.
get()
supports multiple calls and will return new independent InputStream
instances. Moreover it will generate SeekableInputStream
instances if possible.
Constructor and Description |
---|
FileStreamProvider(File file)
Construct a
FileStreamProvider for the given File . |
public FileStreamProvider(File file)
FileStreamProvider
for the given File
.IllegalArgumentException
- if the file is null
public SeekableInputStream get() throws IOException
Provider
T
. Must never return null
. Whether this method may be
called more that one time is not specified. Supporting multiple calls is up to the
implementation.get
in interface Provider<SeekableInputStream,IOException>
IOException
Copyright © 2024 levigo holding gmbh. All rights reserved.