OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_BLUETOOTH_BLUETOOTH_SOCKET_MAC_H_ | 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_SOCKET_MAC_H_ |
6 #define DEVICE_BLUETOOTH_BLUETOOTH_SOCKET_MAC_H_ | 6 #define DEVICE_BLUETOOTH_BLUETOOTH_SOCKET_MAC_H_ |
7 | 7 |
8 #include <queue> | 8 #include <queue> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
54 virtual void Close() OVERRIDE; | 54 virtual void Close() OVERRIDE; |
55 virtual void Disconnect(const base::Closure& callback) OVERRIDE; | 55 virtual void Disconnect(const base::Closure& callback) OVERRIDE; |
56 virtual void Receive( | 56 virtual void Receive( |
57 int /* buffer_size */, | 57 int /* buffer_size */, |
58 const ReceiveCompletionCallback& success_callback, | 58 const ReceiveCompletionCallback& success_callback, |
59 const ReceiveErrorCompletionCallback& error_callback) OVERRIDE; | 59 const ReceiveErrorCompletionCallback& error_callback) OVERRIDE; |
60 virtual void Send(scoped_refptr<net::IOBuffer> buffer, | 60 virtual void Send(scoped_refptr<net::IOBuffer> buffer, |
61 int buffer_size, | 61 int buffer_size, |
62 const SendCompletionCallback& success_callback, | 62 const SendCompletionCallback& success_callback, |
63 const ErrorCompletionCallback& error_callback) OVERRIDE; | 63 const ErrorCompletionCallback& error_callback) OVERRIDE; |
64 virtual void Accept(const AcceptCompletionCallback& success_callback, | |
65 const ErrorCompletionCallback& error_callback) OVERRIDE; | |
Ilya Sherman
2014/05/09 23:44:15
This method name is a bit confusing in this class,
| |
66 | |
64 | 67 |
65 // Called by BluetoothRFCOMMChannelDelegate. | 68 // Called by BluetoothRFCOMMChannelDelegate. |
66 void OnChannelOpened(IOBluetoothRFCOMMChannel* rfcomm_channel, | 69 void OnChannelOpened(IOBluetoothRFCOMMChannel* rfcomm_channel, |
67 IOReturn status); | 70 IOReturn status); |
68 void OnChannelClosed(IOBluetoothRFCOMMChannel* rfcomm_channel); | 71 void OnChannelClosed(IOBluetoothRFCOMMChannel* rfcomm_channel); |
69 void OnChannelDataReceived(IOBluetoothRFCOMMChannel* rfcomm_channel, | 72 void OnChannelDataReceived(IOBluetoothRFCOMMChannel* rfcomm_channel, |
70 void* data, | 73 void* data, |
71 size_t length); | 74 size_t length); |
72 void OnChannelWriteComplete(IOBluetoothRFCOMMChannel* rfcomm_channel, | 75 void OnChannelWriteComplete(IOBluetoothRFCOMMChannel* rfcomm_channel, |
73 void* refcon, | 76 void* refcon, |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
142 | 145 |
143 // Send queue -- one entry per pending send operation. | 146 // Send queue -- one entry per pending send operation. |
144 std::queue<linked_ptr<SendRequest> > send_queue_; | 147 std::queue<linked_ptr<SendRequest> > send_queue_; |
145 | 148 |
146 DISALLOW_COPY_AND_ASSIGN(BluetoothSocketMac); | 149 DISALLOW_COPY_AND_ASSIGN(BluetoothSocketMac); |
147 }; | 150 }; |
148 | 151 |
149 } // namespace device | 152 } // namespace device |
150 | 153 |
151 #endif // DEVICE_BLUETOOTH_BLUETOOTH_SOCKET_MAC_H_ | 154 #endif // DEVICE_BLUETOOTH_BLUETOOTH_SOCKET_MAC_H_ |
OLD | NEW |