Ejemplo n.º 1
0
 def _deserialize_response(self, json_response_string,
                           protocol_response_class):
     self._protocol_bytes_received += len(json_response_string)
     self._logger.debug("response:{}".format(json_response_string))
     if not json_response_string:
         raise exceptions.EmptyResponseException()
     return protocol.fromJson(json_response_string, protocol_response_class)
Ejemplo n.º 2
0
 def _deserializeResponse(self, jsonResponseString, protocolResponseClass):
     self._protocolBytesReceived += len(jsonResponseString)
     self._logger.debug("response:{}".format(jsonResponseString))
     if jsonResponseString == '':
         raise exceptions.EmptyResponseException()
     responseObject = protocolResponseClass.fromJsonString(
         jsonResponseString)
     return responseObject
Ejemplo n.º 3
0
 def _deserializeResponse(self, response, protocolResponseClass):
     jsonResponseString = response.text
     self._updateBytesRead(jsonResponseString)
     self._debugResponse(jsonResponseString)
     if jsonResponseString == '':
         raise exceptions.EmptyResponseException()
     responseObject = protocolResponseClass.fromJsonString(
         jsonResponseString)
     return responseObject