mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-14 04:05:35 +08:00
refactor bot action sender, add BotMap to mark bot
This commit is contained in:
31
src/ZM/Context/BotConnectContext.php
Normal file
31
src/ZM/Context/BotConnectContext.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace ZM\Context;
|
||||
|
||||
use ZM\Context\Trait\BotActionTrait;
|
||||
|
||||
/**
|
||||
* 机器人裸连接的上下文
|
||||
*/
|
||||
class BotConnectContext
|
||||
{
|
||||
use BotActionTrait;
|
||||
|
||||
private ?array $self = null;
|
||||
|
||||
public function __construct(private int $flag, private int $fd)
|
||||
{
|
||||
}
|
||||
|
||||
public function getFd(): int
|
||||
{
|
||||
return $this->fd;
|
||||
}
|
||||
|
||||
public function getFlag(): int
|
||||
{
|
||||
return $this->flag;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user