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

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

Issue 826283002: Add support for sending a USB SET_CONFIGURATION request. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. 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 | « device/usb/usb_device_filter_unittest.cc ('k') | device/usb/usb_device_handle_impl.h » ('j') | 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_DEVICE_HANDLE_H_ 5 #ifndef DEVICE_USB_USB_DEVICE_HANDLE_H_
6 #define DEVICE_USB_USB_DEVICE_HANDLE_H_ 6 #define DEVICE_USB_USB_DEVICE_HANDLE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 44
45 // Notifies UsbDevice to drop the reference of this object; cancels all the 45 // Notifies UsbDevice to drop the reference of this object; cancels all the
46 // flying transfers. 46 // flying transfers.
47 // It is possible that the object has no other reference after this call. So 47 // It is possible that the object has no other reference after this call. So
48 // if it is called using a raw pointer, it could be invalidated. 48 // if it is called using a raw pointer, it could be invalidated.
49 // The platform device handle will be closed when UsbDeviceHandle destructs. 49 // The platform device handle will be closed when UsbDeviceHandle destructs.
50 virtual void Close() = 0; 50 virtual void Close() = 0;
51 51
52 // Device manipulation operations. These methods are blocking and must be 52 // Device manipulation operations. These methods are blocking and must be
53 // called on FILE thread. 53 // called on FILE thread.
54 virtual bool SetConfiguration(int configuration_value) = 0;
54 virtual bool ClaimInterface(int interface_number) = 0; 55 virtual bool ClaimInterface(int interface_number) = 0;
55 virtual bool ReleaseInterface(int interface_number) = 0; 56 virtual bool ReleaseInterface(int interface_number) = 0;
56 virtual bool SetInterfaceAlternateSetting(int interface_number, 57 virtual bool SetInterfaceAlternateSetting(int interface_number,
57 int alternate_setting) = 0; 58 int alternate_setting) = 0;
58 virtual bool ResetDevice() = 0; 59 virtual bool ResetDevice() = 0;
59 60
60 // Gets the string descriptor with the given index from the device, or returns 61 // Gets the string descriptor with the given index from the device, or returns
61 // false. This method is blocking and must be called on the FILE thread. 62 // false. This method is blocking and must be called on the FILE thread.
62 virtual bool GetStringDescriptor(uint8 string_id, base::string16* string) = 0; 63 virtual bool GetStringDescriptor(uint8 string_id, base::string16* string) = 0;
63 64
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 UsbDeviceHandle() {}; 103 UsbDeviceHandle() {};
103 104
104 virtual ~UsbDeviceHandle() {}; 105 virtual ~UsbDeviceHandle() {};
105 106
106 DISALLOW_COPY_AND_ASSIGN(UsbDeviceHandle); 107 DISALLOW_COPY_AND_ASSIGN(UsbDeviceHandle);
107 }; 108 };
108 109
109 } // namespace device 110 } // namespace device
110 111
111 #endif // DEVICE_USB_USB_DEVICE_HANDLE_H_ 112 #endif // DEVICE_USB_USB_DEVICE_HANDLE_H_
OLDNEW
« no previous file with comments | « device/usb/usb_device_filter_unittest.cc ('k') | device/usb/usb_device_handle_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698