public class MediaResult extends java.lang.Object implements android.os.Parcelable, java.lang.Comparable<MediaResult>
| Modifier and Type | Field and Description |
|---|---|
static android.os.Parcelable.Creator<MediaResult> |
CREATOR |
static long |
UNKNOWN_VALUE |
| Constructor and Description |
|---|
MediaResult(java.io.File file,
android.net.Uri uri,
android.net.Uri originalUri,
java.lang.String name,
java.lang.String mimeType,
long size,
long width,
long height) |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(MediaResult o) |
int |
describeContents() |
boolean |
equals(java.lang.Object o) |
java.io.File |
getFile()
Get the resolved
File. |
long |
getHeight()
Gets the height of the image.
|
java.lang.String |
getMimeType()
Get the mime type of the file
|
java.lang.String |
getName()
Get the name of the file.
|
android.net.Uri |
getOriginalUri()
Get the original
Uri to the media. |
long |
getSize()
Gets the file size.
|
android.net.Uri |
getUri()
Get the
Uri to the File. |
long |
getWidth()
Gets the width of the image.
|
int |
hashCode() |
void |
writeToParcel(android.os.Parcel dest,
int flags) |
public static final long UNKNOWN_VALUE
public static final android.os.Parcelable.Creator<MediaResult> CREATOR
public MediaResult(java.io.File file,
android.net.Uri uri,
android.net.Uri originalUri,
java.lang.String name,
java.lang.String mimeType,
long size,
long width,
long height)
public java.io.File getFile()
File.Filepublic android.net.Uri getUri()
Uri to the File.
Uri points to the
BelvedereFileProvider and could be used
to open the File in a 3rd party app or share
it with other apps.Uripublic android.net.Uri getOriginalUri()
Uri to the media.
This might not always be available or be invalid. This
is the original Uri before it was resolved.
Uripublic int describeContents()
describeContents in interface android.os.Parcelablepublic java.lang.String getName()
public java.lang.String getMimeType()
public long getSize()
public long getWidth()
public long getHeight()
public void writeToParcel(android.os.Parcel dest,
int flags)
writeToParcel in interface android.os.Parcelablepublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic int compareTo(MediaResult o)
compareTo in interface java.lang.Comparable<MediaResult>