createrepo_c library
0.19.0
C library for metadata manipulation
locate_metadata.h
1
/* createrepo_c - Library of routines for manipulation with repodata
2
* Copyright (C) 2012 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_LOCATE_METADATA_H__
21
#define __C_CREATEREPOLIB_LOCATE_METADATA_H__
22
23
#include <glib.h>
24
#include "repomd.h"
25
26
#ifdef __cplusplus
27
extern
"C"
{
28
#endif
29
37
struct
cr_MetadataLocation
{
38
char
*
pri_xml_href
;
39
char
*
fil_xml_href
;
40
char
*
oth_xml_href
;
41
char
*
pri_sqlite_href
;
42
char
*
fil_sqlite_href
;
43
char
*
oth_sqlite_href
;
44
GSList *
additional_metadata
;
47
char
*
repomd
;
48
char
*
original_url
;
50
char
*
local_path
;
51
int
tmp
;
54
cr_Repomd
*
repomd_data
;
55
};
56
61
typedef
struct
{
62
gchar *name;
63
gchar *type;
64
}
cr_Metadatum
;
65
66
struct
cr_MetadataLocation
*
67
cr_parse_repomd(
const
char
*repomd_path,
const
char
*repopath,
int
ignore_sqlite);
68
78
GSList*
79
cr_insert_additional_metadatum
(
const
gchar *path,
80
const
gchar *type,
81
GSList *
additional_metadata
);
82
91
gint
cr_cmp_metadatum_type
(gconstpointer metadatum, gconstpointer type);
92
101
gint
cr_cmp_repomd_record_type
(gconstpointer repomd_record, gconstpointer type);
102
112
struct
cr_MetadataLocation
*
cr_locate_metadata
(
const
char
*repopath,
113
gboolean ignore_sqlite,
114
GError **err);
115
120
void
cr_metadatalocation_free
(
struct
cr_MetadataLocation
*ml);
121
125
void
cr_metadatum_free
(
cr_Metadatum
*m);
126
138
gchar*
cr_copy_metadatum
(
const
gchar *src,
const
gchar *tmp_out_repo, GError **err);
139
142
#ifdef __cplusplus
143
}
144
#endif
145
146
#endif
/* __C_CREATEREPOLIB_LOCATE_METADATA_H__ */
cr_insert_additional_metadatum
GSList * cr_insert_additional_metadatum(const gchar *path, const gchar *type, GSList *additional_metadata)
cr_metadatum_free
void cr_metadatum_free(cr_Metadatum *m)
cr_copy_metadatum
gchar * cr_copy_metadatum(const gchar *src, const gchar *tmp_out_repo, GError **err)
cr_cmp_repomd_record_type
gint cr_cmp_repomd_record_type(gconstpointer repomd_record, gconstpointer type)
cr_locate_metadata
struct cr_MetadataLocation * cr_locate_metadata(const char *repopath, gboolean ignore_sqlite, GError **err)
cr_cmp_metadatum_type
gint cr_cmp_metadatum_type(gconstpointer metadatum, gconstpointer type)
cr_metadatalocation_free
void cr_metadatalocation_free(struct cr_MetadataLocation *ml)
cr_MetadataLocation
Definition:
locate_metadata.h:37
cr_MetadataLocation::oth_sqlite_href
char * oth_sqlite_href
Definition:
locate_metadata.h:43
cr_MetadataLocation::pri_xml_href
char * pri_xml_href
Definition:
locate_metadata.h:38
cr_MetadataLocation::additional_metadata
GSList * additional_metadata
Definition:
locate_metadata.h:44
cr_MetadataLocation::original_url
char * original_url
Definition:
locate_metadata.h:48
cr_MetadataLocation::tmp
int tmp
Definition:
locate_metadata.h:51
cr_MetadataLocation::repomd
char * repomd
Definition:
locate_metadata.h:47
cr_MetadataLocation::fil_sqlite_href
char * fil_sqlite_href
Definition:
locate_metadata.h:42
cr_MetadataLocation::fil_xml_href
char * fil_xml_href
Definition:
locate_metadata.h:39
cr_MetadataLocation::local_path
char * local_path
Definition:
locate_metadata.h:50
cr_MetadataLocation::repomd_data
cr_Repomd * repomd_data
Definition:
locate_metadata.h:54
cr_MetadataLocation::pri_sqlite_href
char * pri_sqlite_href
Definition:
locate_metadata.h:41
cr_MetadataLocation::oth_xml_href
char * oth_xml_href
Definition:
locate_metadata.h:40
cr_Metadatum
Definition:
locate_metadata.h:61
cr_Repomd
Definition:
repomd.h:103
src
locate_metadata.h
Generated by
1.9.1