Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Side by Side Diff: remoting/test/host_list_fetcher.h

Issue 1864213002: Convert //remoting to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Mac IWYU Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « remoting/test/fake_socket_factory.h ('k') | remoting/test/host_list_fetcher.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 REMOTING_TEST_HOST_LIST_FETCHER_H_ 5 #ifndef REMOTING_TEST_HOST_LIST_FETCHER_H_
6 #define REMOTING_TEST_HOST_LIST_FETCHER_H_ 6 #define REMOTING_TEST_HOST_LIST_FETCHER_H_
7 7
8 #include <memory>
8 #include <string> 9 #include <string>
9 #include <vector> 10 #include <vector>
10 11
11 #include "base/callback.h" 12 #include "base/callback.h"
12 #include "base/macros.h" 13 #include "base/macros.h"
13 #include "base/memory/ref_counted.h" 14 #include "base/memory/ref_counted.h"
14 #include "base/memory/scoped_ptr.h"
15 #include "net/url_request/url_fetcher_delegate.h" 15 #include "net/url_request/url_fetcher_delegate.h"
16 #include "remoting/test/host_info.h" 16 #include "remoting/test/host_info.h"
17 17
18 namespace net { 18 namespace net {
19 class UrlFetcher; 19 class UrlFetcher;
20 } 20 }
21 namespace remoting { 21 namespace remoting {
22 class URLRequestContextGetter; 22 class URLRequestContextGetter;
23 } 23 }
24 24
(...skipping 26 matching lines...) Expand all
51 const HostlistCallback& callback); 51 const HostlistCallback& callback);
52 52
53 private: 53 private:
54 // Processes the response from the directory service. 54 // Processes the response from the directory service.
55 bool ProcessResponse(std::vector<HostInfo>* hostlist); 55 bool ProcessResponse(std::vector<HostInfo>* hostlist);
56 56
57 // net::URLFetcherDelegate interface. 57 // net::URLFetcherDelegate interface.
58 void OnURLFetchComplete(const net::URLFetcher* source) override; 58 void OnURLFetchComplete(const net::URLFetcher* source) override;
59 59
60 // Holds the URLFetcher for the Host List request. 60 // Holds the URLFetcher for the Host List request.
61 scoped_ptr<net::URLFetcher> request_; 61 std::unique_ptr<net::URLFetcher> request_;
62 62
63 // Provides application-specific context for the network request. 63 // Provides application-specific context for the network request.
64 scoped_refptr<remoting::URLRequestContextGetter> request_context_getter_; 64 scoped_refptr<remoting::URLRequestContextGetter> request_context_getter_;
65 65
66 // Caller-supplied callback used to return hostlist on success. 66 // Caller-supplied callback used to return hostlist on success.
67 HostlistCallback hostlist_callback_; 67 HostlistCallback hostlist_callback_;
68 68
69 DISALLOW_COPY_AND_ASSIGN(HostListFetcher); 69 DISALLOW_COPY_AND_ASSIGN(HostListFetcher);
70 }; 70 };
71 71
72 } // namespace test 72 } // namespace test
73 } // namespace remoting 73 } // namespace remoting
74 74
75 #endif // REMOTING_TEST_HOST_LIST_FETCHER_H_ 75 #endif // REMOTING_TEST_HOST_LIST_FETCHER_H_
OLDNEW
« no previous file with comments | « remoting/test/fake_socket_factory.h ('k') | remoting/test/host_list_fetcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698