public function equals(Name $other): bool
    {
        // if RDN count doesn't match
        if (count($this) != count($other)) {
            return false;
        }
        for ($i = count($this) - 1; $i >= 0; --$i) {
            $rdn1 = $this->_rdns[$i];
            $rdn2 = $other->_rdns[$i];
            if (!$rdn1->equals($rdn2)) {
                return false;
            }
        }
        return true;
    }
public function equals(Name $other): bool
    {
        // if RDN count doesn't match
        if (count($this) != count($other)) {
            return false;
        }
        for ($i = count($this) - 1; $i >= 0; --$i) {
            $rdn1 = $this->_rdns[$i];
            $rdn2 = $other->_rdns[$i];
            if (!$rdn1->equals($rdn2)) {
                return false;
            }
        }
        return true;
    }
public function equals ( Name $ other ) : bool { // if RDN count doesn't match if ( count ( $ this ) != count ( $ other ) ) { return false ; } for ( $ i = count ( $ this ) - 1 ; $ i >= 0 ; -- $ i ) { $ rdn1 = $ this -> _rdns [ $ i ] ; $ rdn2 = $ other -> _rdns [ $ i ] ; if ( ! $ rdn1 -> equals ( $ rdn2 ) ) { return false ; } } return true ; }
Whether name is semantically equal to other.
Comparison conforms to RFC 4518 string preparation algorithm.

@link https://tools.ietf.org/html/rfc4518
@param Name $other Object to compare to
@return bool
Whether name is semantically equal to other . Comparison conforms to RFC 4518 string preparation algorithm .