Chromium Code Reviews| Index: android_webview/browser/net/aw_web_resource_request.h |
| diff --git a/android_webview/browser/net/aw_web_resource_request.h b/android_webview/browser/net/aw_web_resource_request.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..5bd934420e7eb0ec36b78e27b9817361bec81abd |
| --- /dev/null |
| +++ b/android_webview/browser/net/aw_web_resource_request.h |
| @@ -0,0 +1,32 @@ |
| +// Copyright 2016 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. |
| + |
| +#ifndef ANDROID_WEBVIEW_BROWSER_NET_AW_WEB_RESOURCE_REQUEST_H_ |
| +#define ANDROID_WEBVIEW_BROWSER_NET_AW_WEB_RESOURCE_REQUEST_H_ |
| + |
| +#include <string> |
| +#include <vector> |
| + |
| +namespace net { |
| +class URLRequest; |
| +} |
| + |
| +namespace android_webview { |
| + |
| +// A passive data structure only used to carry request information. |
| +struct AwWebResourceRequest { |
| + AwWebResourceRequest(const net::URLRequest* request); |
|
boliu
2016/12/08 05:48:38
const&, to avoid confusion that it's taking owners
sgurun-gerrit only
2016/12/08 21:56:46
Done.
|
| + virtual ~AwWebResourceRequest() {} |
|
boliu
2016/12/08 05:48:38
why virtual?
sgurun-gerrit only
2016/12/08 21:56:46
just getting used to I guess. Here in a struct it
boliu
2016/12/08 22:11:55
having an virtual destructor implies it's ok to su
sgurun-gerrit only
2016/12/08 22:43:18
did not know final. it works best.
|
| + |
| + std::string url; |
| + std::string method; |
| + bool is_main_frame; |
| + bool has_user_gesture; |
| + std::vector<std::string> header_names; |
| + std::vector<std::string> header_values; |
| +}; |
| + |
| +} // namespace android_webview |
| + |
| +#endif // ANDROID_WEBVIEW_BROWSER_NET_AW_WEB_RESOURCE_REQUEST_H_ |