Class ImageReadException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
cloud.opencode.base.image.exception.ImageException
cloud.opencode.base.image.exception.ImageIOException
cloud.opencode.base.image.exception.ImageReadException
- All Implemented Interfaces:
Serializable
Image Read Exception
图片读取异常
Exception thrown when image reading fails.
当图片读取失败时抛出的异常。
Features | 主要功能:
- Exception for image reading failures - 图片读取失败的异常
- Carries ImageErrorCode for programmatic error handling - 携带 ImageErrorCode 用于编程式错误处理
Usage Examples | 使用示例:
// Catch specific exception
try {
OpenImage.read(path);
} catch (ImageReadException e) {
System.err.println(e.getMessage());
}
Security | 安全性:
- Thread-safe: Yes (immutable exception) - 线程安全: 是(不可变异常)
- Null-safe: No (message must not be null) - 空值安全: 否(消息不能为 null)
- Since:
- JDK 25, opencode-base-image V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionImageReadException(String message) Create an image read exception 创建图片读取异常ImageReadException(String message, Throwable cause) Create an image read exception with message and cause 创建带消息和原因的图片读取异常ImageReadException(Path path) Create an image read exception with path 创建带路径的图片读取异常ImageReadException(Path path, Throwable cause) Create an image read exception with path and cause 创建带路径和原因的图片读取异常 -
Method Summary
Methods inherited from class ImageException
getErrorCodeMethods inherited from class Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
ImageReadException
Create an image read exception 创建图片读取异常- Parameters:
message- the error message | 错误消息
-
ImageReadException
Create an image read exception with path 创建带路径的图片读取异常- Parameters:
path- the file path | 文件路径
-
ImageReadException
-
ImageReadException
-
-
Method Details
-
getPath
-