summaryrefslogtreecommitdiff
path: root/apt-pkg/deb/debmetaindex.h
diff options
context:
space:
mode:
authorDavid Kalnischkies <kalnischkies@gmail.com>2009-12-23 12:38:19 +0100
committerDavid Kalnischkies <kalnischkies@gmail.com>2009-12-23 12:38:19 +0100
commit5dd4c8b811d9c7bc33e50254811f5bc0fc37f872 (patch)
tree013eba814628166b4b949c928772463d02630a9e /apt-pkg/deb/debmetaindex.h
parent5bf15716398fdb767ca6249a0155219b88d7ae60 (diff)
merge Goswin Brederlow "support download of index files for different archs"
patch which includes the following big changes: - Declare the unused [vendor] field in sources.list as option field, e.g. deb [arch=amd64,i386 lang=en_GB have=fun] http://example.org - When fetching index files download them for all APT::Architectures (overrideable with the options field above) - Allow all architectures of APT::Architectures to be in the Cache - Add the architecture to status and progress informations - Add b= (Binary architecture) to policy This commit doesn't incude the "pin-hack" as the Group structure will take care of this (and does it already to some extend).
Diffstat (limited to 'apt-pkg/deb/debmetaindex.h')
-rw-r--r--apt-pkg/deb/debmetaindex.h28
1 files changed, 16 insertions, 12 deletions
diff --git a/apt-pkg/deb/debmetaindex.h b/apt-pkg/deb/debmetaindex.h
index 8e6a1463b..360fa5419 100644
--- a/apt-pkg/deb/debmetaindex.h
+++ b/apt-pkg/deb/debmetaindex.h
@@ -5,40 +5,44 @@
#include <apt-pkg/metaindex.h>
#include <apt-pkg/sourcelist.h>
+#include <map>
+
class debReleaseIndex : public metaIndex {
public:
class debSectionEntry
{
public:
- debSectionEntry (string Section, bool IsSrc);
- bool IsSrc;
- string Section;
+ debSectionEntry (string const &Section, bool const &IsSrc);
+ string const Section;
+ bool const IsSrc;
};
private:
- vector <const debSectionEntry *> SectionEntries;
+ std::map<string, vector<debSectionEntry const*> > ArchEntries;
public:
- debReleaseIndex(string URI, string Dist);
+ debReleaseIndex(string const &URI, string const &Dist);
~debReleaseIndex();
- virtual string ArchiveURI(string File) const {return URI + File;};
- virtual bool GetIndexes(pkgAcquire *Owner, bool GetAll=false) const;
+ virtual string ArchiveURI(string const &File) const {return URI + File;};
+ virtual bool GetIndexes(pkgAcquire *Owner, bool const &GetAll=false) const;
vector <struct IndexTarget *>* ComputeIndexTargets() const;
- string Info(const char *Type, const string Section) const;
+ string Info(const char *Type, string const &Section, string const &Arch="") const;
string MetaIndexInfo(const char *Type) const;
string MetaIndexFile(const char *Types) const;
string MetaIndexURI(const char *Type) const;
- string IndexURI(const char *Type, const string Section) const;
- string IndexURISuffix(const char *Type, const string Section) const;
- string SourceIndexURI(const char *Type, const string Section) const;
- string SourceIndexURISuffix(const char *Type, const string Section) const;
+ string IndexURI(const char *Type, string const &Section, string const &Arch="native") const;
+ string IndexURISuffix(const char *Type, string const &Section, string const &Arch="native") const;
+ string SourceIndexURI(const char *Type, const string &Section) const;
+ string SourceIndexURISuffix(const char *Type, const string &Section) const;
virtual vector <pkgIndexFile *> *GetIndexFiles();
virtual bool IsTrusted() const;
+ void PushSectionEntry(vector<string> const &Archs, const debSectionEntry *Entry);
+ void PushSectionEntry(string const &Arch, const debSectionEntry *Entry);
void PushSectionEntry(const debSectionEntry *Entry);
};