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

Side by Side Diff: device/serial/data_sink_receiver.h

Issue 1311043003: Update mojo sdk to rev c02a28868825edfa57ab77947b8cb15e741c5598 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef DEVICE_SERIAL_DATA_SINK_RECEIVER_H_ 5 #ifndef DEVICE_SERIAL_DATA_SINK_RECEIVER_H_
6 #define DEVICE_SERIAL_DATA_SINK_RECEIVER_H_ 6 #define DEVICE_SERIAL_DATA_SINK_RECEIVER_H_
7 7
8 #include <queue> 8 #include <queue>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
11 #include "base/memory/linked_ptr.h" 11 #include "base/memory/linked_ptr.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/memory/weak_ptr.h" 13 #include "base/memory/weak_ptr.h"
14 #include "device/serial/buffer.h" 14 #include "device/serial/buffer.h"
15 #include "device/serial/data_stream.mojom.h" 15 #include "device/serial/data_stream.mojom.h"
16 #include "third_party/mojo/src/mojo/public/cpp/bindings/binding.h"
16 #include "third_party/mojo/src/mojo/public/cpp/system/data_pipe.h" 17 #include "third_party/mojo/src/mojo/public/cpp/system/data_pipe.h"
17 18
18 namespace device { 19 namespace device {
19 20
20 class DataSinkReceiver : public base::RefCounted<DataSinkReceiver>, 21 class DataSinkReceiver : public base::RefCounted<DataSinkReceiver>,
21 public serial::DataSink { 22 public serial::DataSink {
22 public: 23 public:
23 typedef base::Callback<void(scoped_ptr<ReadOnlyBuffer>)> ReadyCallback; 24 typedef base::Callback<void(scoped_ptr<ReadOnlyBuffer>)> ReadyCallback;
24 typedef base::Callback<void(int32_t error)> CancelCallback; 25 typedef base::Callback<void(int32_t error)> CancelCallback;
25 typedef base::Callback<void()> ErrorCallback; 26 typedef base::Callback<void()> ErrorCallback;
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 bool shut_down_; 101 bool shut_down_;
101 102
102 base::WeakPtrFactory<DataSinkReceiver> weak_factory_; 103 base::WeakPtrFactory<DataSinkReceiver> weak_factory_;
103 104
104 DISALLOW_COPY_AND_ASSIGN(DataSinkReceiver); 105 DISALLOW_COPY_AND_ASSIGN(DataSinkReceiver);
105 }; 106 };
106 107
107 } // namespace device 108 } // namespace device
108 109
109 #endif // DEVICE_SERIAL_DATA_SINK_RECEIVER_H_ 110 #endif // DEVICE_SERIAL_DATA_SINK_RECEIVER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698