DragonFly On-Line Manual Pages
DNSTABLE_READER(3) DNSTABLE_READER(3)
NAME
dnstable_reader - read dnstable data from an mtbl source
SYNOPSIS
#include <dnstable.h>
struct dnstable_reader *
dnstable_reader_init(const struct mtbl_source *s);
struct dnstable_reader *
dnstable_reader_init_setfile(const char *setfile);
void
dnstable_reader_reload_setfile(struct dnstable_reader *r);
void
dnstable_reader_destroy(struct dnstable_reader **r);
struct dnstable_iter *
dnstable_reader_iter(struct dnstable_reader *r);
struct dnstable_iter *
dnstable_reader_iter_rrset(struct dnstable_reader *r);
struct dnstable_iter *
dnstable_reader_iter_rdata(struct dnstable_reader *r);
struct dnstable_iter *
dnstable_reader_query(struct dnstable_reader *r, struct dnstable_query *q);
DESCRIPTION
dnstable_reader is the high-level interface for reading dnstable
entries from a dnstable data source. Results are returned through the
dnstable_iter interface.
dnstable_reader objects can be initialized by calling
dnstable_reader_init(), which takes an mtbl_source object, or by
calling dnstable_reader_init_setfile(), which takes the path to a
"setfile", which is a text file containing a list of dnstable data file
paths, one per line.
dnstable_reader_reload_setfile() will force a reload of a
dnstable_reader object initialized by dnstable_reader_init_setfile() by
re-reading the underlying setfile.
dnstable_reader_iter() iterates over every entry object in the data
source.
dnstable_reader_iter_rrset() iterates over just the entries of type
DNSTABLE_ENTRY_TYPE_RRSET. Likewise, dnstable_reader_iter_rdata()
iterates over just the entries of type DNSTABLE_ENTRY_TYPE_RDATA.
dnstable_reader_query() iterates over all the entry objects that match
the specified query object.
SEE ALSO
dnstable_iter(3), dnstable_query(3), mtbl_source(3)
11/10/2015 DNSTABLE_READER(3)