Stay organized with collections
Save and categorize content based on your preferences.
BridgeModeConstants
public
class
BridgeModeConstants
extends Object
This class is deprecated.
use the androidx.wear.utils.MetadataConstants
provided by the Jetpack Wear library instead.
Constants for customizing bridging of notifications from the phone to the wearable.
We support specifying whether notifications should be bridged from the phone to the wearable
in the Wear app manifest file. Simply add a meta-data element to the Wear app manifest with the
name "com.google.android.wearable.notificationBridgeMode" and either the value NO_BRIDGING or the
value BRIDGING. If you choose not to update your Wear app manifest, then notifications will be
bridged by default from the phone to the wearable.
NO_BRIDGING means that phone notifications will not be bridged to the wearable if the wearable
app is installed.
BRIDGING means that phone notifications will be bridged to the wearable, unless they are
posted with setLocalOnly(true)
.
Example AndroidManifest.xml meta-data element for NO_BRIDGING:
<meta-data
android:name="com.google.android.wearable.notificationBridgeMode"
android:value="NO_BRIDGING" />
Example AndroidManifest.xml meta-data element for BRIDGING:
<meta-data
android:name="com.google.android.wearable.notificationBridgeMode"
android:value="BRIDGING" />
Summary
Inherited methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
Constants
NOTIFICATION_BRIDGE_MODE_BRIDGING
public static final String NOTIFICATION_BRIDGE_MODE_BRIDGING
The value of the notification bridge mode meta-data element in the case where the Wear app
wants notifications to be bridged from the phone to the wearable.
Constant Value:
"BRIDGING"
public static final String NOTIFICATION_BRIDGE_MODE_METADATA_NAME
The name of the meta-data element in the Wear app manifest for specifying whether notifications
should be bridged from the phone to the wearable.
Constant Value:
"com.google.android.wearable.notificationBridgeMode"
NOTIFICATION_BRIDGE_MODE_NO_BRIDGING
public static final String NOTIFICATION_BRIDGE_MODE_NO_BRIDGING
The value of the notification bridge mode meta-data element in the case where the Wear app does
not want notifications to be bridged from the phone to the wearable.
Constant Value:
"NO_BRIDGING"
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,["# BridgeModeConstants\n\nSummary: [Constants](#constants) \\| [Inherited Methods](#inhmethods) \n\nBridgeModeConstants\n===================\n\n\n`\npublic\n\n\nclass\nBridgeModeConstants\n`\n\n\n`\n\nextends `[Object](http://developer.android.com/reference/java/lang/Object.html)`\n\n\n`\n\n`\n\n\n`\n\n|---|------------------------------------------------------------|\n| [java.lang.Object](http://developer.android.com/reference/java/lang/Object.html) ||\n| ↳ | android.support.wearable.notifications.BridgeModeConstants |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\n\n**This class is deprecated.** \n\nuse the `androidx.wear.utils.MetadataConstants` provided by the [Jetpack Wear](../../../../../jetpack/androidx/releases/wear) library instead.\n\nConstants for customizing bridging of notifications from the phone to the wearable.\n\nWe support specifying whether notifications should be bridged from the phone to the wearable\nin the Wear app manifest file. Simply add a meta-data element to the Wear app manifest with the\nname \"com.google.android.wearable.notificationBridgeMode\" and either the value NO_BRIDGING or the\nvalue BRIDGING. If you choose not to update your Wear app manifest, then notifications will be\nbridged by default from the phone to the wearable.\n\nNO_BRIDGING means that phone notifications will not be bridged to the wearable if the wearable\napp is installed.\n\nBRIDGING means that phone notifications will be bridged to the wearable, unless they are\nposted with [setLocalOnly(true)](http://developer.android.com/reference/android/app/Notification.Builder.html#setLocalOnly(boolean)).\n\nExample AndroidManifest.xml meta-data element for NO_BRIDGING:\n\n \u003cmeta-data\n android:name=\"com.google.android.wearable.notificationBridgeMode\"\n android:value=\"NO_BRIDGING\" /\u003e\n \nExample AndroidManifest.xml meta-data element for BRIDGING:\n\n \u003cmeta-data\n android:name=\"com.google.android.wearable.notificationBridgeMode\"\n android:value=\"BRIDGING\" /\u003e\n \n\u003cbr /\u003e\n\nSummary\n-------\n\n| ### Constants ||\n|------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [String](http://developer.android.com/reference/java/lang/String.html) | [NOTIFICATION_BRIDGE_MODE_BRIDGING](../../../../../reference/android/support/wearable/notifications/BridgeModeConstants.html#NOTIFICATION_BRIDGE_MODE_BRIDGING) The value of the notification bridge mode meta-data element in the case where the Wear app wants notifications to be bridged from the phone to the wearable. |\n| [String](http://developer.android.com/reference/java/lang/String.html) | [NOTIFICATION_BRIDGE_MODE_METADATA_NAME](../../../../../reference/android/support/wearable/notifications/BridgeModeConstants.html#NOTIFICATION_BRIDGE_MODE_METADATA_NAME) The name of the meta-data element in the Wear app manifest for specifying whether notifications should be bridged from the phone to the wearable. |\n| [String](http://developer.android.com/reference/java/lang/String.html) | [NOTIFICATION_BRIDGE_MODE_NO_BRIDGING](../../../../../reference/android/support/wearable/notifications/BridgeModeConstants.html#NOTIFICATION_BRIDGE_MODE_NO_BRIDGING) The value of the notification bridge mode meta-data element in the case where the Wear app does not want notifications to be bridged from the phone to the wearable. |\n\n| ### Inherited methods |\n|-----------------------|---|\n| From class ` `[java.lang.Object](http://developer.android.com/reference/java/lang/Object.html)` ` |------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------| | ` `[Object](http://developer.android.com/reference/java/lang/Object.html) | ` clone() ` | | ` boolean` | ` equals(`[Object](http://developer.android.com/reference/java/lang/Object.html)` arg0) ` | | ` void` | ` finalize() ` | | ` final `[Class](http://developer.android.com/reference/java/lang/Class.html)`\u003c?\u003e` | ` getClass() ` | | ` int` | ` hashCode() ` | | ` final void` | ` notify() ` | | ` final void` | ` notifyAll() ` | | ` `[String](http://developer.android.com/reference/java/lang/String.html) | ` toString() ` | | ` final void` | ` wait(long arg0, int arg1) ` | | ` final void` | ` wait(long arg0) ` | | ` final void` | ` wait() ` | ||\n\nConstants\n---------\n\n### NOTIFICATION_BRIDGE_MODE_BRIDGING\n\n```\npublic static final String NOTIFICATION_BRIDGE_MODE_BRIDGING\n```\n\nThe value of the notification bridge mode meta-data element in the case where the Wear app\nwants notifications to be bridged from the phone to the wearable.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n\"BRIDGING\"\n\n\n### NOTIFICATION_BRIDGE_MODE_METADATA_NAME\n\n```\npublic static final String NOTIFICATION_BRIDGE_MODE_METADATA_NAME\n```\n\nThe name of the meta-data element in the Wear app manifest for specifying whether notifications\nshould be bridged from the phone to the wearable.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n\"com.google.android.wearable.notificationBridgeMode\"\n\n\n### NOTIFICATION_BRIDGE_MODE_NO_BRIDGING\n\n```\npublic static final String NOTIFICATION_BRIDGE_MODE_NO_BRIDGING\n```\n\nThe value of the notification bridge mode meta-data element in the case where the Wear app does\nnot want notifications to be bridged from the phone to the wearable.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n\"NO_BRIDGING\""]]