Пример #1
0
 /**
  * This method compares two URLs and check if they are equal.
  *
  * @param Customweb_Http_Url $url
  * @return boolean Equal or not
  */
 public function equals(Customweb_Http_Url $url)
 {
     return $this->__toString() == $url->__toString();
 }
Пример #2
0
 /**
  * This method compares two URLs and check if they are equal.
  *
  * @param Customweb_Http_Url $url
  * @return boolean Equal or not
  */
 public function equals($url)
 {
     if (!($url instanceof Customweb_Core_Url || $url instanceof Customweb_Http_Url)) {
         throw new InvalidArgumentException("Expects that the parameter for equals must be of type 'Customweb_Core_Url'.");
     }
     return $this->__toString() == $url->__toString();
 }