@@ -25,7 +25,7 @@ |
||
25 | 25 | { |
26 | 26 | assert( |
27 | 27 | $property instanceof IProperty || is_string($property), |
28 | - 'The property to search for must either be a string representing the name or IProperty'. |
|
28 | + 'The property to search for must either be a string representing the name or IProperty' . |
|
29 | 29 | ' representing the property' |
30 | 30 | ); |
31 | 31 | foreach ($this->getPropertyValueBindings() as $propertyBinding) { |
@@ -1338,14 +1338,12 @@ discard block |
||
1338 | 1338 | { |
1339 | 1339 | /* @noinspection PhpUnhandledExceptionInspection suppressing exceptions for asserts.*/ |
1340 | 1340 | assert( |
1341 | - count((is_array($toXml) ? new ReflectionMethod(...$toXml) : |
|
1342 | - new ReflectionFunction($toXml))->getParameters()) === 1, |
|
1341 | + count((is_array($toXml) ? new ReflectionMethod(...$toXml) : new ReflectionFunction($toXml))->getParameters()) === 1, |
|
1343 | 1342 | '$toXml should be a callable takeing one paramater of mixed type' |
1344 | 1343 | ); |
1345 | 1344 | /* @noinspection PhpUnhandledExceptionInspection suppressing exceptions for asserts.*/ |
1346 | 1345 | assert( |
1347 | - (is_array($toXml) ? new ReflectionMethod(...$toXml) : |
|
1348 | - new ReflectionFunction($toXml))->getReturnType()->getName() === 'string', |
|
1346 | + (is_array($toXml) ? new ReflectionMethod(...$toXml) : new ReflectionFunction($toXml))->getReturnType()->getName() === 'string', |
|
1349 | 1347 | '$toXml should be a callable returning a string' |
1350 | 1348 | ); |
1351 | 1349 | if ($value !== $defaultValue) { |
@@ -1363,14 +1361,12 @@ discard block |
||
1363 | 1361 | { |
1364 | 1362 | /* @noinspection PhpUnhandledExceptionInspection suppressing exceptions for asserts.*/ |
1365 | 1363 | assert( |
1366 | - count((is_array($toXml) ? new ReflectionMethod(...$toXml) : |
|
1367 | - new ReflectionFunction($toXml))->getParameters()) === 1, |
|
1364 | + count((is_array($toXml) ? new ReflectionMethod(...$toXml) : new ReflectionFunction($toXml))->getParameters()) === 1, |
|
1368 | 1365 | '$toXml should be a callable takeing one paramater of mixed type' |
1369 | 1366 | ); |
1370 | 1367 | /* @noinspection PhpUnhandledExceptionInspection suppressing exceptions for asserts.*/ |
1371 | 1368 | assert( |
1372 | - (is_array($toXml) ? new ReflectionMethod(...$toXml) : |
|
1373 | - new ReflectionFunction($toXml))->getReturnType()->getName() === 'string', |
|
1369 | + (is_array($toXml) ? new ReflectionMethod(...$toXml) : new ReflectionFunction($toXml))->getReturnType()->getName() === 'string', |
|
1374 | 1370 | '$toXml should be a callable returning a string' |
1375 | 1371 | ); |
1376 | 1372 | $this->xmlWriter->writeAttribute($attribute, $toXml($value)); |
@@ -1464,7 +1460,7 @@ discard block |
||
1464 | 1460 | |
1465 | 1461 | private static function SridAsXml(?int $i): string |
1466 | 1462 | { |
1467 | - return $i !== null ? strval($i) : CsdlConstants::Value_SridVariable; |
|
1463 | + return $i !== null ? strval($i) : CsdlConstants::Value_SridVariable; |
|
1468 | 1464 | } |
1469 | 1465 | |
1470 | 1466 | /** |