mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-21 07:35:34 +08:00
@@ -13,8 +13,6 @@ use OneBot\V12\Object\ActionResponse;
|
||||
use OneBot\V12\Object\OneBotEvent;
|
||||
use Psr\Http\Message\ServerRequestInterface;
|
||||
use ZM\Context\BotContext;
|
||||
use ZM\Context\Context;
|
||||
use ZM\Context\ContextInterface;
|
||||
|
||||
class ContainerRegistrant
|
||||
{
|
||||
@@ -59,7 +57,6 @@ class ContainerRegistrant
|
||||
'http.request.event' => DI\get(HttpRequestEvent::class),
|
||||
ServerRequestInterface::class => fn () => $event->getRequest(),
|
||||
'http.request' => DI\get(ServerRequestInterface::class),
|
||||
ContextInterface::class => Context::class,
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace ZM\Context;
|
||||
|
||||
use ZM\Context\Trait\HttpTrait;
|
||||
|
||||
/**
|
||||
* 下面是机器人类的方法
|
||||
* @method reply($message) 快速回复消息
|
||||
* @method action(string $action, array $params = []) 执行动作
|
||||
* @method getArgument(string $name) 获取BotCommand的参数
|
||||
* @method getRawArguments() 获取裸的参数
|
||||
* @method getBotEvent(bool $array = false) 获取事件原对象
|
||||
* @method getBotSelf() 获取机器人自身的信息
|
||||
*/
|
||||
class Context implements ContextInterface
|
||||
{
|
||||
use HttpTrait;
|
||||
|
||||
// TODO:完善上下文的方法们
|
||||
}
|
||||
Reference in New Issue
Block a user