PX4 Firmware
PX4 Autopilot Software http://px4.io
|
#include <timestamped_list.h>
Classes | |
struct | item_t |
Public Member Functions | |
TimestampedList (int num_items) | |
~TimestampedList () | |
void | put (const T &new_value) |
Insert a value into the list, overwrite the oldest entry if full. More... | |
void | reset_to_start () |
Before iterating using get_next(), reset to start. More... | |
T * | get_next () |
Iterate through all active values (not sorted). More... | |
void | drop_current () |
Disable the last item that we have gotten. More... | |
void | update_current () |
Update the timestamp of the item we have gotten. More... | |
TimestampedList (const TimestampedList &)=delete | |
TimestampedList | operator= (const TimestampedList &)=delete |
Private Attributes | |
item_t * | _list = nullptr |
int | _list_len = 0 |
int | _current_i = -1 |
Definition at line 53 of file timestamped_list.h.
|
inline |
Definition at line 56 of file timestamped_list.h.
Referenced by TimestampedList< MavlinkCommandSender::command_item_t >::update_current().
|
inline |
Definition at line 62 of file timestamped_list.h.
|
delete |
|
inline |
Disable the last item that we have gotten.
Definition at line 129 of file timestamped_list.h.
|
inline |
Iterate through all active values (not sorted).
Return nullptr if at end of list.
This is basically a poor man's iterator.
Definition at line 111 of file timestamped_list.h.
|
delete |
Referenced by TimestampedList< MavlinkCommandSender::command_item_t >::update_current().
|
inline |
Insert a value into the list, overwrite the oldest entry if full.
Definition at line 70 of file timestamped_list.h.
|
inline |
Before iterating using get_next(), reset to start.
Definition at line 100 of file timestamped_list.h.
|
inline |
Update the timestamp of the item we have gotten.
Definition at line 139 of file timestamped_list.h.
|
private |
Definition at line 158 of file timestamped_list.h.
Referenced by TimestampedList< MavlinkCommandSender::command_item_t >::drop_current(), TimestampedList< MavlinkCommandSender::command_item_t >::get_next(), TimestampedList< MavlinkCommandSender::command_item_t >::reset_to_start(), and TimestampedList< MavlinkCommandSender::command_item_t >::update_current().
|
private |
Definition at line 156 of file timestamped_list.h.
Referenced by TimestampedList< MavlinkCommandSender::command_item_t >::drop_current(), TimestampedList< MavlinkCommandSender::command_item_t >::get_next(), TimestampedList< MavlinkCommandSender::command_item_t >::put(), TimestampedList< MavlinkCommandSender::command_item_t >::TimestampedList(), TimestampedList< MavlinkCommandSender::command_item_t >::update_current(), and TimestampedList< MavlinkCommandSender::command_item_t >::~TimestampedList().
|
private |
Definition at line 157 of file timestamped_list.h.
Referenced by TimestampedList< MavlinkCommandSender::command_item_t >::drop_current(), TimestampedList< MavlinkCommandSender::command_item_t >::get_next(), TimestampedList< MavlinkCommandSender::command_item_t >::put(), TimestampedList< MavlinkCommandSender::command_item_t >::TimestampedList(), and TimestampedList< MavlinkCommandSender::command_item_t >::update_current().