summaryrefslogtreecommitdiff
path: root/methods/mirror.h
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2006-11-29 22:59:35 +0100
committerMichael Vogt <michael.vogt@ubuntu.com>2006-11-29 22:59:35 +0100
commit14e097c105c49a102a642c8108979356c5cc3152 (patch)
treebcf699c8e66bdfa37e2d2f424f9a9d390b4c5d90 /methods/mirror.h
parent5f6b130d6342965bfa49beb9413bdf742440b8ab (diff)
* working mirror implementation based on http method
Diffstat (limited to 'methods/mirror.h')
-rw-r--r--methods/mirror.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/methods/mirror.h b/methods/mirror.h
index ca3428830..91cf8c64f 100644
--- a/methods/mirror.h
+++ b/methods/mirror.h
@@ -20,17 +20,24 @@ using std::endl;
#include "http.h"
-class MirrorMethod : public pkgAcqMethod
+class MirrorMethod : public HttpMethod
{
FetchResult Res;
- string Mirror;
- string BaseUri;
- string MirrorFile;
+ string BaseUri; // the original mirror://... url
+ string Mirror; // the selected mirror uri (http://...)
+ string MirrorFile; //
bool HasMirrorFile;
+ bool Debug;
+
protected:
bool GetMirrorFile(string uri);
bool SelectMirror();
+ virtual void Fail(string Why, bool Transient = false);
+ virtual void URIStart(FetchResult &Res);
+ virtual void URIDone(FetchResult &Res,FetchResult *Alt = 0);
+ virtual bool Configuration(string Message);
+
public:
MirrorMethod();
virtual bool Fetch(FetchItem *Itm);