/** * @see Comparable::equals * * @since 0.7.4 * * @param mixed $target * * @return bool */ public function equals($target) { if ($this === $target) { return true; } return $target instanceof self && $this->guid === $target->guid && $this->rank === $target->rank && $this->mainSnak->equals($target->mainSnak) && $this->qualifiers->equals($target->qualifiers) && $this->references->equals($target->references); }
/** * @see Comparable::equals * * The comparison is done purely value based, ignoring the order of the snaks. * * @since 0.3 * * @param mixed $target * * @return bool */ public function equals($target) { if ($this === $target) { return true; } return $target instanceof self && $this->snaks->equals($target->snaks); }