Файловый менеджер - Редактировать - /home/tuudkjt/globeasy/wp-content/plugins/reviewx/vendor/nahid/apiz/src/Http/Clients/AbstractClient.php
Назад
<?php namespace Rvx\Apiz\Http\Clients; use Exception; use Rvx\Psr\Http\Message\RequestInterface; use Rvx\Psr\Http\Message\ResponseInterface; use Rvx\Psr\Http\Message\UriInterface; abstract class AbstractClient { /** * @var array */ protected $config; public function __construct($config = []) { $this->config = $config; } /** * @return string */ protected abstract function getRequestClass() : string; /** * @return string */ protected abstract function getResponseClass() : string; /** * @return string */ protected abstract function getUriClass() : string; /** * @param array $args * @return ResponseInterface * @throws Exception */ public abstract function send(...$args) : ResponseInterface; /** * @param mixed ...$args * @return RequestInterface */ public function getRequest(...$args) { $class = $this->getRequestClass(); return new $class(...$args); } /** * @param mixed ...$args * @return ResponseInterface */ public function getResponse(...$args) { $class = $this->getResponseClass(); return new $class(...$args); } /** * @param mixed ...$args * @return UriInterface */ public function getUri(...$args) { $class = $this->getUriClass(); return new $class(...$args); } /** * @param ResponseInterface $response * @return bool */ public function isValidResponse(ResponseInterface $response) { $responseClass = $this->getResponseClass(); if ($response instanceof $responseClass) { return \true; } return \false; } }
| ver. 1.6 |
Github
|
.
| PHP 8.1.34 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка