flux sdk  v01.02.02-3-g292b3a7
Embedded C++ SDK
Loading...
Searching...
No Matches
flxFormatJSON< BUFFER_SIZE > Class Template Reference

#include <flxFmtJSON.h>

Inheritance diagram for flxFormatJSON< BUFFER_SIZE >:
flxOutputFormat

Public Member Functions

 flxFormatJSON ()
 
void logValue (const std::string &tag, bool value)
 
void logValue (const std::string &tag, int8_t value)
 
void logValue (const std::string &tag, int16_t value)
 
void logValue (const std::string &tag, int32_t value)
 
void logValue (const std::string &tag, uint8_t value)
 
void logValue (const std::string &tag, uint16_t value)
 
void logValue (const std::string &tag, uint32_t value)
 
void logValue (const std::string &tag, float value, uint16_t precision=3)
 
void logValue (const std::string &tag, double value, uint16_t precision=3)
 
void logValue (const std::string &tag, const std::string &value)
 
void logValue (const std::string &tag, const char *value)
 
void logValue (const std::string &tag, flxDataArrayBool *value)
 
void logValue (const std::string &tag, flxDataArrayInt8 *value)
 
void logValue (const std::string &tag, flxDataArrayInt16 *value)
 
void logValue (const std::string &tag, flxDataArrayInt32 *value)
 
void logValue (const std::string &tag, flxDataArrayUInt8 *value)
 
void logValue (const std::string &tag, flxDataArrayUInt16 *value)
 
void logValue (const std::string &tag, flxDataArrayUInt32 *value)
 
void logValue (const std::string &tag, flxDataArrayFloat *value, uint16_t precision=3)
 
void logValue (const std::string &tag, flxDataArrayDouble *value, uint16_t precision=3)
 
void logValue (const std::string &tag, flxDataArrayString *value)
 
virtual void beginObservation (const char *szTitle=nullptr)
 
void beginSection (const char *szName)
 
void endSection ()
 
void endObservation (void)
 
virtual void writeObservation ()
 
void clearObservation (void)
 
void reset (void)
 
void add (flxIWriterJSON &newWriter)
 
void add (flxIWriterJSON *newWriter)
 
void remove (flxIWriterJSON *oldWriter)
 
void setBufferSize (size_t new_size)
 
size_t bufferSize (void)
 
uint32_t getMaxSizeUsed (void)
 
void add (flxWriter &newWriter)
 
void add (flxWriter *newWriter)
 
void remove (flxWriter &oldWriter)
 
void remove (flxWriter *oldWriter)
 
- Public Member Functions inherited from flxOutputFormat
 flxOutputFormat ()
 
virtual void logValue (const std::string &tag, bool value)=0
 
virtual void logValue (const std::string &tag, int8_t value)=0
 
virtual void logValue (const std::string &tag, int16_t value)=0
 
virtual void logValue (const std::string &tag, int32_t value)=0
 
virtual void logValue (const std::string &tag, uint8_t value)=0
 
virtual void logValue (const std::string &tag, uint16_t value)=0
 
virtual void logValue (const std::string &tag, uint32_t value)=0
 
virtual void logValue (const std::string &tag, float value, uint16_t precision=3)=0
 
virtual void logValue (const std::string &tag, double value, uint16_t precision=3)=0
 
virtual void logValue (const std::string &tag, const char *value)=0
 
virtual void logValue (const std::string &tag, std::string &value)
 
virtual void logValue (const std::string &tag, flxDataArrayBool *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayInt8 *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayInt16 *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayInt32 *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayUInt8 *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayUInt16 *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayUInt32 *value)=0
 
virtual void logValue (const std::string &tag, flxDataArrayFloat *value, uint16_t precision=3)=0
 
virtual void logValue (const std::string &tag, flxDataArrayDouble *value, uint16_t precision=3)=0
 
virtual void logValue (const std::string &tag, flxDataArrayString *value)=0
 
virtual void beginObservation (const char *szTitle=nullptr)=0
 
virtual void beginSection (const char *szName)
 
virtual void beginSection (const std::string &name)
 
virtual void endSection (void)
 
virtual void endObservation (void)=0
 
virtual void writeObservation (void)=0
 
virtual void clearObservation (void)
 
virtual void reset (void)
 
void add (flxWriter &newWriter)
 
void add (flxWriter *newWriter)
 
void remove (flxWriter &oldWriter)
 
void remove (flxWriter *oldWriter)
 
void outputObservation (const char *szBuffer, flxLineType_t type=flxLineTypeData)
 

Protected Member Functions

template<typename T >
void writeOutArrayDimension (JsonArray &jsonArray, T *&pData, flxDataArrayType< T > *theArray, uint16_t currentDim)
 
template<typename T >
void writeOutArray (const std::string &tag, flxDataArrayType< T > *theArray)
 

Protected Attributes

