Class MusicBrainz::Model::Rating
In: lib/rbrainz/model/rating.rb
Parent: Object

Represents a rating of an entity.

MusicBrainz allows it‘s users to rate artists, labels, releases and tracks. Each user rating will be a Float between 1 and 5 or nil, where nil means no rating. The system will aggregate user ratings to compute the average community rating.

See:wiki.musicbrainz.org/RatingSystem

Methods

empty?   new   to_f   to_i   to_s  

Attributes

count  [RW]  The rating count indicating how often entity was rated.
value  [RW]  The rating (an Float between 1 and 5). If :count is greater than 1 this will be the average rating.

Public Class methods

Public Instance methods

Tests if this rating is empty

Convert this rating into a Float. Will return rating.

Convert this rating into an Integer. Will return rating.

Convert this rating into a String. Will return rating.

[Validate]