| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2011 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | |
| 6 | |
| 7 #ifndef CONTENT_COMMON_RESOURCE_RESPONSE_H_ | |
| 8 #define CONTENT_COMMON_RESOURCE_RESPONSE_H_ | |
| 9 #pragma once | |
| 10 | |
| 11 #include <string> | |
| 12 | |
| 13 #include "base/memory/ref_counted.h" | |
| 14 #include "content/common/content_export.h" | |
| 15 #include "googleurl/src/gurl.h" | |
| 16 #include "net/url_request/url_request_status.h" | |
| 17 #include "webkit/glue/resource_loader_bridge.h" | |
| 18 | |
| 19 // Parameters for a resource response header. | |
| 20 struct ResourceResponseHead : webkit_glue::ResourceResponseInfo { | |
| 21 // The response status. | |
| 22 net::URLRequestStatus status; | |
| 23 }; | |
| 24 | |
| 25 // Parameters for a synchronous resource response. | |
| 26 struct SyncLoadResult : ResourceResponseHead { | |
| 27 // The final URL after any redirects. | |
| 28 GURL final_url; | |
| 29 | |
| 30 // The response data. | |
| 31 std::string data; | |
| 32 }; | |
| 33 | |
| 34 // Simple wrapper that refcounts ResourceResponseHead. | |
| 35 struct CONTENT_EXPORT ResourceResponse | |
| 36 : public base::RefCounted<ResourceResponse> { | |
| 37 ResourceResponse(); | |
| 38 | |
| 39 ResourceResponseHead response_head; | |
| 40 | |
| 41 private: | |
| 42 friend class base::RefCounted<ResourceResponse>; | |
| 43 | |
| 44 ~ResourceResponse(); | |
| 45 }; | |
| 46 | |
| 47 #endif // CONTENT_COMMON_RESOURCE_RESPONSE_H_ | |
| OLD | NEW |