public
static
final
class
NotificationCompat.BubbleMetadata
extends Object
java.lang.Object
|
↳ |
androidx.core.app.NotificationCompat.BubbleMetadata
|
Encapsulates the information needed to display a notification as a bubble.
A bubble is used to display app content in a floating window over the existing
foreground activity. A bubble has a collapsed state represented by an icon,
NotificationCompat.BubbleMetadata.Builder.setIcon(IconCompat)
and an expanded state which is populated
via NotificationCompat.BubbleMetadata.Builder.setIntent(PendingIntent)
.
Notifications with a valid and allowed bubble will display in collapsed state
outside of the notification shade on unlocked devices. When a user interacts with the
collapsed bubble, the bubble intent will be invoked and displayed.
Summary
Nested classes |
class |
NotificationCompat.BubbleMetadata.Builder
Builder to construct a NotificationCompat.BubbleMetadata object.
|
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()
|
|
Public methods
getAutoExpandBubble
public boolean getAutoExpandBubble ()
Returns |
boolean |
whether this bubble should auto expand when it is posted. |
getDeleteIntent
public PendingIntent getDeleteIntent ()
Returns |
PendingIntent |
the pending intent to send when the bubble is dismissed by a user, if one exists.
|
getDesiredHeight
public int getDesiredHeight ()
Returns |
int |
the ideal height, in DPs, for the floating window that app content defined by
getIntent() for this bubble. A value of 0 indicates a desired height has not
been set.
|
getDesiredHeightResId
public int getDesiredHeightResId ()
Returns |
int |
the resId of ideal height for the floating window that app content defined by
getIntent() for this bubble. A value of 0 indicates a res value has not
been provided for the desired height.
|
getShortcutId
public String getShortcutId ()
isNotificationSuppressed
public boolean isNotificationSuppressed ()
Returns |
boolean |
whether this bubble should suppress the notification when it is posted. |
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"Missing the information I need"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"Too complicated / too many steps"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"Out of date"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"Samples/Code issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
Content and code samples on this page are subject to the licenses described in the Content License. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2020-11-11 UTC.