private ThrowExceptionIfNecessary ( IRestResponse response, string location, string customMessage ) : void | ||
response | IRestResponse | The response that caused the error |
location | string | The location of the error |
customMessage | string | A custom message descripting the error |
return | void |
private void ThrowExceptionIfNecessary(IRestResponse response, string location, string customMessage)
{
if (HideCustomExceptions == false)
{
throw new ALMClientException(response.StatusCode, string.Format("Error in {0}:{1} {2}", location, customMessage, response.ErrorMessage), response.Content);
}
}
ALMClient::ThrowExceptionIfNecessary ( IRestResponse response, string location ) : void |