summaryrefslogtreecommitdiff
path: root/apt-pkg/acquire-item.h
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg/acquire-item.h')
-rw-r--r--apt-pkg/acquire-item.h21
1 files changed, 18 insertions, 3 deletions
diff --git a/apt-pkg/acquire-item.h b/apt-pkg/acquire-item.h
index da1bea801..f659bb459 100644
--- a/apt-pkg/acquire-item.h
+++ b/apt-pkg/acquire-item.h
@@ -9,8 +9,8 @@
the Owner Acquire class. Derived classes will then call QueueURI to
register all the URI's they wish to fetch at the initial moment.
- Two item classes are provided to provide functionality for downloading
- of Index files and downloading of Packages.
+ Three item classes are provided to provide functionality for
+ downloading of Index, Translation and Packages files.
A Archive class is provided for downloading .deb files. It does Md5
checking and source location as well as a retry algorithm.
@@ -48,7 +48,8 @@ class pkgAcquire::Item
public:
// State of the item
- enum {StatIdle, StatFetching, StatDone, StatError, StatAuthError} Status;
+ enum {StatIdle, StatFetching, StatDone, StatError,
+ StatAuthError, StatTransientNetworkError} Status;
string ErrorText;
unsigned long FileSize;
unsigned long PartialSize;
@@ -56,6 +57,7 @@ class pkgAcquire::Item
unsigned long ID;
bool Complete;
bool Local;
+ string UsedMirror;
// Number of queues we are inserted into
unsigned int QueueCounter;
@@ -78,6 +80,9 @@ class pkgAcquire::Item
pkgAcquire *GetOwner() {return Owner;};
virtual bool IsTrusted() {return false;};
+ // report mirror problems
+ void ReportMirrorFailure(string FailCode);
+
Item(pkgAcquire *Owner);
virtual ~Item();
};
@@ -107,6 +112,16 @@ class pkgAcqIndex : public pkgAcquire::Item
string ShortDesct, string ExpectedMD5, string compressExt="");
};
+// Item class for translated package index files
+class pkgAcqIndexTrans : public pkgAcqIndex
+{
+ public:
+
+ virtual void Failed(string Message,pkgAcquire::MethodConfig *Cnf);
+ pkgAcqIndexTrans(pkgAcquire *Owner,string URI,string URIDesc,
+ string ShortDesct);
+};
+
struct IndexTarget
{
string URI;