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)
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
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