summaryrefslogtreecommitdiff
path: root/src/poolid.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/poolid.h')
-rw-r--r--src/poolid.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/poolid.h b/src/poolid.h
new file mode 100644
index 0000000..087d113
--- /dev/null
+++ b/src/poolid.h
@@ -0,0 +1,31 @@
+/*
+ * poolid.h
+ *
+ */
+
+#ifndef POOLID_H
+#define POOLID_H
+
+#include "pooltypes.h"
+#include "hash.h"
+
+//-----------------------------------------------
+// Id's with relation
+
+typedef struct _Reldep {
+ Id name; // "package"
+ Id evr; // "0:42-3"
+ int flags; // operation/relation, see REL_x below
+} Reldep;
+
+extern Id str2id(Pool *pool, const char *, int);
+extern Id rel2id(Pool *pool, Id, Id, int, int);
+extern const char *id2str(Pool *pool, Id);
+extern const char *id2rel(Pool *pool, Id);
+extern const char *id2evr(Pool *pool, Id);
+
+extern void pool_shrink_strings(Pool *pool);
+extern void pool_shrink_rels(Pool *pool);
+extern void pool_freeidhashes(Pool *pool);
+
+#endif /* POOLID_H */