summaryrefslogtreecommitdiff
path: root/apt-pkg/metaindex.h
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2015-06-23 12:17:35 +0100
committerMichael Vogt <mvo@debian.org>2015-06-23 12:17:35 +0100
commit245dde96193702f7f51389d3583dee547f8ba366 (patch)
tree6cf8c191641c760bcc6a6c08fb0ff65d27e0cffd /apt-pkg/metaindex.h
parent5530255b5f3ad7de2e23dfcb39ce325001126501 (diff)
parentc8a4ce6cbed57ae108dc955d4a850f9b129a0693 (diff)
Merge remote-tracking branch 'donkult/debian/experimental' into debian/experimental
Diffstat (limited to 'apt-pkg/metaindex.h')
-rw-r--r--apt-pkg/metaindex.h34
1 files changed, 14 insertions, 20 deletions
diff --git a/apt-pkg/metaindex.h b/apt-pkg/metaindex.h
index 7c4d0c1aa..760c7dd15 100644
--- a/apt-pkg/metaindex.h
+++ b/apt-pkg/metaindex.h
@@ -22,9 +22,13 @@ using std::string;
#endif
class pkgAcquire;
+class IndexTarget;
+class pkgCacheGenerator;
+class OpProgress;
class metaIndex
{
+ void *d;
protected:
std::vector <pkgIndexFile *> *Indexes;
const char *Type;
@@ -40,33 +44,23 @@ class metaIndex
virtual const char* GetType() const {return Type;}
// interface to to query it
-#if (APT_PKG_MAJOR >= 4 && APT_PKG_MINOR >= 13)
- // returns the path of the local file (or "" if its not available)
- virtual std::string LocalFileName() const {return "";};
-#endif
+ /** \return the path of the local file (or "" if its not available) */
+ virtual std::string LocalFileName() const;
// Interface for acquire
virtual std::string ArchiveURI(std::string const& File) const = 0;
virtual bool GetIndexes(pkgAcquire *Owner, bool const &GetAll=false) const = 0;
- virtual std::vector<pkgIndexFile *> *GetIndexFiles() = 0;
+ virtual std::vector<IndexTarget> GetIndexTargets() const = 0;
+ virtual std::vector<pkgIndexFile *> *GetIndexFiles() = 0;
virtual bool IsTrusted() const = 0;
- metaIndex(std::string const &URI, std::string const &Dist,
- char const * const Type)
- : Indexes(NULL), Type(Type), URI(URI), Dist(Dist), Trusted(false)
- {
- /* nothing */
- }
+ virtual std::string Describe() const;
+ virtual pkgCache::RlsFileIterator FindInCache(pkgCache &Cache, bool const ModifyCheck) const;
+ virtual bool Merge(pkgCacheGenerator &Gen,OpProgress *Prog) const;
- virtual ~metaIndex()
- {
- if (Indexes == 0)
- return;
- for (std::vector<pkgIndexFile *>::iterator I = (*Indexes).begin();
- I != (*Indexes).end(); ++I)
- delete *I;
- delete Indexes;
- }
+ metaIndex(std::string const &URI, std::string const &Dist,
+ char const * const Type);
+ virtual ~metaIndex();
};
#endif