Add BIND 9.2.4rc7.
[dragonfly.git] / contrib / bind-9.2.4rc7 / lib / dns / include / dns / rdatalist.h
blobd632201bfa04e8863c4a760d66952bd4ae150720
1 /*
2 * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
3 * Copyright (C) 1999-2001 Internet Software Consortium.
5 * Permission to use, copy, modify, and distribute this software for any
6 * purpose with or without fee is hereby granted, provided that the above
7 * copyright notice and this permission notice appear in all copies.
9 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
10 * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
11 * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
12 * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
13 * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
14 * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
15 * PERFORMANCE OF THIS SOFTWARE.
18 /* $Id: rdatalist.h,v 1.13.2.1 2004/03/09 06:11:20 marka Exp $ */
20 #ifndef DNS_RDATALIST_H
21 #define DNS_RDATALIST_H 1
23 /*****
24 ***** Module Info
25 *****/
28 * DNS Rdatalist
30 * A DNS rdatalist is a list of rdata of a common type and class.
32 * MP:
33 * Clients of this module must impose any required synchronization.
35 * Reliability:
36 * No anticipated impact.
38 * Resources:
39 * <TBS>
41 * Security:
42 * No anticipated impact.
44 * Standards:
45 * None.
48 #include <isc/lang.h>
50 #include <dns/types.h>
53 * Clients may use this type directly.
55 struct dns_rdatalist {
56 dns_rdataclass_t rdclass;
57 dns_rdatatype_t type;
58 dns_rdatatype_t covers;
59 dns_ttl_t ttl;
60 ISC_LIST(dns_rdata_t) rdata;
61 ISC_LINK(dns_rdatalist_t) link;
64 ISC_LANG_BEGINDECLS
66 void
67 dns_rdatalist_init(dns_rdatalist_t *rdatalist);
69 * Initialize rdatalist.
71 * Ensures:
72 * All fields of rdatalist have been initialized to their default
73 * values.
76 isc_result_t
77 dns_rdatalist_tordataset(dns_rdatalist_t *rdatalist,
78 dns_rdataset_t *rdataset);
80 * Make 'rdataset' refer to the rdata in 'rdatalist'.
82 * Note:
83 * The caller must ensure that 'rdatalist' remains valid and unchanged
84 * while 'rdataset' is associated with it.
86 * Requires:
88 * 'rdatalist' is a valid rdatalist.
90 * 'rdataset' is a valid rdataset that is not currently associated with
91 * any rdata.
93 * Ensures:
94 * On success,
96 * 'rdataset' is associated with the rdata in rdatalist.
98 * Returns:
99 * ISC_R_SUCCESS
102 ISC_LANG_ENDDECLS
104 #endif /* DNS_RDATALIST_H */