| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 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 | 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 // The intent of this file is to provide a type-neutral abstraction between | 5 // The intent of this file is to provide a type-neutral abstraction between |
| 6 // Chrome and WebKit for resource loading. This pure-virtual interface is | 6 // Chrome and WebKit for resource loading. This pure-virtual interface is |
| 7 // implemented by the embedder, which also provides a factory method Create | 7 // implemented by the embedder, which also provides a factory method Create |
| 8 // to instantiate this object. | 8 // to instantiate this object. |
| 9 // | 9 // |
| 10 // One of these objects will be created by WebKit for each request. WebKit | 10 // One of these objects will be created by WebKit for each request. WebKit |
| 11 // will own the pointer to the bridge, and will delete it when the request is | 11 // will own the pointer to the bridge, and will delete it when the request is |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 241 bool has_user_gesture; | 241 bool has_user_gesture; |
| 242 }; | 242 }; |
| 243 | 243 |
| 244 // See the SyncLoad method declared below. (The name of this struct is not | 244 // See the SyncLoad method declared below. (The name of this struct is not |
| 245 // suffixed with "Info" because it also contains the response data.) | 245 // suffixed with "Info" because it also contains the response data.) |
| 246 struct SyncLoadResponse : ResourceResponseInfo { | 246 struct SyncLoadResponse : ResourceResponseInfo { |
| 247 SyncLoadResponse(); | 247 SyncLoadResponse(); |
| 248 ~SyncLoadResponse(); | 248 ~SyncLoadResponse(); |
| 249 | 249 |
| 250 // The response status. | 250 // The response status. |
| 251 URLRequestStatus status; | 251 net::URLRequestStatus status; |
| 252 | 252 |
| 253 // The final URL of the response. This may differ from the request URL in | 253 // The final URL of the response. This may differ from the request URL in |
| 254 // the case of a server redirect. | 254 // the case of a server redirect. |
| 255 GURL url; | 255 GURL url; |
| 256 | 256 |
| 257 // The response data. | 257 // The response data. |
| 258 std::string data; | 258 std::string data; |
| 259 }; | 259 }; |
| 260 | 260 |
| 261 // Generated by the bridge. This is implemented by our custom resource loader | 261 // Generated by the bridge. This is implemented by our custom resource loader |
| (...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 377 // construction must go through Create() | 377 // construction must go through Create() |
| 378 ResourceLoaderBridge(); | 378 ResourceLoaderBridge(); |
| 379 | 379 |
| 380 private: | 380 private: |
| 381 DISALLOW_COPY_AND_ASSIGN(ResourceLoaderBridge); | 381 DISALLOW_COPY_AND_ASSIGN(ResourceLoaderBridge); |
| 382 }; | 382 }; |
| 383 | 383 |
| 384 } // namespace webkit_glue | 384 } // namespace webkit_glue |
| 385 | 385 |
| 386 #endif // WEBKIT_GLUE_RESOURCE_LOADER_BRIDGE_H_ | 386 #endif // WEBKIT_GLUE_RESOURCE_LOADER_BRIDGE_H_ |
| OLD | NEW |