protected function validateValueRating()
    {
        $field = 'rating';

        if ($this->isExcluded($field)) {
            return null;
        }

        $value = $this->getSubmitted($field);
        $label = $this->translation->text('Rating');

        if (!isset($value)) {
            $this->setErrorRequired($field, $label);
            return false;
        }

        if (!is_numeric($value)) {
            $this->setErrorNumeric($field, $label);
            return false;
        }

        if ($value > 5) {
            $this->setErrorInvalid($field, $label);
            return false;
        }

        return true;
    }