the middle of the idiots
This commit is contained in:
		
							
								
								
									
										3
									
								
								qwen/php/vendor/psr/container/.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								qwen/php/vendor/psr/container/.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,3 @@
 | 
			
		||||
composer.lock
 | 
			
		||||
composer.phar
 | 
			
		||||
/vendor/
 | 
			
		||||
							
								
								
									
										21
									
								
								qwen/php/vendor/psr/container/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								qwen/php/vendor/psr/container/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,21 @@
 | 
			
		||||
The MIT License (MIT)
 | 
			
		||||
 | 
			
		||||
Copyright (c) 2013-2016 container-interop
 | 
			
		||||
Copyright (c) 2016 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.
 | 
			
		||||
							
								
								
									
										13
									
								
								qwen/php/vendor/psr/container/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								qwen/php/vendor/psr/container/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,13 @@
 | 
			
		||||
Container interface
 | 
			
		||||
==============
 | 
			
		||||
 | 
			
		||||
This repository holds all interfaces related to [PSR-11 (Container Interface)][psr-url].
 | 
			
		||||
 | 
			
		||||
Note that this is not a Container implementation of its own. It is merely abstractions that describe the components of a Dependency Injection Container.
 | 
			
		||||
 | 
			
		||||
The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist.
 | 
			
		||||
 | 
			
		||||
[psr-url]: https://www.php-fig.org/psr/psr-11/
 | 
			
		||||
[package-url]: https://packagist.org/packages/psr/container
 | 
			
		||||
