Methods:
The DeviceList class represents a list of Device objects.
Get a DeviceList object by calling Controller::devices().
Public Type
- Since
- 1.0
Public Functionstypedef ConstListIterator< DeviceList , Device > const_iterator
A C++ iterator type for the DeviceList class.
- Since
- 1.0
DeviceList & append(const DeviceList & other)Appends the members of the specified DeviceList to this DeviceList.
- Since
- 1.0
- Parameters
- other -
A DeviceList object containing Device objects to append to the end of this DeviceList.
const_iterator begin()The C++ iterator set to the beginning of this DeviceList.
- Since
- 1.0
int count()Returns the number of devices in this list.
- Return
- The number of devices in this list.
- Since
- 1.0
DeviceList()Constructs an empty list of devices.
- Since
- 1.0
const_iterator end()The C++ iterator set to the end of this DeviceList.
- Since
- 1.0
bool isEmpty()Reports whether the list is empty.
if(!controller.devices().isEmpty()) Leap::Device leapDevice = controller.devices()[0];
- Return
- True, if the list has no members.
- Since
- 1.0
Device operator[](int index)Access a list member by its position in the list.
- Return
- The Device object at the specified index.
- Since
- 1.0
- Parameters
- index -
The zero-based list position index.