for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Base class for error handlers
*
* @file BaseErrorHandler.php
* PHP version 5.4+
* @author Yancharuk Alexander <alex at itvault dot info>
* @copyright © 2012-2015 Alexander Yancharuk <alex at itvault at info>
* @date 2015-08-10 10:07
* @license The BSD 3-Clause License
* <https://tldrlegal.com/license/bsd-3-clause-license-(revised)>
*/
namespace Veles\ErrorHandler;
use Veles\Helpers\Observable;
* Class BaseErrorHandler
class BaseErrorHandler extends Observable
{
/** @var array */
protected $vars = [];
/** @var string */
protected $time;
* Get error variables
* @return array
public function getVars()
return $this->vars;
}
* @return string
public function getTime()
if (null === $this->time) {
$this->time = strftime('%Y-%m-%d %H:%M:%S', time());
return $this->time;
* @param string $time
* @return $this
public function setTime($time)
$this->time = $time;
return $this;