public function compareTo(UuidInterface $other) { $comparison = 0; if ($this->getMostSignificantBitsHex() < $other->getMostSignificantBitsHex()) { $comparison = -1; } elseif ($this->getMostSignificantBitsHex() > $other->getMostSignificantBitsHex()) { $comparison = 1; } elseif ($this->getLeastSignificantBitsHex() < $other->getLeastSignificantBitsHex()) { $comparison = -1; } elseif ($this->getLeastSignificantBitsHex() > $other->getLeastSignificantBitsHex()) { $comparison = 1; } return $comparison; }