com.clinia.exceptions.CliniaResponseException Maven / Gradle / Ivy
package com.clinia.exceptions;
/** Exception thrown in case of API failure such as 4XX, 5XX error. */
public class CliniaResponseException extends CliniaRuntimeException {
private static final long serialVersionUID = 1L;
public int getHttpErrorCode() {
return httpErrorCode;
}
private final int httpErrorCode;
public CliniaResponseException(String message, Throwable cause, int httpErrorCode) {
super(message, cause);
this.httpErrorCode = httpErrorCode;
}
public CliniaResponseException(String message, int httpErrorCode) {
super(message);
this.httpErrorCode = httpErrorCode;
}
public CliniaResponseException(Throwable cause, int httpErrorCode) {
super(cause);
this.httpErrorCode = httpErrorCode;
}
}