Skip to content

Commit

Permalink
Syncs interfaces with proposal
Browse files Browse the repository at this point in the history
  • Loading branch information
sagikazarmark committed Oct 13, 2014
1 parent 69271a5 commit dae7a8e
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 14 deletions.
16 changes: 8 additions & 8 deletions src/IncomingRequestInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ interface IncomingRequestInterface extends RequestInterface
*
* The return value can be either an array or an object that acts like
* an array (e.g., implements ArrayAccess, or an ArrayObject).
*
*
* @return array|\ArrayAccess
*/
public function getCookieParams();
Expand All @@ -39,9 +39,9 @@ public function getCookieParams();
*
* The value provided should be an array or array-like object
* (e.g., implements ArrayAccess, or an ArrayObject).
*
*
* @param array|\ArrayAccess $cookies Cookie values/structs
*
*
* @return void
*/
public function setCookieParams($cookies);
Expand All @@ -57,7 +57,7 @@ public function setCookieParams($cookies);
*
* The return value can be either an array or an object that acts like
* an array (e.g., implements ArrayAccess, or an ArrayObject).
*
*
* @return array
*/
public function getQueryParams();
Expand All @@ -74,7 +74,7 @@ public function getQueryParams();
*
* The return value can be either an array or an object that acts like
* an array (e.g., implements ArrayAccess, or an ArrayObject).
*
*
* @return array Upload file(s) metadata, if any.
*/
public function getFileParams();
Expand All @@ -88,7 +88,7 @@ public function getFileParams();
*
* In other cases, the parent getBody() method should be used to retrieve
* the body content.
*
*
* @return array|object The deserialized body parameters, if any. These may
* be either an array or an object, though an array or
* array-like object is recommended.
Expand All @@ -101,7 +101,7 @@ public function getBodyParams();
* If the body content can be deserialized, the values obtained may then
* be injected into the response using this method. This method will
* typically be invoked by a factory marshaling request parameters.
*
*
* @param array|object $values The deserialized body parameters, if any.
* These may be either an array or an object,
* though an array or array-like object is
Expand All @@ -128,7 +128,7 @@ public function getPathParams();
* If a router or similar is used to match against the path and/or request,
* this method can be used to inject the request with the results, so long
* as those results can be represented as an array or array-like object.
*
*
* @param array|\ArrayAccess $values Path parameters matched by routing
*
* @return void
Expand Down
17 changes: 12 additions & 5 deletions src/MessageInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,9 @@ public function getHeaderAsArray($header);
* or an array of strings.
*
* @param string $header Header name
* @param string|string[] $value Header value(s)
* @param string|string[]|object|object[] $value Header value(s). Values may
* be objects as long as they
* can be cast to strings.
*
* @return void
*/
Expand All @@ -115,8 +117,9 @@ public function setHeader($header, $value);
/**
* Sets headers, replacing any headers that have already been set on the message.
*
* The array keys MUST be a string. The array values must be either a
* string or an array of strings.
* The array keys MUST be a string. Each array value MUST be either a string
* or object, or array of strings and/or objects; any object used as a
* header value MUST be able to be cast to a string.
*
* @param array $headers Headers to set.
*
Expand All @@ -131,7 +134,8 @@ public function setHeaders(array $headers);
* value will be appended to the existing list.
*
* @param string $header Header name to add
* @param string $value Value of the header
* @param string|object $value Value of the header; object is allowed if it
* can be cast to a string.
*
* @return void
*/
Expand All @@ -141,7 +145,10 @@ public function addHeader($header, $value);
* Merges in an associative array of headers.
*
* Each array key MUST be a string representing the case-insensitive name
* of a header. Each value MUST be either a string or an array of strings.
* of a header. Each value MUST be either a string or object, or array of
* strings and/or objects; any object used as a header value MUST be able
* to be cast to a string.
*
* For each value, the value is appended to any existing header of the same
* name, or, if a header does not already exist by the given name, then the
* header is added.
Expand Down
6 changes: 5 additions & 1 deletion src/StreamableInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,11 @@
namespace Psr\Http\Message;

/**
* Describes a stream instance.
* Describes streamable content.
*
* Typically, an instance will wrap a PHP stream; this interface provides
* a wrapper around the most common operations, including serialization of
* the entire stream to a string.
*/
interface StreamableInterface
{
Expand Down

0 comments on commit dae7a8e

Please sign in to comment.