public function setResponse(Entity $entity)
    {
        $body = $entity->getBody();

        $body['ToUserName'] = $this['FromUserName'];
        $body['FromUserName'] = $this['ToUserName'];
        $body['MsgType'] = $entity->getType();
        $body['CreateTime'] = time();

        $response = new XmlResponse($body);
        $response->send();
    }
public function setResponse(Entity $entity)
    {
        $body = $entity->getBody();

        $body['ToUserName'] = $this['FromUserName'];
        $body['FromUserName'] = $this['ToUserName'];
        $body['MsgType'] = $entity->getType();
        $body['CreateTime'] = time();

        $response = new XmlResponse($body);
        $response->send();
    }
public function setResponse ( Entity $ entity ) { $ body = $ entity -> getBody ( ) ; $ body [ 'ToUserName' ] = $ this [ 'FromUserName' ] ; $ body [ 'FromUserName' ] = $ this [ 'ToUserName' ] ; $ body [ 'MsgType' ] = $ entity -> getType ( ) ; $ body [ 'CreateTime' ] = time ( ) ; $ response = new XmlResponse ( $ body ) ; $ response -> send ( ) ; }
response message entity.
response message entity .