Merge pull request #12852 from bancer/2.x-code-style

Improve documentation
This commit is contained in:
Mark Story 2018-12-28 08:52:05 -08:00 committed by GitHub
commit 29d49214c4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -251,7 +251,7 @@ class HttpSocket extends CakeSocket {
* method and provide a more granular interface.
*
* @param string|array $request Either an URI string, or an array defining host/uri
* @return mixed false on error, HttpSocketResponse on success
* @return false|HttpSocketResponse false on error, HttpSocketResponse on success
* @throws SocketException
*/
public function request($request = array()) {
@ -449,7 +449,7 @@ class HttpSocket extends CakeSocket {
* @param string|array $uri URI to request. Either a string uri, or a uri array, see HttpSocket::_parseUri()
* @param array $query Querystring parameters to append to URI
* @param array $request An indexed array with indexes such as 'method' or uri
* @return mixed Result of request, either false on failure or the response to the request.
* @return false|HttpSocketResponse Result of request, either false on failure or the response to the request.
*/
public function get($uri = null, $query = array(), $request = array()) {
if (!empty($query)) {
@ -475,7 +475,7 @@ class HttpSocket extends CakeSocket {
* @param string|array $uri URI to request. Either a string URI, or a URI array, see HttpSocket::_parseUri()
* @param array $query Querystring parameters to append to URI
* @param array $request An indexed array with indexes such as 'method' or uri
* @return mixed Result of request, either false on failure or the response to the request.
* @return false|HttpSocketResponse Result of request, either false on failure or the response to the request.
*/
public function head($uri = null, $query = array(), $request = array()) {
if (!empty($query)) {
@ -507,7 +507,7 @@ class HttpSocket extends CakeSocket {
* @param string|array $uri URI to request. See HttpSocket::_parseUri()
* @param array $data Array of request body data keys and values.
* @param array $request An indexed array with indexes such as 'method' or uri
* @return mixed Result of request, either false on failure or the response to the request.
* @return false|HttpSocketResponse Result of request, either false on failure or the response to the request.
*/
public function post($uri = null, $data = array(), $request = array()) {
$request = Hash::merge(array('method' => 'POST', 'uri' => $uri, 'body' => $data), $request);
@ -520,7 +520,7 @@ class HttpSocket extends CakeSocket {
* @param string|array $uri URI to request, See HttpSocket::_parseUri()
* @param array $data Array of request body data keys and values.
* @param array $request An indexed array with indexes such as 'method' or uri
* @return mixed Result of request
* @return false|HttpSocketResponse Result of request
*/
public function put($uri = null, $data = array(), $request = array()) {
$request = Hash::merge(array('method' => 'PUT', 'uri' => $uri, 'body' => $data), $request);
@ -533,7 +533,7 @@ class HttpSocket extends CakeSocket {
* @param string|array $uri URI to request, See HttpSocket::_parseUri()
* @param array $data Array of request body data keys and values.
* @param array $request An indexed array with indexes such as 'method' or uri
* @return mixed Result of request
* @return false|HttpSocketResponse Result of request
*/
public function patch($uri = null, $data = array(), $request = array()) {
$request = Hash::merge(array('method' => 'PATCH', 'uri' => $uri, 'body' => $data), $request);
@ -546,7 +546,7 @@ class HttpSocket extends CakeSocket {
* @param string|array $uri URI to request (see {@link _parseUri()})
* @param array $data Array of request body data keys and values.
* @param array $request An indexed array with indexes such as 'method' or uri
* @return mixed Result of request
* @return false|HttpSocketResponse Result of request
*/
public function delete($uri = null, $data = array(), $request = array()) {
$request = Hash::merge(array('method' => 'DELETE', 'uri' => $uri, 'body' => $data), $request);