Index: multi_http_fetcher.h |
diff --git a/multi_http_fetcher.h b/multi_http_fetcher.h |
index 197234799e1d3d4259ec9f55eab76c29416f952e..43281990952ffa668cdd1574b51495c81dfffd39 100644 |
--- a/multi_http_fetcher.h |
+++ b/multi_http_fetcher.h |
@@ -73,8 +73,7 @@ class MultiHttpFetcher : public HttpFetcher, public HttpFetcherDelegate { |
fetchers_[current_index_]->Unpause(); |
} |
- // These two function are overloaded in LibcurlHttp fetcher to speed |
- // testing. |
+ // These functions are overloaded in LibcurlHttp fetcher for testing purposes. |
void set_idle_seconds(int seconds) { |
for (typename std::vector<std::tr1::shared_ptr<BaseHttpFetcher> >::iterator |
it = fetchers_.begin(), |
@@ -89,6 +88,20 @@ class MultiHttpFetcher : public HttpFetcher, public HttpFetcherDelegate { |
(*it)->set_retry_seconds(seconds); |
} |
} |
+ void SetConnectionAsExpensive(bool is_expensive) { |
+ for (typename std::vector<std::tr1::shared_ptr<BaseHttpFetcher> >::iterator |
+ it = fetchers_.begin(), |
+ e = fetchers_.end(); it != e; ++it) { |
+ (*it)->SetConnectionAsExpensive(is_expensive); |
+ } |
+ } |
+ void SetBuildType(bool is_official) { |
+ for (typename std::vector<std::tr1::shared_ptr<BaseHttpFetcher> >::iterator |
+ it = fetchers_.begin(), |
+ e = fetchers_.end(); it != e; ++it) { |
+ (*it)->SetBuildType(is_official); |
+ } |
+ } |
private: |
void SendTransferComplete(HttpFetcher* fetcher, bool successful) { |
@@ -173,7 +186,7 @@ class MultiHttpFetcher : public HttpFetcher, public HttpFetcherDelegate { |
} |
// If true, do not send any more data or TransferComplete to the delegate. |
- bool sent_transfer_complete_; |
+ bool sent_transfer_complete_; |
RangesVect ranges_; |
std::vector<std::tr1::shared_ptr<BaseHttpFetcher> > fetchers_; |