AlertCallback


@CarProtocol
@RequiresCarApi(value = 5)
public interface AlertCallback


A listener of dismiss events.

Summary

Constants

default static final int

Indicates the cancellation is due to the request not being supported, e.g. when current template cannot display the alert.

default static final int

Indicates the cancellation is due to timeout.

default static final int

Indicates the cancellation is due to user generated action, e.g. close button being pressed.

Public methods

abstract void
onCancel(int reason)

Notifies that a cancel event happened with given reason.

abstract void

Notifies that a dismiss happened.

Constants

REASON_NOT_SUPPORTED

Added in 1.2.0
default static final int REASON_NOT_SUPPORTED = 3

Indicates the cancellation is due to the request not being supported, e.g. when current template cannot display the alert.

REASON_TIMEOUT

Added in 1.2.0
default static final int REASON_TIMEOUT = 1

Indicates the cancellation is due to timeout.

REASON_USER_ACTION

Added in 1.2.0
default static final int REASON_USER_ACTION = 2

Indicates the cancellation is due to user generated action, e.g. close button being pressed.

Public methods

onCancel

Added in 1.2.0
abstract void onCancel(int reason)

Notifies that a cancel event happened with given reason.

onDismiss

Added in 1.2.0
abstract void onDismiss()

Notifies that a dismiss happened.