/** * @param Condition $condition * @return bool */ public function equalsTo($condition) { if ($this === $condition) { return true; } $className = __CLASS__; if (!$condition instanceof $className) { return false; } return $this->getName() == $condition->getName(); }
/** * @param Condition|IsAjax $condition * @return bool */ public function equalsTo($condition) { if (!parent::equalsTo($condition)) { return false; } return $this->isAjax() === $condition->isAjax(); }
/** * @param Condition|Method $condition * @return bool */ public function equalsTo($condition) { if (!parent::equalsTo($condition)) { return false; } return $this->methods == $condition->getMethods(); }