Language

FrozenCalleePolicy Enum

Definition

Defines frozen callee policy values used by the Android OS API.

public enum FrozenCalleePolicy
type FrozenCalleePolicy = 
Inheritance
FrozenCalleePolicy

Fields

Name Value Description
Unset 0

Callbacks are invoked immediately regardless of the frozen state of the target process. Not recommended. Only exists for backward-compatibility. This represents the behavior up to SDK 35. Starting with SDK 36, clients should set a policy to govern callback invocations when recipients are frozen.

EnqueueAll 1

When the callback recipient's process is frozen, callbacks are enqueued so they're invoked after the recipient is unfrozen. This is commonly used when the recipient wants to receive all callbacks without losing any history, e.g. the recipient maintains a running count of events that occurred. Queued callbacks are invoked in the order they were originally broadcasted.

EnqueueMostRecent 2

When the callback recipient's process is frozen, only the most recent callback is enqueued, which is later invoked after the recipient is unfrozen. This can be used when only the most recent state matters, for instance when clients are listening to screen brightness changes.

Drop 3

When the callback recipient's process is frozen, callbacks are suppressed as if they never happened.

Remarks

Provides Android OS API values for FrozenCalleePolicy.

Java documentation for android.os.RemoteCallbackList.

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