src/Library/Logger.php
protected function addRecord($level, $message, array $context = array())
    {
        $message = $this->interpolate($message, $context);
        $record = array(
            'message' => (string) $message,
            'context' => $context,
            'level' => self::getLevelCode($level),
            'level_name' => strtoupper($level),
            'datetime' => new \DateTime(),
            'ip' => self::getUserIp(),
            'pid' => @getmypid(),
            'extra' => array(),
        );
        return self::write(self::getLogRecord($record)."\n", $level);
    }
protected function addRecord($level, $message, array $context = array())
    {
        $message = $this->interpolate($message, $context);
        $record = array(
            'message' => (string) $message,
            'context' => $context,
            'level' => self::getLevelCode($level),
            'level_name' => strtoupper($level),
            'datetime' => new \DateTime(),
            'ip' => self::getUserIp(),
            'pid' => @getmypid(),
            'extra' => array(),
        );
        return self::write(self::getLogRecord($record)."\n", $level);
    }
protected function addRecord ( $ level , $ message , array $ context = array ( ) ) { $ message = $ this -> interpolate ( $ message , $ context ) ; $ record = array ( 'message' => ( string ) $ message , 'context' => $ context , 'level' => self :: getLevelCode ( $ level ) , 'level_name' => strtoupper ( $ level ) , 'datetime' => new \ DateTime ( ) , 'ip' => self :: getUserIp ( ) , 'pid' => @ getmypid ( ) , 'extra' => array ( ) , ) ; return self :: write ( self :: getLogRecord ( $ record ) . "\n" , $ level ) ; }
Create a new log record and writes it

@param   string  $message    The message info to log
@param   int     $level      A type for the message, must be a class constant
@param   array   $context    An optional context array for the message
@return  bool
Create a new log record and writes it