original_string: protected function formatParams($message, $context)
      {
          if (!is_array($context)) {
              $context = array('context' => $context);
          }
          if ($message instanceof \Exception) {
              $context += array(
                  'code' => $message->getCode(),
                  'file' => $message->getFile(),
                  'line' => $message->getLine(),
                  'trace' => $message->getTraceAsString(),
              );
              $message = $message->getMessage();
          } elseif (is_array($message)) {
              $message = print_r($message, true);
          } else {
              $message = (string)$message;
          }
          return array('message' => $message, 'context' => $context);
      }
code: protected function formatParams($message, $context)
      {
          if (!is_array($context)) {
              $context = array('context' => $context);
          }
          if ($message instanceof \Exception) {
              $context += array(
                  'code' => $message->getCode(),
                  'file' => $message->getFile(),
                  'line' => $message->getLine(),
                  'trace' => $message->getTraceAsString(),
              );
              $message = $message->getMessage();
          } elseif (is_array($message)) {
              $message = print_r($message, true);
          } else {
              $message = (string)$message;
          }
          return array('message' => $message, 'context' => $context);
      }
code_tokens: protected function formatParams ( $ message , $ context ) { if ( ! is_array ( $ context ) ) { $ context = array ( 'context' => $ context ) ; } if ( $ message instanceof \ Exception ) { $ context += array ( 'code' => $ message -> getCode ( ) , 'file' => $ message -> getFile ( ) , 'line' => $ message -> getLine ( ) , 'trace' => $ message -> getTraceAsString ( ) , ) ; $ message = $ message -> getMessage ( ) ; } elseif ( is_array ( $ message ) ) { $ message = print_r ( $ message , true ) ; } else { $ message = ( string ) $ message ; } return array ( 'message' => $ message , 'context' => $ context ) ; }
docstring: Convert message to string and content to array for writing
  
  @param string|\Exception $message
  @param string|array $context
  @return array
docstring_tokens: Convert message to string and content to array for writing