summaryrefslogtreecommitdiff
path: root/core/java/android
diff options
context:
space:
mode:
authorMike Lockwood <lockwood@google.com>2010-11-04 12:40:26 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2010-11-04 12:40:26 -0700
commitd8d7b555cb45bf55f74e89a7cf9312e400f7cd1c (patch)
tree86f65d52d07f82bd1bec55b6100e300f670b64f5 /core/java/android
parentbbd4a9f9166c3c4da98e5c6bae2978ffe485ed71 (diff)
parent0b20b77ff5a67a054695954bc65f1c5c473b348b (diff)
Merge "MediaStore: Make definitions for Files table public"
Diffstat (limited to 'core/java/android')
-rw-r--r--core/java/android/provider/MediaStore.java41
1 files changed, 34 insertions, 7 deletions
diff --git a/core/java/android/provider/MediaStore.java b/core/java/android/provider/MediaStore.java
index b74e76f19864..f111ef23ad99 100644
--- a/core/java/android/provider/MediaStore.java
+++ b/core/java/android/provider/MediaStore.java
@@ -266,36 +266,62 @@ public final class MediaStore {
}
/**
- * Media provider table containing an index of all files in the storage.
- * This can be used by applications to find all documents of a particular type
- * and is also used internally by the device side MTP implementation.
- * @hide
+ * Media provider table containing an index of all files in the media storage,
+ * including non-media files. This should be used by applications that work with
+ * non-media file types (text, HTML, PDF, etc) as well as applications that need to
+ * work with multiple media file types in a single query.
*/
public static final class Files {
+ /**
+ * Get the content:// style URI for the files table on the
+ * given volume.
+ *
+ * @param volumeName the name of the volume to get the URI for
+ * @return the URI to the files table on the given volume
+ */
public static Uri getContentUri(String volumeName) {
return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName +
"/file");
}
+ /**
+ * Get the content:// style URI for a single row in the files table on the
+ * given volume.
+ *
+ * @param volumeName the name of the volume to get the URI for
+ * @param rowId the file to get the URI for
+ * @return the URI to the files table on the given volume
+ */
public static final Uri getContentUri(String volumeName,
- long fileId) {
+ long rowId) {
return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName
- + "/file/" + fileId);
+ + "/file/" + rowId);
}
+ /**
+ * For use only by the MTP implementation.
+ * @hide
+ */
public static Uri getMtpObjectsUri(String volumeName) {
return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName +
"/object");
}
+ /**
+ * For use only by the MTP implementation.
+ * @hide
+ */
public static final Uri getMtpObjectsUri(String volumeName,
long fileId) {
return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName
+ "/object/" + fileId);
}
- // Used to implement the MTP GetObjectReferences and SetObjectReferences commands.
+ /**
+ * Used to implement the MTP GetObjectReferences and SetObjectReferences commands.
+ * @hide
+ */
public static final Uri getMtpReferencesUri(String volumeName,
long fileId) {
return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName
@@ -310,6 +336,7 @@ public final class MediaStore {
/**
* The MTP format code of the file
* <P>Type: INTEGER</P>
+ * @hide
*/
public static final String FORMAT = "format";