summaryrefslogtreecommitdiff
path: root/chromium/chrome/browser/signin/header_modification_delegate.h
blob: 8d3bce133acf8a0b20bfcefa9c73f7b42bd8203d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// Copyright 2018 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 CHROME_BROWSER_SIGNIN_HEADER_MODIFICATION_DELEGATE_H_
#define CHROME_BROWSER_SIGNIN_HEADER_MODIFICATION_DELEGATE_H_

class GURL;

namespace content {
class WebContents;
}

namespace signin {

class ChromeRequestAdapter;
class ResponseAdapter;

class HeaderModificationDelegate {
 public:
  HeaderModificationDelegate() = default;

  HeaderModificationDelegate(const HeaderModificationDelegate&) = delete;
  HeaderModificationDelegate& operator=(const HeaderModificationDelegate&) =
      delete;

  virtual ~HeaderModificationDelegate() = default;

  virtual bool ShouldInterceptNavigation(content::WebContents* contents) = 0;
  virtual void ProcessRequest(ChromeRequestAdapter* request_adapter,
                              const GURL& redirect_url) = 0;
  virtual void ProcessResponse(ResponseAdapter* response_adapter,
                               const GURL& redirect_url) = 0;
};

}  // namespace signin

#endif  // CHROME_BROWSER_SIGNIN_HEADER_MODIFICATION_DELEGATE_H_