PAMI\Client\Impl\ClientImpl::messageToResponse PHP Method

messageToResponse() private method

Returns a ResponseMessage from a raw string that came from asterisk.
private messageToResponse ( string $msg ) : PAMI\Message\Response\ResponseMessage
$msg string Raw string.
return PAMI\Message\Response\ResponseMessage
    private function messageToResponse($msg)
    {
        $response = new ResponseMessage($msg);
        $actionId = $response->getActionId();
        if (is_null($actionId)) {
            $actionId = $this->lastActionId;
            $response->setActionId($this->lastActionId);
        }
        return $response;
    }