com.bumptech.glide.load.data
Class StreamLocalUriFetcher
java.lang.Object
com.bumptech.glide.load.data.LocalUriFetcher<InputStream>
com.bumptech.glide.load.data.StreamLocalUriFetcher
- All Implemented Interfaces:
- DataFetcher<InputStream>
public class StreamLocalUriFetcher
- extends LocalUriFetcher<InputStream>
Fetches an InputStream
for a local Uri
.
Method Summary |
protected void |
close(InputStream data)
Closes the concrete data type if necessary. |
protected InputStream |
loadResource(android.net.Uri uri,
android.content.ContentResolver contentResolver)
Returns a concrete data type from the given Uri using the given
ContentResolver . |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StreamLocalUriFetcher
public StreamLocalUriFetcher(android.content.Context context,
android.net.Uri uri)
loadResource
protected InputStream loadResource(android.net.Uri uri,
android.content.ContentResolver contentResolver)
throws FileNotFoundException
- Description copied from class:
LocalUriFetcher
- Returns a concrete data type from the given
Uri
using the given
ContentResolver
.
- Specified by:
loadResource
in class LocalUriFetcher<InputStream>
- Throws:
FileNotFoundException
close
protected void close(InputStream data)
throws IOException
- Description copied from class:
LocalUriFetcher
- Closes the concrete data type if necessary.
Note - We can't rely on the closeable interface because it was added after our min API level. See issue #157.
- Specified by:
close
in class LocalUriFetcher<InputStream>
- Parameters:
data
- The data to close.
- Throws:
IOException