Chromium Code Reviews| Index: content/browser/frame_host/navigation_request.h |
| diff --git a/content/browser/frame_host/navigation_request.h b/content/browser/frame_host/navigation_request.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..9741a2ed7b45f89708d9baf056884f5bb595d884 |
| --- /dev/null |
| +++ b/content/browser/frame_host/navigation_request.h |
| @@ -0,0 +1,43 @@ |
| +// 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. |
| + |
| +#ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ |
| +#define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ |
| + |
| +#include "base/basictypes.h" |
| +#include "base/memory/ref_counted.h" |
| +#include "content/browser/frame_host/navigation_request_info.h" |
| + |
| +namespace content { |
| +struct NavigationRequestInfo; |
|
jam
2014/07/15 00:05:43
nit: not needed because of the header include
clamy
2014/07/15 15:32:13
Done.
|
| +class ResourceRequestBody; |
| + |
| +// A UI thread object that owns a navigation request until it commits. It |
| +// ensures the UI thread can start a navigation request in the |
| +// ResourceDispatcherHost (that lives on the IO thread). |
| +// TODO(clamy): Describe the interactions between the UI and IO thread during |
| +// the navigation following its refactoring. |
| +class NavigationRequest { |
| + public: |
| + explicit NavigationRequest(const NavigationRequestInfo& info, |
|
jam
2014/07/15 00:05:43
nit: don't need explicit since it has more than on
clamy
2014/07/15 15:32:14
Done.
|
| + int64 frame_node_id); |
| + ~NavigationRequest(); |
| + |
| + const NavigationRequestInfo& info_for_testing() const { return info_; } |
| + int64 frame_node_id() const { return frame_node_id_; } |
| + |
| + // Called on the UI thread by the RenderFrameHostManager which owns the |
| + // NavigationRequest. |
|
davidben
2014/07/09 15:14:27
This probably wants a comment that, after calling
clamy
2014/07/15 15:32:14
Done.
|
| + void BeginNavigation(scoped_refptr<ResourceRequestBody> body); |
| + |
| + private: |
| + const NavigationRequestInfo info_; |
| + const int64 frame_node_id_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(NavigationRequest); |
| +}; |
| + |
| +} // namespace content |
| + |
| +#endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ |