Added in API level 30

GetWalletCardsResponse


class GetWalletCardsResponse : Parcelable
kotlin.Any
   ↳ android.service.quickaccesswallet.GetWalletCardsResponse

The response for an GetWalletCardsRequest contains a list of wallet cards and the index of the card that should initially be displayed in the 'selected' position.

Summary

Inherited constants
Public constructors
GetWalletCardsResponse(walletCards: MutableList<WalletCard!>, selectedIndex: Int)

Construct a new response.

Public methods
Int

Int

The selectedIndex represents the index of the card that should be presented in the 'selected' position when the cards are initially displayed in the quick access wallet.

MutableList<WalletCard!>

The list of WalletCards.

Unit
writeToParcel(dest: Parcel, flags: Int)

Flatten this object in to a Parcel.

Properties
static Parcelable.Creator<GetWalletCardsResponse!>

Public constructors

GetWalletCardsResponse

Added in API level 30
GetWalletCardsResponse(
    walletCards: MutableList<WalletCard!>,
    selectedIndex: Int)

Construct a new response.

Parameters
walletCards MutableList<WalletCard!>: The list of wallet cards. The list may be empty but must NOT be larger than GetWalletCardsRequest#getMaxCards(). The list may not contain null values.
selectedIndex Int: The index of the card that should be presented as the initially 'selected' card. The index must be greater than or equal to zero and less than the size of the list of walletCards (unless the list is empty in which case the value may be 0).

Public methods

describeContents

Added in API level 30
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

getSelectedIndex

Added in API level 30
fun getSelectedIndex(): Int

The selectedIndex represents the index of the card that should be presented in the 'selected' position when the cards are initially displayed in the quick access wallet. The selectedIndex should be greater than or equal to zero and less than the size of the list of walletCards, unless the list is empty in which case the selectedIndex can take any value. 0 is a nice round number for such cases.

getWalletCards

Added in API level 30
fun getWalletCards(): MutableList<WalletCard!>

The list of WalletCards. The size of this list should not exceed android.service.quickaccesswallet.GetWalletCardsRequest#getMaxCards().

Return
MutableList<WalletCard!> This value cannot be null.

writeToParcel

Added in API level 30
fun writeToParcel(
    dest: Parcel,
    flags: Int
): Unit

Flatten this object in to a Parcel.

Parameters
dest Parcel: 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

Added in API level 30
static val CREATOR: Parcelable.Creator<GetWalletCardsResponse!>