/* scorpiox_io — pluggable synchronous HTTP transport. * Core never links libcurl; iOS supplies URLSession behind this vtable. */ #ifndef SCORPIOX_IO_H #define SCORPIOX_IO_H #ifdef __cplusplus extern "C" { #endif typedef struct scorpiox_io { void *ctx; /* Return 0 = completed (*http_code set); -1 = transport failure (*out_err set). * Backend mallocs *out_body / *out_err; core frees via free_buf. */ int (*http_get) (void *ctx, const char *url, char **out_body, long *http_code, char **out_err); int (*http_post)(void *ctx, const char *url, const char *body, const char *content_type, char **out_body, long *http_code, char **out_err); void (*free_buf)(void *ctx, void *ptr); } scorpiox_io; #ifdef __cplusplus } #endif #endif