Garmin Fleet Management Controller  2.19.0
AobrdEventLogConverter Class Reference

Utility for converting between raw AOBRD data to human- readable CSV file. Used to attempt to auto-convert files received from device and CSV files selected for upload as AOBRD content to device. More...

#include <AobrdEventLogConverter.h>

Public Types

enum  evt_log_reason {
  DRIVER_ANNOTATION,
  DRIVER_STATUS_CHANGE,
  DRIVER_VERIFIED_LOG,
  DRIVER_COULD_NOT_VERIFY_LOG,
  DRIVER_ADDED_NEW_SHIPMENT_ENTRY,
  DRIVER_MODIFIED_EXISTING_SHIPMENT_ENTRY,
  PND_FAILURE_DETECTION,
  DRIVER_DELETED_SHIPMENT_ENTRY,
  EVT_LOG_REASON_COUNT
}
 

Public Member Functions

 AobrdEventLogConverter ()
 Constructor. More...
 
bool convertAnnotation (std::vector< std::string > &record, fmi_driver_annotation_data_type *annotation)
 Convert an Annotation record to structure sent to FMI device. More...
 
void convertToCsv (const char *source, const char *destFormat)
 Convert raw file to CSV. More...
 
uint32 convertToRaw (const char *source, const char *dest)
 Convert CSV file to raw. More...
 
uint16 countRecords (const char *source, evt_log_reason type)
 Count records by type. More...
 
bool findRecordAt (const char *source, evt_log_reason type, uint16 index, bool(*visitor)(AobrdEventLogConverter *converter, std::vector< std::string > &record, void *data), void *data)
 Visit records by type and index. More...
 

Detailed Description

Utility for converting between raw AOBRD data to human- readable CSV file. Used to attempt to auto-convert files received from device and CSV files selected for upload as AOBRD content to device.

Since
Protocol A610

Definition at line 26 of file AobrdEventLogConverter.h.

Member Enumeration Documentation

Enumerator
DRIVER_ANNOTATION 
DRIVER_STATUS_CHANGE 
DRIVER_VERIFIED_LOG 
DRIVER_COULD_NOT_VERIFY_LOG 
DRIVER_ADDED_NEW_SHIPMENT_ENTRY 
DRIVER_MODIFIED_EXISTING_SHIPMENT_ENTRY 
PND_FAILURE_DETECTION 
DRIVER_DELETED_SHIPMENT_ENTRY 
EVT_LOG_REASON_COUNT 

Definition at line 30 of file AobrdEventLogConverter.h.

Constructor & Destructor Documentation

AobrdEventLogConverter::AobrdEventLogConverter ( )

Constructor.

Definition at line 55 of file AobrdEventLogConverter.cpp.

Member Function Documentation

bool AobrdEventLogConverter::convertAnnotation ( std::vector< std::string > &  record,
fmi_driver_annotation_data_type annotation 
)
uint32 AobrdEventLogConverter::convertToRaw ( const char *  source,
const char *  dest 
)
uint16 AobrdEventLogConverter::countRecords ( const char *  source,
evt_log_reason  type 
)

Count records by type.

Definition at line 956 of file AobrdEventLogConverter.cpp.

References readCSVRecord().

Referenced by FmiApplicationLayer::rx().

bool AobrdEventLogConverter::findRecordAt ( const char *  source,
evt_log_reason  type,
uint16  index,
bool(*)(AobrdEventLogConverter *converter, std::vector< std::string > &record, void *data)  visitor,
void *  data 
)

Visit records by type and index.

Definition at line 991 of file AobrdEventLogConverter.cpp.

References readCSVRecord().

Referenced by FmiApplicationLayer::sendNextAOBRDAnnotation().


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