Change the project's website to http://noping.cc/ everywhere.
[liboping.git] / src / mans / ping_iterator_get.pod
1 =head1 NAME
2
3 ping_iterator_get, ping_iterator_next - Iterate over all hosts of a liboping object
4
5 =head1 SYNOPSIS
6
7   #include <oping.h>
8
9   pingobj_iter_t *ping_iterator_get (pingobj_t *obj);
10   pingobj_iter_t *ping_iterator_next (pingobj_iter_t *iter)
11
12 =head1 DESCRIPTION
13
14 These two functions can be used to iterate over all hosts associated with a
15 liboping object. You can use these methods as follows:
16
17   pingobj_iter_t *iter;
18
19   for (iter = ping_iterator_get (obj);
20        iter != NULL;
21        iter = ping_iterator_next (iter))
22   {
23     ...;
24   }
25
26 To get usable information from an iterator object (which is also an opaque data
27 type, just like the liboping object itself) use L<ping_iterator_get_info(3)> and
28 L<ping_iterator_get_context(3)>.
29
30 =head1 RETURN VALUE
31
32 The B<ping_iterator_get> returns an iterator for I<obj> or NULL if no host is
33 associated with I<obj>.
34
35 The B<ping_iterator_next> returns an iterator for the host following I<iter> or
36 NULL if the last host has been reached.
37
38 =head1 SEE ALSO
39
40 L<ping_host_add(3)>,
41 L<ping_iterator_get_info(3)>,
42 L<ping_iterator_get_context(3)>,
43 L<liboping(3)>
44
45 =head1 AUTHOR
46
47 liboping is written by Florian "octo" Forster E<lt>ff at octo.itE<gt>.
48 Its homepage can be found at L<http://noping.cc/>.
49
50 Copyright (c) 2005-2011 by Florian "octo" Forster.