7 while (std::getline(inputFile, line)) {
Declares a helper that writes processed model code and parameters.
Processes lines of a template C++ file and injects custom code.
void processLine(std::ofstream &outputFile, const std::string ¤tLine)
Processes a single line of input and writes to the output file.
void writeParam(std::ofstream ¶mFile, const std::unordered_map< std::string, double > ¶ms)
Writes parameters to the parameter file.
void writeModel(std::ifstream &inputFile, std::ofstream &outputFile)
Processes the model source and writes the transformed file.
ModelWriter(LineProcessor &lineProcessor, ParamWriter ¶mwriter)
Constructs a ModelWriter with the given helpers.
Helper class to serialize parameter values to a text stream.
void writeParams(std::ofstream &outputFile, const std::unordered_map< std::string, double > ¶ms)
Writes a map of parameters to an output stream.