class HeartRating : Rating


A rating expressed as "heart" or "no heart". It can be used to indicate whether the content is a favorite.

Summary

Constants

const Bundleable.Creator<HeartRating!>!

This property is deprecated.

Use fromBundle instead.

Public constructors

Creates a unrated instance.

HeartRating(isHeart: Boolean)

Creates a rated instance.

Public functions

Boolean
equals(obj: Any?)
java-static HeartRating!

Restores a HeartRating from a Bundle.

Int
Boolean

Whether the rating exists or not.

Bundle!

Returns a Bundle representing the information stored in this object.

Public properties

Boolean

Inherited Constants

From androidx.media3.common.Rating
const Bundleable.Creator<Rating!>!

This property is deprecated.

Use fromBundle instead.

Inherited functions

From androidx.media3.common.Rating
java-static Rating!

Restores a Rating from a Bundle.

Constants

CREATOR

@UnstableApi
const val CREATORBundleable.Creator<HeartRating!>!

Object that can restore a HeartRating from a Bundle.

Public constructors

HeartRating

HeartRating()

Creates a unrated instance.

HeartRating

HeartRating(isHeart: Boolean)

Creates a rated instance.

Parameters
isHeart: Boolean

true for "heart", false for "no heart".

Public functions

equals

fun equals(obj: Any?): Boolean

fromBundle

@UnstableApi
java-static fun fromBundle(bundle: Bundle!): HeartRating!

Restores a HeartRating from a Bundle.

hashCode

fun hashCode(): Int

isRated

fun isRated(): Boolean

Whether the rating exists or not.

toBundle

@UnstableApi
fun toBundle(): Bundle!

Returns a Bundle representing the information stored in this object.

Public properties

isHeart

val isHeartBoolean