diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2010-06-04 14:43:03 +0200 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2010-06-04 14:43:03 +0200 |
commit | 2e5f4e45f593535e2c88181ff7a9e2d32a5e60f9 (patch) | |
tree | 184314cc04e793b2a00b854078174c4a7b174f70 /apt-pkg/cachefile.h | |
parent | d4489d4983d5b9840bb2882a088dd1f363a280b9 (diff) | |
download | apt-2e5f4e45f593535e2c88181ff7a9e2d32a5e60f9.tar.gz |
* apt-pkg/cachefile.{cc,h}:
- split Open() into submethods to be able to build only parts
- make the OpProgress optional in the Cache buildprocess
Diffstat (limited to 'apt-pkg/cachefile.h')
-rw-r--r-- | apt-pkg/cachefile.h | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/apt-pkg/cachefile.h b/apt-pkg/cachefile.h index 3b057951c..b75a7dbe4 100644 --- a/apt-pkg/cachefile.h +++ b/apt-pkg/cachefile.h @@ -30,11 +30,10 @@ class pkgCacheFile MMap *Map; pkgCache *Cache; pkgDepCache *DCache; - + pkgPolicy *Policy; + public: - pkgPolicy *Policy; - // We look pretty much exactly like a pointer to a dep cache inline operator pkgCache &() {return *Cache;}; inline operator pkgCache *() {return Cache;}; @@ -45,12 +44,16 @@ class pkgCacheFile inline pkgDepCache::StateCache &operator [](pkgCache::PkgIterator const &I) {return (*DCache)[I];}; inline unsigned char &operator [](pkgCache::DepIterator const &I) {return (*DCache)[I];}; - bool BuildCaches(OpProgress &Progress,bool WithLock = true); - bool Open(OpProgress &Progress,bool WithLock = true); + bool BuildCaches(OpProgress *Progress = NULL,bool WithLock = true); + __deprecated bool BuildCaches(OpProgress &Progress,bool const &WithLock = true) { return BuildCaches(&Progress, WithLock); }; + bool BuildPolicy(OpProgress *Progress = NULL); + bool BuildDepCache(OpProgress *Progress = NULL); + bool Open(OpProgress *Progress = NULL, bool WithLock = true); + __deprecated bool Open(OpProgress &Progress,bool const &WithLock = true) { return Open(&Progress, WithLock); }; void Close(); pkgCacheFile(); - ~pkgCacheFile(); + virtual ~pkgCacheFile(); }; #endif |