X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/c8a4ce6cbed57ae108dc955d4a850f9b129a0693..0741daeb7ab870b4dd62a93fa12a1cf6330f9a72:/apt-pkg/policy.h diff --git a/apt-pkg/policy.h b/apt-pkg/policy.h index c4b1cbadd..58b062a7b 100644 --- a/apt-pkg/policy.h +++ b/apt-pkg/policy.h @@ -59,10 +59,11 @@ class pkgPolicy : public pkgDepCache::Policy struct PkgPin : Pin { std::string Pkg; - PkgPin(std::string const &Pkg) : Pin(), Pkg(Pkg) {}; + explicit PkgPin(std::string const &Pkg) : Pin(), Pkg(Pkg) {}; }; Pin *Pins; + Pin *VerPins; signed short *PFPriority; std::vector Defaults; std::vector Unmatched; @@ -79,14 +80,16 @@ class pkgPolicy : public pkgDepCache::Policy // Things for the cache interface. virtual pkgCache::VerIterator GetCandidateVer(pkgCache::PkgIterator const &Pkg); virtual signed short GetPriority(pkgCache::PkgIterator const &Pkg); + virtual signed short GetPriority(pkgCache::VerIterator const &Pkg); virtual signed short GetPriority(pkgCache::PkgFileIterator const &File); bool InitDefaults(); - pkgPolicy(pkgCache *Owner); + explicit pkgPolicy(pkgCache *Owner); virtual ~pkgPolicy(); private: - void *d; + APT_HIDDEN pkgCache::VerIterator GetCandidateVerNew(pkgCache::PkgIterator const &Pkg); + void * const d; }; bool ReadPinFile(pkgPolicy &Plcy, std::string File = "");