CastRemoteDisplayLocalService.NotificationSettings.Builder

  • CastRemoteDisplayLocalService.NotificationSettings.Builder is a builder class for creating CastRemoteDisplayLocalService.NotificationSettings objects.

  • It includes methods to build the settings object, set a custom notification, set a PendingIntent for the default notification click, and set the default notification text and title.

  • If a custom notification is provided using setNotification, other settings like text, title, and PendingIntent should not be used.

public static final class CastRemoteDisplayLocalService.NotificationSettings.Builder extends Object

Public Constructor Summary

Public Method Summary

CastRemoteDisplayLocalService.NotificationSettings
CastRemoteDisplayLocalService.NotificationSettings.Builder
setNotification(Notification notification)
Sets a custom Notification.
CastRemoteDisplayLocalService.NotificationSettings.Builder
setNotificationPendingIntent(PendingIntent notificationPendingIntent)
Sets a PendingIntent that will be executed when the default notification is clicked.
CastRemoteDisplayLocalService.NotificationSettings.Builder
setNotificationText(String notificationText)
The default Notification text.
CastRemoteDisplayLocalService.NotificationSettings.Builder
setNotificationTitle(String notificationTitle)
The default Notification title.

Inherited Method Summary

Public Constructors

public Builder ()

Public Methods

public CastRemoteDisplayLocalService.NotificationSettings build ()

Builds and returns the CastRemoteDisplayLocalService.NotificationSettings object. It verifies that if the notification is provided the other arguments are not provided.

public CastRemoteDisplayLocalService.NotificationSettings.Builder setNotification (Notification notification)

Sets a custom Notification. If a custom notification is used, the rest of the settings should not be provided.

Parameters
notification The custom notification.

public CastRemoteDisplayLocalService.NotificationSettings.Builder setNotificationPendingIntent (PendingIntent notificationPendingIntent)

Sets a PendingIntent that will be executed when the default notification is clicked. If a custom notification is used, this value should not be provided.

Parameters
notificationPendingIntent The PendingIntent that will be executed when the default notification is clicked.