Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(109)

Unified Diff: chromeos/dbus/fake_cups_client.h

Issue 2232203003: Implement a dbus client for CupsTool. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chromeos/dbus/fake_cups_client.h
diff --git a/chromeos/dbus/fake_cups_client.h b/chromeos/dbus/fake_cups_client.h
new file mode 100644
index 0000000000000000000000000000000000000000..8e47fbba55be85c4d22371c20aa3bbee18bfd37c
--- /dev/null
+++ b/chromeos/dbus/fake_cups_client.h
@@ -0,0 +1,40 @@
+// Copyright 2016 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 CHROMEOS_DBUS_FAKE_CUPS_CLIENT_H_
+#define CHROMEOS_DBUS_FAKE_CUPS_CLIENT_H_
+
+#include <set>
+#include <string>
+
+#include "chromeos/chromeos_export.h"
+#include "chromeos/dbus/cups_client.h"
+
+namespace chromeos {
hashimoto 2016/09/07 05:53:17 nit: Please add a blank line.
skau 2016/09/09 15:25:32 Acknowledged.
+class CHROMEOS_EXPORT FakeCupsClient : public CupsClient {
+ public:
+ FakeCupsClient();
+
+ ~FakeCupsClient() override;
+
+ void AddPrinter(const std::string& name,
+ const std::string& uri,
+ const std::string& ppd_path,
+ bool ipp_everywhere,
+ const AddPrinterCallback& callback,
+ const base::Closure& error_callback) override;
+
+ void RemovePrinter(const std::string& name,
+ const RemovePrinterCallback& callback,
+ const base::Closure& error_callback) override;
+
+ protected:
+ void Init(dbus::Bus* bus) override;
+
+ private:
+ std::set<std::string> printers_;
+};
hashimoto 2016/09/07 05:53:17 nit: Please add a blank line.
skau 2016/09/09 15:25:32 Acknowledged.
+} // namespace chromeos
+
+#endif // CHROMEOS_DBUS_FAKE_CUPS_CLIENT_H_

Powered by Google App Engine
This is Rietveld 408576698