createrepo_c library 1.0.4
C library for metadata manipulation
|
Data Structures | |
struct | cr_MetadataLocation |
struct | cr_Metadatum |
Functions | |
struct cr_MetadataLocation * | cr_parse_repomd (const char *repomd_path, const char *repopath, int ignore_sqlite) |
GSList * | cr_insert_additional_metadatum (const gchar *path, const gchar *type, GSList *additional_metadata) |
gint | cr_cmp_metadatum_type (gconstpointer metadatum, gconstpointer type) |
gint | cr_cmp_repomd_record_type (gconstpointer repomd_record, gconstpointer type) |
struct cr_MetadataLocation * | cr_locate_metadata (const char *repopath, gboolean ignore_sqlite, GError **err) |
void | cr_metadatalocation_free (struct cr_MetadataLocation *ml) |
void | cr_metadatum_free (cr_Metadatum *m) |
gchar * | cr_copy_metadatum (const gchar *src, const gchar *tmp_out_repo, GError **err) |
gint cr_cmp_metadatum_type | ( | gconstpointer | metadatum, |
gconstpointer | type | ||
) |
Compares type (string) of specified metadatum with second parameter string (type)
metadatum | Cmp type of this metadatum |
type | String value |
gint cr_cmp_repomd_record_type | ( | gconstpointer | repomd_record, |
gconstpointer | type | ||
) |
Compares type (string) of specified cr_RepomdRecord with second parameter string (type)
cr_RepomdRecord | Cmp type of this cr_RepomdRecord |
type | String value |
gchar * cr_copy_metadatum | ( | const gchar * | src, |
const gchar * | tmp_out_repo, | ||
GError ** | err | ||
) |
Copies metadata files, exactly, even hashed name It first constructs target path (location + name), Then it copies file to that location
Metadatum as in singular of metadata, it is eg. groupfile, updateinfo..
src | From where are we copying |
tmp_out_repo | Copying destination dir |
err | GError ** |
GSList * cr_insert_additional_metadatum | ( | const gchar * | path, |
const gchar * | type, | ||
GSList * | additional_metadata | ||
) |
Inserts additional metadatum to list of additional metadata if this type is already present it gets overridden
path | Path to metadatum |
type | Type of metadatum |
additional_metadata | List of additional metadata |
struct cr_MetadataLocation * cr_locate_metadata | ( | const char * | repopath, |
gboolean | ignore_sqlite, | ||
GError ** | err | ||
) |
Parses repomd.xml and returns a filled cr_MetadataLocation structure. Remote repodata (repopath with prefix "ftp://" or "http://") are dowloaded into a temporary directory and removed when the cr_metadatalocation_free() is called on the cr_MetadataLocation.
repopath | path to directory with repodata/ subdirectory |
ignore_sqlite | if ignore_sqlite != 0 sqlite dbs are ignored |
err | GError ** |
void cr_metadatalocation_free | ( | struct cr_MetadataLocation * | ml | ) |
Free cr_MetadataLocation. If repodata were downloaded remove a temporary directory with repodata.
ml | MeatadaLocation |
void cr_metadatum_free | ( | cr_Metadatum * | m | ) |
Free cr_Metadatum.
m | Meatadatum |