1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
<?php
/**
* @author @jenschude <jens.schulze@commercetools.de>
*/
namespace Commercetools\Core\Model\Review;
use Commercetools\Core\Model\Common\JsonObject;
/**
* @package Commercetools\Core\Model\Review
* @link https://docs.commercetools.com/http-api-projects-reviews.html#reviewratingstatistics
* @method float getAverageRating()
* @method ReviewRatingStatistics setAverageRating(float $averageRating = null)
* @method float getHighestRating()
* @method ReviewRatingStatistics setHighestRating(float $highestRating = null)
* @method float getLowestRating()
* @method ReviewRatingStatistics setLowestRating(float $lowestRating = null)
* @method int getCount()
* @method ReviewRatingStatistics setCount(int $count = null)
* @method array getRatingsDistribution()
* @method ReviewRatingStatistics setRatingsDistribution(array $ratingsDistribution = null)
*/
class ReviewRatingStatistics extends JsonObject
{
public function fieldDefinitions()
{
return [
'averageRating' => [static::TYPE => 'float'],
'highestRating' => [static::TYPE => 'float'],
'lowestRating' => [static::TYPE => 'float'],
'count' => [static::TYPE => 'int'],
'ratingsDistribution' => [static::TYPE => 'array'],
];
}
}