PictureProfile


class PictureProfile : Parcelable
kotlin.Any
   ↳ android.media.quality.PictureProfile

Profile for picture quality.

Summary

Nested classes

A builder for PictureProfile.

Constants
static Int

Error code for creating a profile with existing profile type and name.

static Int

Error code for invalid argument.

static Int

Error code for the case when an operation requires an allowlist but the caller is not in the list.

static Int

Error code for missing necessary permission to handle the profiles.

static Int

Error code for unknown errors.

static Int

Application profile type.

static Int

System profile type.

Inherited constants
Public methods
Int

String?

Gets the input ID if the profile is for a TV input.

String

Gets the profile name.

String?

Gets the package name of this profile.

PersistableBundle

Gets the parameters of this profile.

String?

Gets profile ID.

Int

Gets profile type.

Unit
writeToParcel(dest: Parcel, flags: Int)

Properties
static Parcelable.Creator<PictureProfile!>

Constants

ERROR_DUPLICATE

static val ERROR_DUPLICATE: Int

Error code for creating a profile with existing profile type and name.

Value: 2

ERROR_INVALID_ARGUMENT

static val ERROR_INVALID_ARGUMENT: Int

Error code for invalid argument.

Value: 3

ERROR_NOT_ALLOWLISTED

static val ERROR_NOT_ALLOWLISTED: Int

Error code for the case when an operation requires an allowlist but the caller is not in the list.

Value: 4

See Also

    ERROR_NO_PERMISSION

    static val ERROR_NO_PERMISSION: Int

    Error code for missing necessary permission to handle the profiles.

    Value: 1

    ERROR_UNKNOWN

    static val ERROR_UNKNOWN: Int

    Error code for unknown errors.

    Value: 0

    TYPE_APPLICATION

    static val TYPE_APPLICATION: Int

    Application profile type.

    A profile of application type is managed by the package returned by getPackageName().

    Value: 2

    TYPE_SYSTEM

    static val TYPE_SYSTEM: Int

    System profile type.

    A profile of system type is managed by the system, and readable to the package returned by getPackageName().

    Value: 1

    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

    getInputId

    fun getInputId(): String?

    Gets the input ID if the profile is for a TV input.

    Return
    String? the corresponding TV input ID; null if the profile is not associated with a TV input.

    getName

    fun getName(): String

    Gets the profile name.

    getPackageName

    fun getPackageName(): String?

    Gets the package name of this profile.

    The package name defines the user of a profile. Only this specific package and system app can access to this profile.

    Return
    String? the package name; null if the profile is built locally using Builder and the package is not set.

    getParameters

    fun getParameters(): PersistableBundle

    Gets the parameters of this profile.

    The keys of commonly used parameters can be found in MediaQualityContract.PictureQuality.

    Return
    PersistableBundle The profile parameters. Empty bundle if parameters are not included in a query.

    getProfileId

    fun getProfileId(): String?

    Gets profile ID.

    A profile ID is a globally unique ID generated and assigned by the system. For profile objects retrieved from system (e.g MediaQualityManager.getAvailablePictureProfiles) this profile ID is non-null; For profiles built locally with Builder, it's null.

    Return
    String? the unique profile ID; null if the profile is built locally with Builder.

    getProfileType

    fun getProfileType(): Int

    Gets profile type.

    Return
    Int Value is android.media.quality.PictureProfile#TYPE_SYSTEM, or android.media.quality.PictureProfile#TYPE_APPLICATION

    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<PictureProfile!>