/home/mip/www/img/credit/datatables/http-client.tar
LICENSE000064400000002075151520411640005554 0ustar00Copyright (c) 2017 PHP Framework Interoperability Group

Permission is hereby granted, free of charge, to any person obtaining a copy 
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights 
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
copies of the Software, and to permit persons to whom the Software is 
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in 
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
src/RequestExceptionInterface.php000064400000001112151520411640013166 0ustar00<?php

namespace Psr\Http\Client;

use Psr\Http\Message\RequestInterface;

/**
 * Exception for when a request failed.
 *
 * Examples:
 *      - Request is invalid (e.g. method is missing)
 *      - Runtime request errors (e.g. the body stream is not seekable)
 */
interface RequestExceptionInterface extends ClientExceptionInterface
{
    /**
     * Returns the request.
     *
     * The request object MAY be a different object from the one passed to ClientInterface::sendRequest()
     *
     * @return RequestInterface
     */
    public function getRequest(): RequestInterface;
}
src/ClientInterface.php000064400000000764151520411640011111 0ustar00<?php

namespace Psr\Http\Client;

use Psr\Http\Message\RequestInterface;
use Psr\Http\Message\ResponseInterface;

interface ClientInterface
{
    /**
     * Sends a PSR-7 request and returns a PSR-7 response.
     *
     * @param RequestInterface $request
     *
     * @return ResponseInterface
     *
     * @throws \Psr\Http\Client\ClientExceptionInterface If an error happens while processing the request.
     */
    public function sendRequest(RequestInterface $request): ResponseInterface;
}
src/ClientExceptionInterface.php000064400000000253151520411640012761 0ustar00<?php

namespace Psr\Http\Client;

/**
 * Every HTTP client related exception MUST implement this interface.
 */
interface ClientExceptionInterface extends \Throwable
{
}
src/NetworkExceptionInterface.php000064400000001222151520411640013171 0ustar00<?php

namespace Psr\Http\Client;

use Psr\Http\Message\RequestInterface;

/**
 * Thrown when the request cannot be completed because of network issues.
 *
 * There is no response object as this exception is thrown when no response has been received.
 *
 * Example: the target host name can not be resolved or the connection failed.
 */
interface NetworkExceptionInterface extends ClientExceptionInterface
{
    /**
     * Returns the request.
     *
     * The request object MAY be a different object from the one passed to ClientInterface::sendRequest()
     *
     * @return RequestInterface
     */
    public function getRequest(): RequestInterface;
}
CHANGELOG.md000064400000000771151520411640006361 0ustar00# Changelog

All notable changes to this project will be documented in this file, in reverse chronological order by release.

## 1.0.3

Add `source` link in composer.json. No code changes.

## 1.0.2

Allow PSR-7 (psr/http-message) 2.0. No code changes.

## 1.0.1

Allow installation with PHP 8. No code changes.

## 1.0.0

First stable release. No changes since 0.3.0.

## 0.3.0

Added Interface suffix on exceptions
 
## 0.2.0 

All exceptions are in `Psr\Http\Client` namespace

## 0.1.0

First release
composer.json000064400000001327151520411640007270 0ustar00{
    "name": "psr/http-client",
    "description": "Common interface for HTTP clients",
    "keywords": ["psr", "psr-18", "http", "http-client"],
    "homepage": "https://github.com/php-fig/http-client",
    "license": "MIT",
    "authors": [
        {
            "name": "PHP-FIG",
            "homepage": "https://www.php-fig.org/"
        }
    ],
    "support": {
        "source": "https://github.com/php-fig/http-client"
    },
    "require": {
        "php": "^7.0 || ^8.0",
        "psr/http-message": "^1.0 || ^2.0"
    },
    "autoload": {
        "psr-4": {
            "Psr\\Http\\Client\\": "src/"
        }
    },
    "extra": {
        "branch-alias": {
            "dev-master": "1.0.x-dev"
        }
    }
}
README.md000064400000001045151520411640006022 0ustar00HTTP Client
===========

This repository holds all the common code related to [PSR-18 (HTTP Client)][psr-url].

Note that this is not a HTTP Client implementation of its own. It is merely abstractions that describe the components of a HTTP Client.

The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist.

[psr-url]: https://www.php-fig.org/psr/psr-18
[package-url]: https://packagist.org/packages/psr/http-client
[implementation-url]: https://packagist.org/providers/psr/http-client-implementation