public class FileProviderHelper
extends java.lang.Object
Constructor and Description |
---|
FileProviderHelper() |
Modifier and Type | Method and Description |
---|---|
static android.net.Uri |
fromFile(android.content.Context context,
java.io.File file)
Required helper method that will given a file, correctly set the data
and type across the variety of versions ATAK supports.
|
static void |
setDataAndType(android.content.Context context,
android.content.Intent intent,
java.io.File file,
java.lang.String type)
Required helper method that will given a file, correctly set the data
and type across the variety of versions ATAK supports.
|
static void |
setReadAccess(android.content.Intent intent)
Required helper method that will set the appropriate access granting flags
on an intent that offers a file.
|
public static void setDataAndType(android.content.Context context, android.content.Intent intent, java.io.File file, java.lang.String type)
context
- the context to use for the setDataAndType which is the
application context.intent
- intent to set the data and type on.file
- the file to be passed by intent.type
- the type of the file.public static android.net.Uri fromFile(android.content.Context context, java.io.File file)
context
- the context to use for the setDataAndType which is the
application context.file
- the file to be passed by intent.public static void setReadAccess(android.content.Intent intent)