2017 © Pedro Peláez
 

microphork-package package-debug

A simple debugging package for the microphork framework

image

microphork/package-debug

A simple debugging package for the microphork framework

  • Sunday, March 23, 2014
  • by elenor
  • Repository
  • 0 Watchers
  • 0 Stars
  • 148 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Introduction

This is a simple debugging package for the microphork framework. The debug class is a dispatcher. The display handler outputs the debugging data and the log handler logs it to a file., (*1)

To extend this package create a \Phork\App\Debug class in the app/classes folder and an app/config/debug.php file to define the active handler(s)., (*2)

Usage

//load and initialize a new debug package
$class = \Phork::instance()->initPackage('Debug');
$debug = new $class();

//get the loaded config
$config = \Phork::config()->get('debug');

//initialize the debug handler
if ($config->handlers && $handlers = $config->handlers->export()) {
    $debug->init($handlers);
}

//send some debugging data
$debug->log('this', 'will', 'be', 'concatenated');

Credits

Built by Elenor at Phork Labs., (*3)

License

Licensed under The MIT License http://www.opensource.org/licenses/mit-license.php, (*4)

The Versions

23/03 2014

dev-master

9999999-dev

A simple debugging package for the microphork framework

  Sources   Download

The Requires