public function matches($expr)
    {
        $params = self::parseEventExpr($expr);

        if ($params['topic'] === '*') {
            return true;
        } elseif ($this->topic !== $params['topic']) {
            return false;
        }

        if ($params['event'] === '*') {
            return true;
        } elseif ($this->name !== $params['event']) {
            return false;
        }

        if ($params['version'] === '*') {
            return true;
        } else {
            return Semver::satisfies($this->version, $params['version']);
        }
    }