| Index: content/public/browser/navigation_handle.h
|
| diff --git a/content/public/browser/navigation_handle.h b/content/public/browser/navigation_handle.h
|
| index f8a3b5e02fda3d45e37658e55253a77c4d3740bf..4f69719f790ab97b72b0b188d0da47f68692c074 100644
|
| --- a/content/public/browser/navigation_handle.h
|
| +++ b/content/public/browser/navigation_handle.h
|
| @@ -1,26 +1,28 @@
|
| // Copyright 2015 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_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_
|
| #define CONTENT_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_
|
|
|
| +#include "base/supports_user_data.h"
|
| #include "content/common/content_export.h"
|
| #include "content/public/browser/navigation_throttle.h"
|
| #include "content/public/common/referrer.h"
|
| #include "net/base/net_errors.h"
|
| #include "ui/base/page_transition_types.h"
|
|
|
| class GURL;
|
|
|
| namespace content {
|
| +class NavigationUserData;
|
| class NavigationThrottle;
|
| class RenderFrameHost;
|
| class WebContents;
|
|
|
| // A NavigationHandle tracks information related to a single navigation.
|
| // NavigationHandles are provided to several WebContentsObserver methods to
|
| // allow observers to track specific navigations. Observers should clear any
|
| // references to a NavigationHandle at the time of
|
| // WebContentsObserver::DidFinishNavigation, just before the handle is
|
| // destroyed.
|
| @@ -127,20 +129,22 @@ class CONTENT_EXPORT NavigationHandle {
|
|
|
| // Resumes a navigation that was previously deferred by a NavigationThrottle.
|
| virtual void Resume() = 0;
|
|
|
| // Cancels a navigation that was previously deferred by a NavigationThrottle.
|
| // |result| should be equal to NavigationThrottle::CANCEL or
|
| // NavigationThrottle::CANCEL_AND_IGNORE.
|
| virtual void CancelDeferredNavigation(
|
| NavigationThrottle::ThrottleCheckResult result) = 0;
|
|
|
| + virtual base::SupportsUserData::Data* GetUserData(const void* key) = 0;
|
| +
|
| // Testing methods ----------------------------------------------------------
|
| //
|
| // The following methods should be used exclusively for writing unit tests.
|
|
|
| static scoped_ptr<NavigationHandle> CreateNavigationHandleForTesting(
|
| const GURL& url,
|
| RenderFrameHost* render_frame_host);
|
|
|
| // Registers a NavigationThrottle for tests. The throttle can
|
| // modify the request, pause the request or cancel the request. This will
|
|
|