public function getSummaryMessage(): string {
        if ($main = $this->getMainMessage()) {
            return $main;
        } elseif ($this->isValid()) {
            return $this->translate('Validation succeeded.');
        } else {
            return $this->translate('Validation failed.');
        }
    }