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

Side by Side Diff: ios/web/public/test/http_server/string_response_provider.mm

Issue 2923563005: [ObjC ARC] Converts ios/web/public/test/http_server:http_server to ARC. (Closed)
Patch Set: cleanup Created 3 years, 6 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 | « ios/web/public/test/http_server/response_provider.mm ('k') | no next file » | 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 #import "ios/web/public/test/http_server/string_response_provider.h" 5 #import "ios/web/public/test/http_server/string_response_provider.h"
6 6
7 #if !defined(__has_feature) || !__has_feature(objc_arc)
8 #error "This file requires ARC support."
9 #endif
10
7 namespace web { 11 namespace web {
8 12
9 StringResponseProvider::StringResponseProvider(const std::string& response_body) 13 StringResponseProvider::StringResponseProvider(const std::string& response_body)
10 : response_body_(response_body) {} 14 : response_body_(response_body) {}
11 15
12 bool StringResponseProvider::CanHandleRequest(const Request& request) { 16 bool StringResponseProvider::CanHandleRequest(const Request& request) {
13 return true; 17 return true;
14 } 18 }
15 19
16 void StringResponseProvider::GetResponseHeadersAndBody( 20 void StringResponseProvider::GetResponseHeadersAndBody(
17 const Request& request, 21 const Request& request,
18 scoped_refptr<net::HttpResponseHeaders>* headers, 22 scoped_refptr<net::HttpResponseHeaders>* headers,
19 std::string* response_body) { 23 std::string* response_body) {
20 *headers = GetDefaultResponseHeaders(); 24 *headers = GetDefaultResponseHeaders();
21 *response_body = response_body_; 25 *response_body = response_body_;
22 } 26 }
23 27
24 } // namespace web 28 } // namespace web
OLDNEW
« no previous file with comments | « ios/web/public/test/http_server/response_provider.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698