forked from Pissandshittium/pissandshittium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfake_oauth_token_getter.h
34 lines (25 loc) · 927 Bytes
/
fake_oauth_token_getter.h
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
// 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 REMOTING_BASE_FAKE_OAUTH_TOKEN_GETTER_H_
#define REMOTING_BASE_FAKE_OAUTH_TOKEN_GETTER_H_
#include <string>
#include "base/callback.h"
#include "remoting/base/oauth_token_getter.h"
namespace remoting {
class FakeOAuthTokenGetter : public OAuthTokenGetter {
public:
FakeOAuthTokenGetter(Status status,
const std::string& user_email,
const std::string& access_token);
~FakeOAuthTokenGetter() override;
// OAuthTokenGetter interface.
void CallWithToken(TokenCallback on_access_token) override;
void InvalidateCache() override;
private:
Status status_;
std::string user_email_;
std::string access_token_;
};
} // namespace remoting
#endif // REMOTING_BASE_FAKE_OAUTH_TOKEN_GETTER_H_