Class HeartRating

  • All Implemented Interfaces:

    public final class HeartRating
    extends Rating
    A rating expressed as "heart" or "no heart". It can be used to indicate whether the content is a favorite.
    • Constructor Detail

      • HeartRating

        public HeartRating()
        Creates a unrated instance.
      • HeartRating

        public HeartRating​(boolean isHeart)
        Creates a rated instance.
        isHeart - true for "heart", false for "no heart".
    • Method Detail

      • isRated

        public boolean isRated()
        Description copied from class: Rating
        Whether the rating exists or not.
        Specified by:
        isRated in class Rating
      • isHeart

        public boolean isHeart()
        Returns whether the rating is "heart".
      • hashCode

        public int hashCode()
        hashCode in class Object
      • equals

        public boolean equals​(@Nullable
                              Object obj)
        equals in class Object
      • toBundle

        public Bundle toBundle()
        Description copied from interface: Bundleable
        Returns a Bundle representing the information stored in this object.