Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / chrome / browser / ui / app_list / test / fake_profile.cc
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/ui/app_list/test/fake_profile.h"
6
7 FakeProfile::FakeProfile(const std::string& name)
8     : name_(name) {
9 }
10
11 FakeProfile::FakeProfile(const std::string& name, const base::FilePath& path)
12     : name_(name),
13       path_(path) {
14 }
15
16 std::string FakeProfile::GetProfileName() {
17   return name_;
18 }
19
20 base::FilePath FakeProfile::GetPath() const {
21   return path_;
22 }
23
24 bool FakeProfile::IsOffTheRecord() const {
25   return false;
26 }
27
28 content::DownloadManagerDelegate*
29 FakeProfile::GetDownloadManagerDelegate() {
30   return NULL;
31 }
32
33 net::URLRequestContextGetter* FakeProfile::GetRequestContextForRenderProcess(
34     int renderer_child_id) {
35   return NULL;
36 }
37
38 net::URLRequestContextGetter* FakeProfile::GetMediaRequestContext() {
39   return NULL;
40 }
41
42 net::URLRequestContextGetter*
43 FakeProfile::GetMediaRequestContextForRenderProcess(
44     int renderer_child_id) {
45   return NULL;
46 }
47
48 net::URLRequestContextGetter*
49 FakeProfile::GetMediaRequestContextForStoragePartition(
50         const base::FilePath& partition_path,
51         bool in_memory) {
52   return NULL;
53 }
54
55 void FakeProfile::RequestMidiSysExPermission(
56     int render_process_id,
57     int render_view_id,
58     int bridge_id,
59     const GURL& requesting_frame,
60     const MidiSysExPermissionCallback& callback) {
61 }
62
63 void FakeProfile::CancelMidiSysExPermissionRequest(
64     int render_process_id,
65     int render_view_id,
66     int bridge_id,
67     const GURL& requesting_frame) {
68 }
69
70 void FakeProfile::RequestProtectedMediaIdentifierPermission(
71     int render_process_id,
72     int render_view_id,
73     int bridge_id,
74     int group_id,
75     const GURL& requesting_frame,
76     const ProtectedMediaIdentifierPermissionCallback& callback) {
77 }
78
79 void FakeProfile::CancelProtectedMediaIdentifierPermissionRequests(
80     int group_id) {
81 }
82
83 content::ResourceContext* FakeProfile::GetResourceContext() {
84   return NULL;
85 }
86
87 content::GeolocationPermissionContext*
88 FakeProfile::GetGeolocationPermissionContext() {
89   return NULL;
90 }
91
92 quota::SpecialStoragePolicy* FakeProfile::GetSpecialStoragePolicy() {
93   return NULL;
94 }
95
96 scoped_refptr<base::SequencedTaskRunner>
97 FakeProfile::GetIOTaskRunner() {
98   return scoped_refptr<base::SequencedTaskRunner>();
99 }
100
101 Profile* FakeProfile::GetOffTheRecordProfile() {
102   return NULL;
103 }
104
105 void FakeProfile::DestroyOffTheRecordProfile() {}
106
107 bool FakeProfile::HasOffTheRecordProfile() {
108   return false;
109 }
110
111 Profile* FakeProfile::GetOriginalProfile() {
112   return this;
113 }
114
115 bool FakeProfile::IsManaged() {
116   return false;
117 }
118
119 history::TopSites* FakeProfile::GetTopSites() {
120   return NULL;
121 }
122
123 history::TopSites* FakeProfile::GetTopSitesWithoutCreating() {
124   return NULL;
125 }
126
127 ExtensionService* FakeProfile::GetExtensionService() {
128   return NULL;
129 }
130
131 ExtensionSpecialStoragePolicy* FakeProfile::GetExtensionSpecialStoragePolicy() {
132   return NULL;
133 }
134
135 PrefService* FakeProfile::GetPrefs() {
136   return NULL;
137 }
138
139 PrefService* FakeProfile::GetOffTheRecordPrefs() {
140   return NULL;
141 }
142
143 net::URLRequestContextGetter* FakeProfile::GetRequestContext() {
144   return NULL;
145 }
146
147 net::URLRequestContextGetter* FakeProfile::GetRequestContextForExtensions() {
148   return NULL;
149 }
150
151 net::SSLConfigService* FakeProfile::GetSSLConfigService() {
152   return NULL;
153 }
154
155 HostContentSettingsMap* FakeProfile::GetHostContentSettingsMap() {
156   return NULL;
157 }
158
159 bool FakeProfile::IsSameProfile(Profile* profile) {
160   return false;
161 }
162
163 base::Time FakeProfile::GetStartTime() const {
164   return base::Time();
165 }
166
167 net::URLRequestContextGetter* FakeProfile::CreateRequestContext(
168     content::ProtocolHandlerMap* protocol_handlers) {
169   return NULL;
170 }
171
172 net::URLRequestContextGetter*
173 FakeProfile::CreateRequestContextForStoragePartition(
174     const base::FilePath& partition_path,
175     bool in_memory,
176     content::ProtocolHandlerMap* protocol_handlers) {
177   return NULL;
178 }
179
180 base::FilePath FakeProfile::last_selected_directory() {
181   return base::FilePath();
182 }
183
184 void FakeProfile::set_last_selected_directory(const base::FilePath& path) {}
185
186 #if defined(OS_CHROMEOS)
187 void FakeProfile::ChangeAppLocale(
188     const std::string& locale, AppLocaleChangedVia via) {}
189 void FakeProfile::OnLogin() {}
190 void FakeProfile::InitChromeOSPreferences() {}
191 #endif  // defined(OS_CHROMEOS)
192
193 PrefProxyConfigTracker* FakeProfile::GetProxyConfigTracker() {
194   return NULL;
195 }
196
197 chrome_browser_net::Predictor* FakeProfile::GetNetworkPredictor() {
198   return NULL;
199 }
200
201 void FakeProfile::ClearNetworkingHistorySince(base::Time time,
202                                               const base::Closure& completion) {
203 }
204
205 GURL FakeProfile::GetHomePage() {
206   return GURL();
207 }
208
209 bool FakeProfile::WasCreatedByVersionOrLater(const std::string& version) {
210   return false;
211 }
212
213 void FakeProfile::SetExitType(ExitType exit_type) {
214 }
215
216 Profile::ExitType FakeProfile::GetLastSessionExitType() {
217   return EXIT_NORMAL;
218 }