public function equals($httpVersion): bool
    {
        if (empty($httpVersion)) {
            return false;
        }

        try {
            $other = self::castFrom($httpVersion);
        } catch (\InvalidArgumentException $iae) {
            return false;
        }

        return $this->major() === $other->major() && $this->minor() === $other->minor();
    }
public function equals($httpVersion): bool
    {
        if (empty($httpVersion)) {
            return false;
        }

        try {
            $other = self::castFrom($httpVersion);
        } catch (\InvalidArgumentException $iae) {
            return false;
        }

        return $this->major() === $other->major() && $this->minor() === $other->minor();
    }
public function equals ( $ httpVersion ) : bool { if ( empty ( $ httpVersion ) ) { return false ; } try { $ other = self :: castFrom ( $ httpVersion ) ; } catch ( \ InvalidArgumentException $ iae ) { return false ; } return $ this -> major ( ) === $ other -> major ( ) && $ this -> minor ( ) === $ other -> minor ( ) ; }
checks if given http version is equal to this http version

@param   string|\stubbles\peer\http\HttpVersion  $httpVersion
@return  bool
checks if given http version is equal to this http version