NotificationCompat

public class NotificationCompat
extends Object

java.lang.Object
   ↳ androidx.core.app.NotificationCompat


Helper for accessing features in Notification.

Summary

Nested classes

class NotificationCompat.Action

Structure to encapsulate a named action that can be shown as part of this notification. 

class NotificationCompat.BigPictureStyle

Helper class for generating large-format notifications that include a large image attachment. 

class NotificationCompat.BigTextStyle

Helper class for generating large-format notifications that include a lot of text. 

class NotificationCompat.BubbleMetadata

Encapsulates the information needed to display a notification as a bubble. 

class NotificationCompat.Builder

Builder class for NotificationCompat objects. 

class NotificationCompat.CarExtender

Helper class to add Android Auto extensions to notifications. 

class NotificationCompat.DecoratedCustomViewStyle

Notification style for custom views that are decorated by the system. 

interface NotificationCompat.Extender

Extender interface for use with NotificationCompat.Builder.extend(NotificationCompat.Extender)

class NotificationCompat.InboxStyle

Helper class for generating large-format notifications that include a list of (up to 5) strings. 

class NotificationCompat.MessagingStyle

Helper class for generating large-format notifications that include multiple back-and-forth messages of varying types between any number of people. 

class NotificationCompat.Style

An object that can apply a rich notification style to a Notification.CarExtender.Builder object. 

class NotificationCompat.WearableExtender

Helper class to add wearable extensions to notifications. 

Constants

int BADGE_ICON_LARGE

If this notification is being shown as a badge, use the icon provided to NotificationCompat.Builder.setLargeIcon(Bitmap) to represent this notification.

int BADGE_ICON_NONE

If this notification is being shown as a badge, always show as a number.

int BADGE_ICON_SMALL

If this notification is being shown as a badge, use the icon provided to NotificationCompat.Builder.setSmallIcon(int) to represent this notification.

String CATEGORY_ALARM

Notification category: alarm or timer.

String CATEGORY_CALL

Notification category: incoming call (voice or video) or similar synchronous communication request.

String CATEGORY_EMAIL

Notification category: asynchronous bulk message (email).

String CATEGORY_ERROR

Notification category: error in background operation or authentication status.

String CATEGORY_EVENT

Notification category: calendar event.

String CATEGORY_LOCATION_SHARING

Notification category: temporarily sharing location.

String CATEGORY_MESSAGE

Notification category: incoming direct message (SMS, instant message, etc.).

String CATEGORY_MISSED_CALL

Notification category: missed call.

String CATEGORY_NAVIGATION

Notification category: map turn-by-turn navigation.

String CATEGORY_PROGRESS

Notification category: progress of a long-running background operation.

String CATEGORY_PROMO

Notification category: promotion or advertisement.

String CATEGORY_RECOMMENDATION

Notification category: a specific, timely recommendation for a single thing.

String CATEGORY_REMINDER

Notification category: user-scheduled reminder.

String CATEGORY_SERVICE

Notification category: indication of running background service.

String CATEGORY_SOCIAL

Notification category: social network or sharing update.

String CATEGORY_STATUS

Notification category: ongoing information about device or contextual status.

String CATEGORY_STOPWATCH

Notification category: running stopwatch.

String CATEGORY_SYSTEM

Notification category: system or device status update.

String CATEGORY_TRANSPORT

Notification category: media transport control for playback.

String CATEGORY_WORKOUT

Notification category: tracking a user's workout.

int COLOR_DEFAULT

Value of Notification.color equal to 0 (also known as Color.TRANSPARENT), telling the system not to decorate this notification with any special color but instead use default colors when presenting this notification.

int DEFAULT_ALL

Use all default values (where applicable).

int DEFAULT_LIGHTS

Use the default notification lights.

int DEFAULT_SOUND

Use the default notification sound.

int DEFAULT_VIBRATE

Use the default notification vibrate.

String EXTRA_AUDIO_CONTENTS_URI

Keys into the getExtras(Notification) Bundle: the audio contents of this notification.