Rx\Timestamped::equals PHP Метод

equals() публичный Метод

public equals ( $other )
    public function equals($other)
    {
        if ($this === $other) {
            return true;
        }
        if (!$other instanceof Timestamped) {
            return false;
        }
        if ($this->getTimestampMillis() !== $other->getTimestampMillis()) {
            return false;
        }
        if (is_scalar($this->value) && $this->value == $other->value) {
            return true;
        }
        if ($this->value === $other->value) {
            return true;
        }
        return false;
    }