public function __toString()
{
if ($this->getLine() < 0) {
return sprintf('[%s] %s: %s', strtoupper($this->getType()), $this->getFile(), $this->getError());
}
return sprintf('[%s] %s: %s on line %d', strtoupper($this->getType()), $this->getFile(), $this->getError(), $this->getLine());
}