123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081 |
- <?php
- namespace App\JsonRpc;
- use Hyperf\RpcClient\AbstractServiceClient;
- use Hyperf\Logger\LoggerFactory;
- use Psr\Log\LoggerInterface;
- class ClientService extends AbstractServiceClient implements ClientServiceInterface
- {
- /**
- * 定义对应服务提供者的服务名称
- * @var string
- */
- protected string $serviceName = 'ClientService';
- /**
- * 定义对应服务提供者的服务协议
- * @var string
- */
- protected string $protocol = 'jsonrpc-http';
- protected $logger;
- public function __construct(LoggerFactory $loggerFactory)
- {
- $this->logger = $loggerFactory->get('default');
- }
- /**
- * test
- * @param array $data
- * @return array
- */
- public function test(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function indexData(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function addWeb(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function deleteWeb(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function updateWeb(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function getWebList(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function getWebInfo(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function updateWebConfig(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function updateWebOutput(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function updateWebMove(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function runWeb(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- public function stopWeb(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- }
|