类 ErrorEvent
java.lang.Object
io.agentscope.core.hook.HookEvent
io.agentscope.core.hook.ErrorEvent
已过时, 待删除: 此 API 元素将从以后的版本中删除。
Event fired when an error occurs during agent execution.
Modifiable: No (notification-only)
Context:
HookEvent.getAgent()- The agent instanceHookEvent.getMemory()- Agent's memorygetError()- The error that occurred
Use Cases:
- Log errors with context
- Send error notifications
- Collect error metrics
- Implement custom error handling
-
构造器概要
构造器构造器说明ErrorEvent(Agent agent, Throwable error) 已过时, 待删除: 此 API 元素将从以后的版本中删除。Constructor for ErrorEvent. -
方法概要
从类继承的方法 io.agentscope.core.hook.HookEvent
appendSystemContent, appendSystemContent, getAgent, getMemory, getSystemMessage, getTimestamp, getType, setSystemMessage
-
构造器详细资料
-
ErrorEvent
已过时, 待删除: 此 API 元素将从以后的版本中删除。Constructor for ErrorEvent.- 参数:
agent- The agent instance (must not be null)error- The error that occurred (must not be null)- 抛出:
NullPointerException- if agent or error is null
-
-
方法详细资料
-
getError
已过时, 待删除: 此 API 元素将从以后的版本中删除。Get the error that occurred.- 返回:
- The error
-
MiddlewareBaseinstead.