@@ -348,7 +348,7 @@ discard block |
||
348 | 348 | /** |
349 | 349 | * @phpstan-return \Generator<TKey,T> $generator |
350 | 350 | */ |
351 | - $generator = function () use ($key, $value): \Generator { |
|
351 | + $generator = function() use ($key, $value): \Generator { |
|
352 | 352 | if ($this->properties !== []) { |
353 | 353 | $this->checkType($key, $value); |
354 | 354 | } |
@@ -537,7 +537,7 @@ discard block |
||
537 | 537 | |
538 | 538 | /** @phpstan-var \Arrayy\ArrayyRewindableGenerator<TKey,T> */ |
539 | 539 | $generatorTmp = new ArrayyRewindableExtendedGenerator( |
540 | - static function () use ($generator): \Generator { |
|
540 | + static function() use ($generator): \Generator { |
|
541 | 541 | yield from $generator; |
542 | 542 | }, |
543 | 543 | null, |
@@ -749,7 +749,7 @@ discard block |
||
749 | 749 | */ |
750 | 750 | $this->callAtPath( |
751 | 751 | $containerPath, |
752 | - static function ($container) use ($lastOffset, &$offsetExists) { |
|
752 | + static function($container) use ($lastOffset, &$offsetExists) { |
|
753 | 753 | $offsetExists = \array_key_exists($lastOffset, $container); |
754 | 754 | } |
755 | 755 | ); |
@@ -857,7 +857,7 @@ discard block |
||
857 | 857 | */ |
858 | 858 | $this->callAtPath( |
859 | 859 | \implode($this->pathSeparator, $path), |
860 | - static function (&$offset) use ($pathToUnset) { |
|
860 | + static function(&$offset) use ($pathToUnset) { |
|
861 | 861 | if (\is_array($offset)) { |
862 | 862 | unset($offset[$pathToUnset]); |
863 | 863 | } else { |
@@ -913,7 +913,7 @@ discard block |
||
913 | 913 | |
914 | 914 | if (\strpos($iteratorClass, '\\') === 0) { |
915 | 915 | /** @var class-string<\Arrayy\ArrayyIterator<TKey,T>> $iteratorClass */ |
916 | - $iteratorClass = '\\' . $iteratorClass; |
|
916 | + $iteratorClass = '\\'.$iteratorClass; |
|
917 | 917 | if (\class_exists($iteratorClass)) { |
918 | 918 | /** |
919 | 919 | * @psalm-suppress PropertyTypeCoercion |
@@ -924,7 +924,7 @@ discard block |
||
924 | 924 | } |
925 | 925 | } |
926 | 926 | |
927 | - throw new \InvalidArgumentException('The iterator class does not exist: ' . $iteratorClass); |
|
927 | + throw new \InvalidArgumentException('The iterator class does not exist: '.$iteratorClass); |
|
928 | 928 | } |
929 | 929 | |
930 | 930 | /** |
@@ -1106,13 +1106,13 @@ discard block |
||
1106 | 1106 | |
1107 | 1107 | foreach ($this->getGenerator() as $key => $item) { |
1108 | 1108 | if ($item instanceof self) { |
1109 | - $result[$prefix . $key] = $item->appendToEachKey($prefix); |
|
1109 | + $result[$prefix.$key] = $item->appendToEachKey($prefix); |
|
1110 | 1110 | } elseif (\is_array($item)) { |
1111 | - $result[$prefix . $key] = self::create($item, $this->iteratorClass, false) |
|
1111 | + $result[$prefix.$key] = self::create($item, $this->iteratorClass, false) |
|
1112 | 1112 | ->appendToEachKey($prefix) |
1113 | 1113 | ->toArray(); |
1114 | 1114 | } else { |
1115 | - $result[$prefix . $key] = $item; |
|
1115 | + $result[$prefix.$key] = $item; |
|
1116 | 1116 | } |
1117 | 1117 | } |
1118 | 1118 | |
@@ -1147,7 +1147,7 @@ discard block |
||
1147 | 1147 | } elseif (\is_object($item) === true) { |
1148 | 1148 | $result[$key] = $item; |
1149 | 1149 | } else { |
1150 | - $result[$key] = $prefix . $item; |
|
1150 | + $result[$key] = $prefix.$item; |
|
1151 | 1151 | } |
1152 | 1152 | } |
1153 | 1153 | |
@@ -1332,7 +1332,7 @@ discard block |
||
1332 | 1332 | public function chunk($size, $preserveKeys = false): self |
1333 | 1333 | { |
1334 | 1334 | if ($preserveKeys) { |
1335 | - $generator = function () use ($size) { |
|
1335 | + $generator = function() use ($size) { |
|
1336 | 1336 | $values = []; |
1337 | 1337 | $tmpCounter = 0; |
1338 | 1338 | foreach ($this->getGenerator() as $key => $value) { |
@@ -1352,7 +1352,7 @@ discard block |
||
1352 | 1352 | } |
1353 | 1353 | }; |
1354 | 1354 | } else { |
1355 | - $generator = function () use ($size) { |
|
1355 | + $generator = function() use ($size) { |
|
1356 | 1356 | $values = []; |
1357 | 1357 | $tmpCounter = 0; |
1358 | 1358 | foreach ($this->getGenerator() as $value) { |
@@ -1396,7 +1396,7 @@ discard block |
||
1396 | 1396 | public function clean(): self |
1397 | 1397 | { |
1398 | 1398 | return $this->filter( |
1399 | - static function ($value) { |
|
1399 | + static function($value) { |
|
1400 | 1400 | return (bool) $value; |
1401 | 1401 | } |
1402 | 1402 | ); |
@@ -1777,9 +1777,9 @@ discard block |
||
1777 | 1777 | |
1778 | 1778 | foreach ($items as $key => $value) { |
1779 | 1779 | if (\is_array($value) && $value !== []) { |
1780 | - $flatten[] = $this->flatten($delimiter, $prepend . $key . $delimiter, $value); |
|
1780 | + $flatten[] = $this->flatten($delimiter, $prepend.$key.$delimiter, $value); |
|
1781 | 1781 | } else { |
1782 | - $flatten[] = [$prepend . $key => $value]; |
|
1782 | + $flatten[] = [$prepend.$key => $value]; |
|
1783 | 1783 | } |
1784 | 1784 | } |
1785 | 1785 | |
@@ -1964,7 +1964,7 @@ discard block |
||
1964 | 1964 | */ |
1965 | 1965 | \array_walk( |
1966 | 1966 | $array, |
1967 | - static function (&$val) { |
|
1967 | + static function(&$val) { |
|
1968 | 1968 | if ((string) $val === $val) { |
1969 | 1969 | $val = \trim($val); |
1970 | 1970 | } |
@@ -2200,7 +2200,7 @@ discard block |
||
2200 | 2200 | $array = $array[0]; |
2201 | 2201 | } |
2202 | 2202 | |
2203 | - $generator = function () use ($array): \Generator { |
|
2203 | + $generator = function() use ($array): \Generator { |
|
2204 | 2204 | foreach ($this->getGenerator() as $key => $value) { |
2205 | 2205 | if (\in_array($value, $array, true) === false) { |
2206 | 2206 | yield $key => $value; |
@@ -2235,7 +2235,7 @@ discard block |
||
2235 | 2235 | $array = $array[0]; |
2236 | 2236 | } |
2237 | 2237 | |
2238 | - $generator = function () use ($array): \Generator { |
|
2238 | + $generator = function() use ($array): \Generator { |
|
2239 | 2239 | foreach ($this->getGenerator() as $key => $value) { |
2240 | 2240 | if (\array_key_exists($key, $array) === false) { |
2241 | 2241 | yield $key => $value; |
@@ -2270,7 +2270,7 @@ discard block |
||
2270 | 2270 | $array = $array[0]; |
2271 | 2271 | } |
2272 | 2272 | |
2273 | - $generator = function () use ($array): \Generator { |
|
2273 | + $generator = function() use ($array): \Generator { |
|
2274 | 2274 | foreach ($this->getGenerator() as $key => $value) { |
2275 | 2275 | $isset = isset($array[$key]); |
2276 | 2276 | |
@@ -2579,7 +2579,7 @@ discard block |
||
2579 | 2579 | } |
2580 | 2580 | |
2581 | 2581 | if ($flag === \ARRAY_FILTER_USE_KEY) { |
2582 | - $generator = function () use ($closure) { |
|
2582 | + $generator = function() use ($closure) { |
|
2583 | 2583 | foreach ($this->getGenerator() as $key => $value) { |
2584 | 2584 | if ($closure($key) === true) { |
2585 | 2585 | yield $key => $value; |
@@ -2591,7 +2591,7 @@ discard block |
||
2591 | 2591 | /** @phpstan-var \Closure(T,TKey):bool $closure */ |
2592 | 2592 | $closure = $closure; |
2593 | 2593 | |
2594 | - $generator = function () use ($closure) { |
|
2594 | + $generator = function() use ($closure) { |
|
2595 | 2595 | foreach ($this->getGenerator() as $key => $value) { |
2596 | 2596 | if ($closure($value, $key) === true) { |
2597 | 2597 | yield $key => $value; |
@@ -2599,7 +2599,7 @@ discard block |
||
2599 | 2599 | } |
2600 | 2600 | }; |
2601 | 2601 | } else { |
2602 | - $generator = function () use ($closure) { |
|
2602 | + $generator = function() use ($closure) { |
|
2603 | 2603 | foreach ($this->getGenerator() as $key => $value) { |
2604 | 2604 | if ($closure($value) === true) { |
2605 | 2605 | yield $key => $value; |
@@ -2655,40 +2655,40 @@ discard block |
||
2655 | 2655 | } |
2656 | 2656 | |
2657 | 2657 | $ops = [ |
2658 | - 'eq' => static function ($item, $prop, $value): bool { |
|
2658 | + 'eq' => static function($item, $prop, $value): bool { |
|
2659 | 2659 | return $item[$prop] === $value; |
2660 | 2660 | }, |
2661 | - 'gt' => static function ($item, $prop, $value): bool { |
|
2661 | + 'gt' => static function($item, $prop, $value): bool { |
|
2662 | 2662 | return $item[$prop] > $value; |
2663 | 2663 | }, |
2664 | - 'ge' => static function ($item, $prop, $value): bool { |
|
2664 | + 'ge' => static function($item, $prop, $value): bool { |
|
2665 | 2665 | return $item[$prop] >= $value; |
2666 | 2666 | }, |
2667 | - 'gte' => static function ($item, $prop, $value): bool { |
|
2667 | + 'gte' => static function($item, $prop, $value): bool { |
|
2668 | 2668 | return $item[$prop] >= $value; |
2669 | 2669 | }, |
2670 | - 'lt' => static function ($item, $prop, $value): bool { |
|
2670 | + 'lt' => static function($item, $prop, $value): bool { |
|
2671 | 2671 | return $item[$prop] < $value; |
2672 | 2672 | }, |
2673 | - 'le' => static function ($item, $prop, $value): bool { |
|
2673 | + 'le' => static function($item, $prop, $value): bool { |
|
2674 | 2674 | return $item[$prop] <= $value; |
2675 | 2675 | }, |
2676 | - 'lte' => static function ($item, $prop, $value): bool { |
|
2676 | + 'lte' => static function($item, $prop, $value): bool { |
|
2677 | 2677 | return $item[$prop] <= $value; |
2678 | 2678 | }, |
2679 | - 'ne' => static function ($item, $prop, $value): bool { |
|
2679 | + 'ne' => static function($item, $prop, $value): bool { |
|
2680 | 2680 | return $item[$prop] !== $value; |
2681 | 2681 | }, |
2682 | - 'contains' => static function ($item, $prop, $value): bool { |
|
2682 | + 'contains' => static function($item, $prop, $value): bool { |
|
2683 | 2683 | return \in_array($item[$prop], (array) $value, true); |
2684 | 2684 | }, |
2685 | - 'notContains' => static function ($item, $prop, $value): bool { |
|
2685 | + 'notContains' => static function($item, $prop, $value): bool { |
|
2686 | 2686 | return !\in_array($item[$prop], (array) $value, true); |
2687 | 2687 | }, |
2688 | - 'newer' => static function ($item, $prop, $value): bool { |
|
2688 | + 'newer' => static function($item, $prop, $value): bool { |
|
2689 | 2689 | return \strtotime($item[$prop]) > \strtotime($value); |
2690 | 2690 | }, |
2691 | - 'older' => static function ($item, $prop, $value): bool { |
|
2691 | + 'older' => static function($item, $prop, $value): bool { |
|
2692 | 2692 | return \strtotime($item[$prop]) < \strtotime($value); |
2693 | 2693 | }, |
2694 | 2694 | ]; |
@@ -2696,7 +2696,7 @@ discard block |
||
2696 | 2696 | $result = \array_values( |
2697 | 2697 | \array_filter( |
2698 | 2698 | $this->toArray(false, true), |
2699 | - static function ($item) use ( |
|
2699 | + static function($item) use ( |
|
2700 | 2700 | $property, |
2701 | 2701 | $value, |
2702 | 2702 | $ops, |
@@ -2926,7 +2926,7 @@ discard block |
||
2926 | 2926 | */ |
2927 | 2927 | public function flip(): self |
2928 | 2928 | { |
2929 | - $generator = function (): \Generator { |
|
2929 | + $generator = function(): \Generator { |
|
2930 | 2930 | foreach ($this->getGenerator() as $key => $value) { |
2931 | 2931 | yield (string) $value => $key; |
2932 | 2932 | } |
@@ -3203,9 +3203,9 @@ discard block |
||
3203 | 3203 | $jsonObject = \json_decode($json, false); |
3204 | 3204 | |
3205 | 3205 | $mapper = new \Arrayy\Mapper\Json(); |
3206 | - $mapper->undefinedPropertyHandler = static function ($object, $key, $jsonValue) use ($class) { |
|
3206 | + $mapper->undefinedPropertyHandler = static function($object, $key, $jsonValue) use ($class) { |
|
3207 | 3207 | if ($class->checkPropertiesMismatchInConstructor) { |
3208 | - throw new \TypeError('Property mismatch - input: ' . \print_r(['key' => $key, 'jsonValue' => $jsonValue], true) . ' for object: ' . \get_class($object)); |
|
3208 | + throw new \TypeError('Property mismatch - input: '.\print_r(['key' => $key, 'jsonValue' => $jsonValue], true).' for object: '.\get_class($object)); |
|
3209 | 3209 | } |
3210 | 3210 | }; |
3211 | 3211 | |
@@ -3273,13 +3273,13 @@ discard block |
||
3273 | 3273 | public function getColumn($columnKey = null, $indexKey = null): self |
3274 | 3274 | { |
3275 | 3275 | if ($columnKey === null && $indexKey === null) { |
3276 | - $generator = function () { |
|
3276 | + $generator = function() { |
|
3277 | 3277 | foreach ($this->getGenerator() as $value) { |
3278 | 3278 | yield $value; |
3279 | 3279 | } |
3280 | 3280 | }; |
3281 | 3281 | } else { |
3282 | - $generator = function () use ($columnKey, $indexKey) { |
|
3282 | + $generator = function() use ($columnKey, $indexKey) { |
|
3283 | 3283 | foreach ($this->getGenerator() as $value) { |
3284 | 3284 | // reset |
3285 | 3285 | $newKey = null; |
@@ -3596,7 +3596,7 @@ discard block |
||
3596 | 3596 | |
3597 | 3597 | if ($UN_FOUND === null) { |
3598 | 3598 | // Generate unique string to use as marker. |
3599 | - $UN_FOUND = 'arrayy--' . \uniqid('arrayy', true); |
|
3599 | + $UN_FOUND = 'arrayy--'.\uniqid('arrayy', true); |
|
3600 | 3600 | } |
3601 | 3601 | |
3602 | 3602 | if (\is_array($key)) { |
@@ -3648,7 +3648,7 @@ discard block |
||
3648 | 3648 | */ |
3649 | 3649 | public function implode(string $glue = '', string $prefix = ''): string |
3650 | 3650 | { |
3651 | - return $prefix . $this->implode_recursive($glue, $this->toArray(), false); |
|
3651 | + return $prefix.$this->implode_recursive($glue, $this->toArray(), false); |
|
3652 | 3652 | } |
3653 | 3653 | |
3654 | 3654 | /** |
@@ -3762,7 +3762,7 @@ discard block |
||
3762 | 3762 | \array_uintersect( |
3763 | 3763 | $this->toArray(), |
3764 | 3764 | $search, |
3765 | - static function ($a, $b) { |
|
3765 | + static function($a, $b) { |
|
3766 | 3766 | return $a === $b ? 0 : -1; |
3767 | 3767 | } |
3768 | 3768 | ), |
@@ -4112,13 +4112,13 @@ discard block |
||
4112 | 4112 | // non recursive |
4113 | 4113 | |
4114 | 4114 | if ($search_values === null) { |
4115 | - $arrayFunction = function (): \Generator { |
|
4115 | + $arrayFunction = function(): \Generator { |
|
4116 | 4116 | foreach ($this->getGenerator() as $key => $value) { |
4117 | 4117 | yield $key; |
4118 | 4118 | } |
4119 | 4119 | }; |
4120 | 4120 | } else { |
4121 | - $arrayFunction = function () use ($search_values, $strict): \Generator { |
|
4121 | + $arrayFunction = function() use ($search_values, $strict): \Generator { |
|
4122 | 4122 | $is_array_tmp = \is_array($search_values); |
4123 | 4123 | |
4124 | 4124 | /** @noinspection PhpParameterByRefIsNotUsedAsReferenceInspection */ |
@@ -4372,7 +4372,7 @@ discard block |
||
4372 | 4372 | $useArguments = \func_num_args() > 2; |
4373 | 4373 | |
4374 | 4374 | return static::create( |
4375 | - function () use ($useArguments, $callable, $useKeyAsSecondParameter, $arguments) { |
|
4375 | + function() use ($useArguments, $callable, $useKeyAsSecondParameter, $arguments) { |
|
4376 | 4376 | foreach ($this->getGenerator() as $key => $value) { |
4377 | 4377 | if ($useArguments) { |
4378 | 4378 | if ($useKeyAsSecondParameter) { |
@@ -4876,7 +4876,7 @@ discard block |
||
4876 | 4876 | */ |
4877 | 4877 | public function nth(int $step, int $offset = 0): self |
4878 | 4878 | { |
4879 | - $arrayFunction = function () use ($step, $offset): \Generator { |
|
4879 | + $arrayFunction = function() use ($step, $offset): \Generator { |
|
4880 | 4880 | $position = 0; |
4881 | 4881 | foreach ($this->getGenerator() as $key => $value) { |
4882 | 4882 | if ($position++ % $step !== $offset) { |
@@ -4910,7 +4910,7 @@ discard block |
||
4910 | 4910 | { |
4911 | 4911 | $keys = \array_flip($keys); |
4912 | 4912 | |
4913 | - $generator = function () use ($keys): \Generator { |
|
4913 | + $generator = function() use ($keys): \Generator { |
|
4914 | 4914 | foreach ($this->getGenerator() as $key => $value) { |
4915 | 4915 | if (isset($keys[$key])) { |
4916 | 4916 | yield $key => $value; |
@@ -5047,7 +5047,7 @@ discard block |
||
5047 | 5047 | */ |
5048 | 5048 | public function prependImmutable($value, $key = null) |
5049 | 5049 | { |
5050 | - $generator = function () use ($key, $value): \Generator { |
|
5050 | + $generator = function() use ($key, $value): \Generator { |
|
5051 | 5051 | if ($this->properties !== []) { |
5052 | 5052 | $this->checkType($key, $value); |
5053 | 5053 | } |
@@ -5097,7 +5097,7 @@ discard block |
||
5097 | 5097 | )->prependToEachKey($suffix) |
5098 | 5098 | ->toArray(); |
5099 | 5099 | } else { |
5100 | - $result[$key . $suffix] = $item; |
|
5100 | + $result[$key.$suffix] = $item; |
|
5101 | 5101 | } |
5102 | 5102 | } |
5103 | 5103 | |
@@ -5137,7 +5137,7 @@ discard block |
||
5137 | 5137 | } elseif (\is_object($item) === true) { |
5138 | 5138 | $result[$key] = $item; |
5139 | 5139 | } else { |
5140 | - $result[$key] = $item . $suffix; |
|
5140 | + $result[$key] = $item.$suffix; |
|
5141 | 5141 | } |
5142 | 5142 | } |
5143 | 5143 | |
@@ -5959,7 +5959,7 @@ discard block |
||
5959 | 5959 | */ |
5960 | 5960 | public function replaceValues($search, $replacement = ''): self |
5961 | 5961 | { |
5962 | - $callable = static function ($value) use ($search, $replacement) { |
|
5962 | + $callable = static function($value) use ($search, $replacement) { |
|
5963 | 5963 | return \str_replace($search, $replacement, $value); |
5964 | 5964 | }; |
5965 | 5965 | |
@@ -6684,7 +6684,7 @@ discard block |
||
6684 | 6684 | * @psalm-suppress MissingClosureParamType |
6685 | 6685 | */ |
6686 | 6686 | $results = $arrayy->each( |
6687 | - static function ($value) use ($sorter) { |
|
6687 | + static function($value) use ($sorter) { |
|
6688 | 6688 | if (\is_callable($sorter) === true) { |
6689 | 6689 | return $sorter($value); |
6690 | 6690 | } |
@@ -6757,7 +6757,7 @@ discard block |
||
6757 | 6757 | public function split(int $numberOfPieces = 2, bool $keepKeys = false): self |
6758 | 6758 | { |
6759 | 6759 | if ($keepKeys) { |
6760 | - $generator = function () use ($numberOfPieces) { |
|
6760 | + $generator = function() use ($numberOfPieces) { |
|
6761 | 6761 | $carry = []; |
6762 | 6762 | $i = 1; |
6763 | 6763 | foreach ($this->getGenerator() as $key => $value) { |
@@ -6780,7 +6780,7 @@ discard block |
||
6780 | 6780 | } |
6781 | 6781 | }; |
6782 | 6782 | } else { |
6783 | - $generator = function () use ($numberOfPieces) { |
|
6783 | + $generator = function() use ($numberOfPieces) { |
|
6784 | 6784 | $carry = []; |
6785 | 6785 | $i = 1; |
6786 | 6786 | foreach ($this->getGenerator() as $value) { |
@@ -6827,7 +6827,7 @@ discard block |
||
6827 | 6827 | public function stripEmpty(): self |
6828 | 6828 | { |
6829 | 6829 | return $this->filter( |
6830 | - static function ($item) { |
|
6830 | + static function($item) { |
|
6831 | 6831 | if ($item === null) { |
6832 | 6832 | return false; |
6833 | 6833 | } |
@@ -7035,7 +7035,7 @@ discard block |
||
7035 | 7035 | // INFO: \array_unique() can't handle e.g. "stdClass"-values in an array |
7036 | 7036 | |
7037 | 7037 | $this->array = $this->reduce( |
7038 | - static function ($resultArray, $value, $key) { |
|
7038 | + static function($resultArray, $value, $key) { |
|
7039 | 7039 | if (!\in_array($value, $resultArray, true)) { |
7040 | 7040 | $resultArray[] = $value; |
7041 | 7041 | } |
@@ -7074,7 +7074,7 @@ discard block |
||
7074 | 7074 | */ |
7075 | 7075 | $this->array = \array_reduce( |
7076 | 7076 | \array_keys($array), |
7077 | - static function ($resultArray, $key) use ($array) { |
|
7077 | + static function($resultArray, $key) use ($array) { |
|
7078 | 7078 | if (!\in_array($array[$key], $resultArray, true)) { |
7079 | 7079 | $resultArray[$key] = $array[$key]; |
7080 | 7080 | } |
@@ -7171,7 +7171,7 @@ discard block |
||
7171 | 7171 | public function values(): self |
7172 | 7172 | { |
7173 | 7173 | return static::create( |
7174 | - function () { |
|
7174 | + function() { |
|
7175 | 7175 | foreach ($this->getGenerator() as $value) { |
7176 | 7176 | yield $value; |
7177 | 7177 | } |
@@ -7255,7 +7255,7 @@ discard block |
||
7255 | 7255 | public function where(string $keyOrPropertyOrMethod, $value): self |
7256 | 7256 | { |
7257 | 7257 | return $this->filter( |
7258 | - function ($item) use ($keyOrPropertyOrMethod, $value) { |
|
7258 | + function($item) use ($keyOrPropertyOrMethod, $value) { |
|
7259 | 7259 | $accessorValue = $this->extractValue( |
7260 | 7260 | $item, |
7261 | 7261 | $keyOrPropertyOrMethod |
@@ -7551,7 +7551,7 @@ discard block |
||
7551 | 7551 | protected function getPropertiesFromPhpDoc() |
7552 | 7552 | { |
7553 | 7553 | static $PROPERTY_CACHE = []; |
7554 | - $cacheKey = 'Class::' . static::class; |
|
7554 | + $cacheKey = 'Class::'.static::class; |
|
7555 | 7555 | |
7556 | 7556 | if (isset($PROPERTY_CACHE[$cacheKey])) { |
7557 | 7557 | return $PROPERTY_CACHE[$cacheKey]; |
@@ -7864,7 +7864,7 @@ discard block |
||
7864 | 7864 | if ($array === null) { |
7865 | 7865 | $array = []; |
7866 | 7866 | } elseif (!\is_array($array)) { |
7867 | - throw new \RuntimeException('Can not set value at this path "' . $key . '" because (' . \gettype($array) . ')"' . \print_r($array, true) . '" is not an array.'); |
|
7867 | + throw new \RuntimeException('Can not set value at this path "'.$key.'" because ('.\gettype($array).')"'.\print_r($array, true).'" is not an array.'); |
|
7868 | 7868 | } |
7869 | 7869 | |
7870 | 7870 | $array[$key] = $value; |
@@ -7928,7 +7928,7 @@ discard block |
||
7928 | 7928 | && |
7929 | 7929 | \count(\array_diff_key($properties, $data)) > 0 |
7930 | 7930 | ) { |
7931 | - throw new \TypeError('Property mismatch - input: ' . \print_r(\array_keys($data), true) . ' | expected: ' . \print_r(\array_keys($properties), true)); |
|
7931 | + throw new \TypeError('Property mismatch - input: '.\print_r(\array_keys($data), true).' | expected: '.\print_r(\array_keys($properties), true)); |
|
7932 | 7932 | } |
7933 | 7933 | } |
7934 | 7934 | |
@@ -8045,7 +8045,7 @@ discard block |
||
8045 | 8045 | * |
8046 | 8046 | * @return void |
8047 | 8047 | */ |
8048 | - static function (&$item) { |
|
8048 | + static function(&$item) { |
|
8049 | 8049 | if ($item instanceof self) { |
8050 | 8050 | $item = $item->getArray(); |
8051 | 8051 | } |
@@ -8070,7 +8070,7 @@ discard block |
||
8070 | 8070 | && |
8071 | 8071 | $this->checkPropertiesMismatch === true |
8072 | 8072 | ) { |
8073 | - throw new \TypeError('The key "' . $key . '" does not exists as "@property" phpdoc. (' . \get_class($this) . ').'); |
|
8073 | + throw new \TypeError('The key "'.$key.'" does not exists as "@property" phpdoc. ('.\get_class($this).').'); |
|
8074 | 8074 | } |
8075 | 8075 | |
8076 | 8076 | if (isset($this->properties[self::ARRAYY_HELPER_TYPES_FOR_ALL_PROPERTIES])) { |