-
Notifications
You must be signed in to change notification settings - Fork 0
/
libex_http_app.h
executable file
·43 lines (29 loc) · 2.02 KB
/
libex_http_app.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/* -------------------------------------------------------------------------- */
/* (c) ali@balarabe.com [libex_http_app.h] */
/* -------------------------------------------------------------------------- */
#if !defined INCLUDED_LIBEX_HTTP_APP_H
#define INCLUDED_LIBEX_HTTP_APP_H
#include "libex_archive.h"
#include "libex_http_server.h"
#define LX_HTTP_APP_DATA_READER_FN( CALLBACK_FN_PTR_ ) \
lx_new_chars_t (*CALLBACK_FN_PTR_)( lx_chars_t sql_ ) /*#*/
/* -------------------------------------------------------------------------- */
LX_NAMESPACE(lx_c)
/* -------------------------------------------------------------------------- */
/* Initializer: */
LX_PUBLIC void lx_HttpApp_init( /*C*/
lx_archive_t archive_, /*-*/
lx_chars_t site_path_ ); /*-*/
/* -------------------------------------------------------------------------- */
/* Destructor: */
LX_PUBLIC void lx_HttpApp_free( void ); /*D*/
/* -------------------------------------------------------------------------- */
/* Methods: */
LX_PUBLIC void lx_HttpApp_setDataReader( /*M*/
LX_HTTP_APP_DATA_READER_FN(callback_fn_) ); /*-*/
LX_PUBLIC void lx_HttpApp_run( const int listen_on_port_ ); /*M*/
/* -------------------------------------------------------------------------- */
/* Methods: HTTP */
LX_PUBLIC lx_new_bytes_t lx_HttpApp_get( lx_http_request_t* request_ ); /*M*/
LX_END_NAMESPACE /*lx_c*/
#endif /*eof*/