public class FileChooserUtils
Provides methods for extracting image path from chooser
public static FileChooserUtils INSTANCE
Provides methods for extracting image path from chooser
@JvmStatic
@Nullable
public static java.lang.String getPath(@Nullable
android.content.Context context,
@NotNull
android.net.Uri uri)
Get a file path from a Uri. This will get the the path for Storage Access Framework Documents, as well as the _data field for the MediaStore and other file-based ContentProviders.
context - The context.uri - The Uri to query.@JvmStatic
@NotNull
public static java.lang.String getDataColumn(@Nullable
android.content.Context context,
@Nullable
android.net.Uri uri,
@Nullable
java.lang.String selection,
@Nullable
java.lang.String[] selectionArgs)
Get the value of the data column for this Uri. This is useful for MediaStore Uris, and other file-based ContentProviders.
context - The context.uri - The Uri to query.selection - (Optional) Filter used in the query.selectionArgs - (Optional) Selection arguments used in the query.@JvmStatic
public static boolean isExternalStorageDocument(@NotNull
android.net.Uri uri)
uri - The Uri to check.@JvmStatic
public static boolean isDownloadsDocument(@NotNull
android.net.Uri uri)
uri - The Uri to check.@JvmStatic
public static boolean isMediaDocument(@NotNull
android.net.Uri uri)
uri - The Uri to check.