1234567891011121314151617181920212223242526272829 |
- <?php
- namespace App\JsonRpc;
- use Hyperf\RpcClient\AbstractServiceClient;
- class CrawlerService extends AbstractServiceClient implements CrawlerServiceInterface
- {
- /**
- * 定义对应服务提供者的服务名称
- * @var string
- */
- protected string $serviceName = 'CrawlerService';
- /**
- * 定义对应服务提供者的服务协议
- * @var string
- */
- protected string $protocol = 'jsonrpc-http';
- /**
- * @param array $data
- * @return array|mixed
- */
- public function sendCrawler(array $data)
- {
- return $this->__request(__FUNCTION__, $data);
- }
- }
|