// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: packagemanager.h,v 1.14 2001/05/07 04:24:08 jgg Exp $
/* ######################################################################
Package Manager - Abstacts the package manager
virtual bool Install(PkgIterator /*Pkg*/,std::string /*File*/) {return false;};
virtual bool Configure(PkgIterator /*Pkg*/) {return false;};
virtual bool Remove(PkgIterator /*Pkg*/,bool /*Purge*/=false) {return false;};
-#if APT_PKG_ABI >= 413
virtual bool Go(APT::Progress::PackageManager * /*progress*/) {return true;};
-#endif
virtual bool Go(int /*statusFd*/=-1) {return true;};
virtual void Reset() {};
pkgRecords *Recs);
// Do the installation
-#if APT_PKG_ABI >= 413
OrderResult DoInstall(APT::Progress::PackageManager *progress);
// compat
APT_DEPRECATED OrderResult DoInstall(int statusFd=-1);
-#else
- OrderResult DoInstall(int statusFd=-1);
-#endif
// stuff that needs to be done before the fork() of a library that
// uses apt
Res = OrderInstall();
return Res;
};
-#if APT_PKG_ABI >= 413
// stuff that needs to be done after the fork
OrderResult DoInstallPostFork(APT::Progress::PackageManager *progress);
// compat
APT_DEPRECATED OrderResult DoInstallPostFork(int statusFd=-1);
-#else
- OrderResult DoInstallPostFork(int statusFd=-1);
-#endif
// ?
bool FixMissing();
/** \brief returns all packages dpkg let disappear */
inline std::set<std::string> GetDisappearedPackages() { return disappearedPkgs; };
- pkgPackageManager(pkgDepCache *Cache);
+ explicit pkgPackageManager(pkgDepCache *Cache);
virtual ~pkgPackageManager();
private:
+ void * const d;
enum APT_HIDDEN SmartAction { UNPACK_IMMEDIATE, UNPACK, CONFIGURE };
APT_HIDDEN bool NonLoopingSmart(SmartAction const action, pkgCache::PkgIterator &Pkg,
pkgCache::PkgIterator DepPkg, int const Depth, bool const PkgLoop,