libcollectdclient: Move the header files to a subdirectory.
[collectd.git] / src / libcollectdclient / collectd / network_buffer.h
1 /**
2  * collectd - src/libcollectdclient/network_buffer.h
3  * Copyright (C) 2010  Florian octo Forster
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms of the GNU Lesser General Public License as published by
7  * the Free Software Foundation; only version 2.1 of the License is
8  * applicable.
9  *
10  * This program is distributed in the hope that it will be useful, but
11  * WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with this program; if not, write to the Free Software Foundation,
17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
18  *
19  * Authors:
20  *   Florian octo Forster <octo at verplant.org>
21  **/
22
23 #ifndef LIBCOLLECTDCLIENT_NETWORK_BUFFER_H
24 #define LIBCOLLECTDCLIENT_NETWORK_BUFFER_H 1
25
26 /* FIXME */
27 #include "client.h"
28 #include "network.h"
29
30 /* Ethernet frame - (IPv6 header + UDP header) */
31 #define LCC_NETWORK_BUFFER_SIZE_DEFAULT 1452
32
33 struct lcc_network_buffer_s;
34 typedef struct lcc_network_buffer_s lcc_network_buffer_t;
35
36 lcc_network_buffer_t *lcc_network_buffer_create (size_t size);
37 void lcc_network_buffer_destroy (lcc_network_buffer_t *nb);
38
39 int lcc_network_buffer_set_security_level (lcc_network_buffer_t *nb,
40     lcc_security_level_t level,
41     const char *user, const char *password);
42
43 int lcc_network_buffer_initialize (lcc_network_buffer_t *nb);
44 int lcc_network_buffer_finalize (lcc_network_buffer_t *nb);
45
46 int lcc_network_buffer_add_value (lcc_network_buffer_t *nb,
47     const lcc_value_list_t *vl);
48
49 int lcc_network_buffer_get (lcc_network_buffer_t *nb,
50     void *buffer, size_t *buffer_size);
51
52 #endif /* LIBCOLLECTDCLIENT_NETWORK_BUFFER_H */
53 /* vim: set sw=2 sts=2 et : */