#pragma once typedef void exdata_free(int idx, void *ex_ptr, void *arg); struct exdata_schema; struct exdata_schema *exdata_schema_new(); void exdata_schema_free(struct exdata_schema *s); int exdata_new_index(struct exdata_schema *schema, const char *name, exdata_free *free_func,void *free_arg); int exdata_schema_get_idx_by_name(struct exdata_schema *schema, const char *name); struct exdata_runtime; struct exdata_runtime *exdata_handle_new(struct exdata_schema *h); void exdata_handle_free(struct exdata_runtime *h); void exdata_handle_reset(struct exdata_runtime *h); int exdata_set(struct exdata_runtime *h, int idx, void *ex_ptr); void *exdata_get(struct exdata_runtime *h, int idx);