liberty_code_module / error
模块
v1.0.0
2024-02-28 18:38 UTC
Requires
- php: ~7 || ~8
- liberty_code/command: ^1.0.
- liberty_code/config: ^1.0.
- liberty_code/di: ^1.0.
- liberty_code/error: ^1.0.
- liberty_code/framework: ^1.0.
- liberty_code/http: ^1.0.
- liberty_code/library: ^1.0.
- liberty_code/register: ^1.0.
- liberty_code/request_flow: ^1.0.
This package is auto-updated.
Last update: 2024-09-28 19:58:09 UTC
README
描述
库包含框架模块,用于管理应用程序错误。
要求
- 脚本语言:PHP:版本 7 或 8
安装
有几种可能的安装方式
Composer
要求
需要安装 Composer。更多信息请参阅:https://getcomposer.org.cn
命令:在项目根路径下移动
cd "<project_root_path>"
命令:安装
php composer.phar require liberty_code_module/error ["<version>"]
注意
包含 vendor
如果项目使用 Composer,则必须包含 vendor
require_once('<project_root_path>/vendor/autoload.php');
配置
安装命令允许在 composer 文件中添加
{ "require": { "liberty_code_module/error": "<version>" } }
包含
下载
- 下载以下存储库。
- 将其放在存储库根路径上。
包含源代码
require_once('<repository_root_path>/include/Include.php');
应用程序安装
配置
配置:应用程序模块:"
在列表部分添加所需模块
YML 配置格式示例,来自 composer 安装
list: [ { path: "/vendor/liberty_code_module/error/src/error", config_parser: { type: "string_table_php", source_format_get_regexp: "#^\\<\\?php\\s*(.*)(\\s\\?\\>)?\\s*$#ms", source_format_set_pattern: "<?php \\n%1$s" } }, { path: "/vendor/liberty_code_module/error/src/handler", config_parser: { type: "string_table_php", source_format_get_regexp: "#^\\<\\?php\\s*(.*)(\\s\\?\\>)?\\s*$#ms", source_format_set_pattern: "<?php \\n%1$s" } } ]
配置
应用程序参数配置
在您的模块中使用以下文件来配置特定元素
<module_root_path>/config/ParamApp.php
可配置元素
参数警告配置
填充处理器集合配置
用法
错误
功能允许设置和管理应用程序中的错误处理。
处理器
功能允许设置和管理应用程序中的基本处理器。