public function convertToPHPValue($value, AbstractPlatform $platform) { if (empty($value)) { return null; } if ($value instanceof Uuid) { return $value; } try { $uuid = Uuid::fromString($value); } catch (InvalidArgumentException $e) { throw ConversionException::conversionFailed($value, self::NAME); } return $uuid; }