summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/fake_lorgnette_manager_client.cc
blob: 3487ea4f6ea6f43c5fc3fa6b38c6f9c633308a6f (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
39
40
41
42
43
44
45
46
47
48
49
// 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.

#include "chromeos/dbus/fake_lorgnette_manager_client.h"

#include <map>
#include <string>
#include <vector>

#include "base/bind.h"
#include "base/callback.h"
#include "base/location.h"
#include "base/message_loop/message_loop.h"

namespace chromeos {

FakeLorgnetteManagerClient::FakeLorgnetteManagerClient() {}

FakeLorgnetteManagerClient::~FakeLorgnetteManagerClient() {}

void FakeLorgnetteManagerClient::Init(dbus::Bus* bus) {}

void FakeLorgnetteManagerClient::ListScanners(
    const ListScannersCallback& callback) {
  std::map<std::string, ScannerTableEntry> scanners;
  base::MessageLoop::current()->PostTask(FROM_HERE,
                                         base::Bind(callback, false, scanners));
}

void FakeLorgnetteManagerClient::ScanImageToFile(
    std::string device_name,
    const ScanProperties& properties,
    const ScanImageToFileCallback& callback,
    base::File* file) {
  base::MessageLoop::current()->PostTask(FROM_HERE,
                                         base::Bind(callback, false));
}

void FakeLorgnetteManagerClient::ScanImageToString(
    std::string device_name,
    const ScanProperties& properties,
    const ScanImageToStringCallback& callback) {
  base::MessageLoop::current()->PostTask(FROM_HERE,
                                         base::Bind(callback, false,
                                                    std::string()));
}

}  // namespace chromeos