votca 2026-dev
Loading...
Searching...
No Matches
votca::xtp::ResultFile Class Reference

Small machine-readable result file of a calculator: one "key value unit" line per quantity (unit "-" if dimensionless), after a "#" header. Meant for scripts, tutorials and regression tests. More...

#include <resultfile.h>

Collaboration diagram for votca::xtp::ResultFile:

Public Member Functions

 ResultFile (const std::string &title)
void Add (const std::string &key, double value, const std::string &unit)
void Add (const std::string &key, Index value)
void Add (const std::string &key, const std::string &value)
void Write (const std::string &filename) const

Private Attributes

std::stringstream text_

Detailed Description

Small machine-readable result file of a calculator: one "key value unit" line per quantity (unit "-" if dimensionless), after a "#" header. Meant for scripts, tutorials and regression tests.

Definition at line 42 of file resultfile.h.

Constructor & Destructor Documentation

◆ ResultFile()

votca::xtp::ResultFile::ResultFile ( const std::string & title)
inlineexplicit

Definition at line 44 of file resultfile.h.

Member Function Documentation

◆ Add() [1/3]

void votca::xtp::ResultFile::Add ( const std::string & key,
const std::string & value )
inline

Definition at line 55 of file resultfile.h.

◆ Add() [2/3]

void votca::xtp::ResultFile::Add ( const std::string & key,
double value,
const std::string & unit )
inline

Definition at line 49 of file resultfile.h.

◆ Add() [3/3]

void votca::xtp::ResultFile::Add ( const std::string & key,
Index value )
inline

Definition at line 52 of file resultfile.h.

◆ Write()

void votca::xtp::ResultFile::Write ( const std::string & filename) const
inline

Definition at line 59 of file resultfile.h.

Member Data Documentation

◆ text_

std::stringstream votca::xtp::ResultFile::text_
private

Definition at line 68 of file resultfile.h.


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