mageguide/mglogger

Adds Custom Logger Functionality mageguide.log

Installs: 31

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Type:magento2-module

1.0.3 2017-12-05 08:44 UTC

This package is not auto-updated.

Last update: 2024-05-05 11:30:04 UTC


README

Adds Custom Logger Functionality (mageguide.log)

Usage example:

class mgLoggerExample
{
    /**
     * Logging instance
    */
    protected $_mglogger;

    /**
     * Constructor injection
     */
    public function __construct(
        \MageGuide\Mglogger\Logger\Logger $mglogger
    ) {
        $this->_mglogger = $mglogger;
    }

    /* Some function to call logger */
    public function doSomething()
    {
        $this->_mglogger->info('Info Test');
        $this->_mglogger->alert('Alert Test');
        $this->_mglogger->critical('Critical Test');
        $this->_mglogger->emergency('Emergency Test');
        $this->_mglogger->error('Error Test');
        $this->_mglogger->notice('Notice Test');
        $this->_mglogger->warning('Warning Test');
    }
}