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

Side by Side Diff: device/usb/usb_descriptors.h

Issue 869063004: Remove iterator typedefs for USB descriptor types. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_USB_USB_DESCRIPTORS_H_ 5 #ifndef DEVICE_USB_USB_DESCRIPTORS_H_
6 #define DEVICE_USB_USB_DESCRIPTORS_H_ 6 #define DEVICE_USB_USB_DESCRIPTORS_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 21 matching lines...) Expand all
32 enum UsbUsageType { 32 enum UsbUsageType {
33 USB_USAGE_DATA = 0, 33 USB_USAGE_DATA = 0,
34 USB_USAGE_FEEDBACK, 34 USB_USAGE_FEEDBACK,
35 USB_USAGE_EXPLICIT_FEEDBACK 35 USB_USAGE_EXPLICIT_FEEDBACK
36 }; 36 };
37 37
38 struct UsbEndpointDescriptor { 38 struct UsbEndpointDescriptor {
39 UsbEndpointDescriptor(); 39 UsbEndpointDescriptor();
40 ~UsbEndpointDescriptor(); 40 ~UsbEndpointDescriptor();
41 41
42 typedef std::vector<UsbEndpointDescriptor>::const_iterator Iterator;
43
44 uint8_t address; 42 uint8_t address;
45 UsbEndpointDirection direction; 43 UsbEndpointDirection direction;
46 uint16_t maximum_packet_size; 44 uint16_t maximum_packet_size;
47 UsbSynchronizationType synchronization_type; 45 UsbSynchronizationType synchronization_type;
48 UsbTransferType transfer_type; 46 UsbTransferType transfer_type;
49 UsbUsageType usage_type; 47 UsbUsageType usage_type;
50 uint16_t polling_interval; 48 uint16_t polling_interval;
51 std::vector<uint8_t> extra_data; 49 std::vector<uint8_t> extra_data;
52 }; 50 };
53 51
54 struct UsbInterfaceDescriptor { 52 struct UsbInterfaceDescriptor {
55 UsbInterfaceDescriptor(); 53 UsbInterfaceDescriptor();
56 ~UsbInterfaceDescriptor(); 54 ~UsbInterfaceDescriptor();
57 55
58 typedef std::vector<UsbInterfaceDescriptor>::const_iterator Iterator;
59
60 uint8_t interface_number; 56 uint8_t interface_number;
61 uint8_t alternate_setting; 57 uint8_t alternate_setting;
62 uint8_t interface_class; 58 uint8_t interface_class;
63 uint8_t interface_subclass; 59 uint8_t interface_subclass;
64 uint8_t interface_protocol; 60 uint8_t interface_protocol;
65 std::vector<UsbEndpointDescriptor> endpoints; 61 std::vector<UsbEndpointDescriptor> endpoints;
66 std::vector<uint8_t> extra_data; 62 std::vector<uint8_t> extra_data;
67 }; 63 };
68 64
69 struct UsbConfigDescriptor { 65 struct UsbConfigDescriptor {
70 UsbConfigDescriptor(); 66 UsbConfigDescriptor();
71 ~UsbConfigDescriptor(); 67 ~UsbConfigDescriptor();
72 68
73 uint8_t configuration_value; 69 uint8_t configuration_value;
74 bool self_powered; 70 bool self_powered;
75 bool remote_wakeup; 71 bool remote_wakeup;
76 uint16_t maximum_power; 72 uint16_t maximum_power;
77 std::vector<UsbInterfaceDescriptor> interfaces; 73 std::vector<UsbInterfaceDescriptor> interfaces;
78 std::vector<uint8_t> extra_data; 74 std::vector<uint8_t> extra_data;
79 }; 75 };
80 76
81 } // namespace device 77 } // namespace device
82 78
83 #endif // DEVICE_USB_USB_DESCRIPTORS_H_ 79 #endif // DEVICE_USB_USB_DESCRIPTORS_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698