Class: SchemaDotOrg::AggregateRating
- Inherits:
-
SchemaType
- Object
- SchemaType
- SchemaDotOrg::AggregateRating
- Defined in:
- app/models/schema_dot_org/aggregate_rating.rb
Overview
https://schema.org/AggregateRating
Helper class scoped to SchemaDotOrg.
Constant Summary
Constants inherited from SchemaType
SchemaType::ROOT_ATTR, SchemaType::UNQUALIFIED_CLASS_NAME_REGEX
Instance Attribute Summary
Attributes inherited from SchemaType
Instance Method Summary collapse
- #bestRating ⇒ Integer
- #ratingCount ⇒ Integer
-
#ratingValue ⇒ Float
Allow decimal ratings (e.g., 4.5).
- #reviewCount ⇒ Integer
- #worstRating ⇒ Integer
Methods inherited from SchemaType
#_to_json_struct, attribute, #initialize, #to_json, #to_json_ld, #to_json_struct, #to_s, #un_namespaced_classname
Constructor Details
This class inherits a constructor from SchemaDotOrg::SchemaType
Instance Method Details
#bestRating ⇒ Integer
16 |
# File 'app/models/schema_dot_org/aggregate_rating.rb', line 16 attribute :bestRating, Integer, default: 5 |
#ratingCount ⇒ Integer
14 |
# File 'app/models/schema_dot_org/aggregate_rating.rb', line 14 attribute :ratingCount, Integer |
#ratingValue ⇒ Float
Allow decimal ratings (e.g., 4.5)
Validations:
10 |
# File 'app/models/schema_dot_org/aggregate_rating.rb', line 10 attribute :ratingValue, Float |
#reviewCount ⇒ Integer
Validations:
12 |
# File 'app/models/schema_dot_org/aggregate_rating.rb', line 12 attribute :reviewCount, Integer |
#worstRating ⇒ Integer
18 |
# File 'app/models/schema_dot_org/aggregate_rating.rb', line 18 attribute :worstRating, Integer, default: 1 |