Notification.Builder.SetOnlyAlertOnce(Boolean) Method

Definition

Set this flag if you would only like the sound, vibrate and ticker to be played if the notification is not already showing.

[Android.Runtime.Register("setOnlyAlertOnce", "(Z)Landroid/app/Notification$Builder;", "GetSetOnlyAlertOnce_ZHandler")]
public virtual Android.App.Notification.Builder SetOnlyAlertOnce(bool onlyAlertOnce);
[<Android.Runtime.Register("setOnlyAlertOnce", "(Z)Landroid/app/Notification$Builder;", "GetSetOnlyAlertOnce_ZHandler")>]
abstract member SetOnlyAlertOnce : bool -> Android.App.Notification.Builder
override this.SetOnlyAlertOnce : bool -> Android.App.Notification.Builder

Parameters

onlyAlertOnce
Boolean

boolean

Returns

This Android.App.Notification.Builder instance, allowing calls to be chained.

Attributes

Remarks

Set this flag if you would only like the sound, vibrate and ticker to be played if the notification is not already showing. Note that using this flag will stop any ongoing alerting behaviour such as sound, vibration or blinking notification LED.

See also:

Android reference for android.app.Notification.Builder.setOnlyAlertOnce.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to