original_string: protected function sendImageMsgToXmlString(WxSendImageMsg $msg)
      {
          $formatStr = <<<XML
  <xml>
  <ToUserName><![CDATA[%s]]></ToUserName>
  <FromUserName><![CDATA[%s]]></FromUserName>
  <CreateTime>%d</CreateTime>
  <MsgType><![CDATA[%s]]></MsgType>
  <Image>
  <MediaId><![CDATA[%s]]></MediaId>
  </Image>
  </xml>
  XML;
          $result = sprintf($formatStr,   $msg->getToUserName(),
                                          $msg->getFromUserName(),
                                          strtotime($msg->getCreateTime()),
                                          $msg->getMsgType(),
                                          $msg->getMediaId()
                          );
  
  
          return $result;
      }
code: protected function sendImageMsgToXmlString(WxSendImageMsg $msg)
      {
          $formatStr = <<<XML
  <xml>
  <ToUserName><![CDATA[%s]]></ToUserName>
  <FromUserName><![CDATA[%s]]></FromUserName>
  <CreateTime>%d</CreateTime>
  <MsgType><![CDATA[%s]]></MsgType>
  <Image>
  <MediaId><![CDATA[%s]]></MediaId>
  </Image>
  </xml>
  XML;
          $result = sprintf($formatStr,   $msg->getToUserName(),
                                          $msg->getFromUserName(),
                                          strtotime($msg->getCreateTime()),
                                          $msg->getMsgType(),
                                          $msg->getMediaId()
                          );
  
  
          return $result;
      }
code_tokens: protected function sendImageMsgToXmlString ( WxSendImageMsg $ msg ) { $ formatStr =  <<<XML
  <xml>
  <ToUserName><![CDATA[%s]]></ToUserName>
  <FromUserName><![CDATA[%s]]></FromUserName>
  <CreateTime>%d</CreateTime>
  <MsgType><![CDATA[%s]]></MsgType>
  <Image>
  <MediaId><![CDATA[%s]]></MediaId>
  </Image>
  </xml>
  XML ; $ result = sprintf ( $ formatStr , $ msg -> getToUserName ( ) , $ msg -> getFromUserName ( ) , strtotime ( $ msg -> getCreateTime ( ) ) , $ msg -> getMsgType ( ) , $ msg -> getMediaId ( ) ) ; return $ result ; }
docstring: formatter WxSendImageMsg to xml string
  @param WxSendImageMsg $msg
  @return string
docstring_tokens: formatter WxSendImageMsg to xml string