AudioUsage
Stay organized with collections
Save and categorize content based on your preferences.
Identify the audio usage of an SASS device.
Constant Summary
int |
A2DP
|
This constant is deprecated. Use MEDIA
instead.
|
int |
CALL
|
The usage of this audio event is call. |
int |
HFP
|
This constant is deprecated. Use CALL
instead.
|
int |
LE_AUDIO
|
This constant is deprecated. Use MEDIA
or CALL
instead.
|
int |
MEDIA
|
The usage of this audio event is media. |
int |
UNKNOWN
|
|
Inherited Method Summary
From interface java.lang.annotation.Annotation
Constants
public static final int
A2DP
This constant is deprecated.
Use MEDIA
instead.
Constant Value:
2
public static final int
CALL
public static final int
HFP
This constant is deprecated.
Use CALL
instead.
Constant Value:
1
public static final int
LE_AUDIO
This constant is deprecated.
Use MEDIA
or CALL
instead.
Constant Value:
3
public static final int
UNKNOWN
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License
, and code samples are licensed under the Apache 2.0 License
. For details, see the Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-31 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 2024-10-31 UTC."],[[["\u003cp\u003e\u003ccode\u003eAudioUsage\u003c/code\u003e is an annotation used to identify the audio usage of an SASS device.\u003c/p\u003e\n"],["\u003cp\u003eIt defines constants representing different audio usages, such as \u003ccode\u003eCALL\u003c/code\u003e for calls and \u003ccode\u003eMEDIA\u003c/code\u003e for media playback.\u003c/p\u003e\n"],["\u003cp\u003eDeprecated constants like \u003ccode\u003eA2DP\u003c/code\u003e, \u003ccode\u003eHFP\u003c/code\u003e, and \u003ccode\u003eLE_AUDIO\u003c/code\u003e should be replaced with \u003ccode\u003eMEDIA\u003c/code\u003e or \u003ccode\u003eCALL\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eCALL\u003c/code\u003e supports \u003ccode\u003eBluetoothProfile.HEADSET\u003c/code\u003e for Bluetooth Classic and \u003ccode\u003eBluetoothProfile.LE_AUDIO\u003c/code\u003e for LE Audio devices.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eMEDIA\u003c/code\u003e supports \u003ccode\u003eBluetoothProfile.A2DP\u003c/code\u003e for Bluetooth Classic and \u003ccode\u003eBluetoothProfile.LE_AUDIO\u003c/code\u003e for LE Audio devices.\u003c/p\u003e\n"]]],[],null,["# AudioUsage\n\npublic abstract @interface **AudioUsage** implements [Annotation](//developer.android.com/reference/java/lang/annotation/Annotation.html) \nIdentify the audio usage of an SASS device. \n\n### Constant Summary\n\n|-----|-------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| int | [A2DP](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#A2DP) | *This constant is deprecated. Use [MEDIA](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#MEDIA) instead.* |\n| int | [CALL](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#CALL) | The usage of this audio event is call. |\n| int | [HFP](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#HFP) | *This constant is deprecated. Use [CALL](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#CALL) instead.* |\n| int | [LE_AUDIO](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#LE_AUDIO) | *This constant is deprecated. Use [MEDIA](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#MEDIA) or [CALL](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#CALL) instead.* |\n| int | [MEDIA](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#MEDIA) | The usage of this audio event is media. |\n| int | [UNKNOWN](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#UNKNOWN) | |\n\n### Inherited Method Summary\n\nFrom interface java.lang.annotation.Annotation \n\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------|\n| abstract [Class](//developer.android.com/reference/java/lang/Class.html)\\\u003c? extends [Annotation](//developer.android.com/reference/java/lang/annotation/Annotation.html)\\\u003e | annotationType() |\n| abstract boolean | equals([Object](//developer.android.com/reference/java/lang/Object.html) arg0) |\n| abstract int | hashCode() |\n| abstract [String](//developer.android.com/reference/java/lang/String.html) | toString() |\n\nConstants\n---------\n\n#### public static final int\n**A2DP**\n\n**This constant is deprecated.** \n\nUse [MEDIA](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#MEDIA)\ninstead. \nConstant Value: 2 \n\n#### public static final int\n**CALL**\n\nThe usage of this audio event is call. It supports [BluetoothProfile.HEADSET](//developer.android.com/reference/android/bluetooth/BluetoothProfile.html#HEADSET)\nprofile for Bluetooth Classic, and [BluetoothProfile.LE_AUDIO](//developer.android.com/reference/android/bluetooth/BluetoothProfile.html#LE_AUDIO)\nprofile for devices that support LE Audio. \nConstant Value: 1 \n\n#### public static final int\n**HFP**\n\n**This constant is deprecated.** \n\nUse [CALL](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#CALL)\ninstead. \nConstant Value: 1 \n\n#### public static final int\n**LE_AUDIO**\n\n**This constant is deprecated.** \n\nUse [MEDIA](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#MEDIA)\nor [CALL](/android/reference/com/google/android/gms/nearby/fastpair/AudioUsage#CALL)\ninstead. \nConstant Value: 3 \n\n#### public static final int\n**MEDIA**\n\nThe usage of this audio event is media. It supports [BluetoothProfile.A2DP](//developer.android.com/reference/android/bluetooth/BluetoothProfile.html#A2DP)\nprofile for Bluetooth Classic, and [BluetoothProfile.LE_AUDIO](//developer.android.com/reference/android/bluetooth/BluetoothProfile.html#LE_AUDIO)\nprofile for devices that support LE Audio. \nConstant Value: 2 \n\n#### public static final int\n**UNKNOWN**\n\nConstant Value: 0"]]