update api docs

This commit is contained in:
Github Build Bot 2022-04-02 11:37:16 +00:00
parent daa1822bc5
commit ff0f11da7f
7 changed files with 69 additions and 68 deletions

View File

@ -1 +1 @@
module.exports = [{"title":"ZM","collapsable":true,"children":["ZM/ZMServer","ZM/ConsoleApplication","ZM/Framework"]},{"title":"ZM/API","collapsable":true,"children":["ZM/API/CQ","ZM/API/OneBotV11","ZM/API/TuringAPI","ZM/API/GoCqhttpAPIV11"]},{"title":"ZM/Annotation","collapsable":true,"children":["ZM/Annotation/AnnotationParser"]},{"title":"ZM/Annotation/Swoole","collapsable":true,"children":["ZM/Annotation/Swoole/OnSwooleEventBase"]},{"title":"ZM/Command","collapsable":true,"children":["ZM/Command/CheckConfigCommand"]},{"title":"ZM/Command/Generate","collapsable":true,"children":["ZM/Command/Generate/APIDocsGenerateCommand"]},{"title":"ZM/Context","collapsable":true,"children":["ZM/Context/Context"]},{"title":"ZM/DB","collapsable":true,"children":["ZM/DB/Table","ZM/DB/DeleteBody","ZM/DB/UpdateBody","ZM/DB/DB","ZM/DB/SelectBody","ZM/DB/InsertBody"]},{"title":"ZM/Event","collapsable":true,"children":["ZM/Event/EventManager","ZM/Event/EventTracer","ZM/Event/EventDispatcher"]},{"title":"ZM/Event/SwooleEvent","collapsable":true,"children":["ZM/Event/SwooleEvent/OnWorkerStart","ZM/Event/SwooleEvent/OnTask"]},{"title":"ZM/Http","collapsable":true,"children":["ZM/Http/Response"]},{"title":"ZM/Module","collapsable":true,"children":["ZM/Module/ModuleUnpacker","ZM/Module/ModulePacker","ZM/Module/ModuleBase","ZM/Module/QQBot"]},{"title":"ZM/MySQL","collapsable":true,"children":["ZM/MySQL/MySQLStatementWrapper","ZM/MySQL/MySQLQueryBuilder","ZM/MySQL/MySQLWrapper","ZM/MySQL/MySQLPool"]},{"title":"ZM/Store","collapsable":true,"children":["ZM/Store/LightCache","ZM/Store/ZMAtomic","ZM/Store/LightCacheInside"]},{"title":"ZM/Store/Redis","collapsable":true,"children":["ZM/Store/Redis/ZMRedis"]},{"title":"ZM/Utils","collapsable":true,"children":["ZM/Utils/Terminal","ZM/Utils/MessageUtil","ZM/Utils/DataProvider","ZM/Utils/SignalListener","ZM/Utils/ZMUtil","ZM/Utils/HttpUtil","ZM/Utils/CoMessage"]},{"title":"ZM/Utils/Manager","collapsable":true,"children":["ZM/Utils/Manager/CronManager","ZM/Utils/Manager/ModuleManager","ZM/Utils/Manager/WorkerManager"]}]
module.exports = [{"title":"ZM","collapsable":true,"children":["ZM/Framework","ZM/ConsoleApplication","ZM/ZMServer"]},{"title":"ZM/API","collapsable":true,"children":["ZM/API/TuringAPI","ZM/API/GoCqhttpAPIV11","ZM/API/CQ","ZM/API/OneBotV11"]},{"title":"ZM/Annotation","collapsable":true,"children":["ZM/Annotation/AnnotationParser"]},{"title":"ZM/Annotation/Swoole","collapsable":true,"children":["ZM/Annotation/Swoole/OnSwooleEventBase"]},{"title":"ZM/Command","collapsable":true,"children":["ZM/Command/CheckConfigCommand"]},{"title":"ZM/Command/Module","collapsable":true,"children":["ZM/Command/Module/ModuleListCommand","ZM/Command/Module/ModulePackCommand"]},{"title":"ZM/Context","collapsable":true,"children":["ZM/Context/Context"]},{"title":"ZM/DB","collapsable":true,"children":["ZM/DB/InsertBody","ZM/DB/DB","ZM/DB/DeleteBody","ZM/DB/UpdateBody","ZM/DB/Table","ZM/DB/SelectBody"]},{"title":"ZM/Event","collapsable":true,"children":["ZM/Event/EventManager","ZM/Event/EventTracer","ZM/Event/EventDispatcher"]},{"title":"ZM/Event/SwooleEvent","collapsable":true,"children":["ZM/Event/SwooleEvent/OnWorkerStart","ZM/Event/SwooleEvent/OnTask"]},{"title":"ZM/Http","collapsable":true,"children":["ZM/Http/Response"]},{"title":"ZM/Module","collapsable":true,"children":["ZM/Module/ModuleBase","ZM/Module/ModuleUnpacker","ZM/Module/QQBot","ZM/Module/ModulePacker"]},{"title":"ZM/MySQL","collapsable":true,"children":["ZM/MySQL/MySQLQueryBuilder","ZM/MySQL/MySQLPool","ZM/MySQL/MySQLStatementWrapper","ZM/MySQL/MySQLWrapper"]},{"title":"ZM/Store","collapsable":true,"children":["ZM/Store/LightCacheInside","ZM/Store/LightCache","ZM/Store/ZMAtomic"]},{"title":"ZM/Store/Redis","collapsable":true,"children":["ZM/Store/Redis/ZMRedis"]},{"title":"ZM/Utils","collapsable":true,"children":["ZM/Utils/ZMUtil","ZM/Utils/DataProvider","ZM/Utils/HttpUtil","ZM/Utils/SignalListener","ZM/Utils/MessageUtil","ZM/Utils/Terminal","ZM/Utils/CoMessage"]},{"title":"ZM/Utils/Manager","collapsable":true,"children":["ZM/Utils/Manager/CronManager","ZM/Utils/Manager/ModuleManager","ZM/Utils/Manager/WorkerManager"]}]

