Imported Upstream version 0.6.15
[platform/upstream/libsolv.git] / src / repodata.h
index bdd4b4a..c18c688 100644 (file)
@@ -7,13 +7,13 @@
 
 /*
  * repodata.h
- * 
+ *
  */
 
 #ifndef LIBSOLV_REPODATA_H
 #define LIBSOLV_REPODATA_H
 
-#include <stdio.h> 
+#include <stdio.h>
 
 #include "pooltypes.h"
 #include "pool.h"
@@ -29,7 +29,10 @@ extern "C" {
 
 #define SIZEOF_MD5     16
 #define SIZEOF_SHA1    20
+#define SIZEOF_SHA224  28
 #define SIZEOF_SHA256  32
+#define SIZEOF_SHA384  48
+#define SIZEOF_SHA512  64
 
 struct _Repo;
 struct _KeyValue;
@@ -195,9 +198,9 @@ repodata_has_keyname(Repodata *data, Id keyname)
  * Call <callback> for each match */
 void repodata_search(Repodata *data, Id solvid, Id keyname, int flags, int (*callback)(void *cbdata, Solvable *s, Repodata *data, Repokey *key, struct _KeyValue *kv), void *cbdata);
 
-/* Make sure the found KeyValue has the "str" field set. Return false
- * if not possible */
-int repodata_stringify(Pool *pool, Repodata *data, Repokey *key, struct _KeyValue *kv, int flags);
+/* Make sure the found KeyValue has the "str" field set. Return "str"
+ * if valid, NULL if not possible */
+const char *repodata_stringify(Pool *pool, Repodata *data, Repokey *key, struct _KeyValue *kv, int flags);
 
 int repodata_filelistfilter_matches(Repodata *data, const char *str);
 
@@ -271,7 +274,7 @@ void repodata_add_flexarray(Repodata *data, Id solvid, Id keyname, Id ghandle);
 void repodata_unset(Repodata *data, Id solvid, Id keyname);
 void repodata_unset_uninternalized(Repodata *data, Id solvid, Id keyname);
 
-/* 
+/*
  merge/swap attributes from one solvable to another
  works only if the data is not yet internalized
 */
@@ -298,6 +301,7 @@ void repodata_set_location(Repodata *data, Id solvid, int medianr, const char *d
 void repodata_set_deltalocation(Repodata *data, Id handle, int medianr, const char *dir, const char *file);
 void repodata_set_sourcepkg(Repodata *data, Id solvid, const char *sourcepkg);
 Id repodata_lookup_id_uninternalized(Repodata *data, Id solvid, Id keyname, Id voidid);
+const char *repodata_lookup_dirstrarray_uninternalized(Repodata *data, Id solvid, Id keyname, Id *didp, Id *iterp);
 
 /* stats */
 unsigned int repodata_memused(Repodata *data);