createrepo_c library  0.15.1
C library for metadata manipulation
updateinfo.h
1 /* createrepo_c - Library of routines for manipulation with repodata
2  * Copyright (C) 2014 Tomas Mlcoch
3  *
4  * This program is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU General Public License
6  * as published by the Free Software Foundation; either version 2
7  * of the License, or (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
17  * USA.
18  */
19 
20 #ifndef __C_CREATEREPOLIB_UPDATEINFO_H__
21 #define __C_CREATEREPOLIB_UPDATEINFO_H__
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 
27 #include <glib.h>
28 #include "checksum.h"
29 
38 typedef struct {
39  gchar *name;
40  gchar *version;
41  gchar *release;
42  gchar *epoch;
43  gchar *arch;
44  gchar *src;
45  gchar *filename;
46  gchar *sum;
47  cr_ChecksumType sum_type;
48  gboolean reboot_suggested;
49 
50  GStringChunk *chunk;
52 
53 typedef struct {
54  gchar *name;
55  gchar *stream;
56  guint64 version;
57  gchar *context;
58  gchar *arch;
59 
60  GStringChunk *chunk;
62 
63 typedef struct {
64  gchar *shortname;
65  gchar *name;
67  GSList *packages;
68  GStringChunk *chunk;
70 
71 typedef struct {
72  gchar *href;
73  gchar *id;
74  gchar *type;
75  gchar *title;
76  GStringChunk *chunk;
78 
79 typedef struct {
80  gchar *from;
81  gchar *status;
82  gchar *type;
83  gchar *version;
84  gchar *id;
85  gchar *title;
86  gchar *issued_date;
87  gchar *updated_date;
88  gchar *rights;
89  gchar *release;
90  gchar *pushcount;
91  gchar *severity;
92  gchar *summary;
93  gchar *description;
94  gchar *solution;
96  GSList *references;
97  GSList *collections;
99  GStringChunk *chunk;
101 
102 typedef struct {
103  GSList *updates;
104 } cr_UpdateInfo;
105 
106 /*
107  * cr_UpdateCollectionPackage
108  */
109 
111 cr_updatecollectionpackage_new(void);
112 
114 cr_updatecollectionpackage_copy(const cr_UpdateCollectionPackage *orig);
115 
116 void
117 cr_updatecollectionpackage_free(cr_UpdateCollectionPackage *pkg);
118 
119 /*
120  * cr_UpdateCollectionModule
121  */
122 
124 cr_updatecollectionmodule_new(void);
125 
127 cr_updatecollectionmodule_copy(const cr_UpdateCollectionModule *orig);
128 
129 void
130 cr_updatecollectionmodule_free(cr_UpdateCollectionModule *pkg);
131 
132 /*
133  * cr_UpdateCollection
134  */
135 
137 cr_updatecollection_new(void);
138 
140 cr_updatecollection_copy(const cr_UpdateCollection *orig);
141 
142 void
143 cr_updatecollection_free(cr_UpdateCollection *collection);
144 
145 void
146 cr_updatecollection_append_package(cr_UpdateCollection *collection,
148 
149 /*
150  * cr_UpdateReference
151  */
152 
154 cr_updatereference_new(void);
155 
157 cr_updatereference_copy(const cr_UpdateReference *orig);
158 
159 void
160 cr_updatereference_free(cr_UpdateReference *ref);
161 
162 /*
163  * cr_UpdateRecord
164  */
165 
167 cr_updaterecord_new(void);
168 
170 cr_updaterecord_copy(const cr_UpdateRecord *orig);
171 
172 void
173 cr_updaterecord_free(cr_UpdateRecord *record);
174 
175 void
176 cr_updaterecord_append_reference(cr_UpdateRecord *record,
177  cr_UpdateReference *ref);
178 
179 void
180 cr_updaterecord_append_collection(cr_UpdateRecord *record,
181  cr_UpdateCollection *collection);
182 
183 /*
184  * cr_Updateinfo
185  */
186 
188 cr_updateinfo_new(void);
189 
190 void
191 cr_updateinfo_free(cr_UpdateInfo *uinfo);
192 
193 void
194 cr_updateinfo_apped_record(cr_UpdateInfo *uinfo, cr_UpdateRecord *record);
195 
198 #ifdef __cplusplus
199 }
200 #endif
201 
202 #endif /* __C_CREATEREPOLIB_UPDATEINFO_H__ */
gchar * from
Definition: updateinfo.h:80
cr_ChecksumType
Definition: checksum.h:43
gchar * pushcount
Definition: updateinfo.h:90
gchar * issued_date
Definition: updateinfo.h:86
GStringChunk * chunk
Definition: updateinfo.h:99
gchar * description
Definition: updateinfo.h:93
gchar * updated_date
Definition: updateinfo.h:87
GSList * references
Definition: updateinfo.h:96
GSList * collections
Definition: updateinfo.h:97
gchar * type
Definition: updateinfo.h:82
gchar * solution
Definition: updateinfo.h:94
gchar * status
Definition: updateinfo.h:81
gchar * version
Definition: updateinfo.h:83
gchar * release
Definition: updateinfo.h:89
gchar * severity
Definition: updateinfo.h:91
gchar * title
Definition: updateinfo.h:85
gchar * summary
Definition: updateinfo.h:92
gchar * rights
Definition: updateinfo.h:88
GSList * updates
Definition: updateinfo.h:103