diff options
-rw-r--r-- | ept/apt/apt.cc | 7 | ||||
-rw-r--r-- | ept/apt/apt.h | 8 |
2 files changed, 15 insertions, 0 deletions
diff --git a/ept/apt/apt.cc b/ept/apt/apt.cc index 76c34f0..2d625fb 100644 --- a/ept/apt/apt.cc +++ b/ept/apt/apt.cc @@ -633,6 +633,13 @@ std::string Apt::rawRecord(const Version& ver) const return std::string(); } + +const pkgCache* Apt::aptPkgCache() const +{ + return impl->m_cache; +} + + void Apt::checkCacheUpdates() { if (impl->m_open_timestamp < timestamp()) diff --git a/ept/apt/apt.h b/ept/apt/apt.h index 0cfff60..6e6ce74 100644 --- a/ept/apt/apt.h +++ b/ept/apt/apt.h @@ -29,6 +29,8 @@ #include <iterator> +class pkgCache; + namespace ept { namespace apt { @@ -198,6 +200,7 @@ public: Apt(); ~Apt(); + iterator begin() const; iterator end() const; @@ -257,6 +260,11 @@ public: /// Get the raw package record for the given Version std::string rawRecord(const Version& ver) const; + /// Returns the pointer to the internal libapt pkgCache object used. + const pkgCache* aptPkgCache() const; + + + /// Timestamp of when the apt index was last modified time_t timestamp(); |