@@ -33,7 +33,7 @@ |
||
| 33 | 33 | ); |
| 34 | 34 | break; |
| 35 | 35 | |
| 36 | - case SchemaElementKind::Function(): |
|
| 36 | + case SchemaElementKind::Function (): |
|
| 37 | 37 | InterfaceValidator::CollectErrors( |
| 38 | 38 | InterfaceValidator::CheckForInterfaceKindValueMismatchError( |
| 39 | 39 | $item, |
@@ -33,7 +33,7 @@ |
||
| 33 | 33 | ); |
| 34 | 34 | break; |
| 35 | 35 | |
| 36 | - case SchemaElementKind::Function(): |
|
| 36 | + case SchemaElementKind::function(): |
|
| 37 | 37 | InterfaceValidator::CollectErrors( |
| 38 | 38 | InterfaceValidator::CheckForInterfaceKindValueMismatchError( |
| 39 | 39 | $item, |
@@ -224,7 +224,7 @@ discard block |
||
| 224 | 224 | ); |
| 225 | 225 | break; |
| 226 | 226 | |
| 227 | - case ExpressionKind::If(): |
|
| 227 | + case ExpressionKind::If (): |
|
| 228 | 228 | $expressionKindError = InterfaceValidator::CheckForInterfaceKindValueMismatchError( |
| 229 | 229 | $expression, |
| 230 | 230 | $expression->getExpressionKind(), |
@@ -288,7 +288,7 @@ discard block |
||
| 288 | 288 | } |
| 289 | 289 | } |
| 290 | 290 | |
| 291 | - return null !== $expressionKindError ? [ $expressionKindError ] : null; |
|
| 291 | + return null !== $expressionKindError ? [$expressionKindError] : null; |
|
| 292 | 292 | } |
| 293 | 293 | |
| 294 | 294 | public function forType(): string |
@@ -134,7 +134,7 @@ discard block |
||
| 134 | 134 | ); |
| 135 | 135 | break; |
| 136 | 136 | |
| 137 | - case ExpressionKind::Null(): |
|
| 137 | + case ExpressionKind::null(): |
|
| 138 | 138 | $expressionKindError = InterfaceValidator::CheckForInterfaceKindValueMismatchError( |
| 139 | 139 | $expression, |
| 140 | 140 | $expression->getExpressionKind(), |
@@ -224,7 +224,7 @@ discard block |
||
| 224 | 224 | ); |
| 225 | 225 | break; |
| 226 | 226 | |
| 227 | - case ExpressionKind::If(): |
|
| 227 | + case ExpressionKind::if(): |
|
| 228 | 228 | $expressionKindError = InterfaceValidator::CheckForInterfaceKindValueMismatchError( |
| 229 | 229 | $expression, |
| 230 | 230 | $expression->getExpressionKind(), |
@@ -98,7 +98,7 @@ |
||
| 98 | 98 | break; |
| 99 | 99 | } |
| 100 | 100 | |
| 101 | - return null !== $typeKindError ? [$typeKindError ] : null; |
|
| 101 | + return null !== $typeKindError ? [$typeKindError] : null; |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | public function forType(): string |
@@ -26,7 +26,7 @@ |
||
| 26 | 26 | if (!in_array($property->getPartner(), $prop)) { |
| 27 | 27 | $followup[] = $property->getPartner(); |
| 28 | 28 | } else { |
| 29 | - $references[] =$property->getPartner(); |
|
| 29 | + $references[] = $property->getPartner(); |
|
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | if ($property->getPartner()->getPartner() !== $property || $property->getPartner() === $property) { |
@@ -144,7 +144,7 @@ discard block |
||
| 144 | 144 | |
| 145 | 145 | $thisTypeKeys = array_keys($thisFunction->getParameters()); |
| 146 | 146 | $otherTypeKeys = array_keys($otherFunction->getParameters()); |
| 147 | - $keyCount = count($thisTypeKeys); |
|
| 147 | + $keyCount = count($thisTypeKeys); |
|
| 148 | 148 | for ($i = 0; $i < $keyCount; ++$i) { |
| 149 | 149 | if (!self::isEquivalentTo( |
| 150 | 150 | $thisFunction->getParameters()[$thisTypeKeys[$i]], |
@@ -207,7 +207,7 @@ discard block |
||
| 207 | 207 | |
| 208 | 208 | $thisTypeKeys = array_keys($thisType->getDeclaredProperties()); |
| 209 | 209 | $otherTypeKeys = array_keys($otherType->getDeclaredProperties()); |
| 210 | - $keyCount = count($thisTypeKeys); |
|
| 210 | + $keyCount = count($thisTypeKeys); |
|
| 211 | 211 | for ($i = 0; $i < $keyCount; ++$i) { |
| 212 | 212 | if (!self::isEquivalentTo( |
| 213 | 213 | $thisType->getDeclaredProperties()[$thisTypeKeys[$i]], |
@@ -21,7 +21,7 @@ |
||
| 21 | 21 | */ |
| 22 | 22 | $annotation = $this; |
| 23 | 23 | return $annotation->GetSerializationLocation($model) == |
| 24 | - EdmVocabularyAnnotationSerializationLocation::Inline || $annotation->TargetString() == null; |
|
| 24 | + EdmVocabularyAnnotationSerializationLocation::Inline || $annotation->TargetString() == null; |
|
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | public function TargetString(): string |
@@ -51,7 +51,7 @@ |
||
| 51 | 51 | $annotation, |
| 52 | 52 | EdmConstants::InternalUri, |
| 53 | 53 | CsdlConstants::AnnotationSerializationLocationAnnotation, |
| 54 | - (object)$location |
|
| 54 | + (object) $location |
|
| 55 | 55 | ); |
| 56 | 56 | } |
| 57 | 57 | |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | case $element instanceof IProperty: |
| 54 | 54 | assert($element instanceof IProperty); |
| 55 | 55 | $type = $element->getType(); |
| 56 | - return $element->getName() ?? '' . ':' . ($type !== null ? self::ToTraceString($type) :''); |
|
| 56 | + return $element->getName() ?? '' . ':' . ($type !== null ? self::ToTraceString($type) : ''); |
|
| 57 | 57 | case $element instanceof IEntityReferenceType: |
| 58 | 58 | assert($element instanceof IEntityReferenceType); |
| 59 | 59 | return TypeKind::EntityReference()->getKey() . '(' . ($element->getEntityType() !== null ? |
@@ -188,7 +188,7 @@ discard block |
||
| 188 | 188 | $sb, |
| 189 | 189 | EdmConstants::FacetName_Srid, |
| 190 | 190 | null !== $type->getSpatialReferenceIdentifier() |
| 191 | - ? $type->getSpatialReferenceIdentifier(): EdmConstants::Value_SridVariable |
|
| 191 | + ? $type->getSpatialReferenceIdentifier() : EdmConstants::Value_SridVariable |
|
| 192 | 192 | ); |
| 193 | 193 | return $sb; |
| 194 | 194 | } |
@@ -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 | /** |