DamBreak++ Wave Simulator 0.3
DamBreak++ Simulation Framework
Loading...
Searching...
No Matches
Testvs19::FileDataStore Class Reference

File based implementation of the DataStore interface. This class makes use of the toString() method defined in the PhysicalMeasurement interface. More...

#include <Testvs19_FileDataStore.h>

Inheritance diagram for Testvs19::FileDataStore:

Public Member Functions

void close () override final
 Method to close the connection to the data store.
void open () override final
 Method to open a connection to the data store.
void save (Sfx::IPhyMeasurement *aMeasure) override final
 Method to write the PhysicalMeasurement data to the file.
void save (Sfx::IPhysicalMeasurement *aPhysicalMeasure) override final
 Method to save the PhysicalMeasurement bean to the data store.
void setFileName (std::string aFilename)
 Set data store file name.
bool isOpen () const
 check if file open

Private Attributes

bool m_isOpen {false}
 A file for saving result.
std::ofstream m_FileRes
std::string m_fileName {}

Detailed Description

File based implementation of the DataStore interface. This class makes use of the toString() method defined in the PhysicalMeasurement interface.

Member Function Documentation

◆ close()

void Testvs19::FileDataStore::close ( )
finaloverride

Method to close the connection to the data store.

◆ isOpen()

bool Testvs19::FileDataStore::isOpen ( ) const
inline

check if file open

Returns
true/false

◆ open()

void Testvs19::FileDataStore::open ( )
finaloverride

Method to open a connection to the data store.

◆ save() [1/2]

void Testvs19::FileDataStore::save ( Sfx::IPhyMeasurement * aMeasure)
inlinefinaloverride

Method to write the PhysicalMeasurement data to the file.

Parameters
aMeasurePhysical measure

◆ save() [2/2]

void Testvs19::FileDataStore::save ( Sfx::IPhysicalMeasurement * aPhysicalMeasure)
finaloverride

Method to save the PhysicalMeasurement bean to the data store.

Parameters
aPhysicalMeasure

◆ setFileName()

void Testvs19::FileDataStore::setFileName ( std::string aFilename)
inline

Set data store file name.

Parameters
aFilenameflie name

Member Data Documentation

◆ m_fileName

std::string Testvs19::FileDataStore::m_fileName {}
private

file name

◆ m_FileRes

std::ofstream Testvs19::FileDataStore::m_FileRes
private

file stream

◆ m_isOpen

bool Testvs19::FileDataStore::m_isOpen {false}
private

A file for saving result.

file status


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