public function __construct(string $id, $value) { $this->id = $id; if ($value instanceof self) { throw InvalidArgumentExceptionFactory::createForRedundantUniqueValue($id); } $this->value = deep_clone($value); }