Class GraphTimeoutException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
cloud.opencode.base.core.exception.OpenException
cloud.opencode.base.graph.exception.GraphException
cloud.opencode.base.graph.exception.GraphTimeoutException
- All Implemented Interfaces:
OpenExceptionMeta, Serializable
Graph Timeout Exception
图计算超时异常
Exception thrown when a graph computation times out.
当图计算超时时抛出的异常。
Features | 主要功能:
- Carries timeout duration information - 携带超时时长信息
- Extends
GraphExceptionwithGraphErrorCode.TIMEOUT- 使用TIMEOUT错误码扩展GraphException
Usage Examples | 使用示例:
try {
SafeGraphOperations.safeShortestPath(graph, source, target);
} catch (GraphTimeoutException e) {
Duration timeout = e.getTimeout();
}
Security | 安全性:
- Thread-safe: Yes (immutable after construction) - 线程安全: 是(构造后不可变)
- Null-safe: Yes (timeout may be null) - 空值安全: 是(timeout可能为null)
- Since:
- JDK 25, opencode-base-graph V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGraphTimeoutException(String message) Create graph timeout exception 创建图计算超时异常GraphTimeoutException(String message, Duration timeout) Create graph timeout exception with timeout duration 使用超时时长创建图计算超时异常 -
Method Summary
Methods inherited from class GraphException
getGraphErrorCodeMethods inherited from class OpenException
getComponent, getErrorCode, getMessage, getRawMessageMethods inherited from class Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface OpenExceptionMeta
getMetaPrefix
-
Constructor Details
-
GraphTimeoutException
Create graph timeout exception 创建图计算超时异常- Parameters:
message- the error message | 错误消息
-
GraphTimeoutException
-
-
Method Details
-
getTimeout
-