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

Side by Side Diff: content/public/common/resource_response.h

Issue 519533002: Initial PlzNavigate RDH-side logic. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix tests Created 6 years, 2 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading
6 6
7 #ifndef CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_H_ 7 #ifndef CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_H_
8 #define CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_H_ 8 #define CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_H_
9 9
10 #include <string> 10 #include <string>
(...skipping 22 matching lines...) Expand all
33 // The final URL after any redirects. 33 // The final URL after any redirects.
34 GURL final_url; 34 GURL final_url;
35 35
36 // The response data. 36 // The response data.
37 std::string data; 37 std::string data;
38 }; 38 };
39 39
40 // Simple wrapper that refcounts ResourceResponseHead. 40 // Simple wrapper that refcounts ResourceResponseHead.
41 // Inherited, rather than typedef'd, to allow forward declarations. 41 // Inherited, rather than typedef'd, to allow forward declarations.
42 struct CONTENT_EXPORT ResourceResponse 42 struct CONTENT_EXPORT ResourceResponse
43 : public base::RefCounted<ResourceResponse> { 43 : public base::RefCountedThreadSafe<ResourceResponse> {
44 public: 44 public:
45 ResourceResponseHead head; 45 ResourceResponseHead head;
46 46
47 // Performs a deep copy of the ResourceResponse and all fields in it, safe to
48 // pass across threads.
49 //
50 // TODO(davidben): This structure should be passed along in a scoped_ptr. It's
51 // currently reference-counted to avoid copies, but may be
52 // modified. https://crbug.com/416050
53 scoped_refptr<ResourceResponse> DeepCopy() const;
54
47 private: 55 private:
48 friend class base::RefCounted<ResourceResponse>; 56 friend class base::RefCountedThreadSafe<ResourceResponse>;
49 ~ResourceResponse() {} 57 ~ResourceResponse() {}
50 }; 58 };
51 59
52 } // namespace content 60 } // namespace content
53 61
54 #endif // CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_H_ 62 #endif // CONTENT_PUBLIC_COMMON_RESOURCE_RESPONSE_H_
OLDNEW
« no previous file with comments | « content/public/common/resource_devtools_info.cc ('k') | content/public/common/resource_response.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698