Files
CloudflareDNS-java/src/main/java/codes/thischwa/cf/CloudflareNotFoundException.java
T
thischwaandgitea-actions-bot 8515f81621
Build and Analyse / build-and-analyse (push) Successful in 1m20s
ai review (#1)
Co-authored-by: gitea-actions-bot <bot@mein-gateway.de>
Reviewed-on: #1
Co-authored-by: Thilo Schwarz <osp@thischwa.codes>
2026-11-06 14:28:06 +01:00

41 lines
1.3 KiB
Java

package codes.thischwa.cf;
import codes.thischwa.cf.model.ResponseResultInfo;
import java.io.Serial;
import java.util.List;
/**
* This exception is thrown to indicate that a requested resource was not found during interaction
* with the Cloudflare API.
*
* <p>It is thrown if Cloudflare responds with HTTP status 404, or if a result is empty and
* 'emptyResultThrowsException' is enabled.
*/
public class CloudflareNotFoundException extends CloudflareApiException {
@Serial
private static final long serialVersionUID = 1L;
/**
* Constructs a new CloudflareNotFoundException with the specified detail message.
*
* @param message the detail message, which provides additional context about the "not found"
* error encountered during interaction with the Cloudflare API.
*/
public CloudflareNotFoundException(String message) {
super(message);
}
/**
* Constructs a new CloudflareNotFoundException caused by an API response.
*
* @param message the detail message
* @param statusCode the HTTP status code of the response
* @param errors the errors reported by Cloudflare, may be {@code null}
*/
public CloudflareNotFoundException(String message, int statusCode,
List<ResponseResultInfo.Error> errors) {
super(message, statusCode, errors);
}
}