WallpaperInstance


class WallpaperInstance : Parcelable
kotlin.Any
   ↳ android.app.wallpaper.WallpaperInstance

Describes a wallpaper that has been set as a current wallpaper.

This class is used by android.app.WallpaperManager to store information about a wallpaper that is currently in use. Because it has been set as an active wallpaper it offers some guarantees that WallpaperDescription does not:

Summary

Inherited constants
Public constructors

Create a WallpaperInstance for the wallpaper given by WallpaperDescription.

Public methods
Int

Boolean
equals(other: Any?)

WallpaperDescription

String

See WallpaperDescription.Builder.getId() for rules about id uniqueness.

WallpaperInfo?

Int

Unit
writeToParcel(dest: Parcel, flags: Int)

Properties
static Parcelable.Creator<WallpaperInstance!>

Public constructors

WallpaperInstance

WallpaperInstance(
    info: WallpaperInfo?,
    description: WallpaperDescription)

Create a WallpaperInstance for the wallpaper given by WallpaperDescription.

Parameters
info WallpaperInfo?: the live wallpaper info for this wallpaper, or null if static
description WallpaperDescription: description of the wallpaper for this instance

Public methods

describeContents

fun describeContents(): Int
Return
Int a bitmask indicating the set of special object types marshaled by this Parcelable object instance. Value is either 0 or android.os.Parcelable#CONTENTS_FILE_DESCRIPTOR

equals

fun equals(other: Any?): Boolean
Parameters
obj the reference object with which to compare.
Return
Boolean true if this object is the same as the obj argument; false otherwise.

getDescription

fun getDescription(): WallpaperDescription
Return
WallpaperDescription the description for this wallpaper

getId

fun getId(): String

See WallpaperDescription.Builder.getId() for rules about id uniqueness.

Return
String the ID of the wallpaper instance if given by the wallpaper description, otherwise a default value

getInfo

fun getInfo(): WallpaperInfo?
Return
WallpaperInfo? the live wallpaper info, or null if static

hashCode

fun hashCode(): Int
Return
Int a hash code value for this object.

writeToParcel

fun writeToParcel(
    dest: Parcel,
    flags: Int
): Unit
Parameters
dest Parcel: The Parcel in which the object should be written. This value cannot be null.
flags Int: Additional flags about how the object should be written. May be 0 or PARCELABLE_WRITE_RETURN_VALUE. Value is either 0 or a combination of android.os.Parcelable#PARCELABLE_WRITE_RETURN_VALUE, and android.os.Parcelable.PARCELABLE_ELIDE_DUPLICATES

Properties

CREATOR

static val CREATOR: Parcelable.Creator<WallpaperInstance!>