]>
Commit | Line | Data |
---|---|---|
1 | // -*- mode: cpp; mode: fold -*- | |
2 | // Description /*{{{*/ | |
3 | /* ###################################################################### | |
4 | ||
5 | Upgrade - Upgrade/DistUpgrade releated code | |
6 | ||
7 | ##################################################################### */ | |
8 | /*}}}*/ | |
9 | ||
10 | #ifndef PKGLIB_UPGRADE_H | |
11 | #define PKGLIB_UPGRADE_H | |
12 | ||
13 | #include <stddef.h> | |
14 | #include <apt-pkg/macros.h> | |
15 | ||
16 | class pkgDepCache; | |
17 | class OpProgress; | |
18 | ||
19 | namespace APT { | |
20 | namespace Upgrade { | |
21 | // FIXME: make this "enum class UpgradeMode {" once we enable c++11 | |
22 | enum UpgradeMode { | |
23 | FORBID_REMOVE_PACKAGES = 1, | |
24 | FORBID_INSTALL_NEW_PACKAGES = 2, | |
25 | ALLOW_EVERYTHING = 0 | |
26 | }; | |
27 | #if APT_PKG_ABI >= 413 | |
28 | bool Upgrade(pkgDepCache &Cache, int UpgradeMode, OpProgress * const Progress = NULL); | |
29 | #else | |
30 | bool Upgrade(pkgDepCache &Cache, int UpgradeMode); | |
31 | bool Upgrade(pkgDepCache &Cache, int UpgradeMode, OpProgress * const Progress); | |
32 | #endif | |
33 | } | |
34 | } | |
35 | ||
36 | // please use APT::Upgrade::Upgrade() instead | |
37 | APT_DEPRECATED bool pkgDistUpgrade(pkgDepCache &Cache); | |
38 | APT_DEPRECATED bool pkgAllUpgrade(pkgDepCache &Cache); | |
39 | ||
40 | bool pkgMinimizeUpgrade(pkgDepCache &Cache); | |
41 | #endif |