1get_vector_list(3)                  GETDATA                 get_vector_list(3)
2
3
4

NAME

6       get_vector_list — retrieve a list of vector fields in a dirfile
7

SYNOPSIS

9       #include <getdata.h>
10
11       const char **get_vector_list(DIRFILE *dirfile);
12

DESCRIPTION

14       The  get_vector_list() function queries a dirfile(5) database specified
15       by dirfile and returns a read-only list of names of the all vector type
16       fields defined in the database (i.e.  fields of types BIT, LINCOM, LIN‐
17       TERP, MULTIPLY, PHASE, POLYNOM, RAW, SBIT).  Notably,  this  list  does
18       not include /META subfields.
19
20       The  dirfile  argument  must point to a valid DIRFILE object previously
21       created by a call to dirfile_open(3).
22
23       The array returned will be de-allocated by a call  to  dirfile_close(3)
24       and should not be de-allocated by the caller.  The list returned should
25       not be assumed to be in any particular order.  The array is  terminated
26       by  a NULL pointer.  The number of strings in the array can be obtained
27       from a call to get_nvectors(3).
28
29       The caller may not modify any strings in the array, or  the  array  it‐
30       self.  Doing so may cause database corruption.  The pointer returned is
31       guaranteed to be valid until get_vector_list() is called again  on  the
32       same  DIRFILE  object,  or  until the array is deallocated by a call to
33       dirfile_close(3).
34
35

RETURN VALUE

37       Upon successful completion, get_vector_list() returns a pointer  to  an
38       array  of strings containing the names of all the vector fields defined
39       in the dirfile database.  On error it returns NULL and sets the dirfile
40       error to a non-zero error value.  Possible error values are:
41
42       GD_E_ALLOC
43               The library was unable to allocate memory.
44
45       GD_E_BAD_DIRFILE
46               The supplied dirfile was invalid.
47
48       The dirfile error may be retrieved by calling get_error(3).  A descrip‐
49       tive error string for the last error encountered can be obtained from a
50       call to get_error_string(3).
51

SEE ALSO

53       dirfile(5),    dirfile_open(3),    get_error(3),   get_error_string(3),
54       get_field_list(3), get_mvector_list(3), get_nvectors(3)
55
56
57
58Version 0.6.0                   16 October 2009             get_vector_list(3)
Impressum