1
0
Fork 0
apt/ftparchive/override.h
Daniel Baumann 6810ba718b
Adding upstream version 3.0.2.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-20 21:10:43 +02:00

48 lines
994 B
C++

// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
/* ######################################################################
Override
Store the override file.
##################################################################### */
/*}}}*/
#ifndef OVERRIDE_H
#define OVERRIDE_H
#include <map>
#include <string>
using std::string;
using std::map;
class Override
{
public:
struct Item
{
string Priority;
string OldMaint;
string NewMaint;
map<string,string> FieldOverride;
string SwapMaint(std::string_view Orig,bool &Failed);
~Item() {};
};
map<string,Item,std::less<>> Mapping;
inline Item *GetItem(std::string_view Package)
{
return GetItem(Package, "");
}
Item *GetItem(std::string_view Package, std::string_view Architecture);
bool ReadOverride(string const &File,bool const &Source = false);
bool ReadExtraOverride(string const &File,bool const &Source = false);
};
#endif