Pull class BPackageInfoSet out of BRepositoryCache

This commit is contained in:
Ingo Weinhold
2011-07-17 16:55:21 +02:00
parent f195cdc8c0
commit db9a50a2c6
7 changed files with 326 additions and 204 deletions
+3 -29
View File
@@ -9,18 +9,16 @@
#include <Entry.h>
#include <String.h>
#include <package/PackageInfoSet.h>
#include <package/RepositoryInfo.h>
namespace BPackageKit {
class BPackageInfo;
class BRepositoryCache {
public:
class Iterator;
typedef BPackageInfoSet::Iterator Iterator;
public:
BRepositoryCache();
@@ -38,39 +36,15 @@ public:
Iterator GetIterator() const;
private:
struct PackageInfo;
struct PackageInfoHashDefinition;
struct PackageMap;
struct RepositoryContentHandler;
struct StandardErrorOutput;
friend class Iterator;
private:
BEntry fEntry;
BRepositoryInfo fInfo;
bool fIsUserSpecific;
PackageMap* fPackageMap;
};
class BRepositoryCache::Iterator {
public:
Iterator();
bool HasNext() const;
const BPackageInfo* Next();
private:
Iterator(const BRepositoryCache* cache);
private:
friend class BRepositoryCache;
private:
const BRepositoryCache* fCache;
PackageInfo* fNextInfo;
BPackageInfoSet fPackages;
};