Skip to content

Commit e232bd6

Browse files
committed
fix cs
1 parent 2b30d73 commit e232bd6

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

src/ArrayBuilder.php

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,32 @@
22

33
namespace Utilitte\Php;
44

5+
// phpcs:ignoreFile -- cs bug
6+
57
final class ArrayBuilder
68
{
79

10+
/** @var mixed[] */
811
private array $values = [];
912

1013
public static function create(): self
1114
{
1215
return new self();
1316
}
1417

18+
/**
19+
* @param mixed[] $values
20+
*/
1521
public function setValues(array $values): self
1622
{
1723
$this->values = $values;
1824

1925
return $this;
2026
}
2127

28+
/**
29+
* @param mixed $values
30+
*/
2231
public function addSkipIfEmpty(string $key, $values): self
2332
{
2433
if (!empty($values)) {
@@ -28,6 +37,9 @@ public function addSkipIfEmpty(string $key, $values): self
2837
return $this;
2938
}
3039

40+
/**
41+
* @param mixed $values
42+
*/
3143
public function addSkipIf(string $key, $values, bool $skip): self
3244
{
3345
if (!$skip) {
@@ -37,6 +49,9 @@ public function addSkipIf(string $key, $values, bool $skip): self
3749
return $this;
3850
}
3951

52+
/**
53+
* @param mixed $values
54+
*/
4055
public function appendSkipIf($values, bool $skip): self
4156
{
4257
if (!$skip) {
@@ -46,20 +61,29 @@ public function appendSkipIf($values, bool $skip): self
4661
return $this;
4762
}
4863

64+
/**
65+
* @param mixed $values
66+
*/
4967
public function append($values): self
5068
{
5169
$this->values[] = $values;
5270

5371
return $this;
5472
}
5573

74+
/**
75+
* @param mixed $values
76+
*/
5677
public function add(string $key, $values): self
5778
{
5879
$this->values[$key] = $values;
5980

6081
return $this;
6182
}
6283

84+
/**
85+
* @return mixed[]
86+
*/
6387
public function getResult(): array
6488
{
6589
return $this->values;

0 commit comments

Comments
 (0)