| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_SUPERVISED_USER_EXPERIMENTAL_SUPERVISED_USER_BLACKLIST_DO
WNLOADER_H_ | 5 #ifndef CHROME_BROWSER_SUPERVISED_USER_EXPERIMENTAL_SUPERVISED_USER_BLACKLIST_DO
WNLOADER_H_ |
| 6 #define CHROME_BROWSER_SUPERVISED_USER_EXPERIMENTAL_SUPERVISED_USER_BLACKLIST_DO
WNLOADER_H_ | 6 #define CHROME_BROWSER_SUPERVISED_USER_EXPERIMENTAL_SUPERVISED_USER_BLACKLIST_DO
WNLOADER_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 // If the instance is destroyed before it is finished, |callback| is not run. | 32 // If the instance is destroyed before it is finished, |callback| is not run. |
| 33 SupervisedUserBlacklistDownloader( | 33 SupervisedUserBlacklistDownloader( |
| 34 const GURL& url, | 34 const GURL& url, |
| 35 const base::FilePath& path, | 35 const base::FilePath& path, |
| 36 net::URLRequestContextGetter* request_context, | 36 net::URLRequestContextGetter* request_context, |
| 37 const DownloadFinishedCallback& callback); | 37 const DownloadFinishedCallback& callback); |
| 38 virtual ~SupervisedUserBlacklistDownloader(); | 38 virtual ~SupervisedUserBlacklistDownloader(); |
| 39 | 39 |
| 40 private: | 40 private: |
| 41 // net::URLFetcherDelegate implementation. | 41 // net::URLFetcherDelegate implementation. |
| 42 virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE; | 42 virtual void OnURLFetchComplete(const net::URLFetcher* source) override; |
| 43 | 43 |
| 44 void OnFileExistsCheckDone(bool exists); | 44 void OnFileExistsCheckDone(bool exists); |
| 45 | 45 |
| 46 DownloadFinishedCallback callback_; | 46 DownloadFinishedCallback callback_; |
| 47 | 47 |
| 48 scoped_ptr<net::URLFetcher> fetcher_; | 48 scoped_ptr<net::URLFetcher> fetcher_; |
| 49 | 49 |
| 50 base::WeakPtrFactory<SupervisedUserBlacklistDownloader> weak_ptr_factory_; | 50 base::WeakPtrFactory<SupervisedUserBlacklistDownloader> weak_ptr_factory_; |
| 51 | 51 |
| 52 DISALLOW_COPY_AND_ASSIGN(SupervisedUserBlacklistDownloader); | 52 DISALLOW_COPY_AND_ASSIGN(SupervisedUserBlacklistDownloader); |
| 53 }; | 53 }; |
| 54 | 54 |
| 55 #endif // CHROME_BROWSER_SUPERVISED_USER_EXPERIMENTAL_SUPERVISED_USER_BLACKLIST
_DOWNLOADER_H_ | 55 #endif // CHROME_BROWSER_SUPERVISED_USER_EXPERIMENTAL_SUPERVISED_USER_BLACKLIST
_DOWNLOADER_H_ |
| OLD | NEW |