@@ -674,6 +674,7 @@ |
||
674 | 674 | * True if response needs to be |
675 | 675 | * serialized, False otherwise |
676 | 676 | * @param bool $needToSerializeResponse |
677 | + * @param QueryResult $entryObject |
|
677 | 678 | * |
678 | 679 | * @return string|null The ETag for the entry object if it has eTag properties |
679 | 680 | * NULL otherwise |
@@ -469,7 +469,7 @@ |
||
469 | 469 | ODataConstants::HTTPQUERY_STRING_ORDERBY, |
470 | 470 | ODataConstants::HTTPQUERY_STRING_INLINECOUNT, |
471 | 471 | ODataConstants::HTTPQUERY_STRING_SELECT |
472 | - ] as $queryOption) { |
|
472 | + ] as $queryOption) { |
|
473 | 473 | $value = $this->getService()->getHost()->getQueryStringItem($queryOption); |
474 | 474 | if (!is_null($value)) { |
475 | 475 | if (!is_null($queryParameterString)) { |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | * |
31 | 31 | * @return ODataFeed |
32 | 32 | */ |
33 | - public function writeTopLevelElements(QueryResult &$entryObjects); |
|
33 | + public function writeTopLevelElements(QueryResult & $entryObjects); |
|
34 | 34 | |
35 | 35 | /** |
36 | 36 | * Write top level url element. |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | * |
61 | 61 | * @return ODataPropertyContent |
62 | 62 | */ |
63 | - public function writeTopLevelComplexObject(QueryResult &$complexValue, $propertyName, ResourceType &$resourceType); |
|
63 | + public function writeTopLevelComplexObject(QueryResult & $complexValue, $propertyName, ResourceType & $resourceType); |
|
64 | 64 | |
65 | 65 | /** |
66 | 66 | * Write top level bag resource. |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | * |
72 | 72 | * @return ODataPropertyContent |
73 | 73 | */ |
74 | - public function writeTopLevelBagObject(QueryResult &$BagValue, $propertyName, ResourceType &$resourceType); |
|
74 | + public function writeTopLevelBagObject(QueryResult & $BagValue, $propertyName, ResourceType & $resourceType); |
|
75 | 75 | |
76 | 76 | /** |
77 | 77 | * Write top level primitive value. |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | * |
82 | 82 | * @return ODataPropertyContent |
83 | 83 | */ |
84 | - public function writeTopLevelPrimitive(QueryResult &$primitiveValue, ResourceProperty &$resourceProperty = null); |
|
84 | + public function writeTopLevelPrimitive(QueryResult & $primitiveValue, ResourceProperty & $resourceProperty = null); |
|
85 | 85 | |
86 | 86 | /** |
87 | 87 | * Gets reference to the request submitted by client. |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | * |
76 | 76 | * @return ODataFeed |
77 | 77 | */ |
78 | - public function writeTopLevelElements(QueryResult &$entryObjects) |
|
78 | + public function writeTopLevelElements(QueryResult & $entryObjects) |
|
79 | 79 | { |
80 | 80 | assert(is_array($entryObjects->results), '!is_array($entryObjects->results)'); |
81 | 81 | $requestTargetSource = $this->getRequest()->getTargetSource(); |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | * @return ODataPropertyContent |
185 | 185 | */ |
186 | 186 | public function writeTopLevelComplexObject( |
187 | - QueryResult &$complexValue, |
|
187 | + QueryResult & $complexValue, |
|
188 | 188 | $propertyName, |
189 | 189 | ResourceType & $resourceType |
190 | 190 | ) { |
@@ -210,9 +210,9 @@ discard block |
||
210 | 210 | * @return ODataPropertyContent |
211 | 211 | */ |
212 | 212 | public function writeTopLevelBagObject( |
213 | - QueryResult &$BagValue, |
|
213 | + QueryResult & $BagValue, |
|
214 | 214 | $propertyName, |
215 | - ResourceType &$resourceType |
|
215 | + ResourceType & $resourceType |
|
216 | 216 | ) { |
217 | 217 | $propertyContent = new ODataPropertyContent(); |
218 | 218 | $this->writeBagValue( |
@@ -235,8 +235,8 @@ discard block |
||
235 | 235 | * @return ODataPropertyContent |
236 | 236 | */ |
237 | 237 | public function writeTopLevelPrimitive( |
238 | - QueryResult &$primitiveValue, |
|
239 | - ResourceProperty &$resourceProperty = null |
|
238 | + QueryResult & $primitiveValue, |
|
239 | + ResourceProperty & $resourceProperty = null |
|
240 | 240 | ) { |
241 | 241 | assert(null != $resourceProperty, "Resource property must not be null"); |
242 | 242 | $propertyContent = new ODataPropertyContent(); |
@@ -323,11 +323,11 @@ discard block |
||
323 | 323 | */ |
324 | 324 | private function writeFeedElements( |
325 | 325 | &$entryObjects, |
326 | - ResourceType &$resourceType, |
|
326 | + ResourceType & $resourceType, |
|
327 | 327 | $title, |
328 | 328 | $absoluteUri, |
329 | 329 | $relativeUri, |
330 | - ODataFeed &$feed, |
|
330 | + ODataFeed & $feed, |
|
331 | 331 | $needLink = false |
332 | 332 | ) { |
333 | 333 | assert(is_array($entryObjects), '!_writeFeedElements::is_array($entryObjects)'); |
@@ -378,11 +378,11 @@ discard block |
||
378 | 378 | */ |
379 | 379 | private function writeObjectProperties( |
380 | 380 | $customObject, |
381 | - ResourceType &$resourceType, |
|
381 | + ResourceType & $resourceType, |
|
382 | 382 | $absoluteUri, |
383 | 383 | $relativeUri, |
384 | 384 | &$odataEntry, |
385 | - ODataPropertyContent &$odataPropertyContent |
|
385 | + ODataPropertyContent & $odataPropertyContent |
|
386 | 386 | ) { |
387 | 387 | $resourceTypeKind = $resourceType->getResourceTypeKind(); |
388 | 388 | if (is_null($absoluteUri) == (ResourceTypeKind::ENTITY == $resourceTypeKind) |
@@ -505,8 +505,8 @@ discard block |
||
505 | 505 | */ |
506 | 506 | private function writePrimitiveValue( |
507 | 507 | &$primitiveValue, |
508 | - ODataProperty &$odataProperty, |
|
509 | - ResourceProperty &$resourceProperty |
|
508 | + ODataProperty & $odataProperty, |
|
509 | + ResourceProperty & $resourceProperty |
|
510 | 510 | ) { |
511 | 511 | if (is_object($primitiveValue)) { |
512 | 512 | //TODO ERROR: The property 'PropertyName' |
@@ -540,9 +540,9 @@ discard block |
||
540 | 540 | private function writeComplexValue( |
541 | 541 | &$complexValue, |
542 | 542 | $propertyName, |
543 | - ResourceType &$resourceType, |
|
543 | + ResourceType & $resourceType, |
|
544 | 544 | $relativeUri, |
545 | - ODataPropertyContent &$odataPropertyContent |
|
545 | + ODataPropertyContent & $odataPropertyContent |
|
546 | 546 | ) { |
547 | 547 | $odataProperty = new ODataProperty(); |
548 | 548 | $odataProperty->name = $propertyName; |
@@ -581,9 +581,9 @@ discard block |
||
581 | 581 | private function writeBagValue( |
582 | 582 | &$BagValue, |
583 | 583 | $propertyName, |
584 | - ResourceType &$resourceType, |
|
584 | + ResourceType & $resourceType, |
|
585 | 585 | $relativeUri, |
586 | - ODataPropertyContent &$odataPropertyContent |
|
586 | + ODataPropertyContent & $odataPropertyContent |
|
587 | 587 | ) { |
588 | 588 | assert(null == $BagValue || is_array($BagValue), 'Bag parameter must be null or array'); |
589 | 589 | $bagItemResourceTypeKind = $resourceType->getResourceTypeKind(); |
@@ -640,10 +640,10 @@ discard block |
||
640 | 640 | */ |
641 | 641 | private function writeMediaResourceMetadata( |
642 | 642 | $entryObject, |
643 | - ResourceType &$resourceType, |
|
643 | + ResourceType & $resourceType, |
|
644 | 644 | $title, |
645 | 645 | $relativeUri, |
646 | - ODataEntry &$odataEntry |
|
646 | + ODataEntry & $odataEntry |
|
647 | 647 | ) { |
648 | 648 | $streamProviderWrapper = $this->getService()->getStreamProviderWrapper(); |
649 | 649 | assert(null != $streamProviderWrapper, "Retrieved stream provider must not be null"); |
@@ -716,7 +716,7 @@ discard block |
||
716 | 716 | * @return string |
717 | 717 | */ |
718 | 718 | private function primitiveToString( |
719 | - ResourceType &$primitiveResourceType, |
|
719 | + ResourceType & $primitiveResourceType, |
|
720 | 720 | $primitiveValue |
721 | 721 | ) { |
722 | 722 | $type = $primitiveResourceType->getInstanceType(); |
@@ -755,9 +755,9 @@ discard block |
||
755 | 755 | private function complexObjectToContent( |
756 | 756 | &$complexValue, |
757 | 757 | $propertyName, |
758 | - ResourceType &$resourceType, |
|
758 | + ResourceType & $resourceType, |
|
759 | 759 | $relativeUri, |
760 | - ODataPropertyContent &$odataPropertyContent |
|
760 | + ODataPropertyContent & $odataPropertyContent |
|
761 | 761 | ) { |
762 | 762 | $count = count($this->complexTypeInstanceCollection); |
763 | 763 | for ($i = 0; $i < $count; ++$i) { |
@@ -800,9 +800,9 @@ discard block |
||
800 | 800 | */ |
801 | 801 | private function writeObjectPropertiesUnexpanded( |
802 | 802 | $customObject, |
803 | - ResourceType &$resourceType, |
|
803 | + ResourceType & $resourceType, |
|
804 | 804 | $relativeUri, |
805 | - ODataPropertyContent &$odataPropertyContent, |
|
805 | + ODataPropertyContent & $odataPropertyContent, |
|
806 | 806 | $resourceTypeKind, |
807 | 807 | $navigationProperties |
808 | 808 | ) { |
@@ -901,7 +901,7 @@ discard block |
||
901 | 901 | if (28 < $resourceKind) { |
902 | 902 | return false; |
903 | 903 | } |
904 | - return 0 == ($resourceKind % 4); |
|
904 | + return 0 == ($resourceKind%4); |
|
905 | 905 | } |
906 | 906 | |
907 | 907 | |
@@ -919,9 +919,9 @@ discard block |
||
919 | 919 | */ |
920 | 920 | private function writeObjectPropertiesExpanded( |
921 | 921 | $customObject, |
922 | - ResourceType &$resourceType, |
|
922 | + ResourceType & $resourceType, |
|
923 | 923 | $relativeUri, |
924 | - ODataPropertyContent &$odataPropertyContent, |
|
924 | + ODataPropertyContent & $odataPropertyContent, |
|
925 | 925 | $projectionNodes, |
926 | 926 | $navigationProperties |
927 | 927 | ) { |