μHAL (v2.7.9)
Part of the IPbus software repository
Functions | Variables
generator.cxx File Reference
#include <cctype>
#include <exception>
#include <fstream>
#include <iostream>
#include <stdint.h>
#include <stdlib.h>
#include <sstream>
#include <string>
#include <vector>
#include <boost/algorithm/string/case_conv.hpp>
Include dependency graph for generator.cxx:

Go to the source code of this file.

Functions

static const uint32_t gNumberEntries (6)
 
static const std::string gDefaultLevel ("Info")
 
static const std::vector< std::string > gLogLevels (gLogLevelsChar, gLogLevelsChar+gNumberEntries)
 
std::string gDivider ("// "+std::string(150,'=')+"\n"+"// WARNING! This file is automatically generated! Do not modify it! Any changes will be overwritten!\n"+"// "+std::string(150,'=')+"\n")
 
void fileHeaders (std::ofstream &aHppFile, std::ofstream &aHxxFile, std::ofstream &aCppFile)
 
void log_configuration_functions (std::ofstream &aHppFile, std::ofstream &aHxxFile, std::ofstream &aCppFile)
 
std::string suffix (uint32_t i)
 
void log_functions (std::ofstream &aHppFile, std::ofstream &aHxxFile, std::ofstream &aCppFile)
 
void fileFooters (std::ofstream &aHppFile, std::ofstream &aHxxFile, std::ofstream &aCppFile)
 
int main (int argc, char *argv[])
 

Variables

static const std::string gLogLevelsChar [] = { "Fatal" , "Error" , "Warning" , "Notice" , "Info" , "Debug" }
 

Function Documentation

◆ fileFooters()

void fileFooters ( std::ofstream &  aHppFile,
std::ofstream &  aHxxFile,
std::ofstream &  aCppFile 
)

Definition at line 414 of file generator.cxx.

Referenced by main().

◆ fileHeaders()

void fileHeaders ( std::ofstream &  aHppFile,
std::ofstream &  aHxxFile,
std::ofstream &  aCppFile 
)

Definition at line 62 of file generator.cxx.

References gDivider().

Referenced by main().

◆ gDefaultLevel()

static const std::string gDefaultLevel ( "Info"  )
static

◆ gDivider()

std::string gDivider ( "// "+std::string(150,'=')+"\n"+"// WARNING! This file is automatically generated! Do not modify it! Any changes will be overwritten!\n"+"// "+std::string(150,'=')+"\n"  )

◆ gLogLevels()

static const std::vector< std::string > gLogLevels ( gLogLevelsChar  ,
gLogLevelsChar gNumberEntries 
)
static

◆ gNumberEntries()

static const uint32_t gNumberEntries ( )
static

◆ log_configuration_functions()

void log_configuration_functions ( std::ofstream &  aHppFile,
std::ofstream &  aHxxFile,
std::ofstream &  aCppFile 
)

Definition at line 119 of file generator.cxx.

References gDefaultLevel(), gDivider(), and gLogLevels().

Referenced by main().

◆ log_functions()

void log_functions ( std::ofstream &  aHppFile,
std::ofstream &  aHxxFile,
std::ofstream &  aCppFile 
)

Definition at line 313 of file generator.cxx.

References gDivider(), gLogLevels(), and suffix().

Referenced by main().

◆ main()

int main ( int  argc,
char *  argv[] 
)

◆ suffix()

std::string suffix ( uint32_t  i)

Definition at line 299 of file generator.cxx.

Referenced by log_functions().

Variable Documentation

◆ gLogLevelsChar

const std::string gLogLevelsChar[] = { "Fatal" , "Error" , "Warning" , "Notice" , "Info" , "Debug" }
static

Definition at line 47 of file generator.cxx.