From 33ebb53bbb069cfbb5b13f375c4a8d1810cfc2cc Mon Sep 17 00:00:00 2001 From: Max Boesing Date: Wed, 7 Oct 2015 15:31:58 +0200 Subject: [PATCH 1/2] Add RequestInterface::getPost to ensure correct code completion in IDE Fixes #29 --- src/RequestInterface.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/RequestInterface.php b/src/RequestInterface.php index c2bac316d..3a6b5647c 100644 --- a/src/RequestInterface.php +++ b/src/RequestInterface.php @@ -11,4 +11,5 @@ interface RequestInterface extends MessageInterface { + public function getPost(); } From 0b716e58b4e9c3740b14eff7c84ca11454f6793a Mon Sep 17 00:00:00 2001 From: Max Boesing Date: Wed, 7 Oct 2015 15:35:40 +0200 Subject: [PATCH 2/2] Fixed RequestInterface::getPost PhpDocBlock and added method parameters --- src/RequestInterface.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/RequestInterface.php b/src/RequestInterface.php index 3a6b5647c..944de72e9 100644 --- a/src/RequestInterface.php +++ b/src/RequestInterface.php @@ -11,5 +11,12 @@ interface RequestInterface extends MessageInterface { - public function getPost(); + /** + * Return the parameter container responsible for post parameters or a single post parameter. + * + * @param string|null $name Parameter name to retrieve, or null to get the whole container. + * @param mixed|null $default Default value to use when the parameter is missing. + * @return \Zend\Stdlib\ParametersInterface|mixed + */ + public function getPost($name = null, $default = null) }