View File

@ -3,24 +3,24 @@
## get
```php
public function get(int|string $robot_id): ZMRobot
public function get(mixed $robot_id): ZMRobot
```
### 描述
获取机器人Action/API实例
作者很懒,什么也没有说
### 参数
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| robot_id | int|string | 机器人ID |
| robot_id | mixed | |
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| ZMRobot | 机器人实例 |
| ZMRobot | |
## getRandom
@ -31,13 +31,13 @@ public function getRandom(): ZMRobot
### 描述
随机获取一个连接到框架的机器人实例
作者很懒,什么也没有说
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| ZMRobot | 机器人实例 |
| ZMRobot | |
## getAllRobot
@ -48,65 +48,19 @@ public function getAllRobot(): ZMRobot[]
### 描述
获取所有机器人实例
作者很懒,什么也没有说
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| ZMRobot[] | 机器人实例们 |
## setCallback
```php
public function setCallback(bool|Closure $callback): OneBotV11
```
### 描述
设置回调或启用协程等待API回包
### 参数
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| callback | bool|Closure | 是否开启协程或设置异步回调函数如果为true则协程等待结果如果为false则异步执行并不等待结果如果为回调函数则异步执行且调用回调 |
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| OneBotV11 | 返回本身 |
## setPrefix
```php
public function setPrefix(int $prefix): OneBotV11
```
### 描述
设置API调用类型后缀
### 参数
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| prefix | int | 设置后缀类型API_NORMAL为不加后缀API_ASYNC为异步调用API_RATE_LIMITED为加后缀并且限制调用频率 |
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| OneBotV11 | 返回本身 |
| ZMRobot[] | |
## sendPrivateMsg
```php
public function sendPrivateMsg(int|string $user_id, string $message, bool $auto_escape): array|bool
public function sendPrivateMsg(mixed $user_id, mixed $message, bool $auto_escape): null|array|bool
```
### 描述
@ -117,15 +71,15 @@ public function sendPrivateMsg(int|string $user_id, string $message, bool $auto_
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| user_id | int|string | 用户ID |
| message | string | 消息内容 |
| auto_escape | bool | 是否自动转义默认为false |
| user_id | mixed | |
| message | mixed | |
| auto_escape | bool | |
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| array|bool | 返回API调用结果数组或异步API调用状态bool |
| null|array|bool | |
## sendGroupMsg

View File

@ -1 +1,24 @@
# ZM\Command\Module\ModuleListCommand
# ZM\Command\Module\ModuleListCommand
## execute
```php
public function execute(Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output): int
```
### 描述
作者很懒,什么也没有说
### 参数
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| input | Symfony\Component\Console\Input\InputInterface | |
| output | Symfony\Component\Console\Output\OutputInterface | |
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| int | |

View File

@ -1 +1,24 @@
# ZM\Command\Module\ModulePackCommand
# ZM\Command\Module\ModulePackCommand
## execute
```php
public function execute(Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output): int
```
### 描述
作者很懒,什么也没有说
### 参数
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| input | Symfony\Component\Console\Input\InputInterface | |
| output | Symfony\Component\Console\Output\OutputInterface | |
### 返回
| 类型 | 描述 |
| ---- | ----------- |
| int | |

View File

@ -3,7 +3,7 @@
## yieldByWS
```php
public function yieldByWS(int $timeout, array $hang, array $compare): mixed
public function yieldByWS(array $hang, array $compare, int $timeout): mixed
```
### 描述
@ -14,9 +14,9 @@ public function yieldByWS(int $timeout, array $hang, array $compare): mixed
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| timeout | int | |
| hang | array | |
| compare | array | |
| timeout | int | |
### 返回

View File

@ -20,7 +20,7 @@ public function getConfiguredModules(): array
## packModule
```php
public function packModule(mixed $module): bool
public function packModule(array $module, string $target): bool
```
### 描述
@ -31,7 +31,8 @@ public function packModule(mixed $module): bool
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| module | mixed | |
| module | array | 模块信息 |
| target | string | 目标路径 |
### 返回

View File

@ -3,7 +3,7 @@
## downloadCQImage
```php
public function downloadCQImage(mixed $msg, null $path): array|false
public function downloadCQImage(mixed $msg, string $path): array|false
```
### 描述
@ -15,7 +15,7 @@ public function downloadCQImage(mixed $msg, null $path): array|false
| 名称 | 类型 | 描述 |
| -------- | ---- | ----------- |
| msg | mixed | |
| path | null | |
| path | string | |
### 返回