summaryrefslogtreecommitdiff
path: root/ftparchive/override.h
diff options
context:
space:
mode:
authorArch Librarian <arch@canonical.com>2004-09-20 16:56:32 +0000
committerArch Librarian <arch@canonical.com>2004-09-20 16:56:32 +0000
commitb2e465d6d32d2dc884f58b94acb7e35f671a87fe (patch)
tree5928383b9bde7b0ba9812e6526ad746466e558f7 /ftparchive/override.h
parent00b47c98ca4a4349686a082eba6d77decbb03a4d (diff)
Join with aliencode
Author: jgg Date: 2001-02-20 07:03:16 GMT Join with aliencode
Diffstat (limited to 'ftparchive/override.h')
-rw-r--r--ftparchive/override.h50
1 files changed, 50 insertions, 0 deletions
diff --git a/ftparchive/override.h b/ftparchive/override.h
new file mode 100644
index 000000000..63f123c42
--- /dev/null
+++ b/ftparchive/override.h
@@ -0,0 +1,50 @@
+// -*- mode: cpp; mode: fold -*-
+// Description /*{{{*/
+// $Id: override.h,v 1.2 2001/02/20 07:03:18 jgg Exp $
+/* ######################################################################
+
+ Override
+
+ Store the override file.
+
+ ##################################################################### */
+ /*}}}*/
+#ifndef OVERRIDE_H
+#define OVERRIDE_H
+
+#ifdef __GNUG__
+#pragma interface "override.h"
+#endif
+
+#include <map>
+#include <string>
+
+class Override
+{
+ public:
+
+ struct Item
+ {
+ string Priority;
+ string Section;
+ string OldMaint;
+ string NewMaint;
+
+ string SwapMaint(string Orig,bool &Failed);
+ };
+
+ map<string,Item> Mapping;
+
+ inline Item *GetItem(string Package)
+ {
+ map<string,Item>::iterator I = Mapping.find(Package);
+ if (I == Mapping.end())
+ return 0;
+ return &I->second;
+ };
+
+ bool ReadOverride(string File,bool Source = false);
+};
+
+#endif
+