ClassifiableContent


class ClassifiableContent : Parcelable
kotlin.Any
   ↳ android.app.contentsafety.ClassifiableContent

A class representing content to be classified.

Summary

Nested classes

Builder for ClassifiableContent.

Inherited constants
Public methods
Int

Describe the kinds of special objects contained in this Parcelable instance's marshaled representation.

ParcelFileDescriptor?

Returns a ParcelFileDescriptor containing the raw data of this content.

LocusId

Returns the LocusId associated with this content.

String

Returns the MIME type of the content.

String?

Returns the package name of the app that requested the classification.

Uri?

Returns the Uri associated with this content.

Unit
writeToParcel(parcel: Parcel, flags: Int)

Flatten this object in to a Parcel.

Properties
static Parcelable.Creator<ClassifiableContent!>

Public methods

describeContents

fun describeContents(): Int

Describe the kinds of special objects contained in this Parcelable instance's marshaled representation. For example, if the object will include a file descriptor in the output of writeToParcel(Parcel,int), the return value of this method must include the CONTENTS_FILE_DESCRIPTOR bit.

Return
Int a bitmask indicating the set of special object types marshaled by this Parcelable object instance.
Value is either 0 or

getData

fun getData(): ParcelFileDescriptor?

Returns a ParcelFileDescriptor containing the raw data of this content.

Return
ParcelFileDescriptor? the ParcelFileDescriptor containing the content data, or null if the raw content isn't provided

getId

fun getId(): LocusId

Returns the LocusId associated with this content.

Return
LocusId the LocusId of the content.
This value cannot be null.

getMimeType

fun getMimeType(): String

Returns the MIME type of the content.

Return
String the MIME type.
This value cannot be null.

getOriginatingPackageName

fun getOriginatingPackageName(): String?

Returns the package name of the app that requested the classification.

Return
String? the originating package name, or null if the originating package is unknown or not provided

getUri

fun getUri(): Uri?

Returns the Uri associated with this content.

Return
Uri? the content Uri, or null if this content is not associated with a Uri

writeToParcel

fun writeToParcel(
    parcel: Parcel,
    flags: Int
): Unit

Flatten this object in to a Parcel.

Parameters
dest The Parcel in which the object should be written.
This value cannot be null.
flags Int: Value is either 0 or a combination of the following:
parcel Parcel: This value cannot be null.

Properties

CREATOR

static val CREATOR: Parcelable.Creator<ClassifiableContent!>