MediaStore.Audio.AudioColumns  |  API reference  |  Android Developers


public static interface MediaStore.Audio.AudioColumns
implements MediaStore.MediaColumns

android.provider.MediaStore.Audio.AudioColumns



Audio metadata columns.

Summary

Constants

String ALBUM_ID

The id of the album the audio file is from, if any.

String ALBUM_KEY

This constant was deprecated in API level 30. These keys are generated using Locale.ROOT, which means they don't reflect locale-specific sorting preferences. To apply locale-specific sorting preferences, use ContentResolver.QUERY_ARG_SQL_SORT_ORDER with COLLATE LOCALIZED, or ContentResolver.QUERY_ARG_SORT_LOCALE.

String ARTIST_ID

The id of the artist who created the audio file, if any.

String ARTIST_KEY

This constant was deprecated in API level 30. These keys are generated using Locale.ROOT, which means they don't reflect locale-specific sorting preferences. To apply locale-specific sorting preferences, use ContentResolver.QUERY_ARG_SQL_SORT_ORDER with COLLATE LOCALIZED, or ContentResolver.QUERY_ARG_SORT_LOCALE.

String BITS_PER_SAMPLE

The number of bits used to represent each audio sample, if available.

String BOOKMARK

The position within the audio item at which playback should be resumed.

String GENRE

The genre of the audio file, if any.

String GENRE_ID

The id of the genre the audio file is from, if any.

String GENRE_KEY

This constant was deprecated in API level 30. These keys are generated using Locale.ROOT, which means they don't reflect locale-specific sorting preferences. To apply locale-specific sorting preferences, use ContentResolver.QUERY_ARG_SQL_SORT_ORDER with COLLATE LOCALIZED, or ContentResolver.QUERY_ARG_SORT_LOCALE.

String IS_ALARM

Non-zero if the audio file may be an alarm.

String IS_AUDIOBOOK

Non-zero if the audio file is an audiobook.

String IS_MUSIC

Non-zero if the audio file is music.

String IS_NOTIFICATION

Non-zero if the audio file may be a notification sound.

String IS_PODCAST

Non-zero if the audio file is a podcast.

String IS_RECORDING

Non-zero if the audio file is a voice recording recorded by voice recorder apps.

String IS_RINGTONE

Non-zero if the audio file may be a ringtone.

String SAMPLERATE

The sample rate in Hz, if available.

String TITLE_KEY

This constant was deprecated in API level 30. These keys are generated using Locale.ROOT, which means they don't reflect locale-specific sorting preferences. To apply locale-specific sorting preferences, use ContentResolver.QUERY_ARG_SQL_SORT_ORDER with COLLATE LOCALIZED, or ContentResolver.QUERY_ARG_SORT_LOCALE.

String TITLE_RESOURCE_URI

The resource URI of a localized title, if any.

String TRACK

The track number of this song on the album, if any.

String YEAR

The year the audio file was recorded, if any.

Inherited constants

From interface android.provider.MediaStore.MediaColumns

String ALBUM

Indexed value of MediaMetadataRetriever.METADATA_KEY_ALBUM extracted from this media item.

String ALBUM_ARTIST

Indexed value of MediaMetadataRetriever.METADATA_KEY_ALBUMARTIST extracted from this media item.

String ARTIST

Indexed value of MediaMetadataRetriever.METADATA_KEY_ARTIST or ExifInterface.TAG_ARTIST extracted from this media item.

String AUTHOR

Indexed value of MediaMetadataRetriever.METADATA_KEY_AUTHOR extracted from this media item.

String BITRATE

Indexed value of MediaMetadataRetriever.METADATA_KEY_BITRATE extracted from this media item.

String BUCKET_DISPLAY_NAME

The primary bucket display name of this media item.

String BUCKET_ID

The primary bucket ID of this media item.

String CAPTURE_FRAMERATE

Indexed value of MediaMetadataRetriever.METADATA_KEY_CAPTURE_FRAMERATE extracted from this media item.

String CD_TRACK_NUMBER

Indexed value of MediaMetadataRetriever.METADATA_KEY_CD_TRACK_NUMBER extracted from this media item.

String COMPILATION

Indexed value of MediaMetadataRetriever.METADATA_KEY_COMPILATION extracted from this media item.

String COMPOSER

Indexed value of MediaMetadataRetriever.METADATA_KEY_COMPOSER extracted from this media item.

String DATA

Absolute filesystem path to the media item on disk.

String DATE_ADDED

The time the media item was first added.

String DATE_EXPIRES

The time the media item should be considered expired.

String DATE_MODIFIED

Indexed value of File.lastModified() extracted from this media item.

String DATE_TAKEN

Indexed value of MediaMetadataRetriever.METADATA_KEY_DATE or ExifInterface.TAG_DATETIME_ORIGINAL extracted from this media item.

String DISC_NUMBER

Indexed value of MediaMetadataRetriever.METADATA_KEY_DISC_NUMBER extracted from this media item.

String DISPLAY_NAME

The display name of the media item.

String DOCUMENT_ID

The "document ID" GUID as defined by the XMP Media Management standard, extracted from any XMP metadata contained within this media item.

String DURATION

Indexed value of MediaMetadataRetriever.METADATA_KEY_DURATION extracted from this media item.

String GENERATION_ADDED

Generation number at which metadata for this media item was first inserted.

String GENERATION_MODIFIED

Generation number at which metadata for this media item was last changed.

String GENRE

Indexed value of MediaMetadataRetriever.METADATA_KEY_GENRE extracted from this media item.

String HEIGHT

Indexed value of MediaMetadataRetriever.METADATA_KEY_VIDEO_HEIGHT, MediaMetadataRetriever.METADATA_KEY_IMAGE_HEIGHT or ExifInterface.TAG_IMAGE_LENGTH extracted from this media item.

String INFERRED_DATE

File's approximate creation date.

String INSTANCE_ID

The "instance ID" GUID as defined by the XMP Media Management standard, extracted from any XMP metadata contained within this media item.

String IS_DOWNLOAD

Flag indicating if the media item has been marked as being part of the Downloads collection.

String IS_DRM

Flag indicating if a media item is DRM protected.

String IS_FAVORITE

Flag indicating if the media item has been marked as being a "favorite" by the user.

String IS_PENDING

Flag indicating if a media item is pending, and still being inserted by its owner.

String IS_TRASHED

Flag indicating if a media item is trashed.

String MIME_TYPE

The MIME type of the media item.

String NUM_TRACKS

Indexed value of MediaMetadataRetriever.METADATA_KEY_NUM_TRACKS extracted from this media item.

String OEM_METADATA

Column which allows OEMs to store custom metadata for a media file.

String ORIENTATION

Indexed value of MediaMetadataRetriever.METADATA_KEY_VIDEO_ROTATION, MediaMetadataRetriever.METADATA_KEY_IMAGE_ROTATION, or ExifInterface.TAG_ORIENTATION extracted from this media item.

String ORIGINAL_DOCUMENT_ID

The "original document ID" GUID as defined by the XMP Media Management standard, extracted from any XMP metadata contained within this media item.

String OWNER_PACKAGE_NAME

Package name that contributed this media.

String RELATIVE_PATH

Relative path of this media item within the storage device where it is persisted.

String RESOLUTION

Calculated value that combines WIDTH and HEIGHT into a user-presentable string.

String SIZE

Indexed value of File.length() extracted from this media item.

String TITLE

Indexed value of MediaMetadataRetriever.METADATA_KEY_TITLE extracted from this media item.

String VOLUME_NAME

Volume name of the specific storage device where this media item is persisted.

String WIDTH

Indexed value of MediaMetadataRetriever.METADATA_KEY_VIDEO_WIDTH, MediaMetadataRetriever.METADATA_KEY_IMAGE_WIDTH or ExifInterface.TAG_IMAGE_WIDTH extracted from this media item.

String WRITER

Indexed value of MediaMetadataRetriever.METADATA_KEY_WRITER extracted from this media item.

String XMP

Indexed XMP metadata extracted from this media item.

String YEAR

Indexed value of MediaMetadataRetriever.METADATA_KEY_YEAR extracted from this media item.

From interface android.provider.BaseColumns

String _COUNT

The count of rows in a directory.

String _ID

The unique ID for a row.

Constants

ALBUM_ID

public static final String ALBUM_ID

The id of the album the audio file is from, if any.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "album_id"

ARTIST_ID

public static final String ARTIST_ID

The id of the artist who created the audio file, if any.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "artist_id"

BITS_PER_SAMPLE

public static final String BITS_PER_SAMPLE

The number of bits used to represent each audio sample, if available.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "bits_per_sample"

BOOKMARK

public static final String BOOKMARK

The position within the audio item at which playback should be resumed.
Value is a non-negative duration in milliseconds.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER .

Constant Value: "bookmark"

GENRE

public static final String GENRE

The genre of the audio file, if any.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_STRING , and are read-only and cannot be mutated.

Constant Value: "genre"

GENRE_ID

public static final String GENRE_ID

The id of the genre the audio file is from, if any.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "genre_id"

IS_ALARM

public static final String IS_ALARM

Non-zero if the audio file may be an alarm.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_alarm"

IS_AUDIOBOOK

public static final String IS_AUDIOBOOK

Non-zero if the audio file is an audiobook.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_audiobook"

IS_MUSIC

public static final String IS_MUSIC

Non-zero if the audio file is music.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_music"

IS_NOTIFICATION

public static final String IS_NOTIFICATION

Non-zero if the audio file may be a notification sound.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_notification"

IS_PODCAST

public static final String IS_PODCAST

Non-zero if the audio file is a podcast.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_podcast"

IS_RECORDING

public static final String IS_RECORDING

Non-zero if the audio file is a voice recording recorded by voice recorder apps.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_recording"

IS_RINGTONE

public static final String IS_RINGTONE

Non-zero if the audio file may be a ringtone.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "is_ringtone"

SAMPLERATE

public static final String SAMPLERATE

The sample rate in Hz, if available.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "samplerate"

TITLE_RESOURCE_URI

public static final String TITLE_RESOURCE_URI

The resource URI of a localized title, if any.

Conforms to this pattern:

  • Scheme: ContentResolver.SCHEME_ANDROID_RESOURCE
  • Authority: Package Name of ringtone title provider
  • First Path Segment: Type of resource (must be "string")
  • Second Path Segment: Resource ID of title

.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_STRING , and are read-only and cannot be mutated.

Constant Value: "title_resource_uri"

TRACK

public static final String TRACK

The track number of this song on the album, if any. This number encodes both the track number and the disc number. For multi-disc sets, this number will be 1xxx for tracks on the first disc, 2xxx for tracks on the second disc, etc.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "track"

YEAR

public static final String YEAR

The year the audio file was recorded, if any.
This constant represents a column name that can be used with a ContentProvider through a ContentValues or Cursor object. The values stored in this column are Cursor#FIELD_TYPE_INTEGER , and are read-only and cannot be mutated.

Constant Value: "year"