FreeSWITCH API Documentation  1.7.0
switch_curl.h
Go to the documentation of this file.
1 /*
2  * FreeSWITCH Modular Media Switching Software Library / Soft-Switch Application
3  * Copyright (C) 2005-2014, Anthony Minessale II <anthm@freeswitch.org>
4  *
5  * Version: MPL 1.1
6  *
7  * The contents of this file are subject to the Mozilla Public License Version
8  * 1.1 (the "License"); you may not use this file except in compliance with
9  * the License. You may obtain a copy of the License at
10  * http://www.mozilla.org/MPL/
11  *
12  * Software distributed under the License is distributed on an "AS IS" basis,
13  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
14  * for the specific language governing rights and limitations under the
15  * License.
16  *
17  * The Original Code is FreeSWITCH Modular Media Switching Software Library / Soft-Switch Application
18  *
19  * The Initial Developer of the Original Code is
20  * Anthony Minessale II <anthm@freeswitch.org>
21  * Portions created by the Initial Developer are Copyright (C)
22  * the Initial Developer. All Rights Reserved.
23  *
24  * Contributor(s):
25  *
26  *
27  * switch_curl.h
28  *
29  */
30 
31 #ifndef __SWITCH_CURL_H
32 #define __SWITCH_CURL_H
33 #include <curl/curl.h>
34 
36 
37 typedef void switch_CURL;
38 typedef struct curl_slist switch_curl_slist_t;
39 typedef int switch_CURLINFO;
40 typedef int switch_CURLcode;
41 typedef int switch_CURLoption;
42 
53 SWITCH_DECLARE(switch_status_t) switch_curl_process_form_post_params(switch_event_t *event, switch_CURL *curl_handle, struct curl_httppost **formpostp);
54 #define switch_curl_easy_setopt curl_easy_setopt
55 
57 
58 #endif
59 
60 
61 /* For Emacs:
62  * Local Variables:
63  * mode:c
64  * indent-tabs-mode:t
65  * tab-width:4
66  * c-basic-offset:4
67  * End:
68  * For VIM:
69  * vim:set softtabstop=4 shiftwidth=4 tabstop=4 noet:
70  */
71 
#define SWITCH_END_EXTERN_C
Definition: switch.h:43
int switch_CURLoption
Definition: switch_curl.h:41
switch_CURLcode switch_curl_easy_getinfo(switch_CURL *curl, switch_CURLINFO info,...)
Definition: switch_curl.c:16
Representation of an event.
Definition: switch_event.h:80
switch_CURL * switch_curl_easy_init(void)
Definition: switch_curl.c:5
switch_CURLcode switch_curl_easy_perform(switch_CURL *handle)
Definition: switch_curl.c:10
switch_status_t switch_curl_process_form_post_params(switch_event_t *event, switch_CURL *curl_handle, struct curl_httppost **formpostp)
Definition: switch_curl.c:61
void switch_curl_destroy(void)
Definition: switch_curl.c:56
void switch_curl_easy_cleanup(switch_CURL *handle)
Definition: switch_curl.c:28
switch_curl_slist_t * switch_curl_slist_append(switch_curl_slist_t *list, const char *string)
Definition: switch_curl.c:35
SWITCH_BEGIN_EXTERN_C typedef void switch_CURL
Definition: switch_curl.h:37
int switch_CURLcode
Definition: switch_curl.h:40
struct curl_slist switch_curl_slist_t
Definition: switch_curl.h:38
switch_status_t
Common return values.
#define SWITCH_DECLARE(type)
const char * switch_curl_easy_strerror(switch_CURLcode errornum)
Definition: switch_curl.c:46
#define switch_curl_easy_setopt
Definition: switch_curl.h:54
void switch_curl_init(void)
Definition: switch_curl.c:51
void switch_curl_slist_free_all(switch_curl_slist_t *list)
Definition: switch_curl.c:41
int switch_CURLINFO
Definition: switch_curl.h:39
#define SWITCH_BEGIN_EXTERN_C
Definition: switch.h:42