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

Unified Diff: ios/net/crn_http_url_response.mm

Issue 994823004: [iOS] Upstream //ios/net (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: ios/net/crn_http_url_response.mm
diff --git a/ios/net/crn_http_url_response.mm b/ios/net/crn_http_url_response.mm
new file mode 100644
index 0000000000000000000000000000000000000000..3d32875efecff6794cecc926cd54e0e9b813b5de
--- /dev/null
+++ b/ios/net/crn_http_url_response.mm
@@ -0,0 +1,34 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#import "ios/net/crn_http_url_response.h"
+
+#include "base/mac/scoped_nsobject.h"
+
+@interface CRNHTTPURLResponse () {
+ base::scoped_nsobject<NSString> _cr_HTTPVersion;
+}
+@end
+
+@implementation CRNHTTPURLResponse
+
+- (NSString*)cr_HTTPVersion {
+ return _cr_HTTPVersion;
+}
+
+- (instancetype)initWithURL:(NSURL*)url
+ statusCode:(NSInteger)statusCode
+ HTTPVersion:(NSString*)HTTPVersion
+ headerFields:(NSDictionary*)headerFields {
+ self = [super initWithURL:url
+ statusCode:statusCode
+ HTTPVersion:HTTPVersion
+ headerFields:headerFields];
+ if (self) {
+ _cr_HTTPVersion.reset([HTTPVersion copy]);
+ }
+ return self;
+}
+
+@end

Powered by Google App Engine
This is Rietveld 408576698