forked from GNUsocial/gnu-social
[COMPOSER] Added predis/predis and updated packages
This commit is contained in:
committed by
Diogo Cordeiro
parent
0bb35d7e7f
commit
630a578e1d
39
vendor/php-http/client-common/src/Exception/BatchException.php
vendored
Normal file
39
vendor/php-http/client-common/src/Exception/BatchException.php
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
namespace Http\Client\Common\Exception;
|
||||
|
||||
use Http\Client\Exception\TransferException;
|
||||
use Http\Client\Common\BatchResult;
|
||||
|
||||
/**
|
||||
* This exception is thrown when HttpClient::sendRequests led to at least one failure.
|
||||
*
|
||||
* It gives access to a BatchResult with the request-exception and request-response pairs.
|
||||
*
|
||||
* @author Márk Sági-Kazár <mark.sagikazar@gmail.com>
|
||||
*/
|
||||
final class BatchException extends TransferException
|
||||
{
|
||||
/**
|
||||
* @var BatchResult
|
||||
*/
|
||||
private $result;
|
||||
|
||||
/**
|
||||
* @param BatchResult $result
|
||||
*/
|
||||
public function __construct(BatchResult $result)
|
||||
{
|
||||
$this->result = $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the BatchResult that contains all responses and exceptions.
|
||||
*
|
||||
* @return BatchResult
|
||||
*/
|
||||
public function getResult()
|
||||
{
|
||||
return $this->result;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user