1ldns(3)                    Library Functions Manual                    ldns(3)
2
3
4

NAME

6       ldns_buffer
7
8

SYNOPSIS

10       #include <stdint.h>
11       #include <stdbool.h>
12
13       #include <ldns/ldns.h>
14

DESCRIPTION

16       ldns_buffer
17              implementation of buffers to ease operations
18
19              ldns_buffers  can  contain arbitrary information, per octet. You
20              can write
21              to the current end of a buffer, read from the current  position,
22              and
23              access any data within it.
24
25              Example use of buffers is in the source code of \ref host2str.c
26              struct ldns_struct_buffer
27              {
28                   The current position used for reading/writing:
29                   size_t   _position;
30
31                   The read/write limit:
32                   size_t   _limit;
33
34                   The amount of data the buffer can contain:
35                   size_t   _capacity;
36
37                   The data contained in the buffer:
38                   uint8_t *_data;
39
40                   If the buffer is fixed it cannot be resized:
41                   unsigned _fixed : 1;
42
43                   /** The current state of the buffer. If writing to the buf‐
44              fer fails
45                    * for any reason, this value is changed. This way, you can
46              perform
47                    * multiple writes in sequence and check for success after‐
48              wards. */
49                   ldns_status _status;
50              };
51              typedef struct ldns_struct_buffer ldns_buffer;
52

AUTHOR

54       The ldns team at NLnet Labs. Which consists out  of  Jelte  Jansen  and
55       Miek Gieben.
56
57

REPORTING BUGS

59       Please  report  bugs  to  ldns-team@nlnetlabs.nl  or in our bugzilla at
60       http://www.nlnetlabs.nl/bugs/index.html
61
62
64       Copyright (c) 2004 - 2006 NLnet Labs.
65
66       Licensed under the BSD License. There is NO warranty; not even for MER‐
67       CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
68
69

SEE ALSO

71       ldns_buffer_new, ldns_buffer_new_frm_data, ldns_buffer_clear, ldns_buf‐
72       fer_printf,  ldns_buffer_free,  ldns_buffer_export,   ldns_buffer_flip,
73       ldns_buffer_rewind,   ldns_buffer_position,   ldns_buffer_set_position,
74       ldns_buffer_skip, ldns_buffer_limit,  ldns_buffer_set_limit,  ldns_buf‐
75       fer_capacity,  ldns_buffer_set_capacity, ldns_buffer_reserve, ldns_buf‐
76       fer_at,   ldns_buffer_begin,   ldns_buffer_end,    ldns_buffer_current,
77       ldns_buffer_remaining_at,   ldns_buffer_remaining,   ldns_buffer_avail‐
78       able_at,  ldns_buffer_available,  ldns_buffer_status,  ldns_buffer_sta‐
79       tus_ok,  ldns_buffer_write_at, ldns_buffer_write_at, ldns_buffer_write,
80       ldns_buffer_write_string_at,    ldns_buffer_write_string,     ldns_buf‐
81       fer_write_u8_at,     ldns_buffer_write_u8,    ldns_buffer_write_u16_at,
82       ldns_buffer_write_u16, ldns_buffer_read_at, ldns_buffer_read, ldns_buf‐
83       fer_read_u8_at, ldns_buffer_read_u8, ldns_buffer_read_u16_at, ldns_buf‐
84       fer_read_u16, ldns_buffer_read_u32_at, ldns_buffer_read_u32.  And perl‐
85       doc Net::DNS, RFC1034, RFC1035, RFC4033, RFC4034  and RFC4035.
86

REMARKS

88       This manpage was automaticly generated from the ldns source code by use
89       of Doxygen and some perl.
90
91
92
93                                  30 May 2006                          ldns(3)
Impressum