juandon/core

核心功能

安装: 6

依赖者: 0

建议者: 0

安全性: 0

类型:核心

dev-master 2017-07-16 01:52 UTC

This package is auto-updated.

Last update: 2024-09-23 08:13:38 UTC


README

包含注册、事件、日志功能。

安装

将以下代码添加到您的 "composer.json" 文件中

    "repositories": [
        {
            "type": "vcs",
            "url": "https://bitbucket.org/juandon/core"
        }
    ],
    "require": {
        "juandon/core": "dev-develop"
    }

然后运行 composer update 或运行 composer require juandon/core

使用方法

将以下代码添加到您的引导文件中

use \juandon\Core\Bootstrap;

Bootstrap::initByPath("./config.ini.php");

"config.ini.php" 文件

;<?php die; __halt_compiler();

[core]
; By default: Off
event[debug] = On

; By default: "StdOut"
;log[method] = "StdOut"

; By default: E_ERROR | E_WARNING
log[level] = E_ERROR | E_WARNING | E_NOTICE

;log.source[] = "*" ; means all log sources
log.source[] = "Foo::someMethod()"

@todo

单元测试。