Evaluates the constraint for parameter $other. Returns true if the
constraint is met, false otherwise.

@param array|ResponseSection|ResponseSection[] $other ResponseSections to evaluate
@return bool
339192
protected function matches($other): bool
    {
        if (is_array($other)) {
            $success = null;
            foreach ($other as $item) {
                $currentSuccess = $this->matchesSection($item);
                $success = ($success === null ? $currentSuccess : $success || $currentSuccess);
            }
            return !empty($success);
        } else {
            return $this->matchesSection($other);
        }
    }
68904
public function equals($other): bool
    {
        if (is_array($other) || $other instanceof self) {
            return count($other) === count($this) &&
                $this->zip($other)->every(
                    function ($tuple) {
                        list($a, $b) = $tuple;

                        if ($a instanceof Equalable) {
                            return $a->equals($b);
                        }

                        return $a === $b;
                    }
                );
        }

        throw new \InvalidArgumentException('`$other` must be `Seq` or `array`');
    }
677980
public function Compare($other)
	{
	    switch ( $other->GetValueCode() )
	    {
	        case SByteProxyFactory::Code:
	            return 0;

	        case ByteProxyFactory::Code:
	        case UShortProxyFactory::Code:
	        case UIntProxyFactory::Code:
	        case ULongProxyFactory::Code:
	        case ShortProxyFactory::Code:
	        case IntProxyFactory::Code:
	        case LongProxyFactory::Code:
	        case IntegerProxyFactory::Code:
	        case DecimalProxyFactory::Code:
	        case FloatProxyFactory::Code:
	        case DoubleProxyFactory::Code:
	            return -1;

	        default:
	            return -2;
	    }
	}
1247828
public function equals(LatLngBounds $other)
    {
        if (!$this->getNorthEast()->equals($other->getNorthEast())) {
            return false;
        }

        return $this->getSouthWest()->equals($other->getSouthWest());
    }
1026977
public function equals(GeneralName $other): bool
    {
        if ($this->_tag != $other->_tag) {
            return false;
        }
        if ($this->_choiceASN1()->toDER() != $other->_choiceASN1()->toDER()) {
            return false;
        }
        return true;
    }
175654
public function lessThanOrEqual($other)
    {
        $this->doCheck(function ($value) use ($other) {
            $this->throwExceptionIfFalse(
                $value <= $other,
                'Failed assertion that %s is less than %s', $value, $other
            );
        });

        return $this;
    }
1244483
public function equals(DateTimeBase $other) : bool
    {
        $dateTime      = $this->dateTime;
        $otherDateTime = $other->dateTime;

        return $dateTime == $otherDateTime
                && $dateTime->getTimezone()->getName() === $otherDateTime->getTimezone()->getName();
    }
11494
public function compareTo($other): bool {
        if(!($other instanceof $this)) {
            return FALSE;
        }
        if($this->getHost() !== $other->getHost()) {
            return FALSE;
        }
        if($this->getPort() !== $other->getPort()) {
            return FALSE;
        }
        return TRUE;
    }
1080597
public function compareTo($other)
    {
        if ($other === null) {
            return false;
        }
        if (!($other instanceof SubExpressionNode)) {
            return false;
        }

        return $this->getValue() == $other->getValue();
    }
492422
public function isSuperset(EnumSet $other): bool
    {
        return $this->enumeration === $other->enumeration
            && ($this->bitset | $other->bitset) === $this->bitset;
    }
1155639
public function crosses(Geometry $other): bool {
        $event = new SpatialRelationshipOpEvent($this, ['other' => $other]);
        $this->fireOperationEvent(SpatialRelationshipOpEvent::CROSSES_EVENT, $event);
        return $event->getResults();
    }
238043
private function samePartialIndex(Index $other)
    {
        if ($this->hasOption('where') && $other->hasOption('where') && $this->getOption('where') === $other->getOption('where')) {
            return true;
        }

        return ! $this->hasOption('where') && ! $other->hasOption('where');
    }
365657
public function equals($other) {
		if ($other instanceof UrlQuery) {
			return ($this->isEmpty() && $other->isEmpty()) || ($this->__toString() === $other->__toString() );
		}
		if (is_null($other)) {
			return $this->isEmpty();
		}
		return false;
	}
306232
public function equals($other)
    {
        if (!($other instanceof self)) {
            $other = new BigInt($other);
        }
        return ($this->compare($other) === 0);
    }
53845
public function equals(ColumnDefaultValue $other)
    {
        if ($this->getType() != $other->getType()) {
            return false;
        }
        if ($this == $other) {
            return true;
        }
        // special case for current timestamp
        $equivalents = array('CURRENT_TIMESTAMP', 'NOW()');
        if (in_array(strtoupper($this->getValue()), $equivalents) && in_array(strtoupper($other->getValue()), $equivalents)) {
            return true;
        }

        return false; // Can't help, they are different
    }
596352
public function compareTo($other)
    {
        if ($other === null) {
            return false;
        }
        if (!($other instanceof FunctionNode)) {
            return false;
        }

        $thisOperand = $this->getOperand();
        $otherOperand = $other->getOperand();

        return $this->getName() == $other->getName() && $thisOperand->compareTo($otherOperand);
    }
242713
public function isEqualTo(ValueHolderInterface $other_value_holder)
    {
        if (get_class($this) !== get_class($other_value_holder)) {
            return false;
        }

        return $this->sameValueAs($other_value_holder->getValue());
    }