1 #ifndef HEADER_CURL_MULTIIF_H
2 #define HEADER_CURL_MULTIIF_H
3 /***************************************************************************
5 * Project ___| | | | _ \| |
7 * | (__| |_| | _ <| |___
8 * \___|\___/|_| \_\_____|
10 * Copyright (C) 1998 - 2010, Daniel Stenberg, <daniel@haxx.se>, et al.
12 * This software is licensed as described in the file COPYING, which
13 * you should have received as part of this distribution. The terms
14 * are also available at http://curl.haxx.se/docs/copyright.html.
16 * You may opt to use, copy, modify, merge, publish, distribute and/or sell
17 * copies of the Software, and permit persons to whom the Software is
18 * furnished to do so, under the terms of the COPYING file.
20 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
21 * KIND, either express or implied.
23 ***************************************************************************/
26 * Prototypes for library-wide functions provided by multi.c
28 void Curl_expire(struct SessionHandle *data, long milli);
30 bool Curl_multi_pipeline_enabled(const struct Curl_multi* multi);
31 void Curl_multi_handlePipeBreak(struct SessionHandle *data);
33 /* the write bits start at bit 16 for the *getsock() bitmap */
34 #define GETSOCK_WRITEBITSTART 16
36 #define GETSOCK_BLANK 0 /* no bits set */
38 /* set the bit for the given sock number to make the bitmap for writable */
39 #define GETSOCK_WRITESOCK(x) (1 << (GETSOCK_WRITEBITSTART + (x)))
41 /* set the bit for the given sock number to make the bitmap for readable */
42 #define GETSOCK_READSOCK(x) (1 << (x))
46 * Curl_multi_dump is not a stable public function, this is only meant to
47 * allow easier tracking of the internal handle's state and what sockets
48 * they use. Only for research and development DEBUGBUILD enabled builds.
50 void Curl_multi_dump(const struct Curl_multi *multi_handle);
53 /* Update the current connection of a One_Easy handle */
54 void Curl_multi_set_easy_connection(struct SessionHandle *handle,
55 struct connectdata *conn);
57 void Curl_multi_process_pending_handles(struct Curl_multi *multi);
59 /* Return the value of the CURLMOPT_MAX_HOST_CONNECTIONS option */
60 size_t Curl_multi_max_host_connections(struct Curl_multi *multi);
62 /* Return the value of the CURLMOPT_MAX_PIPELINE_LENGTH option */
63 size_t Curl_multi_max_pipeline_length(struct Curl_multi *multi);
65 /* Return the value of the CURLMOPT_CONTENT_LENGTH_PENALTY_SIZE option */
66 curl_off_t Curl_multi_content_length_penalty_size(struct Curl_multi *multi);
68 /* Return the value of the CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE option */
69 curl_off_t Curl_multi_chunk_length_penalty_size(struct Curl_multi *multi);
71 /* Return the value of the CURLMOPT_PIPELINING_SITE_BL option */
72 struct curl_llist *Curl_multi_pipelining_site_bl(struct Curl_multi *multi);
74 /* Return the value of the CURLMOPT_PIPELINING_SERVER_BL option */
75 struct curl_llist *Curl_multi_pipelining_server_bl(struct Curl_multi *multi);
77 /* Return the value of the CURLMOPT_MAX_TOTAL_CONNECTIONS option */
78 size_t Curl_multi_max_total_connections(struct Curl_multi *multi);
80 #endif /* HEADER_CURL_MULTIIF_H */