protected function initMessage($level, $message, array $context)
    {
        // assert that message is a string, and interpolate placeholders
        $message = (string) $message;
        $context = $this->initContext($context);
        $message = self::interpolate($message, $context);

        // create message object
        $messageObj = new Message();
        $messageObj->setLevel($level);
        $messageObj->setShortMessage($message);
        $messageObj->setFacility($this->facility);

        foreach ($this->getDefaultContext() as $key => $value) {
            $messageObj->setAdditional($key, $value);
        }
        foreach ($context as $key => $value) {
            $messageObj->setAdditional($key, $value);
        }

        return $messageObj;
    }
protected function initMessage($level, $message, array $context)
    {
        // assert that message is a string, and interpolate placeholders
        $message = (string) $message;
        $context = $this->initContext($context);
        $message = self::interpolate($message, $context);

        // create message object
        $messageObj = new Message();
        $messageObj->setLevel($level);
        $messageObj->setShortMessage($message);
        $messageObj->setFacility($this->facility);

        foreach ($this->getDefaultContext() as $key => $value) {
            $messageObj->setAdditional($key, $value);
        }
        foreach ($context as $key => $value) {
            $messageObj->setAdditional($key, $value);
        }

        return $messageObj;
    }
protected function initMessage ( $ level , $ message , array $ context ) { // assert that message is a string, and interpolate placeholders $ message = ( string ) $ message ; $ context = $ this -> initContext ( $ context ) ; $ message = self :: interpolate ( $ message , $ context ) ; // create message object $ messageObj = new Message ( ) ; $ messageObj -> setLevel ( $ level ) ; $ messageObj -> setShortMessage ( $ message ) ; $ messageObj -> setFacility ( $ this -> facility ) ; foreach ( $ this -> getDefaultContext ( ) as $ key => $ value ) { $ messageObj -> setAdditional ( $ key , $ value ) ; } foreach ( $ context as $ key => $ value ) { $ messageObj -> setAdditional ( $ key , $ value ) ; } return $ messageObj ; }
Initializes message-object

@param  mixed   $level
@param  mixed   $message
@param  array   $context
@return Message
Initializes message - object