@@ -62,7 +62,6 @@ |
||
| 62 | 62 | /** |
| 63 | 63 | * Set the URL of the request |
| 64 | 64 | * |
| 65 | - * @param string $url|Url Full URL to set including query string |
|
| 66 | 65 | * |
| 67 | 66 | * @return self |
| 68 | 67 | */ |
@@ -190,7 +190,7 @@ discard block |
||
| 190 | 190 | /** |
| 191 | 191 | * Set the response entity body |
| 192 | 192 | * |
| 193 | - * @param EntityBodyInterface|string $body Body to set |
|
| 193 | + * @param string $body Body to set |
|
| 194 | 194 | * |
| 195 | 195 | * @return self |
| 196 | 196 | */ |
@@ -296,7 +296,7 @@ discard block |
||
| 296 | 296 | /** |
| 297 | 297 | * Get the response status code |
| 298 | 298 | * |
| 299 | - * @return integer |
|
| 299 | + * @return string |
|
| 300 | 300 | */ |
| 301 | 301 | public function getStatusCode() |
| 302 | 302 | { |
@@ -377,7 +377,7 @@ discard block |
||
| 377 | 377 | /** |
| 378 | 378 | * Get the Age HTTP header |
| 379 | 379 | * |
| 380 | - * @return integer|null Returns the age the object has been in a proxy cache in seconds. |
|
| 380 | + * @return string Returns the age the object has been in a proxy cache in seconds. |
|
| 381 | 381 | */ |
| 382 | 382 | public function getAge() |
| 383 | 383 | { |
@@ -387,7 +387,7 @@ discard block |
||
| 387 | 387 | /** |
| 388 | 388 | * Get the Allow HTTP header |
| 389 | 389 | * |
| 390 | - * @return string|null Returns valid actions for a specified resource. To be used for a 405 Method not allowed. |
|
| 390 | + * @return string Returns valid actions for a specified resource. To be used for a 405 Method not allowed. |
|
| 391 | 391 | */ |
| 392 | 392 | public function getAllow() |
| 393 | 393 | { |
@@ -438,7 +438,7 @@ discard block |
||
| 438 | 438 | /** |
| 439 | 439 | * Get the Content-Encoding HTTP header |
| 440 | 440 | * |
| 441 | - * @return string|null |
|
| 441 | + * @return string |
|
| 442 | 442 | */ |
| 443 | 443 | public function getContentEncoding() |
| 444 | 444 | { |
@@ -448,7 +448,7 @@ discard block |
||
| 448 | 448 | /** |
| 449 | 449 | * Get the Content-Language HTTP header |
| 450 | 450 | * |
| 451 | - * @return string|null Returns the language the content is in. |
|
| 451 | + * @return string Returns the language the content is in. |
|
| 452 | 452 | */ |
| 453 | 453 | public function getContentLanguage() |
| 454 | 454 | { |
@@ -468,7 +468,7 @@ discard block |
||
| 468 | 468 | /** |
| 469 | 469 | * Get the Content-Location HTTP header |
| 470 | 470 | * |
| 471 | - * @return string|null Returns an alternate location for the returned data (e.g /index.htm) |
|
| 471 | + * @return string Returns an alternate location for the returned data (e.g /index.htm) |
|
| 472 | 472 | */ |
| 473 | 473 | public function getContentLocation() |
| 474 | 474 | { |
@@ -478,7 +478,7 @@ discard block |
||
| 478 | 478 | /** |
| 479 | 479 | * Get the Content-Disposition HTTP header |
| 480 | 480 | * |
| 481 | - * @return string|null Returns the Content-Disposition header |
|
| 481 | + * @return string Returns the Content-Disposition header |
|
| 482 | 482 | */ |
| 483 | 483 | public function getContentDisposition() |
| 484 | 484 | { |
@@ -488,7 +488,7 @@ discard block |
||
| 488 | 488 | /** |
| 489 | 489 | * Get the Content-MD5 HTTP header |
| 490 | 490 | * |
| 491 | - * @return string|null Returns a Base64-encoded binary MD5 sum of the content of the response. |
|
| 491 | + * @return string Returns a Base64-encoded binary MD5 sum of the content of the response. |
|
| 492 | 492 | */ |
| 493 | 493 | public function getContentMd5() |
| 494 | 494 | { |
@@ -532,7 +532,7 @@ discard block |
||
| 532 | 532 | /** |
| 533 | 533 | * Get the Date HTTP header |
| 534 | 534 | * |
| 535 | - * @return string|null Returns the date and time that the message was sent. |
|
| 535 | + * @return string Returns the date and time that the message was sent. |
|
| 536 | 536 | */ |
| 537 | 537 | public function getDate() |
| 538 | 538 | { |
@@ -542,7 +542,7 @@ discard block |
||
| 542 | 542 | /** |
| 543 | 543 | * Get the ETag HTTP header |
| 544 | 544 | * |
| 545 | - * @return string|null Returns an identifier for a specific version of a resource, often a Message digest. |
|
| 545 | + * @return string Returns an identifier for a specific version of a resource, often a Message digest. |
|
| 546 | 546 | */ |
| 547 | 547 | public function getEtag() |
| 548 | 548 | { |
@@ -552,7 +552,7 @@ discard block |
||
| 552 | 552 | /** |
| 553 | 553 | * Get the Expires HTTP header |
| 554 | 554 | * |
| 555 | - * @return string|null Returns the date/time after which the response is considered stale. |
|
| 555 | + * @return string Returns the date/time after which the response is considered stale. |
|
| 556 | 556 | */ |
| 557 | 557 | public function getExpires() |
| 558 | 558 | { |
@@ -562,7 +562,7 @@ discard block |
||
| 562 | 562 | /** |
| 563 | 563 | * Get the Last-Modified HTTP header |
| 564 | 564 | * |
| 565 | - * @return string|null Returns the last modified date for the requested object, in RFC 2822 format |
|
| 565 | + * @return string Returns the last modified date for the requested object, in RFC 2822 format |
|
| 566 | 566 | * (e.g. Tue, 15 Nov 1994 12:45:26 GMT) |
| 567 | 567 | */ |
| 568 | 568 | public function getLastModified() |
@@ -573,7 +573,7 @@ discard block |
||
| 573 | 573 | /** |
| 574 | 574 | * Get the Location HTTP header |
| 575 | 575 | * |
| 576 | - * @return string|null Used in redirection, or when a new resource has been created. |
|
| 576 | + * @return string Used in redirection, or when a new resource has been created. |
|
| 577 | 577 | */ |
| 578 | 578 | public function getLocation() |
| 579 | 579 | { |
@@ -583,7 +583,7 @@ discard block |
||
| 583 | 583 | /** |
| 584 | 584 | * Get the Pragma HTTP header |
| 585 | 585 | * |
| 586 | - * @return Header|null Returns the implementation-specific headers that may have various effects anywhere along |
|
| 586 | + * @return string Returns the implementation-specific headers that may have various effects anywhere along |
|
| 587 | 587 | * the request-response chain. |
| 588 | 588 | */ |
| 589 | 589 | public function getPragma() |
@@ -594,7 +594,7 @@ discard block |
||
| 594 | 594 | /** |
| 595 | 595 | * Get the Proxy-Authenticate HTTP header |
| 596 | 596 | * |
| 597 | - * @return string|null Authentication to access the proxy (e.g. Basic) |
|
| 597 | + * @return string Authentication to access the proxy (e.g. Basic) |
|
| 598 | 598 | */ |
| 599 | 599 | public function getProxyAuthenticate() |
| 600 | 600 | { |
@@ -604,7 +604,7 @@ discard block |
||
| 604 | 604 | /** |
| 605 | 605 | * Get the Retry-After HTTP header |
| 606 | 606 | * |
| 607 | - * @return int|null If an entity is temporarily unavailable, this instructs the client to try again after a |
|
| 607 | + * @return string If an entity is temporarily unavailable, this instructs the client to try again after a |
|
| 608 | 608 | * specified period of time. |
| 609 | 609 | */ |
| 610 | 610 | public function getRetryAfter() |
@@ -615,7 +615,7 @@ discard block |
||
| 615 | 615 | /** |
| 616 | 616 | * Get the Server HTTP header |
| 617 | 617 | * |
| 618 | - * @return string|null A name for the server |
|
| 618 | + * @return string A name for the server |
|
| 619 | 619 | */ |
| 620 | 620 | public function getServer() |
| 621 | 621 | { |
@@ -625,7 +625,7 @@ discard block |
||
| 625 | 625 | /** |
| 626 | 626 | * Get the Set-Cookie HTTP header |
| 627 | 627 | * |
| 628 | - * @return string|null An HTTP cookie. |
|
| 628 | + * @return string An HTTP cookie. |
|
| 629 | 629 | */ |
| 630 | 630 | public function getSetCookie() |
| 631 | 631 | { |
@@ -635,7 +635,7 @@ discard block |
||
| 635 | 635 | /** |
| 636 | 636 | * Get the Trailer HTTP header |
| 637 | 637 | * |
| 638 | - * @return string|null The Trailer general field value indicates that the given set of header fields is present in |
|
| 638 | + * @return string The Trailer general field value indicates that the given set of header fields is present in |
|
| 639 | 639 | * the trailer of a message encoded with chunked transfer-coding. |
| 640 | 640 | */ |
| 641 | 641 | public function getTrailer() |
@@ -646,7 +646,7 @@ discard block |
||
| 646 | 646 | /** |
| 647 | 647 | * Get the Transfer-Encoding HTTP header |
| 648 | 648 | * |
| 649 | - * @return string|null The form of encoding used to safely transfer the entity to the user |
|
| 649 | + * @return string The form of encoding used to safely transfer the entity to the user |
|
| 650 | 650 | */ |
| 651 | 651 | public function getTransferEncoding() |
| 652 | 652 | { |
@@ -656,7 +656,7 @@ discard block |
||
| 656 | 656 | /** |
| 657 | 657 | * Get the Vary HTTP header |
| 658 | 658 | * |
| 659 | - * @return string|null Tells downstream proxies how to match future request headers to decide whether the cached |
|
| 659 | + * @return string Tells downstream proxies how to match future request headers to decide whether the cached |
|
| 660 | 660 | * response can be used rather than requesting a fresh one from the origin server. |
| 661 | 661 | */ |
| 662 | 662 | public function getVary() |
@@ -667,7 +667,7 @@ discard block |
||
| 667 | 667 | /** |
| 668 | 668 | * Get the Via HTTP header |
| 669 | 669 | * |
| 670 | - * @return string|null Informs the client of proxies through which the response was sent. |
|
| 670 | + * @return string Informs the client of proxies through which the response was sent. |
|
| 671 | 671 | */ |
| 672 | 672 | public function getVia() |
| 673 | 673 | { |
@@ -677,7 +677,7 @@ discard block |
||
| 677 | 677 | /** |
| 678 | 678 | * Get the Warning HTTP header |
| 679 | 679 | * |
| 680 | - * @return string|null A general warning about possible problems with the entity body |
|
| 680 | + * @return string A general warning about possible problems with the entity body |
|
| 681 | 681 | */ |
| 682 | 682 | public function getWarning() |
| 683 | 683 | { |
@@ -687,7 +687,7 @@ discard block |
||
| 687 | 687 | /** |
| 688 | 688 | * Get the WWW-Authenticate HTTP header |
| 689 | 689 | * |
| 690 | - * @return string|null Indicates the authentication scheme that should be used to access the requested entity |
|
| 690 | + * @return string Indicates the authentication scheme that should be used to access the requested entity |
|
| 691 | 691 | */ |
| 692 | 692 | public function getWwwAuthenticate() |
| 693 | 693 | { |
@@ -811,7 +811,7 @@ discard block |
||
| 811 | 811 | * A response is considered fresh when its age is less than or equal to the freshness lifetime (maximum age) of the |
| 812 | 812 | * response. |
| 813 | 813 | * |
| 814 | - * @return bool|null |
|
| 814 | + * @return boolean |
|
| 815 | 815 | */ |
| 816 | 816 | public function isFresh() |
| 817 | 817 | { |
@@ -129,7 +129,7 @@ |
||
| 129 | 129 | * |
| 130 | 130 | * One of: false, "RFC 3986", or "application/x-www-form-urlencoded" |
| 131 | 131 | * |
| 132 | - * @return bool|string |
|
| 132 | + * @return boolean |
|
| 133 | 133 | */ |
| 134 | 134 | public function getUrlEncoding() |
| 135 | 135 | { |
@@ -2,8 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | namespace Guzzle\Http; |
| 4 | 4 | |
| 5 | -use Guzzle\Stream\StreamInterface; |
|
| 6 | - |
|
| 7 | 5 | /** |
| 8 | 6 | * EntityBody decorator used to return only a subset of an entity body |
| 9 | 7 | */ |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | * @param string $password Password of the URL |
| 117 | 117 | * @param int $port Port of the URL |
| 118 | 118 | * @param string $path Path of the URL |
| 119 | - * @param QueryString|array|string $query Query string of the URL |
|
| 119 | + * @param QueryString $query Query string of the URL |
|
| 120 | 120 | * @param string $fragment Fragment of the URL |
| 121 | 121 | */ |
| 122 | 122 | public function __construct($scheme, $host, $username = null, $password = null, $port = null, $path = null, QueryString $query = null, $fragment = null) |
@@ -543,6 +543,9 @@ discard block |
||
| 543 | 543 | return $this; |
| 544 | 544 | } |
| 545 | 545 | |
| 546 | + /** |
|
| 547 | + * @param boolean $strictRfc386 |
|
| 548 | + */ |
|
| 546 | 549 | private function addQuery(QueryString $new, $strictRfc386) |
| 547 | 550 | { |
| 548 | 551 | if (!$strictRfc386) { |
@@ -25,7 +25,7 @@ |
||
| 25 | 25 | protected $defaultTtl; |
| 26 | 26 | |
| 27 | 27 | /** |
| 28 | - * @param mixed $cache Cache used to store cache data |
|
| 28 | + * @param CacheAdapterInterface $cache Cache used to store cache data |
|
| 29 | 29 | * @param string $keyPrefix Provide an optional key prefix to prefix on all cache keys |
| 30 | 30 | * @param int $defaultTtl Default cache TTL |
| 31 | 31 | */ |
@@ -24,7 +24,7 @@ discard block |
||
| 24 | 24 | /** |
| 25 | 25 | * Gets an array of invalid cookie characters |
| 26 | 26 | * |
| 27 | - * @return array |
|
| 27 | + * @return string |
|
| 28 | 28 | */ |
| 29 | 29 | protected static function getInvalidCharacters() |
| 30 | 30 | { |
@@ -225,7 +225,7 @@ discard block |
||
| 225 | 225 | /** |
| 226 | 226 | * Set the cookie version |
| 227 | 227 | * |
| 228 | - * @param string|int $version Version to set |
|
| 228 | + * @param integer $version Version to set |
|
| 229 | 229 | * |
| 230 | 230 | * @return Cookie |
| 231 | 231 | */ |
@@ -335,7 +335,7 @@ discard block |
||
| 335 | 335 | /** |
| 336 | 336 | * Set a list of acceptable ports this cookie can be used with |
| 337 | 337 | * |
| 338 | - * @param array $ports Array of acceptable ports |
|
| 338 | + * @param integer[] $ports Array of acceptable ports |
|
| 339 | 339 | * |
| 340 | 340 | * @return Cookie |
| 341 | 341 | */ |
@@ -69,7 +69,7 @@ discard block |
||
| 69 | 69 | * Request before-send event handler |
| 70 | 70 | * |
| 71 | 71 | * @param Event $event Event received |
| 72 | - * @return array |
|
| 72 | + * @return Collection |
|
| 73 | 73 | * @throws \InvalidArgumentException |
| 74 | 74 | */ |
| 75 | 75 | public function onRequestBeforeSend(Event $event) |
@@ -105,7 +105,7 @@ discard block |
||
| 105 | 105 | /** |
| 106 | 106 | * Builds the Authorization header for a request |
| 107 | 107 | * |
| 108 | - * @param array $authorizationParams Associative array of authorization parameters |
|
| 108 | + * @param Collection $authorizationParams Associative array of authorization parameters |
|
| 109 | 109 | * |
| 110 | 110 | * @return string |
| 111 | 111 | */ |
@@ -168,8 +168,8 @@ discard block |
||
| 168 | 168 | /** |
| 169 | 169 | * Get the oauth parameters as named by the oauth spec |
| 170 | 170 | * |
| 171 | - * @param $timestamp |
|
| 172 | - * @param $nonce |
|
| 171 | + * @param integer $timestamp |
|
| 172 | + * @param string $nonce |
|
| 173 | 173 | * @return Collection |
| 174 | 174 | */ |
| 175 | 175 | protected function getOauthParams($timestamp, $nonce) |
@@ -237,7 +237,7 @@ discard block |
||
| 237 | 237 | * overwritten e.g. the Flickr API incorrectly adds the post fields when the Content-Type |
| 238 | 238 | * is 'application/x-www-form-urlencoded' |
| 239 | 239 | * |
| 240 | - * @param $request |
|
| 240 | + * @param RequestInterface $request |
|
| 241 | 241 | * @return bool Whether the post fields should be signed or not |
| 242 | 242 | */ |
| 243 | 243 | public function shouldPostFieldsBeSigned($request) |
@@ -6,7 +6,6 @@ |
||
| 6 | 6 | use Guzzle\Common\Collection; |
| 7 | 7 | use Guzzle\Http\Message\RequestInterface; |
| 8 | 8 | use Guzzle\Http\Message\EntityEnclosingRequestInterface; |
| 9 | -use Guzzle\Http\QueryString; |
|
| 10 | 9 | use Guzzle\Http\Url; |
| 11 | 10 | use Symfony\Component\EventDispatcher\EventSubscriberInterface; |
| 12 | 11 | |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | * @param string $method Name of the command object to instantiate |
| 69 | 69 | * @param array $args Arguments to pass to the command |
| 70 | 70 | * |
| 71 | - * @return mixed Returns the result of the command |
|
| 71 | + * @return \Guzzle\Http\Message\Response Returns the result of the command |
|
| 72 | 72 | * @throws BadMethodCallException when a command is not found |
| 73 | 73 | */ |
| 74 | 74 | public function __call($method, $args) |
@@ -181,7 +181,7 @@ discard block |
||
| 181 | 181 | /** |
| 182 | 182 | * Get the inflector used with the client |
| 183 | 183 | * |
| 184 | - * @return self |
|
| 184 | + * @return InflectorInterface |
|
| 185 | 185 | */ |
| 186 | 186 | public function getInflector() |
| 187 | 187 | { |