| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 USBConfiguration_h | 5 #ifndef USBConfiguration_h |
| 6 #define USBConfiguration_h | 6 #define USBConfiguration_h |
| 7 | 7 |
| 8 #include "bindings/core/v8/ScriptWrappable.h" | 8 #include "bindings/core/v8/ScriptWrappable.h" |
| 9 #include "device/usb/public/interfaces/device.mojom-blink.h" | 9 #include "device/usb/public/interfaces/device.mojom-blink.h" |
| 10 #include "platform/heap/Handle.h" | 10 #include "platform/heap/Handle.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 public: | 22 public: |
| 23 static USBConfiguration* Create(const USBDevice*, size_t configuration_index); | 23 static USBConfiguration* Create(const USBDevice*, size_t configuration_index); |
| 24 static USBConfiguration* Create(const USBDevice*, | 24 static USBConfiguration* Create(const USBDevice*, |
| 25 size_t configuration_value, | 25 size_t configuration_value, |
| 26 ExceptionState&); | 26 ExceptionState&); |
| 27 | 27 |
| 28 USBConfiguration(const USBDevice*, size_t configuration_index); | 28 USBConfiguration(const USBDevice*, size_t configuration_index); |
| 29 | 29 |
| 30 const USBDevice* Device() const; | 30 const USBDevice* Device() const; |
| 31 size_t Index() const; | 31 size_t Index() const; |
| 32 const device::usb::blink::ConfigurationInfo& Info() const; | 32 const device::mojom::blink::UsbConfigurationInfo& Info() const; |
| 33 | 33 |
| 34 uint8_t configurationValue() const { return Info().configuration_value; } | 34 uint8_t configurationValue() const { return Info().configuration_value; } |
| 35 String configurationName() const { return Info().configuration_name; } | 35 String configurationName() const { return Info().configuration_name; } |
| 36 HeapVector<Member<USBInterface>> interfaces() const; | 36 HeapVector<Member<USBInterface>> interfaces() const; |
| 37 | 37 |
| 38 DECLARE_TRACE(); | 38 DECLARE_TRACE(); |
| 39 | 39 |
| 40 private: | 40 private: |
| 41 Member<const USBDevice> device_; | 41 Member<const USBDevice> device_; |
| 42 const size_t configuration_index_; | 42 const size_t configuration_index_; |
| 43 }; | 43 }; |
| 44 | 44 |
| 45 } // namespace blink | 45 } // namespace blink |
| 46 | 46 |
| 47 #endif // USBConfiguration_h | 47 #endif // USBConfiguration_h |
| OLD | NEW |