AJA NTV2 SDK  17.1.1.1245
NTV2 SDK 17.1.1.1245
CNTV2SupportLogger Class Reference

Generates a standard support log (register log) for any NTV2 device attached to the host. To write the log into a file, open a std::ofstream, then stream this object into it. More...

#include <ntv2supportlogger.h>

Public Member Functions

 CNTV2SupportLogger (CNTV2Card &card, NTV2SupportLoggerSections sections=NTV2_SupportLoggerSectionsAll)
 Construct from CNTV2Card instance. More...
 
 CNTV2SupportLogger (UWord cardIndex=0, NTV2SupportLoggerSections sections=NTV2_SupportLoggerSectionsAll)
 Default constructor. More...
 
virtual ~CNTV2SupportLogger ()
 My default destructor. More...
 
virtual void PrependToSection (uint32_t section, const std::string &sectionData)
 Prepends arbitrary string data to my support log, ahead of a given section. More...
 
virtual void AppendToSection (uint32_t section, const std::string &sectionData)
 Appends arbitrary string data to my support log, after a given section. More...
 
virtual void AddHeader (const std::string &sectionName, const std::string &sectionData)
 Adds header text to my log. More...
 
virtual void AddFooter (const std::string &sectionName, const std::string &sectionData)
 Adds footer text to my log. More...
 
virtual std::string ToString (void) const
 
virtual void ToString (std::string &outString) const
 Writes my support log into a string object. More...
 
virtual bool LoadFromLog (const std::string &inLogFilePath, const bool bForceLoad)
 

Static Public Member Functions

static int Version (void)
 
static std::string InventLogFilePathAndName (CNTV2Card &inDevice, std::string inPrefix="aja_supportlog", std::string inExtension="log")
 
static bool DumpDeviceSDRAM (CNTV2Card &inDevice, const std::string &inFilePath, std::ostream &msgStream)
 

Detailed Description

Generates a standard support log (register log) for any NTV2 device attached to the host. To write the log into a file, open a std::ofstream, then stream this object into it.

Definition at line 30 of file ntv2supportlogger.h.

Constructor & Destructor Documentation

◆ CNTV2SupportLogger() [1/2]

CNTV2SupportLogger::CNTV2SupportLogger ( CNTV2Card card,
NTV2SupportLoggerSections  sections = NTV2_SupportLoggerSectionsAll 
)

Construct from CNTV2Card instance.

Parameters
[in]cardSpecifies the CNTV2Card instance of the device to be logged. The instance should already be open.
[in]sectionsOptionally specifies which sections to include in the log. Defaults to all sections.

Definition at line 309 of file ntv2supportlogger.cpp.

◆ CNTV2SupportLogger() [2/2]

CNTV2SupportLogger::CNTV2SupportLogger ( UWord  cardIndex = 0,
NTV2SupportLoggerSections  sections = NTV2_SupportLoggerSectionsAll 
)

Default constructor.

Parameters
[in]cardIndexOptionally specifies the zero-based index of the CNTV2Card device to be logged. Defaults to zero, the first device found.
[in]sectionsOptionally specifies which sections to include in the log. Defaults to all sections.

Definition at line 316 of file ntv2supportlogger.cpp.

◆ ~CNTV2SupportLogger()

CNTV2SupportLogger::~CNTV2SupportLogger ( )
virtual

My default destructor.

Definition at line 323 of file ntv2supportlogger.cpp.

Member Function Documentation

◆ AddFooter()

void CNTV2SupportLogger::AddFooter ( const std::string &  sectionName,
const std::string &  sectionData 
)
virtual

Adds footer text to my log.

Parameters
[in]sectionNameSpecifies the section name.
[in]sectionDataSpecifies the footer text.

Definition at line 371 of file ntv2supportlogger.cpp.

◆ AddHeader()

void CNTV2SupportLogger::AddHeader ( const std::string &  sectionName,
const std::string &  sectionData 
)
virtual

Adds header text to my log.

Parameters
[in]sectionNameSpecifies the section name.
[in]sectionDataSpecifies the header text.

Definition at line 363 of file ntv2supportlogger.cpp.

◆ AppendToSection()

void CNTV2SupportLogger::AppendToSection ( uint32_t  section,
const std::string &  sectionData 
)
virtual

Appends arbitrary string data to my support log, after a given section.

Parameters
[in]sectionSpecifies the NTV2SupportLoggerSection to append.
[in]sectionDataSpecifies the text data to append.

Definition at line 349 of file ntv2supportlogger.cpp.

◆ DumpDeviceSDRAM()

bool CNTV2SupportLogger::DumpDeviceSDRAM ( CNTV2Card inDevice,
const std::string &  inFilePath,
std::ostream &  msgStream 
)
static

Definition at line 1099 of file ntv2supportlogger.cpp.

◆ InventLogFilePathAndName()

string CNTV2SupportLogger::InventLogFilePathAndName ( CNTV2Card inDevice,
std::string  inPrefix = "aja_supportlog",
std::string  inExtension = "log" 
)
static

Definition at line 1084 of file ntv2supportlogger.cpp.

◆ LoadFromLog()

bool CNTV2SupportLogger::LoadFromLog ( const std::string &  inLogFilePath,
const bool  bForceLoad 
)
virtual

Definition at line 1005 of file ntv2supportlogger.cpp.

◆ PrependToSection()

void CNTV2SupportLogger::PrependToSection ( uint32_t  section,
const std::string &  sectionData 
)
virtual

Prepends arbitrary string data to my support log, ahead of a given section.

Parameters
[in]sectionSpecifies the NTV2SupportLoggerSection to prepend.
[in]sectionDataSpecifies the text data to prepend.

Definition at line 335 of file ntv2supportlogger.cpp.

◆ ToString() [1/2]

virtual void CNTV2SupportLogger::ToString ( std::string &  outString) const
virtual

Writes my support log into a string object.

Parameters
[out]outStringReceives my entire support log as a standard string, replacing its contents.

◆ ToString() [2/2]

string CNTV2SupportLogger::ToString ( void  ) const
virtual
Returns
My entire support log as a standard string.

Definition at line 397 of file ntv2supportlogger.cpp.

◆ Version()

int CNTV2SupportLogger::Version ( void  )
static
Returns
The log file version I will produce.

Definition at line 329 of file ntv2supportlogger.cpp.


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