faa17feb191366b83f5716cb17cf907d11026398
[egate.git] / include / iso2709.h
1 /*
2  * Record management
3  *
4  * Europagate, 1994-1995.
5  *
6  * $Log: iso2709.h,v $
7  * Revision 1.9  1995/03/29 11:44:25  adam
8  * New functions: iso2709_a_.. for record manipulation.
9  *
10  * Revision 1.8  1995/03/28  16:06:42  adam
11  * New function: iso2709_out.
12  *
13  * Revision 1.7  1995/03/27  12:50:40  adam
14  * New level: GW_LOG_ERRNO.
15  *
16  * Revision 1.6  1995/03/08  12:36:35  adam
17  * New function: dbc2709_cvt.
18  *
19  * Revision 1.5  1995/02/23  08:32:12  adam
20  * Changed header.
21  *
22  * Revision 1.3  1995/02/10  17:05:14  adam
23  * New function iso2709_display to display MARC records in a
24  * line-by-line format. The iso2709_cvt function no longer
25  * prints the record to stderr.
26  *
27  * Revision 1.2  1995/02/10  16:50:25  adam
28  * Indicator field moved to 'struct iso2709_dir' from 'struct
29  * iso2709_field'.
30  * Function iso2709_rm implemented - to delete a MARC record.
31  *
32  * Revision 1.1.1.1  1995/02/09  17:27:12  adam
33  * Initial version of email gateway under CVS control.
34  *
35  */
36
37 #ifndef ISO2709_H
38 #define ISO2709_H
39
40 typedef struct iso2709_rec *Iso2709Rec;
41 typedef struct iso2709_anchor *Iso2709Anchor;
42
43 char *iso2709_read (FILE *inf);
44 Iso2709Rec iso2709_cvt (const char *buf);
45 void iso2709_rm (Iso2709Rec rec);
46 void iso2709_display (Iso2709Rec rec, FILE *out);
47 int iso2709_out (Iso2709Rec p, char **buf, int size);
48
49 Iso2709Anchor iso2709_a_mk (Iso2709Rec rec);
50 void iso2709_a_rm (Iso2709Anchor anchor);
51 int iso2709_a_first (Iso2709Anchor anchor);
52 int iso2709_a_next_line (Iso2709Anchor anchor);
53 int iso2709_a_next_field (Iso2709Anchor anchor);
54 int iso2709_a_next (Iso2709Anchor anchor);
55 int iso2709_a_info_field (Iso2709Anchor anchor,
56                     char **tag, char **indicator,
57                     char **identifier, char **data);
58 int iso2709_a_info_line (Iso2709Anchor anchor,
59                     char **tag, char **indicator);
60 int iso2709_a_delete_field (Iso2709Anchor anchor);
61 int iso2709_a_delete_line (Iso2709Anchor anchor);
62 int iso2709_a_insert (Iso2709Anchor anchor, 
63                       const char *tag, const char *indicator,
64                       const char *identifier, const char *data);
65 int iso2709_a_search (Iso2709Anchor anchor,
66                       const char *tag_p, const char *indicator_p,
67                       const char *identifier_p);
68 #endif
69