Stay organized with collections
Save and categorize content based on your preferences.
public
static
interface
AudioMetadata.Key
android.media.AudioMetadata.Key<T>
|
Key interface for the AudioMetadata
map.
The presence of this Key
interface on an object allows
it to reference metadata in the Audio Framework.
Vendors are allowed to implement this Key
interface for their debugging or
private application use. To avoid name conflicts, vendor key names should be qualified by
the vendor company name followed by a dot; for example, "vendorCompany.someVolume".
Summary
Public methods |
abstract
String
|
getName()
Returns the internal name of the key.
|
abstract
Class<T>
|
getValueClass()
Returns the class type T of the associated value.
|
Public methods
getName
public abstract String getName ()
Returns the internal name of the key. The name should be unique in the
AudioMetadata
namespace. Vendors should prefix their keys with
the company name followed by a dot.
Returns |
String |
This value cannot be null . |
getValueClass
public abstract Class<T> getValueClass ()
Returns the class type T
of the associated value. Valid class types for
Build.VERSION_CODES.R
are
Integer.class
, Long.class
, Float.class
, Double.class
,
String.class
.
Returns |
Class<T> |
This value cannot be null . |
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,["# AudioMetadata.Key\n\nAdded in [API level 30](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\nAudioMetadata.Key\n=================\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/media/AudioMetadata.Key \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\nstatic\n\n\ninterface\nAudioMetadata.Key\n`\n\n\n`\n\n\n`\n\n|--------------------------------------|\n| android.media.AudioMetadata.Key\\\u003cT\\\u003e |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nKey interface for the `AudioMetadata` map.\n\nThe presence of this `Key` interface on an object allows\nit to reference metadata in the Audio Framework.\n\nVendors are allowed to implement this `Key` interface for their debugging or\nprivate application use. To avoid name conflicts, vendor key names should be qualified by\nthe vendor company name followed by a dot; for example, \"vendorCompany.someVolume\".\n\n\u003cbr /\u003e\n\nSummary\n-------\n\n| ### Public methods ||\n|------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract `[String](/reference/java/lang/String) | ` `[getName](/reference/android/media/AudioMetadata.Key#getName())`() ` Returns the internal name of the key. |\n| ` abstract `[Class](/reference/java/lang/Class)`\u003cT\u003e` | ` `[getValueClass](/reference/android/media/AudioMetadata.Key#getValueClass())`() ` Returns the class type `T` of the associated value. |\n\nPublic methods\n--------------\n\n### getName\n\nAdded in [API level 30](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract String getName ()\n```\n\nReturns the internal name of the key. The name should be unique in the\n`AudioMetadata` namespace. Vendors should prefix their keys with\nthe company name followed by a dot.\n\n\u003cbr /\u003e\n\n| Returns ||\n|---------------------------------------|-------------------------------------|\n| [String](/reference/java/lang/String) | This value cannot be `null`. \u003cbr /\u003e |\n\n### getValueClass\n\nAdded in [API level 30](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract Class\u003cT\u003e getValueClass ()\n```\n\nReturns the class type `T` of the associated value. Valid class types for\n[Build.VERSION_CODES.R](/reference/android/os/Build.VERSION_CODES#R) are\n`Integer.class`, `Long.class`, `Float.class`, `Double.class`,\n`String.class`.\n\n\u003cbr /\u003e\n\n| Returns ||\n|------------------------------------------|-------------------------------------|\n| [Class](/reference/java/lang/Class)`\u003cT\u003e` | This value cannot be `null`. \u003cbr /\u003e |"]]