public final class ParcelFileDescriptorRewinder extends java.lang.Object implements DataRewinder<android.os.ParcelFileDescriptor>
ParcelFileDescriptors that rewinds file descriptors by seeking to 0.| Modifier and Type | Class and Description |
|---|---|
static class |
ParcelFileDescriptorRewinder.Factory
Factory for producing
ParcelFileDescriptorRewinders from ParcelFileDescriptors. |
| Constructor and Description |
|---|
ParcelFileDescriptorRewinder(android.os.ParcelFileDescriptor parcelFileDescriptor) |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanup()
Called when this rewinder is no longer needed and can be cleaned up.
|
static boolean |
isSupported() |
android.os.ParcelFileDescriptor |
rewindAndGet()
Rewinds the wrapped data back to the beginning and returns the re-wound data (or a wrapper for
the re-wound data).
|
public ParcelFileDescriptorRewinder(android.os.ParcelFileDescriptor parcelFileDescriptor)
public static boolean isSupported()
@NonNull
public android.os.ParcelFileDescriptor rewindAndGet()
throws java.io.IOException
DataRewinderrewindAndGet in interface DataRewinder<android.os.ParcelFileDescriptor>java.io.IOExceptionpublic void cleanup()
DataRewinderThe underlying data may still be in use and should not be closed or invalidated.
cleanup in interface DataRewinder<android.os.ParcelFileDescriptor>