21 #ifndef NET_INSTAWEB_HTTP_PUBLIC_COUNTING_URL_ASYNC_FETCHER_H_
22 #define NET_INSTAWEB_HTTP_PUBLIC_COUNTING_URL_ASYNC_FETCHER_H_
29 #include "pagespeed/kernel/util/platform.h"
31 namespace net_instaweb {
42 thread_system_(
Platform::CreateThreadSystem()),
43 mutex_(thread_system_->NewMutex()) {
65 return fetch_start_count_;
67 int byte_count()
const {
71 int failure_count()
const {
73 return failure_count_;
77 return most_recent_fetched_url_;
83 friend class CountingFetch;
88 int fetch_start_count_;
92 scoped_ptr<ThreadSystem> thread_system_;
93 scoped_ptr<AbstractMutex> mutex_;
Definition: counting_url_async_fetcher.h:36
std::string GoogleString
PAGESPEED_KERNEL_BASE_STRING_H_.
Definition: string.h:24
int fetch_count() const
number of completed fetches.
Definition: counting_url_async_fetcher.h:57
#define ScopedMutex(x)
Definition: abstract_mutex.h:69
Helper class for lexically scoped mutexing.
Definition: abstract_mutex.h:46
Definition: async_fetch.h:53
int fetch_start_count() const
number of started fetches
Definition: counting_url_async_fetcher.h:63
virtual void Fetch(const GoogleString &url, MessageHandler *message_handler, AsyncFetch *fetch)
Definition: message_handler.h:39
UrlAsyncFetcher()
Definition: url_async_fetcher.h:78
virtual bool SupportsHttps() const
Definition: url_async_fetcher.h:54
virtual bool SupportsHttps() const
Definition: counting_url_async_fetcher.h:50
CountingUrlAsyncFetcher(UrlAsyncFetcher *fetcher)
Definition: counting_url_async_fetcher.h:40
Definition: url_async_fetcher.h:33