![]() |
Fledge
An open source edge computing platform for industrial users
|
A wrapper class for the ReadingSet class that allows conversion to and from Python objects. More...
#include <pythonreadingset.h>
Public Member Functions | |
PythonReadingSet (PyObject *pySet) | |
Construct PythonReadingSet from a python list object that contains a list of readings. More... | |
PyObject * | toPython (bool changeKeys=false) |
Convert the ReadingSet to a Python List. More... | |
![]() | |
ReadingSet () | |
Construct an empty reading set. | |
ReadingSet (const std::string &json) | |
Construct a reading set from a JSON document returned from the Fledge storage service query or notification. More... | |
ReadingSet (const std::vector< Reading *> *readings) | |
Construct a reading set from a vector<Reading *> pointer NOTE: readings are copied into m_readings. More... | |
virtual | ~ReadingSet () |
Destructor for a result set. | |
unsigned long | getCount () const |
const Reading * | operator[] (const unsigned int idx) |
const std::vector< Reading * > & | getAllReadings () const |
std::vector< Reading * > * | getAllReadingsPtr () |
std::vector< Reading * > * | moveAllReadings () |
Remove readings from the vector and return a reference to new vector containing readings*. | |
Reading * | removeReading (unsigned long id) |
Remove reading from vector based on index and return its pointer. | |
unsigned long | getLastId () const |
unsigned long | getReadingId (uint32_t pos) |
Return the ID of the nth reading in the reading set. More... | |
void | append (ReadingSet *) |
Append the readings in a second reading set to this reading set. More... | |
void | append (ReadingSet &) |
Append the readings in a second reading set to this reading set. More... | |
void | append (std::vector< Reading *> &) |
Append a set of readings to this reading set. More... | |
void | removeAll () |
Remove all readings from the reading set and delete the memory After this call the reading set exists but contains no readings. | |
void | clear () |
Remove the readings from the vector without deleting them. | |
bool | copy (const ReadingSet &src) |
Deep copy a set of readings to this reading set. More... | |
Additional Inherited Members | |
![]() | |
ReadingSet (const ReadingSet &) | |
ReadingSet & | operator= (ReadingSet const &) |
![]() | |
unsigned long | m_count |
std::vector< Reading * > | m_readings |
unsigned long | m_last_id |
A wrapper class for the ReadingSet class that allows conversion to and from Python objects.
PythonReadingSet::PythonReadingSet | ( | PyObject * | set | ) |
Construct PythonReadingSet from a python list object that contains a list of readings.
set | A Python object pointer that contians a list of readings |
PyObject * PythonReadingSet::toPython | ( | bool | changeKeys = false | ) |
Convert the ReadingSet to a Python List.