UpdateCheckResult


public final class UpdateCheckResult implements Parcelable


Container for the result of a security update check from a specific provider.

This class encapsulates the list of available updates along with metadata about the source and freshness of the data. It is returned by the IUpdateInfoService.listAvailableUpdates method.

Summary

Public constructors

UpdateCheckResult(
    @NonNull String providerPackageName,
    @NonNull List<@NonNull UpdateInfo> updates,
    long lastCheckTimeMillis
)

Public methods

int
boolean
equals(Object other)
final long

The timestamp of the last successful synchronization with the backend, in milliseconds since the epoch.

final @NonNull String

The package name of the application that provided these update results.

final @NonNull List<@NonNull UpdateInfo>

The list of UpdateInfo objects representing available updates found during this check.

int
@NonNull String
void
writeToParcel(@NonNull Parcel parcel, int flags)

Public fields

CREATOR

public static final @NonNull Parcelable.Creator<@NonNull UpdateCheckResultCREATOR

Public constructors

UpdateCheckResult

Added in 1.1.0-alpha01
public UpdateCheckResult(
    @NonNull String providerPackageName,
    @NonNull List<@NonNull UpdateInfo> updates,
    long lastCheckTimeMillis
)

Public methods

describeContents

Added in 1.1.0-alpha01
public int describeContents()

equals

public boolean equals(Object other)

getLastCheckTimeMillis

Added in 1.1.0-alpha01
public final long getLastCheckTimeMillis()

The timestamp of the last successful synchronization with the backend, in milliseconds since the epoch.

This field is critical for clients to understand the freshness of the result, especially when updates is empty. It allows the UI to display messages like "Last checked: 5 minutes ago" versus "Last checked: Yesterday".

getProviderPackageName

Added in 1.1.0-alpha01
public final @NonNull String getProviderPackageName()

The package name of the application that provided these update results.

This field identifies the authoritative source of the update data (e.g., "com.google.android.gms" for System Updates).

getUpdates

Added in 1.1.0-alpha01
public final @NonNull List<@NonNull UpdateInfogetUpdates()

The list of UpdateInfo objects representing available updates found during this check.

hashCode

public int hashCode()

toString

public @NonNull String toString()

writeToParcel

Added in 1.1.0-alpha01
public void writeToParcel(@NonNull Parcel parcel, int flags)