Debian Codegraph @

lib/grn_http_client.h

raw symbols SCIP
1 /*
2 Copyright (C) 2025 Sutou Kouhei <[email protected]>
3
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Lesser General Public
6 License as published by the Free Software Foundation; either
7 version 2.1 of the License, or (at your option) any later version.
8
9 This library 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 GNU
12 Lesser General Public License for more details.
13
14 You should have received a copy of the GNU Lesser General Public
15 License along with this library; if not, write to the Free Software
16 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 */
18
19 #pragma once
20
21 #include "grn.h"
22
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26
27 typedef struct _grn_http_client grn_http_client;
28
29 grn_http_client *
30 grn_http_client_open(grn_ctx *ctx);
31 grn_rc
32 grn_http_client_close(grn_ctx *ctx, grn_http_client *http_client);
33 grn_rc
34 grn_http_client_set_user_agent(grn_ctx *ctx,
35 grn_http_client *client,
36 const char *user_agent);
37 grn_rc
38 grn_http_client_set_url(grn_ctx *ctx,
39 grn_http_client *client,
40 const char *url);
41 grn_rc
42 grn_http_client_add_header(grn_ctx *ctx,
43 grn_http_client *client,
44 const char *header);
45 grn_rc
46 grn_http_client_set_output_path(grn_ctx *ctx,
47 grn_http_client *client,
48 const char *path);
49 grn_rc
50 grn_http_client_download(grn_ctx *ctx,
51 grn_http_client *http_client);
52 grn_obj *
53 grn_http_client_get_output(grn_ctx *ctx,
54 grn_http_client *http_client);
55
56 #ifdef __cplusplus
57 }
58 #endif