diff options
author | David Kalnischkies <david@kalnischkies.de> | 2016-05-28 15:40:59 +0200 |
---|---|---|
committer | David Kalnischkies <david@kalnischkies.de> | 2016-06-27 11:57:12 +0200 |
commit | f74d99c6a78caafdc6e32d8cb135683b7154795c (patch) | |
tree | 3056bcf8fa40dd70c65ae073e634aa142ab8e628 /apt-pkg/edsp.h | |
parent | dae197476f1831269d13f4e990276ce25c483842 (diff) |
eipp: provide the internal planer as an external one
Testing the current implementation can benefit from being able to be
feed an EIPP request and produce a fully compliant response. It is also
a great test for EIPP in general.
Diffstat (limited to 'apt-pkg/edsp.h')
-rw-r--r-- | apt-pkg/edsp.h | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/apt-pkg/edsp.h b/apt-pkg/edsp.h index 3e0982a56..271cbb6a8 100644 --- a/apt-pkg/edsp.h +++ b/apt-pkg/edsp.h @@ -236,16 +236,31 @@ namespace EDSP /*{{{*/ bool const autoRemove, OpProgress *Progress = NULL); } /*}}}*/ +class pkgPackageManager; namespace EIPP /*{{{*/ { - APT_HIDDEN bool OrderInstall(char const * const solver, pkgDepCache &Cache, - unsigned int const version, OpProgress * const Progress); APT_HIDDEN bool WriteRequest(pkgDepCache &Cache, FileFd &output, unsigned int const version, OpProgress * const Progress); APT_HIDDEN bool WriteScenario(pkgDepCache &Cache, FileFd &output, OpProgress * const Progress); - APT_HIDDEN bool ReadResponse(int const input, pkgDepCache &Cache, + + APT_HIDDEN bool OrderInstall(char const * const planer, pkgPackageManager * const PM, + unsigned int const version, OpProgress * const Progress); + APT_HIDDEN bool ReadResponse(int const input, pkgPackageManager * const PM, OpProgress * const Progress); + + enum class PKG_ACTION + { + NOOP, + INSTALL, + REINSTALL, + REMOVE + }; + bool ReadRequest(int const input, + std::list<std::pair<std::string,PKG_ACTION>> &actions, + unsigned int &flags); + bool ApplyRequest(std::list<std::pair<std::string,PKG_ACTION>> &actions, + pkgDepCache &Cache); } /*}}}*/ #endif |