[implementation-url]: https://packagist.org/providers/psr/container-implementation
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										27
									
								
								qwen/php/vendor/psr/container/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										27
									
								
								qwen/php/vendor/psr/container/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,27 @@
 | 
			
		||||
{
 | 
			
		||||
    "name": "psr/container",
 | 
			
		||||
    "type": "library",
 | 
			
		||||
    "description": "Common Container Interface (PHP FIG PSR-11)",
 | 
			
		||||
    "keywords": ["psr", "psr-11", "container", "container-interop", "container-interface"],
 | 
			
		||||
    "homepage": "https://github.com/php-fig/container",
 | 
			
		||||
    "license": "MIT",
 | 
			
		||||
    "authors": [
 | 
			
		||||
        {
 | 
			
		||||
            "name": "PHP-FIG",
 | 
			
		||||
            "homepage": "https://www.php-fig.org/"
 | 
			
		||||
        }
 | 
			
		||||
    ],
 | 
			
		||||
    "require": {
 | 
			
		||||
        "php": ">=7.4.0"
 | 
			
		||||
    },
 | 
			
		||||
    "autoload": {
 | 
			
		||||
        "psr-4": {
 | 
			
		||||
            "Psr\\Container\\": "src/"
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    "extra": {
 | 
			
		||||
        "branch-alias": {
 | 
			
		||||
            "dev-master": "2.0.x-dev"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										12
									
								
								qwen/php/vendor/psr/container/src/ContainerExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								qwen/php/vendor/psr/container/src/ContainerExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Container;
 | 
			
		||||
 | 
			
		||||
use Throwable;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Base interface representing a generic exception in a container.
 | 
			
		||||
 */
 | 
			
		||||
interface ContainerExceptionInterface extends Throwable
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										36
									
								
								qwen/php/vendor/psr/container/src/ContainerInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										36
									
								
								qwen/php/vendor/psr/container/src/ContainerInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,36 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
declare(strict_types=1);
 | 
			
		||||
 | 
			
		||||
namespace Psr\Container;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Describes the interface of a container that exposes methods to read its entries.
 | 
			
		||||
 */
 | 
			
		||||
interface ContainerInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Finds an entry of the container by its identifier and returns it.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $id Identifier of the entry to look for.
 | 
			
		||||
     *
 | 
			
		||||
     * @throws NotFoundExceptionInterface  No entry was found for **this** identifier.
 | 
			
		||||
     * @throws ContainerExceptionInterface Error while retrieving the entry.
 | 
			
		||||
     *
 | 
			
		||||
     * @return mixed Entry.
 | 
			
		||||
     */
 | 
			
		||||
    public function get(string $id);
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns true if the container can return an entry for the given identifier.
 | 
			
		||||
     * Returns false otherwise.
 | 
			
		||||
     *
 | 
			
		||||
     * `has($id)` returning true does not mean that `get($id)` will not throw an exception.
 | 
			
		||||
     * It does however mean that `get($id)` will not throw a `NotFoundExceptionInterface`.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $id Identifier of the entry to look for.
 | 
			
		||||
     *
 | 
			
		||||
     * @return bool
 | 
			
		||||
     */
 | 
			
		||||
    public function has(string $id): bool;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										10
									
								
								qwen/php/vendor/psr/container/src/NotFoundExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								qwen/php/vendor/psr/container/src/NotFoundExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,10 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Container;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * No entry was found in the container.
 | 
			
		||||
 */
 | 
			
		||||
interface NotFoundExceptionInterface extends ContainerExceptionInterface
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										31
									
								
								qwen/php/vendor/psr/http-client/CHANGELOG.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								qwen/php/vendor/psr/http-client/CHANGELOG.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,31 @@
 | 
			
		||||
# 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
 | 
			
		||||
							
								
								
									
										19
									
								
								qwen/php/vendor/psr/http-client/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								qwen/php/vendor/psr/http-client/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
Copyright (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.
 | 
			
		||||
							
								
								
									
										12
									
								
								qwen/php/vendor/psr/http-client/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								qwen/php/vendor/psr/http-client/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
			
		||||
HTTP 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
 | 
			
		||||
							
								
								
									
										30
									
								
								qwen/php/vendor/psr/http-client/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										30
									
								
								qwen/php/vendor/psr/http-client/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,30 @@
 | 
			
		||||
{
 | 
			
		||||
    "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"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										10
									
								
								qwen/php/vendor/psr/http-client/src/ClientExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								qwen/php/vendor/psr/http-client/src/ClientExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,10 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Client;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Every HTTP client related exception MUST implement this interface.
 | 
			
		||||
 */
 | 
			
		||||
interface ClientExceptionInterface extends \Throwable
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										20
									
								
								qwen/php/vendor/psr/http-client/src/ClientInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								qwen/php/vendor/psr/http-client/src/ClientInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,20 @@
 | 
			
		||||
<?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;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										24
									
								
								qwen/php/vendor/psr/http-client/src/NetworkExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								qwen/php/vendor/psr/http-client/src/NetworkExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
			
		||||
<?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;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										24
									
								
								qwen/php/vendor/psr/http-client/src/RequestExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								qwen/php/vendor/psr/http-client/src/RequestExceptionInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
			
		||||
<?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;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										21
									
								
								qwen/php/vendor/psr/http-factory/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								qwen/php/vendor/psr/http-factory/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,21 @@
 | 
			
		||||
MIT License
 | 
			
		||||
 | 
			
		||||
Copyright (c) 2018 PHP-FIG
 | 
			
		||||
 | 
			
		||||
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.
 | 
			
		||||
							
								
								
									
										12
									
								
								qwen/php/vendor/psr/http-factory/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								qwen/php/vendor/psr/http-factory/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
			
		||||
HTTP Factories
 | 
			
		||||
==============
 | 
			
		||||
 | 
			
		||||
This repository holds all interfaces related to [PSR-17 (HTTP Factories)][psr-url].
 | 
			
		||||
 | 
			
		||||
Note that this is not a HTTP Factory implementation of its own. It is merely interfaces that describe the components of a HTTP Factory.
 | 
			
		||||
 | 
			
		||||
The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist.
 | 
			
		||||
 | 
			
		||||
[psr-url]: https://www.php-fig.org/psr/psr-17/
 | 
			
		||||
[package-url]: https://packagist.org/packages/psr/http-factory
 | 
			
		||||
[implementation-url]: https://packagist.org/providers/psr/http-factory-implementation
 | 
			
		||||
							
								
								
									
										38
									
								
								qwen/php/vendor/psr/http-factory/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										38
									
								
								qwen/php/vendor/psr/http-factory/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,38 @@
 | 
			
		||||
{
 | 
			
		||||
    "name": "psr/http-factory",
 | 
			
		||||
    "description": "PSR-17: Common interfaces for PSR-7 HTTP message factories",
 | 
			
		||||
    "keywords": [
 | 
			
		||||
        "psr",
 | 
			
		||||
        "psr-7",
 | 
			
		||||
        "psr-17",
 | 
			
		||||
        "http",
 | 
			
		||||
        "factory",
 | 
			
		||||
        "message",
 | 
			
		||||
        "request",
 | 
			
		||||
        "response"
 | 
			
		||||
    ],
 | 
			
		||||
    "license": "MIT",
 | 
			
		||||
    "authors": [
 | 
			
		||||
        {
 | 
			
		||||
            "name": "PHP-FIG",
 | 
			
		||||
            "homepage": "https://www.php-fig.org/"
 | 
			
		||||
        }
 | 
			
		||||
    ],
 | 
			
		||||
    "support": {
 | 
			
		||||
        "source": "https://github.com/php-fig/http-factory"
 | 
			
		||||
    },
 | 
			
		||||
    "require": {
 | 
			
		||||
        "php": ">=7.1",
 | 
			
		||||
        "psr/http-message": "^1.0 || ^2.0"
 | 
			
		||||
    },
 | 
			
		||||
    "autoload": {
 | 
			
		||||
        "psr-4": {
 | 
			
		||||
            "Psr\\Http\\Message\\": "src/"
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    "extra": {
 | 
			
		||||
        "branch-alias": {
 | 
			
		||||
            "dev-master": "1.0.x-dev"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										18
									
								
								qwen/php/vendor/psr/http-factory/src/RequestFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								qwen/php/vendor/psr/http-factory/src/RequestFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,18 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
interface RequestFactoryInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new request.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $method The HTTP method associated with the request.
 | 
			
		||||
     * @param UriInterface|string $uri The URI associated with the request. If
 | 
			
		||||
     *     the value is a string, the factory MUST create a UriInterface
 | 
			
		||||
     *     instance based on it.
 | 
			
		||||
     *
 | 
			
		||||
     * @return RequestInterface
 | 
			
		||||
     */
 | 
			
		||||
    public function createRequest(string $method, $uri): RequestInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										18
									
								
								qwen/php/vendor/psr/http-factory/src/ResponseFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								qwen/php/vendor/psr/http-factory/src/ResponseFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,18 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
interface ResponseFactoryInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new response.
 | 
			
		||||
     *
 | 
			
		||||
     * @param int $code HTTP status code; defaults to 200
 | 
			
		||||
     * @param string $reasonPhrase Reason phrase to associate with status code
 | 
			
		||||
     *     in generated response; if none is provided implementations MAY use
 | 
			
		||||
     *     the defaults as suggested in the HTTP specification.
 | 
			
		||||
     *
 | 
			
		||||
     * @return ResponseInterface
 | 
			
		||||
     */
 | 
			
		||||
    public function createResponse(int $code = 200, string $reasonPhrase = ''): ResponseInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										24
									
								
								qwen/php/vendor/psr/http-factory/src/ServerRequestFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								qwen/php/vendor/psr/http-factory/src/ServerRequestFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
interface ServerRequestFactoryInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new server request.
 | 
			
		||||
     *
 | 
			
		||||
     * Note that server-params are taken precisely as given - no parsing/processing
 | 
			
		||||
     * of the given values is performed, and, in particular, no attempt is made to
 | 
			
		||||
     * determine the HTTP method or URI, which must be provided explicitly.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $method The HTTP method associated with the request.
 | 
			
		||||
     * @param UriInterface|string $uri The URI associated with the request. If
 | 
			
		||||
     *     the value is a string, the factory MUST create a UriInterface
 | 
			
		||||
     *     instance based on it.
 | 
			
		||||
     * @param array $serverParams Array of SAPI parameters with which to seed
 | 
			
		||||
     *     the generated request instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @return ServerRequestInterface
 | 
			
		||||
     */
 | 
			
		||||
    public function createServerRequest(string $method, $uri, array $serverParams = []): ServerRequestInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										45
									
								
								qwen/php/vendor/psr/http-factory/src/StreamFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								qwen/php/vendor/psr/http-factory/src/StreamFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,45 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
interface StreamFactoryInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new stream from a string.
 | 
			
		||||
     *
 | 
			
		||||
     * The stream SHOULD be created with a temporary resource.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $content String content with which to populate the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @return StreamInterface
 | 
			
		||||
     */
 | 
			
		||||
    public function createStream(string $content = ''): StreamInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a stream from an existing file.
 | 
			
		||||
     *
 | 
			
		||||
     * The file MUST be opened using the given mode, which may be any mode
 | 
			
		||||
     * supported by the `fopen` function.
 | 
			
		||||
     *
 | 
			
		||||
     * The `$filename` MAY be any string supported by `fopen()`.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $filename Filename or stream URI to use as basis of stream.
 | 
			
		||||
     * @param string $mode Mode with which to open the underlying filename/stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @return StreamInterface
 | 
			
		||||
     * @throws \RuntimeException If the file cannot be opened.
 | 
			
		||||
     * @throws \InvalidArgumentException If the mode is invalid.
 | 
			
		||||
     */
 | 
			
		||||
    public function createStreamFromFile(string $filename, string $mode = 'r'): StreamInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new stream from an existing resource.
 | 
			
		||||
     *
 | 
			
		||||
     * The stream MUST be readable and may be writable.
 | 
			
		||||
     *
 | 
			
		||||
     * @param resource $resource PHP resource to use as basis of stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @return StreamInterface
 | 
			
		||||
     */
 | 
			
		||||
    public function createStreamFromResource($resource): StreamInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										34
									
								
								qwen/php/vendor/psr/http-factory/src/UploadedFileFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										34
									
								
								qwen/php/vendor/psr/http-factory/src/UploadedFileFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,34 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
interface UploadedFileFactoryInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new uploaded file.
 | 
			
		||||
     *
 | 
			
		||||
     * If a size is not provided it will be determined by checking the size of
 | 
			
		||||
     * the file.
 | 
			
		||||
     *
 | 
			
		||||
     * @see http://php.net/manual/features.file-upload.post-method.php
 | 
			
		||||
     * @see http://php.net/manual/features.file-upload.errors.php
 | 
			
		||||
     *
 | 
			
		||||
     * @param StreamInterface $stream Underlying stream representing the
 | 
			
		||||
     *     uploaded file content.
 | 
			
		||||
     * @param int|null $size in bytes
 | 
			
		||||
     * @param int $error PHP file upload error
 | 
			
		||||
     * @param string|null $clientFilename Filename as provided by the client, if any.
 | 
			
		||||
     * @param string|null $clientMediaType Media type as provided by the client, if any.
 | 
			
		||||
     *
 | 
			
		||||
     * @return UploadedFileInterface
 | 
			
		||||
     *
 | 
			
		||||
     * @throws \InvalidArgumentException If the file resource is not readable.
 | 
			
		||||
     */
 | 
			
		||||
    public function createUploadedFile(
 | 
			
		||||
        StreamInterface $stream,
 | 
			
		||||
        ?int $size = null,
 | 
			
		||||
        int $error = \UPLOAD_ERR_OK,
 | 
			
		||||
        ?string $clientFilename = null,
 | 
			
		||||
        ?string $clientMediaType = null
 | 
			
		||||
    ): UploadedFileInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										17
									
								
								qwen/php/vendor/psr/http-factory/src/UriFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								qwen/php/vendor/psr/http-factory/src/UriFactoryInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,17 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
interface UriFactoryInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new URI.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $uri
 | 
			
		||||
     *
 | 
			
		||||
     * @return UriInterface
 | 
			
		||||
     *
 | 
			
		||||
     * @throws \InvalidArgumentException If the given URI cannot be parsed.
 | 
			
		||||
     */
 | 
			
		||||
    public function createUri(string $uri = ''): UriInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										36
									
								
								qwen/php/vendor/psr/http-message/CHANGELOG.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										36
									
								
								qwen/php/vendor/psr/http-message/CHANGELOG.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,36 @@
 | 
			
		||||
# Changelog
 | 
			
		||||
 | 
			
		||||
All notable changes to this project will be documented in this file, in reverse chronological order by release.
 | 
			
		||||
 | 
			
		||||
## 1.0.1 - 2016-08-06
 | 
			
		||||
 | 
			
		||||
### Added
 | 
			
		||||
 | 
			
		||||
- Nothing.
 | 
			
		||||
 | 
			
		||||
### Deprecated
 | 
			
		||||
 | 
			
		||||
- Nothing.
 | 
			
		||||
 | 
			
		||||
### Removed
 | 
			
		||||
 | 
			
		||||
- Nothing.
 | 
			
		||||
 | 
			
		||||
### Fixed
 | 
			
		||||
 | 
			
		||||
- Updated all `@return self` annotation references in interfaces to use
 | 
			
		||||
  `@return static`, which more closelly follows the semantics of the
 | 
			
		||||
  specification.
 | 
			
		||||
- Updated the `MessageInterface::getHeaders()` return annotation to use the
 | 
			
		||||
  value `string[][]`, indicating the format is a nested array of strings.
 | 
			
		||||
- Updated the `@link` annotation for `RequestInterface::withRequestTarget()`
 | 
			
		||||
  to point to the correct section of RFC 7230.
 | 
			
		||||
- Updated the `ServerRequestInterface::withUploadedFiles()` parameter annotation
 | 
			
		||||
  to add the parameter name (`$uploadedFiles`).
 | 
			
		||||
- Updated a `@throws` annotation for the `UploadedFileInterface::moveTo()`
 | 
			
		||||
  method to correctly reference the method parameter (it was referencing an
 | 
			
		||||
  incorrect parameter name previously).
 | 
			
		||||
 | 
			
		||||
## 1.0.0 - 2016-05-18
 | 
			
		||||
 | 
			
		||||
Initial stable release; reflects accepted PSR-7 specification.
 | 
			
		||||
							
								
								
									
										19
									
								
								qwen/php/vendor/psr/http-message/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								qwen/php/vendor/psr/http-message/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
Copyright (c) 2014 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.
 | 
			
		||||
							
								
								
									
										16
									
								
								qwen/php/vendor/psr/http-message/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								qwen/php/vendor/psr/http-message/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,16 @@
 | 
			
		||||
PSR Http Message
 | 
			
		||||
================
 | 
			
		||||
 | 
			
		||||
This repository holds all interfaces/classes/traits related to
 | 
			
		||||
[PSR-7](http://www.php-fig.org/psr/psr-7/).
 | 
			
		||||
 | 
			
		||||
Note that this is not a HTTP message implementation of its own. It is merely an
 | 
			
		||||
interface that describes a HTTP message. See the specification for more details.
 | 
			
		||||
 | 
			
		||||
Usage
 | 
			
		||||
-----
 | 
			
		||||
 | 
			
		||||
Before reading the usage guide we recommend reading the PSR-7 interfaces method list:
 | 
			
		||||
 | 
			
		||||
* [`PSR-7 Interfaces Method List`](docs/PSR7-Interfaces.md)
 | 
			
		||||
* [`PSR-7 Usage Guide`](docs/PSR7-Usage.md)
 | 
			
		||||
							
								
								
									
										26
									
								
								qwen/php/vendor/psr/http-message/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								qwen/php/vendor/psr/http-message/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,26 @@
 | 
			
		||||
{
 | 
			
		||||
    "name": "psr/http-message",
 | 
			
		||||
    "description": "Common interface for HTTP messages",
 | 
			
		||||
    "keywords": ["psr", "psr-7", "http", "http-message", "request", "response"],
 | 
			
		||||
    "homepage": "https://github.com/php-fig/http-message",
 | 
			
		||||
    "license": "MIT",
 | 
			
		||||
    "authors": [
 | 
			
		||||
        {
 | 
			
		||||
            "name": "PHP-FIG",
 | 
			
		||||
            "homepage": "https://www.php-fig.org/"
 | 
			
		||||
        }
 | 
			
		||||
    ],
 | 
			
		||||
    "require": {
 | 
			
		||||
        "php": "^7.2 || ^8.0"
 | 
			
		||||
    },
 | 
			
		||||
    "autoload": {
 | 
			
		||||
        "psr-4": {
 | 
			
		||||
            "Psr\\Http\\Message\\": "src/"
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    "extra": {
 | 
			
		||||
        "branch-alias": {
 | 
			
		||||
            "dev-master": "2.0.x-dev"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										130
									
								
								qwen/php/vendor/psr/http-message/docs/PSR7-Interfaces.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										130
									
								
								qwen/php/vendor/psr/http-message/docs/PSR7-Interfaces.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,130 @@
 | 
			
		||||
# Interfaces
 | 
			
		||||
 | 
			
		||||
The purpose of this list is to help in finding the methods when working with PSR-7. This can be considered as a cheatsheet for PSR-7 interfaces.
 | 
			
		||||
 | 
			
		||||
The interfaces defined in PSR-7 are the following:
 | 
			
		||||
 | 
			
		||||
| Class Name | Description |
 | 
			
		||||
|---|---|
 | 
			
		||||
| [Psr\Http\Message\MessageInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessagemessageinterface) | Representation of a HTTP message |
 | 
			
		||||
| [Psr\Http\Message\RequestInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessagerequestinterface) | Representation of an outgoing, client-side request. |
 | 
			
		||||
| [Psr\Http\Message\ServerRequestInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessageserverrequestinterface) | Representation of an incoming, server-side HTTP request. | 
 | 
			
		||||
| [Psr\Http\Message\ResponseInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessageresponseinterface) | Representation of an outgoing, server-side response. |
 | 
			
		||||
| [Psr\Http\Message\StreamInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessagestreaminterface) | Describes a data stream |
 | 
			
		||||
| [Psr\Http\Message\UriInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessageuriinterface) | Value object representing a URI. |
 | 
			
		||||
| [Psr\Http\Message\UploadedFileInterface](http://www.php-fig.org/psr/psr-7/#psrhttpmessageuploadedfileinterface) | Value object representing a file uploaded through an HTTP request. |
 | 
			
		||||
 | 
			
		||||
## `Psr\Http\Message\MessageInterface` Methods
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `getProtocolVersion()`             | Retrieve HTTP protocol version          |  1.0 or 1.1 |
 | 
			
		||||
| `withProtocolVersion($version)`    | Returns new message instance with given HTTP protocol version          |      |
 | 
			
		||||
| `getHeaders()`                     | Retrieve all HTTP Headers               | [Request Header List](https://en.wikipedia.org/wiki/List_of_HTTP_header_fields#Request_fields), [Response Header List](https://en.wikipedia.org/wiki/List_of_HTTP_header_fields#Response_fields)      |
 | 
			
		||||
| `hasHeader($name)`                 | Checks if HTTP Header with given name exists  | |
 | 
			
		||||
| `getHeader($name)`                 | Retrieves a array with the values for a single header | |
 | 
			
		||||
| `getHeaderLine($name)`             | Retrieves a comma-separated string of the values for a single header |  |
 | 
			
		||||
| `withHeader($name, $value)`        | Returns new message instance with given HTTP Header | if the header existed in the original instance, replaces the header value from the original message with the value provided when creating the new instance. |
 | 
			
		||||
| `withAddedHeader($name, $value)`   | Returns new message instance with appended value to given header | If header already exists value will be appended, if not a new header will be created |
 | 
			
		||||
| `withoutHeader($name)`             | Removes HTTP Header with given name| |
 | 
			
		||||
| `getBody()`                        | Retrieves the HTTP Message Body | Returns object implementing `StreamInterface`|
 | 
			
		||||
| `withBody(StreamInterface $body)`  | Returns new message instance with given HTTP Message Body | |
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## `Psr\Http\Message\RequestInterface` Methods
 | 
			
		||||
 | 
			
		||||
Same methods as `Psr\Http\Message\MessageInterface`  + the following methods:
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `getRequestTarget()`                | Retrieves the message's request target              | origin-form, absolute-form, authority-form, asterisk-form ([RFC7230](https://www.rfc-editor.org/rfc/rfc7230.txt)) |
 | 
			
		||||
| `withRequestTarget($requestTarget)` | Return a new message instance with the specific request-target |      |
 | 
			
		||||
| `getMethod()`                       | Retrieves the HTTP method of the request.  |  GET, HEAD, POST, PUT, DELETE, CONNECT, OPTIONS, TRACE (defined in [RFC7231](https://tools.ietf.org/html/rfc7231)), PATCH (defined in [RFC5789](https://tools.ietf.org/html/rfc5789)) |
 | 
			
		||||
| `withMethod($method)`               | Returns a new message instance with the provided HTTP method  | |
 | 
			
		||||
| `getUri()`                 | Retrieves the URI instance | |
 | 
			
		||||
| `withUri(UriInterface $uri, $preserveHost = false)` | Returns a new message instance with the provided URI |  |
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## `Psr\Http\Message\ServerRequestInterface` Methods
 | 
			
		||||
 | 
			
		||||
Same methods as `Psr\Http\Message\RequestInterface`  + the following methods:
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `getServerParams() `               | Retrieve server parameters  | Typically derived from `$_SERVER`  |
 | 
			
		||||
| `getCookieParams()`                | Retrieves cookies sent by the client to the server. | Typically derived from `$_COOKIES` |
 | 
			
		||||
| `withCookieParams(array $cookies)` |  Returns a new request instance with the specified cookies      |   | 
 | 
			
		||||
| `withQueryParams(array $query)` | Returns a new request instance with the specified query string arguments  |  |
 | 
			
		||||
| `getUploadedFiles()` | Retrieve normalized file upload data  |  |
 | 
			
		||||
| `withUploadedFiles(array $uploadedFiles)` | Returns a new request instance with the specified uploaded files  |  |
 | 
			
		||||
| `getParsedBody()` | Retrieve any parameters provided in the request body  |  |
 | 
			
		||||
| `withParsedBody($data)` | Returns a new request instance with the specified body parameters  |  |
 | 
			
		||||
| `getAttributes()` | Retrieve attributes derived from the request  |  |
 | 
			
		||||
| `getAttribute($name, $default = null)` | Retrieve a single derived request attribute  |  |
 | 
			
		||||
| `withAttribute($name, $value)` | Returns a new request instance with the specified derived request attribute  |  |
 | 
			
		||||
| `withoutAttribute($name)` | Returns a new request instance that without the specified derived request attribute  |  |
 | 
			
		||||
 | 
			
		||||
## `Psr\Http\Message\ResponseInterface` Methods:
 | 
			
		||||
 | 
			
		||||
Same methods as `Psr\Http\Message\MessageInterface`  + the following methods:
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `getStatusCode()` | Gets the response status code. | |
 | 
			
		||||
| `withStatus($code, $reasonPhrase = '')` | Returns a new response instance with the specified status code and, optionally, reason phrase. | |
 | 
			
		||||
| `getReasonPhrase()` | Gets the response reason phrase associated with the status code. | |
 | 
			
		||||
 | 
			
		||||
##  `Psr\Http\Message\StreamInterface` Methods
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `__toString()` | Reads all data from the stream into a string, from the beginning to end. | |
 | 
			
		||||
| `close()` | Closes the stream and any underlying resources. | |
 | 
			
		||||
| `detach()` | Separates any underlying resources from the stream. | |
 | 
			
		||||
| `getSize()` | Get the size of the stream if known. | |
 | 
			
		||||
| `eof()` | Returns true if the stream is at the end of the stream.| |
 | 
			
		||||
| `isSeekable()` |  Returns whether or not the stream is seekable. | |
 | 
			
		||||
| `seek($offset, $whence = SEEK_SET)` | Seek to a position in the stream. | |
 | 
			
		||||
| `rewind()` | Seek to the beginning of the stream. | |
 | 
			
		||||
| `isWritable()` | Returns whether or not the stream is writable. | |
 | 
			
		||||
| `write($string)` | Write data to the stream. | |
 | 
			
		||||
| `isReadable()` | Returns whether or not the stream is readable. | |
 | 
			
		||||
| `read($length)` | Read data from the stream. | |
 | 
			
		||||
| `getContents()` | Returns the remaining contents in a string | |
 | 
			
		||||
| `getMetadata($key = null)()` | Get stream metadata as an associative array or retrieve a specific key. | |
 | 
			
		||||
 | 
			
		||||
## `Psr\Http\Message\UriInterface` Methods
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `getScheme()` | Retrieve the scheme component of the URI. | |
 | 
			
		||||
| `getAuthority()` | Retrieve the authority component of the URI. | |
 | 
			
		||||
| `getUserInfo()` | Retrieve the user information component of the URI. | |
 | 
			
		||||
| `getHost()` | Retrieve the host component of the URI. | |
 | 
			
		||||
| `getPort()` | Retrieve the port component of the URI. | |
 | 
			
		||||
| `getPath()` | Retrieve the path component of the URI. | |
 | 
			
		||||
| `getQuery()` | Retrieve the query string of the URI. | |
 | 
			
		||||
| `getFragment()` | Retrieve the fragment component of the URI. | |
 | 
			
		||||
| `withScheme($scheme)` | Return an instance with the specified scheme. | |
 | 
			
		||||
| `withUserInfo($user, $password = null)` | Return an instance with the specified user information. | |
 | 
			
		||||
| `withHost($host)` | Return an instance with the specified host. | |
 | 
			
		||||
| `withPort($port)` | Return an instance with the specified port. | |
 | 
			
		||||
| `withPath($path)` | Return an instance with the specified path. | |
 | 
			
		||||
| `withQuery($query)` | Return an instance with the specified query string. | |
 | 
			
		||||
| `withFragment($fragment)` | Return an instance with the specified URI fragment. | |
 | 
			
		||||
| `__toString()` | Return the string representation as a URI reference. | |
 | 
			
		||||
 | 
			
		||||
## `Psr\Http\Message\UploadedFileInterface` Methods
 | 
			
		||||
 | 
			
		||||
| Method Name                        | Description | Notes |
 | 
			
		||||
|------------------------------------| ----------- | ----- |
 | 
			
		||||
| `getStream()` | Retrieve a stream representing the uploaded file. | |
 | 
			
		||||
| `moveTo($targetPath)` | Move the uploaded file to a new location. | |
 | 
			
		||||
| `getSize()` | Retrieve the file size. | |
 | 
			
		||||
| `getError()` | Retrieve the error associated with the uploaded file. | |
 | 
			
		||||
| `getClientFilename()` | Retrieve the filename sent by the client. | |
 | 
			
		||||
| `getClientMediaType()` | Retrieve the media type sent by the client. | |
 | 
			
		||||
 | 
			
		||||
> `RequestInterface`, `ServerRequestInterface`, `ResponseInterface` extend `MessageInterface`  because the `Request` and the `Response` are `HTTP Messages`.
 | 
			
		||||
> When using `ServerRequestInterface`, both `RequestInterface` and `Psr\Http\Message\MessageInterface` methods are considered.
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										159
									
								
								qwen/php/vendor/psr/http-message/docs/PSR7-Usage.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										159
									
								
								qwen/php/vendor/psr/http-message/docs/PSR7-Usage.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,159 @@
 | 
			
		||||
### PSR-7 Usage
 | 
			
		||||
 | 
			
		||||
All PSR-7 applications comply with these interfaces 
 | 
			
		||||
They were created to establish a standard between middleware implementations.
 | 
			
		||||
 | 
			
		||||
> `RequestInterface`, `ServerRequestInterface`, `ResponseInterface` extend `MessageInterface`  because the `Request` and the `Response` are `HTTP Messages`.
 | 
			
		||||
> When using `ServerRequestInterface`, both `RequestInterface` and `Psr\Http\Message\MessageInterface` methods are considered.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
The following examples will illustrate how basic operations are done in PSR-7.
 | 
			
		||||
 | 
			
		||||
##### Examples
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
For this examples to work (at least) a PSR-7 implementation package is required. (eg: zendframework/zend-diactoros, guzzlehttp/psr7, slim/slim, etc)
 | 
			
		||||
All PSR-7 implementations should have the same behaviour.
 | 
			
		||||
 | 
			
		||||
The following will be assumed: 
 | 
			
		||||
`$request` is an object of `Psr\Http\Message\RequestInterface` and
 | 
			
		||||
 | 
			
		||||
`$response` is an object implementing `Psr\Http\Message\RequestInterface`
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### Working with HTTP Headers
 | 
			
		||||
 | 
			
		||||
#### Adding headers to response:
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
$response->withHeader('My-Custom-Header', 'My Custom Message');
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
#### Appending values to headers
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
$response->withAddedHeader('My-Custom-Header', 'The second message');
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
#### Checking if header exists:
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
$request->hasHeader('My-Custom-Header'); // will return false
 | 
			
		||||
$response->hasHeader('My-Custom-Header'); // will return true
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
> Note: My-Custom-Header was only added in the Response
 | 
			
		||||
 | 
			
		||||
#### Getting comma-separated values from a header (also applies to request)
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
// getting value from request headers
 | 
			
		||||
$request->getHeaderLine('Content-Type'); // will return: "text/html; charset=UTF-8"
 | 
			
		||||
// getting value from response headers
 | 
			
		||||
$response->getHeaderLine('My-Custom-Header'); // will return:  "My Custom Message; The second message"
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
#### Getting array of value from a header (also applies to request)
 | 
			
		||||
```php
 | 
			
		||||
// getting value from request headers
 | 
			
		||||
$request->getHeader('Content-Type'); // will return: ["text/html", "charset=UTF-8"]
 | 
			
		||||
// getting value from response headers
 | 
			
		||||
$response->getHeader('My-Custom-Header'); // will return:  ["My Custom Message",  "The second message"]
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
#### Removing headers from HTTP Messages
 | 
			
		||||
```php
 | 
			
		||||
// removing a header from Request, removing deprecated "Content-MD5" header
 | 
			
		||||
$request->withoutHeader('Content-MD5'); 
 | 
			
		||||
 | 
			
		||||
// removing a header from Response
 | 
			
		||||
// effect: the browser won't know the size of the stream
 | 
			
		||||
// the browser will download the stream till it ends
 | 
			
		||||
$response->withoutHeader('Content-Length');
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
### Working with HTTP Message Body
 | 
			
		||||
 | 
			
		||||
When working with the PSR-7 there are two methods of implementation:
 | 
			
		||||
#### 1. Getting the body separately
 | 
			
		||||
 | 
			
		||||
> This method makes the body handling easier to understand and is useful when repeatedly calling body methods. (You only call `getBody()` once). Using this method mistakes like `$response->write()` are also prevented.
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
$body = $response->getBody();
 | 
			
		||||
// operations on body, eg. read, write, seek
 | 
			
		||||
// ...
 | 
			
		||||
// replacing the old body
 | 
			
		||||
$response->withBody($body); 
 | 
			
		||||
// this last statement is optional as we working with objects
 | 
			
		||||
// in this case the "new" body is same with the "old" one
 | 
			
		||||
// the $body variable has the same value as the one in $request, only the reference is passed
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
#### 2. Working directly on response
 | 
			
		||||
 | 
			
		||||
> This method is useful when only performing few operations as the `$request->getBody()` statement fragment is required
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
$response->getBody()->write('hello');
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
### Getting the body contents
 | 
			
		||||
 | 
			
		||||
The following snippet gets the contents of a stream contents.
 | 
			
		||||
> Note: Streams must be rewinded, if content was written into streams, it will be ignored when calling `getContents()` because the stream pointer is set to the last character, which is `\0` - meaning end of stream.
 | 
			
		||||
```php 
 | 
			
		||||
$body = $response->getBody();
 | 
			
		||||
$body->rewind(); // or $body->seek(0);
 | 
			
		||||
$bodyText = $body->getContents();
 | 
			
		||||
```
 | 
			
		||||
> Note: If `$body->seek(1)` is called before `$body->getContents()`, the first character will be ommited as the starting pointer is set to `1`, not `0`. This is why using `$body->rewind()` is recommended.
 | 
			
		||||
 | 
			
		||||
### Append to body
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
$response->getBody()->write('Hello'); // writing directly
 | 
			
		||||
$body = $request->getBody(); // which is a `StreamInterface`
 | 
			
		||||
$body->write('xxxxx');
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
### Prepend to body
 | 
			
		||||
Prepending is different when it comes to streams. The content must be copied before writing the content to be prepended.
 | 
			
		||||
The following example will explain the behaviour of streams.
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
// assuming our response is initially empty
 | 
			
		||||
$body = $repsonse->getBody();
 | 
			
		||||
// writing the string "abcd"
 | 
			
		||||
$body->write('abcd');
 | 
			
		||||
 | 
			
		||||
// seeking to start of stream
 | 
			
		||||
$body->seek(0);
 | 
			
		||||
// writing 'ef'
 | 
			
		||||
$body->write('ef'); // at this point the stream contains "efcd"
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
#### Prepending by rewriting separately
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
// assuming our response body stream only contains: "abcd"
 | 
			
		||||
$body = $response->getBody();
 | 
			
		||||
$body->rewind();
 | 
			
		||||
$contents = $body->getContents(); // abcd
 | 
			
		||||
// seeking the stream to beginning
 | 
			
		||||
$body->rewind();
 | 
			
		||||
$body->write('ef'); // stream contains "efcd"
 | 
			
		||||
$body->write($contents); // stream contains "efabcd"
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
> Note: `getContents()` seeks the stream while reading it, therefore if the second `rewind()` method call was not present the stream would have resulted in `abcdefabcd` because the `write()` method appends to stream if not preceeded by `rewind()` or `seek(0)`.
 | 
			
		||||
 | 
			
		||||
#### Prepending by using contents as a string
 | 
			
		||||
```php
 | 
			
		||||
$body = $response->getBody();
 | 
			
		||||
$body->rewind();
 | 
			
		||||
$contents = $body->getContents(); // efabcd
 | 
			
		||||
$contents = 'ef'.$contents;
 | 
			
		||||
$body->rewind();
 | 
			
		||||
$body->write($contents);
 | 
			
		||||
```
 | 
			
		||||
							
								
								
									
										187
									
								
								qwen/php/vendor/psr/http-message/src/MessageInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										187
									
								
								qwen/php/vendor/psr/http-message/src/MessageInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,187 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * HTTP messages consist of requests from a client to a server and responses
 | 
			
		||||
 * from a server to a client. This interface defines the methods common to
 | 
			
		||||
 * each.
 | 
			
		||||
 *
 | 
			
		||||
 * Messages are considered immutable; all methods that might change state MUST
 | 
			
		||||
 * be implemented such that they retain the internal state of the current
 | 
			
		||||
 * message and return an instance that contains the changed state.
 | 
			
		||||
 *
 | 
			
		||||
 * @link http://www.ietf.org/rfc/rfc7230.txt
 | 
			
		||||
 * @link http://www.ietf.org/rfc/rfc7231.txt
 | 
			
		||||
 */
 | 
			
		||||
interface MessageInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves the HTTP protocol version as a string.
 | 
			
		||||
     *
 | 
			
		||||
     * The string MUST contain only the HTTP version number (e.g., "1.1", "1.0").
 | 
			
		||||
     *
 | 
			
		||||
     * @return string HTTP protocol version.
 | 
			
		||||
     */
 | 
			
		||||
    public function getProtocolVersion(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified HTTP protocol version.
 | 
			
		||||
     *
 | 
			
		||||
     * The version string MUST contain only the HTTP version number (e.g.,
 | 
			
		||||
     * "1.1", "1.0").
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * new protocol version.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $version HTTP protocol version
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withProtocolVersion(string $version): MessageInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves all message header values.
 | 
			
		||||
     *
 | 
			
		||||
     * The keys represent the header name as it will be sent over the wire, and
 | 
			
		||||
     * each value is an array of strings associated with the header.
 | 
			
		||||
     *
 | 
			
		||||
     *     // Represent the headers as a string
 | 
			
		||||
     *     foreach ($message->getHeaders() as $name => $values) {
 | 
			
		||||
     *         echo $name . ": " . implode(", ", $values);
 | 
			
		||||
     *     }
 | 
			
		||||
     *
 | 
			
		||||
     *     // Emit headers iteratively:
 | 
			
		||||
     *     foreach ($message->getHeaders() as $name => $values) {
 | 
			
		||||
     *         foreach ($values as $value) {
 | 
			
		||||
     *             header(sprintf('%s: %s', $name, $value), false);
 | 
			
		||||
     *         }
 | 
			
		||||
     *     }
 | 
			
		||||
     *
 | 
			
		||||
     * While header names are not case-sensitive, getHeaders() will preserve the
 | 
			
		||||
     * exact case in which headers were originally specified.
 | 
			
		||||
     *
 | 
			
		||||
     * @return string[][] Returns an associative array of the message's headers. Each
 | 
			
		||||
     *     key MUST be a header name, and each value MUST be an array of strings
 | 
			
		||||
     *     for that header.
 | 
			
		||||
     */
 | 
			
		||||
    public function getHeaders(): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Checks if a header exists by the given case-insensitive name.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $name Case-insensitive header field name.
 | 
			
		||||
     * @return bool Returns true if any header names match the given header
 | 
			
		||||
     *     name using a case-insensitive string comparison. Returns false if
 | 
			
		||||
     *     no matching header name is found in the message.
 | 
			
		||||
     */
 | 
			
		||||
    public function hasHeader(string $name): bool;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves a message header value by the given case-insensitive name.
 | 
			
		||||
     *
 | 
			
		||||
     * This method returns an array of all the header values of the given
 | 
			
		||||
     * case-insensitive header name.
 | 
			
		||||
     *
 | 
			
		||||
     * If the header does not appear in the message, this method MUST return an
 | 
			
		||||
     * empty array.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $name Case-insensitive header field name.
 | 
			
		||||
     * @return string[] An array of string values as provided for the given
 | 
			
		||||
     *    header. If the header does not appear in the message, this method MUST
 | 
			
		||||
     *    return an empty array.
 | 
			
		||||
     */
 | 
			
		||||
    public function getHeader(string $name): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves a comma-separated string of the values for a single header.
 | 
			
		||||
     *
 | 
			
		||||
     * This method returns all of the header values of the given
 | 
			
		||||
     * case-insensitive header name as a string concatenated together using
 | 
			
		||||
     * a comma.
 | 
			
		||||
     *
 | 
			
		||||
     * NOTE: Not all header values may be appropriately represented using
 | 
			
		||||
     * comma concatenation. For such headers, use getHeader() instead
 | 
			
		||||
     * and supply your own delimiter when concatenating.
 | 
			
		||||
     *
 | 
			
		||||
     * If the header does not appear in the message, this method MUST return
 | 
			
		||||
     * an empty string.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $name Case-insensitive header field name.
 | 
			
		||||
     * @return string A string of values as provided for the given header
 | 
			
		||||
     *    concatenated together using a comma. If the header does not appear in
 | 
			
		||||
     *    the message, this method MUST return an empty string.
 | 
			
		||||
     */
 | 
			
		||||
    public function getHeaderLine(string $name): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the provided value replacing the specified header.
 | 
			
		||||
     *
 | 
			
		||||
     * While header names are case-insensitive, the casing of the header will
 | 
			
		||||
     * be preserved by this function, and returned from getHeaders().
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * new and/or updated header and value.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $name Case-insensitive header field name.
 | 
			
		||||
     * @param string|string[] $value Header value(s).
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid header names or values.
 | 
			
		||||
     */
 | 
			
		||||
    public function withHeader(string $name, $value): MessageInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified header appended with the given value.
 | 
			
		||||
     *
 | 
			
		||||
     * Existing values for the specified header will be maintained. The new
 | 
			
		||||
     * value(s) will be appended to the existing list. If the header did not
 | 
			
		||||
     * exist previously, it will be added.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * new header and/or value.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $name Case-insensitive header field name to add.
 | 
			
		||||
     * @param string|string[] $value Header value(s).
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid header names or values.
 | 
			
		||||
     */
 | 
			
		||||
    public function withAddedHeader(string $name, $value): MessageInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance without the specified header.
 | 
			
		||||
     *
 | 
			
		||||
     * Header resolution MUST be done without case-sensitivity.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that removes
 | 
			
		||||
     * the named header.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $name Case-insensitive header field name to remove.
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withoutHeader(string $name): MessageInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Gets the body of the message.
 | 
			
		||||
     *
 | 
			
		||||
     * @return StreamInterface Returns the body as a stream.
 | 
			
		||||
     */
 | 
			
		||||
    public function getBody(): StreamInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified message body.
 | 
			
		||||
     *
 | 
			
		||||
     * The body MUST be a StreamInterface object.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return a new instance that has the
 | 
			
		||||
     * new body stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @param StreamInterface $body Body.
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException When the body is not valid.
 | 
			
		||||
     */
 | 
			
		||||
    public function withBody(StreamInterface $body): MessageInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										130
									
								
								qwen/php/vendor/psr/http-message/src/RequestInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										130
									
								
								qwen/php/vendor/psr/http-message/src/RequestInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,130 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Representation of an outgoing, client-side request.
 | 
			
		||||
 *
 | 
			
		||||
 * Per the HTTP specification, this interface includes properties for
 | 
			
		||||
 * each of the following:
 | 
			
		||||
 *
 | 
			
		||||
 * - Protocol version
 | 
			
		||||
 * - HTTP method
 | 
			
		||||
 * - URI
 | 
			
		||||
 * - Headers
 | 
			
		||||
 * - Message body
 | 
			
		||||
 *
 | 
			
		||||
 * During construction, implementations MUST attempt to set the Host header from
 | 
			
		||||
 * a provided URI if no Host header is provided.
 | 
			
		||||
 *
 | 
			
		||||
 * Requests are considered immutable; all methods that might change state MUST
 | 
			
		||||
 * be implemented such that they retain the internal state of the current
 | 
			
		||||
 * message and return an instance that contains the changed state.
 | 
			
		||||
 */
 | 
			
		||||
interface RequestInterface extends MessageInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves the message's request target.
 | 
			
		||||
     *
 | 
			
		||||
     * Retrieves the message's request-target either as it will appear (for
 | 
			
		||||
     * clients), as it appeared at request (for servers), or as it was
 | 
			
		||||
     * specified for the instance (see withRequestTarget()).
 | 
			
		||||
     *
 | 
			
		||||
     * In most cases, this will be the origin-form of the composed URI,
 | 
			
		||||
     * unless a value was provided to the concrete implementation (see
 | 
			
		||||
     * withRequestTarget() below).
 | 
			
		||||
     *
 | 
			
		||||
     * If no URI is available, and no request-target has been specifically
 | 
			
		||||
     * provided, this method MUST return the string "/".
 | 
			
		||||
     *
 | 
			
		||||
     * @return string
 | 
			
		||||
     */
 | 
			
		||||
    public function getRequestTarget(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specific request-target.
 | 
			
		||||
     *
 | 
			
		||||
     * If the request needs a non-origin-form request-target — e.g., for
 | 
			
		||||
     * specifying an absolute-form, authority-form, or asterisk-form —
 | 
			
		||||
     * this method may be used to create an instance with the specified
 | 
			
		||||
     * request-target, verbatim.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * changed request target.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://tools.ietf.org/html/rfc7230#section-5.3 (for the various
 | 
			
		||||
     *     request-target forms allowed in request messages)
 | 
			
		||||
     * @param string $requestTarget
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withRequestTarget(string $requestTarget): RequestInterface;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves the HTTP method of the request.
 | 
			
		||||
     *
 | 
			
		||||
     * @return string Returns the request method.
 | 
			
		||||
     */
 | 
			
		||||
    public function getMethod(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the provided HTTP method.
 | 
			
		||||
     *
 | 
			
		||||
     * While HTTP method names are typically all uppercase characters, HTTP
 | 
			
		||||
     * method names are case-sensitive and thus implementations SHOULD NOT
 | 
			
		||||
     * modify the given string.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * changed request method.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $method Case-sensitive method.
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid HTTP methods.
 | 
			
		||||
     */
 | 
			
		||||
    public function withMethod(string $method): RequestInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieves the URI instance.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST return a UriInterface instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://tools.ietf.org/html/rfc3986#section-4.3
 | 
			
		||||
     * @return UriInterface Returns a UriInterface instance
 | 
			
		||||
     *     representing the URI of the request.
 | 
			
		||||
     */
 | 
			
		||||
    public function getUri(): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns an instance with the provided URI.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST update the Host header of the returned request by
 | 
			
		||||
     * default if the URI contains a host component. If the URI does not
 | 
			
		||||
     * contain a host component, any pre-existing Host header MUST be carried
 | 
			
		||||
     * over to the returned request.
 | 
			
		||||
     *
 | 
			
		||||
     * You can opt-in to preserving the original state of the Host header by
 | 
			
		||||
     * setting `$preserveHost` to `true`. When `$preserveHost` is set to
 | 
			
		||||
     * `true`, this method interacts with the Host header in the following ways:
 | 
			
		||||
     *
 | 
			
		||||
     * - If the Host header is missing or empty, and the new URI contains
 | 
			
		||||
     *   a host component, this method MUST update the Host header in the returned
 | 
			
		||||
     *   request.
 | 
			
		||||
     * - If the Host header is missing or empty, and the new URI does not contain a
 | 
			
		||||
     *   host component, this method MUST NOT update the Host header in the returned
 | 
			
		||||
     *   request.
 | 
			
		||||
     * - If a Host header is present and non-empty, this method MUST NOT update
 | 
			
		||||
     *   the Host header in the returned request.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * new UriInterface instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://tools.ietf.org/html/rfc3986#section-4.3
 | 
			
		||||
     * @param UriInterface $uri New request URI to use.
 | 
			
		||||
     * @param bool $preserveHost Preserve the original state of the Host header.
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withUri(UriInterface $uri, bool $preserveHost = false): RequestInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										68
									
								
								qwen/php/vendor/psr/http-message/src/ResponseInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										68
									
								
								qwen/php/vendor/psr/http-message/src/ResponseInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,68 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Representation of an outgoing, server-side response.
 | 
			
		||||
 *
 | 
			
		||||
 * Per the HTTP specification, this interface includes properties for
 | 
			
		||||
 * each of the following:
 | 
			
		||||
 *
 | 
			
		||||
 * - Protocol version
 | 
			
		||||
 * - Status code and reason phrase
 | 
			
		||||
 * - Headers
 | 
			
		||||
 * - Message body
 | 
			
		||||
 *
 | 
			
		||||
 * Responses are considered immutable; all methods that might change state MUST
 | 
			
		||||
 * be implemented such that they retain the internal state of the current
 | 
			
		||||
 * message and return an instance that contains the changed state.
 | 
			
		||||
 */
 | 
			
		||||
interface ResponseInterface extends MessageInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Gets the response status code.
 | 
			
		||||
     *
 | 
			
		||||
     * The status code is a 3-digit integer result code of the server's attempt
 | 
			
		||||
     * to understand and satisfy the request.
 | 
			
		||||
     *
 | 
			
		||||
     * @return int Status code.
 | 
			
		||||
     */
 | 
			
		||||
    public function getStatusCode(): int;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified status code and, optionally, reason phrase.
 | 
			
		||||
     *
 | 
			
		||||
     * If no reason phrase is specified, implementations MAY choose to default
 | 
			
		||||
     * to the RFC 7231 or IANA recommended reason phrase for the response's
 | 
			
		||||
     * status code.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * updated status and reason phrase.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://tools.ietf.org/html/rfc7231#section-6
 | 
			
		||||
     * @link http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
 | 
			
		||||
     * @param int $code The 3-digit integer result code to set.
 | 
			
		||||
     * @param string $reasonPhrase The reason phrase to use with the
 | 
			
		||||
     *     provided status code; if none is provided, implementations MAY
 | 
			
		||||
     *     use the defaults as suggested in the HTTP specification.
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException For invalid status code arguments.
 | 
			
		||||
     */
 | 
			
		||||
    public function withStatus(int $code, string $reasonPhrase = ''): ResponseInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Gets the response reason phrase associated with the status code.
 | 
			
		||||
     *
 | 
			
		||||
     * Because a reason phrase is not a required element in a response
 | 
			
		||||
     * status line, the reason phrase value MAY be null. Implementations MAY
 | 
			
		||||
     * choose to return the default RFC 7231 recommended reason phrase (or those
 | 
			
		||||
     * listed in the IANA HTTP Status Code Registry) for the response's
 | 
			
		||||
     * status code.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://tools.ietf.org/html/rfc7231#section-6
 | 
			
		||||
     * @link http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
 | 
			
		||||
     * @return string Reason phrase; must return an empty string if none present.
 | 
			
		||||
     */
 | 
			
		||||
    public function getReasonPhrase(): string;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										261
									
								
								qwen/php/vendor/psr/http-message/src/ServerRequestInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										261
									
								
								qwen/php/vendor/psr/http-message/src/ServerRequestInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,261 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Representation of an incoming, server-side HTTP request.
 | 
			
		||||
 *
 | 
			
		||||
 * Per the HTTP specification, this interface includes properties for
 | 
			
		||||
 * each of the following:
 | 
			
		||||
 *
 | 
			
		||||
 * - Protocol version
 | 
			
		||||
 * - HTTP method
 | 
			
		||||
 * - URI
 | 
			
		||||
 * - Headers
 | 
			
		||||
 * - Message body
 | 
			
		||||
 *
 | 
			
		||||
 * Additionally, it encapsulates all data as it has arrived to the
 | 
			
		||||
 * application from the CGI and/or PHP environment, including:
 | 
			
		||||
 *
 | 
			
		||||
 * - The values represented in $_SERVER.
 | 
			
		||||
 * - Any cookies provided (generally via $_COOKIE)
 | 
			
		||||
 * - Query string arguments (generally via $_GET, or as parsed via parse_str())
 | 
			
		||||
 * - Upload files, if any (as represented by $_FILES)
 | 
			
		||||
 * - Deserialized body parameters (generally from $_POST)
 | 
			
		||||
 *
 | 
			
		||||
 * $_SERVER values MUST be treated as immutable, as they represent application
 | 
			
		||||
 * state at the time of request; as such, no methods are provided to allow
 | 
			
		||||
 * modification of those values. The other values provide such methods, as they
 | 
			
		||||
 * can be restored from $_SERVER or the request body, and may need treatment
 | 
			
		||||
 * during the application (e.g., body parameters may be deserialized based on
 | 
			
		||||
 * content type).
 | 
			
		||||
 *
 | 
			
		||||
 * Additionally, this interface recognizes the utility of introspecting a
 | 
			
		||||
 * request to derive and match additional parameters (e.g., via URI path
 | 
			
		||||
 * matching, decrypting cookie values, deserializing non-form-encoded body
 | 
			
		||||
 * content, matching authorization headers to users, etc). These parameters
 | 
			
		||||
 * are stored in an "attributes" property.
 | 
			
		||||
 *
 | 
			
		||||
 * Requests are considered immutable; all methods that might change state MUST
 | 
			
		||||
 * be implemented such that they retain the internal state of the current
 | 
			
		||||
 * message and return an instance that contains the changed state.
 | 
			
		||||
 */
 | 
			
		||||
interface ServerRequestInterface extends RequestInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve server parameters.
 | 
			
		||||
     *
 | 
			
		||||
     * Retrieves data related to the incoming request environment,
 | 
			
		||||
     * typically derived from PHP's $_SERVER superglobal. The data IS NOT
 | 
			
		||||
     * REQUIRED to originate from $_SERVER.
 | 
			
		||||
     *
 | 
			
		||||
     * @return array
 | 
			
		||||
     */
 | 
			
		||||
    public function getServerParams(): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve cookies.
 | 
			
		||||
     *
 | 
			
		||||
     * Retrieves cookies sent by the client to the server.
 | 
			
		||||
     *
 | 
			
		||||
     * The data MUST be compatible with the structure of the $_COOKIE
 | 
			
		||||
     * superglobal.
 | 
			
		||||
     *
 | 
			
		||||
     * @return array
 | 
			
		||||
     */
 | 
			
		||||
    public function getCookieParams(): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified cookies.
 | 
			
		||||
     *
 | 
			
		||||
     * The data IS NOT REQUIRED to come from the $_COOKIE superglobal, but MUST
 | 
			
		||||
     * be compatible with the structure of $_COOKIE. Typically, this data will
 | 
			
		||||
     * be injected at instantiation.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST NOT update the related Cookie header of the request
 | 
			
		||||
     * instance, nor related values in the server params.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * updated cookie values.
 | 
			
		||||
     *
 | 
			
		||||
     * @param array $cookies Array of key/value pairs representing cookies.
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withCookieParams(array $cookies): ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve query string arguments.
 | 
			
		||||
     *
 | 
			
		||||
     * Retrieves the deserialized query string arguments, if any.
 | 
			
		||||
     *
 | 
			
		||||
     * Note: the query params might not be in sync with the URI or server
 | 
			
		||||
     * params. If you need to ensure you are only getting the original
 | 
			
		||||
     * values, you may need to parse the query string from `getUri()->getQuery()`
 | 
			
		||||
     * or from the `QUERY_STRING` server param.
 | 
			
		||||
     *
 | 
			
		||||
     * @return array
 | 
			
		||||
     */
 | 
			
		||||
    public function getQueryParams(): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified query string arguments.
 | 
			
		||||
     *
 | 
			
		||||
     * These values SHOULD remain immutable over the course of the incoming
 | 
			
		||||
     * request. They MAY be injected during instantiation, such as from PHP's
 | 
			
		||||
     * $_GET superglobal, or MAY be derived from some other value such as the
 | 
			
		||||
     * URI. In cases where the arguments are parsed from the URI, the data
 | 
			
		||||
     * MUST be compatible with what PHP's parse_str() would return for
 | 
			
		||||
     * purposes of how duplicate query parameters are handled, and how nested
 | 
			
		||||
     * sets are handled.
 | 
			
		||||
     *
 | 
			
		||||
     * Setting query string arguments MUST NOT change the URI stored by the
 | 
			
		||||
     * request, nor the values in the server params.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * updated query string arguments.
 | 
			
		||||
     *
 | 
			
		||||
     * @param array $query Array of query string arguments, typically from
 | 
			
		||||
     *     $_GET.
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withQueryParams(array $query): ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve normalized file upload data.
 | 
			
		||||
     *
 | 
			
		||||
     * This method returns upload metadata in a normalized tree, with each leaf
 | 
			
		||||
     * an instance of Psr\Http\Message\UploadedFileInterface.
 | 
			
		||||
     *
 | 
			
		||||
     * These values MAY be prepared from $_FILES or the message body during
 | 
			
		||||
     * instantiation, or MAY be injected via withUploadedFiles().
 | 
			
		||||
     *
 | 
			
		||||
     * @return array An array tree of UploadedFileInterface instances; an empty
 | 
			
		||||
     *     array MUST be returned if no data is present.
 | 
			
		||||
     */
 | 
			
		||||
    public function getUploadedFiles(): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Create a new instance with the specified uploaded files.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * updated body parameters.
 | 
			
		||||
     *
 | 
			
		||||
     * @param array $uploadedFiles An array tree of UploadedFileInterface instances.
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException if an invalid structure is provided.
 | 
			
		||||
     */
 | 
			
		||||
    public function withUploadedFiles(array $uploadedFiles): ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve any parameters provided in the request body.
 | 
			
		||||
     *
 | 
			
		||||
     * If the request Content-Type is either application/x-www-form-urlencoded
 | 
			
		||||
     * or multipart/form-data, and the request method is POST, this method MUST
 | 
			
		||||
     * return the contents of $_POST.
 | 
			
		||||
     *
 | 
			
		||||
     * Otherwise, this method may return any results of deserializing
 | 
			
		||||
     * the request body content; as parsing returns structured content, the
 | 
			
		||||
     * potential types MUST be arrays or objects only. A null value indicates
 | 
			
		||||
     * the absence of body content.
 | 
			
		||||
     *
 | 
			
		||||
     * @return null|array|object The deserialized body parameters, if any.
 | 
			
		||||
     *     These will typically be an array or object.
 | 
			
		||||
     */
 | 
			
		||||
    public function getParsedBody();
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified body parameters.
 | 
			
		||||
     *
 | 
			
		||||
     * These MAY be injected during instantiation.
 | 
			
		||||
     *
 | 
			
		||||
     * If the request Content-Type is either application/x-www-form-urlencoded
 | 
			
		||||
     * or multipart/form-data, and the request method is POST, use this method
 | 
			
		||||
     * ONLY to inject the contents of $_POST.
 | 
			
		||||
     *
 | 
			
		||||
     * The data IS NOT REQUIRED to come from $_POST, but MUST be the results of
 | 
			
		||||
     * deserializing the request body content. Deserialization/parsing returns
 | 
			
		||||
     * structured data, and, as such, this method ONLY accepts arrays or objects,
 | 
			
		||||
     * or a null value if nothing was available to parse.
 | 
			
		||||
     *
 | 
			
		||||
     * As an example, if content negotiation determines that the request data
 | 
			
		||||
     * is a JSON payload, this method could be used to create a request
 | 
			
		||||
     * instance with the deserialized parameters.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * updated body parameters.
 | 
			
		||||
     *
 | 
			
		||||
     * @param null|array|object $data The deserialized body data. This will
 | 
			
		||||
     *     typically be in an array or object.
 | 
			
		||||
     * @return static
 | 
			
		||||
     * @throws \InvalidArgumentException if an unsupported argument type is
 | 
			
		||||
     *     provided.
 | 
			
		||||
     */
 | 
			
		||||
    public function withParsedBody($data): ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve attributes derived from the request.
 | 
			
		||||
     *
 | 
			
		||||
     * The request "attributes" may be used to allow injection of any
 | 
			
		||||
     * parameters derived from the request: e.g., the results of path
 | 
			
		||||
     * match operations; the results of decrypting cookies; the results of
 | 
			
		||||
     * deserializing non-form-encoded message bodies; etc. Attributes
 | 
			
		||||
     * will be application and request specific, and CAN be mutable.
 | 
			
		||||
     *
 | 
			
		||||
     * @return array Attributes derived from the request.
 | 
			
		||||
     */
 | 
			
		||||
    public function getAttributes(): array;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve a single derived request attribute.
 | 
			
		||||
     *
 | 
			
		||||
     * Retrieves a single derived request attribute as described in
 | 
			
		||||
     * getAttributes(). If the attribute has not been previously set, returns
 | 
			
		||||
     * the default value as provided.
 | 
			
		||||
     *
 | 
			
		||||
     * This method obviates the need for a hasAttribute() method, as it allows
 | 
			
		||||
     * specifying a default value to return if the attribute is not found.
 | 
			
		||||
     *
 | 
			
		||||
     * @see getAttributes()
 | 
			
		||||
     * @param string $name The attribute name.
 | 
			
		||||
     * @param mixed $default Default value to return if the attribute does not exist.
 | 
			
		||||
     * @return mixed
 | 
			
		||||
     */
 | 
			
		||||
    public function getAttribute(string $name, $default = null);
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified derived request attribute.
 | 
			
		||||
     *
 | 
			
		||||
     * This method allows setting a single derived request attribute as
 | 
			
		||||
     * described in getAttributes().
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that has the
 | 
			
		||||
     * updated attribute.
 | 
			
		||||
     *
 | 
			
		||||
     * @see getAttributes()
 | 
			
		||||
     * @param string $name The attribute name.
 | 
			
		||||
     * @param mixed $value The value of the attribute.
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withAttribute(string $name, $value): ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance that removes the specified derived request attribute.
 | 
			
		||||
     *
 | 
			
		||||
     * This method allows removing a single derived request attribute as
 | 
			
		||||
     * described in getAttributes().
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST be implemented in such a way as to retain the
 | 
			
		||||
     * immutability of the message, and MUST return an instance that removes
 | 
			
		||||
     * the attribute.
 | 
			
		||||
     *
 | 
			
		||||
     * @see getAttributes()
 | 
			
		||||
     * @param string $name The attribute name.
 | 
			
		||||
     * @return static
 | 
			
		||||
     */
 | 
			
		||||
    public function withoutAttribute(string $name): ServerRequestInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										158
									
								
								qwen/php/vendor/psr/http-message/src/StreamInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										158
									
								
								qwen/php/vendor/psr/http-message/src/StreamInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,158 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Describes a data stream.
 | 
			
		||||
 *
 | 
			
		||||
 * 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 StreamInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Reads all data from the stream into a string, from the beginning to end.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST attempt to seek to the beginning of the stream before
 | 
			
		||||
     * reading data and read the stream until the end is reached.
 | 
			
		||||
     *
 | 
			
		||||
     * Warning: This could attempt to load a large amount of data into memory.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST NOT raise an exception in order to conform with PHP's
 | 
			
		||||
     * string casting operations.
 | 
			
		||||
     *
 | 
			
		||||
     * @see http://php.net/manual/en/language.oop5.magic.php#object.tostring
 | 
			
		||||
     * @return string
 | 
			
		||||
     */
 | 
			
		||||
    public function __toString(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Closes the stream and any underlying resources.
 | 
			
		||||
     *
 | 
			
		||||
     * @return void
 | 
			
		||||
     */
 | 
			
		||||
    public function close(): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Separates any underlying resources from the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * After the stream has been detached, the stream is in an unusable state.
 | 
			
		||||
     *
 | 
			
		||||
     * @return resource|null Underlying PHP stream, if any
 | 
			
		||||
     */
 | 
			
		||||
    public function detach();
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Get the size of the stream if known.
 | 
			
		||||
     *
 | 
			
		||||
     * @return int|null Returns the size in bytes if known, or null if unknown.
 | 
			
		||||
     */
 | 
			
		||||
    public function getSize(): ?int;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns the current position of the file read/write pointer
 | 
			
		||||
     *
 | 
			
		||||
     * @return int Position of the file pointer
 | 
			
		||||
     * @throws \RuntimeException on error.
 | 
			
		||||
     */
 | 
			
		||||
    public function tell(): int;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns true if the stream is at the end of the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @return bool
 | 
			
		||||
     */
 | 
			
		||||
    public function eof(): bool;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns whether or not the stream is seekable.
 | 
			
		||||
     *
 | 
			
		||||
     * @return bool
 | 
			
		||||
     */
 | 
			
		||||
    public function isSeekable(): bool;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Seek to a position in the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://www.php.net/manual/en/function.fseek.php
 | 
			
		||||
     * @param int $offset Stream offset
 | 
			
		||||
     * @param int $whence Specifies how the cursor position will be calculated
 | 
			
		||||
     *     based on the seek offset. Valid values are identical to the built-in
 | 
			
		||||
     *     PHP $whence values for `fseek()`.  SEEK_SET: Set position equal to
 | 
			
		||||
     *     offset bytes SEEK_CUR: Set position to current location plus offset
 | 
			
		||||
     *     SEEK_END: Set position to end-of-stream plus offset.
 | 
			
		||||
     * @throws \RuntimeException on failure.
 | 
			
		||||
     */
 | 
			
		||||
    public function seek(int $offset, int $whence = SEEK_SET): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Seek to the beginning of the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * If the stream is not seekable, this method will raise an exception;
 | 
			
		||||
     * otherwise, it will perform a seek(0).
 | 
			
		||||
     *
 | 
			
		||||
     * @see seek()
 | 
			
		||||
     * @link http://www.php.net/manual/en/function.fseek.php
 | 
			
		||||
     * @throws \RuntimeException on failure.
 | 
			
		||||
     */
 | 
			
		||||
    public function rewind(): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns whether or not the stream is writable.
 | 
			
		||||
     *
 | 
			
		||||
     * @return bool
 | 
			
		||||
     */
 | 
			
		||||
    public function isWritable(): bool;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Write data to the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $string The string that is to be written.
 | 
			
		||||
     * @return int Returns the number of bytes written to the stream.
 | 
			
		||||
     * @throws \RuntimeException on failure.
 | 
			
		||||
     */
 | 
			
		||||
    public function write(string $string): int;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns whether or not the stream is readable.
 | 
			
		||||
     *
 | 
			
		||||
     * @return bool
 | 
			
		||||
     */
 | 
			
		||||
    public function isReadable(): bool;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Read data from the stream.
 | 
			
		||||
     *
 | 
			
		||||
     * @param int $length Read up to $length bytes from the object and return
 | 
			
		||||
     *     them. Fewer than $length bytes may be returned if underlying stream
 | 
			
		||||
     *     call returns fewer bytes.
 | 
			
		||||
     * @return string Returns the data read from the stream, or an empty string
 | 
			
		||||
     *     if no bytes are available.
 | 
			
		||||
     * @throws \RuntimeException if an error occurs.
 | 
			
		||||
     */
 | 
			
		||||
    public function read(int $length): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Returns the remaining contents in a string
 | 
			
		||||
     *
 | 
			
		||||
     * @return string
 | 
			
		||||
     * @throws \RuntimeException if unable to read or an error occurs while
 | 
			
		||||
     *     reading.
 | 
			
		||||
     */
 | 
			
		||||
    public function getContents(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Get stream metadata as an associative array or retrieve a specific key.
 | 
			
		||||
     *
 | 
			
		||||
     * The keys returned are identical to the keys returned from PHP's
 | 
			
		||||
     * stream_get_meta_data() function.
 | 
			
		||||
     *
 | 
			
		||||
     * @link http://php.net/manual/en/function.stream-get-meta-data.php
 | 
			
		||||
     * @param string|null $key Specific metadata to retrieve.
 | 
			
		||||
     * @return array|mixed|null Returns an associative array if no key is
 | 
			
		||||
     *     provided. Returns a specific key value if a key is provided and the
 | 
			
		||||
     *     value is found, or null if the key is not found.
 | 
			
		||||
     */
 | 
			
		||||
    public function getMetadata(?string $key = null);
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										123
									
								
								qwen/php/vendor/psr/http-message/src/UploadedFileInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										123
									
								
								qwen/php/vendor/psr/http-message/src/UploadedFileInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,123 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Value object representing a file uploaded through an HTTP request.
 | 
			
		||||
 *
 | 
			
		||||
 * Instances of this interface are considered immutable; all methods that
 | 
			
		||||
 * might change state MUST be implemented such that they retain the internal
 | 
			
		||||
 * state of the current instance and return an instance that contains the
 | 
			
		||||
 * changed state.
 | 
			
		||||
 */
 | 
			
		||||
interface UploadedFileInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve a stream representing the uploaded file.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST return a StreamInterface instance, representing the
 | 
			
		||||
     * uploaded file. The purpose of this method is to allow utilizing native PHP
 | 
			
		||||
     * stream functionality to manipulate the file upload, such as
 | 
			
		||||
     * stream_copy_to_stream() (though the result will need to be decorated in a
 | 
			
		||||
     * native PHP stream wrapper to work with such functions).
 | 
			
		||||
     *
 | 
			
		||||
     * If the moveTo() method has been called previously, this method MUST raise
 | 
			
		||||
     * an exception.
 | 
			
		||||
     *
 | 
			
		||||
     * @return StreamInterface Stream representation of the uploaded file.
 | 
			
		||||
     * @throws \RuntimeException in cases when no stream is available or can be
 | 
			
		||||
     *     created.
 | 
			
		||||
     */
 | 
			
		||||
    public function getStream(): StreamInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Move the uploaded file to a new location.
 | 
			
		||||
     *
 | 
			
		||||
     * Use this method as an alternative to move_uploaded_file(). This method is
 | 
			
		||||
     * guaranteed to work in both SAPI and non-SAPI environments.
 | 
			
		||||
     * Implementations must determine which environment they are in, and use the
 | 
			
		||||
     * appropriate method (move_uploaded_file(), rename(), or a stream
 | 
			
		||||
     * operation) to perform the operation.
 | 
			
		||||
     *
 | 
			
		||||
     * $targetPath may be an absolute path, or a relative path. If it is a
 | 
			
		||||
     * relative path, resolution should be the same as used by PHP's rename()
 | 
			
		||||
     * function.
 | 
			
		||||
     *
 | 
			
		||||
     * The original file or stream MUST be removed on completion.
 | 
			
		||||
     *
 | 
			
		||||
     * If this method is called more than once, any subsequent calls MUST raise
 | 
			
		||||
     * an exception.
 | 
			
		||||
     *
 | 
			
		||||
     * When used in an SAPI environment where $_FILES is populated, when writing
 | 
			
		||||
     * files via moveTo(), is_uploaded_file() and move_uploaded_file() SHOULD be
 | 
			
		||||
     * used to ensure permissions and upload status are verified correctly.
 | 
			
		||||
     *
 | 
			
		||||
     * If you wish to move to a stream, use getStream(), as SAPI operations
 | 
			
		||||
     * cannot guarantee writing to stream destinations.
 | 
			
		||||
     *
 | 
			
		||||
     * @see http://php.net/is_uploaded_file
 | 
			
		||||
     * @see http://php.net/move_uploaded_file
 | 
			
		||||
     * @param string $targetPath Path to which to move the uploaded file.
 | 
			
		||||
     * @throws \InvalidArgumentException if the $targetPath specified is invalid.
 | 
			
		||||
     * @throws \RuntimeException on any error during the move operation, or on
 | 
			
		||||
     *     the second or subsequent call to the method.
 | 
			
		||||
     */
 | 
			
		||||
    public function moveTo(string $targetPath): void;
 | 
			
		||||
    
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the file size.
 | 
			
		||||
     *
 | 
			
		||||
     * Implementations SHOULD return the value stored in the "size" key of
 | 
			
		||||
     * the file in the $_FILES array if available, as PHP calculates this based
 | 
			
		||||
     * on the actual size transmitted.
 | 
			
		||||
     *
 | 
			
		||||
     * @return int|null The file size in bytes or null if unknown.
 | 
			
		||||
     */
 | 
			
		||||
    public function getSize(): ?int;
 | 
			
		||||
    
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the error associated with the uploaded file.
 | 
			
		||||
     *
 | 
			
		||||
     * The return value MUST be one of PHP's UPLOAD_ERR_XXX constants.
 | 
			
		||||
     *
 | 
			
		||||
     * If the file was uploaded successfully, this method MUST return
 | 
			
		||||
     * UPLOAD_ERR_OK.
 | 
			
		||||
     *
 | 
			
		||||
     * Implementations SHOULD return the value stored in the "error" key of
 | 
			
		||||
     * the file in the $_FILES array.
 | 
			
		||||
     *
 | 
			
		||||
     * @see http://php.net/manual/en/features.file-upload.errors.php
 | 
			
		||||
     * @return int One of PHP's UPLOAD_ERR_XXX constants.
 | 
			
		||||
     */
 | 
			
		||||
    public function getError(): int;
 | 
			
		||||
    
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the filename sent by the client.
 | 
			
		||||
     *
 | 
			
		||||
     * Do not trust the value returned by this method. A client could send
 | 
			
		||||
     * a malicious filename with the intention to corrupt or hack your
 | 
			
		||||
     * application.
 | 
			
		||||
     *
 | 
			
		||||
     * Implementations SHOULD return the value stored in the "name" key of
 | 
			
		||||
     * the file in the $_FILES array.
 | 
			
		||||
     *
 | 
			
		||||
     * @return string|null The filename sent by the client or null if none
 | 
			
		||||
     *     was provided.
 | 
			
		||||
     */
 | 
			
		||||
    public function getClientFilename(): ?string;
 | 
			
		||||
    
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the media type sent by the client.
 | 
			
		||||
     *
 | 
			
		||||
     * Do not trust the value returned by this method. A client could send
 | 
			
		||||
     * a malicious media type with the intention to corrupt or hack your
 | 
			
		||||
     * application.
 | 
			
		||||
     *
 | 
			
		||||
     * Implementations SHOULD return the value stored in the "type" key of
 | 
			
		||||
     * the file in the $_FILES array.
 | 
			
		||||
     *
 | 
			
		||||
     * @return string|null The media type sent by the client or null if none
 | 
			
		||||
     *     was provided.
 | 
			
		||||
     */
 | 
			
		||||
    public function getClientMediaType(): ?string;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										324
									
								
								qwen/php/vendor/psr/http-message/src/UriInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										324
									
								
								qwen/php/vendor/psr/http-message/src/UriInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,324 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Message;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Value object representing a URI.
 | 
			
		||||
 *
 | 
			
		||||
 * This interface is meant to represent URIs according to RFC 3986 and to
 | 
			
		||||
 * provide methods for most common operations. Additional functionality for
 | 
			
		||||
 * working with URIs can be provided on top of the interface or externally.
 | 
			
		||||
 * Its primary use is for HTTP requests, but may also be used in other
 | 
			
		||||
 * contexts.
 | 
			
		||||
 *
 | 
			
		||||
 * Instances of this interface are considered immutable; all methods that
 | 
			
		||||
 * might change state MUST be implemented such that they retain the internal
 | 
			
		||||
 * state of the current instance and return an instance that contains the
 | 
			
		||||
 * changed state.
 | 
			
		||||
 *
 | 
			
		||||
 * Typically the Host header will be also be present in the request message.
 | 
			
		||||
 * For server-side requests, the scheme will typically be discoverable in the
 | 
			
		||||
 * server parameters.
 | 
			
		||||
 *
 | 
			
		||||
 * @link http://tools.ietf.org/html/rfc3986 (the URI specification)
 | 
			
		||||
 */
 | 
			
		||||
interface UriInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the scheme component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If no scheme is present, this method MUST return an empty string.
 | 
			
		||||
     *
 | 
			
		||||
     * The value returned MUST be normalized to lowercase, per RFC 3986
 | 
			
		||||
     * Section 3.1.
 | 
			
		||||
     *
 | 
			
		||||
     * The trailing ":" character is not part of the scheme and MUST NOT be
 | 
			
		||||
     * added.
 | 
			
		||||
     *
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-3.1
 | 
			
		||||
     * @return string The URI scheme.
 | 
			
		||||
     */
 | 
			
		||||
    public function getScheme(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the authority component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If no authority information is present, this method MUST return an empty
 | 
			
		||||
     * string.
 | 
			
		||||
     *
 | 
			
		||||
     * The authority syntax of the URI is:
 | 
			
		||||
     *
 | 
			
		||||
     * <pre>
 | 
			
		||||
     * [user-info@]host[:port]
 | 
			
		||||
     * </pre>
 | 
			
		||||
     *
 | 
			
		||||
     * If the port component is not set or is the standard port for the current
 | 
			
		||||
     * scheme, it SHOULD NOT be included.
 | 
			
		||||
     *
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-3.2
 | 
			
		||||
     * @return string The URI authority, in "[user-info@]host[:port]" format.
 | 
			
		||||
     */
 | 
			
		||||
    public function getAuthority(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the user information component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If no user information is present, this method MUST return an empty
 | 
			
		||||
     * string.
 | 
			
		||||
     *
 | 
			
		||||
     * If a user is present in the URI, this will return that value;
 | 
			
		||||
     * additionally, if the password is also present, it will be appended to the
 | 
			
		||||
     * user value, with a colon (":") separating the values.
 | 
			
		||||
     *
 | 
			
		||||
     * The trailing "@" character is not part of the user information and MUST
 | 
			
		||||
     * NOT be added.
 | 
			
		||||
     *
 | 
			
		||||
     * @return string The URI user information, in "username[:password]" format.
 | 
			
		||||
     */
 | 
			
		||||
    public function getUserInfo(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the host component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If no host is present, this method MUST return an empty string.
 | 
			
		||||
     *
 | 
			
		||||
     * The value returned MUST be normalized to lowercase, per RFC 3986
 | 
			
		||||
     * Section 3.2.2.
 | 
			
		||||
     *
 | 
			
		||||
     * @see http://tools.ietf.org/html/rfc3986#section-3.2.2
 | 
			
		||||
     * @return string The URI host.
 | 
			
		||||
     */
 | 
			
		||||
    public function getHost(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the port component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If a port is present, and it is non-standard for the current scheme,
 | 
			
		||||
     * this method MUST return it as an integer. If the port is the standard port
 | 
			
		||||
     * used with the current scheme, this method SHOULD return null.
 | 
			
		||||
     *
 | 
			
		||||
     * If no port is present, and no scheme is present, this method MUST return
 | 
			
		||||
     * a null value.
 | 
			
		||||
     *
 | 
			
		||||
     * If no port is present, but a scheme is present, this method MAY return
 | 
			
		||||
     * the standard port for that scheme, but SHOULD return null.
 | 
			
		||||
     *
 | 
			
		||||
     * @return null|int The URI port.
 | 
			
		||||
     */
 | 
			
		||||
    public function getPort(): ?int;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the path component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * The path can either be empty or absolute (starting with a slash) or
 | 
			
		||||
     * rootless (not starting with a slash). Implementations MUST support all
 | 
			
		||||
     * three syntaxes.
 | 
			
		||||
     *
 | 
			
		||||
     * Normally, the empty path "" and absolute path "/" are considered equal as
 | 
			
		||||
     * defined in RFC 7230 Section 2.7.3. But this method MUST NOT automatically
 | 
			
		||||
     * do this normalization because in contexts with a trimmed base path, e.g.
 | 
			
		||||
     * the front controller, this difference becomes significant. It's the task
 | 
			
		||||
     * of the user to handle both "" and "/".
 | 
			
		||||
     *
 | 
			
		||||
     * The value returned MUST be percent-encoded, but MUST NOT double-encode
 | 
			
		||||
     * any characters. To determine what characters to encode, please refer to
 | 
			
		||||
     * RFC 3986, Sections 2 and 3.3.
 | 
			
		||||
     *
 | 
			
		||||
     * As an example, if the value should include a slash ("/") not intended as
 | 
			
		||||
     * delimiter between path segments, that value MUST be passed in encoded
 | 
			
		||||
     * form (e.g., "%2F") to the instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-2
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-3.3
 | 
			
		||||
     * @return string The URI path.
 | 
			
		||||
     */
 | 
			
		||||
    public function getPath(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the query string of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If no query string is present, this method MUST return an empty string.
 | 
			
		||||
     *
 | 
			
		||||
     * The leading "?" character is not part of the query and MUST NOT be
 | 
			
		||||
     * added.
 | 
			
		||||
     *
 | 
			
		||||
     * The value returned MUST be percent-encoded, but MUST NOT double-encode
 | 
			
		||||
     * any characters. To determine what characters to encode, please refer to
 | 
			
		||||
     * RFC 3986, Sections 2 and 3.4.
 | 
			
		||||
     *
 | 
			
		||||
     * As an example, if a value in a key/value pair of the query string should
 | 
			
		||||
     * include an ampersand ("&") not intended as a delimiter between values,
 | 
			
		||||
     * that value MUST be passed in encoded form (e.g., "%26") to the instance.
 | 
			
		||||
     *
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-2
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-3.4
 | 
			
		||||
     * @return string The URI query string.
 | 
			
		||||
     */
 | 
			
		||||
    public function getQuery(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Retrieve the fragment component of the URI.
 | 
			
		||||
     *
 | 
			
		||||
     * If no fragment is present, this method MUST return an empty string.
 | 
			
		||||
     *
 | 
			
		||||
     * The leading "#" character is not part of the fragment and MUST NOT be
 | 
			
		||||
     * added.
 | 
			
		||||
     *
 | 
			
		||||
     * The value returned MUST be percent-encoded, but MUST NOT double-encode
 | 
			
		||||
     * any characters. To determine what characters to encode, please refer to
 | 
			
		||||
     * RFC 3986, Sections 2 and 3.5.
 | 
			
		||||
     *
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-2
 | 
			
		||||
     * @see https://tools.ietf.org/html/rfc3986#section-3.5
 | 
			
		||||
     * @return string The URI fragment.
 | 
			
		||||
     */
 | 
			
		||||
    public function getFragment(): string;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified scheme.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified scheme.
 | 
			
		||||
     *
 | 
			
		||||
     * Implementations MUST support the schemes "http" and "https" case
 | 
			
		||||
     * insensitively, and MAY accommodate other schemes if required.
 | 
			
		||||
     *
 | 
			
		||||
     * An empty scheme is equivalent to removing the scheme.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $scheme The scheme to use with the new instance.
 | 
			
		||||
     * @return static A new instance with the specified scheme.
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid or unsupported schemes.
 | 
			
		||||
     */
 | 
			
		||||
    public function withScheme(string $scheme): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified user information.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified user information.
 | 
			
		||||
     *
 | 
			
		||||
     * Password is optional, but the user information MUST include the
 | 
			
		||||
     * user; an empty string for the user is equivalent to removing user
 | 
			
		||||
     * information.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $user The user name to use for authority.
 | 
			
		||||
     * @param null|string $password The password associated with $user.
 | 
			
		||||
     * @return static A new instance with the specified user information.
 | 
			
		||||
     */
 | 
			
		||||
    public function withUserInfo(string $user, ?string $password = null): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified host.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified host.
 | 
			
		||||
     *
 | 
			
		||||
     * An empty host value is equivalent to removing the host.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $host The hostname to use with the new instance.
 | 
			
		||||
     * @return static A new instance with the specified host.
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid hostnames.
 | 
			
		||||
     */
 | 
			
		||||
    public function withHost(string $host): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified port.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified port.
 | 
			
		||||
     *
 | 
			
		||||
     * Implementations MUST raise an exception for ports outside the
 | 
			
		||||
     * established TCP and UDP port ranges.
 | 
			
		||||
     *
 | 
			
		||||
     * A null value provided for the port is equivalent to removing the port
 | 
			
		||||
     * information.
 | 
			
		||||
     *
 | 
			
		||||
     * @param null|int $port The port to use with the new instance; a null value
 | 
			
		||||
     *     removes the port information.
 | 
			
		||||
     * @return static A new instance with the specified port.
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid ports.
 | 
			
		||||
     */
 | 
			
		||||
    public function withPort(?int $port): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified path.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified path.
 | 
			
		||||
     *
 | 
			
		||||
     * The path can either be empty or absolute (starting with a slash) or
 | 
			
		||||
     * rootless (not starting with a slash). Implementations MUST support all
 | 
			
		||||
     * three syntaxes.
 | 
			
		||||
     *
 | 
			
		||||
     * If the path is intended to be domain-relative rather than path relative then
 | 
			
		||||
     * it must begin with a slash ("/"). Paths not starting with a slash ("/")
 | 
			
		||||
     * are assumed to be relative to some base path known to the application or
 | 
			
		||||
     * consumer.
 | 
			
		||||
     *
 | 
			
		||||
     * Users can provide both encoded and decoded path characters.
 | 
			
		||||
     * Implementations ensure the correct encoding as outlined in getPath().
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $path The path to use with the new instance.
 | 
			
		||||
     * @return static A new instance with the specified path.
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid paths.
 | 
			
		||||
     */
 | 
			
		||||
    public function withPath(string $path): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified query string.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified query string.
 | 
			
		||||
     *
 | 
			
		||||
     * Users can provide both encoded and decoded query characters.
 | 
			
		||||
     * Implementations ensure the correct encoding as outlined in getQuery().
 | 
			
		||||
     *
 | 
			
		||||
     * An empty query string value is equivalent to removing the query string.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $query The query string to use with the new instance.
 | 
			
		||||
     * @return static A new instance with the specified query string.
 | 
			
		||||
     * @throws \InvalidArgumentException for invalid query strings.
 | 
			
		||||
     */
 | 
			
		||||
    public function withQuery(string $query): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return an instance with the specified URI fragment.
 | 
			
		||||
     *
 | 
			
		||||
     * This method MUST retain the state of the current instance, and return
 | 
			
		||||
     * an instance that contains the specified URI fragment.
 | 
			
		||||
     *
 | 
			
		||||
     * Users can provide both encoded and decoded fragment characters.
 | 
			
		||||
     * Implementations ensure the correct encoding as outlined in getFragment().
 | 
			
		||||
     *
 | 
			
		||||
     * An empty fragment value is equivalent to removing the fragment.
 | 
			
		||||
     *
 | 
			
		||||
     * @param string $fragment The fragment to use with the new instance.
 | 
			
		||||
     * @return static A new instance with the specified fragment.
 | 
			
		||||
     */
 | 
			
		||||
    public function withFragment(string $fragment): UriInterface;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Return the string representation as a URI reference.
 | 
			
		||||
     *
 | 
			
		||||
     * Depending on which components of the URI are present, the resulting
 | 
			
		||||
     * string is either a full URI or relative reference according to RFC 3986,
 | 
			
		||||
     * Section 4.1. The method concatenates the various components of the URI,
 | 
			
		||||
     * using the appropriate delimiters:
 | 
			
		||||
     *
 | 
			
		||||
     * - If a scheme is present, it MUST be suffixed by ":".
 | 
			
		||||
     * - If an authority is present, it MUST be prefixed by "//".
 | 
			
		||||
     * - The path can be concatenated without delimiters. But there are two
 | 
			
		||||
     *   cases where the path has to be adjusted to make the URI reference
 | 
			
		||||
     *   valid as PHP does not allow to throw an exception in __toString():
 | 
			
		||||
     *     - If the path is rootless and an authority is present, the path MUST
 | 
			
		||||
     *       be prefixed by "/".
 | 
			
		||||
     *     - If the path is starting with more than one "/" and no authority is
 | 
			
		||||
     *       present, the starting slashes MUST be reduced to one.
 | 
			
		||||
     * - If a query is present, it MUST be prefixed by "?".
 | 
			
		||||
     * - If a fragment is present, it MUST be prefixed by "#".
 | 
			
		||||
     *
 | 
			
		||||
     * @see http://tools.ietf.org/html/rfc3986#section-4.1
 | 
			
		||||
     * @return string
 | 
			
		||||
     */
 | 
			
		||||
    public function __toString(): string;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										21
									
								
								qwen/php/vendor/psr/http-server-handler/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								qwen/php/vendor/psr/http-server-handler/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,21 @@
 | 
			
		||||
The MIT License (MIT)
 | 
			
		||||
 | 
			
		||||
Copyright (c) 2016 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.
 | 
			
		||||
							
								
								
									
										12
									
								
								qwen/php/vendor/psr/http-server-handler/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								qwen/php/vendor/psr/http-server-handler/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
			
		||||
HTTP Server Request Handlers for Middleware
 | 
			
		||||
===========================================
 | 
			
		||||
 | 
			
		||||
This repository holds the `RequestHandlerInterface` related to [PSR-15 (HTTP Server Request Handlers)][psr-url].
 | 
			
		||||
 | 
			
		||||
Note that this is not a Server Request Handler implementation of its own. It is merely the interface that describe a Server Request Handler.
 | 
			
		||||
 | 
			
		||||
The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist.
 | 
			
		||||
 | 
			
		||||
[psr-url]: https://www.php-fig.org/psr/psr-15/
 | 
			
		||||
[package-url]: https://packagist.org/packages/psr/http-server-handler
 | 
			
		||||
[implementation-url]: https://packagist.org/providers/psr/http-server-handler-implementation
 | 
			
		||||
							
								
								
									
										36
									
								
								qwen/php/vendor/psr/http-server-handler/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										36
									
								
								qwen/php/vendor/psr/http-server-handler/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,36 @@
 | 
			
		||||
{
 | 
			
		||||
    "name": "psr/http-server-handler",
 | 
			
		||||
    "description": "Common interface for HTTP server-side request handler",
 | 
			
		||||
    "keywords": [
 | 
			
		||||
        "psr",
 | 
			
		||||
        "psr-7",
 | 
			
		||||
        "psr-15",
 | 
			
		||||
        "http-interop",
 | 
			
		||||
        "http",
 | 
			
		||||
        "server",
 | 
			
		||||
        "handler",
 | 
			
		||||
        "request",
 | 
			
		||||
        "response"
 | 
			
		||||
    ],
 | 
			
		||||
    "license": "MIT",
 | 
			
		||||
    "authors": [
 | 
			
		||||
        {
 | 
			
		||||
            "name": "PHP-FIG",
 | 
			
		||||
            "homepage": "https://www.php-fig.org/"
 | 
			
		||||
        }
 | 
			
		||||
    ],
 | 
			
		||||
    "require": {
 | 
			
		||||
        "php": ">=7.0",
 | 
			
		||||
        "psr/http-message": "^1.0 || ^2.0"
 | 
			
		||||
    },
 | 
			
		||||
    "autoload": {
 | 
			
		||||
        "psr-4": {
 | 
			
		||||
            "Psr\\Http\\Server\\": "src/"
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    "extra": {
 | 
			
		||||
        "branch-alias": {
 | 
			
		||||
            "dev-master": "1.0.x-dev"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										22
									
								
								qwen/php/vendor/psr/http-server-handler/src/RequestHandlerInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								qwen/php/vendor/psr/http-server-handler/src/RequestHandlerInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,22 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Server;
 | 
			
		||||
 | 
			
		||||
use Psr\Http\Message\ResponseInterface;
 | 
			
		||||
use Psr\Http\Message\ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Handles a server request and produces a response.
 | 
			
		||||
 *
 | 
			
		||||
 * An HTTP request handler process an HTTP request in order to produce an
 | 
			
		||||
 * HTTP response.
 | 
			
		||||
 */
 | 
			
		||||
interface RequestHandlerInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Handles a request and produces a response.
 | 
			
		||||
     *
 | 
			
		||||
     * May call other collaborating code to generate the response.
 | 
			
		||||
     */
 | 
			
		||||
    public function handle(ServerRequestInterface $request): ResponseInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										21
									
								
								qwen/php/vendor/psr/http-server-middleware/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								qwen/php/vendor/psr/http-server-middleware/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,21 @@
 | 
			
		||||
The MIT License (MIT)
 | 
			
		||||
 | 
			
		||||
Copyright (c) 2016 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.
 | 
			
		||||
							
								
								
									
										12
									
								
								qwen/php/vendor/psr/http-server-middleware/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								qwen/php/vendor/psr/http-server-middleware/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
			
		||||
HTTP Server Middleware
 | 
			
		||||
==============
 | 
			
		||||
 | 
			
		||||
This repository holds the `MiddlewareInterface` related to [PSR-15 (HTTP Server Request Handlers)][psr-url].
 | 
			
		||||
 | 
			
		||||
Note that this is not a Middleware implementation of its own. It is merely the interface that describe a Middleware.
 | 
			
		||||
 | 
			
		||||
The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist.
 | 
			
		||||
 | 
			
		||||
[psr-url]: https://www.php-fig.org/psr/psr-15/
 | 
			
		||||
[package-url]: https://packagist.org/packages/psr/http-server-middleware
 | 
			
		||||
[implementation-url]: https://packagist.org/providers/psr/http-server-middleware-implementation
 | 
			
		||||
							
								
								
									
										36
									
								
								qwen/php/vendor/psr/http-server-middleware/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										36
									
								
								qwen/php/vendor/psr/http-server-middleware/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,36 @@
 | 
			
		||||
{
 | 
			
		||||
    "name": "psr/http-server-middleware",
 | 
			
		||||
    "description": "Common interface for HTTP server-side middleware",
 | 
			
		||||
    "keywords": [
 | 
			
		||||
        "psr",
 | 
			
		||||
        "psr-7",
 | 
			
		||||
        "psr-15",
 | 
			
		||||
        "http-interop",
 | 
			
		||||
        "http",
 | 
			
		||||
        "middleware",
 | 
			
		||||
        "request",
 | 
			
		||||
        "response"
 | 
			
		||||
    ],
 | 
			
		||||
    "license": "MIT",
 | 
			
		||||
    "authors": [
 | 
			
		||||
        {
 | 
			
		||||
            "name": "PHP-FIG",
 | 
			
		||||
            "homepage": "https://www.php-fig.org/"
 | 
			
		||||
        }
 | 
			
		||||
    ],
 | 
			
		||||
    "require": {
 | 
			
		||||
        "php": ">=7.0",
 | 
			
		||||
        "psr/http-message": "^1.0 || ^2.0",
 | 
			
		||||
        "psr/http-server-handler": "^1.0"
 | 
			
		||||
    },
 | 
			
		||||
    "autoload": {
 | 
			
		||||
        "psr-4": {
 | 
			
		||||
            "Psr\\Http\\Server\\": "src/"
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    "extra": {
 | 
			
		||||
        "branch-alias": {
 | 
			
		||||
            "dev-master": "1.0.x-dev"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										25
									
								
								qwen/php/vendor/psr/http-server-middleware/src/MiddlewareInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								qwen/php/vendor/psr/http-server-middleware/src/MiddlewareInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,25 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Http\Server;
 | 
			
		||||
 | 
			
		||||
use Psr\Http\Message\ResponseInterface;
 | 
			
		||||
use Psr\Http\Message\ServerRequestInterface;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Participant in processing a server request and response.
 | 
			
		||||
 *
 | 
			
		||||
 * An HTTP middleware component participates in processing an HTTP message:
 | 
			
		||||
 * by acting on the request, generating the response, or forwarding the
 | 
			
		||||
 * request to a subsequent middleware and possibly acting on its response.
 | 
			
		||||
 */
 | 
			
		||||
interface MiddlewareInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Process an incoming server request.
 | 
			
		||||
     *
 | 
			
		||||
     * Processes an incoming server request in order to produce a response.
 | 
			
		||||
     * If unable to produce the response itself, it may delegate to the provided
 | 
			
		||||
     * request handler to do so.
 | 
			
		||||
     */
 | 
			
		||||
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										19
									
								
								qwen/php/vendor/psr/log/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								qwen/php/vendor/psr/log/LICENSE
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
Copyright (c) 2012 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.
 | 
			
		||||
							
								
								
									
										58
									
								
								qwen/php/vendor/psr/log/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										58
									
								
								qwen/php/vendor/psr/log/README.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,58 @@
 | 
			
		||||
PSR Log
 | 
			
		||||
=======
 | 
			
		||||
 | 
			
		||||
This repository holds all interfaces/classes/traits related to
 | 
			
		||||
[PSR-3](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md).
 | 
			
		||||
 | 
			
		||||
Note that this is not a logger of its own. It is merely an interface that
 | 
			
		||||
describes a logger. See the specification for more details.
 | 
			
		||||
 | 
			
		||||
Installation
 | 
			
		||||
------------
 | 
			
		||||
 | 
			
		||||
```bash
 | 
			
		||||
composer require psr/log
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
Usage
 | 
			
		||||
-----
 | 
			
		||||
 | 
			
		||||
If you need a logger, you can use the interface like this:
 | 
			
		||||
 | 
			
		||||
```php
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
use Psr\Log\LoggerInterface;
 | 
			
		||||
 | 
			
		||||
class Foo
 | 
			
		||||
{
 | 
			
		||||
    private $logger;
 | 
			
		||||
 | 
			
		||||
    public function __construct(LoggerInterface $logger = null)
 | 
			
		||||
    {
 | 
			
		||||
        $this->logger = $logger;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public function doSomething()
 | 
			
		||||
    {
 | 
			
		||||
        if ($this->logger) {
 | 
			
		||||
            $this->logger->info('Doing work');
 | 
			
		||||
        }
 | 
			
		||||
           
 | 
			
		||||
        try {
 | 
			
		||||
            $this->doSomethingElse();
 | 
			
		||||
        } catch (Exception $exception) {
 | 
			
		||||
            $this->logger->error('Oh no!', array('exception' => $exception));
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        // do something useful
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
You can then pick one of the implementations of the interface to get a logger.
 | 
			
		||||
 | 
			
		||||
If you want to implement the interface, you can require this package and
 | 
			
		||||
implement `Psr\Log\LoggerInterface` in your code. Please read the
 | 
			
		||||
[specification text](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md)
 | 
			
		||||
for details.
 | 
			
		||||
							
								
								
									
										26
									
								
								qwen/php/vendor/psr/log/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								qwen/php/vendor/psr/log/composer.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,26 @@
 | 
			
		||||
{
 | 
			
		||||
    "name": "psr/log",
 | 
			
		||||
    "description": "Common interface for logging libraries",
 | 
			
		||||
    "keywords": ["psr", "psr-3", "log"],
 | 
			
		||||
    "homepage": "https://github.com/php-fig/log",
 | 
			
		||||
    "license": "MIT",
 | 
			
		||||
    "authors": [
 | 
			
		||||
        {
 | 
			
		||||
            "name": "PHP-FIG",
 | 
			
		||||
            "homepage": "https://www.php-fig.org/"
 | 
			
		||||
        }
 | 
			
		||||
    ],
 | 
			
		||||
    "require": {
 | 
			
		||||
        "php": ">=8.0.0"
 | 
			
		||||
    },
 | 
			
		||||
    "autoload": {
 | 
			
		||||
        "psr-4": {
 | 
			
		||||
            "Psr\\Log\\": "src"
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    "extra": {
 | 
			
		||||
        "branch-alias": {
 | 
			
		||||
            "dev-master": "3.x-dev"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										15
									
								
								qwen/php/vendor/psr/log/src/AbstractLogger.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								qwen/php/vendor/psr/log/src/AbstractLogger.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,15 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * This is a simple Logger implementation that other Loggers can inherit from.
 | 
			
		||||
 *
 | 
			
		||||
 * It simply delegates all log-level-specific methods to the `log` method to
 | 
			
		||||
 * reduce boilerplate code that a simple Logger that does the same thing with
 | 
			
		||||
 * messages regardless of the error level has to implement.
 | 
			
		||||
 */
 | 
			
		||||
abstract class AbstractLogger implements LoggerInterface
 | 
			
		||||
{
 | 
			
		||||
    use LoggerTrait;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										7
									
								
								qwen/php/vendor/psr/log/src/InvalidArgumentException.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								qwen/php/vendor/psr/log/src/InvalidArgumentException.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,7 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
class InvalidArgumentException extends \InvalidArgumentException
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										18
									
								
								qwen/php/vendor/psr/log/src/LogLevel.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								qwen/php/vendor/psr/log/src/LogLevel.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,18 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Describes log levels.
 | 
			
		||||
 */
 | 
			
		||||
class LogLevel
 | 
			
		||||
{
 | 
			
		||||
    const EMERGENCY = 'emergency';
 | 
			
		||||
    const ALERT     = 'alert';
 | 
			
		||||
    const CRITICAL  = 'critical';
 | 
			
		||||
    const ERROR     = 'error';
 | 
			
		||||
    const WARNING   = 'warning';
 | 
			
		||||
    const NOTICE    = 'notice';
 | 
			
		||||
    const INFO      = 'info';
 | 
			
		||||
    const DEBUG     = 'debug';
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										14
									
								
								qwen/php/vendor/psr/log/src/LoggerAwareInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								qwen/php/vendor/psr/log/src/LoggerAwareInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,14 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Describes a logger-aware instance.
 | 
			
		||||
 */
 | 
			
		||||
interface LoggerAwareInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Sets a logger instance on the object.
 | 
			
		||||
     */
 | 
			
		||||
    public function setLogger(LoggerInterface $logger): void;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										22
									
								
								qwen/php/vendor/psr/log/src/LoggerAwareTrait.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								qwen/php/vendor/psr/log/src/LoggerAwareTrait.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,22 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Basic Implementation of LoggerAwareInterface.
 | 
			
		||||
 */
 | 
			
		||||
trait LoggerAwareTrait
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * The logger instance.
 | 
			
		||||
     */
 | 
			
		||||
    protected ?LoggerInterface $logger = null;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Sets a logger.
 | 
			
		||||
     */
 | 
			
		||||
    public function setLogger(LoggerInterface $logger): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->logger = $logger;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										98
									
								
								qwen/php/vendor/psr/log/src/LoggerInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										98
									
								
								qwen/php/vendor/psr/log/src/LoggerInterface.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,98 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Describes a logger instance.
 | 
			
		||||
 *
 | 
			
		||||
 * The message MUST be a string or object implementing __toString().
 | 
			
		||||
 *
 | 
			
		||||
 * The message MAY contain placeholders in the form: {foo} where foo
 | 
			
		||||
 * will be replaced by the context data in key "foo".
 | 
			
		||||
 *
 | 
			
		||||
 * The context array can contain arbitrary data. The only assumption that
 | 
			
		||||
 * can be made by implementors is that if an Exception instance is given
 | 
			
		||||
 * to produce a stack trace, it MUST be in a key named "exception".
 | 
			
		||||
 *
 | 
			
		||||
 * See https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md
 | 
			
		||||
 * for the full interface specification.
 | 
			
		||||
 */
 | 
			
		||||
interface LoggerInterface
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * System is unusable.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function emergency(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Action must be taken immediately.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: Entire website down, database unavailable, etc. This should
 | 
			
		||||
     * trigger the SMS alerts and wake you up.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function alert(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Critical conditions.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: Application component unavailable, unexpected exception.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function critical(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Runtime errors that do not require immediate action but should typically
 | 
			
		||||
     * be logged and monitored.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function error(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Exceptional occurrences that are not errors.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: Use of deprecated APIs, poor use of an API, undesirable things
 | 
			
		||||
     * that are not necessarily wrong.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function warning(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Normal but significant events.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function notice(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Interesting events.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: User logs in, SQL logs.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function info(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Detailed debug information.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     */
 | 
			
		||||
    public function debug(string|\Stringable $message, array $context = []): void;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Logs with an arbitrary level.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed $level
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     *
 | 
			
		||||
     * @throws \Psr\Log\InvalidArgumentException
 | 
			
		||||
     */
 | 
			
		||||
    public function log($level, string|\Stringable $message, array $context = []): void;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										98
									
								
								qwen/php/vendor/psr/log/src/LoggerTrait.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										98
									
								
								qwen/php/vendor/psr/log/src/LoggerTrait.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,98 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * This is a simple Logger trait that classes unable to extend AbstractLogger
 | 
			
		||||
 * (because they extend another class, etc) can include.
 | 
			
		||||
 *
 | 
			
		||||
 * It simply delegates all log-level-specific methods to the `log` method to
 | 
			
		||||
 * reduce boilerplate code that a simple Logger that does the same thing with
 | 
			
		||||
 * messages regardless of the error level has to implement.
 | 
			
		||||
 */
 | 
			
		||||
trait LoggerTrait
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * System is unusable.
 | 
			
		||||
     */
 | 
			
		||||
    public function emergency(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::EMERGENCY, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Action must be taken immediately.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: Entire website down, database unavailable, etc. This should
 | 
			
		||||
     * trigger the SMS alerts and wake you up.
 | 
			
		||||
     */
 | 
			
		||||
    public function alert(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::ALERT, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Critical conditions.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: Application component unavailable, unexpected exception.
 | 
			
		||||
     */
 | 
			
		||||
    public function critical(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::CRITICAL, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Runtime errors that do not require immediate action but should typically
 | 
			
		||||
     * be logged and monitored.
 | 
			
		||||
     */
 | 
			
		||||
    public function error(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::ERROR, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Exceptional occurrences that are not errors.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: Use of deprecated APIs, poor use of an API, undesirable things
 | 
			
		||||
     * that are not necessarily wrong.
 | 
			
		||||
     */
 | 
			
		||||
    public function warning(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::WARNING, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Normal but significant events.
 | 
			
		||||
     */
 | 
			
		||||
    public function notice(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::NOTICE, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Interesting events.
 | 
			
		||||
     *
 | 
			
		||||
     * Example: User logs in, SQL logs.
 | 
			
		||||
     */
 | 
			
		||||
    public function info(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::INFO, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Detailed debug information.
 | 
			
		||||
     */
 | 
			
		||||
    public function debug(string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        $this->log(LogLevel::DEBUG, $message, $context);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Logs with an arbitrary level.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed $level
 | 
			
		||||
     *
 | 
			
		||||
     * @throws \Psr\Log\InvalidArgumentException
 | 
			
		||||
     */
 | 
			
		||||
    abstract public function log($level, string|\Stringable $message, array $context = []): void;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										26
									
								
								qwen/php/vendor/psr/log/src/NullLogger.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								qwen/php/vendor/psr/log/src/NullLogger.php
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,26 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace Psr\Log;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * This Logger can be used to avoid conditional log calls.
 | 
			
		||||
 *
 | 
			
		||||
 * Logging should always be optional, and if no logger is provided to your
 | 
			
		||||
 * library creating a NullLogger instance to have something to throw logs at
 | 
			
		||||
 * is a good way to avoid littering your code with `if ($this->logger) { }`
 | 
			
		||||
 * blocks.
 | 
			
		||||
 */
 | 
			
		||||
class NullLogger extends AbstractLogger
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * Logs with an arbitrary level.
 | 
			
		||||
     *
 | 
			
		||||
     * @param mixed[] $context
 | 
			
		||||
     *
 | 
			
		||||
     * @throws \Psr\Log\InvalidArgumentException
 | 
			
		||||
     */
 | 
			
		||||
    public function log($level, string|\Stringable $message, array $context = []): void
 | 
			
		||||
    {
 | 
			
		||||
        // noop
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user