1// Copyright 2014 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "chrome/browser/local_discovery/gcd_api_flow.h"
6
7#include "chrome/browser/local_discovery/gcd_api_flow_impl.h"
8#include "chrome/browser/local_discovery/gcd_constants.h"
9#include "chrome/common/cloud_print/cloud_print_constants.h"
10#include "components/cloud_devices/common/cloud_devices_urls.h"
11
12namespace local_discovery {
13
14GCDApiFlow::Request::Request() {
15}
16
17GCDApiFlow::Request::~Request() {
18}
19
20net::URLFetcher::RequestType GCDApiFlow::Request::GetRequestType() {
21  return net::URLFetcher::GET;
22}
23
24void GCDApiFlow::Request::GetUploadData(std::string* upload_type,
25                                        std::string* upload_data) {
26  *upload_type = std::string();
27  *upload_data = std::string();
28}
29
30scoped_ptr<GCDApiFlow> GCDApiFlow::Create(
31    net::URLRequestContextGetter* request_context,
32    OAuth2TokenService* token_service,
33    const std::string& account_id) {
34  return scoped_ptr<GCDApiFlow>(
35      new GCDApiFlowImpl(request_context, token_service, account_id));
36}
37
38GCDApiFlow::GCDApiFlow() {
39}
40
41GCDApiFlow::~GCDApiFlow() {
42}
43
44GCDApiFlowRequest::GCDApiFlowRequest() {
45}
46
47GCDApiFlowRequest::~GCDApiFlowRequest() {
48}
49
50std::string GCDApiFlowRequest::GetOAuthScope() {
51  return cloud_devices::kCloudDevicesAuthScope;
52}
53
54std::vector<std::string> GCDApiFlowRequest::GetExtraRequestHeaders() {
55  return std::vector<std::string>();
56}
57
58CloudPrintApiFlowRequest::CloudPrintApiFlowRequest() {
59}
60
61CloudPrintApiFlowRequest::~CloudPrintApiFlowRequest() {
62}
63
64std::string CloudPrintApiFlowRequest::GetOAuthScope() {
65  return cloud_devices::kCloudPrintAuthScope;
66}
67
68std::vector<std::string> CloudPrintApiFlowRequest::GetExtraRequestHeaders() {
69  return std::vector<std::string>(1, cloud_print::kChromeCloudPrintProxyHeader);
70}
71
72}  // namespace local_discovery
73