Files
kiri-core/HttpServer/Service/Packet.php
T
as2252258@163.com 682246df28 modify
2021-08-11 01:04:57 +08:00

41 lines
597 B
PHP

<?php
declare(strict_types=1);
namespace HttpServer\Service;
use HttpServer\Service\Abstracts\Tcp;
use ReflectionException;
use Kiri\Exception\NotFindClassException;
/**
* Class OnPacket
* @package HttpServer\Events
*/
class Packet extends Tcp
{
/**
* @throws ReflectionException
* @throws NotFindClassException
*/
public function onInit()
{
$this->onHandlerListener();
$this->onBaseListener();
}
/**
* @throws NotFindClassException
* @throws ReflectionException
*/
public function onBaseListener()
{
$this->on('packet', $this->createHandler('packet'));
}
}