#include <Leap.h>
The ToolList class represents a list of Tool objects.
Get a ToolList object by calling Frame::tools().
◆ ToolList() [1/2]
◆ ToolList() [2/2]
LEAP_EXPORT Leap::ToolList::ToolList |
( |
| ) |
|
Constructs an empty list of tools.
◆ append()
◆ begin()
The C++ iterator set to the beginning of this ToolList.
◆ count()
LEAP_EXPORT int Leap::ToolList::count |
( |
| ) |
const |
Returns the number of tools in this list.
- Returns
- The number of tools in this list.
◆ empty()
LEAP_EXPORT bool Leap::ToolList::empty |
( |
| ) |
const |
◆ end()
The C++ iterator set to the end of this ToolList.
◆ frontmost()
LEAP_EXPORT Tool Leap::ToolList::frontmost |
( |
| ) |
const |
The member of the list that is farthest to the front within the standard Leap frame of reference (i.e has the smallest Z coordinate).
- Returns
- The frontmost tool, or invalid if list is empty.
◆ isEmpty()
LEAP_EXPORT bool Leap::ToolList::isEmpty |
( |
| ) |
const |
Reports whether the list is empty.
- Returns
- True, if the list has no members.
◆ leftmost()
LEAP_EXPORT Tool Leap::ToolList::leftmost |
( |
| ) |
const |
The member of the list that is farthest to the left within the standard Leap frame of reference (i.e has the smallest X coordinate).
- Returns
- The leftmost tool, or invalid if list is empty.
◆ operator[]()
LEAP_EXPORT Tool Leap::ToolList::operator[] |
( |
int |
index | ) |
const |
Access a list member by its position in the list.
- Parameters
-
index | The zero-based list position index. |
- Returns
- The Tool object at the specified index.
◆ rightmost()
LEAP_EXPORT Tool Leap::ToolList::rightmost |
( |
| ) |
const |
The member of the list that is farthest to the right within the standard Leap frame of reference (i.e has the largest X coordinate).
- Returns
- The rightmost tool, or invalid if list is empty.