Custom exception for JSON read/write errors in LangChain4j.
// Source: https://github.com/langchain4j/langchain4j | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
// Provided via justclaw.it.com; keep this notice with the code.
package dev.langchain4j.exception;
/**
* Thrown when LangChain4j cannot read or write JSON.
*
* <p>Which JSON library is doing the work is a detail of how the application is assembled, so the
* exception a caller sees should not depend on it. That library's own failure is kept as the
* {@linkplain #getCause() cause}.
*
* <p><b>Not yet reported everywhere.</b> The codecs in {@code langchain4j-jackson3} report
* failures as these types. The Jackson 2 codecs, which are what LangChain4j uses by default, still
* wrap Jackson's own exception in a plain {@link RuntimeException}
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key