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

Side by Side Diff: device/bluetooth/bluetooth_service_record_win.h

Issue 1542163002: Switch to standard integer types in device/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: win Created 4 years, 12 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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_SERVICE_RECORD_WIN_H_ 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_SERVICE_RECORD_WIN_H_
6 #define DEVICE_BLUETOOTH_BLUETOOTH_SERVICE_RECORD_WIN_H_ 6 #define DEVICE_BLUETOOTH_BLUETOOTH_SERVICE_RECORD_WIN_H_
7 7
8 #include <stdint.h>
9
8 #include <string> 10 #include <string>
9 #include <vector> 11 #include <vector>
10 12
11 #include "base/basictypes.h" 13 #include "base/macros.h"
12 #include "device/bluetooth/bluetooth_export.h" 14 #include "device/bluetooth/bluetooth_export.h"
13 #include "device/bluetooth/bluetooth_init_win.h" 15 #include "device/bluetooth/bluetooth_init_win.h"
14 #include "device/bluetooth/bluetooth_uuid.h" 16 #include "device/bluetooth/bluetooth_uuid.h"
15 17
16 namespace device { 18 namespace device {
17 19
18 class DEVICE_BLUETOOTH_EXPORT BluetoothServiceRecordWin { 20 class DEVICE_BLUETOOTH_EXPORT BluetoothServiceRecordWin {
19 public: 21 public:
20 BluetoothServiceRecordWin(const std::string& device_address, 22 BluetoothServiceRecordWin(const std::string& device_address,
21 const std::string& name, 23 const std::string& name,
22 const std::vector<uint8>& sdp_bytes, 24 const std::vector<uint8_t>& sdp_bytes,
23 const BluetoothUUID& gatt_uuid); 25 const BluetoothUUID& gatt_uuid);
24 26
25 bool IsEqual(const BluetoothServiceRecordWin& other); 27 bool IsEqual(const BluetoothServiceRecordWin& other);
26 28
27 // The BTH_ADDR address of the BluetoothDevice providing this service. 29 // The BTH_ADDR address of the BluetoothDevice providing this service.
28 BTH_ADDR device_bth_addr() const { return device_bth_addr_; } 30 BTH_ADDR device_bth_addr() const { return device_bth_addr_; }
29 31
30 // The address of the BluetoothDevice providing this service. 32 // The address of the BluetoothDevice providing this service.
31 const std::string& device_address() const { return device_address_; } 33 const std::string& device_address() const { return device_address_; }
32 34
33 // The human-readable name of this service. 35 // The human-readable name of this service.
34 const std::string& name() const { return name_; } 36 const std::string& name() const { return name_; }
35 37
36 // The UUID of the service. This field may be empty if no UUID was 38 // The UUID of the service. This field may be empty if no UUID was
37 // specified in the service record. 39 // specified in the service record.
38 const BluetoothUUID& uuid() const { return uuid_; } 40 const BluetoothUUID& uuid() const { return uuid_; }
39 41
40 // Indicates if this service supports RFCOMM communication. 42 // Indicates if this service supports RFCOMM communication.
41 bool SupportsRfcomm() const { return supports_rfcomm_; } 43 bool SupportsRfcomm() const { return supports_rfcomm_; }
42 44
43 // The RFCOMM channel to use, if this service supports RFCOMM communication. 45 // The RFCOMM channel to use, if this service supports RFCOMM communication.
44 // The return value is undefined if SupportsRfcomm() returns false. 46 // The return value is undefined if SupportsRfcomm() returns false.
45 uint8 rfcomm_channel() const { return rfcomm_channel_; } 47 uint8_t rfcomm_channel() const { return rfcomm_channel_; }
46 48
47 private: 49 private:
48 BTH_ADDR device_bth_addr_; 50 BTH_ADDR device_bth_addr_;
49 std::string device_address_; 51 std::string device_address_;
50 std::string name_; 52 std::string name_;
51 BluetoothUUID uuid_; 53 BluetoothUUID uuid_;
52 54
53 bool supports_rfcomm_; 55 bool supports_rfcomm_;
54 uint8 rfcomm_channel_; 56 uint8_t rfcomm_channel_;
55 57
56 DISALLOW_COPY_AND_ASSIGN(BluetoothServiceRecordWin); 58 DISALLOW_COPY_AND_ASSIGN(BluetoothServiceRecordWin);
57 }; 59 };
58 60
59 } // namespace device 61 } // namespace device
60 62
61 #endif // DEVICE_BLUETOOTH_BLUETOOTH_SERVICE_RECORD_WIN_H_ 63 #endif // DEVICE_BLUETOOTH_BLUETOOTH_SERVICE_RECORD_WIN_H_
OLDNEW
« no previous file with comments | « device/bluetooth/bluetooth_rfcomm_channel_mac.h ('k') | device/bluetooth/bluetooth_service_record_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698