JsonObject _jSection
 
size_t _buffer_size
 
std::shared_ptr< JsonDocument > _spDoc
 

Constructor & Destructor Documentation

◆ flxFormatJSON()

template<std::size_t BUFFER_SIZE>
flxFormatJSON< BUFFER_SIZE >::flxFormatJSON ( )
inline

Member Function Documentation

◆ add() [1/4]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::add ( flxIWriterJSON newWriter)
inline

◆ add() [2/4]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::add ( flxIWriterJSON newWriter)
inline

◆ add() [3/4]

template<std::size_t BUFFER_SIZE>
void flxOutputFormat::add ( flxWriter newWriter)
inline

◆ add() [4/4]

template<std::size_t BUFFER_SIZE>
void flxOutputFormat::add ( flxWriter newWriter)
inline

◆ beginObservation()

template<std::size_t BUFFER_SIZE>
virtual void flxFormatJSON< BUFFER_SIZE >::beginObservation ( const char *  szTitle = nullptr)
inlinevirtual

Implements flxOutputFormat.

◆ beginSection()

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::beginSection ( const char *  szName)
inlinevirtual

Reimplemented from flxOutputFormat.

◆ bufferSize()

template<std::size_t BUFFER_SIZE>
size_t flxFormatJSON< BUFFER_SIZE >::bufferSize ( void  )
inline

◆ clearObservation()

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::clearObservation ( void  )
inlinevirtual

Reimplemented from flxOutputFormat.

◆ endObservation()

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::endObservation ( void  )
inlinevirtual

Implements flxOutputFormat.

◆ endSection()

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::endSection ( void  )
inlinevirtual

Reimplemented from flxOutputFormat.

◆ getMaxSizeUsed()

template<std::size_t BUFFER_SIZE>
uint32_t flxFormatJSON< BUFFER_SIZE >::getMaxSizeUsed ( void  )
inline

◆ logValue() [1/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
bool  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [2/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
const char *  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [3/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
const std::string &  value 
)
inline

◆ logValue() [4/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
double  value,
uint16_t  precision = 3 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [5/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
float  value,
uint16_t  precision = 3 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [6/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayBool value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [7/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayDouble value,
uint16_t  precision = 3 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [8/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayFloat value,
uint16_t  precision = 3 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [9/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayInt16 value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [10/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayInt32 value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [11/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayInt8 value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [12/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayString value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [13/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayUInt16 value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [14/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayUInt32 value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [15/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
flxDataArrayUInt8 value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [16/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
int16_t  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [17/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
int32_t  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [18/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
int8_t  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [19/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
uint16_t  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [20/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
uint32_t  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ logValue() [21/21]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::logValue ( const std::string &  tag,
uint8_t  value 
)
inlinevirtual

Implements flxOutputFormat.

◆ remove() [1/3]

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::remove ( flxIWriterJSON oldWriter)
inline

◆ remove() [2/3]

template<std::size_t BUFFER_SIZE>
void flxOutputFormat::remove ( flxWriter oldWriter)
inline

◆ remove() [3/3]

template<std::size_t BUFFER_SIZE>
void flxOutputFormat::remove ( flxWriter oldWriter)
inline

◆ reset()

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::reset ( void  )
inlinevirtual

Reimplemented from flxOutputFormat.

◆ setBufferSize()

template<std::size_t BUFFER_SIZE>
void flxFormatJSON< BUFFER_SIZE >::setBufferSize ( size_t  new_size)
inline

◆ writeObservation()

template<std::size_t BUFFER_SIZE>
virtual void flxFormatJSON< BUFFER_SIZE >::writeObservation ( void  )
inlinevirtual

Implements flxOutputFormat.

◆ writeOutArray()

template<std::size_t BUFFER_SIZE>
template<typename T >
void flxFormatJSON< BUFFER_SIZE >::writeOutArray ( const std::string &  tag,
flxDataArrayType< T > *  theArray 
)
inlineprotected

◆ writeOutArrayDimension()

template<std::size_t BUFFER_SIZE>
template<typename T >
void flxFormatJSON< BUFFER_SIZE >::writeOutArrayDimension ( JsonArray &  jsonArray,
T *&  pData,
flxDataArrayType< T > *  theArray,
uint16_t  currentDim 
)
inlineprotected

Member Data Documentation

◆ _buffer_size

template<std::size_t BUFFER_SIZE>
size_t flxFormatJSON< BUFFER_SIZE >::_buffer_size
protected

◆ _jSection

template<std::size_t BUFFER_SIZE>
JsonObject flxFormatJSON< BUFFER_SIZE >::_jSection
protected

◆ _spDoc

template<std::size_t BUFFER_SIZE>
std::shared_ptr<JsonDocument> flxFormatJSON< BUFFER_SIZE >::_spDoc
protected

The documentation for this class was generated from the following file: