Stay organized with collections
Save and categorize content based on your preferences.
public
interface
AudioMetadataMap
implements
AudioMetadataReadMap
android.media.AudioMetadataMap
|
AudioMetadataMap is a writeable Map
-style
interface of AudioMetadata.Key
value pairs.
This interface is not guaranteed to be thread-safe
unless the underlying implementation for the AudioMetadataMap
states it as thread safe.
Summary
Public methods |
abstract
<T>
T
|
remove(Key<T> key)
Removes the value associated with the key.
|
abstract
<T>
T
|
set(Key<T> key, T value)
Sets a value for the key.
|
Public methods
public abstract T remove (Key<T> key)
Removes the value associated with the key.
Parameters |
key |
Key : interface for storing the value.
This value cannot be null . |
Returns |
T |
the value of the key, null if it doesn't exist. |
public abstract T set (Key<T> key,
T value)
Sets a value for the key.
Parameters |
key |
Key : interface for storing the value.
This value cannot be null . |
value |
T : a non-null value of type T. |
Returns |
T |
the previous value associated with key or null if it doesn't exist. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# AudioMetadataMap\n\nAdded in [API level 30](/guide/topics/manifest/uses-sdk-element#ApiLevels) \nSummary: [Methods](#pubmethods) \\| [Inherited Methods](#inhmethods) \n\nAudioMetadataMap\n================\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/media/AudioMetadataMap \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\n\n\ninterface\nAudioMetadataMap\n`\n\n\n`\n\n\nimplements\n\n`[AudioMetadataReadMap](/reference/android/media/AudioMetadataReadMap)`\n\n\n`\n\n|--------------------------------|\n| android.media.AudioMetadataMap |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nAudioMetadataMap is a writeable `Map`-style\ninterface of [AudioMetadata.Key](/reference/android/media/AudioMetadata.Key) value pairs.\nThis interface is not guaranteed to be thread-safe\nunless the underlying implementation for the `AudioMetadataMap`\nstates it as thread safe.\n\n**See also:**\n\n- [AudioMetadataReadMap](/reference/android/media/AudioMetadataReadMap)\n\nSummary\n-------\n\n| ### Public methods ||\n|-------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract \u003cT\u003e T` | ` `[remove](/reference/android/media/AudioMetadataMap#remove(android.media.AudioMetadata.Key\u003cT\u003e))`(`[Key](/reference/android/media/AudioMetadata.Key)`\u003cT\u003e key) ` Removes the value associated with the key. |\n| ` abstract \u003cT\u003e T` | ` `[set](/reference/android/media/AudioMetadataMap#set(android.media.AudioMetadata.Key\u003cT\u003e,%20T))`(`[Key](/reference/android/media/AudioMetadata.Key)`\u003cT\u003e key, T value) ` Sets a value for the key. |\n\n| ### Inherited methods |\n|-----------------------|---|\n| From interface ` `[android.media.AudioMetadataReadMap](/reference/android/media/AudioMetadataReadMap)` ` |---------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | ` abstract \u003cT\u003e boolean` | ` `[containsKey](/reference/android/media/AudioMetadataReadMap#containsKey(android.media.AudioMetadata.Key\u003cT\u003e))`(`[Key](/reference/android/media/AudioMetadata.Key)`\u003cT\u003e key) ` Returns true if the key exists in the map. | | ` abstract `[AudioMetadataMap](/reference/android/media/AudioMetadataMap) | ` `[dup](/reference/android/media/AudioMetadataReadMap#dup())`() ` Returns a copy of the map. | | ` abstract \u003cT\u003e T` | ` `[get](/reference/android/media/AudioMetadataReadMap#get(android.media.AudioMetadata.Key\u003cT\u003e))`(`[Key](/reference/android/media/AudioMetadata.Key)`\u003cT\u003e key) ` Returns the value associated with the key. | | ` abstract int` | ` `[size](/reference/android/media/AudioMetadataReadMap#size())`() ` Returns the number of elements in the map. | ||\n\nPublic methods\n--------------\n\n### remove\n\nAdded in [API level 30](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract T remove (Key\u003cT\u003e key)\n```\n\nRemoves the value associated with the key.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|-------|-----------------------------------------------------------------------------|\n| `key` | `Key`: interface for storing the value. This value cannot be `null`. \u003cbr /\u003e |\n\n| Returns ||\n|-----|--------------------------------------------------------|\n| `T` | the value of the key, null if it doesn't exist. \u003cbr /\u003e |\n\n### set\n\nAdded in [API level 30](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract T set (Key\u003cT\u003e key, \n T value)\n```\n\nSets a value for the key.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|---------|-----------------------------------------------------------------------------|\n| `key` | `Key`: interface for storing the value. This value cannot be `null`. \u003cbr /\u003e |\n| `value` | `T`: a non-null value of type T. \u003cbr /\u003e |\n\n| Returns ||\n|-----|----------------------------------------------------------------------------|\n| `T` | the previous value associated with key or null if it doesn't exist. \u003cbr /\u003e |"]]