Official reference client implementation for Cumulocity SmartREST on u-blox C027.

Dependencies:   C027_Support C12832 LM75B MMA7660 MbedSmartRest mbed-rtos mbed

Fork of MbedSmartRestMain by Vincent Wochnik

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers AbstractReporter.h Source File

AbstractReporter.h

00001 #ifndef ABSTRACTREPORTER_H
00002 #define ABSTRACTREPORTER_H
00003 #include <stddef.h>
00004 
00005 class AbstractReporter
00006 {
00007 public:
00008         virtual ~AbstractReporter() {}
00009         virtual bool init() = 0;
00010 
00011         /* A string representation of the actual report.
00012            \return identifying name of the class.
00013          */
00014         virtual const char* name() const = 0;
00015 
00016         /* Dump a SmartRest report to buf.
00017            \param buf  buffer for the report.
00018            \param maxLen  maximum length of buf.
00019            \param status  a short summary of the report.
00020                           Pass NULL if the status is not interested.
00021            \param num  maximum length of status.
00022            \return  number of characters written to buf, 0 means no report, -1 means error
00023          */
00024         virtual int read(char* buf, size_t maxLen,
00025                             char* status, size_t num) = 0;
00026 };
00027 
00028 #endif /* ABSTRACTREPORTER_H */