Home | History | Annotate | Download | only in examples
      1 /*
      2     Copyright Copyright (C) 2013 Andrey Uzunov
      3 
      4     This program is free software: you can redistribute it and/or modify
      5     it under the terms of the GNU General Public License as published by
      6     the Free Software Foundation, either version 3 of the License, or
      7     (at your option) any later version.
      8 
      9     This program is distributed in the hope that it will be useful,
     10     but WITHOUT ANY WARRANTY; without even the implied warranty of
     11     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     12     GNU General Public License for more details.
     13 
     14     You should have received a copy of the GNU General Public License
     15     along with this program.  If not, see <http://www.gnu.org/licenses/>.
     16 */
     17 
     18 /**
     19  * @file mhd2spdy_http.h
     20  * @brief  HTTP part of the proxy. libmicrohttpd is used for the server side.
     21  * @author Andrey Uzunov
     22  */
     23 
     24 #ifndef HTTP_H
     25 #define HTTP_H
     26 
     27 #include "mhd2spdy_structures.h"
     28 
     29 
     30 int
     31 http_cb_request (void *cls,
     32                 struct MHD_Connection *connection,
     33                 const char *url,
     34                 const char *method,
     35                 const char *version,
     36                 const char *upload_data,
     37                 size_t *upload_data_size,
     38                 void **ptr);
     39 
     40 
     41 void * http_cb_log(void * cls, const char * uri);
     42 
     43 
     44 void
     45 http_create_response(struct Proxy* proxy, char **nv);
     46 
     47 
     48 void
     49 http_cb_request_completed (void *cls,
     50                                    struct MHD_Connection *connection,
     51                                    void **con_cls,
     52                                    enum MHD_RequestTerminationCode toe);
     53 
     54 #endif
     55