File tree Expand file tree Collapse file tree 3 files changed +7
-0
lines changed
core/src/main/java/com/sap/ai/sdk/core/commons Expand file tree Collapse file tree 3 files changed +7
-0
lines changed Original file line number Diff line number Diff line change 11package com .sap .ai .sdk .core .commons ;
22
3+ import com .google .common .annotations .Beta ;
34import javax .annotation .Nonnull ;
45
56/**
67 * Generic class that contains a JSON error response.
78 *
89 * @since 1.1.0
910 */
11+ @ Beta
12+ @ FunctionalInterface
1013public interface ClientError {
1114 /**
1215 * Get the error message.
Original file line number Diff line number Diff line change 11package com .sap .ai .sdk .core .commons ;
22
3+ import com .google .common .annotations .Beta ;
34import lombok .experimental .StandardException ;
45
56/**
67 * Generic exception for errors occurring when using AI SDK clients.
78 *
89 * @since 1.1.0
910 */
11+ @ Beta
1012@ StandardException
1113public class ClientException extends RuntimeException {}
Original file line number Diff line number Diff line change 44
55import com .fasterxml .jackson .core .JsonProcessingException ;
66import com .fasterxml .jackson .databind .ObjectMapper ;
7+ import com .google .common .annotations .Beta ;
78import io .vavr .control .Try ;
89import java .io .IOException ;
910import java .nio .charset .StandardCharsets ;
2627 * @param <E> The type of the exception to throw
2728 * @since 1.1.0
2829 */
30+ @ Beta
2931@ Slf4j
3032@ RequiredArgsConstructor
3133public class ClientResponseHandler <T , E extends ClientException >
You can’t perform that action at this time.
0 commit comments