/home/techb158/immovalet.com/vendor/doctrine/dbal/src
NameSizeModeActions
ArrayParameters/-0755rm
Cache/-0755rm
Connections/-0755rm
Driver/-0755rm
Event/-0755rm
Exception/-0755rm
Id/-0755rm
Logging/-0755rm
Platforms/-0755rm
Portability/-0755rm
Query/-0755rm
Schema/-0755rm
SQL/-0755rm
Tools/-0755rm
Types/-0755rm
ColumnCase.php4290644editdlrm
Configuration.php33630644editdlrm
Connection.php579890644editdlrm
ConnectionException.php9690644editdlrm
Driver.php13790644editdlrm
DriverManager.php154450644editdlrm
Events.php11300644editdlrm
Exception.php51980644editdlrm
ExpandArrayParameters.php37030644editdlrm
FetchMode.php3310644editdlrm
LockMode.php4190644editdlrm
ParameterType.php9820644editdlrm
Query.php12220644editdlrm
Result.php84840644editdlrm
Statement.php66270644editdlrm
TransactionIsolationLevel.php6130644editdlrm
VersionAwarePlatformDriver.php9460644editdlrm
Edit: /home/techb158/immovalet.com/vendor/doctrine/dbal/src/ExpandArrayParameters.php (3703B)
|array */ private $originalParameters; /** @var array|array */ private $originalTypes; /** @var int */ private $originalParameterIndex = 0; /** @var list */ private $convertedSQL = []; /** @var list */ private $convertedParameteres = []; /** @var array */ private $convertedTypes = []; /** * @param array|array $parameters * @param array|array $types */ public function __construct(array $parameters, array $types) { $this->originalParameters = $parameters; $this->originalTypes = $types; } public function acceptPositionalParameter(string $sql): void { $index = $this->originalParameterIndex; if (! array_key_exists($index, $this->originalParameters)) { throw MissingPositionalParameter::new($index); } $this->acceptParameter($index, $this->originalParameters[$index]); $this->originalParameterIndex++; } public function acceptNamedParameter(string $sql): void { $name = substr($sql, 1); if (! array_key_exists($name, $this->originalParameters)) { throw MissingNamedParameter::new($name); } $this->acceptParameter($name, $this->originalParameters[$name]); } public function acceptOther(string $sql): void { $this->convertedSQL[] = $sql; } public function getSQL(): string { return implode('', $this->convertedSQL); } /** * @return list */ public function getParameters(): array { return $this->convertedParameteres; } /** * @param int|string $key * @param mixed $value */ private function acceptParameter($key, $value): void { if (! isset($this->originalTypes[$key])) { $this->convertedSQL[] = '?'; $this->convertedParameteres[] = $value; return; } $type = $this->originalTypes[$key]; if ($type !== Connection::PARAM_INT_ARRAY && $type !== Connection::PARAM_STR_ARRAY) { $this->appendTypedParameter([$value], $type); return; } if (count($value) === 0) { $this->convertedSQL[] = 'NULL'; return; } $this->appendTypedParameter($value, $type - Connection::ARRAY_PARAM_OFFSET); } /** * @return array */ public function getTypes(): array { return $this->convertedTypes; } /** * @param list $values * @param Type|int|string|null $type */ private function appendTypedParameter(array $values, $type): void { $this->convertedSQL[] = implode(', ', array_fill(0, count($values), '?')); $index = count($this->convertedParameteres); foreach ($values as $value) { $this->convertedParameteres[] = $value; $this->convertedTypes[$index] = $type; $index++; } } }