#include <nng/nng.h>
#include <nng/supplemental/http/http.h>
typedef struct nng_http_handler nng_http_handler;
int nng_http_handler_alloc(nng_http_handler **hp, const char *path,
void (*func)(nng_aio *);
int nng_http_handler_alloc_directory(nng_http_handler **hp, const char *path,
const char *dirname);
int nng_http_handler_alloc_file(nng_http_handler **hp, const char *path,
const char *filename);
int nng_http_handler_alloc_redirect(nng_http_handler **hp, const char *path,
uint16_t status, const char *location);
int nng_http_handler_alloc_static(nng_http_handler **hp, const char *path,
const void *data, size_t size, const char *content_type);