public function getIssuesBySeverity(string $severity): array
    {
        return array_values(array_filter($this->getIssues(), function(Issue $i) use ($severity) {
            return $i->getSeverity() === $severity;
        }));
    }
public function getIssuesBySeverity(string $severity): array
    {
        return array_values(array_filter($this->getIssues(), function(Issue $i) use ($severity) {
            return $i->getSeverity() === $severity;
        }));
    }
public function getIssuesBySeverity ( string $ severity ) : array { return array_values ( array_filter ( $ this -> getIssues ( ) , function ( Issue $ i ) use ( $ severity ) { return $ i -> getSeverity ( ) === $ severity ; } ) ) ; }
Gets all issues for this file that have a certain severity.

@param string $severity The severity. Should be one of the Issue class' SEVERITY_* constants
@return Issue[] All issues with the given severity
Gets all issues for this file that have a certain severity .