Alert


@CarProtocol
@RequiresCarApi(value = 5)
class Alert


Represents an alert with an optional icon, subtitle and actions.

Summary

Nested types

A builder of Alert.

Constants

const Int

By setting the alert duration to this value, the progress bar (timer) on the alert will not be shown.

Public functions

Boolean
equals(other: Any?)
(Mutable)List<Action!>

Returns the List of Actions associated with the alert.

AlertCallbackDelegate?

Returns the AlertCallbackDelegate that should be used for this alert.

Long

Returns the maximum duration in milli seconds for which the alert can be shown.

CarIcon?

Returns the CarIcon to display in the alert or null if the alert does not have an icon.

Int

Returns the id of the alert.

CarText?

Returns the subtitle displayed in the alert or null if the alert does not have a subtitle.

CarText

Returns the title displayed in the alert.

Int
String

Constants

SHOW_ALERT_INDEFINITELY_DURATION

Added in 1.7.0-alpha02
const val SHOW_ALERT_INDEFINITELY_DURATION = 2147483647: Int

By setting the alert duration to this value, the progress bar (timer) on the alert will not be shown.

Public functions

equals

fun equals(other: Any?): Boolean

getActions

Added in 1.2.0
fun getActions(): (Mutable)List<Action!>

Returns the List of Actions associated with the alert.

See also
addAction

getCallbackDelegate

Added in 1.2.0
fun getCallbackDelegate(): AlertCallbackDelegate?

Returns the AlertCallbackDelegate that should be used for this alert.

See also
Alert.Builder

getDurationMillis

Added in 1.2.0
fun getDurationMillis(): Long

Returns the maximum duration in milli seconds for which the alert can be shown.

getIcon

Added in 1.2.0
fun getIcon(): CarIcon?

Returns the CarIcon to display in the alert or null if the alert does not have an icon.

See also
setIcon

getId

Added in 1.2.0
fun getId(): Int

Returns the id of the alert.

getSubtitle

Added in 1.2.0
fun getSubtitle(): CarText?

Returns the subtitle displayed in the alert or null if the alert does not have a subtitle.

See also
setSubtitle

getTitle

Added in 1.2.0
fun getTitle(): CarText

Returns the title displayed in the alert.

hashCode

fun hashCode(): Int

toString

fun toString(): String